diff --git a/content/components/link/index.md b/content/components/link/index.md index e1b4446..d3496dd 100644 --- a/content/components/link/index.md +++ b/content/components/link/index.md @@ -24,7 +24,7 @@ The example below a link with default behavior. You can use the `.link-*` classes to colorize links. Unlike the `.text-*` classes, these classes have a `:hover` and `:focus` state. -{{< example class="d-flex flex-wrap gap-3">}} +{{< example class="d-flex flex-column gap-2">}} Primary link Secondary link Success link @@ -33,26 +33,107 @@ You can use the `.link-*` classes to colorize links. Unlike the `.text-*` classe Info link Light link Dark link +Emphasis link {{ example >}} -Or take the [text color]({{< docsref "text-color" >}}) utilities `text-{color}` to change the link color. +### Reset link color + +Reset a link’s color with `.text-reset`, so that it inherits the color from its parent. + +{{< example >}} +
+ Muted text with a reset link. +
+{{ example >}} + +## Link opacity + +The below table are available CSS utilities for link opacity. + +{{< bs-table "table api-class-table" >}} +| CSS | Desc | +| --- | --- | +| `.link-opacity-10` | --bs-link-opacity: .1 | +| `.link-opacity-25` | --bs-link-opacity: .25 | +| `.link-opacity-50` | --bs-link-opacity: .5 | +| `.link-opacity-75` | --bs-link-opacity: .75 | +| `.link-opacity-100` | --bs-link-opacity: 100 | +{{< /bs-table >}} {{< example class="d-flex flex-wrap gap-3" >}} -link 1 -link 2 -link 4 -link 5 +Link 1 +Link 2 +Link 3 {{ example >}} +You can even change the opacity level on `hover` by `.link-opacity-*-hover`. -## Reset link color +{{< example class="d-flex flex-wrap gap-3" >}} +Link 1 +Link 2 +Link 3 +{{ example >}} -Reset a link’s color with `.text-reset`, so that it inherits the color from its parent. +## Link underlines + +Add a `.link-underline` to the link element to display underline. {{< example >}} -- Muted text with a reset link. -
+Underline link +{{ example >}} + +### Underline color + +Change the underline’s color independent of the link text color by `.link-underline-{color}`. + +{{< example class="d-flex flex-column gap-2" >}} +Primary underline +Secondary underline +Success underline +Danger underline +Warning underline +Info underline +Light underline +Dark underline +{{ example >}} + +### Underline offset + +Change the underline’s distance from your text. Offset is set in `em` units to automatically scale with the element’s current `font-size`. + +{{< example class="d-flex flex-column gap-2" >}} +Default link +Offset 1 link +Offset 2 link +Offset 3 link +{{ example >}} + +### Underline opacity + + +{{< bs-table "table api-class-table" >}} +| CSS | Desc | +| --- | --- | +| `.link-underline-opacity-10` | --bs-link-underline-opacity: .1 | +| `.link-underline-opacity-25` | --bs-link-underline-opacity: .25 | +| `.link-underline-opacity-50` | --bs-link-underline-opacity: .5 | +| `.link-underline-opacity-75` | --bs-link-underline-opacity: .75 | +| `.link-underline-opacity-100` | --bs-link-underline-opacity: 100 | +{{< /bs-table >}} + +{{< example class="d-flex flex-column gap-3" >}} +Primary link +Secondary link +{{ example >}} + +### Hover variants + +ust like the `.link-opacity-*-hover` utilities, `.link-offset` and `.link-underline-opacity` utilities include `:hover` variants by default. Mix and match to create unique link styles. + +{{< example >}} + + Underline opacity 0 + {{ example >}} ## No underline