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

Add skip navigation button #5804

Merged

Conversation

andrico1234
Copy link
Contributor

Notes

I messed up the rebase, and I'm just opening up a new PR with the same changes.

Description

I've added a button inside of Layout.tsx that only displays when the first action a user performs on a RA site is pressing the tab button.

This moves the focus into the main content of the website, avoiding having to tab through the top and side menus.

While the functionality is complete, I'm going to write Cypress tests for this functionality.

Notes:

Because navigating to anchors via the # didn't seem to work nicely with HashRouter, I had to install an node module that exports a custom link. Here's a link to the discussion

Fortunately the module has no dependencies, and it works out of the box.

I implementing this component similarly to how it's written inside of the Material-UI repo. You can view their implementation here

skip-navigation-smol.mov

@djhi djhi added the WIP Work In Progress label Jan 21, 2021
@andrico1234
Copy link
Contributor Author

This is no longer a WIP, I believe the code is exactly how the previous MR was before I messed up the. rebase

@djhi djhi added RFR Ready For Review and removed WIP Work In Progress labels Jan 22, 2021
Copy link
Contributor

@djhi djhi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@fzaninotto fzaninotto merged commit 2d73dd5 into marmelab:next Jan 27, 2021
@fzaninotto
Copy link
Member

Thanks a lot, this is a great feature!

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

Successfully merging this pull request may close these issues.

None yet

3 participants