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

Don't allow previously hidden items to be checkable; add ActionMenu js API #2393

Merged
merged 6 commits into from
Nov 22, 2023

Conversation

camertron
Copy link
Contributor

@camertron camertron commented Nov 21, 2023

What are you trying to accomplish?

This PR does three things for the ActionMenu component:

  1. Fixes the issue described in https://github.com/github/primer/issues/2873
  2. Adds a JavaScript API to ActionMenu to make it easier to hide, disable, and check items.
  3. Fires a custom event called itemActivated whenever an item is activated by the mouse or keyboard.

Integration

No changes necessary in production.

List the issues that this change affects.

Fixes https://github.com/github/primer/issues/2873

Risk Assessment

  • Low risk the change is small, highly observable, and easily rolled back.
  • Medium risk changes that are isolated, reduced in scope or could impact few users. The change will not impact library availability.
  • High risk changes are those that could impact customers and SLOs, low or no test coverage, low observability, or slow to rollback.

Accessibility

  • No new axe scan violation - This change does not introduce any new axe scan violations.

Merge checklist

  • Added/updated tests
  • Added/updated documentation
  • Added/updated previews (Lookbook)
  • Tested in Chrome
  • Tested in Firefox
  • Tested in Safari
  • Tested in Edge

Copy link

changeset-bot bot commented Nov 21, 2023

🦋 Changeset detected

Latest commit: 47d0690

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/view-components Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@camertron camertron changed the title Don't allow previously hidden items to be checkable; add ActionMenu j… Don't allow previously hidden items to be checkable; add ActionMenu js API Nov 21, 2023
@github-actions github-actions bot added javascript Pull requests that update Javascript code ruby Pull requests that update Ruby code labels Nov 21, 2023
@camertron camertron marked this pull request as ready for review November 22, 2023 23:04
@camertron camertron requested review from a team, keithamus and jonrohan and removed request for keithamus November 22, 2023 23:04
@camertron camertron merged commit 745eae0 into main Nov 22, 2023
31 checks passed
@camertron camertron deleted the action_menu_js_api branch November 22, 2023 23:15
@primer primer bot mentioned this pull request Nov 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
javascript Pull requests that update Javascript code minor release ruby Pull requests that update Ruby code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants