mirror of
https://github.com/imfing/hextra.git
synced 2025-05-13 07:29:39 -04:00
Compare commits
3 Commits
63c7b7cfdc
...
a28be8ffa6
Author | SHA1 | Date | |
---|---|---|---|
![]() |
a28be8ffa6 | ||
![]() |
0c90c1aa50 | ||
![]() |
f66c915d5b |
@ -10,6 +10,10 @@
|
|||||||
<title>
|
<title>
|
||||||
{{- if .IsHome -}}
|
{{- if .IsHome -}}
|
||||||
{{ .Site.Title -}}
|
{{ .Site.Title -}}
|
||||||
|
{{ else if eq .Kind "page" -}}
|
||||||
|
{{ with .Title }}{{ . }} – {{ end -}}
|
||||||
|
{{ $sectionTitle := index .Site.Params.sectionsTitles .Section }}
|
||||||
|
{{ $sectionTitle | default .Site.Title }}
|
||||||
{{ else -}}
|
{{ else -}}
|
||||||
{{ with .Title }}{{ . }} – {{ end -}}
|
{{ with .Title }}{{ . }} – {{ end -}}
|
||||||
{{ .Site.Title -}}
|
{{ .Site.Title -}}
|
||||||
|
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" -}}
|
||||||
|
{{- $heading := int (strings.TrimPrefix "h" (.Get "heading" | default "h2")) -}}
|
||||||
|
{{- $size := cond (ge $heading 4) "xl" (cond (eq $heading 3) "2xl" "4xl") -}}
|
||||||
|
|
||||||
|
<h{{ $heading }}
|
||||||
|
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{{ $heading }}>
|
Loading…
x
Reference in New Issue
Block a user