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

Ensure specified trigger id is used for menu aria-labelledby #31339

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

Conversation

jacksonv1lle
Copy link
Contributor

Previous Behavior

Currently the aria-labelledby relationship in Menu is automatic. The useId hook is used to generate the id. If a users uses their own id prop they must also set their own aria relationship with that id manually.

New Behavior

If the user manually sets id prop on the trigger then the aria-labelledby relationship that depends on it will be reflected.

Related Issue(s)

Copy link

codesandbox-ci bot commented May 11, 2024

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@jacksonv1lle jacksonv1lle marked this pull request as ready for review May 12, 2024 08:08
@jacksonv1lle jacksonv1lle requested a review from a team as a code owner May 12, 2024 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Menu: Update aria relationships if user manually sets id prop
1 participant