Browse Source

initial commit & drone CI test

master
jk 3 years ago
parent
commit
c1347b0405
  1. 11
      archetypes/default.md
  2. 133
      config.toml
  3. BIN
      static/fonts/forkawesome-webfont.woff2
  4. 15
      themes/nipponalba/archetypes/post.md
  5. 6
      themes/nipponalba/layouts/404.html
  6. 102
      themes/nipponalba/layouts/_default/backup_single.html
  7. 14
      themes/nipponalba/layouts/_default/baseof.html
  8. 58
      themes/nipponalba/layouts/_default/list.html
  9. 27
      themes/nipponalba/layouts/_default/list.jp.html
  10. 100
      themes/nipponalba/layouts/_default/single.html
  11. 51
      themes/nipponalba/layouts/index.html
  12. 40
      themes/nipponalba/layouts/partials/aside.html
  13. 19
      themes/nipponalba/layouts/partials/footer.html
  14. 29
      themes/nipponalba/layouts/partials/head.html
  15. 3
      themes/nipponalba/layouts/partials/image.html
  16. 7
      themes/nipponalba/layouts/partials/likes.html
  17. 30
      themes/nipponalba/layouts/partials/math.html
  18. 20
      themes/nipponalba/layouts/partials/navbar.html
  19. 7
      themes/nipponalba/layouts/partials/photo.html
  20. 5
      themes/nipponalba/layouts/partials/shares.html
  21. 3
      themes/nipponalba/layouts/partials/syndication.html
  22. 6
      themes/nipponalba/layouts/partials/taxonomy/blog.html
  23. 6
      themes/nipponalba/layouts/partials/taxonomy/categories.html
  24. 6
      themes/nipponalba/layouts/partials/taxonomy/tags.html
  25. 30
      themes/nipponalba/layouts/partials/webmention.html
  26. 1058
      themes/nipponalba/static/css/style.css

11
archetypes/default.md

@ -0,0 +1,11 @@
---
title: "{{ replace .Name "-" " " | title }}"
date: {{ .Date }}
draft: true
Blog: []
Categories: []
Tags: []
Image:
Type:
draft: false
---

133
config.toml

@ -0,0 +1,133 @@
baseURL = "https://sakino.kelbie.scot"
languageCode = "en-gb"
title = "Sakino Kelbie"
theme=["nipponalba"]
summarylength=20
enableEmoji=true
defaultContentLanguage="en"
[outputs]
home = ["html", "rss"] # default = ["HTML", "RSS"]
section = ["html", "rss"] # default = ["HTML", "RSS"]
taxonomy = ["html", "rss"] # default = ["HTML", "RSS"]
term = ["html", "rss"] # default = ["HTML", "RSS"]
[markup]
[markup.goldmark]
[markup.goldmark.extensions]
definitionList = true
footnote = true
linkify = true
strikethrough = true
table = true
taskList = true
typographer = true
[markup.goldmark.parser]
attribute = true
autoHeadingID = true
autoHeadingIDType = "github"
[markup.goldmark.renderer]
hardWraps = false
unsafe = false
xhtml = false
[taxonomies]
blog = "blog"
image = "image"
tag = "tag"
category = "category"
type = "type"
like-of = "like-of"
in-reply-to = "in-reply-to"
repost-of = "repost-of"
bookmark-of = "bookmark-of"
posttype = "posttype"
slug = "slug"
[params]
title = "Sakino's Place"
author = "Sakino Kelbie󠁧󠁢󠁳󠁣󠁴󠁿"
firstname = "Sakino"
profilePicture = "images/profile1.jpg"
siteLogo = ""
keywords = ""
favicon = "images/"
pronouns = "she/her"
[languages.en.Params]
description = "Dedicated Dad"
[languages.jp.Params]
description = "日本語の紹介を書くーQuintessentially Celtic, vehemently Viking, passionately European, unashamedly, proudly Scottish, craft beer and single malt whisky lover, enthusiastic cook, vegan, perpetually exhausted dad, pronouns: he/him"
## Social Links
[[params.socialIcons]]
icon = "fa fa-envelope-o fa-2x fa-fw"
title = "e-mail"
url = "mailto:sakino@kelbie.scot"
[languages.en]
weight = 0
languageName = "English"
[[languages.en.menu.main]]
name="Home"
weight= 100
url = "/"
[[languages.en.menu.main]]
name = "Blogs"
weight = 200
url = "/blog/"
[[languages.en.menu.main]]
name = "Articles"
weight = 300
url = "/article/"
[[languages.en.menu.main]]
name = "Notes"
weight = 400
url = "/note/"
[[languages.en.menu.main]]
name = "Photos"
weight = 500
url = "/photo/"
[[languages.en.menu.main]]
name = "Bookmarks"
weight = 600
url = "/bookmarks/"
[[languages.en.menu.main]]
name = "Résumé"
weight = 700
url = "/resume/"
identifier = "resume"
[[languages.en.menu.main]]
name = "Feeds"
weight = 800
url = "/feeds/"
identifier = "feeds"
[languages.jp]
weight = 10
languageName = "日本語"
[[languages.jp.menu.main]]
name="ホーム"
weight= 100
url = "/jp/"
[[languages.jp.menu.main]]
name = "全部のブログ"
weight = 200
url = "/jp/blog/"
[[languages.jp.menu.main]]
name = "記事"
weight = 300
url = "/jp/article/"

BIN
static/fonts/forkawesome-webfont.woff2

15
themes/nipponalba/archetypes/post.md

@ -0,0 +1,15 @@
---
title: "{{ replace .Name "-" " " | title }}"
date: {{ .Date }}
Description: ""
Blog:
-
category:
-
tag:
-
Image:
-
posttype:
draft:
---

6
themes/nipponalba/layouts/404.html

@ -0,0 +1,6 @@
{{- define "main" -}}
<div class="page_404">
<p>The page you are looking for is missing</p>
</div>
{{- end -}}

102
themes/nipponalba/layouts/_default/backup_single.html

@ -0,0 +1,102 @@
{{ define "main" }}
{{ if not (eq .Type "response" "bookmarkof")}}
<article class="post h-entry entry contents">
<div class="author" style="display:none;">
<a rel="author" class="u-author h-card" rel="me" href="https://jk.nipponalba.scot">{{ .Site.Params.Title }}<img src="/images/profile.jpg"/></a>
</div>
{{ with .Page.Params.Image }}{{ partial "taxonomy/image.html" . }}{{ end }}<h3 class="p-name entry-title">{{ .Title }}</h3><b>{{ .Description }}</b>
<aside>
{{ if eq .Type "article" }}<div class="info">
{{ with .Page.Params.Blog }}Blog: {{ partial "taxonomy/blog.html" . }}{{ end }}<span id="info-date"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></span><br/>
{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}<span class="reading-time">{{ .ReadingTime }}-minute read</span><br/>
{{ with .Page.Params.tag }}Tags: {{ partial "taxonomy/tags.html" . }}{{ end }}
</div>{{ end }}
<div class="e-content">
{{ .Content }}
{{ if eq .Type "photo"}}
<div class="photogrid">
{{ range .Page.Params.Photo }}
<a href="{{ . }}"><img class="u-photo thumb" src="{{ replace . "800." "300."}}"/></a>
{{end}}
</div>
{{end}}
{{ if eq .Type "article" }}<div class="p-summary" style="display:none">
{{ .Page.Params.summary }}<br/>
</div>
{{ end }}<br/>
</div>
{{ if not (eq .Type "article") }}<div class="info">
{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}
</div>{{ end }}
{{ $pathJSON := (print .Permalink "bridgy.json") }}
{{ $relpathJSON := (print .RelPermalink "bridgy.json") }}
{{ if fileExists $relpathJSON }}
<span class="syndication">
{{ $mJSON := getJSON $pathJSON }}
Syndicated to <a href="{{ printf $mJSON.url}}">Pleroma</a>
</span><span id="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></a></span>
{{ end }}
<a href="https://brid.gy/publish/mastodon"></a>
<div class="interactions"><h4>Interactions</h4></div>
<div class="webmention-form">
<form action="https://webmention.io/jk.nipponalba.scot/webmention" method="post">
<label>Did you mention this {{ .Type }} on your website? Put the URL of your post here:</label><br/>
<input name="source" type="url"/>
<input name="target" value="{{ .Permalink }}" type="hidden"/>
<input value="Send Webmention" type="submit"/>
</form>
</div>
{{ $pathJSON := (print "data" (strings.TrimSuffix "/" .RelPermalink) ".json") }}
{{ if fileExists $pathJSON }}
<div class="webmentions">
{{ $mJSON := getJSON $pathJSON }}
<div class="like interaction"><h4>Likes</h4>{{ partial "likes.html" $mJSON }}</div>
<div class="share interaction"><h4>Shares</h4>{{ partial "shares.html" $mJSON }}</div>
<h4>Comments & Replies</h4>{{ partial "webmention.html" $mJSON }}
</div>
{{ end }}
</aside>
</article>
{{ else if eq .Type "bookmarkof" }}
{{ $cats := slice }}
{{ range .Site.Data.bookmarks }}
{{ $cats = $cats | append .category }}
{{ end }}
{{ $cats = uniq $cats | sort }}
{{ range $cats }}
{{ $cat := . }}
<h4>{{ $cat }}</h4>
{{ range $.Site.Data.bookmarks }}
{{ if eq .category $cat }}
<section data-post-type="bookmark-of" data-post-id="{{ .Params.slug }}" class="bookmark h-entry">
<div class="author" style="display:none">
<a rel="author" class="p-author h-card" rel="me" href="https://jk.nipponalba.scot"><img src="/images/profile.jpg"/><div class="title">{{ .Site.Params.Title }}</div></a>
</div>
<aside>
<article class="h-cite">
<a href="{{ .bookmarkof | absURL }}" class="u-bookmark-of" target="_blank">{{ .name }}</a> - <div class="p-name p-content">{{ .content | markdownify }}</div>
</article>
</aside>
</section>
{{ end }}
{{ end }}
{{ end }}
{{ else }}
<article class="h-entry" id="response">
<div class="author">
<a rel="author" class="u-author h-card" rel="me" href="https://jk.nipponalba.scot"><img src="/images/profile.jpg"/><div class="title">{{ .Site.Params.Title }}</div></a>
</div>
<div>
{{ if .Params.likeof }}<p>Liked <a href="{{ .Params.likeof }}" class="u-url u-like-of"> {{ .Params.likeof }}</a>{{ end }}
{{ if .Params.inreplyto }}<p>Replied to <a href="{{ .Params.inreplyto }}" class="u-url u-in-reply-to"> {{ .Params.inreplyto }}</a>{{ end }}
{{ if .Params.repostof }}<p>Shared <a href="{{ .Params.repostof }}" class="u-url u-repost-of"> {{ .Params.repostof }}</a>{{ end }}</p>
{{ if .Content }}<div class="p-name p-content"><p>{{ .Content }}</p></div> {{end}}
</div>
{{ if not (eq .Type "article") }}<div class="info">
{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}<span id="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></a></span><br/>
</div>{{ end }}
{{end}}
{{end}}

