From a116d78951de2e05d59ea95b9df7e98be942dfa1 Mon Sep 17 00:00:00 2001 From: Leo Vasanko Date: Thu, 27 Aug 2026 22:42:20 +0000 Subject: [PATCH] Flood fill images in aside. --- frontend/src/assets/pagerite.css | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/frontend/src/assets/pagerite.css b/frontend/src/assets/pagerite.css index 17a3d7d..4075eda 100644 --- a/frontend/src/assets/pagerite.css +++ b/frontend/src/assets/pagerite.css @@ -856,6 +856,22 @@ blockquote p + p { margin-bottom: 0; } +/* A figure inside an aside spans the box to its borders (negative + margins matching the box's padding); the caption keeps the box's + padding for itself. Explicit-width images keep their shrink-wrap. */ +.aside>figure:not(:has(img[width])) { + width: auto; + margin: -0.6rem -0.9rem 1rem; +} + +.aside>figure figcaption { + padding: 0.6rem 0.9rem 0; +} + +.aside>figure:last-child figcaption { + padding-bottom: 0.6rem; +} + .margin { float: left; clear: left;