Add support for configuring a custom header image from a page's front matter, and use a new one for foundation.
24 lines
833 B
HTML
24 lines
833 B
HTML
{{ define "main" }}
|
|
{{ if .Params.HeaderImage }}
|
|
<!-- <div class="w-full h-32 bg-[center_bottom_23rem] bg-cover" -->
|
|
<!-- style="background-image: url(/img/{{ .Params.HeaderImage }})"> -->
|
|
<div class="w-full h-32 bg-[center] bg-cover"
|
|
style="background-image: url(/img/{{ .Params.HeaderImage }})">
|
|
</div>
|
|
{{ else }}
|
|
<div class="w-full h-32 bg-[url('/img/lagoon-close-02.jpg')]
|
|
bg-[center_top_30rem] bg-cover">
|
|
</div>
|
|
{{ end }}
|
|
<div class="max-w-5xl mx-auto -mt-12 py-8 px-8 text-left bg-white">
|
|
<header class="mb-8">
|
|
<h1 class="text-2xl font-bold">{{ .Title }}</h1>
|
|
{{ if .Description }}
|
|
<p class="mt-2 text-lg text-zinc-500">{{ .Description }}</p>
|
|
{{ end }}
|
|
</header>
|
|
<div class="content">
|
|
{{ .Content }}
|
|
</div>
|
|
{{ end }}
|