14
themes/nipponalba/layouts/_default/baseof.html

@ -0,0 +1,14 @@
<!DOCTYPE html>
<html lang="{{- site.Language.Lang -}}">
{{- partial "head.html" . -}}
<body>
<input type="checkbox" id="theme-switch" class="theme-switch" autocomplete="on">
<section id="page">
{{ partial "navbar.html" . }}
<main>
{{- block "main" . }}{{- end }}
<aside class="profile title h-card p-author">
{{ partial "aside.html" . }}
</aside>
</main>
{{ partial "footer.html"}}

58
themes/nipponalba/layouts/_default/list.html

@ -0,0 +1,58 @@
{{ define "main" }}
<section class="archive">
<section class="archive-listing">
<span class="list-title">{{if not (eq .Name "Blog")}}{{ .Name }}{{ end }}{{if eq .Name "Blog"}}All Blogs{{ end }} <a href="{{ .Permalink }}index.xml"><i class="fa fa-rss fa-2x fa-fw" aria-hidden="true" title="{{ .Name }} RSS feed"></i></a></span>
{{ if eq .Type "article" "blog"}}<ul class="listing">{{ range .Data.Pages.GroupByDate "2006" }}
{{ range .Pages }}
<li class="archive-listing-item">
{{ if eq .Type "blog"}}
<span class="list-blog"><a class="u-url" href="{{ .Permalink }}" title="{{ .Title }}">
{{ $image := (replace .Title " " "") }}
{{ $image := print "/images/" $image ".jpg" }}
<img class="banner" src="{{ ( $image | urlize ) | relLangURL }}" />
<span class="p-name entry-title">{{ .Title }}</span></a>
</span>
{{end}}
{{ if eq .Type "article"}}
<span class="list-article h-entry entry"><a class="u-url" href="{{ .Permalink }}">
{{ with .Page.Params.Image }}{{ partial "image.html" . }}{{ end }}<span class="p-name entry-title">{{ .Title }}</span>
<section class="e-content">{{ .Description }}</section>
</a></span>
{{end}}
</li>
{{ end }}{{end}}</ul>{{else}}
<ul class="listing">
{{ range .Pages }}
<li class="archive-listing-item">
{{ if not (eq .Type "note" "photo") }}
{{ if eq .Type "article"}}
<span class="list-article h-entry entry"><a class="u-url" href="{{ .Permalink }}">
{{ with .Page.Params.Image }}{{ partial "image.html" . }}{{ end }}<span class="p-name entry-title">{{ .Title }}</span>
<section class="e-content">{{ .Description }}</section>
</a></span>
{{else}}<span class="listing-post"><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</span>{{end}}{{else}}
{{ if eq .Type "note"}}
<span class="list-category"><a class="u-url" href="{{ .Permalink }}" title="{{ .Title }}">
<span class="note-banner">{{ humanize .Type }}</span>
<span class="p-summary e-content"><p>{{ .Summary }}</p></span></a>
</span>{{else}}
<article class="list-category index-photo h-entry entry"><a class="u-url" href="{{ .Permalink }}">
<section class="e-content">
<section class="photos">
{{ range first 1 .Page.Params.Photo }}
{{ if isset . "value" }}
<img class="u-photo thumb" src="{{ replace .value "800." "300."}}" alt="{{ .alt }}"/>
{{ else }}
<img class="u-photo thumb" src="{{ replace . "800." "300."}}" alt="Alt not yet added, will fix!"/>
{{ end }}
{{end}}
</section>
</section>
</a></article>{{end}}{{end}}
</li>
{{ end }}</ul>
{{ end }}
</section>
</section>
{{ end }}

27
themes/nipponalba/layouts/_default/list.jp.html

