Search code examples
twitter-bootstrapbootstrap-selectpicker

Bootstrap Selectpicker bugs out in center


I encountered a bug(?) for Bootstrap Selectpicker.

On Chrome (so far this happens only on Chrome) when selecting middle, you don't select the selectpicker dropdown, but the actual original select, like this:

enter image description here

As can be seen in the image, the original select drowpdown is picked and also displayed:

enter image description here

Anyone else experiencing this and knows how to fix it?

It can be selected only in the middle for around 10-20 pixels in width :/


Solution

  • Adding this to my site.ccs helped me as a workaround:

    .bootstrap-select > select {
        z-index: 0 !important;
    }
    

    Apparently, the issue is with select's form-control attribute (if you delete it in code, the problem's solved), which adds z-index, that breaks it for Chrome.