Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

fix: reference fonts by css vars (#630)

Myles Scolnick374e90aef8ec
diff --git a/frontend/src/css/App.css b/frontend/src/css/App.css
index 0ddce83734..a52e3e61e1 100644
--- a/frontend/src/css/App.css
+++ b/frontend/src/css/App.css
@@ -22,6 +22,7 @@ html {
--content-width: 740px;
--monospace-font: "Fira Mono";
--text-font: "PT Sans", sans-serif;
+ --heading-font: Lora, serif;
}
#App {
diff --git a/frontend/src/css/md.css b/frontend/src/css/md.css
index 19573da67c..ca87e759bd 100644
--- a/frontend/src/css/md.css
+++ b/frontend/src/css/md.css
@@ -5,7 +5,7 @@
.markdown span:not(.arithmatex *, code *, .MuiBox-root) {
/* the not selector makes sure we don't change katex/LaTeX styles */
line-height: 1.5rem;
- font-family: "PT Sans", sans-serif;
+ font-family: var(--text-font);
}
.markdown p:first-child,
@@ -96,7 +96,7 @@
.markdown h4,
.markdown h5,
.markdown h6 {
- font-family: Lora, serif;
+ font-family: var(--heading-font);
}
.markdown pre {
diff --git a/frontend/src/plugins/impl/plotly/plotly.css b/frontend/src/plugins/impl/plotly/plotly.css
index 8e38afb5d0..966febc2cc 100644
--- a/frontend/src/plugins/impl/plotly/plotly.css
+++ b/frontend/src/plugins/impl/plotly/plotly.css
@@ -3,13 +3,13 @@
.js-plotly-plot .plotly,
.js-plotly-plot .plotly div {
direction: ltr;
- font-family: "Open Sans", verdana, arial, sans-serif;
+ font-family: var(--text-font);
margin: 0;
padding: 0;
}
.js-plotly-plot .plotly input,
.js-plotly-plot .plotly button {
- font-family: "Open Sans", verdana, arial, sans-serif;
+ font-family: var(--text-font);
}
.js-plotly-plot .plotly input:focus,
.js-plotly-plot .plotly button:focus {
@@ -237,7 +237,7 @@
}
.plotly-notifier {
- font-family: "Open Sans", verdana, arial, sans-serif;
+ font-family: var(--text-font);
position: fixed;
top: 50px;
right: 20px;