@ -0,0 +1,27 @@
{{ define "main" }}
<section class="archive">
<span class="list-title">{{if not (eq .Name "Blog" "Categories" "Tags") }}{{ .Name }}{{ end }}{{if eq .Name "Blog"}}全部のブログ{{ end }}{{if eq .Name "Categories"}}カテゴリー{{ end }}{{if eq .Name "Tags"}}タグ{{ end }} <a href="{{ .Permalink }}index.xml"><i class="fa fa-rss fa-2x fa-fw" aria-hidden="true" title="{{ .Name }} RSS feed"></i></a></span>
<ul class="list-with-title">
{{ if eq .Type "article" "blog"}}{{ range .Data.Pages.GroupByDate "2006" }}
<span class="listing-title">{{ .Key }}</span>
{{ range .Pages }}
<ul class="listing">
<li class="listing-item">
{{ if eq .Type "article" "blog"}}
<span class="listing-post"><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a>
<time class="post-time"><span class="date">{{.Date.Format "Jan 2" }}</span></time>
</span>
{{end}}
</li>
</ul>{{ end }}{{end}}{{else}}
{{ range .Pages }}
<ul class="listing">
<li class="listing-item">
{{ if not (eq .Type "note" "photo") }}<span class="listing-post"><a href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</span>{{else}}
<span class="listing-post"><a href="{{ .Permalink }}" title="{{ .Summary }}"><b>{{ humanize .Type }}:</b> {{ .Summary }}</span>{{end}}
</li>
</ul>{{ end }}
{{ end }}
</ul>
</section>
{{ end }}

100
themes/nipponalba/layouts/_default/single.html

@ -0,0 +1,100 @@
{{ define "main" }}
{{ if not (eq .Type "response" "bookmarkof")}}
<article class="post h-entry entry contents">
<section class="author" style="display:none;">
<a rel="author" class="p-author h-card" rel="me" href="https://jon.kelbie.scot">{{ .Site.Params.Author }}<img src="/images/profile1.jpg"/></a>
</section>
{{ with .Page.Params.Image }}{{ partial "image.html" . }}{{ end }}
<section class="post_content">{{ if eq .Type "article" }}<h3 class="p-name entry-title">{{ .Title }}</h3><b>{{ .Description }}</b><section class="info">
<span class="blogs_span">{{ with .Page.Params.Blog }}Blog: {{ partial "taxonomy/blog.html" . }}{{ end }}</span><span class="info-date"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></span><br/>
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><span class="reading-time">{{ .ReadingTime }}-minute read</span><br/>
<span class="tags_span">{{ with .Page.Params.tag }}Tags: {{ partial "taxonomy/tags.html" . }}{{ end }}</span>
</section>{{ end }}
{{ if eq .Type "article" }}<section class="e-content">{{else}}<section class="e-content p-name">{{end}}
{{ .Content }}
{{ if eq .Type "photo"}}
<section class="photogrid">
{{ range .Page.Params.Photo }}
{{ if isset . "value" }}
<a href="{{ .value }}"><img class="u-photo" src="{{ .value }}" alt="{{ .alt }}"/></a>
{{ else }}
<a href="{{ . }}"><img class="u-photo" src="{{ . }}" alt=" Trying to fix"/></a>
{{end}}
{{end}}
</section>
{{end}}
{{ if eq .Type "article" }}<section class="p-summary" style="display:none">
{{ .Page.Params.summary }}<br/>
</section>
{{ end }}<br/>
</section>
<section class="info">
{{ if not (eq .Type "article") }}<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span>{{ end }}
<span class="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></a></span></section>
<hr/>
<section id="interactions"><h4>Interactions</h4>
<section id="webmention-form">
Interactions on this site are possible only via <a href="https://indieweb.org/Webmention" title="Webmention is a web standard for mentions and conversations across the web, a powerful building block that is used for a growing federated network of comments, likes, reposts, and other rich interactions across the decentralized social web." class="u-url" target="_blank">webmentions</a>. Alternatively, contact me via <a href="xmpp:jk@nipponalba.scot" class="u-url" target="_blank">xmpp</a>, <a href="https://matrix.to/#/@jk:nipponalba.scot" class="u-url" target="_blank">matrix</a> or <a href="mailto:jon@kelbie.scot" class="u-url">email</a>.<br/><br/>
<form action="https://webmention.io/jon.kelbie.scot/webmention" method="post">
<label>Did you mention this {{ .Type }} on your website? Put the URL of your post here:</label><br/>
<input name="source" type="url"/>
<input name="target" value="{{ .Permalink }}" type="hidden"/>
<input value="Send Webmention" type="submit"/>
</form>
<p>Alternatively, if you do not have a webmentions enabled website then you can leave a message using the comment parade form below.</p>
<details id="commentparade"><summary>Comment Parade</summary><p>Please copy the following and paste into the URL field below: <span class="url">{{.Permalink }}</span></p><embed type="text/html" class="commentparade" src="https://commentpara.de"></embed></details>
<p>All going well, interactions will take a few minutes to appear, possibly longer due to .. gremlins.</p>
</section>
{{ $mention_ids := index $.Site.Data.index .RelPermalink }}
{{ if isset $mention_ids 0}}
{{ $mentions := apply $mention_ids "index" $.Site.Data.mentions "." }}
{{ $mentions := sort $mentions "wm-received" }}
<section id="webmentions">
<section class="like interaction"><h4>Likes</h4>{{ range $mentions }}{{ if eq (index . "wm-property") "like-of" }}
<a href="{{ .author.url }}"><img class="remote_profile" src="{{ .author.photo }}" title="{{ .author.name }}" alt="{{ .author.name }}" /></a>{{ end}}
{{ end }}</section>
<section class="share interaction"><h4>Shares</h4>{{ range $mentions }}{{ if eq (index . "wm-property") "repost-of" }}
<a href="{{ .author.url }}"><img class="remote_profile" src="{{ .author.photo }}" title="{{ .author.name }}" alt="{{ .author.name }}" /></a>{{ end}}
{{ end }}</section>
<h4>Comments & Replies</h4>{{ partial "webmention.html" $mentions }}
</section>{{ end }}</section>
</article>
{{ else if eq .Type "bookmarkof" }}
<section class="bookmarks">{{ $cats := slice }}
{{ range .Site.Data.bookmarks }}
{{ $cats = $cats | append .category }}
{{ end }}
{{ $cats = uniq $cats | sort }}
{{ range $cats }}
{{ $cat := . }}
<section id="{{ $cat }}">
<h4>{{ $cat }}</h4>
{{ range $.Site.Data.bookmarks }}
{{ if eq .category $cat }}
<article data-post-type="bookmark-of" data-post-id="{{ .Params.slug }}" class="bookmark h-entry">
<section class="h-cite">
<a href="{{ (index . "bookmark-of") | absURL }}" class="u-bookmark-of" target="_blank">{{ .name }}</a> - <div class="p-name p-content">{{ .content | markdownify }}</div>
</section>
</article>
{{ end }}
{{ end }}</section>
{{ end }}</section>
{{ else}}
<article class="h-entry" id="response">
<section class="author" style="display:none;">
<a rel="author" class="p-author h-card" rel="me" href="https://jon.kelbie.scot">{{ .Site.Params.Author }}<img src="/images/profile1.jpg"/></a>
</section>
<section id="response-details"><br/><p class="response-top">{{ .Site.Params.Firstname }}
{{ if eq .Params.posttype "in-reply-to" }} replied to <a href="{{ index .Params "in-reply-to" }}" class="u-in-reply-to">{{ index .Params "in-reply-to" }}</a>{{ end }}
{{ if eq .Params.posttype "like-of" }} liked <a href="{{ index .Params "like-of" }}" class="u-like-of">{{ index .Params "like-of" }}</a>{{ end }}
{{ if eq .Params.posttype "repost-of" }} shared <a href="{{ index .Params "repost-of" }}" class="u-repost-of">{{ index .Params "repost-of" }}</a>{{ end }}</p>
{{ if .Content }}<span class="p-name p-content"><p>{{ .Content }}</p></span> {{end}}
{{ if not (eq .Type "article") }}<section class="info">
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><span class="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></a></span><br/>
</section>
</section>
</article>{{ end }}
{{ end }}
{{end}}

