From 7ed442dfa3b26483ff6cd1eeb871b40b6be97f52 Mon Sep 17 00:00:00 2001
From: User Mms
Date: Tue, 29 Oct 2024 15:30:06 +0100
Subject: feat: UF archive
---
themes/24-unification/layouts/_default/baseof.html | 539 +++++++++++----------
themes/24-unification/layouts/_default/comic.html | 68 +++
.../layouts/_default/comic_index.html | 43 ++
themes/24-unification/layouts/_default/list.html | 2 +-
themes/24-unification/layouts/_default/rss.xml | 2 +-
themes/24-unification/layouts/_default/single.html | 1 -
6 files changed, 383 insertions(+), 272 deletions(-)
create mode 100644 themes/24-unification/layouts/_default/comic.html
create mode 100644 themes/24-unification/layouts/_default/comic_index.html
(limited to 'themes')
diff --git a/themes/24-unification/layouts/_default/baseof.html b/themes/24-unification/layouts/_default/baseof.html
index 8911927..23bcf48 100644
--- a/themes/24-unification/layouts/_default/baseof.html
+++ b/themes/24-unification/layouts/_default/baseof.html
@@ -59,26 +59,26 @@
--breakpoint: 800px;
}
- @font-face {
- font-family: "bryle";
- {{- $font := resources.Get "fonts/Atkinson-Hyperlegible-Regular-102a.woff2" -}}
- src: url("{{ $font.Permalink }}");
- font-weight: normal;
- }
-
- @font-face {
- font-family: "bryle";
- {{- $font := resources.Get "fonts/Atkinson-Hyperlegible-Bold-102a.woff2" -}}
- src: url("{{ $font.Permalink }}");
- font-weight: bold;
- }
-
- @font-face {
- font-family: "bryle";
- {{- $font := resources.Get "fonts/Atkinson-Hyperlegible-Italic-102a.woff2" -}}
- src: url("{{ $font.Permalink }}");
- font-style: italic;
- }
+ @font-face {
+ font-family: "bryle";
+ {{- $font := resources.Get "fonts/Atkinson-Hyperlegible-Regular-102a.woff2" -}}
+ src: url("{{ $font.Permalink }}");
+ font-weight: normal;
+ }
+
+ @font-face {
+ font-family: "bryle";
+ {{- $font := resources.Get "fonts/Atkinson-Hyperlegible-Bold-102a.woff2" -}}
+ src: url("{{ $font.Permalink }}");
+ font-weight: bold;
+ }
+
+ @font-face {
+ font-family: "bryle";
+ {{- $font := resources.Get "fonts/Atkinson-Hyperlegible-Italic-102a.woff2" -}}
+ src: url("{{ $font.Permalink }}");
+ font-style: italic;
+ }
html {
min-height: 100dvh;
}
@@ -150,7 +150,7 @@
margin: 0;
padding: 0;
}
-
+
li {
box-sizing: border-box;
background-color: var(--bg-nav-section);
@@ -185,7 +185,7 @@
box-sizing: border-box;
padding-left: 20px;
border-bottom: var(--cool-border);
-
+
li {
background-color: var(--panel-color);
border: 0;
@@ -207,266 +207,267 @@
display: block;
}
}
-
- @media only screen and (max-width: 800px) {
- .logo {
- display: none;
- }
-
- .nav {
- width: 100%;
- margin-bottom: 20px;
- border-bottom: var(--cool-border);
- border-right: none;
-
- .nav-box {
- width: 100%;
- border: 0;
- }
-
- ol.section {
- display: flex;
- flex-direction: row;
- flex-wrap: wrap;
- }
-
- ol.subsection {
- display: none!important;
- }
-
- li {
- flex-shrink: 1;
- border: var(--cool-border)!important;
- padding: 5px;
-
- a {
- width: 100%!important;
- border: 0!important;
- }
- }
- }
-
- .webbuttons {
- display: none;
- }
-
- }
-
- /* Main */
- main {
- padding-left: 20px;
- box-sizing: border-box;
- width: 100%;
- padding-top: 20px;
-
- article {
- background-color: var(--panel-color);
- margin-bottom: 20px;
- border: var(--cool-border);
- display: flow-root;
-
- h2 {
- margin: 0;
- padding-top: 10px;
- padding-bottom: 5px;
- padding-left: 20px;
- padding-right: 20px;
-
- }
- p {
- padding-left: 20px;
- padding-right: 20px;
- text-align: justify;
- }
-
- time {
- padding-left: 20px;
- padding-right: 20px;
- }
-
- > pre, table {
- padding-left: 20px;
- padding-right: 20px;
- overflow-x: scroll;
- }
-
- .highlight {
- padding-left: 20px;
- padding-right: 20px;
-
- pre {
- overflow-x: scroll;
-
- }
- }
-
- aside.post-meta {
- border-top: var(--cool-border);
- padding-left: 20px;
- padding-right: 20px;
- padding-top: 5px;
- padding-bottom: 5px;
- background-color: var(--panel-meta-color);
- }
-
- figure {
- text-align: center;
- margin: 0;
- max-width: 100%;
- font-size: 0.8em;
- }
-
- img.float-right {
- float: right;
- display: inline;
- margin-left: 10px;
- }
-
- img.center {
- max-width: 100%;
- height: auto;
- }
+
+ @media only screen and (max-width: 800px) {
+ .logo {
+ display: none;
+ }
+
+ .nav {
+ width: 100%;
+ margin-bottom: 20px;
+ border-bottom: var(--cool-border);
+ border-right: none;
+
+ .nav-box {
+ width: 100%;
+ border: 0;
+ }
+
+ ol.section {
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
+ }
+
+ ol.subsection {
+ display: none!important;
+ }
+
+ li {
+ flex-shrink: 1;
+ border: var(--cool-border)!important;
+ padding: 5px;
+
+ a {
+ width: 100%!important;
+ border: 0!important;
+ }
+ }
+ }
+
+ .webbuttons {
+ display: none;
+ }
- .button img {
- width: 88px;
- padding-left: 44px;
- }
-
- .pull-left {
- float: left;
- margin: 10px;
- }
-
- .pull-right {
- float: right;
- margin: 10px;
- }
- }
- article.link {
- padding: 20px;
- display: flex;
- justify-content: center;
+
+ }
+nav.horizontal {
+ display: flex;
+ width: 100%;
+
+ a {
+ display: block;
+ flex-grow: 1;
+ border: var(--cool-border);
+ padding: 5px;
+ text-align: center;
+ margin-bottom: 10px;
+ margin-top: 10px;
+ background-color: var(--panel-color);
+ }}
+
+
+ /* Main */
+ main {
+ padding-left: 20px;
+ box-sizing: border-box;
+ width: 100%;
+ padding-top: 20px;
+
+ article {
+ background-color: var(--panel-color);
+ margin-bottom: 20px;
+ border: var(--cool-border);
+ display: flow-root;
+
+ h1.comic-title {
+ margin: 0;
+ border-bottom: var(--cool-border);
+ padding-left: 20px;
+ padding-right: 20px;
+ padding-top: 5px;
+ padding-bottom: 5px;
+ background-color: var(--panel-meta-color);
+
+ time {
+ padding: 0;
+ }
+ }
+
+ h2, h3, h4, h5 {
+ margin: 0;
+ padding-top: 10px;
+ padding-bottom: 5px;
+ padding-left: 20px;
+ padding-right: 20px;
+
+ }
+ p {
+ padding-left: 20px;
+ padding-right: 20px;
+ text-align: justify;
+ }
+
+ time {
+ padding-left: 20px;
+ padding-right: 20px;
+ }
+
+ > pre, table {
+ padding-left: 20px;
+ padding-right: 20px;
+ overflow-x: scroll;
+ }
+
+ .highlight {
+ padding-left: 20px;
+ padding-right: 20px;
- time {
- padding-left: 0;;
- }
- .img {
- padding-right: 20px;
- flex-grow: 0;
- height: 32px;
- width: 32px;
- }
- .text {
- flex-grow: 1;
- }
- }
+ pre {
+ overflow-x: scroll;
+ padding: 10px;
+ border: var(--cool-border);
- table.eptab {
- width: 100%;
-
- th {
- text-align: center;
- padding: 20px;
- }
-
- tr td {
- text-align: center;
- }
- tr td:last-child {
- text-align: left;
- }
- }
-
- }
+ }
+ }
+
+ .post-meta {
+ border-top: var(--cool-border);
+ padding-left: 20px;
+ padding-right: 20px;
+ padding-top: 5px;
+ padding-bottom: 5px;
+ background-color: var(--panel-meta-color);
+ }
+
+ figure {
+ text-align: center;
+ margin: 0;
+ max-width: 100%;
+ font-size: 0.8em;
+ }
+
+ img.float-right {
+ float: right;
+ display: inline;
+ margin-left: 10px;
+ }
+
+ img.center {
+ max-width: 100%;
+ height: auto;
+ }
+
+ .button img {
+ width: 88px;
+ padding-left: 44px;
+ }
+
+ .pull-left {
+ float: left;
+ margin: 10px;
+ }
+
+ .pull-right {
+ float: right;
+ margin: 10px;
+ }
+ }
+ article.link {
+ padding: 20px;
+ display: flex;
+ justify-content: center;
+
+ time {
+ padding-left: 0;;
+ }
+ .img {
+ padding-right: 20px;
+ flex-grow: 0;
+ height: 32px;
+ width: 32px;
+ }
+ .text {
+ flex-grow: 1;
+ }
+ }
+
+ table.eptab {
+ width: 100%;
+
+ th {
+ text-align: center;
+ padding: 20px;
+ }
+
+ tr td {
+ text-align: center;
+ }
+ tr td:last-child {
+ text-align: left;
+ }
+ }
+
+ a.list-button-link {
+ margin-left: 5px;
+ }
+ a.visit-marked:visited {
+ color: #888!important;
+ }
+
+ }
+
+ @media only screen and (max-width: 650px) {
+ table.eptab {
+ th, td {
+ display: none;
+ }
+ tr th:nth-child(2) {
+ display: table-cell;
+ }
+ tr th:last-child {
+ display: table-cell;
+ }
+ tr td:last-child {
+ display: table-cell;
+ }
+ tr td:nth-child(2) {
+ display: table-cell;
+ }
+ tr td:last-child {
+ display: table-cell;
+ }
+ }
+ }
+
+ img {
+ max-width: 100%;
+ height: auto;
+
+ }
- @media only screen and (max-width: 650px) {
- table.eptab {
- th, td {
- display: none;
- }
- tr th:nth-child(2) {
- display: table-cell;
- }
- tr th:last-child {
- display: table-cell;
- }
- tr td:last-child {
- display: table-cell;
- }
- tr td:nth-child(2) {
- display: table-cell;
- }
- tr td:last-child {
- display: table-cell;
- }
- }
- }
-
- img {
- max-width: 100%;
- height: auto;
-
- }
+ .blog-pages-list {
+ border: var(--cool-border);
+ margin-bottom: 20px;
+ padding: 20px;
+ background-color: var(--panel-color);
+ }
- .blog-pages-list {
- border: var(--cool-border);
- margin-bottom: 20px;
- padding: 20px;
- background-color: var(--panel-color);
- }
+ @media only screen and (max-width: 800px) {
+ main {
+ padding: 10px;
+ }
+ }
- @media only screen and (max-width: 800px) {
- main {
- padding: 10px;
- }
- }
-Skip to content
-
-
- {{ partial "blog/face-game.html" . }}
-
- {{ $page := . }}
- {{- with index site.Menus "sections" }}
-
- CRYS SITE
- {{- range . }}
- {{ .Name }}
- {{- with index site.Menus .Params.submenu }}
-
- {{- range .}}
- {{ .Name }}
- {{- end}}
-
-
- {{- end}}
-
-
- {{- end}}
-
-
- Buy me a Ko-Fi
-
-
- {{- end}}
-
-
-
-
- {{ partial "button-31" (dict "file" "rss.gif" "alt" "RSS Feed" "href" "https://michal.sapka.me/blog/index.xml") }}
-
+ {{ partialCached "24-unification/nav.html" . .Section }}
diff --git a/themes/24-unification/layouts/_default/comic.html b/themes/24-unification/layouts/_default/comic.html
new file mode 100644
index 0000000..1b3efde
--- /dev/null
+++ b/themes/24-unification/layouts/_default/comic.html
@@ -0,0 +1,68 @@
+{{ define "main" }}
+
+{{- $path := .Params.assetPath}}
+{{- $img := resources.Get $path }}
+
+{{ $mirror := where .Site.RegularPages ".Params.mirrorName" .Params.mirrorName}}
+
+
+ {{- with $mirror.Next . }}
+ [previous]
+ {{- end }}
+
+ [index]
+
+ {{- with $mirror.Prev . }}
+ [next]
+ {{- end }}
+
+
+
+
+ Comic for
+
+ {{ .PublishDate.Format "Monday, 2 Jan 2006" }}
+
+
+ {{ if gt $img.Width 0 }}
+ {{- $img2xproc := printf "x%d gif q90" (math.Mul 2 $img.Height) }}
+ {{- $img1x := $img }}
+ {{- $img2x := $img.Resize $img2xproc }}
+
+
+
+
+
+ {{ else }}
+ Corrupted image :-(
+ {{ end }}
+
+
+
+ {{- with $mirror.Next . }}
+ [previous]
+ {{- end }}
+
+ [index]
+
+ {{- with $mirror.Prev . }}
+ [next]
+ {{- end }}
+
+
+
+{{ end }}
+
+
diff --git a/themes/24-unification/layouts/_default/comic_index.html b/themes/24-unification/layouts/_default/comic_index.html
new file mode 100644
index 0000000..601c85d
--- /dev/null
+++ b/themes/24-unification/layouts/_default/comic_index.html
@@ -0,0 +1,43 @@
+{{ define "main" }}
+
+{{ $lastYear := 0 }}
+{{ $lastMonth := 0 }}
+
+ {{ .Title }}
+
+
+ User Friendly was a regular comic strip by J. D. Frazer (aka Illiad).
+ It tells a story of a group of techies working in an ISP.
+ Over 5500 pages of Quake, Linux, creatures born from old server dust, and making fun of Microsoft.
+ Weeks of fun!
+
+
+ Of course, I take no claim to have any copyright to User Friendly.
+
+ {{ range where .Site.RegularPages "Section" .Section }}
+
+
+ {{ if ne $lastYear (.PublishDate.Format "2006")}}
+
+ {{ .PublishDate.Format "2006"}}
+
+ {{ end }}
+ {{ $lastYear = (.PublishDate.Format "2006")}}
+
+
+ {{ if ne $lastMonth (.PublishDate.Format "January")}}
+
{{ .PublishDate.Format "January" }}
+
+ {{ end }}
+ {{ $lastMonth = (.PublishDate.Format "January")}}
+
+
+
+
+ {{(.PublishDate.Format "02") }}
+
+
+
+{{ end }}
+
+{{ end }}
diff --git a/themes/24-unification/layouts/_default/list.html b/themes/24-unification/layouts/_default/list.html
index 58cb880..3b91e9f 100644
--- a/themes/24-unification/layouts/_default/list.html
+++ b/themes/24-unification/layouts/_default/list.html
@@ -5,7 +5,7 @@
{{ .Page.Content }}
{{ else }}
-{{ $paginator := .Paginate .Site.RegularPages.ByDate.Reverse 10 }}
+{{ $paginator := .Paginate (where .Site.RegularPages.ByDate.Reverse ".Params.nolist" "<>" true ) 10 }}
{{ range $paginator.Pages }}
{{ if eq .Section "blog" }}
diff --git a/themes/24-unification/layouts/_default/rss.xml b/themes/24-unification/layouts/_default/rss.xml
index fa34bd5..8df6fa9 100644
--- a/themes/24-unification/layouts/_default/rss.xml
+++ b/themes/24-unification/layouts/_default/rss.xml
@@ -34,7 +34,7 @@
{{- if .IsHome }}{{ $pctx = .Site }}{{ end }}
{{- $pages := slice }}
{{- if $.IsHome }}
-{{- $pages = $pctx.RegularPages}}
+{{- $pages = where $pctx.RegularPages ".Params.nolist" "<>" true }}
{{- else if $.IsSection }}
{{- $pages = $pctx.RegularPagesRecursive}}
{{- else }}
diff --git a/themes/24-unification/layouts/_default/single.html b/themes/24-unification/layouts/_default/single.html
index fdfcdd4..838debd 100644
--- a/themes/24-unification/layouts/_default/single.html
+++ b/themes/24-unification/layouts/_default/single.html
@@ -1,4 +1,3 @@
{{ define "main" }}
{{ partial "partials/blog/full-post.html" . }}
-
{{- end }}
--
cgit v1.2.3