-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
feat(button): allow tooltips on disabled buttons via disabledFocusable
#14646
feat(button): allow tooltips on disabled buttons via disabledFocusable
#14646
Conversation
✅ Deploy Preview for v11-carbon-react ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for carbon-elements ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Here's my thoughts on the open questions Does the aria spec allow for this?
Can
|
Should it read out that it is disabled? Or is that expected to be added in the description text of why it is disabled? Adding |
After a lot of consideration and review, we're not going to land this for a variety of reasons. I know this isn't the outcome many folks wanted, but our team is committed to evaluating the root issue and providing more robust guidance around disabled elements. This work will be aimed at extending the disabled states pattern already present on the website. This and more is outlined in the issue I opened today: |
Closes #8509
Related internal slack thread
This adds a new
disabledFocusable
prop toButton
. It gives disabled styling to the button while allowing it to remain focusable.This aims to solve a longstanding problem where users have no way to understand why disabled buttons (particularly
IconButton
s) are disabled.I'm opening this as a draft for now to get feedback from the design team, IBMa and the community. I hope we can reach a consensus to merge this, but it's still possible this exploration could fail for a number of reasons.
Changelog
New
disabledFocusable
to buttonTesting / Reviewing
disabledFocusable
.disabledFocusable
Open questions
These are sourced from conversations in Slack, GitHub, and Carbon team discussions.
disabledFocusable
be used on a button that is a link (has anhref
)?aria-disabled
or something likedisabledFocusable
?