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

Prevent scrolling when activating ActionMenu form items via space #2326

Merged
merged 2 commits into from
Oct 23, 2023

Conversation

camertron
Copy link
Contributor

@camertron camertron commented Oct 23, 2023

What are you trying to accomplish?

This PR prevents scrolling when activating a single-select ActionMenu item that submits a form. I tried pretty hard to write a test for this but the behavior does not appear in Lookbook for some reason. I verified this will fix the issue in dotcom though, and I left a number of comments.

Integration

No changes necessary in production.

List the issues that this change affects.

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

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.

What approach did you choose and why?

See inline comments.

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

@changeset-bot
Copy link

changeset-bot bot commented Oct 23, 2023

🦋 Changeset detected

Latest commit: 3b824e0

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 Patch

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

@github-actions github-actions bot added the javascript Pull requests that update Javascript code label Oct 23, 2023
@camertron camertron marked this pull request as ready for review October 23, 2023 22:34
@camertron camertron requested review from a team and jonrohan October 23, 2023 22:34
@camertron camertron merged commit 4e05b7e into main Oct 23, 2023
30 checks passed
@camertron camertron deleted the action_menu_stop_scrolling_on_space branch October 23, 2023 22:34
@camertron camertron temporarily deployed to preview October 23, 2023 22:34 — with GitHub Actions Inactive
@primer primer bot mentioned this pull request Oct 23, 2023
@camertron camertron changed the title Prevent scrolling when activating ActionMenu items via space Prevent scrolling when activating ActionMenu form items via space Oct 24, 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 patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant