Skip to content

Commit c8725c0

Browse files
committed
fix: Update highlight shortcode to error if used + styling
1 parent 6311910 commit c8725c0

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

assets/css/v2/style.css

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@
6060
--color-shadow: #d2d2d2;
6161
--color-codeblock-border: #888;
6262
--color-codeblock-shadow: #e5e5e5;
63+
--color-codeblock-highlight: #fffed9;
6364
--color-footer: #1d1d1d;
6465
--color-footer-text: #e2e2e2;
6566
--color-product-title: #8d8d8d;
@@ -1449,6 +1450,12 @@ ul .code-block {
14491450
padding: 0;
14501451
}
14511452

1453+
.highlight code .hl {
1454+
width: fit-content;
1455+
min-width: 100%;
1456+
background-color: var(--color-codeblock-highlight);
1457+
}
1458+
14521459
/* MARK: Images
14531460
*/
14541461
figure {

layouts/shortcodes/highlight.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{{ errorf "'<highlight></highlight>' is deprecated. Use codeblock shortcode (via triple ticks and setting 'hl_lines') instead."}}

0 commit comments

Comments
 (0)