From 71c0e0f07c24a887d5447a0ab68e3567735c9307 Mon Sep 17 00:00:00 2001 From: Helen Chong <119173961+helenclx@users.noreply.github.com> Date: Fri, 10 May 2024 02:01:32 +0800 Subject: [PATCH] Fix width of pre element for code blocks --- _site/assets/css/main.css | 10 +++++++--- _site/feed.xml | 2 +- src/assets/css/main.css | 10 +++++++--- 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/_site/assets/css/main.css b/_site/assets/css/main.css index c474af09..2cdc9227 100644 --- a/_site/assets/css/main.css +++ b/_site/assets/css/main.css @@ -242,9 +242,13 @@ pre { } pre { - max-width: calc(100vw - 2em); - overflow-x: auto; - padding: 0.8em 1.4em; + max-width: 90vw; + overflow: auto; + padding: 1rem; +} + +pre > code { + white-space: pre; } summary { diff --git a/_site/feed.xml b/_site/feed.xml index 9172acd9..49928702 100644 --- a/_site/feed.xml +++ b/_site/feed.xml @@ -4,7 +4,7 @@ Leilukin's personal website. - 2024-05-09T17:12:48Z + 2024-05-09T18:00:34Z https://leilukin.neocities.org Leilukin diff --git a/src/assets/css/main.css b/src/assets/css/main.css index c474af09..2cdc9227 100644 --- a/src/assets/css/main.css +++ b/src/assets/css/main.css @@ -242,9 +242,13 @@ pre { } pre { - max-width: calc(100vw - 2em); - overflow-x: auto; - padding: 0.8em 1.4em; + max-width: 90vw; + overflow: auto; + padding: 1rem; +} + +pre > code { + white-space: pre; } summary {