0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-11-29 11:24:18 +01:00

Merge pull request #30389 from twbs/underline-links

v5: Underline links
This commit is contained in:
Mark Otto 2020-03-20 08:58:54 -07:00 committed by GitHub
commit 0388ee03d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 13 additions and 9 deletions

View File

@ -21,7 +21,7 @@
&:hover {
color: $body-color;
text-decoration: none;
text-decoration: if($link-hover-decoration == underline, none, null);
}
&:focus,

View File

@ -150,7 +150,7 @@
&:hover,
&:focus {
color: $dropdown-link-hover-color;
text-decoration: none;
text-decoration: if($link-hover-decoration == underline, none, null);
@include gradient-bg($dropdown-link-hover-bg);
}

View File

@ -18,7 +18,7 @@
&:hover,
&:focus {
text-decoration: none;
text-decoration: if($link-hover-decoration == underline, none, null);
}
// Disabled state lightens text

View File

@ -14,7 +14,7 @@
&:hover {
z-index: 2;
color: $pagination-hover-color;
text-decoration: none;
text-decoration: if($link-hover-decoration == underline, none, null);
background-color: $pagination-hover-bg;
border-color: $pagination-hover-border-color;
}

View File

@ -249,9 +249,9 @@ $body-text-align: null !default;
// Style anchor elements.
$link-color: $primary !default;
$link-decoration: none !default;
$link-decoration: underline !default;
$link-hover-color: darken($link-color, 15%) !default;
$link-hover-decoration: underline !default;
$link-hover-decoration: null !default;
// Darken percentage for links with `.text-*` class (e.g. `.text-success`)
$emphasized-link-hover-darken-percentage: 15% !default;

View File

@ -24,6 +24,7 @@
padding: .25rem .625rem .25rem .5rem;
font-weight: 600;
color: rgba($black, .65);
text-decoration: none;
@include border-radius(.25rem);
> * { pointer-events: none; }
@ -31,7 +32,6 @@
&:hover,
&:focus {
color: rgba($black, .85);
text-decoration: none;
background-color: rgba($bd-purple-bright, .1);
}
}
@ -64,12 +64,12 @@
padding: .25rem .5rem;
@include font-size(.875rem);
color: rgba($black, .65);
text-decoration: none;
@include border-radius(.25rem);
&:hover,
&:focus {
color: rgba($black, .85);
text-decoration: none;
background-color: rgba($bd-purple-bright, .1);
}
}

View File

@ -1,4 +1,4 @@
// stylelint-disable selector-max-type, selector-max-combinators, selector-max-compound-selectors
// stylelint-disable selector-max-type, selector-max-compound-selectors
.bd-toc nav {
padding-top: .125em;
@ -14,6 +14,10 @@
list-style-type: disc;
}
a:not(:hover) {
text-decoration: none;
}
a code {
font: inherit;
}