commit 3a3e37a13f3015c24cfc3a99a35b6b87aaab93e9
parent bf09351eb380caff9b79410151e2fcc95cbcca06
Author: Chris Kiriakou <chris@kiriakou.net>
Date: Mon, 23 Nov 2026 21:10:37 +0100
finish refactoring
Diffstat:
23 files changed, 658 insertions(+), 700 deletions(-)
diff --git a/assets/css/chroma.css b/assets/css/chroma.css
@@ -0,0 +1,37 @@
+.highlight {
+ padding-left: 0;
+ padding-right: 0;
+}
+
+.chroma tr { border: none; }
+
+.chroma:has(table) pre.chroma { margin: 0; }
+
+.chroma:has(table) td:first-of-type pre {
+ border-right: none;
+ padding-right: 1ch;
+ color: var(--secondary-fg-color);
+ -webkit-user-select: none;
+ user-select: none;
+}
+
+.chroma:has(table) td:last-of-type pre {
+ border-left: none;
+ padding-left: 0;
+}
+
+.chroma { overflow-x: auto; }
+
+.chroma td,
+.chroma th { padding: 0; }
+
+.chroma .cp,
+.chroma .c,
+.chroma .c1 { color: var(--secondary-fg-color); }
+
+div.chroma { margin: 1rem 0; }
+
+pre.chroma {
+ padding: 1rem;
+ margin: 1rem 0;
+}
diff --git a/assets/css/debug.css b/assets/css/debug.css
@@ -0,0 +1,20 @@
+/*
+article { border: 1px solid cyan; }
+article:before {
+ content: "article";
+ color: cyan;
+}
+
+main { border: 1px solid magenta; }
+main:before {
+ content: "main";
+ color: magenta;
+}
+
+main:before,
+article:before {
+ font-size: smaller;
+ background-color: black;
+ position: absolute;
+}
+*/
diff --git a/assets/css/layouts.css b/assets/css/layouts.css
@@ -0,0 +1,159 @@
+/* main elements */
+.title { text-align: center; }
+
+.post-nav {
+ font: small/1.5 'Linux Biolinum', sans-serif;
+ display: flex;
+ justify-content: space-between;
+ gap: 2ch;
+ margin: 2rem 0;
+ padding: 0 1rem;
+}
+
+.post-nav a:link,
+.post-nav a:visited { color: var(--secondary-fg-color); }
+
+/* home.html */
+.recent-posts > * { margin: 2rem 0; }
+
+.recent-post {
+ color: var(--primary-fg-color);
+ margin: 0;
+}
+
+.recent-post-wrapper {
+ border: 1px solid var(--ui-element-color);
+ padding: 1rem;
+ transition: box-shadow 0.5s ease;
+ text-decoration: none;
+}
+
+.recent-post-wrapper:hover { box-shadow: 0 0 0 2px var(--ui-element-color); }
+
+.recent-post > h3,
+.recent-post > .metadata { padding: 0; }
+
+.recent-post > h3 {
+ margin-top: 0;
+ margin-bottom: 0.5rem;
+}
+
+.recent-post > .metadata {
+ margin-top: 0.5rem;
+ margin-bottom: 0;
+}
+
+.recent-posts .post-nav > .nav-item::after { content: " ›"; }
+
+/* header elements */
+.breadcrumb {
+ gap: 0.5ch;
+ list-style: none;
+ padding: 0;
+ margin: 0;
+ white-space: nowrap;
+ text-overflow: ellipsis;
+ overflow: hidden;
+}
+
+.breadcrumb li { display: inline; }
+
+.breadcrumb a { color: var(--secondary-fg-color); }
+
+.breadcrumb li:not(:last-child)::after { content: " › "; }
+
+.language-menu {
+ font: small/var(--line-height) 'Linux Biolinum', sans-serif;
+ border: none;
+ background: none;
+ outline: none;
+ color: var(--secondary-fg-color);
+ flex-shrink: 0;
+}
+
+.language-menu:focus { outline: none; }
+
+/* footer */
+.footer-row {
+ display: flex;
+ flex-direction: row;
+ margin: 2rem 0;
+ gap: 7%;
+}
+
+.footer-column {
+ display: flex;
+ flex-direction: column;
+ gap: 0.25rem;
+}
+
+.footer-column-title { font-weight: bold; }
+
+.footer-row:last-child > .footer-item:last-child { margin-left: auto; }
+
+.footer-item {
+ display: flex;
+ flex-direction: row;
+}
+
+.footer-column > a:link,
+.footer-column > a:visited { color: var(--secondary-fg-color); }
+
+.version-name { text-decoration: none; }
+
+/* article elements */
+.metadata .tags {
+ display: flex;
+ gap: 1ch;
+}
+
+.metadata .tag {
+ text-transform: uppercase;
+ color: var(--secondary-fg-color);
+}
+
+.metadata {
+ color: var(--secondary-fg-color);
+ font: small/1.5 'Linux Biolinum', sans-serif;
+ margin: 1rem 0;
+ display: flex;
+ gap: 1ch;
+}
+
+.preview-wrapper {
+ text-decoration: none;
+ color: var(--primary-fg-color);
+}
+
+.preview { margin: 2rem 0; }
+
+.preview > * > * { margin: 0.5rem 0; }
+
+.preview nav { text-align: right; }
+
+.preview-footer {
+ display: flex;
+ column-gap: 1ch;
+}
+
+.preview-footer > * {
+ display: flex;
+ gap: 1ch;
+}
+
+.preview-footer-right { margin-left: auto; }
+
+.page-item {
+ display: flex;
+ flex-direction: row;
+ align-items: baseline;
+ margin: 0.25rem 0;
+ column-gap: 1ch;
+}
+
+.page-item > div:first-child {
+ flex-shrink: 0;
+ white-space: nowrap;
+}
+
+.page-item > div > span { padding-right: 0.5rem; }
diff --git a/assets/css/main.css b/assets/css/main.css
@@ -1,39 +1,16 @@
/* Wide screens */
-@media screen and (min-width: 40rem) {
- html { font-size: 1.1rem; }
-
- .row {
- display: flex;
- flex-wrap: wrap;
- gap: 1ch;
- }
-
- .column {
- flex: 1 1 0;
- min-width: 0;
- }
-
- .column > *:first-child {
- margin-top: 0;
- }
-}
+@media screen and (min-width: 40rem) { html { font-size: 1.1rem; } }
/* Narrow screens */
-@media screen and (max-width: 40rem) {
- html { font-size: 1rem; }
-}
+@media screen and (max-width: 40rem) { html { font-size: 1.05rem; } }
@media (prefers-color-scheme: dark) {
:root {
--primary-fg-color: #fcfcfa;
--primary-bg-color: #121212;
-
--secondary-fg-color: #bcbcba;
--secondary-bg-color: #232323;
-
--ui-element-color: #343434;
-
- --chroma-string-color: #c9b2f7;
}
}
@@ -41,56 +18,23 @@
:root {
--primary-fg-color: #121212;
--primary-bg-color: #fcfcfa;
-
--secondary-fg-color: #565654;
--secondary-bg-color: #efefed;
-
--ui-element-color: #dededc;
-
- --chroma-string-color: #735ca1;
}
}
-h1,
-h2,
-h3,
-h4,
-h5,
-h6 {
- font-family: 'Linux Libertine Display', sans-serif;
- line-height: 1.2;
-}
-
-.title { text-align: center; }
-
-.profile-picture {
- display: flex;
- justify-content: center;
- align-items: center;
-}
-
-.profile-picture img {
- width: 150px;
- height: 150px;
- border-radius: 50%;
- object-fit: cover;
-}
-
-:root {
- -webkit-tap-highlight-color: transparent;
-}
+:root { --line-height: 1.4; }
html {
font-family: 'Linux Libertine', serif;
- line-height: 1.4;
- text-size-adjust: 100%;
- -ms-text-size-adjust: 100%;
- -moz-text-size-adjust: 100%;
- -webkit-text-size-adjust: 100%;
- height: 100%;
- scrollbar-color: var(--ui-element-color) transparent;
+ line-height: var(--line-height);
color: var(--primary-fg-color);
background-color: var(--primary-bg-color);
+ height: 100%;
+ -webkit-text-size-adjust: 100%;
+ -webkit-tap-highlight-color: transparent;
+ scrollbar-color: var(--ui-element-color) transparent;
}
body {
@@ -99,198 +43,90 @@ body {
min-height: 100dvh;
height: 100%;
margin: 0 auto;
- max-width: 40rem;
width: 100%;
}
-main:has(.article) {
- padding-left: 0;
- padding-right: 0;
-}
-
-.post-nav,
-.page-item,
-article > .row > .column > p,
-article > .row > .column > h1,
-article > .row > .column > h2,
-article > .row > .column > h3,
-article > .row > .column > h4,
-article > .row > .column > h5,
-article > .row > .column figure > figcaption,
-article > .row > .column > table,
-article > .rss-link,
-article > .preview-footer,
-article > .tag-section,
-article > table,
-article > .post-title,
-article > .metadata,
-article > h1,
-article > h2,
-article > h3,
-article > h4,
-article > h5,
-article > h6,
-article figure > figcaption,
-article > p {
- padding-left: 1rem;
- padding-right: 1rem;
-}
-
-a:visited,
-a:link { color: var(--primary-fg-color); }
-
-.current-page {
- font-family: 'Linux Biolinum', serif;
+header {
+ font: small/var(--line-height) 'Linux Biolinum', sans-serif;
color: var(--secondary-fg-color);
-}
-
-article > iframe {
- flex: 1;
+ background-color: var(--primary-bg-color);
display: flex;
- margin-inline: auto;
-}
-
-header,
-footer {
- padding-left: 2ch;
- padding-right: 2ch;
+ max-width: 40rem;
width: 100%;
+ margin: 0 auto;
+ padding: 0.25rem 1rem;
box-sizing: border-box;
-}
-
-header {
- background-color: var(--primary-bg-color);
-
- padding-bottom: 0.25rem;
- padding-top: 0.5rem;
- display: flex;
-
top: 0;
left: 0;
right: 0;
-
z-index: 10;
position: fixed;
-
- width: 40rem;
- margin: 0 auto;
}
-.nav-menu {
- font-family: 'Linux Biolinum', sans-serif;
- font-size: small;
+header > nav {
display: flex;
width: 100%;
- align-items: baseline;
- gap: 2ch;
-}
-
-.nav-menu-right {
- margin-left: auto;
- flex-shrink: 0;
-}
-
-.nav-menu-left {
- flex: 1;
- min-width: 0;
-}
-
-.nav-menu-center {
- display: flex;
gap: 2ch;
+ justify-content: space-between;
+ align-items: baseline;
}
-.breadcrumb {
- gap: 0.5ch;
- list-style: none;
- padding: 0;
- margin: 0;
- white-space: nowrap;
- text-overflow: ellipsis;
- overflow: hidden;
-}
-
-.breadcrumb li { display: inline; }
-
-.breadcrumb li:not(:last-child)::after {
- content: "›";
-}
-
-select {
- font-family: 'Linux Biolinum', sans-serif;
+footer {
font-size: small;
- border-radius: var(--border-radius);
- border: none;
- background: none;
- outline: none;
+ font-family: 'Linux Biolinum', sans-serif;
color: var(--secondary-fg-color);
-}
-
-select:focus {
- outline: none;
-}
-
-main {
- flex: 1 0 auto;
- max-width: 100%;
- box-sizing: border-box;
- margin-top: 2rem;
-}
-
-footer {
+ background: var(--ui-element-color);
+ background: linear-gradient(0deg, var(--ui-element-color) 0%, var(--primary-bg-color) 100%);
display: flex;
flex-direction: column;
-
margin-top: 2rem;
- padding-bottom: 0.5rem;
- color: var(--secondary-fg-color);
- text-decoration-color: var(--secondary-fg-color);
+}
-
- background: var(--ui-element-color);
- background: linear-gradient(0deg, var(--ui-element-color) 0%, var(--primary-bg-color) 100%);
+footer > div {
+ max-width: 40rem;
+ width: 100%;
+ margin: 0 auto;
}
-.footer-row {
- display: flex;
- flex-direction: row;
+footer > div > * { padding: 0 1rem; }
- margin: 1rem 0;
- gap: 5%;
+main {
+ flex: 1 0 auto;
+ box-sizing: border-box;
+ margin: 2rem auto;
+ max-width: 40rem;
+ width: 100%;
}
-.footer-column {
- display: flex;
- flex-direction: column;
- gap: 0.25rem;
-}
+article { margin: 2rem auto; }
-.footer-column-title {
- font-weight: bold;
-}
+article > * { padding: 0 1rem; }
-.footer-row:last-child > .footer-item:last-child {
- margin-left: auto;
-}
+article > ul,
+article > ol { padding-left: 3rem; }
-.footer-item {
- display: flex;
- flex-direction: row;
-}
+h1,
+h2,
+h3,
+h4,
+h5,
+h6 { font-family: 'Linux Libertine Display', sans-serif; }
figure {
margin-left: 0;
margin-right: 0;
+ padding-left: 0;
+ padding-right: 0;
}
figcaption {
font-size: small;
color: var(--secondary-fg-color);
+ padding-left: 1rem;
+ padding-right: 1rem;
}
-figcaption p {
- margin-top: 0.5em;
-}
+figcaption > p:first-of-type { margin-top: 0.5em; }
video,
img {
@@ -298,78 +134,48 @@ img {
max-width: 100%;
}
-p:has(img) {
- display: flex;
- gap: 1ch;
- align-items: flex-start;
-}
-
-p img {
- max-width: 35%;
- height: auto;
- align-self: flex-start;
- object-fit: contain;
- flex-shrink: 0;
-}
-
p sup,
-p sub { line-height: 1; }
+p sub { line-height: 0; }
blockquote {
color: var(--secondary-fg-color);
border-left: 3px solid var(--ui-element-color);
- margin-left: 0;
- margin-right: 0;
+ margin: 1rem 0;
padding: 0 1rem;
}
-blockquote .citation { text-align: right; }
-
-.citation .small-text {
- font-family: 'Linux Biolinum', sans-serif;
-}
-
a { overflow-wrap: break-word; }
a:hover { text-decoration: none; }
pre,
code {
- font-family: 'Linux Libertine Mono', monospace;
- font-size: 0.8rem;
- line-height: 1.3;
+ font: small/var(--line-height) 'Linux Libertine Mono', monospace;
+ -webkit-text-size-adjust: 100%;
}
-pre { background-color: var(--secondary-bg-color); }
+code { overflow-wrap: break-word; }
pre {
+ background-color: var(--secondary-bg-color);
padding: 1rem;
scrollbar-color: var(--ui-element-color) transparent;
}
-pre + * {
- margin-top: 0;
-}
-
-del { color: var(--secondary-fg-color); }
-
-code { overflow-wrap: break-word; }
-
-
article > pre {
display: block;
white-space: pre-wrap;
overflow-wrap: anywhere;
}
+del { color: var(--secondary-fg-color); }
+
table {
+ border-collapse: collapse;
display: block;
- width: fit-content; /* oder eine feste Breite */
+ width: fit-content;
max-width: 100%;
- margin: 1rem auto; /* zentriert horizontal */
- padding: 0 1rem;
- border-collapse: collapse;
- overflow: hidden;
+ margin: 1rem auto;
}
thead {
@@ -386,285 +192,19 @@ hr {
border: none;
border-top: 1px solid var(--ui-element-color);
width: 60%;
+ margin: 2rem auto;
}
-.math-block {
- width: 100%;
- overflow-x: auto;
-}
-
-
-.nav-menu a:link,
-.nav-menu a:visited {
- color: var(--secondary-fg-color)
-}
-
-.back-to-parent {
- color: var(--primary-fg-color);
- text-decoration: none;
-}
-
-.post-nav {
- font-family: 'Linux Biolinum', sans-serif;
- font-size: small;
- display: flex;
- justify-content: space-between;
- align-items: center;
- gap: 1rem;
- margin-top: 1rem;
- margin-bottom: 1rem;
-}
-
-.next-post {
- text-align: right;
- margin-left: auto;
-}
-
-.metadata .tags {
- display: flex;
- gap: 1ch;
-}
-
-.metadata .tag {
- text-transform: uppercase;
- color: var(--secondary-fg-color);
-}
-
-.metadata {
- color: var(--secondary-fg-color);
- font-family: 'Linux Biolinum', sans-serif;
- font-size: small;
- display: flex;
- gap: 1ch;
-}
-
-.metadata-edited { font-style: italic; }
-
-.preview-wrapper {
- text-decoration: none;
- color: var(--primary-fg-color);
-}
-
-.preview {
- margin: 2rem 0;
-}
+ul li { list-style-type: disc; }
-hr {
- margin-top: 2rem;
- margin-bottom: 2rem;
-}
-
-p:has( + ul) {
- margin-bottom: 0.25rem;
-}
-
-ul {
- margin-top: 0.25rem;
-}
-
-ul li {
- list-style: "- ";
-}
-
-.preview > * > * {
- margin: 0.5rem 0;
-}
-
-.preview nav { text-align: right; }
-
-.preview-footer {
- display: flex;
- column-gap: 1ch;
-}
-
-.preview-footer > * {
- display: flex;
- gap: 1ch;
-}
-
-.hint {
- border: 1px solid var(--ui-element-color);
- margin: 1rem;
- padding: 1rem;
-}
-
-.hint-title {
- text-align: center;
-}
-
-.preview-footer-right { margin-left: auto; }
-
-.page-item {
- display: flex;
- flex-direction: row;
- align-items: baseline;
- margin: 0.25rem 0;
- column-gap: 1ch;
-}
-
-.page-item > div:first-child {
- flex-shrink: 0;
- white-space: nowrap;
-}
-
-.page-item > div > span { padding-right: 0.5rem; }
-
-footer *,
.footnotes {
- font-family: 'Linux Biolinum', sans-serif;
- font-size: small;
-}
-
-footer a:link,
-footer a:visited,
-footer {
- color: var(--secondary-fg-color);
-}
-
-.footnotes {
- margin-top: 2rem;
- margin-bottom: 2rem;
-}
-
-.footnotes ol {
- padding-left: 2rem;
- padding-right: 1rem;
-}
-
-.highlight table { display: table; }
-
-.highlight + * { margin-top: 0; }
-
-.highlight > .chroma {
- overflow-x: auto;
-}
-
-.highlight .cl { padding-right: 1rem; }
-
-.highlight tr,
-.highlight td,
-.highlight th,
-.highlight table { border: none; }
-
-.highlight .lntable {
- padding: 0;
- margin: 0;
-}
-
-.highlight .lnt { color: var(--secondary-fg-color); }
-
-.highlight td,
-.highlight th { padding: 0; }
-
-.chroma .lnlinks { outline: none; }
-
-.chroma .lntd { vertical-align: top; }
-
-.chroma .line {
- display: flex;
- width: 100%;
+ font: small/var(--line-height) 'Linux Biolinum', sans-serif;
+ margin: 2rem 0;
}
-.chroma .cl { flex: 1 1 auto; }
-
-.chroma .mi,
-.chroma .mf,
-.chroma .s { color: var(--chroma-string-color); }
+.footnotes ol { padding-left: 2rem; }
-.chroma .c1 { color: var(--secondary-fg-color); }
-
-.chroma
-
-/* Carousel begin */
-.carousel {
+.math-block {
width: 100%;
- display: flex;
- align-items: center;
-
- overflow-x: scroll;
- scroll-snap-type: x mandatory;
-}
-
-.carousel > figure {
- align-items: center;
-}
-
-.carousel figure {
- margin: 0; /* reset the browser's default figure margins */
-
- flex: 0 0 100%;
- scroll-snap-align: center;
-}
-
-.carousel figcaption {
- display: column;
-}
-/* Carousel end */
-
-.small-text {
- font-size: small;
-}
-
-.greeting {
- text-align: center;
- border: 1px solid var(--ui-element-color);
- font-style: italic;
- padding: 1ch;
- margin-left: 1rem;
- margin-right: 1rem;
-}
-
-.greeting > * {
- margin-left: auto;
- margin-right: auto;
- width: 70%;
-}
-
-.greeting > *:first-child { margin-top: 0; }
-
-.greeting > *:last-child { margin-bottom: 0; }
-
-.version-name { text-decoration: none; }
-
-@media print {
- html {
- font-size: 12pt;
- line-height: 1.6;
- }
-
- a,
- p {
- overflow-wrap: break-word;
- hyphens: auto;
- text-align: justify;
- }
-
- .tag-section,
- .micro-post-footer,
- .regular-post-footer,
- header,
- footer { display: none; }
-
- tbody,
- thead {
- border-top: 1px solid;
- border-bottom: 1px solid;
- }
-
- figure,
- .footnotes > ol > li,
- table,
- tr,
- td,
- th { page-break-inside: avoid; }
-
- pre {
- font-size: 10pt;
- line-height: 1.1;
- }
-
- @page {
- size: A4;
- margin: 20mm;
- }
+ overflow-x: auto;
}
diff --git a/assets/css/print.css b/assets/css/print.css
@@ -0,0 +1,97 @@
+@media print {
+ :root {
+ --primary-fg-color: #000;
+ --primary-bg-color: #fff;
+ --secondary-fg-color: #000;
+ --secondary-bg-color: #fff;
+ --ui-element-color: #000;
+ }
+
+ html {
+ font-size: 12pt;
+ line-height: 1.5;
+ }
+
+ main {
+ margin-top: 0;
+ margin-bottom: 0;
+ }
+
+ article > * { padding: 0; }
+
+ a,
+ p {
+ overflow-wrap: break-word;
+ hyphens: auto;
+ text-align: justify;
+ }
+
+ .citation .source { font: italic 12pt/1.5 serif; }
+
+ a:visited,
+ a:link { color: #00f; }
+
+ .footnotes * {
+ font: 12pt/1.5 'Linux Libertine', serif;
+ text-align: start;
+ }
+
+ .recent-posts,
+ .footnotes hr,
+ .post-nav,
+ .tag-section,
+ .micro-post-footer,
+ .regular-post-footer,
+ header,
+ footer { display: none; }
+
+
+ .hint,
+ blockquote { border: none; }
+
+ blockquote > * { padding: 0 3rem; }
+
+ pre,
+ figure,
+ .footnotes,
+ table,
+ tr,
+ td,
+ th { page-break-inside: avoid; }
+
+ .footnotes { font-size: 12pt; }
+
+ .footnotes:before {
+ content: "Fußnoten & Quellen";
+ font-size: 18pt;
+ font-family: 'Linux Libertine Display', serif;
+ font-weight: bold;
+ }
+
+ pre {
+ font-size: 10pt;
+ line-height: 1.1;
+ display: block;
+ white-space: pre-wrap;
+ overflow-wrap: anywhere;
+ padding: 0;
+ }
+
+ video,
+ img {
+ margin-left: auto;
+ margin-right: auto;
+ }
+
+ figure { max-width: 500px; }
+
+ figcaption { font: 12pt/1.5 "Linux Libertine", serif; }
+
+ pre.chroma,
+ .highlight { padding: 0; }
+
+ @page {
+ size: A4;
+ margin: 20mm;
+ }
+}
diff --git a/assets/css/shortcodes.css b/assets/css/shortcodes.css
@@ -0,0 +1,60 @@
+.row figcaption > p { margin-bottom: 0; }
+
+.row {
+ display: flex;
+ flex-wrap: wrap;
+ gap: 1rem;
+ padding: 0 1rem;
+ margin: 1rem 0;
+}
+
+.column {
+ flex: 1 1 0;
+ min-width: 0;
+}
+
+.column > *:first-child { margin-top: 0; }
+
+.column > *:last-child { margin-bottom: 0; }
+
+.citation { text-align: right; }
+
+.citation .source {
+ font-family: 'Linux Biolinum', sans-serif;
+ font-size: small;
+}
+
+.carousel {
+ margin: 1rem 0;
+ padding: 0;
+ width: 100%;
+ display: flex;
+ align-items: center;
+ overflow-x: scroll;
+ scroll-snap-type: x mandatory;
+}
+
+.carousel > *:first-child { margin-top: 0; }
+
+.carousel > *:last-child { margin-bottom: 0; }
+
+.carousel figure {
+ margin: 0;
+ flex: 0 0 100%;
+ scroll-snap-align: center;
+}
+
+.centered > p { text-align: center; }
+
+.small-text { font-size: small; }
+
+.hint {
+ border: 1px solid var(--ui-element-color);
+ margin: 1rem;
+ padding: 1rem;
+}
+
+.hint-title {
+ text-align: center;
+ padding-bottom: 0.5rem;
+}
diff --git a/hugo.toml b/hugo.toml
@@ -0,0 +1,3 @@
+[params.theme]
+version = "0.0.1"
+versionName = "GlizzyGobbler"
diff --git a/i18n/de.json b/i18n/de.json
@@ -1,4 +1,6 @@
{
+ "showAllPosts": "Alle Beiträge anzeigen",
+ "legal": "Rechtliches",
"contact": "Kontakt",
"external": "Extern",
"socialMedia": "Soziale Medien",
@@ -16,7 +18,7 @@
"edited": "Bearbeitet",
"blog": "Blog",
"home": "Startseite",
- "about": "About",
+ "about": "Über Mich",
"email": "E-Mail",
"imprint": "Impressum",
"privacy": "Datenschutz",
@@ -24,5 +26,5 @@
"readMore": "Mehr lesen",
"min": "Min.",
"readingTime": "Lesedauer",
- "recentPosts": "Aktuelle Blogbeiträge"
+ "recentPosts": "Neuste Beiträge"
}
diff --git a/i18n/en.json b/i18n/en.json
@@ -1,4 +1,6 @@
{
+ "showAllPosts": "Show all posts",
+ "legal": "Legal",
"contact": "Contact",
"external": "External",
"pages": "Pages",
diff --git a/layouts/_partials/breadcrumb.html b/layouts/_partials/breadcrumb.html
@@ -1,10 +1,8 @@
-<nav aria-label="breadcrumb" class="nav-menu-left breadcrumb">
- <ol>
- {{ range .Ancestors.Reverse }}
- <li>
- <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
- </li>
- {{ end }}
- <li class="current-page" aria-current="page">{{ .LinkTitle }}</li>
- </ol>
-</nav>
+<ol aria-label="breadcrumb" class="breadcrumb">
+ {{ range .Ancestors.Reverse }}
+ <li>
+ <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
+ </li>
+ {{ end }}
+ <li class="current-page" aria-current="page">{{ .LinkTitle }}</li>
+</ol>
diff --git a/layouts/_partials/footer.html b/layouts/_partials/footer.html
@@ -1,89 +1,94 @@
-<div class="footer-row">
- <nav class="footer-column" id="site-navigation">
- <span class="footer-column-title">{{ T "pages" }}:</span>
- {{- partial "menu.html" (dict "menuID" "main" "page" .) -}}
- <a
- class="nav-item"
- id="rss-link"
- href="{{ absLangURL "posts" }}/index.xml"
- >{{ T "rssFeed" }}</a>
- <a
- class="nav-item"
- id="imprint"
- href="{{ absLangURL "imprint" }}"
- >{{ T "imprint" }}</a>
- <a
- class="nav-item"
- id="privacy-link"
- href="{{ absLangURL "privacy" }}"
- >{{ T "privacy" }}</a>
- </nav>
- <nav class="footer-column" id="external-links">
- <span class="footer-column-title">{{ T "external" }}:</span>
- <a
- class="nav-item"
- id="git"
- {{ if not .Site.Params.author.gitURL }}
- style="text-decoration: line-through"
- {{ else }}
- href="{{ .Site.Params.author.gitURL }}"
- {{ end }}
- >Git</a>
- <a
- class="nav-item"
- id="github"
- {{ if not .Site.Params.author.githubUser }}
- style="text-decoration: line-through"
- {{ else }}
- href="https://github.com/{{ .Site.Params.author.githubUser }}"
- {{ end }}
- >GitHub</a>
- <a
- class="nav-item"
- id="linkedin"
- {{ if not .Site.Params.autor.linkedinUser }}
- style="text-decoration: line-through"
- {{ else }}
- href="{{ .Site.Params.autor.linkedinUser }}"
- {{ end }}
- >LinkedIn</a>
- <a
- class="nav-item"
- id="twitter"
- {{ if not .Site.Params.autor.twitterUser }}
- style="text-decoration: line-through"
- {{ else }}
- href="{{ .Site.Params.autor.twitterUser }}"
- {{ end }}
- >Twitter/X</a>
- </nav>
- <div class="footer-column" id="contact-info">
- <span class="footer-column-title">{{ T "contact" }}:</span>
- <a
- class="nav-item"
- id="email"
- {{ if not .Site.Params.author.email }}
- style="text-decoration: line-through"
- {{ else }}
- href="mailto:{{ .Site.Params.author.discordID }}"
- {{ end }}
- >{{ T "email" }}</a>
- <a
- class="nav-item"
- id="discord"
- {{ if not .Site.Params.author.discordID }}
- style="text-decoration: line-through"
- {{ else }}
- href="https://discordapp.com/users/{{ .Site.Params.author.discordID }}"
- {{ end }}
- >Discord</a>
+<div>
+ <div class="footer-row">
+ <nav class="footer-column" id="site-navigation">
+ <span class="footer-column-title">{{ T "pages" }}:</span>
+ {{- partial "menu.html" (dict "menuID" "main" "page" .) -}}
+ <a
+ class="nav-item"
+ id="rss-link"
+ href="{{ absLangURL "posts" }}/index.xml"
+ >{{ T "rssFeed" }}</a>
+ </nav>
+ <nav class="footer-column" id="external-links">
+ <span class="footer-column-title">{{ T "external" }}:</span>
+ <a
+ class="nav-item"
+ id="git"
+ {{ if not .Site.Params.author.gitURL }}
+ style="text-decoration: line-through"
+ {{ else }}
+ href="{{ .Site.Params.author.gitURL }}"
+ {{ end }}
+ >Git</a>
+ <a
+ class="nav-item"
+ id="github"
+ {{ if not .Site.Params.author.githubUser }}
+ style="text-decoration: line-through"
+ {{ else }}
+ href="https://github.com/{{ .Site.Params.author.githubUser }}"
+ {{ end }}
+ >GitHub</a>
+ <a
+ class="nav-item"
+ id="linkedin"
+ {{ if not .Site.Params.autor.linkedinUser }}
+ style="text-decoration: line-through"
+ {{ else }}
+ href="{{ .Site.Params.autor.linkedinUser }}"
+ {{ end }}
+ >LinkedIn</a>
+ <a
+ class="nav-item"
+ id="twitter"
+ {{ if not .Site.Params.autor.twitterUser }}
+ style="text-decoration: line-through"
+ {{ else }}
+ href="{{ .Site.Params.autor.twitterUser }}"
+ {{ end }}
+ >Twitter/X</a>
+ </nav>
+ <nav class="footer-column" id="legal-links">
+ <span class="footer-column-title">{{ T "legal" }}:</span>
+ <a
+ class="nav-item"
+ id="imprint"
+ href="{{ absLangURL "imprint" }}"
+ >{{ T "imprint" }}</a>
+ <a
+ class="nav-item"
+ id="privacy-link"
+ href="{{ absLangURL "privacy" }}"
+ >{{ T "privacy" }}</a>
+ </nav>
+ <div class="footer-column" id="contact">
+ <span class="footer-column-title">{{ T "contact" }}:</span>
+ <a
+ class="nav-item"
+ id="email"
+ {{ if not .Site.Params.author.email }}
+ style="text-decoration: line-through"
+ {{ else }}
+ href="mailto:{{ .Site.Params.author.discordID }}"
+ {{ end }}
+ >{{ T "email" }}</a>
+ <a
+ class="nav-item"
+ id="discord"
+ {{ if not .Site.Params.author.discordID }}
+ style="text-decoration: line-through"
+ {{ else }}
+ href="https://discordapp.com/users/{{ .Site.Params.author.discordID }}"
+ {{ end }}
+ >Discord</a>
+ </div>
</div>
-</div>
-<div class="footer-row">
- <div class="footer-item">
- <span class="copyright">© {{ now.Year }} {{ .Site.Params.author.name }}</span>
- </div>
- <div class="footer-item">
- <span class="version">v{{ .Site.Params.version }}-{{ .Site.Params.versionName }}</span>
+ <div class="footer-row">
+ <div class="footer-item">
+ <span class="copyright">© {{ now.Year }} {{ .Site.Params.author.name }}</span>
+ </div>
+ <div class="footer-item">
+ <span class="version">v{{ .Site.Params.theme.version }}-{{ .Site.Params.theme.versionName }}</span>
+ </div>
</div>
</div>
diff --git a/layouts/_partials/head/css.html b/layouts/_partials/head/css.html
@@ -21,3 +21,33 @@
{{- end -}}
{{- end -}}
{{- end }}
+
+{{- with resources.Get "css/layouts.css" -}}
+ {{- if hugo.IsDevelopment -}}
+ <link rel="stylesheet" href="{{ .RelPermalink }}">
+ {{- else -}}
+ {{- with . | minify | fingerprint -}}
+ <link rel="stylesheet" href="{{ .RelPermalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous">
+ {{- end -}}
+ {{- end -}}
+{{- end }}
+
+{{- with resources.Get "css/shortcodes.css" -}}
+ {{- if hugo.IsDevelopment -}}
+ <link rel="stylesheet" href="{{ .RelPermalink }}">
+ {{- else -}}
+ {{- with . | minify | fingerprint -}}
+ <link rel="stylesheet" href="{{ .RelPermalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous">
+ {{- end -}}
+ {{- end -}}
+{{- end }}
+
+{{- with resources.Get "css/chroma.css" -}}
+ {{- if hugo.IsDevelopment -}}
+ <link rel="stylesheet" href="{{ .RelPermalink }}">
+ {{- else -}}
+ {{- with . | minify | fingerprint -}}
+ <link rel="stylesheet" href="{{ .RelPermalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous">
+ {{- end -}}
+ {{- end -}}
+{{- end }}
diff --git a/layouts/_partials/header.html b/layouts/_partials/header.html
@@ -1,27 +1,6 @@
-<div class="nav-menu">
- <nav aria-label="breadcrumb" class="nav-menu-left">
- <ol class="breadcrumb">
- {{ range .Ancestors.Reverse }}
- <li>
- <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
- </li>
- {{ end }}
- <li class="current-page" aria-current="page">{{ .LinkTitle }}</li>
- </ol>
- </nav>
- <div class="nav-menu-right">
- {{ $currentLang := .Language.Label }}
- {{ if .Translations }}
- <select
- id="language-menu"
- onchange="location = this.value;"
- aria-label="Language menu"
- >
- <option value="{{ .RelPermalink }}">{{ $currentLang }}</option>
- {{- range .Translations -}}
- <option value="{{ .RelPermalink }}">{{ .Language.Label }}</option>
- {{ end -}}
- </select>
- {{ end }}
- </div>
-</div>
+<nav>
+ {{ partial "breadcrumb.html" . }}
+ {{ if .Translations }}
+ {{ partial "language-selector.html" . }}
+ {{ end }}
+</nav>
diff --git a/layouts/_partials/language-selector.html b/layouts/_partials/language-selector.html
@@ -0,0 +1,11 @@
+{{- $currentLang := .Language.Label -}}
+<select
+ class="language-menu"
+ onchange="location = this.value;"
+ aria-label="Language menu"
+>
+ <option value="{{ .RelPermalink }}">{{ $currentLang }}</option>
+ {{- range .Translations -}}
+ <option value="{{ .RelPermalink }}">{{ .Language.Label }}</option>
+ {{ end -}}
+</select>
diff --git a/layouts/_partials/preview.html b/layouts/_partials/preview.html
@@ -1,8 +1,7 @@
<a href="{{ .RelPermalink }}" class="preview-wrapper">
<div class="preview">
{{- $wc := .WordCount }}
- {{- $microPostLen := .Site.Params.microPostLen }}
- <article class="{{ if le $wc $microPostLen }}preview-micro-post{{ else }}preview-regular-post{{ end }}" id="{{ .File.ContentBaseName }}">
+ <article class="post-preview" id="{{ .File.ContentBaseName }}">
<h2 class="preview-post-title">{{ .Title }}</h2>
{{ .Summary }}
<div class="preview-footer metadata">
diff --git a/layouts/_shortcodes/dl.html b/layouts/_shortcodes/dl.html
@@ -0,0 +1,3 @@
+<dl>
+ {{ .Inner }}
+</dl>
diff --git a/layouts/_shortcodes/dt.html b/layouts/_shortcodes/dt.html
@@ -0,0 +1,2 @@
+{{- with .Get "term" -}}<dt>{{ . | markdownify }}</dt>{{- end -}}
+{{- with .Get "definition" -}}<dd>{{ . | markdownify }}</dd>{{- end -}}
diff --git a/layouts/_shortcodes/posts.html b/layouts/_shortcodes/posts.html
@@ -1,17 +0,0 @@
-{{- $posts := where .Site.RegularPages "Section" "posts" }}
-{{- with $posts }}
- <div class="pages">
- {{- range . -}}
- <div class="page-item" id="{{ .File.ContentBaseName }}">
- {{ $dateTime := .Date | time.Format "2006-01-02T15:04:05-07:00" -}}
- {{- $dateF := .Date | time.Format ":date_short" -}}
- <span>
- <time datetime="{{ $dateTime }}">{{ $dateF }}</time>:
- </span>
- <div>
- <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
- </div>
- </div>
- {{- end }}
- </div>
-{{- end }}
diff --git a/layouts/_shortcodes/quote.html b/layouts/_shortcodes/quote.html
@@ -1,10 +1,17 @@
+{{- $citation := .Get "citation" -}}
+{{- $source := .Get "source" -}}
<blockquote>
-<div class="quote">
- {{- .Inner | markdownify -}}
-</div>
-{{- with .Get "citation" -}}
- <div class="citation">
- — {{ . | markdownify }}
+ <div class="quote">
+ {{- .Inner | markdownify -}}
</div>
-{{- end -}}
+ {{- if $citation -}}
+ <div class="citation">
+ — {{ $citation | markdownify -}}
+ {{- if $source -}}
+ <span class="source">
+ {{ $source | markdownify -}}
+ </span>
+ {{- end -}}
+ </div>
+ {{- end -}}
</blockquote>
diff --git a/layouts/_shortcodes/small.html b/layouts/_shortcodes/small.html
@@ -1,3 +0,0 @@
-<span class="small-text">
- {{ .Inner | markdownify }}
-</span>
diff --git a/layouts/home.html b/layouts/home.html
@@ -8,4 +8,28 @@
{{ end }}
{{ .Content }}
</article>
+<hr>
+<div class="recent-posts">
+ <h2 class="title">{{ T "recentPosts" }}</h2>
+ <div class="row">
+ {{ range first 3 (where site.RegularPages "Type" "posts") }}
+ <a class="recent-post-wrapper" href="{{ .RelPermalink }}">
+ <article class="recent-post">
+ <h3>{{ .Title }}</h3>
+ <div class="preview-footer metadata">
+ {{- $dateTime := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
+ {{- $dateF := .Date | time.Format ":date_medium" }}
+ {{- $timeF := .Date | time.Format ":time_short" }}
+ <time id="publication-date-time" datetime="dateTime">{{ $dateF }}, {{ $timeF }}</time>
+ <span class="seperator">·</span>
+ <span class="reading-time">{{ .ReadingTime }} MIN</span>
+ </div>
+ </article>
+ </a>
+ {{ end }}
+ </div>
+ <nav class="post-nav">
+ <a href="{{ absLangURL "posts" }}" class="nav-item">{{ T "showAllPosts" }}</a>
+ </nav>
+</div>
{{ end }}
diff --git a/layouts/taxonomy.html b/layouts/taxonomy.html
@@ -2,10 +2,10 @@
<article>
<h1>{{ .Title }}</h1>
{{ .Content -}}
+ <ul class="tags-list">
+ {{- range .Pages -}}
+ <li>{{- partial "tag.html" . -}}</li>
+ {{- end -}}
+ </ul>
</article>
- <ul class="tags-list">
- {{- range .Pages -}}
- <li>{{- partial "tag.html" . -}}</li>
- {{- end -}}
- </ul>
{{ end }}
diff --git a/layouts/term.html b/layouts/term.html
@@ -5,20 +5,20 @@
{{ . }}
<hr>
{{ end }}
- </article>
- <div class="pages">
- {{- range .Pages }}
- <div class="page-item" id="{{ .File.ContentBaseName }}">
- {{ $dateTime := .Date | time.Format "2006-01-02T15:04:05-07:00" -}}
- {{- $dateF := .Date | time.Format ":date_medium" -}}
- {{- $timeF := .Date | time.Format ":time_short" -}}
- <div>
- <span><time datetime="{{ $dateTime }}">{{ $dateF }} {{ $timeF }}</time>:</span>
- </div>
- <div>
- <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
+ <div class="pages">
+ {{- range .Pages }}
+ <div class="page-item" id="{{ .File.ContentBaseName }}">
+ {{ $dateTime := .Date | time.Format "2006-01-02T15:04:05-07:00" -}}
+ {{- $dateF := .Date | time.Format ":date_medium" -}}
+ {{- $timeF := .Date | time.Format ":time_short" -}}
+ <div>
+ <span><time datetime="{{ $dateTime }}">{{ $dateF }} {{ $timeF }}</time>:</span>
+ </div>
+ <div>
+ <a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
+ </div>
</div>
- </div>
- {{- end }}
- </div>
+ {{- end }}
+ </div>
+ </article>
{{ end }}