Problem/Motivation
The focus color in the navigation module is using a different shade of green than the focus color used in Claro and is not meeting the required color contrast of at least 3:1 for SC1.4.11:
Navigation: (rgb(0,204,109) : rgb(255,255,255) -> 2.1:1)

Claro Header: (rgb(38,167,105) : rgb(243,344,249) -> 2.8:1)

Claro main: (rgb(38,167,105) : rgb(255,255,255) -> 3.1:1)

Steps to reproduce
- go to for example
admin/modulesand check the color contrast for the top level menu itempeoplein the sidebar and thefilterfield
Proposed resolution
There are two options how to solve this:
- Use
--color-lightninggreen(#26a769) on the navigation sidebar as well. That way the color would be consistent across the navigation and the rest of claro - the problem that way the focus outline would still have a too low color contrast against the header background. - Use
--drupal-admin-color-green-400(#009952) instead of--drupal-admin-color-green-300for the navigation sidebar and the focus for the rest of claro.
It looks like option 2 would be the preferable choice. Found the different shades of green in variables.css in the navigation module. going with --drupal-admin-color-green-400 for the navigation and claro in general, aside the overall consistency, it would also have another positive side effect, the focus would have enough color contrast against the background color of the header in claro as well:
#009952 against #fff (general background) 3.7:1
#009952 against #F3F4F9 (header) 3.4:1
Remaining tasks
Review
User interface changes
Before

After

Introduced terminology
NA
API changes
NA
Data model changes
NA
Release notes snippet
NA
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | Screenshot 2025-02-26 at 12.02.07 PM.png | 139.33 KB | rinku jacob 13 |
| #6 | before.png | 156.72 KB | rinku jacob 13 |
| #2 | claro_main.jpg | 172.94 KB | rkoller |
| #2 | claro_header.jpg | 175.31 KB | rkoller |
| #2 | nav_sidebar.jpg | 134.17 KB | rkoller |
Issue fork drupal-3498326
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3498326-focus-outline-has
compare
- 3498326-focus-outline
changes, plain diff MR !11299
Comments
Comment #2
rkollerUpdated the title and issue summary and added screenshots
Comment #3
rkollerComment #6
rinku jacob 13 commentedI've created a Merge Request based on Proposed Resolution 2. Could you please review the Merge Request.


before the CSS style changes are applied
After the CSS changes:
Comment #7
rinku jacob 13 commentedComment #8
smustgrave commentedSeems pretty straightforward and the multiple screenshots
Did update the summary slightly to include the before/after
Comment #9
ckrinaUsing
--drupal-admin-color-green-400(#009952) seems the more reasonable approach in terms of design and it'll keep the same variables so Gin&other can keep any override.Comment #13
nod_Committed and pushed 667827baf8f to 11.x and b6569266a24 to 11.1.x. Thanks!
Comment #14
rinku jacob 13 commentedComment #15
rinku jacob 13 commentedComment #16
rinku jacob 13 commentedComment #17
rinku jacob 13 commented