From 32a07b5109564f96f2122c4009150b9a568f1900 Mon Sep 17 00:00:00 2001 From: Alessio Di Mauro Date: Fri, 6 Aug 2021 15:55:03 +0200 Subject: [PATCH] Fix
 HTML tag to follow theme settings

The 
 tag was set to a fixed background color that on the light
theme happened to be the same color of the text, making it impossible
to read.

This changes the background color to follow the theme setting using
the secondary light/dark color as background.
---
 assets/scss/_main.scss | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/assets/scss/_main.scss b/assets/scss/_main.scss
index b783fc4..7a62d4b 100644
--- a/assets/scss/_main.scss
+++ b/assets/scss/_main.scss
@@ -239,7 +239,14 @@ code {
 }
 
 pre {
-  background: #212020;
+  [data-theme=dark] & {
+    background-color: $dark-background-secondary;
+  }
+
+  [data-theme=light] & {
+    background-color: $light-background-secondary;
+  }
+
   padding: 10px 10px 10px 20px;
   border-radius: 8px;
   font-size: 0.95rem;