diff options
author | Benjamin Chausse <benjamin@chausse.xyz> | 2023-11-14 17:14:20 -0500 |
---|---|---|
committer | Benjamin Chausse <benjamin@chausse.xyz> | 2023-11-14 17:14:20 -0500 |
commit | 81618e8bb6f00b3b74c30c1cc75a782cf266efd6 (patch) | |
tree | 3c2e85db1c401471004e5ca1241fa54e707c989f /themes |
initial commit
Diffstat (limited to 'themes')
26 files changed, 715 insertions, 0 deletions
diff --git a/themes/cranky/.gitignore b/themes/cranky/.gitignore new file mode 100644 index 0000000..9a8a3fc --- /dev/null +++ b/themes/cranky/.gitignore @@ -0,0 +1,2 @@ +# No ctags plz +tags diff --git a/themes/cranky/README.md b/themes/cranky/README.md new file mode 100644 index 0000000..58959fa --- /dev/null +++ b/themes/cranky/README.md @@ -0,0 +1,33 @@ +# Cranky hugo theme (based on lukesmithxyz/lugo) + +A simple Hugo theme I plan on using for my personal website. +I plan to do lot's of things: + +- Study +- Work on home projects +- Take photos +- Blog + +I want a website that handles it all. Projects should be part of some +portfolio I can showcase. Photos should have a dedicated photography +section. My posts shouldn't get mixed with my portfolio. + +This theme aims to do these three things in one simple package. + +## get started + +```sh +hugo new site new-site +cd new-site +git clone https://github.com/lukesmithxyz/lugo themes/lugo +echo "theme = 'cranky'" >> config.toml +cp themes/lugo/static/style.css static/ +``` + +## stuff + +- Makes one RSS feed for the entire site at `/index.xml` +- Stylesheet is in `/style.css` and includes some important stuff for partials. +- If a post is tagged, links to the tags are placed at the bottom of the post. +- `nextprev.html` adds links to the Next and Previous articles to the bottom of a page. +- `taglist.html` links all tags an article is tagged to for related content. diff --git a/themes/cranky/archetypes/default.md b/themes/cranky/archetypes/default.md new file mode 100644 index 0000000..1540cb3 --- /dev/null +++ b/themes/cranky/archetypes/default.md @@ -0,0 +1,6 @@ +--- +title: "{{ replace .Name "-" " " | title }}" +author: 'Benjamin Chausse' +date: {{ .Date }} +draft: true +--- diff --git a/themes/cranky/archetypes/projects.md b/themes/cranky/archetypes/projects.md new file mode 100644 index 0000000..49842d0 --- /dev/null +++ b/themes/cranky/archetypes/projects.md @@ -0,0 +1,8 @@ +--- +title: "{{ replace .Name "-" " " | title }}" +date: {{ .Date }} +tags: ['Shool Projects'] +draft: true +--- + +Your first paraph will be a short summary on the Projects page. diff --git a/themes/cranky/config.toml b/themes/cranky/config.toml new file mode 100644 index 0000000..e884199 --- /dev/null +++ b/themes/cranky/config.toml @@ -0,0 +1,17 @@ +title = "Website Name" +baseURL = 'https://example.org' +languageCode = 'en-us' + +[params] + # "relatedtext" is the text that appears above the tag list at the bottom of pages. + relatedtext = "Related" + favicon = "/favicon.ico" + + #list items + datesinlist = true + authorsinlist = true + + #footer items + nextprev = true + taglist = true + showrss = true
\ No newline at end of file diff --git a/themes/cranky/layouts/404.html b/themes/cranky/layouts/404.html new file mode 100644 index 0000000..8451d1c --- /dev/null +++ b/themes/cranky/layouts/404.html @@ -0,0 +1,69 @@ +<!doctype html> +<html lang="en"> + <head> + <meta charset="UTF-8" /> + <title>404 | Chause Benjamin</title> + <meta name="apple-mobile-web-app-title" content="Chausse Benjamin" /> + <meta name="application-name" content="Chausse Benjamin" /> + <meta name="msapplication-TileColor" content="#222d32" /> + <meta name="theme-color" content="#222d32" /> + </head> + <body> + <div class="sad">¯\_(ツ)_/¯</div> + <p class="error-message"> + Your web search ran into a problem and you should go back to my home page. + <br /> + <br /> + If you'd like to know more, you can search online for this error: + <a href="https://en.wikipedia.org/wiki/HTTP_404">404-Page not found</a> + <br /> + You can also scan the QR code below to for a quick diagnostic: + <br /> + <img + src="/qr-diag.png" + alt="QR Code" + class="qrcode" + style="width: 200px" + /> + <br /> + We are collecting no info and will not restart for you. + <br /> + <br /> + You can return to my home page by + <a href="/"> Clicking Here</a>. + </p> + </body> +</html> + +<style> + body { + font-family: sans-serif; + background-color: #0075d1; + color: #f2f2f2; + } + + .sad { + font-size: 140px; + margin-top: 40px; + margin-left: 40px; + } + .qrcode { + font-family: monospace; + margin: 0; + padding: 0; + } + .error-message { + margin-bottom: 0px; + margin-left: 16px; + font-size: 21px; + } + + .speech { + display: grid; + grid-template-columns: auto, 1fr; + } + + a { + color: #f2f2a2; + } +</style> diff --git a/themes/cranky/layouts/_default/baseof.html b/themes/cranky/layouts/_default/baseof.html new file mode 100644 index 0000000..57e17ce --- /dev/null +++ b/themes/cranky/layouts/_default/baseof.html @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html lang="{{ .Site.Language }}"> +<head> + <title>{{ if not .IsHome }}{{ .Title | title }} | {{ end }}{{ .Site.Title }}</title> + <link rel="canonical" href="{{ .Site.BaseURL }}"> + <link rel='alternate' type='application/rss+xml' title="{{ .Site.Title }} RSS" href='/index.xml'> + <link rel='stylesheet' type='text/css' href='/style.css'> + {{ with .Site.Params.favicon }}<link rel="icon" href="{{ . }}"> + {{ end -}} + <meta name="description" content="{{ with .Params.description }}{{ . }}{{ else }}{{ .Summary }}{{ end }}"> + {{ if isset .Params "tags" }}<meta name="keywords" content="{{ with .Params.tags }}{{ delimit . ", " }}{{ end }}"> + {{ end -}} + <meta name="viewport" content="width=device-width, initial-scale=1"> + <meta name="robots" content="index, follow"> + <meta charset="utf-8"> +</head> +<body> +{{ if .Site.Menus.main }}{{ partial "nav.html" . }}{{ end -}} +<main> +<header><h1 id="tag_{{ .Title }}">{{ block "title" . }}{{ end }}</h1></header> +<article> +{{ block "main" . }} +{{ .Content }} +{{ end }} +{{ if .Param "nextprev" }}{{ partial "nextprev.html" . -}}{{ end -}} +{{ if .Param "taglist" }}{{ partial "taglist.html" . }}{{ end -}} +</article> +</main> +{{ block "footer" . }} +<footer> + <a href="{{ .Site.BaseURL }}">{{ .Site.BaseURL }}</a> + {{- if .Param "showrss" }}<br><br><a href="/index.xml"><img src="/rss.svg" style="max-height:1.5em" alt="RSS Feed" title="Subscribe via RSS for updates."></a>{{ end }} +</footer> +{{ end }} +</body> +</html> diff --git a/themes/cranky/layouts/_default/list.html b/themes/cranky/layouts/_default/list.html new file mode 100644 index 0000000..ada7939 --- /dev/null +++ b/themes/cranky/layouts/_default/list.html @@ -0,0 +1,28 @@ +{{ define "title" -}} +{{ .Title | title }} +{{- end }} +{{ define "main" -}} +{{ .Content }} +<div class="post-list"> +{{- range.Pages }} +<div class="post-item"> + + <a href="{{ .RelPermalink }}">{{ .Title }}</a><br> + <small class="post-summary">{{ .Summary | truncate 220 " ..." }} </small> + <small class="post-date"> + {{- if .Param "datesinlist" }} + <br> + <time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}"> + {{ .Date.Format "(2006-01-02)" }}</time> + {{ end -}} + </small> + {{- if .Param "authorsinlist" }} + {{ with .Params.authors }} + by + {{ delimit . ", " " and " }} + {{end}} + {{ end -}} +</div> +{{- end }} +</div> +{{- end }} diff --git a/themes/cranky/layouts/_default/rss.xml b/themes/cranky/layouts/_default/rss.xml new file mode 100644 index 0000000..38dbe3d --- /dev/null +++ b/themes/cranky/layouts/_default/rss.xml @@ -0,0 +1,26 @@ +<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"> + <channel> + <title>{{ .Site.Title }}</title> + <link>{{ .Permalink }}</link> + <description>Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{.}} {{ end }}{{ end }}on {{ .Site.Title }}</description> + <generator>Hugo -- gohugo.io</generator>{{ with .Site.LanguageCode }} + <language>{{.}}</language>{{end}}{{ with .Site.Author.email }} + <managingEditor>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</managingEditor>{{end}}{{ with .Site.Author.email }} + <webMaster>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</webMaster>{{end}}{{ with .Site.Copyright }} + <copyright>{{.}}</copyright>{{end}}{{ if not .Date.IsZero }} + <lastBuildDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }} + {{ with .OutputFormats.Get "RSS" }} + {{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }} + {{ end }} + {{ range .Site.RegularPages }} + <item> + <title>{{ .Title }}</title> + <link>{{ .Permalink }}</link> + <pubDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</pubDate> + {{ with .Site.Author.email }}<author>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</author>{{end}} + <guid>{{ .Permalink }}</guid> + <description>{{- .Content | html -}}</description> + </item> + {{ end }} + </channel> +</rss> diff --git a/themes/cranky/layouts/_default/single.html b/themes/cranky/layouts/_default/single.html new file mode 100644 index 0000000..56c5a11 --- /dev/null +++ b/themes/cranky/layouts/_default/single.html @@ -0,0 +1,3 @@ +{{ define "title" -}} +{{ .Title }} +{{- end }} diff --git a/themes/cranky/layouts/baseof.html b/themes/cranky/layouts/baseof.html new file mode 100644 index 0000000..10a6263 --- /dev/null +++ b/themes/cranky/layouts/baseof.html @@ -0,0 +1,82 @@ +<!DOCTYPE html> +<html lang="{{ .Site.Language }}"> +<head> + <title>{{ if not .IsHome }}{{ .Title | title }} | {{ end }}{{ .Site.Title }}</title> + <link rel="canonical" href="{{ .Site.BaseURL }}"> + <link rel='alternate' type='application/rss+xml' title="{{ .Site.Title }} RSS" href='/index.xml'> + <link rel='stylesheet' type='text/css' href='/style.css'> + {{ with .Site.Params.favicon }}<link rel="icon" href="{{ . }}"> + {{ end -}} + <meta name="description" content="{{ with .Params.description }}{{ . }}{{ else }}{{ .Summary }}{{ end }}"> + {{ if isset .Params "tags" }}<meta name="keywords" content="{{ with .Params.tags }}{{ delimit . ", " }}{{ end }}"> + {{ end -}} + <meta name="viewport" content="width=device-width, initial-scale=1"> + <meta name="robots" content="index, follow"> + <meta charset="utf-8"> +</head> +<body> +{{ if .Site.Menus.main }}{{ partial "nav.html" . }}{{ end -}} +<main> +<header> + + <img src="/logo.png" style="max-width:500px;display:block;margin-left:auto;margin-right:auto;margin-bottom:0px;width:50%"> + <h1 id="tag_{{ .Title }}" style="margin-top:-30px;position:relative;">{{ block "title" . }}{{ end }}</h1> +<nav> + <div class="nav-bar"> + <a class="button" href="#about" class="section-link">About Me</a> + <a class="button" href="/projects" class="page-link">Projects</a> + <a class="button" href="/photography" class="page-link">Photography</a> + <a class="button" href="/blog" class="page-link">Posts</a> + <a class="button" href="https://git.chausse.xyz" class="page-link">Git</a> + <a class="button" href="#contact" class="section-link">Contact</a> + </div> +</nav> +</header> +<article> +{{ block "main" . }} +{{ .Content }} +{{ end }} +{{ if .Param "nextprev" }}{{ partial "nextprev.html" . -}}{{ end -}} +{{ if .Param "taglist" }}{{ partial "taglist.html" . }}{{ end -}} +</article> +</main> +{{ block "footer" . }} +<footer> + <a href="{{ .Site.BaseURL }}">{{ .Site.BaseURL }}</a> + {{- if .Param "showrss" }}<br><br><a href="/index.xml"><img src="/rss.svg" style="max-height:1.5em" alt="RSS Feed" title="Subscribe via RSS for updates."></a>{{ end }} +</footer> +{{ end }} +</body> + <style> + .nav-logo { + width: 60px; + margin: auto; + display: block; + } + .nav-bar { + top: 0; + left: 0; + width: 100%; + height: 50px; + display: flex; + flex-wrap: wrap; + justify-content: center; + align-items: center; + z-index: 100; + margin-bottom: 20px; + } + + .button { + background-image: linear-gradient(45deg, #111a1f, #222d32); + color: #808a8e; + margin: 0 5px; + margin-bottom: 10px; + padding: 5px 10px; + border-radius: 5px; + transition: 0.4s ease; + } + .button:hover { + color: #ebcb88; + } + </style> +</html> diff --git a/themes/cranky/layouts/list.html b/themes/cranky/layouts/list.html new file mode 100644 index 0000000..1ef8cfc --- /dev/null +++ b/themes/cranky/layouts/list.html @@ -0,0 +1,5 @@ +{{ define "title" -}} {{ .Title | title }} {{- end }} {{ define "main" -}} {{ +.Content }} +<!--div that spans .5vw for id links to work better --> +<div style="padding-bottom: 100%; visibility: none"></div> +{{- end }} diff --git a/themes/cranky/layouts/partials/nav.html b/themes/cranky/layouts/partials/nav.html new file mode 100644 index 0000000..a7318fe --- /dev/null +++ b/themes/cranky/layouts/partials/nav.html @@ -0,0 +1,8 @@ +<nav> + <ul> + {{- $sec := .Page.Section }}{{ $file := .File.TranslationBaseName -}} + {{ range.Site.Menus.main.ByWeight }}{{ $base := path.Base .URL }} + <li><a {{ if or ( eq $sec $base ) ( eq $file $base ) ( and (eq $sec "") ( eq $file "_index") (eq $base "/") ) }}class="menuactive" {{ end }}href="{{ .URL }}"><span class=pre>{{ .Pre }}</span><span class=menuname>{{ .Name }}</span></a></li> + {{- end }} + </ul> +</nav> diff --git a/themes/cranky/layouts/partials/nextprev.html b/themes/cranky/layouts/partials/nextprev.html new file mode 100644 index 0000000..099f16d --- /dev/null +++ b/themes/cranky/layouts/partials/nextprev.html @@ -0,0 +1,10 @@ +{{ if or .Next .Prev -}} +<div id="nextprev"> +{{- with .Prev }} +<a href="{{ .RelPermalink}}"><div id="prevart">Previous:<br>{{.Title}}</div></a> +{{ end -}} +{{- with .Next -}} +<a href="{{ .RelPermalink}}"><div id="nextart">Next:<br>{{.Title}}</div></a> +{{ end -}} +</div> +{{ end -}} diff --git a/themes/cranky/layouts/partials/taglist.html b/themes/cranky/layouts/partials/taglist.html new file mode 100644 index 0000000..757db6f --- /dev/null +++ b/themes/cranky/layouts/partials/taglist.html @@ -0,0 +1,13 @@ + {{- if isset .Params "tags" -}} + {{- $tagsLen := len .Params.tags -}} + {{- if gt $tagsLen 0 -}} + <div style="clear:both" class=taglist> + {{- with .Site.Params.relatedtext }}{{ . }}<br>{{ end -}} + {{- range $k, $v := .Params.tags -}} + {{- $url := printf "tags/%s" (. | urlize | lower) -}} + <a id="tag_{{ . | lower }}" href="{{ $url | absURL }}">{{ . | title }}</a> + {{- if lt $k (sub $tagsLen 1) }} · {{ end -}} + {{- end -}} + </div> + {{- end -}} + {{- end }} diff --git a/themes/cranky/layouts/photography/list.html b/themes/cranky/layouts/photography/list.html new file mode 100644 index 0000000..77a4a24 --- /dev/null +++ b/themes/cranky/layouts/photography/list.html @@ -0,0 +1,16 @@ +{{ define "title" -}} {{ .Title | title }} {{- end }} {{ define "main" -}} {{ +.Content }} +<!-- Match all files in the gallery folder which are images --> +<div class="photo-gallery"> + {{- range sort (resources.Match "images/gallery/*") "Name" "desc" -}} {{ + $image := . }} {{ $small := $image.Resize "300x webp" }} + <a href="{{ .RelPermalink }}" class="photo-item"> + <img + src="{{ $small.RelPermalink }}" + alt="{{ $image.Name }}" + loading="lazy" + /> + </a> + {{ end -}} +</div> +{{- end }} diff --git a/themes/cranky/layouts/projects/list.html b/themes/cranky/layouts/projects/list.html new file mode 100644 index 0000000..9dc5286 --- /dev/null +++ b/themes/cranky/layouts/projects/list.html @@ -0,0 +1,96 @@ +{{ define "title" -}} +{{ .Title | title }} +{{- end }} +{{ define "main" -}} +{{ .Content }} +<style> +time { + float: right; + font-size: 0.8em; + color: var(--light-fg); +} + +.project-title { + font-size: 1.2em; + color: var(--header-fg); + text-decoration: none; +} + +.project-box > * { + margin-left: 5px; + margin-right: 5px; +} + +.project-box { + margin-bottom: 1em; + padding: 7px; + border-radius: 10px; + position: relative; + box-shadow: 0 0 50px rgba(0, 0, 0, 0.5); + background: linear-gradient( + 45deg, + #222d32, + #111a1f + ); + z-index: 1; +} + +.project-box::before { + position: absolute; + content: ''; + top: 0; + right: 0; + bottom: 0; + left: 0; + background: linear-gradient( + 45deg, + #111a1f, + #222d32 + ); + border-radius: 10px; + z-index: -1; + transition: opacity 0.5s linear; + opacity: 0; +} + +.project-box:hover::before { + opacity: 1; +} +/* Align the read more link to the bottom right corner of the box */ +.read-more { + position: absolute; + bottom: 0; + right: 0; + margin: 5px; + font-size: 0.8em; + color: var(--header-fg); + transition: color 0.5s ease-out; + text-decoration: none; + padding: 5px; + border-radius: 7px; + background: linear-gradient( + -45deg, + #a84, + #223 + ); +} +.read-more:hover { + color: var(--link-fg-std); +} +</style> +{{- range.Pages }} +<div class="project-box"> + <a class="project-title" href="{{ .RelPermalink }}">{{ .Title }}</a> + {{- if .Param "datesinlist" }}<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">{{ .Date.Format "2006 Jan 02" }}</time> {{ end -}} + {{ $summary := index (split .Content "</p>") 0 }} + <p>{{ $summary | plainify }} </p> + {{- if .Param "authorsinlist" }} + {{ with .Params.authors }} + by + {{ delimit . ", " " and " }} + {{end}} + <a class="read-more" href="{{ .RelPermalink }}">Read more...</a> +</div> + {{ end -}} +{{- end }} +{{- end }} diff --git a/themes/cranky/layouts/shortcodes/hidvid.html b/themes/cranky/layouts/shortcodes/hidvid.html new file mode 100644 index 0000000..14f592d --- /dev/null +++ b/themes/cranky/layouts/shortcodes/hidvid.html @@ -0,0 +1,10 @@ +<details> + <summary>Click to reveal video.</summary> +<iframe src="{{ index .Params 0 }}" + loading="lazy" + sandbox="allow-same-origin allow-scripts allow-popups" + allowfullscreen frameborder="0" + class="embvid" + title="Embedded Video"> +</iframe> +</details> diff --git a/themes/cranky/layouts/shortcodes/img.html b/themes/cranky/layouts/shortcodes/img.html new file mode 100644 index 0000000..ff7959b --- /dev/null +++ b/themes/cranky/layouts/shortcodes/img.html @@ -0,0 +1,20 @@ +<!-- + class: class of the figure + link: url the image directs to + alt: alternative text + caption: caption + mouse: what the image says when moused over ("title" in HTML) +--> +<figure {{ with .Get "class" }}class="{{.}}"{{ end -}}> + {{- with .Get "link"}}<a href="{{.}}">{{ end -}} + <img src="{{ .Get "src" }}" + {{- with .Get "mouse" }} title="{{.}}"{{ end -}} + {{- with .Get "alt" }} alt="{{.}}"{{ end -}} + > + {{- if .Get "link"}}</a>{{ end -}} + {{- with .Get "caption" -}} + <figcaption> + {{- . -}} + </figcaption> + {{- end -}} +</figure> diff --git a/themes/cranky/layouts/shortcodes/prj.html b/themes/cranky/layouts/shortcodes/prj.html new file mode 100644 index 0000000..246a8e1 --- /dev/null +++ b/themes/cranky/layouts/shortcodes/prj.html @@ -0,0 +1,116 @@ +<div class="container"> + <!-- Loop through all projects --> + {{ range first 3 (where .Site.RegularPages "Section" "projects") }} + <a class="card" href="{{ .Permalink }}"> + <h3 class="title">{{ .Title }}</h3> + <div class="bar"> + <div class="emptybar"></div> + <div class="filledbar"></div> + </div> + <p class="summary">{{ .Summary | truncate 220 "..." }}</p> + </a> + <!-- End the loop --> + {{ end }} +</div> +<a class="button projects" href="/projects">More Projects</a> +<style> + .container { + position: relative; + height: auto; + width: 600px; + left: calc(50% - 300px); + display: flex; + margin-bottom: 30px; + } + + .card { + display: flex; + height: auto; + width: 230px; + margin-top: 20px; + /* background-color: #222d32; */ + background: linear-gradient(-45deg, #111a1f, #222d32); + color: var(--text-fg); + border-radius: 10px; + box-shadow: -1rem 0 3rem #000; + /* margin-left: -50px; */ + transition: 0.4s ease-out; + position: relative; + left: 0px; + } + + .card:not(:first-child) { + margin-left: -50px; + } + + .card:hover { + box-shadow: 0 0 4rem #554; + transform: translateY(-20px); + transition: 0.4s ease-out; + color: var(--text-fg); + } + + .card:hover ~ .card { + position: relative; + left: 70px; + transition: 0.4s ease-out; + } + + .title { + color: var(--text-fg); + font-weight: bold; + position: absolute; + left: 20px; + top: 15px; + } + + .card:hover > .title { + color: var(--header-fg); + transition: 0.4s ease-out; + } + + .bar { + position: absolute; + top: 70px; + left: 20px; + height: 5px; + width: 150px; + } + + .summary { + /* position: relative; */ + margin-top: 80px; + margin-left: 10px; + margin-right: 10px; + top: 70px; + left: 20px; + } + + .emptybar { + background-color: #2e3033; + width: 100%; + height: 100%; + } + + .filledbar { + position: absolute; + top: 0px; + z-index: 3; + width: 0px; + height: 100%; + background: linear-gradient(90deg, #66aabb 0%, #8ea374 22%, #ebcb88 100%); + transition: 0.6s ease-out; + } + + .card:hover .filledbar { + width: 120px; + transition: 0.4s ease-out; + } + /* center the button */ + .projects { + position: relative; + left: calc(50% - 50px); + margin-top: 30px; + margin-bottom: 30px; + } +</style> diff --git a/themes/cranky/layouts/shortcodes/tagcloud.html b/themes/cranky/layouts/shortcodes/tagcloud.html new file mode 100644 index 0000000..0cf0118 --- /dev/null +++ b/themes/cranky/layouts/shortcodes/tagcloud.html @@ -0,0 +1,3 @@ +{{ if isset .Site.Taxonomies "tags" }}{{ if not (eq (len .Site.Taxonomies.tags) 0) }} <ul id="tagcloud"> + {{ range $name, $items := .Site.Taxonomies.tags }}{{ $url := printf "%s/%s" "tags" ($name | urlize | lower)}}<li><a href="{{ $url | absURL }}" id="tag_{{ $name }}">{{ $name | title }}</a></li> + {{ end }}</ul>{{ end }}{{ end }} diff --git a/themes/cranky/layouts/shortcodes/vid.html b/themes/cranky/layouts/shortcodes/vid.html new file mode 100644 index 0000000..4c612fe --- /dev/null +++ b/themes/cranky/layouts/shortcodes/vid.html @@ -0,0 +1,6 @@ +<iframe src="{{ index .Params 0 }}" + loading="lazy" + sandbox="allow-same-origin allow-scripts allow-popups" + allowfullscreen frameborder="0" + title="Embedded Video"> +</iframe> diff --git a/themes/cranky/static/favicon.ico b/themes/cranky/static/favicon.ico Binary files differnew file mode 100644 index 0000000..8580b50 --- /dev/null +++ b/themes/cranky/static/favicon.ico diff --git a/themes/cranky/static/qr-diag.png b/themes/cranky/static/qr-diag.png Binary files differnew file mode 100644 index 0000000..2e58ca2 --- /dev/null +++ b/themes/cranky/static/qr-diag.png diff --git a/themes/cranky/static/rss.svg b/themes/cranky/static/rss.svg new file mode 100644 index 0000000..59ea164 --- /dev/null +++ b/themes/cranky/static/rss.svg @@ -0,0 +1 @@ +<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><!--! Font Awesome Pro 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path d="M0 64C0 46.3 14.3 32 32 32c229.8 0 416 186.2 416 416c0 17.7-14.3 32-32 32s-32-14.3-32-32C384 253.6 226.4 96 32 96C14.3 96 0 81.7 0 64zM0 416a64 64 0 1 1 128 0A64 64 0 1 1 0 416zM32 160c159.1 0 288 128.9 288 288c0 17.7-14.3 32-32 32s-32-14.3-32-32c0-123.7-100.3-224-224-224c-17.7 0-32-14.3-32-32s14.3-32 32-32z" fill="#f2f1f0"/></svg> diff --git a/themes/cranky/static/style.css b/themes/cranky/static/style.css new file mode 100644 index 0000000..a53ad99 --- /dev/null +++ b/themes/cranky/static/style.css @@ -0,0 +1,101 @@ +:root { + --std-bg: #111a1f; + --light-bg: #222d32; + --header-fg: #f2f1f0; + --text-fg: #c0c7ca; + --link-fg-std: #ebcb88; + --link-fg-hover: #b7416e; +} + +body { + font-family: sans-serif; + color: var(--text-fg); + background: var(--std-bg); +} + +main { + max-width: 800px; + margin: auto; +} + +img { + max-width: 100%; +} + +header h1 { + color: var(--header-fg); + text-align: center; +} + +footer { + text-align: center; + clear: both; +} + +a { + color: var(--link-fg-std); + text-decoration: none; +} + +a:hover { + color: var(--link-fg-hover); +} + +/* For TAGLIST.HTML */ +.taglist { + text-align: center; + clear: both; +} + +/* For NEXTPREV.HTML */ +#nextprev { + /* The container for both the previous and next articles. */ +} +#prevart { + float: left; + text-align: left; +} +#nextart { + float: right; + text-align: right; +} +#nextart, +#prevart { + max-width: 33%; +} + +/* Photo Gallery Stuff */ + +.photo-gallery { + column-count: 3; + column-gap: 20px; + min-width: 300px; + width: 100%; + max-width: 1500px; +} + +.photo-gallery > a { + display: inline-block; + padding: 20 20px; + margin: auto; + width: 100%; + box-sizing: border-box; +} + +@media screen and (max-width: 600) { + .photo-gallery { + column-count: 1; + } +} + +@media screen and (min-width: 1025px) { + .photo-gallery { + column-count: 3; + } +} + +@media screen and (min-width: 1200px) { + .photo-gallery { + column-count: 4; + } +} |