Skip to content

Commit

Permalink
Navigation: Try fixing link color in some TT2 contexts. (#44578)
Browse files Browse the repository at this point in the history
* Navigation: Try fixing link color in some TT2 contexts.

* Add comment.

* Update comment.
  • Loading branch information
jasmussen authored Oct 3, 2022
1 parent 79c7180 commit af5802a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/block-library/src/navigation/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,14 @@ $navigation-icon-size: 24px;
display: block;
}

// This rule needs extra specificity so that it inherits the correct color from its parent.
// Otherwise, a link color set by a parent group can override the value.
// This also fixes an issue where a navigation with an explicitly set color is overridden
// by link colors defined in Global Styles.
.wp-block-navigation-item__content.wp-block-navigation-item__content {
color: inherit;
}

// The following rules provide class based application of user selected text
// decoration via block supports.
&.has-text-decoration-underline .wp-block-navigation-item__content {
Expand Down

0 comments on commit af5802a

Please sign in to comment.