0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-12-01 13:24:25 +01:00

refactor(color-scheme): reduce complexity

This commit is contained in:
Gaël Poupard 2021-04-10 21:16:45 +02:00 committed by Mark Otto
parent 5a9440da9c
commit 4383ae0459

View File

@ -1,17 +1,7 @@
// scss-docs-start mixin-color-scheme
@mixin color-scheme($name) {
@if $name == dark {
@media (prefers-color-scheme: dark) {
@content;
}
} @else if $name == light {
@media (prefers-color-scheme: light) {
@content;
}
} @else {
@media (prefers-color-scheme: #{$name}) {
@content;
}
@media (prefers-color-scheme: #{$name}) {
@content;
}
}
// scss-docs-end mixin-color-scheme