From ee0f7d69b424d92b6164b04fa18113670a3f4f2c Mon Sep 17 00:00:00 2001 From: Aaron Robertshaw <60436221+aaronrobertshaw@users.noreply.github.com> Date: Tue, 2 Nov 2021 11:56:05 +1000 Subject: [PATCH] Apply text decoration to nav item anchor tags instead of item --- .../block-library/src/navigation/style.scss | 23 ++++++++----------- 1 file changed, 10 insertions(+), 13 deletions(-) diff --git a/packages/block-library/src/navigation/style.scss b/packages/block-library/src/navigation/style.scss index 309ff28919053..bc266c5aea5ea 100644 --- a/packages/block-library/src/navigation/style.scss +++ b/packages/block-library/src/navigation/style.scss @@ -60,24 +60,21 @@ // The following rules provide class based application of user selected text // decoration via block supports. - &.has-text-decoration-underline .wp-block-navigation-item { + &.has-text-decoration-underline .wp-block-navigation-item a { text-decoration: underline; - } - &.has-text-decoration-line-through .wp-block-navigation-item { - text-decoration: line-through; + &:focus, + &:active { + text-decoration: underline; + } } - &[class*="has-text-decoration"] { - .wp-block-navigation-item { - a { - text-decoration: inherit; + &.has-text-decoration-line-through .wp-block-navigation-item a { + text-decoration: line-through; - &:focus, - &:active { - text-decoration: inherit; - } - } + &:focus, + &:active { + text-decoration: line-through; } }