From c1c80802e21448ba2ae6089093d9a00cd11d14ab Mon Sep 17 00:00:00 2001 From: Tom Byers Date: Fri, 3 Sep 2021 10:55:06 +0100 Subject: [PATCH] Give outline reset same precedence as for focus The CSS that cancelled outline on focus events not fired by the :focus-visible heuristic is being overridden by the higher precedence of the outline style for :focus, due to its use of !important. This adds !important to the cancelling CSS. This brings that block up to the same level as that for :focus, meaning the :focus-visible styles will win because they sit lower in the stylesheet. --- app/assets/stylesheets/map.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/stylesheets/map.scss b/app/assets/stylesheets/map.scss index f0e8ad502..b03dabeb8 100644 --- a/app/assets/stylesheets/map.scss +++ b/app/assets/stylesheets/map.scss @@ -32,7 +32,7 @@ $zoom-button-hover-colour: govuk-shade($zoom-button-colour, 10%); // from other sources (like clicks on child elements). &:focus:not(:focus-visible) { box-shadow: none; - outline: none; + outline: none !important; // sass-lint:disable-line no-important } }