Skip to content

Commit

Permalink
💄Menu: focus-ring from :focus to :focus-visible (#3396)
Browse files Browse the repository at this point in the history
* 💄Menu: focus-ring from :focus to :focus-visible

* remove no longer needed z-index
  • Loading branch information
oddvernes authored Apr 23, 2024
1 parent a441137 commit 6662c26
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions packages/eds-core-react/src/components/Menu/MenuItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,6 @@ const Item = styled.button.attrs<StyleAttrsProps>(({ $isFocused }) => ({
svg {
fill: ${icon.states.disabled.typography.color};
}
&:focus {
outline: none;
}
@media (hover: hover) and (pointer: fine) {
&:hover {
cursor: not-allowed;
Expand All @@ -73,12 +70,11 @@ const Item = styled.button.attrs<StyleAttrsProps>(({ $isFocused }) => ({
: css`
@media (hover: hover) and (pointer: fine) {
&:hover {
z-index: 1;
cursor: pointer;
background: ${hover.background};
}
}
&:focus {
&:focus-visible {
z-index: 3;
${outlineTemplate(focus.outline)}
}
Expand Down

0 comments on commit 6662c26

Please sign in to comment.