Topic: Material Select problem in Chrome (Windows)

russ pro asked 5 years ago


Hi, when I click a Material Select using the Chrome browser on Windows, the dropdown appears for a split second then disappears again. Then when I click the Material Select for a second time, the dropdown appears normally, awaiting selection. This process then repeats - click once and it flashes, click again and it appears normally.

This occurs not only in my own code but also on your own website at https://mdbootstrap.com/docs/jquery/forms/select/

This behaviour does not seem to occur on other browser/OS combinations (ie Chrome for Linux, Firefox (Windows/Linux), Edge (Windows).


Rufus d'Ithamar free commented 5 years ago

Hi, I have the same issue, do you a workaround ?


Piotr Glejzer staff commented 5 years ago

I think it's is still open ticket about this problem. Sorry about that.


Guasy free answered 4 years ago


Updating to the last version worked for me :)


Bartłomiej Malanowski staff commented 4 years ago

That's amazing to hear :)


Rufus d'Ithamar free answered 5 years ago


Hi, if you still have this issue, here is a workaround :

in the file "mdb.js" search the string "_onHTMLClick" (line 20804) in the function

Replace : !$(e.target).closest("#select-options-".concat(this.uuid)).length

By : !$(e.target).closest("#select-options-".concat(this.uuid)).length && !$(e.target).hasClass('mdb-select') && $("#select-options-".concat(this.uuid)).hasClass('active')

Then uglify back your file mdb.js in other to have a .min version again.

Don't forget to update this thread if you have a better solution.


it@strong.tv pro commented 5 years ago

Tnxs Rufus. Super workaround. Line numbers update: mdb.js version 4.5.13 line number: 20779 mdb.lite.js version 4.7.2 line number: 3445


cdenby pro commented 5 years ago

In 4.5.12, it's line 20698 Thanks for the workaround!


Thomas Emmanuel free commented 5 years ago

Hi, Thanks for the workaround. But, after i click open the select, and click outside, the dropdown doesn't close. Any help?


Thomas Emmanuel free commented 5 years ago

Hi, Thanks for the workaround. But, after i click open the select, and click outside, the dropdown doesn't close. Any help?


Rufus d'Ithamar free commented 5 years ago

Hi Thomas, what is the version you're using ? inspect mdb select element to see if you have the class "mdb-select"


Piotr Glejzer staff commented 5 years ago

Did you try to use 4.7.7 version?


it@strong.tv pro answered 5 years ago


Hi Sebastian, any news about a solution for the question ? I have the same issue with chrome on windows. Chrome version Version 73.0.3683.86 (Offizieller Build) (64-Bit)

But it is working on your website. Which version of mdb is being used there ?

Also when clicking the search field, the select is closing.


Sebastian Kaczmarek staff commented 5 years ago

Please try to upgrade to the latest version of MDB. Something has changed in the Chrome Version 73 which was causing the issues but MDB has addressed the most annoying ones. We continue to fix them


Sebastian Kaczmarek staff answered 5 years ago


It seems like a bug, I don't have a quick workaround for this. We'll fix it


russ pro commented 5 years ago

Thanks, it's been driving me crazy!



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Resolved

Specification of the issue

  • ForumUser: Pro
  • Premium support: No
  • Technology: MDB jQuery
  • MDB Version: 4.7.3
  • Device: PC
  • Browser: Chrome
  • OS: Windows
  • Provided sample code: No
  • Provided link: Yes