engineering blog at https://blog.tangled.sh
at master 2.8 kB view raw
1<!doctype html> 2<html lang=en> 3 <head> 4 {{ template "partials/head.html" . }} 5 <meta name="description" content="{{ index .Meta "subtitle" }}"> 6 <meta property="og:title" content="{{ .Meta.title }}" /> 7 <meta property="og:description" content="{{ .Meta.subtitle }}" /> 8 <meta property="og:url" content="https://blog.tangled.org/{{ .Meta.slug }}" /> 9 <meta property="og:image" content="https://blog.tangled.org{{ .Meta.image }}" /> 10 <meta property="og:type" content="website" /> 11 <meta property="og:image:width" content="1200" /> 12 <meta property="og:image:height" content="630" /> 13 14 <meta name="twitter:card" content="summary_large_image" /> 15 <meta name="twitter:title" content="{{ .Meta.title }}" /> 16 <meta name="twitter:description" content="{{ .Meta.subtitle }}" /> 17 <meta name="twitter:image" content="https://blog.tangled.org{{ .Meta.image }}" /> 18 19 <title> 20 {{ index .Meta "title" }} 21 </title> 22 </head> 23 <body class="bg-slate-100 dark:bg-gray-900"> 24 {{ template "partials/nav.html" }} 25 <div class="prose dark:prose-invert mx-auto px-1 pt-2 min-h-screen flex flex-col"> 26 <main> 27 28 <header> 29 <p class="post-date px-6 mb-0 text-sm"> 30 {{ $dateStr := index .Meta "date" }} 31 {{ $date := parsedate $dateStr }} 32 {{ $date.Format "02 Jan, 2006" }} 33 34 <span class="mx-2 select-none">&middot;</span> 35 36 by 37 {{ $authors := index .Meta "authors" }} 38 {{ if eq (len $authors) 2 }} 39 <a href="https://bsky.app/profile/{{ (index $authors 0).handle }}" class="no-underline">{{ (index $authors 0).name }}</a> 40 & 41 <a href="https://bsky.app/profile/{{ (index $authors 1).handle }}" class="no-underline"> 42 {{ (index $authors 1).name }} 43 </a> 44 {{ else }} 45 {{ range $author := $authors }} 46 <a href="https://bsky.app/profile/{{ $author.handle }}" class="no-underline"> 47 {{ $author.name }} 48 </a> 49 {{ end }} 50 {{ end }} 51 </p> 52 53 {{ if .Meta.draft }} 54 <h1 class="title px-6 mb-0">{{ index .Meta "title" }} <span 55 class="text-red-500">[draft]</span></h1> 56 {{ else }} 57 <h1 class="title px-6 mb-0">{{ index .Meta "title" }}</h1> 58 {{ end }} 59 <p class="italic px-6 mt-1 mb-0 text-lg">{{ index .Meta "subtitle" }}</p> 60 </header> 61 62 <article class="mt-5 bg-white dark:bg-gray-800 px-6 py-2 rounded drop-shadow-sm"> 63 {{ .Body }} 64 </article> 65 </main> 66 </div> 67 <footer class="w-full"> 68 {{ template "partials/footer.html" }} 69 </footer> 70 </body> 71 72</html>