« get me outta code hell

always use colors.dark for theme-color - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2022-12-06 17:13:33 -0400
committer(quasar) nebula <qznebula@protonmail.com>2022-12-06 17:14:03 -0400
commitd0059cc2743e785605bb7b34553dd2def528ab5c (patch)
treed5d53cd6943d2a4d429e1580c08b11687597324e
parent431c3b636bcbd9cd46c5dd90ca0f818a4ea50e1f (diff)
always use colors.dark for theme-color
-rwxr-xr-xsrc/upd8.js20
1 files changed, 5 insertions, 15 deletions
diff --git a/src/upd8.js b/src/upd8.js
index 38a2e87d..518e5f1a 100755
--- a/src/upd8.js
+++ b/src/upd8.js
@@ -1235,21 +1235,11 @@ writePage.html = (pageInfo, {
     socialEmbed.image &&
       html.tag('meta', {property: 'og:image', content: socialEmbed.image}),
 
-    ...html.fragment(
-      colors && [
-        // Safari only respects the first media-matching meta tag here,
-        // so position the dark-specific entry first
-        html.tag('meta', {
-          name: 'theme-color',
-          content: colors.dark,
-          media: '(prefers-color-scheme: dark)'
-        }),
-
-        html.tag('meta', {
-          name: 'theme-color',
-          content: colors.primary,
-        }),
-      ]),
+    colors &&
+      html.tag('meta', {
+        name: 'theme-color',
+        content: colors.dark,
+      }),
 
     oEmbedJSONHref &&
       html.tag('link', {