Files
homepage/layouts/_default/_markup/render-blockquote.html
T
2026-08-23 20:00:09 +02:00

31 lines
695 B
HTML

{{ $emojis := dict
"tip" ":bulb:"
"note" ":page_with_curl:"
"info" ":information_source:"
"warning" ":warning:"
"caution" ":exclamation:"
"danger" ":bangbang:"
}}
{{ if eq .Type "alert" }}
<blockquote class="alert alert-{{ .AlertType }}">
<div class="alert-heading">
<p class="alert-heading-emoji">
{{ transform.Emojify (index $emojis .AlertType) }}
</p>
<p class="alert-heading-text">
{{ with .AlertTitle }}
{{ . }}
{{ else }}
{{ or (i18n .AlertType) (title .AlertType) }}
{{ end }}
</p>
</div>
{{ .Text }}
</blockquote>
{{ else }}
<blockquote>
{{ .Text }}
</blockquote>
{{ end }}