Skip to content

IconButton: Add keyshortcuts prop to allow labelling and describing support for keyboard shortcut (through tooltips) - #4707

Merged
broccolinisoup merged 11 commits into
mainfrom
icon-button-keyshortcuts
Jul 11, 2024
Merged

IconButton: Add keyshortcuts prop to allow labelling and describing support for keyboard shortcut (through tooltips)#4707
broccolinisoup merged 11 commits into
mainfrom
icon-button-keyshortcuts

Conversation

@broccolinisoup

@broccolinisoupbroccolinisoup commented Jul 1, 2024

Copy link
Copy Markdown
Member

This PR proposes an addition to the icon button API as it is accepted on https://github.com/github/primer/pull/2650 (internal link only). The keyshortcuts prop is added to the IconButton component to allow labelling and describing support for keyboard shortcuts through tooltips. This change is beneficial as it provides a more accessible user experience.

Changelog

New

  • Add keyshortcuts prop to icon buttons

Changed

  • Rendered HTML when keyshortcuts prop is present (Only when tooltips are enabled which will be the default behaviour very soon)

Rollout strategy

  • Patch release
  • Minor release
  • Major release; if selected, include a written rollout or migration plan
  • None; if selected, include a brief description as to why

Testing & Reviewing

Merge checklist

@changeset-bot

changeset-botBot commented Jul 1, 2024

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7974ffb

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

This PR includes changesets to release 1 package
NameType
@primer/reactMinor

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-actionsBot commented Jul 1, 2024

Copy link
Copy Markdown
Contributor

size-limit report 📦

PathSize
packages/react/dist/browser.esm.js91.21 KB (+0.07% 🔺)
packages/react/dist/browser.umd.js91.46 KB (-0.03% 🔽)

@broccolinisoupbroccolinisoup changed the title Add keyboard shortcut labelling and describing support for icon buttons (through tooltip)IconButton: Add keyshortcuts prop to allow labelling and describing support for keyboard shortcut (through tooltips)Jul 1, 2024
@broccolinisoup
broccolinisoup marked this pull request as ready for review July 1, 2024 03:01
@broccolinisoup
broccolinisoup requested a review from a team as a code ownerJuly 1, 2024 03:01
@broccolinisoupbroccolinisoup added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Jul 1, 2024
@github-actions
github-actionsBottemporarily deployed to storybook-preview-4707 July 1, 2024 03:02 Inactive
@primer
primerBot requested a review from a team as a code ownerJuly 1, 2024 03:08
@github-actionsgithub-actionsBot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Jul 1, 2024
@primer
primerBottemporarily deployed to github-pages July 1, 2024 03:12 Inactive
@github-actions
github-actionsBottemporarily deployed to storybook-preview-4707 July 1, 2024 03:12 Inactive
@broccolinisoupbroccolinisoup added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Jul 1, 2024
@github-actionsgithub-actionsBot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Jul 1, 2024
@primer
primerBottemporarily deployed to github-pages July 1, 2024 05:01 Inactive
@github-actions
github-actionsBottemporarily deployed to storybook-preview-4707 July 1, 2024 05:01 Inactive
@github-actions
github-actionsBottemporarily deployed to storybook-preview-4707 July 3, 2024 22:44 Inactive
@broccolinisoupbroccolinisoup added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Jul 3, 2024
@github-actionsgithub-actionsBot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Jul 3, 2024
@primer
primerBottemporarily deployed to github-pages July 3, 2024 23:29 Inactive
@github-actions
github-actionsBottemporarily deployed to storybook-preview-4707 July 3, 2024 23:29 Inactive
@primer-integration

Copy link
Copy Markdown

👋 Hi from github/github! Your integration PR is ready: https://github.com/github/github/pull/332131

Sign up for freeto 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.

3 participants

@broccolinisoup@joshblack@langermank