josefarias / hotwire_combobox

An accessible autocomplete for Ruby on Rails.
https://hotwirecombobox.com
MIT License
456 stars 30 forks source link

Order of collection affects selection ability #94

Closed aroth closed 6 months ago

aroth commented 6 months ago

Option "A" cannot be selected (left):

  <%= form.combobox(
    :supervisor_idx,
    ["A1", "A", "A2", "A3"]
  ) %>

All options are selectable (right):

  <%= form.combobox(
    :supervisor_idy,
    ["A", "A1", "A2", "A3"]
  ) %>

order

josefarias commented 6 months ago

@aroth great catch! Really appreciate you calling out these edge cases. Should be fixed on v0.1.41 which is out now!