blowfish/layouts/partials/home/hero.html

55 lines
2.9 KiB
HTML
Raw Normal View History

2022-10-10 10:23:51 -05:00
<article class="max-w-full prose dark:prose-invert">
<div class="relative">
<div class="absolute inset-x-0 bottom-0 h-1/2 bg-gray-100"></div>
<div class="mx-auto max-w-7xl p-0">
<div class="relative shadow-xl sm:overflow-hidden rounded-2xl">
<div class="absolute inset-0">
{{ $homepageImage := "" }}
{{ with .Site.Params.defaultBackgroundImage }}{{ $homepageImage = resources.Get . }}{{ end }}
{{ with .Site.Params.homepage.homepageImage }}{{ $homepageImage = resources.Get . }}{{ end }}
2022-10-20 06:15:37 -05:00
{{ if $homepageImage }}
<img class="h-full w-full object-cover m-0 nozoom" src="{{ $homepageImage.RelPermalink }}">
2022-10-11 17:40:31 -05:00
<div
class="absolute inset-0 bg-gradient-to-r from-primary-500 to-secondary-700 dark:from-primary-600 dark:to-secondary-800 mix-blend-multiply">
2022-10-10 10:23:51 -05:00
</div>
2022-10-20 06:15:37 -05:00
{{ end }}
2022-10-10 10:23:51 -05:00
</div>
<div class="relative px-4 py-16 sm:px-6 sm:py-24 lg:py-32 lg:px-8 flex flex-col items-center justify-center text-center">
2022-10-10 10:23:51 -05:00
{{ with .Site.Author.image }}
{{ $authorImage := resources.Get . }}
{{ if $authorImage }}
{{ $authorImage := $authorImage.Fill "288x288" }}
<img class="mb-2 rounded-full h-36 w-36" width="144" height="144"
alt="{{ $.Site.Author.name | default " Author" }}" src="{{ $authorImage.RelPermalink }}" />
{{ end }}
{{ end }}
2022-10-11 17:40:31 -05:00
<h1 class="mb-2 text-4xl font-extrabold text-neutral-200">
2022-10-10 10:23:51 -05:00
{{ .Site.Author.name | default .Site.Title }}
</h1>
{{ with .Site.Author.headline }}
2022-10-11 17:40:31 -05:00
<h2 class="mt-0 mb-0 text-xl text-neutral-300">
2022-10-10 10:23:51 -05:00
{{ . | markdownify | emojify }}
</h2>
{{ end }}
2022-10-11 17:40:31 -05:00
<div class="mt-1 mb-10 text-2xl">
{{ with .Site.Author.links }}
<div class="flex flex-wrap">
{{ range $links := . }}
{{ range $name, $url := $links }}
<a class="px-1 hover:text-primary-400 text-primary-300" href="{{ $url }}" target="_blank"
aria-label="{{ $name | title }}" rel="me noopener noreferrer">{{ partial
"icon.html" $name }}</a>
{{ end }}
{{ end }}
</div>
{{ end }}
2022-10-10 10:23:51 -05:00
</div>
<section class="prose dark:prose-invert">{{ .Content | emojify }}</section>
2022-10-10 10:23:51 -05:00
</div>
</div>
</div>
</div>
</article>
<section>
{{ partial "recent-articles/main.html" . }}
2022-10-11 17:40:31 -05:00
</section>