Repos / pytaku / 09d948b643
commit 09d948b6431345adc1718d952eb3603586697e9f
Author: Nhân <hi@imnhan.com>
Date: Fri Sep 29 21:32:44 2023 +0700
lazy dark mode
diff --git a/src/pytaku/static/darkmode.css b/src/pytaku/static/darkmode.css
new file mode 100644
index 0000000..1af0e15
--- /dev/null
+++ b/src/pytaku/static/darkmode.css
@@ -0,0 +1,17 @@
+@media (prefers-color-scheme: dark) {
+ :root {
+ background-color: #333;
+ color: #eee;
+ }
+
+ footer {
+ background-color: var(--bg-black);
+ color: #eee;
+ border: none;
+ }
+
+ .follows--title.non-empty,
+ .title--descriptions {
+ background-color: #555;
+ }
+}
diff --git a/src/pytaku/templates/spa.html b/src/pytaku/templates/spa.html
index be5f0a0..ed98465 100644
--- a/src/pytaku/templates/spa.html
+++ b/src/pytaku/templates/spa.html
@@ -13,6 +13,7 @@
<link rel="stylesheet" href="{{ url_for('static', filename='feathericons/iconfont.css') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='lookandfeel.css') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='spa.css') }}">
+ <link rel="stylesheet" href="{{ url_for('static', filename='darkmode.css') }}">
{% if open_graph %}
<meta property="og:title" content="{{ open_graph['title'] }}">