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

tabIndex backwards not working with clear button #2366

Open
RobinAraCom opened this issue May 3, 2024 · 3 comments · May be fixed by #2371
Open

tabIndex backwards not working with clear button #2366

RobinAraCom opened this issue May 3, 2024 · 3 comments · May be fixed by #2371

Comments

@RobinAraCom
Copy link

RobinAraCom commented May 3, 2024

Describe the bug
when you have the dropdown in focus and press tab, you get to the clear button as expected.
when you press shift + tab you get back to the dropdown as expected.
when you press shift + tab (from the dropdown) you are supposed to get to the previous input, but you get to the clear button (the next elemet).

Reproducbile example
live demo, probably everywhere work for me on the first dropdown I saw.

more info
when you spam shift + tab it toggels between the dropdown and the clear button. Even tho there are alot of other inputs on the page.

@lssbq
Copy link

lssbq commented May 6, 2024

Same issue encounted, it trapped the focus and prevent user navigate back by keyboard.
I can only focus backward by 'shift + tab' on the dropdown panel opened.
keyboradnav

@RobinAraCom
Copy link
Author

RobinAraCom commented May 6, 2024

SHIFT + Tab will also select the entry when [selectOnTab] is true, which I think is not desired. Not sure if I should open an new Issue for this.

@lssbq thank you very much for the screenshot/gif

oliverguenther added a commit to oliverguenther/ng-select that referenced this issue May 13, 2024
@oliverguenther oliverguenther linked a pull request May 13, 2024 that will close this issue
@oliverguenther
Copy link

I opened a pull request for this issue, allowing shift+tab to escape the ng-select with the clear icon shown: #2371

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants