summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sass/_partial/_dark.scss3
-rw-r--r--sass/_partial/_post.scss3
-rw-r--r--templates/base.html11
3 files changed, 13 insertions, 4 deletions
diff --git a/sass/_partial/_dark.scss b/sass/_partial/_dark.scss
index 8789275..ab778df 100644
--- a/sass/_partial/_dark.scss
+++ b/sass/_partial/_dark.scss
@@ -32,7 +32,6 @@ body {
.post {
border-color: #616161;
code, pre {
- background-color: black;
color: white;
}
.highlight {
@@ -54,4 +53,4 @@ body {
.archive .post-archive .post-item .post-title {
color: white;
-} \ No newline at end of file
+}
diff --git a/sass/_partial/_post.scss b/sass/_partial/_post.scss
index e1f9c60..b96aad5 100644
--- a/sass/_partial/_post.scss
+++ b/sass/_partial/_post.scss
@@ -33,7 +33,6 @@
}
code, pre {
font-size: 16px;
- background-color: #f7f7f7;
font-family: 'Fantasque Sans Mono', 'PT Mono', 'Source Code Pro', monospace;
}
.highlight {
@@ -180,4 +179,4 @@
.post-meta {
color: black;
}
-} \ No newline at end of file
+}
diff --git a/templates/base.html b/templates/base.html
index 793efad..795adb3 100644
--- a/templates/base.html
+++ b/templates/base.html
@@ -33,9 +33,20 @@
<meta property="og:image:height" content="200" />
<link rel="stylesheet" href="{{ config.base_url }}/style.css">
{% if config.extra.seje_darkmode == "auto" %}
+ {% if config.markdown.highlight_code and config.markdown.highlight_theme == "css" %}
+ <link rel="stylesheet" type="text/css" href="/syntax-theme-dark.css" media="(prefers-color-scheme: dark)" />
+ <link rel="stylesheet" type="text/css" href="/syntax-theme-light.css" media="(prefers-color-scheme: light)" />
+ {% endif %}
<link rel="stylesheet" href="{{ config.base_url }}/autodarkmode.css">
{% elif config.extra.seje_darkmode == "always" %}
+ {% if config.markdown.highlight_code and config.markdown.highlight_theme == "css" %}
+ <link rel="stylesheet" type="text/css" href="/syntax-theme-dark.css">
+ {% endif %}
<link rel="stylesheet" href="{{ config.base_url }}/darkmode.css">
+ {% else %}
+ {% if config.markdown.highlight_code and config.markdown.highlight_theme == "css" %}
+ <link rel="stylesheet" type="text/css" href="/syntax-theme-light.css">
+ {% endif %}
{% endif %}
{% if config.extra.seje_vertical_layout %}
<link rel="stylesheet" href="{{ config.base_url }}/vertical.css">