1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-09-03 02:13:01 +02:00

Proposal to offer a customization way for dark mode

This commit is contained in:
louismaxime.piton
2023-02-28 12:31:55 +01:00
parent 80ba848443
commit 7726b345aa
3 changed files with 57 additions and 20 deletions

View File

@@ -44,12 +44,30 @@ $theme-colors-border-subtle: (
"dark": $dark-border-subtle,
) !default;
// scss-docs-end theme-border-subtle-map
$theme-colors-dark: null !default;
$theme-colors-rgb-dark: null !default;
$theme-colors-text-dark: null !default;
$theme-colors-bg-subtle-dark: null !default;
$theme-colors-border-subtle-dark: null !default;
@if $enable-dark-mode {
// scss-docs-start theme-color-dark-map
$theme-colors-dark: (
"primary": $primary-dark,
"secondary": $secondary-dark,
"success": $success-dark,
"info": $info-dark,
"warning": $warning-dark,
"danger": $danger-dark,
"light": $light-dark,
"dark": $dark-dark,
) !default;
// scss-docs-end theme-color-dark-map
// scss-docs-start theme-colors-rgb-dark
$theme-colors-rgb-dark: map-loop($theme-colors-dark, to-rgb, "$value") !default;
// scss-docs-end theme-colors-rgb-dark
// scss-docs-start theme-text-dark-map
$theme-colors-text-dark: (
"primary": $primary-text-emphasis-dark,