51
themes/nipponalba/layouts/index.html

@ -0,0 +1,51 @@
{{ define "main" }}
<section class="about">
<section class="h-feed">
<section class="latest_note"><h2>Latest note</h2>
{{ range (first 1 (where .Site.RegularPages "Type" "=" "note")) }}
<article class="index-note h-entry entry">
<section class="author" style="display:none;">
<a rel="author" class="p-author h-card" rel="me" href="https://jon.kelbie.scot">{{ .Site.Params.Author }}<img src="/images/profile1.jpg"/></a>
</section>
<section class="e-content">{{ .Content }}
</section>
<section class="info">
{{ if eq .Type "article" }}
<span class="blogs_span">{{ with .Page.Params.Blog }}Blog: {{ partial "taxonomy/blog.html" . }}{{ end }}</span><span class="info-date"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></span><br/>
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><span class="reading-time">{{ .ReadingTime }}-minute read</span><br/>
<span class="tags_span">{{ with .Page.Params.tag }}Tags: {{ partial "taxonomy/tags.html" . }}{{ end }}</span>
{{ else }}
<span class="categories_span">{{ with .Page.Params.category }}Categories: {{ partial "taxonomy/categories.html" . }}{{ end }}</span><span class="info-date"><a href="{{ .Permalink }}" class="u-url"><time class="dt-published" datetime="{{ .Date.Format "2 Jan 2006 15:04 GMT" }}">{{ .Date.Format "02/01/2006 15:04 GMT" }}</time></a></span><br/>
{{ end }}
</section>
</article> {{ end }}
</section>
<section class="latest_articles"><h2>Latest articles</h2>
{{ range (first 3 (where .Site.RegularPages "Type" "=" "article")) }}
<article class="index-article h-entry entry"><a class="u-url" href="{{ .Permalink }}" title="{{ .Title }}">
{{ range first 1 .Page.Params.image }} <img class="banner" src="{{ replace . "images" "images/300" }}"/>{{ end }}<span class="p-name entry-title">{{ .Title }}</span>
<section class="e-content">{{ .Description }}</section>
</a></article>{{ end }}</section>
<section class="latest_photos"><h2>Latest photos</h2>
{{ range (first 3 (where .Site.RegularPages "Type" "=" "photo")) }}
<article class="index-photo h-entry entry"><a class="u-url" href="{{ .Permalink }}">
<section class="e-content">
{{ if eq .Type "photo"}}
<section class="photos">
{{ $summary := .Content }}
{{ range first 1 .Page.Params.Photo }}
{{ if isset . "value" }}
<img class="u-photo thumb" src="{{ replace .value "800." "300."}}" title="{{$summary}}" alt="{{ .alt }}"/>
{{ else }}
<img class="u-photo thumb" src="{{ replace . "800." "300."}}" title="{{$summary}}" alt="Alt not yet added, will fix!"/>
{{ end }}
{{end}}
</section>
{{end}}
</section>
</a></article>{{ end }}</section>
<a href="https://brid.gy/publish/mastodon"></a>
</section>
</section>
{{ end }}

