-
Notifications
You must be signed in to change notification settings - Fork 50
CodeBlock
, CodeEditor
, SideNav
- Focus ring color contrast fix
#2819
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@dchyun I would add the specific designer you worked with on this as a reviewer so they can comment on/approve the visual changes you implemented. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks perfect, thank you for writing everything up so clearly!
@dchyun If all the visual diffs in Percy are as expected and the designer has approved the implemented visual changes then you can approve the Percy diffs to clear the failing check. |
📌 Summary
If merged, this PR would update the colors of focus rings for interactive elements in the following components, and fix color contrast issues with the existing colors.
CodeBlock
(Preview)CodeEditor
(Preview)SideNav
(Preview)🛠️ Detailed description
Currently the
CodeBlock
,CodeEditor
, andSideNav
components leverage our existing focus ring color tokens that are used on light colored backgrounds, but these components all have interactive elements on dark colored backgrounds. This was resulting in a color contrast violation as the focus ring colors had contrast less than 3:1.New dark background focus ring tokens were created in HDS-4640 to fix these issues.
Note: These new token values are being implemented at the component level, not in the tokens package. The organization of global tokens for themes will be implemented in the future, and when that occurs these tokens will be moved from the component level to the global level.
📸 Screenshots
CodeBlock
Before


After
CodeEditor
Before




After
SideNav
Before






After
🔗 External links
Jira ticket: HDS-4767
Figma file: Link
👀 Component checklist
💬 Please consider using conventional comments when reviewing this PR.