summaryrefslogtreecommitdiff
path: root/scss/modules/link.scss
diff options
context:
space:
mode:
authorJoe Carstairs <118172583+jcarstairs-scottlogic@users.noreply.github.com>2023-12-21 21:21:30 +0000
committerJoe Carstairs <65492573+Sycamost@users.noreply.github.com>2024-01-12 08:29:08 +0000
commit5d5e2f8aa5c4030c33bf06f2cb817b9d770cc884 (patch)
tree1ef67a95bec53331eeba34787e6edc03a2fd9bb1 /scss/modules/link.scss
parent9102fe8bcd13c01bf7bae462e013c920cae9f52f (diff)
Improve CSS reset (#51)
* Font size inflation * Removes main adjustment for IE * Documents hr corrections * Documents pre corrections * Documents abbr[title] corrections * Documents b, strong corrections * Squishes pre rule with code,kbd,samp * Documents sub,sub line-height fix * Removes IE fix for img borders * Documents form control resets * Documents details display:block * Documents summary correction * Removes [hidden] fix for IE * Adds border-box sizing rules * Refactors links
Diffstat (limited to 'scss/modules/link.scss')
-rw-r--r--scss/modules/link.scss33
1 files changed, 16 insertions, 17 deletions
diff --git a/scss/modules/link.scss b/scss/modules/link.scss
index dfcabcf..83206d4 100644
--- a/scss/modules/link.scss
+++ b/scss/modules/link.scss
@@ -1,32 +1,31 @@
-.link {
+a, .link {
color: var(--special-text-color);
text-decoration-line: underline;
text-decoration-color: var(--special-text-color);
text-decoration-thickness: var(--relative-eighth-rem);
text-underline-offset: var(--relative-eighth-rem);
border: dotted transparent var(--relative-eighth-rem);
- border-radius: calc(3 * var(--relative-eighth-rem));
transition:
color 100ms,
text-decoration-color 100ms,
text-decoration-thickness 100ms,
border-color 100ms;
-}
-.link:is(:hover, :focus, :focus-visible, :focus-within),
-.group-hover:is(:hover, :focus, :focus-visible, :focus-within) .link {
- text-decoration-color: currentColor;
- text-decoration-thickness: calc(3 * var(--relative-eighth-rem));
- transition:
- color 300ms,
- text-decoration-color 300ms,
- text-decoration-thickness 300ms,
- border-color 300ms;
-}
+ &:is(:hover, :focus, :focus-visible, :focus-within),
+ .group-hover:is(:hover, :focus, :focus-visible, :focus-within) & {
+ text-decoration-color: currentColor;
+ text-decoration-thickness: calc(3 * var(--relative-eighth-rem));
+ transition:
+ color 300ms,
+ text-decoration-color 300ms,
+ text-decoration-thickness 300ms,
+ border-color 300ms;
+ }
-.link:focus, .link:focus-visible {
- box-shadow: none;
- outline: none;
- border-color: var(--special-text-color);
+ &:is(:focus, :focus-visible, :focus-within) {
+ box-shadow: none;
+ outline: none;
+ border-color: var(--special-text-color);
+ }
}