40
themes/nipponalba/layouts/partials/aside.html

@ -0,0 +1,40 @@
<section class="h-card p-author">
<img class="u-photo" src="{{ .Site.Params.ProfilePicture }}" alt="profile picture">
<span rel="author" class="title p-name" rel="me">{{ .Site.Params.Author }}</span><br/>
<ul class="social-links">
{{ range $item := .Site.Params.socialIcons }}
<a href="{{ $item.url | safeURL }}" rel="me" >
<i class="fa {{ $item.icon }}" aria-hidden="true" title="{{ $item.title }}"></i>
</a>
{{ end }}
<span id="session"><a href="#"><img src="images/session.png" title="Session ID QR Code" alt="Session messenger icon"/>
<span><img src="images/sessionid.png" title="Session ID QR Code" alt="Session messenger id QR code"/></span></a></span>
</ul>
<section class="description">
<h4 class="p-note">{{ .Site.Params.description }}<br/>
Pronouns: <span class="p-x-pronoun-nominative">he</span>/<span class="p-x-pronoun-oblique">him</span>/<span class="p-x-pronoun-posessive">his</span></h4>
<section class="interests">
<span class="p-category">Craft Beer</span>
<span class="p-category">Single Malt Whisky</span>
<span class="p-category">Homebrewing</span>
<span class="p-category">Scottish Politics</span>
<span class="p-category">Scottish History</span>
<span class="p-category">Japanese History</span>
<span class="p-category">Tech</span>
<span class="p-category">Veganism</span>
<span class="p-category">Cooking</span></section>
</section>
<section style="display:none">
<span class="p-country-name">Scotland or Japan</span>
<a class="u-email" rel="me" href="mailto:jon@kelbie.scot"></a>
<a class="u-url u-uid" rel="me" href="https://jon.kelbie.scot"></a>
</section>
<section class="doing">
<section class="reading h-product"><i class="fa fa-book" aria-hidden="true" target="_blank"></i> <a href="https://www.sciencedirect.com/book/9781782423317/brewing-microbiology" class="u-url" title="now reading: Brewing Microbiology"><span class="p-name">Brewing Microbiology</span><img class="u-photo" src="/images/reading/brewing-microbiology.jpg"/></a></section>
<section class="playing h-product"><i class="fa fa-gamepad" aria-hidden="true"></i> <a href="https://www.cyberpunk.net" class="u-url" target="_blank" title="now playing: Cyberpunk 2077"><span class="p-name">Cyberpunk 2077</span><img class="u-photo" src="/images/playing/cyberpunk2077.jpg"/></a></section>
<section class="watching h-product"><i class="fa fa-television" aria-hidden="true"></i> <a href="https://www.themoviedb.org/tv/63639-the-expanse" class="u-url" target="_blank" title="now watching: The Expanse"><span class="p-name">The Expanse</span><img class="u-photo" src="/images/watching/theexpanse.jpg"/></a></section>
</section>
</section>
<hr/>
<section class="site-info">&copy; {{ now.Format "2006"}} | <a href="https://creativecommons.org/licenses/by/4.0/" target="_blank">CC-BY 4.0</a> | <a href="{{ .Permalink }}index.xml"><i class="fa fa-rss fa-fw" aria-hidden="true" title="Blog RSS feed"></i></a><br/>
Made with ❤ and <a href="https://gohugo.io/">Hugo</a> by {{ .Site.Params.author }}</section>

19
themes/nipponalba/layouts/partials/footer.html

@ -0,0 +1,19 @@
</section>
<script>
// This code is only used to remember theme selection between page loads
const themeSwitch = document.querySelector('.theme-switch');
themeSwitch.checked = localStorage.getItem('switchedTheme') === 'true';
themeSwitch.addEventListener('change', function(e) {
if (e.currentTarget.checked === true) {
// Add item to localstorage
localStorage.setItem('switchedTheme', 'true');
} else {
// Remove item if theme is switched back to normal
localStorage.removeItem('switchedTheme');
}
});
</script>
</body>
</html>

29
themes/nipponalba/layouts/partials/head.html

