fix(styles): add white background to TikZ diagrams in dark mode

Apply the workaround suggested by @eimlav to make TikZ diagrams
visible in dark mode by adding a white background to all figure images.

Since all diagrams are TikZ-based (converted to SVG with output-format:
svg), they were designed with a white background assumption. This adds:
- White background to preserve diagram readability
- 1rem padding for spacing
- Rounded corners (8px) for polish
- Subtle shadow for depth on dark backgrounds

This is a temporary workaround until diagrams can be regenerated with
proper transparent backgrounds or dark-mode-aware colors. The approach
keeps diagrams readable without requiring regeneration of all TikZ
content.

Thanks to @eimlav for the suggestion and identifying the issue.
This commit is contained in:
Vijay Janapa Reddi
2025-10-27 10:28:57 -04:00
parent 03c7c4f7d9
commit dc2a810e4f
59 changed files with 9 additions and 58 deletions

View File

@@ -1 +0,0 @@
[]

View File

@@ -290,6 +290,15 @@ figure figcaption,
background-color: transparent !important;
}
// TikZ diagrams - add white background for visibility in dark mode
figure img,
.quarto-figure img {
background-color: white !important;
padding: 1rem !important;
border-radius: 8px !important;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}
// Footnotes and margin notes - critical fix
.sidenote,
.marginnote,

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
[{"autoid":"callout-quiz-question-id-quiz-question-sec-conclusion-overview-9b37","cls":"callout-quiz-question","file":"conclusion","id":"quiz-question-sec-conclusion-overview-9b37","label":"Self-Check: Question","neu":true,"reflabel":"Self-Check: Question","refnum":"1.1","reftag":"1.1","title":""},{"autoid":"callout-quiz-answer-id-quiz-answer-sec-conclusion-overview-9b37","cls":"callout-quiz-answer","file":"conclusion","id":"quiz-answer-sec-conclusion-overview-9b37","label":"Self-Check: Answer","neu":true,"reflabel":"Self-Check: Answer","refnum":"1.1","reftag":"1.1","title":""}]

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]

View File

@@ -1 +0,0 @@
[]