svelte-select
svelte-select copied to clipboard
Select items on group search
Is it possible to select items on group search with v5?
In this svelte Repl v4, the search behavior works for everything except grouped items. I.e. the searched item is not selected when pressing enter (when searching for 'Chocolate' in the complex select-field
and then pressing enter, the item is selected, but when doing the same in the group select-field
the item is not getting selected.
It seems to me that is has something to do with the isGroupHeaderSelectable
setting as seen in the example.
When searching the isGroupHeaderSelectable
probably doesn't get checked correctly so that the header is selected internally instead of the first item.
Here's the REPL: https://svelte.dev/repl/4755fdc2817045fe99f0845140a64f30?version=3.20.1
Should be fixed in latest beta?
https://svelte.dev/repl/242d533350d141f3b982e8ebeb229c53?version=3.49.0
Not really when searching “ice“ in the first input field and hitting enter nothing happens, although you would expect to select the “Ice Cream“ item.
I got it fixed locally. I can do a PR.
Should be all fixed in 5.0.0-beta.23
(reopen if not)
https://svelte.dev/repl/242d533350d141f3b982e8ebeb229c53?version=3.49.0