Skip to content
This repository has been archived by the owner on Jun 29, 2023. It is now read-only.

fix(action): Prevent disabled buttons from being clicked or tabbed into #1004

Merged
merged 7 commits into from
Jun 1, 2020

Conversation

driskull
Copy link
Member

Related Issue: None

Summary

fix(action): Prevent disabled buttons from being clicked or tabbed into

@driskull driskull added this to the Marceline milestone May 29, 2020
@driskull driskull requested a review from a team as a code owner May 29, 2020 22:15
@driskull driskull self-assigned this May 29, 2020
@asangma
Copy link
Contributor

asangma commented Jun 1, 2020

Shouldn't browsers default to this behavior with buttons elements that have a disabled attribute?

@driskull
Copy link
Member Author

driskull commented Jun 1, 2020

Shouldn't browsers default to this behavior with buttons elements that have a disabled attribute?

Yes, but when users set an onClick on the element it isn't set on the button. So this is needed.

@asangma
Copy link
Contributor

asangma commented Jun 1, 2020

Ah...got it.

Copy link
Member

@jcfranco jcfranco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good!

src/components/calcite-action/calcite-action.tsx Outdated Show resolved Hide resolved
@driskull driskull requested a review from jcfranco June 1, 2020 21:15
Copy link
Member

@jcfranco jcfranco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💥 💥 💥 💥

@driskull driskull merged commit c03019d into master Jun 1, 2020
@driskull driskull deleted the dris0000/action-disabled branch June 1, 2020 21:37
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants