Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Chrome Update 73 - Materialize CSS JS trigger error

After the latest Chrome Update 73, the date pickers, time pickers and dropdowns for Materialize CSS 0.100.2 isn't working anymore, it flickers when you click on it and then disappears.

Any idea how to fix this?

like image 484
doer123456789 Avatar asked Mar 13 '19 17:03

doer123456789


2 Answers

I had the same problem. Although I am using angular2-materialize, I believe this should work for people using materialize directly.

The solution that worked for me was to wrap the materialize select input with a div that has a click listener that simply calls event.stopPropagation():

<div (click)="$event.stopPropagation()">
    <select materialize="material_select" [value]="selectValue" formControlName="someControl">
    // options omitted (not relevant to answer)
    </select>
</div>

I hope this helps some people.

like image 190
Armando Avatar answered Sep 23 '22 23:09

Armando


For those who are too lazy to tweak the materialize.js yourself. I have added a default timeout of 500ms (which I think works consistently). This works with both the date and time pickers.

materialize.js

like image 40
Lemmie Avatar answered Sep 26 '22 23:09

Lemmie