@ -0,0 +1,29 @@
<head>
<title> {{.Title}} </title>
<meta charset="utf-8">
{{- hugo.Generator -}}
<meta name="viewport" content="width=device-width,initial-scale=1,viewport-fit=cover">
<meta name="description" content="{{ .Site.Params.description }}">
<link rel="stylesheet" href="{{ `css/style.css` | absURL }}" type="text/css">
<link rel="preload" as="font" href="https://rsms.me/inter/fonts/Inter-Regular.woff2=3.15" type="font/woff2" crossorigin="anonymous" />
<link rel="preload" as="font" href="https://rsms.me/inter/fonts/Inter-Regular.woff=3.15" type="font/woff" crossorigin="anonymous" />
<base href="{{ .Site.BaseURL }}">
<!-- indieweb stuff -->
<link rel="me" href="mailto:jon@kelbie.scot" />
<link rel="authorization_endpoint" href="https://indieauth.com/auth">
<link rel="token_endpoint" href="https://tokens.indieauth.com/token">
<link rel="webmention" href="https://webmention.io/jon.kelbie.scot/webmention" />
<link rel="pingback" href="https://webmention.io/jon.kelbie.scot/xmlrpc" />
<link rel="microsub" href="https://aperture.p3k.io/microsub/545">
<link rel="micropub" href="https://jon.kelbie.scot/api/index.php">
<link href="https://jon.kelbie.scot/api/media-endpoint.php" rel="media_endpoint"/>
<link rel="micropub_media" href="https://jon.kelbie.scot/api/media-endpoint.php"/>
<link rel="pgpkey" href="/jon-kelbie-scot-key.txt">
<!-- Favicons -->
<link rel="icon" type="image/png" sizes="32x32 16x16" href="{{ .Site.Params.favicon | absURL }}favicon.ico">
<link rel="alternate" type="application/atom+xml" href="http://jon.kelbie.scot/atom.xml" rel="self" />
<meta name="msapplication-TileColor" content="#da532c">
<meta name="theme-color" content="#ffffff">
<link rel="canonical" href="{{ .Permalink }}">
</head>

3
themes/nipponalba/layouts/partials/image.html

@ -0,0 +1,3 @@
{{- range $index, $el := . -}}
<img class="banner" src="{{ ( printf "%s" ( . | urlize ) ) | relLangURL }}"/>
{{ end }}

7
themes/nipponalba/layouts/partials/likes.html

@ -0,0 +1,7 @@
{{ range . }}
{{ $_wm_property := "wm-property" }}
{{ .Params.wm_property }}
{{ if eq "wm-property" "life-of"}}
<a href="{{ .author.url }}"><img class="remote_profile" src="{{ .author.photo }}" title="{{ .author.name }}" alt="{{ .author.name }}" /></a>
{{ end }}
{{ end }}

30
themes/nipponalba/layouts/partials/math.html

@ -0,0 +1,30 @@
{{- if or (eq site.Params.math true) (eq .Params.math true) -}}
{{- $use := "katex" -}}
{{- with site.Params.math -}}
{{- if and (isset . "use") (eq (.use | lower) "mathjax") -}}
{{- $use = "mathjax" -}}
{{- end -}}
{{- end -}}
{{- if eq $use "mathjax" -}}
{{- $url := "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/MathJax.js?config=TeX-AMS-MML_HTMLorMML" -}}
{{- $hash := "sha384-e/4/LvThKH1gwzXhdbY2AsjR3rm7LHWyhIG5C0jiRfn8AN2eTN5ILeztWw0H9jmN" -}}
<script defer type="text/javascript" src="{{- $url -}}" integrity="{{- $hash -}}" crossorigin="anonymous"></script>
<script
type="text/x-mathjax-config">MathJax.Hub.Config({ tex2jax: { inlineMath: [['$','$'], ['\\(','\\)']] } });</script>
{{- else -}}
{{- $url := "https://cdn.jsdelivr.net/npm/katex@0.11.1/dist/katex.min.css" -}}
{{- $hash := "sha384-zB1R0rpPzHqg7Kpt0Aljp8JPLqbXI3bhnPWROx27a9N0Ll6ZP/+DiW/UqRcLbRjq" -}}
<link rel="stylesheet" href="{{- $url -}}" integrity="{{- $hash -}}" crossorigin="anonymous">
{{- $url := "https://cdn.jsdelivr.net/npm/katex@0.11.1/dist/katex.min.js" -}}
{{- $hash := "sha384-y23I5Q6l+B6vatafAwxRu/0oK/79VlbSz7Q9aiSZUvyWYIYsd+qj+o24G5ZU2zJz" -}}
<script defer src="{{- $url -}}" integrity="{{- $hash -}}" crossorigin="anonymous"></script>
{{- $url := "https://cdn.jsdelivr.net/npm/katex@0.11.1/dist/contrib/auto-render.min.js" -}}
{{- $hash := "sha384-kWPLUVMOks5AQFrykwIup5lo0m3iMkkHrD0uJ4H5cjeGihAutqP0yW0J6dpFiVkI" -}}
<script defer src="{{- $url -}}" integrity="{{- $hash -}}" crossorigin="anonymous"
onload="renderMathInElement(document.body);"></script>
{{- end -}}
{{- end -}}

20
themes/nipponalba/layouts/partials/navbar.html

