Merge pull request #28 from odysa/dev

fix: make card support darkmode change
This commit is contained in:
Sivan 2020-10-22 13:14:59 +08:00 committed by GitHub
commit fcfda461a9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,16 +53,23 @@
}
}
@media (prefers-color-scheme: dark) {
.card {
@mixin darkmode {
background-color: hsl(0, 0%, 16%);
> figcaption {
border-block-start: 1px solid hsl(0, 0%, 20%);
}
}
.card__vertical-container {
border-color: hsl(0, 0%, 20%);
}
}
.card {
[data-darkmode="dark"] & {
@include darkmode();
}
@media (prefers-color-scheme: dark) {
[data-darkmode="auto"] & {
@include darkmode();
}
}
}