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

datepicker keyboard tab navigation #3433

Closed
WAmadeus opened this issue Jul 27, 2021 · 6 comments · Fixed by #3749
Closed

datepicker keyboard tab navigation #3433

WAmadeus opened this issue Jul 27, 2021 · 6 comments · Fixed by #3749

Comments

@WAmadeus
Copy link

Overview of the problem

Buefy version: [0.9.8]
Vuejs version: [2.6.12]
OS/Browser: Linux, Firefox 90

Description

Keyboard tab navigation doesn't stop into INPUT element of DatePicker, focusing the outer container instead. It was working fine on previous versions (at least 0.9.3)

Steps to reproduce

Open buefy documentation, "editable" section. Try to navigate using keyboard. You'll have to press TAB twice for keyboard cursor to stop inside DatePicker.

Expected behavior

Press TAB once to focus DatePicker

Actual behavior

You need to press TAB twice. First TAB focus the outer frame of DatePicker. Second TAB finally moves focus to INPUT element.

@oddjobz
Copy link

oddjobz commented Jan 31, 2022

Hi, any news on this one?
To expand a little, I'm seeing the same issue on Chrome, also seems to happen with the time picker widget ...
Buefy version: [0.9.14]
Vuejs version: [2.6.11]

@Spacarar
Copy link
Contributor

I'm having this issue as well, and ran into this before opening my own issue.

to help document this issue I've created two codepens.

Hopefully this will help get this issue some attention.

@Spacarar
Copy link
Contributor

Spacarar commented Jun 13, 2022

This seems to stem back to PR #3363 as commented in #3553

@WAmadeus
Copy link
Author

You are right.

The addition of 'tabIndex="0"' in 'dropdown-trigger' is causing this problem. If you open devtools in your codpen example and manually remove it, it starts to work as expected.

image

Maybe some sort of js to remove it can be a workaround until a proper fix is commited.

@jtommy
Copy link
Member

jtommy commented Jun 13, 2022

@WAmadeus @Spacarar any PR are welcome

@Spacarar
Copy link
Contributor

@jtommy here's a PR that adds a prop trigger-tabindex to the dropdown component and sets it to -1 in the datepicker's dropdown to solve this issue. It was the easiest solution I could think of, but if you have another solution I'm open to suggestions.

#3749

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.

4 participants