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

Keyboard accessibility #385

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

judeGibbons
Copy link

This branch was started from release 1.7.13.
Adds keyboard accessibility to the gallery navigation.

Links are more semantically-correct than spans.
Anchor tags have native tabindex.
Edit css to work with anchor tags rather than spans.
Add 'keypress' event to navigation for keyboard accessibility.
Use 'on' to attach event handlers.
Make navigation elements visible on hover, focus and active states.
Insert gallery navigation at start of featherlight-content rather than end.
User will then tab to 'next' element first, then 'previous', then 'close'.
@marcandre
Copy link
Collaborator

Thanks for the PR and wanting to improve Featherlight.

I'm afraid I can't merge this as is though.

First, it's not clear to me why you'd want this; aren't left and right arrow keys more intuitive and convenient?

Second, changing span to a is a breaking change.

Finally, it is not acceptable to rely on the title attribute not being changed by the user.

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 this pull request may close these issues.

None yet

2 participants