Add dark mode

If the client uses a dark color-scheme, the CSS will switch to a dark
color scheme as well.
This commit is contained in:
Alexander Haase 2020-10-18 21:12:08 +02:00
parent 76a9ef4932
commit 97c6d25a67
2 changed files with 27 additions and 0 deletions

View file

@ -32,3 +32,16 @@ body {
* the content and the footer. */
padding-bottom: @footer-height;
}
/* If the client prefers a dark color scheme, the following classes will be
* applied to give the site a dark look and feel.
*
* NOTE: These classes need to be at the end of this file, as they override the
* default settings previously defined, if the dark color scheme is
* requested. */
@media (prefers-color-scheme: dark) {
body {
background-color: @gray-800;
color: white;
}
}

View file

@ -49,3 +49,17 @@
white-space: normal;
}
}
/* If the client prefers a dark color scheme, the following classes will be
* applied to give the site a dark look and feel.
*
* NOTE: These classes need to be at the end of this file, as they override the
* default settings previously defined, if the dark color scheme is
* requested. */
@media (prefers-color-scheme: dark) {
a,
a:hover,
a:focus {
color: @black;
}
}