-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(buttonbadge): change form button to button role
This changes the the element from a button to a span and is adding the `role="button"` attribute to the element.
- Loading branch information
Poltergeist
committed
Apr 18, 2018
1 parent
f8154d4
commit e846642
Showing
3 changed files
with
24 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 21 additions & 14 deletions
35
packages/badge/tests/__snapshots__/badgeButton.test.tsx.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,73 +1,80 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`BadgeButton accept jsx as children 1`] = ` | ||
<button | ||
<span | ||
className="css-y5qucr" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
<span> | ||
string | ||
</span> | ||
</button> | ||
</span> | ||
`; | ||
|
||
exports[`BadgeButton danger 1`] = ` | ||
<button | ||
<span | ||
className="css-aqlru0" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
danger | ||
</button> | ||
</span> | ||
`; | ||
|
||
exports[`BadgeButton default 1`] = ` | ||
<button | ||
<span | ||
className="css-y5qucr" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
default | ||
</button> | ||
</span> | ||
`; | ||
|
||
exports[`BadgeButton outline 1`] = ` | ||
<button | ||
<span | ||
className="css-j343ve" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
outline | ||
</button> | ||
</span> | ||
`; | ||
|
||
exports[`BadgeButton primary 1`] = ` | ||
<button | ||
<span | ||
className="css-q2731u" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
primary | ||
</button> | ||
</span> | ||
`; | ||
|
||
exports[`BadgeButton success 1`] = ` | ||
<button | ||
<span | ||
className="css-10v0ttp" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
success | ||
</button> | ||
</span> | ||
`; | ||
|
||
exports[`BadgeButton warning 1`] = ` | ||
<button | ||
<span | ||
className="css-1qzzy6w" | ||
onClick={[Function]} | ||
role="button" | ||
tabIndex={-1} | ||
> | ||
warning | ||
</button> | ||
</span> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters