sagalbot / vue-select

Everything you wish the HTML <select> element could do, wrapped up into a lightweight, extensible Vue component.
https://vue-select.org
MIT License
4.62k stars 1.33k forks source link

Dropdown is not hiding itself by clicking inside of box #1606

Closed bbangg closed 2 years ago

bbangg commented 2 years ago

Im using vue 2.6.14 (using all sources statically, not as vue project)

The dropdown is not hiding itself by clicking the search element.

The code which i use

 <v-select role="combobox" :options="[0,1,2,3,4,5]" v-model="current_league" :searchable="false"></v-select>

I just need to hide the dropdown by clicking inside the box (not dropdown icon or outside)

bbangg commented 2 years ago

https://user-images.githubusercontent.com/73590558/156630946-217e78aa-c600-49ff-83b4-1e69e3fc8621.mp4

bbangg commented 2 years ago

I just fix the issue by overwrite the css of .vs__search

.vs--unsearchable:not(.vs--disabled) .vs__search {
    cursor: pointer !important;
    max-width: 1px !important;
    min-width: 1px !important;
}
ihardyslide commented 1 year ago

Hi,

please reopen this issue, since the workaround provided does not work for me. If I add this CSS, then my placeholder-text is not visible anymore:

image

Without this workaround (but then again, dropdown is not closable by clicking in the input):

image

So currently I found no way to fix this issue properly.

I am using vue-select: 4.0.0-beta.6

Thanks & Br