Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ComboBox does not make the found item active #862

Open
laurynasr opened this issue Dec 19, 2022 · 1 comment
Open

ComboBox does not make the found item active #862

laurynasr opened this issue Dec 19, 2022 · 1 comment
Labels
a11y Accessibility issues (keyboard navigation, color contrast, assistive technologies, semantics, etc) enhancement New feature or request react Needs change in react package

Comments

@laurynasr
Copy link

Code Sandbox

Easily reproducible on https://itwin.github.io/iTwinUI-react/?path=/story/core-combobox--basic

Steps to reproduce

  1. Type something into ComboBox to find the matching item, for example, "lith" -- ComboBox displays the single entry "Lithuania"
  2. Press Tab to switch focus to another input
  3. [optional] Press arrow down to select the item
  4. The ComboBox stays empty

Actual behavior

The ComboBox does not take the selection

Expected behavior

The ComboBox should set the single/first result as selection.

The only way I found to select the found item is to type the search text, then use arrow keys to find the item, and then press Enter. This is not how standard tag works, see example here: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select

@laurynasr laurynasr added the bug Something isn't working label Dec 19, 2022
@FlyersPh9 FlyersPh9 added the a11y Accessibility issues (keyboard navigation, color contrast, assistive technologies, semantics, etc) label Dec 19, 2022
@mayank99 mayank99 added enhancement New feature or request and removed bug Something isn't working labels Dec 19, 2022
@mayank99
Copy link
Contributor

mayank99 commented Dec 19, 2022

Reclassifying this as a feature request. There are valid use cases for both patterns.

See examples from w3c aria apg patterns:

(we only seem to support "list autocomplete" currently)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a11y Accessibility issues (keyboard navigation, color contrast, assistive technologies, semantics, etc) enhancement New feature or request react Needs change in react package
Projects
None yet
Development

No branches or pull requests

4 participants