From a2a8e2c205008f78c5fe28241c39052d2c6e6e19 Mon Sep 17 00:00:00 2001 From: BBaoVanC Date: Sat, 31 Jan 2026 01:58:42 -0600 Subject: [PATCH] css: Use structured class names for children of code-block --- assets/css/bobastyle.css | 12 ++++++------ layouts/_markup/render-codeblock.html | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/assets/css/bobastyle.css b/assets/css/bobastyle.css index fca2b56..315cdcc 100644 --- a/assets/css/bobastyle.css +++ b/assets/css/bobastyle.css @@ -823,7 +823,7 @@ figcaption { background-color: var(--background-1); border-radius: 8px; } -.code-block > .code-header { +.code-block-header { display: flex; flex-direction: row; justify-content: space-between; @@ -833,17 +833,17 @@ figcaption { border-top-right-radius: 8px; height: 2em; } -.code-block > .code-header > * { +.code-block-header > * { margin: auto 0; } -.code-block > .code-header > .code-type { +.code-block-type { border-top-left-radius: 8px; } /* TODO: make the code copy button prettier */ -.code-block > .code-header > .code-copy-button { +.code-block-copy-button { color: var(--link-1); } -.code-block > .code-header > .code-copy-button:hover { +.code-block-copy-button:hover { cursor: pointer; } .code-block > .highlight { @@ -877,7 +877,7 @@ figcaption { overflow-wrap: break-word; } -.code-block > .code-header > .code-type, +.code-block-type, code { border-radius: 5px; } diff --git a/layouts/_markup/render-codeblock.html b/layouts/_markup/render-codeblock.html index ffeff15..b62fc68 100644 --- a/layouts/_markup/render-codeblock.html +++ b/layouts/_markup/render-codeblock.html @@ -3,9 +3,9 @@ {{ $type = . }} {{ end }}
-