aboutsummaryrefslogtreecommitdiffhomepage
path: root/sass/_zola.scss
diff options
context:
space:
mode:
Diffstat (limited to 'sass/_zola.scss')
-rw-r--r--sass/_zola.scss26
1 files changed, 20 insertions, 6 deletions
diff --git a/sass/_zola.scss b/sass/_zola.scss
index 01fc954..592b893 100644
--- a/sass/_zola.scss
+++ b/sass/_zola.scss
@@ -1,26 +1,40 @@
// -- zola syntax highlighting (https://www.getzola.org/documentation/content/syntax-highlighting/#styling-codeblocks)
+// -- Code Block WITHOUT Line Number -------------------------------------------
+
pre {
padding: 0.5rem;
overflow: auto;
- border-radius: 0.25rem;
}
-pre[data-linenos] {
- padding: 1rem 0;
-}
+// -- Code Block WITH Line Number ----------------------------------------------
-pre table td {
- padding: 0;
+// The <pre> block for blocks with line numbers (get data-linenos attribute).
+//
+// The line numbers already provide some kind of left/right padding. Hence only
+// apply top-bottom padding and overwrite left-write padding inherited from the
+// *pre* style block above.
+pre[data-linenos] {
+ padding: 0.5rem 0;
}
+// The line number cells (column 1).
pre table td:nth-of-type(1) {
text-align: center;
user-select: none;
+ padding: 0 0.5rem;
+}
+
+// The source code cells (column 2).
+pre table td {
+ padding: 0;
}
+// Highlighted line style.
pre mark {
+ // If you want your highlights to take the full width.
display: block;
+ // The default background colour of a mark is bright yellow
background-color: rgba(254, 252, 232, 0.9);
}