From 543ae58a37fb1a81aa71320bbffa026c1509daff Mon Sep 17 00:00:00 2001
From: Sumner Evans
Date: Tue, 7 Apr 2020 00:22:07 -0600
Subject: [PATCH] Added support for dark mode detection
---
static/stylesheet/style.less | 9 +++++++++
templates/partial/flex.html | 39 +++++++++++++++++++++++++++++++++++-
2 files changed, 47 insertions(+), 1 deletion(-)
diff --git a/static/stylesheet/style.less b/static/stylesheet/style.less
index bc18dce..dc677a1 100644
--- a/static/stylesheet/style.less
+++ b/static/stylesheet/style.less
@@ -288,6 +288,11 @@ main {
color: @footer-text-color;
font-size: 11px;
}
+
+ // Flex theme and Theme selection separator
+ span.theme-separator {
+ margin: 0 4px;
+ }
}
}
@@ -556,6 +561,10 @@ ul.social {
left: 25vw;
overflow-x: hidden;
+ nav {
+ text-align: right;
+ }
+
article {
&.single {
diff --git a/templates/partial/flex.html b/templates/partial/flex.html
index 4447454..f5b8dea 100644
--- a/templates/partial/flex.html
+++ b/templates/partial/flex.html
@@ -1,3 +1,40 @@
{{ _('Built with %(pelican_url)s using %(flex_url)s theme',
pelican_url='Pelican',
- flex_url='Flex'|safe) }}
+ flex_url='Flex'|safe) }}
+ |
+ Switch to the
+
+ dark
+ |
+ light
+ |
+ browser
+
+ theme
+
+