vicb/bsmSelect

Selecting item by typing includes multiple items.

rouilj opened this issue · 3 comments

When typing in the select box, bsmSelect will choose an item even if it's not unique.

Using example 1 on:

http://www.suumit.com/projects/bsmSelect/examples/index.html

Highlight the select box (by tabbing to it or clicking it and clicking again on the down arrow).

Now type "honolulu". Note that HongKong is also added to the list. This is wrong only honolulu should be added. An item should be added only if it is unique.

As a second example type "s", and you can add all of the items starting with s. It should add nothing since nothing starts with ssss.

vicb commented

When typing in the select box, bsmSelect will choose an item even if it's not unique.

What do you mean by unique ?

Now type "honolulu". Note that HongKong is also added to the list. This is wrong only honolulu should be added. An item should be added only if it is unique.

To what list, the list below the dropdown ? Not for me, nothing is added until I click or press 'Enter'

I am sorry but I think I don't understanf your issue and at least I can not reproduce it. More details would help.

By unique I mean that the letter S (or h from honolulu) matches more than one option entry in the select.
"list" refers to the block displayed items (with the remove link) below the select box.

This appears to be a browser issue.

chrome - 26.0.1410.64 and 27.0.1453.94
opera - 12.14 1738 and 12.15

work incorrectly selecting and confirming an item (adding it to the list) simply by pressing 's' or 'h'
without needing a return.

I can't reproduce on:

safari - 5.1.7
Pale Moon - 20.1 (a Firefox derivative)

Note that the dropdown menu must not be displayed, but the select box must be in focus.
If the menu is displayed, then with the initial "Click to select a city" highlighted, typing "hono" highlights
Honolulu and I do need to hit enter to confirm the selection and add it to the list in chrome and opera.

-- rouilj

vicb commented

@rouilj Thanks for the details, I was indeed making the tests with the options visible (i.e. dropdown unfolded). Closing the issue as there is nothing I can do about that as bsmSelect rely on a native <select> behavior.