Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions code/core/src/components/components/Button/Button.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,17 @@ export const PseudoStates = meta.story({
Hover
</Button>
</Row>
<Row id="active">
<Button ariaLabel={false} variant="solid">
active
</Button>
<Button ariaLabel={false} variant="outline">
active
</Button>
<Button ariaLabel={false} variant="ghost">
active
</Button>
</Row>
<Row id="focus">
<Button ariaLabel={false} variant="solid">
Focus
Expand Down Expand Up @@ -127,6 +138,7 @@ export const PseudoStates = meta.story({
parameters: {
pseudo: {
hover: '#hover button',
active: '#active button',
focus: '#focus button',
focusVisible: '#focus-visible button',
},
Expand Down
6 changes: 3 additions & 3 deletions code/core/src/components/components/Button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -278,9 +278,9 @@ const StyledButton = styled('button', {
})(),
},

'&:focus': {
boxShadow: `${rgba(theme.color.secondary, 1)} 0 0 0 1px inset`,
outline: 'none',
'&:focus-visible': {
outline: `2px solid ${rgba(theme.color.secondary, 1)}`,
outlineOffset: 2,
},

'> svg': {
Expand Down