use light-dark function
This commit is contained in:
parent
423997bc13
commit
933c1cb7d7
1 changed files with 4 additions and 14 deletions
|
@ -1,22 +1,12 @@
|
|||
@media (prefers-color-scheme: light) {
|
||||
:root {
|
||||
--code-font-color: #333333;
|
||||
--code-bg-color: #eeeeee;
|
||||
--quote-border-color: #9852fa;
|
||||
--quote-bg-color: #d8d6d6;
|
||||
--separator-color: #cccccc;
|
||||
--tag-bg-color: #d2e0f0;
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
:root {
|
||||
--code-font-color: #eeeeee;
|
||||
--code-bg-color: #333333;
|
||||
--quote-border-color: #bd93f9;
|
||||
--quote-bg-color: #273341;
|
||||
--separator-color: #414558;
|
||||
--tag-bg-color: #242e38;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -64,8 +54,8 @@ blockquote {
|
|||
margin: 1em 0;
|
||||
padding: 0.1em 10px;
|
||||
border-left: 6px solid;
|
||||
border-color: var(--quote-border-color);
|
||||
background: var(--quote-bg-color);
|
||||
border-color: light-dark(#9852fa, #bd93f9);
|
||||
background: light-dark(#d8d6d6, #273341);
|
||||
border-top-right-radius: 5px;
|
||||
border-bottom-right-radius: 5px;
|
||||
}
|
||||
|
@ -73,9 +63,9 @@ blockquote {
|
|||
/* Little snippet of code (not blocks) */
|
||||
kbd,
|
||||
code:not(.hljs):not(:has(svg)) {
|
||||
background: var(--code-bg-color);
|
||||
background: light-dark(#eeeeee, #333333);
|
||||
border-radius: 3px;
|
||||
color: var(--code-font-color);
|
||||
color: light-dark(#333333, #eeeeee);
|
||||
box-shadow: 0 1px 1px black;
|
||||
font-size: calc(var(--font-size) * 0.8);
|
||||
padding: 2px 4px;
|
||||
|
|
Loading…
Reference in a new issue