From 0187ada2586d12551efcbd95f25d4c0b21a24d7b Mon Sep 17 00:00:00 2001 From: Void Date: Tue, 10 Nov 2026 06:23:04 +0000 Subject: [PATCH] Math scroll guard: one rule for every block that holds math The guard covered only paragraphs and display blocks, so an unbreakable formula in a list item, heading or table cell widened the page. One rule now names p, li, h1-h6, th, td and the display block; the duplicate overflow-x on the ritual-paper .katex-display is gone. Co-Authored-By: Claude Sonnet 5.5 --- site/quartz/styles/custom.scss | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/site/quartz/styles/custom.scss b/site/quartz/styles/custom.scss index fee2ede..b9d3da7 100644 --- a/site/quartz/styles/custom.scss +++ b/site/quartz/styles/custom.scss @@ -355,7 +355,6 @@ body[data-slug="Blog/witness-authoritative-networking"] { .katex-display { margin: 1.15rem 0; padding: 0.8rem 1rem; - overflow-x: auto; border: 1px solid rgba(96, 119, 255, 0.38); border-radius: 6px; background: @@ -850,9 +849,9 @@ article > h6 { } /* KaTeX does not break inside a formula, so math wider than the column scrolls - in its own paragraph or display block instead of widening the page; math that - fits shows no scrollbar. */ -article p:has(.katex), + in its own block (paragraph, list item, heading, table cell, display block) + instead of widening the page; math that fits shows no scrollbar. */ +article :is(p, li, h1, h2, h3, h4, h5, h6, th, td):has(.katex), article .katex-display { overflow-x: auto; overflow-y: hidden; -- 2.47.3