-
Notifications
You must be signed in to change notification settings - Fork 395
fix(material/api-theme): fix nav items hover/focus contrast #1004
fix(material/api-theme): fix nav items hover/focus contrast #1004
Conversation
Fix hover and focus indicators on header nav items with sufficient contrast Fixes angular#759
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.
Thank you for the screenshots, but what is hovered in those? It looks like it's just showing the selected?
What does it look like when an item has focus
?
Ideally, hover and focus will be a slightly different shade than selected.
@kian23kpt you verified that the contrast in the hovered text is sufficient? |
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.
LGTM
|
||
& a:hover, & a:focus { | ||
background: rgba(0, 0, 0, 0.4); | ||
color: mat.get-color-from-palette($accent, 200); |
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.
I just want to make sure that 200
here isn't too dark to meet the contrast guidelines.
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.
What was the purpose of using the accent color here instead of just inheriting the color? Was the shade of the background not enough to differentiate selected versus hovered/focus states? or was there a contrast issue?
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.
What was the purpose of using the accent color here instead of just inheriting the color? Was the shade of the background not enough to differentiate selected versus hovered/focus states? or was there a contrast issue?
Used only to differentiate, similar to the sidebar. but by removing it, there is no problem of contrast.
Yes, checked! |
Updates to the latest RC versions for v13. This also reverts a change from angular#1004 which made the hover color for the top nav buttons use the accent color, which is **wildly** off-spec.
Updates to the latest RC versions for v13. This also reverts a change from #1004 which made the hover color for the top nav buttons use the accent color, which is **wildly** off-spec.
Fix hover and focus indicators on header nav items with sufficient contrast
Fixes #759