Skip to content

Commit

Permalink
Adjust code block line height
Browse files Browse the repository at this point in the history
  • Loading branch information
iamgio committed Nov 23, 2024
1 parent 2b25176 commit 6502966
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion core/src/main/resources/render/theme/global.css
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,9 @@
--qd-horizontal-alignment: var(--qd-paged-horizontal-alignment);

/* Code */
--qd-code-line-height: var(--qd-line-height); /* Line height of code blocks */
--qd-code-border-radius: 8px; /* Border radius of code blocks */
--qd-code-line-numbers-padding: 0.3em 0.8em; /* Padding of line numbers of code blocks. Also defines code line height. */
--qd-code-line-numbers-padding: 0 0.8em; /* Padding of line numbers of code blocks. Vertical padding also defines code line height. */
--qd-code-line-numbers-opacity: 0.6; /* Opacity of line numbers of code blocks */

/* Quotes */
Expand Down Expand Up @@ -302,8 +303,10 @@ code:not(pre code) {

pre code {
font-size: var(--qd-code-block-font-size);
line-height: var(--qd-code-line-height);
font-style: normal !important;
max-height: none !important;
overflow: hidden;
}

pre, pre code {
Expand Down
1 change: 1 addition & 0 deletions core/src/main/resources/render/theme/layout/minimal.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
--qd-code-span-font-size: 0.9em;
--qd-block-margin: 1.8em;
--qd-line-height: 1.8;
--qd-code-line-height: 1.85;
--qd-location-suffix: "";
}

Expand Down

0 comments on commit 6502966

Please sign in to comment.