Skip to content

Commit

Permalink
Update link design (#8375)
Browse files Browse the repository at this point in the history
Co-authored-by: Alexander Brandes <mc.cache@web.de>
  • Loading branch information
janfaracik and NotMyFault committed Aug 17, 2023
1 parent 0b37bcb commit 97ac833
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 29 deletions.
10 changes: 10 additions & 0 deletions war/src/main/scss/abstracts/mixins.scss
@@ -1,6 +1,8 @@
@mixin link {
text-decoration: var(--link-text-decoration);
font-weight: var(--link-font-weight);
text-underline-offset: 2px;
text-decoration-thickness: 2px;

&:link {
color: var(--link-color);
Expand All @@ -20,6 +22,14 @@
color: var(--link-color--active);
text-decoration: var(--link-text-decoration--active);
}

@media (prefers-contrast: more) {
text-decoration: underline;

&:hover {
text-decoration-thickness: 3px;
}
}
}

@mixin link-dark {
Expand Down
2 changes: 1 addition & 1 deletion war/src/main/scss/abstracts/theme.scss
Expand Up @@ -183,7 +183,7 @@ $semantics: (
--link-text-decoration: none;
--link-text-decoration--hover: underline;
--link-text-decoration--active: underline;
--link-font-weight: 600;
--link-font-weight: 500;

// Tooltips
--tooltip-backdrop-filter: contrast(0.6) brightness(2.4) saturate(2)
Expand Down
28 changes: 0 additions & 28 deletions war/src/main/scss/base/style.scss
@@ -1,5 +1,3 @@
@use "../abstracts/mixins";

/*
* The MIT License
*
Expand Down Expand Up @@ -116,27 +114,6 @@ td.no-wrap {
color: #ccc;
} */

a {
@include mixins.link;
}

.jenkins-link--with-icon {
display: inline-flex;
align-items: center;
justify-content: flex-start;

svg {
width: 16px;
height: 16px;
flex: 0 0 auto;
color: var(--text-color) !important;
}
}

p a {
text-decoration: underline;
}

a.lowkey:link {
text-decoration: none;
color: inherit;
Expand Down Expand Up @@ -239,7 +216,6 @@ pre {
line-height: 1.66;

a {
font-weight: inherit;
word-wrap: break-word;
}
}
Expand Down Expand Up @@ -560,10 +536,6 @@ pre.console {
}
}

.help a {
text-decoration: underline;
}

.help .from-plugin {
text-align: right;
color: #666;
Expand Down
18 changes: 18 additions & 0 deletions war/src/main/scss/base/typography.scss
@@ -1,3 +1,5 @@
@use "../abstracts/mixins";

body,
p {
font-family: var(--font-family-sans);
Expand Down Expand Up @@ -96,3 +98,19 @@ h6,
opacity: 0.7;
}
}

a {
@include mixins.link;
}

.jenkins-link--with-icon {
display: inline-flex;
align-items: center;
justify-content: flex-start;

svg {
width: 16px;
height: 16px;
color: var(--text-color) !important;
}
}

0 comments on commit 97ac833

Please sign in to comment.