mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-17 19:06:40 +02:00
Merge branch 'main' into main-lmp-tab-fix
This commit is contained in:
2
.github/workflows/js.yml
vendored
2
.github/workflows/js.yml
vendored
@@ -45,7 +45,7 @@ jobs:
|
||||
run: npm run js-test
|
||||
|
||||
- name: Run Coveralls
|
||||
uses: coverallsapp/github-action@1.1.3
|
||||
uses: coverallsapp/github-action@v1.2.2
|
||||
with:
|
||||
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
path-to-lcov: "./js/coverage/lcov.info"
|
||||
|
@@ -10,7 +10,7 @@
|
||||
@include rfs($btn-font-size, --#{$prefix}btn-font-size);
|
||||
--#{$prefix}btn-font-weight: #{$btn-font-weight};
|
||||
--#{$prefix}btn-line-height: #{$btn-line-height};
|
||||
--#{$prefix}btn-color: #{$body-color};
|
||||
--#{$prefix}btn-color: #{$btn-color};
|
||||
--#{$prefix}btn-bg: transparent;
|
||||
--#{$prefix}btn-border-width: #{$btn-border-width};
|
||||
--#{$prefix}btn-border-color: transparent;
|
||||
|
@@ -100,9 +100,11 @@
|
||||
margin-bottom: 0;
|
||||
list-style: none;
|
||||
|
||||
.show > .nav-link,
|
||||
.nav-link.active {
|
||||
color: var(--#{$prefix}navbar-active-color);
|
||||
.nav-link {
|
||||
&.active,
|
||||
&.show {
|
||||
color: var(--#{$prefix}navbar-active-color);
|
||||
}
|
||||
}
|
||||
|
||||
.dropdown-menu {
|
||||
|
@@ -459,6 +459,15 @@ $link-hover-decoration: null !default;
|
||||
$stretched-link-pseudo-element: after !default;
|
||||
$stretched-link-z-index: 1 !default;
|
||||
|
||||
// Icon links
|
||||
// scss-docs-start icon-link-variables
|
||||
$icon-link-gap: .375rem !default;
|
||||
$icon-link-underline-offset: .25em !default;
|
||||
$icon-link-icon-size: 1em !default;
|
||||
$icon-link-icon-transition: .2s ease-in-out transform !default;
|
||||
$icon-link-icon-transform: translate3d(.25em, 0, 0) !default;
|
||||
// scss-docs-end icon-link-variables
|
||||
|
||||
// Paragraphs
|
||||
//
|
||||
// Style p element.
|
||||
@@ -801,6 +810,7 @@ $input-btn-border-width: var(--#{$prefix}border-width) !default;
|
||||
// For each of Bootstrap's buttons, define text, background, and border color.
|
||||
|
||||
// scss-docs-start btn-variables
|
||||
$btn-color: var(--#{$prefix}body-color) !default;
|
||||
$btn-padding-y: $input-btn-padding-y !default;
|
||||
$btn-padding-x: $input-btn-padding-x !default;
|
||||
$btn-font-family: $input-btn-font-family !default;
|
||||
|
@@ -1,16 +1,17 @@
|
||||
.icon-link {
|
||||
display: inline-flex;
|
||||
gap: .375rem;
|
||||
gap: $icon-link-gap;
|
||||
align-items: center;
|
||||
text-decoration-color: rgba(var(--#{$prefix}link-color-rgb), var(--#{$prefix}link-opacity, .5));
|
||||
text-underline-offset: .25em;
|
||||
text-underline-offset: $icon-link-underline-offset;
|
||||
backface-visibility: hidden;
|
||||
|
||||
> .bi {
|
||||
flex-shrink: 0;
|
||||
width: 1em;
|
||||
height: 1em;
|
||||
@include transition(.2s ease-in-out transform);
|
||||
width: $icon-link-icon-size;
|
||||
height: $icon-link-icon-size;
|
||||
fill: currentcolor;
|
||||
@include transition($icon-link-icon-transition);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +19,7 @@
|
||||
&:hover,
|
||||
&:focus-visible {
|
||||
> .bi {
|
||||
transform: var(--#{$prefix}icon-link-transform, translate3d(.25em, 0, 0));
|
||||
transform: var(--#{$prefix}icon-link-transform, $icon-link-icon-transform);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -214,7 +214,7 @@ Note that for security reasons the `sanitize`, `sanitizeFn`, and `allowList` opt
|
||||
| `sanitizeFn` | null, function | `null` | Here you can supply your own sanitize function. This can be useful if you prefer to use a dedicated library to perform sanitization. |
|
||||
| `selector` | string, false | `false` | If a selector is provided, tooltip objects will be delegated to the specified targets. In practice, this is used to also apply tooltips to dynamically added DOM elements (`jQuery.on` support). See [this issue]({{< param repo >}}/issues/4215) and [an informative example](https://codepen.io/Johann-S/pen/djJYPb). **Note**: `title` attribute must not be used as a selector. |
|
||||
| `template` | string | `'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>'` | Base HTML to use when creating the tooltip. The tooltip's `title` will be injected into the `.tooltip-inner`. `.tooltip-arrow` will become the tooltip's arrow. The outermost wrapper element should have the `.tooltip` class and `role="tooltip"`. |
|
||||
| `title` | string, element, function | `''` | Default title value if `title` attribute isn't present. If a function is given, it will be called with its `this` reference set to the element that the popover is attached to. |
|
||||
| `title` | string, element, function | `''` | Default title value if `title` attribute isn't present. If a function is given, it will be called with its `this` reference set to the element that the tooltip is attached to. |
|
||||
| `trigger` | string | `'hover focus'` | How tooltip is triggered: click, hover, focus, manual. You may pass multiple triggers; separate them with a space. `'manual'` indicates that the tooltip will be triggered programmatically via the `.tooltip('show')`, `.tooltip('hide')` and `.tooltip('toggle')` methods; this value cannot be combined with any other trigger. `'hover'` on its own will result in tooltips that cannot be triggered via the keyboard, and should only be used if alternative methods for conveying the same information for keyboard users is present. |
|
||||
{{< /bs-table >}}
|
||||
|
||||
|
@@ -10,6 +10,6 @@
|
||||
font-size: 85%;
|
||||
}
|
||||
|
||||
.dropdown-toggle {
|
||||
.dropdown-toggle:not(:focus) {
|
||||
outline: 0;
|
||||
}
|
||||
|
@@ -45,6 +45,14 @@ Add `.icon-link-hover` to move the icon to the right on hover.
|
||||
</a>
|
||||
{{< /example >}}
|
||||
|
||||
## Customize
|
||||
|
||||
Modify the styling of an icon link with our link CSS variables, Sass variables, utilities, or custom styles.
|
||||
|
||||
### CSS variables
|
||||
|
||||
Modify the `--bs-link-*` and `--bs-icon-link-*` CSS variables as needed to change the default appearance.
|
||||
|
||||
Customize the hover `transform` by overriding the `--bs-icon-link-transform` CSS variable:
|
||||
|
||||
{{< example >}}
|
||||
@@ -54,7 +62,22 @@ Customize the hover `transform` by overriding the `--bs-icon-link-transform` CSS
|
||||
</a>
|
||||
{{< /example >}}
|
||||
|
||||
## Pairs with link utilities
|
||||
Customize the color by overriding the `--bs-link-*` CSS variable:
|
||||
|
||||
{{< example >}}
|
||||
<a class="icon-link icon-link-hover" style="--bs-link-hover-color-rgb: 25, 135, 84;" href="#">
|
||||
Icon link
|
||||
<svg class="bi" aria-hidden="true"><use xlink:href="#arrow-right"></use></svg>
|
||||
</a>
|
||||
{{< /example >}}
|
||||
|
||||
### Sass
|
||||
|
||||
Customize the icon link Sass variables to modify all icon link styles across your Bootstrap-powered project.
|
||||
|
||||
{{< scss-docs name="icon-link-variables" file="scss/_variables.scss" >}}
|
||||
|
||||
### Utilities
|
||||
|
||||
Modify icon links with any of [our link utilities]({{< docsref "/utilities/link/" >}}) for modifying underline color and offset.
|
||||
|
||||
|
@@ -214,9 +214,9 @@ We've also introduced a new `.progress-stacked` class to more logically wrap [mu
|
||||
|
||||
### Utilities
|
||||
|
||||
- <span class="badge text-warning-emphasis bg-warning-subtle">Deprecated</span> `.text-body-secondary` will be be replaced by `.text-body-secondary` in v6.
|
||||
- <span class="badge text-warning-emphasis bg-warning-subtle">Deprecated</span> `.text-muted` will be be replaced by `.text-body-secondary` in v6.
|
||||
|
||||
With the addition of the expanded theme colors and variables, the `.text-body-secondary` variables and utility have been deprecated with v5.3.0. Its default value has also has been reassigned to the new `--bs-secondary-color` CSS variable to better support color modes. It will be removed in v6.0.0.
|
||||
With the addition of the expanded theme colors and variables, the `.text-muted` variables and utility have been deprecated with v5.3.0. Its default value has also has been reassigned to the new `--bs-secondary-color` CSS variable to better support color modes. It will be removed in v6.0.0.
|
||||
|
||||
- Adds new `.overflow-x`, `.overflow-y`, and several `.object-fit-*` utilities. _The object-fit property is used to specify how an `<img>` or `<video>` should be resized to fit its container, giving us a responsive alternative to using `background-image` for a resizable fill/fit image._
|
||||
|
||||
|
@@ -25,9 +25,8 @@ Color utilities like `.text-*` that generated from our original `$theme-colors`
|
||||
<p class="text-{{ .name }}-emphasis">.text-{{ .name }}-emphasis</p>
|
||||
{{- end -}}
|
||||
{{< /colors.inline >}}
|
||||
<p class="text-body">.text-body</p>
|
||||
<p class="text-body-secondary">.text-body-secondary</p>
|
||||
|
||||
<p class="text-body">.text-body</p>
|
||||
<p class="text-body-emphasis">.text-body-emphasis</p>
|
||||
<p class="text-body-secondary">.text-body-secondary</p>
|
||||
<p class="text-body-tertiary">.text-body-tertiary</p>
|
||||
@@ -43,7 +42,7 @@ Color utilities like `.text-*` that generated from our original `$theme-colors`
|
||||
{{< /callout >}}
|
||||
|
||||
{{< callout warning >}}
|
||||
**Deprecation:** With the addition of the expanded theme colors and variables, the `.text-body-secondary` utility has been deprecated as of v5.3.0. Its default value has also has been reassigned to the new `--bs-secondary-color` CSS variable to better support color modes. It will be removed in v6.0.0.
|
||||
**Deprecation:** With the addition of the expanded theme colors and variables, the `.text-muted` utility has been deprecated as of v5.3.0. Its default value has also has been reassigned to the new `--bs-secondary-color` CSS variable to better support color modes. It will be removed in v6.0.0.
|
||||
{{< /callout >}}
|
||||
|
||||
## Opacity
|
||||
|
Reference in New Issue
Block a user