mirror of
https://github.com/gcushen/hugo-academic.git
synced 2025-07-23 18:10:52 +02:00
feat(blox): support HTML & multiple paragraphs in Markdown blox
This commit is contained in:
parent
370dc623ab
commit
55b856df3a
1 changed files with 3 additions and 2 deletions
|
@ -6,7 +6,7 @@
|
|||
{{ $page := .wcPage }}
|
||||
{{ $block := .wcBlock }}
|
||||
{{ $title := $block.content.title | emojify | $page.RenderString }}
|
||||
{{ $text := $block.content.text | emojify | $page.RenderString }}
|
||||
{{ $text := $block.content.text | emojify | $page.RenderString | safeHTML }}
|
||||
|
||||
<div class="flex flex-col items-center max-w-prose mx-auto gap-3 justify-center">
|
||||
|
||||
|
@ -14,5 +14,6 @@
|
|||
{{ $title }}
|
||||
</div>
|
||||
|
||||
{{ with $text }}<p class="prose prose-slate lg:prose-xl dark:prose-invert max-w-prose">{{ . }}</p>{{ end }}
|
||||
{{/* We use DIV rather than P to support `prose` class and multiple paragraphs */}}
|
||||
{{ with $text }}<div class="prose prose-slate lg:prose-xl dark:prose-invert max-w-prose">{{ . }}</div>{{ end }}
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue