From 162f3a3fa7fd3f27c563f73d8a1fd9838e6ea1ce Mon Sep 17 00:00:00 2001 From: Xin <5097752+imfing@users.noreply.github.com> Date: Sat, 24 Jan 2026 12:00:47 +0000 Subject: [PATCH] fix(tabs): prevent markdown blockquote parsing when nested in steps (#912) * fix(tabs): prevent markdown blockquote parsing when nested in steps Consolidate HTML attributes onto single lines and add proper whitespace trimming to prevent `>` characters on separate lines from being interpreted as markdown blockquotes when tabs are nested inside the steps shortcode. Fixes #876 * chore: add comment explaining single-line HTML requirement --- layouts/_partials/shortcodes/tabs.html | 36 ++++++-------------------- 1 file changed, 8 insertions(+), 28 deletions(-) diff --git a/layouts/_partials/shortcodes/tabs.html b/layouts/_partials/shortcodes/tabs.html index a9e9dd7..6a2bcb3 100644 --- a/layouts/_partials/shortcodes/tabs.html +++ b/layouts/_partials/shortcodes/tabs.html @@ -30,40 +30,20 @@ The `tabs` parameter is a list of dict with the following keys: {{- /* Generate a unique ID for each tab group. */ -}} {{- $globalID := printf "tabs-%02v" $tabsID -}} +{{- /* Keep HTML on single lines to avoid `>` being parsed as blockquote when nested in steps (#876) */ -}}
-
+
{{- range $i, $item := $tabs -}} - {{- end -}}
- {{- range $i, $item := $tabs -}} -
- {{- $item.content | markdownify -}} -
- {{- end -}} + {{- range $i, $item := $tabs -}} +
+ {{- $item.content | markdownify -}} +
+ {{- end -}}