mirror of
https://github.com/tenrok/bootstrap.git
synced 2026-05-18 12:39:41 +03:00
65 lines
2.6 KiB
SCSS
65 lines
2.6 KiB
SCSS
:root {
|
|
// Note: Custom variable values only support SassScript inside `#{}`.
|
|
|
|
// Colors
|
|
//
|
|
// Generate palettes for full colors, grays, and theme colors.
|
|
|
|
@each $color, $value in $colors {
|
|
--#{$variable-prefix}#{$color}: #{$value};
|
|
}
|
|
|
|
@each $color, $value in $grays {
|
|
--#{$variable-prefix}gray-#{$color}: #{$value};
|
|
}
|
|
|
|
@each $color, $value in $theme-colors {
|
|
--#{$variable-prefix}#{$color}: #{$value};
|
|
}
|
|
|
|
@each $color, $value in $theme-colors-rgb {
|
|
--#{$variable-prefix}#{$color}-rgb: #{$value};
|
|
}
|
|
|
|
--#{$variable-prefix}white-rgb: #{to-rgb($white)};
|
|
--#{$variable-prefix}black-rgb: #{to-rgb($black)};
|
|
--#{$variable-prefix}body-color-rgb: #{to-rgb($body-color)};
|
|
--#{$variable-prefix}body-bg-rgb: #{to-rgb($body-bg)};
|
|
|
|
// Fonts
|
|
|
|
// Note: Use `inspect` for lists so that quoted items keep the quotes.
|
|
// See https://github.com/sass/sass/issues/2383#issuecomment-336349172
|
|
--#{$variable-prefix}font-sans-serif: #{inspect($font-family-sans-serif)};
|
|
--#{$variable-prefix}font-monospace: #{inspect($font-family-monospace)};
|
|
--#{$variable-prefix}gradient: #{$gradient};
|
|
|
|
// Root and body
|
|
// stylelint-disable custom-property-empty-line-before
|
|
// scss-docs-start root-body-variables
|
|
@if $font-size-root != null {
|
|
--#{$variable-prefix}root-font-size: #{$font-size-root};
|
|
}
|
|
--#{$variable-prefix}body-font-family: #{$font-family-base};
|
|
@include rfs($font-size-base, --#{$variable-prefix}body-font-size);
|
|
--#{$variable-prefix}body-font-weight: #{$font-weight-base};
|
|
--#{$variable-prefix}body-line-height: #{$line-height-base};
|
|
--#{$variable-prefix}body-color: #{$body-color};
|
|
@if $body-text-align != null {
|
|
--#{$variable-prefix}body-text-align: #{$body-text-align};
|
|
}
|
|
--#{$variable-prefix}body-bg: #{$body-bg};
|
|
// scss-docs-end root-body-variables
|
|
|
|
// Focus styles
|
|
// scss-docs-start root-focus-variables
|
|
--#{$variable-prefix}focus-ring-width: #{$focus-ring-width};
|
|
--#{$variable-prefix}focus-ring-opacity: #{$focus-ring-opacity};
|
|
--#{$variable-prefix}focus-ring-color: #{$focus-ring-color};
|
|
--#{$variable-prefix}focus-ring-blur: #{$focus-ring-blur};
|
|
// By default, there is no `--bs-focus-ring-offset-x` or `--bs-focus-ring-offset-y`, but we provide CSS variables with fallbacks to initial `0` values
|
|
--#{$variable-prefix}focus-ring-box-shadow: var(--#{$variable-prefix}focus-ring-offset-x, 0) var(--#{$variable-prefix}focus-ring-offset-y, 0) var(--#{$variable-prefix}focus-ring-blur) var(--#{$variable-prefix}focus-ring-width) var(--#{$variable-prefix}focus-ring-color);
|
|
// scss-docs-end root-focus-variables
|
|
// stylelint-enable custom-property-empty-line-before
|
|
}
|