mirror of
https://github.com/imfing/hextra.git
synced 2025-05-13 04:46:26 -04:00
Merge 368c20e935eb96e9a6a5998c5a2941b9416b286c into fe2271b60bd34476726447fd9361aee59eb2a92f
This commit is contained in:
commit
a5a3a08dcf
10
layouts/shortcodes/hextra/hero-section.html
Normal file
10
layouts/shortcodes/hextra/hero-section.html
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
{{- $style := .Get "style" -}}
|
||||||
|
{{- $header := int (strings.TrimPrefix "h" (.Get "header" | default "h2")) -}}
|
||||||
|
{{- $size := cond (ge $header 4) "xl" (cond (eq $header 3) "2xl" "4xl") -}}
|
||||||
|
|
||||||
|
<h{{ $header }}
|
||||||
|
class="not-prose hx-text-{{ $size }} hx-font-bold hx-leading-none hx-tracking-tighter md:hx-text-3xl hx-py-2 hx-bg-clip-text hx-text-transparent hx-bg-gradient-to-r hx-from-gray-900 hx-to-gray-600 dark:hx-from-gray-100 dark:hx-to-gray-400"
|
||||||
|
{{ with $style }}style="{{ . | safeCSS }}"{{ end }}
|
||||||
|
>
|
||||||
|
{{ .Inner | markdownify }}
|
||||||
|
</h{{ $header }}>
|
Loading…
x
Reference in New Issue
Block a user