mdb-select resize after destroy

web
mobile

Topic: mdb-select resize after destroy

Jorge Nuñez Malledo pro premium asked 7 days ago

Expected behavior After the material select restart the grid shouldn't be affected in any form. This issue was reported right after version 4.10 release, and surprisingly is still active in version 4.11. Please, provide some workaround and/or ensure this issue in solved in future release

Actual behavior When you perform the Jquery standard materialSelect restart (destroy + init), it seems to be that the destroy method is destroying something else than it shouldn't, because the grid the select belongs to is being unaligned. Check the snippet below

Resources (screenshots, code snippets etc.) https://mdbootstrap.com/snippets/jquery/jorge_nunez_malledo/1636064


Grzegorz Bujański staff commented 6 days ago

Hi,

We already have a task to improve this. We will fix it soon.

Best, Grzegorz


Jorge Nuñez Malledo pro premium commented a day ago

It seems to be that this issue is still active in version 4.12.0. Check the following snippet:

https://mdbootstrap.com/snippets/jquery/jorge_nunez_malledo/1657391

Please, provide a workaround method to updating/destroying Material Select, because it's not working


Grzegorz Bujański staff commented 8 hours ago

Hi,

Sorry about that. We will fix it as soon as possible.

Best, Grzegorz


Jorge Nuñez Malledo pro premium answered 7 hours ago

Well, it should be quick, because unless you state something else,

materialSelect(destroy) materialSelect()

Is the supported way to update select items via jQuery. And I alredy reported this issue for version 4.10.


Please insert min. 20 characters.
Status

Answered

Specification of the issue
  • User: Pro
  • Premium support: Yes
  • Technology: jQuery
  • MDB Version: 4.11.0
  • Device: Lenovo T480
  • Browser: Mozilla Firefox 72.0.1 (64 bit)
  • OS: Windows 10
  • Provided sample code: No
  • Provided link: Yes