@ -0,0 +1,20 @@
<header id="page-top">
<nav>
{{ $currentPage := . }}
{{ range .Site.Menus.main }}
<li id="{{ .Name }}"><a {{if or ($currentPage.IsMenuCurrent "main" .) ($currentPage.HasMenuCurrent "main" .) }}class="current"{{end}} href="{{ .URL }}" title="{{ .Name }}">{{ .Name }}</a></li>
{{ end }}
{{ if .IsTranslated }}
{{ range .Translations }}
<li><a rel="alternate" href="{{ .RelPermalink }}" hreflang="{{ .Lang }}" lang="{{ .Lang }}">{{ .Language.LanguageName }}<i class="fa fa-language fa-2x language" aria-hidden="true" title="Language"></i></a></li>
{{ end }}
{{ else }}
{{ range .Site.Languages }}
{{ if ne $.Site.Language.Lang .Lang }}
<li><a rel="alternate" href="{{ .Lang | relURL }}" hreflang="{{ .Lang }}" lang="{{ .Lang }}">{{ .LanguageName }} <i class="fa fa-language fa-2x language" aria-hidden="true" title="言語"></i></a></li>
{{ end }}
{{ end }}
{{ end }}
<li><label for="theme-switch"><i class="fa fa-adjust fa-2x light" aria-hidden="true" title="light/dark mode switch"></i></label></li>
</nav>
</header>

7
themes/nipponalba/layouts/partials/photo.html

@ -0,0 +1,7 @@
<span class="separator">
{{- range $index, $el := . -}}
<a href="{{printf "$s" ( . | urlize) | relLangURL }}"><img class="p-photo" src="{{ printf "$s" ( . | urlize ) | relLangURL }}" /></a>
{{- end -}}
</span>

5
themes/nipponalba/layouts/partials/shares.html

@ -0,0 +1,5 @@
{{ range . }}
{{ if eq .mention_type "repost" }}
<a href="{{ .author.url }}"><img class="remote_profile" src="{{ .author.photo_url }}" title="{{ .author.name }}" alt="{{ .author.name }}" /></a>
{{ end }}
{{ end }}

3
themes/nipponalba/layouts/partials/syndication.html

@ -0,0 +1,3 @@
{{ range . }}
Syndicated to <a href="{{ .url }}">Pleroma</a>
{{ end }}

6
themes/nipponalba/layouts/partials/taxonomy/blog.html

@ -0,0 +1,6 @@
<span class="separator">
{{- range $index, $el := . -}}
<a class="blog" href="{{ ( printf "blog/%s/" ( . | urlize ) ) | relLangURL }}">{{ . }}</a>
{{- end -}}
</span>

6
themes/nipponalba/layouts/partials/taxonomy/categories.html

@ -0,0 +1,6 @@
<ul class="categories">
{{- range $index, $el := . -}}
<li><a class="category p-category" href="{{ ( printf "category/%s/" ( . | urlize ) ) | relLangURL }}">{{ . }}</a></li>
{{- end -}}
</ul>

6
themes/nipponalba/layouts/partials/taxonomy/tags.html

@ -0,0 +1,6 @@
<ul class="tags">
{{- range $index, $el := . -}}
<li><a class="tag" href="{{ ( printf "tag/%s/" ( . | urlize ) ) | relLangURL }}">{{ . }}</a></li>
{{- end -}}
</ul>

30
themes/nipponalba/layouts/partials/webmention.html

@ -0,0 +1,30 @@
{{ range sort . "published" "asc" }}
{{ if eq (index . "wm-property") "mention" }}
<section class="mention interaction"><span class="remote_profile"><a href="{{ .author.url }}"><img src="{{ .author.photo }}" /></a></span><section class="intcontent"><span class="intactivity"><a href="{{ .author.url }}">{{ .author.name }}</a> mentioned this post in <a href="{{ .url }}">the post {{ .title }}</a></span>
{{ if .content.html }}
{{ .content.html | safeHTML }}
{{ else }}
<p>{{ .content.text | safeHTML }}</p>
{{ end }}
{{ if not (eq .published nil)}}
<time>{{ dateFormat "02/01/2006 15:04 GMT" ( time .published ) }}</time></section></section>
{{ else }}
<time>{{ dateFormat "02/01/2006 15:04 GMT" ( time (index . "wm-received") ) }}</time></section></section>
{{ end }}
{{ end }}
{{ if eq (index . "wm-property") "in-reply-to" }}
<section class="reply interaction"><span class="remote_profile"><a href="{{ .author.url }}"><img src="{{ .author.photo }}" /></a></span><section class="intcontent"><span class="intactivity"><a href="{{ .author.url }}">{{ .author.name }}</a> replied to this post <a href="{{ .url }}">here</a><br/></span>
{{ if .content.html }}
{{ .content.html | safeHTML }}
{{ else }}
<p>{{ .content.text | safeHTML }}</p>
{{ end }}
{{ if not (eq .published nil) }}
<time>{{ dateFormat "02/01/2006 15:04 GMT" ( time .published ) }}</time></section></section>
{{ else }}
<time>{{ dateFormat "02/01/2006 15:04 GMT" ( time (index . "wm-received") ) }}</time></section></section>
{{ end }}{{ end }}
{{ if eq (index . "wm-property") "bookmark" }}
<section class="bookmark interaction"><a href="{{ .author.url }}"><img class="remote_profile" src="{{ .author.photo }}" /></a><a href="{{ .author.url }}">{{ .author.name }}</a> bookmarked this post</section>
{{ end }}
{{ end }}

1058
themes/nipponalba/static/css/style.css
File diff suppressed because it is too large
View File

Loading…
Cancel
Save