From 93a4ac4ef456875d210ec1bc549da7793c6f4a6c Mon Sep 17 00:00:00 2001 From: eugenchio Date: Thu, 26 Dec 2024 12:07:30 +0200 Subject: [PATCH] Add horizontal scrolling for code tag in blog articles. --- assets/sass/_article.scss | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/assets/sass/_article.scss b/assets/sass/_article.scss index 7567184..33b67fb 100644 --- a/assets/sass/_article.scss +++ b/assets/sass/_article.scss @@ -101,12 +101,20 @@ font-size: 1rem; padding: 0 .375rem; line-height: 1.75; - white-space: pre-wrap; } pre { - background-color: transparent !important; - padding-left: 5px; + margin-left: 5px; + border: 1px solid #e6e8f0; + border-radius: 4px; + background-color: #f9fafc !important; + overflow: auto; + + code { + border: unset; + border-radius: unset; + overflow: visible; + } } table {