-
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
fix(Tag): ignore click events when disabled #4792
fix(Tag): ignore click events when disabled #4792
Conversation
Deploy preview for the-carbon-components ready! Built with commit 60b4537 https://deploy-preview-4792--the-carbon-components.netlify.com |
Deploy preview for carbon-elements ready! Built with commit 60b4537 |
Deploy preview for carbon-components-react ready! Built with commit 60b4537 https://deploy-preview-4792--carbon-components-react.netlify.com |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍 - Thanks @emyarod!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems great to me, just a quick comment
3d29bf3
to
38c846d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
disabled tag looks good to me and is not clickable 👍
We've marked this issue as stale because there hasn't been any activity for a couple of weeks. If there's no further activity on this issue in the next three days then we'll close it. You can keep the conversation going with just a short comment. Thanks for your contributions. |
6bf731b
to
d633147
Compare
5e88749
to
b24f6c8
Compare
@joshblack is this good to go now? |
9b25878
to
371ee11
Compare
* fix(Tag): ignore click events when disabled * test(Tag): remove warning * fix(tag): move aria-label to button * fix: add ellipses when width is constrained * docs: fix example markup * fix(tag): reintroduce padding due to recent markup change * fix(Tag): remove unneeded click handler logic * fix(tag): use disabled token Co-authored-by: Josh Black <josh@josh.black>
* fix(Tag): ignore click events when disabled * test(Tag): remove warning * fix(tag): move aria-label to button * fix: add ellipses when width is constrained * docs: fix example markup * fix(tag): reintroduce padding due to recent markup change * fix(Tag): remove unneeded click handler logic * fix(tag): use disabled token Co-authored-by: Josh Black <josh@josh.black>
Closes #4791
This PR wraps the close icon in a buttonto utilize native button features (rather than spoofing a button with the SVG element) and ignores the onClick handler when the filter tag is disabledChangelog
New
Changed
wrap SVG icon in buttondue to changes introduced in fix(Tag): adds various fixes for screen reader accessibility; adds AAT #4863 the entire tag is now abutton
and the styles are rescoped to the svg icon within thebutton.bx--tag
elementTesting / Reviewing
Ensure click handlers are no longer fired when the tag filter is disabled and the component matches the visual spec (particularly the disabled state)