Review and update whitespaces in shortcodes to improve shortcode nesting

This commit is contained in:
Alex Shpak
2025-09-26 15:48:57 +02:00
parent 48157b18c7
commit 5ffdf5bfaf
18 changed files with 89 additions and 74 deletions
+4 -7
View File
@@ -1,9 +1,7 @@
{{- /* remove whitespace */ -}}
{{- with .Get "href" -}}
{{- $destination := partial "docs/links/portable-link" (dict "Page" $.Page "Destination" .) -}}
<a class="book-card{{ with $.Get "class" }} {{ . }}{{ end }}" href="{{ $destination | safeURL }}">
<div><a class="book-card{{ with $.Get "class" }} {{ . }}{{ end }}" href="{{ . | safeURL }}">
{{- template "book-card-content" $ -}}
</a>
</a></div>
{{- else -}}
<div class="book-card{{ with .Get "class" }} {{ . }}{{ end }}">
{{- template "book-card-content" $ -}}
@@ -14,9 +12,8 @@
{{- with .Get "image" -}}
{{- $destination := partial "docs/links/portable-image" (dict "Page" $.Page "Destination" .) -}}
<img src="{{ $destination | safeURL }}" />
{{- end }}
{{- end -}}
<div class="markdown-inner">
{{ with .Inner }}{{ . }}{{ end }}
{{ with .Inner }}{{ . }}{{ end -}}
</div>
{{- end -}}
{{- /* remove whitespace */ -}}