diff options
| author | Mitja Felicijan <mitja.felicijan@gmail.com> | 2022-08-27 14:05:48 +0200 |
|---|---|---|
| committer | Mitja Felicijan <mitja.felicijan@gmail.com> | 2022-08-27 14:05:48 +0200 |
| commit | 9f5454bda6299db43a4e9de5b3716471388b81d9 (patch) | |
| tree | 1ceedf64a4517a372d70efc2b6f4bbd9478ce792 /themes/simple/layouts/_default/single.html | |
| parent | e728c3a2cbd06d95cd1226d3b23473816bd0d67e (diff) | |
| download | mitjafelicijan.com-9f5454bda6299db43a4e9de5b3716471388b81d9.tar.gz | |
Move blog to Hugo
Diffstat (limited to 'themes/simple/layouts/_default/single.html')
| -rw-r--r-- | themes/simple/layouts/_default/single.html | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/themes/simple/layouts/_default/single.html b/themes/simple/layouts/_default/single.html new file mode 100644 index 0000000..7142f1b --- /dev/null +++ b/themes/simple/layouts/_default/single.html | |||
| @@ -0,0 +1,46 @@ | |||
| 1 | {{ define "main" }} | ||
| 2 | <main aria-role="main" class="container-blog"> | ||
| 3 | |||
| 4 | <!-- Single article --> | ||
| 5 | <article itemtype="http://schema.org/Article" class="mb-12"> | ||
| 6 | <header> | ||
| 7 | <h1 itemtype="headline" class="text-4xl font-extrabold mb-6">{{.Title}}</h1> | ||
| 8 | <time class="text-gray-400 font-medium text-sm">Published on {{ .Date.Format "Monday Jan 2, 2006" }}</time> | ||
| 9 | </header> | ||
| 10 | |||
| 11 | <div class="leading-relaxed"> | ||
| 12 | {{.Content}} | ||
| 13 | </div> | ||
| 14 | </article> | ||
| 15 | |||
| 16 | <hr class="border-2 border-gray-100 mb-10"> | ||
| 17 | |||
| 18 | <!-- Comment, contact --> | ||
| 19 | <section class="mb-10"> | ||
| 20 | <p class="mb-4"> | ||
| 21 | <strong>Comment, contact:</strong> The easiest way to contact me is by writing me a message on <a href="https://t.me/mitjafelicijan" target="_blank">Telegram (https://t.me/mitjafelicijan)</a>. | ||
| 22 | </p> | ||
| 23 | <p>You can also just write me an email at <a href="mailto:m@mitjafelicijan.com">m@mitjafelicijan.com</a>.</p> | ||
| 24 | </section> | ||
| 25 | |||
| 26 | <hr class="border-2 border-gray-100 mb-10"> | ||
| 27 | |||
| 28 | <!-- Read more --> | ||
| 29 | <section> | ||
| 30 | <h1 class="text-2xl font-bold mb-6">Read more from this site</h1> | ||
| 31 | <nav itemscope itemtype="https://schema.org/SiteNavigationElement" class="mb-12"> | ||
| 32 | <meta itemprop="name" content="Article list"> | ||
| 33 | <ul> | ||
| 34 | {{ $randomPosts := shuffle (where .Site.RegularPages "Type" "posts") | first 5 }} | ||
| 35 | {{ range $randomPosts }} | ||
| 36 | <li class="mb-3"> | ||
| 37 | <time class="block text-gray-500 text-sm">{{ .Date.Format "Mon Jan 2, 2006" }}</time> | ||
| 38 | <a href="{{.Permalink}}" itemprop="url" class="hover:bg-yellow-200">{{.Title}}</a> | ||
| 39 | </li> | ||
| 40 | {{end}} | ||
| 41 | </ul> | ||
| 42 | </nav> | ||
| 43 | </section> | ||
| 44 | |||
| 45 | </main> | ||
| 46 | {{ end }} | ||
