mirror of
https://git.sr.ht/~seirdy/seirdy.one
synced 2024-12-18 06:42:10 +00:00
1e7b2008e8
Inspired by the h-entry implementation on Charlie Owen's personal website: https://whalecoiner.com The u-photo re-uses the 32px favicon that the browser has already cached, so it shouldn't bloat up the page anymore. These changes required a bit of additional CSS. I snuck in come color changes too.
30 lines
1.9 KiB
HTML
30 lines
1.9 KiB
HTML
{{ define "main" }}
|
||
<div itemscope itemtype="https://schema.org/Article" class="h-entry">
|
||
<article itemprop="mainEntityOfPage">
|
||
<header id="post-header">
|
||
<h1 itemprop="name headline" class="p-name">{{ .Title }}</h1>
|
||
{{ $lastmod := .Lastmod -}}
|
||
{{ if lt .Date $lastmod -}}
|
||
Originally posted <a class="u-url" href="https://seirdy.one{{ .RelPermalink }}"><time class="dt-published" itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">{{ .Date.Format "2006-01-02" }}</time></a> by {{- partial "indieweb-author.html" -}}.<br>
|
||
Last updated <time itemprop="dateModified" class="dt-updated" datetime="{{ $lastmod.Format "2006-01-02T15:04:05Z07:00" }}">{{ .Lastmod.Format "2006-01-02" }}</time>. <a href="{{ .Site.Params.logUrlPrefix }}content/{{ .File.Path }}">Changelog</a>
|
||
{{ else -}}
|
||
Posted <a class="u-url" href="https://seirdy.one{{ .RelPermalink }}"><time itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">{{ .Date.Format "2006-01-02" }}</time></a> by {{- partial "indieweb-author.html" -}}.
|
||
{{ end }}
|
||
</header>
|
||
<section class="e-content" itemprop="articlebody">
|
||
{{ .Content -}}
|
||
</section>
|
||
</article>
|
||
<br>
|
||
<hr>
|
||
<footer class="comment">
|
||
{{ with .OutputFormats.Get "gemtext" -}}
|
||
<p>
|
||
View this article on <a rel="syndication" class="u-syndication" href="{{replace .Permalink "/gemini" "" 1 | safeURL}}">my Gemini capsule</a>
|
||
</p>
|
||
{{ end -}}
|
||
<p><a href="mailto:~seirdy/seirdy.one-comments@lists.sr.ht">Send an email</a> to leave a comment in the <a href="https://lists.sr.ht/~seirdy/seirdy.one-comments">mailing list</a> for seirdy.one. You'll have to send in plain text; please <a href="https://useplaintext.email/">learn how.</a>. Alternatively, send your email <a href="mailto:seirdy@seirdy.one">directly to me</a>; it won’t show up on the mailing list, but I’ll see it.</p>
|
||
</footer>
|
||
</div>
|
||
<hr>
|
||
{{ end }}
|