Standardize focus indicator for interactive components #338
Replies: 4 comments
-
Does the |
Beta Was this translation helpful? Give feedback.
-
Can outlines have rounded corners on more browsers now? I think we're actually using it for the jump link component's focus state, and that outline is slightly rounded. |
Beta Was this translation helpful? Give feedback.
-
Check out the last demo on https://developer.mozilla.org/en-US/docs/Web/CSS/outline the outline will follow the border radius of the element on FF and Chrome (desktop mac), but not Safari |
Beta Was this translation helpful? Give feedback.
-
Cool, I don't think it's a big deal that border radius isn't supported for outlines on Safari. I think it's more important that we start getting focus states to look more similar. @coreyvickery or @ronniemcbride, chime in if you feel otherwise. |
Beta Was this translation helpful? Give feedback.
-
Description
Some components, like CTAs, use different focus indicators than others, like jump links, for their focus states. These should be standardized as much as possible using the focus indicator from the design system kit.
Suggested solution
The focus indicator is 2px thick. For an outer focus indicator, there should be a 1px margin between the focused element and the focus indicator.
color: #06c
color: #73BCF7
color: #fff
Example: This tertiary button uses the outer focus indicator.

Example API
Additional context
Component focus states can be updated as they're found.
Beta Was this translation helpful? Give feedback.
All reactions