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

Restrict menu heading slot tags #648

Merged
merged 2 commits into from
Jun 16, 2021
Merged

Restrict menu heading slot tags #648

merged 2 commits into from
Jun 16, 2021

Conversation

khiga8
Copy link
Contributor

@khiga8 khiga8 commented Jun 16, 2021

Closes #644

What
This PR updates the heading slot of the MenuComponent to require the tag: argument to be passed in. The tag must be one of the heading tags.

Why
This menu heading looks like a heading and functions as a heading so we should be using a heading tag rather than a :div. This will allow assistive technology users to navigate to the heading more quickly.

Notes
As a reference, a similar vertical menu menu heading on this w3 headings page is rendered with a heading tag.

Part of #491

@khiga8 khiga8 requested a review from a team June 16, 2021 21:03
@vercel
Copy link

vercel bot commented Jun 16, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/primer/view-components/AEL7k8DfTuCnoEhDv3dmMXmxemhJ
✅ Preview: https://view-components-git-kh-menutagrestrictions-primer.vercel.app

@vercel vercel bot temporarily deployed to Preview June 16, 2021 21:03 Inactive
@khiga8 khiga8 force-pushed the kh-menu_tag_restrictions branch from 5087cde to 933223c Compare June 16, 2021 21:12
@vercel vercel bot temporarily deployed to Preview June 16, 2021 21:12 Inactive
@vercel vercel bot temporarily deployed to Preview June 16, 2021 21:14 Inactive
@khiga8 khiga8 force-pushed the kh-menu_tag_restrictions branch from 2a14f36 to 7a03f48 Compare June 16, 2021 21:19
@vercel vercel bot temporarily deployed to Preview June 16, 2021 21:19 Inactive
@vercel vercel bot temporarily deployed to Preview June 16, 2021 21:23 Inactive
@khiga8 khiga8 enabled auto-merge (squash) June 16, 2021 21:27
@khiga8 khiga8 merged commit ed7ef0f into main Jun 16, 2021
@khiga8 khiga8 deleted the kh-menu_tag_restrictions branch June 16, 2021 21:28
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.

Require heading level tag for Menu component
2 participants