Meta: Spring cleaning

Added syntax highlighting, remove font, many small improvements.
Hot fix font: Athelas shows weird symbols in Chrome.
This commit is contained in:
Jan Kremer 2024-04-01 22:42:52 +02:00
parent 138062aac8
commit f91ff03006
Signed by: jan
GPG key ID: A7DA689CB3B078EC
19 changed files with 74 additions and 54 deletions

View file

@ -1,32 +1,46 @@
@font-face {
font-family: "EB Garamond";
src:
/* local("EB Garamond"), */
url("/fonts/EBGaramond-VariableFont_wght.ttf");
/* font-weight: normal; */
/* font-style: normal; */
/* font-display: swap; */
}
:root {
font-size: calc(1rem + 0.25vw);
--red: #FC361D;
--blue1: #116080;
--blue2: #105099;
--light-gray: #F0F0F0;
--white: white;
--beige: #FCF9EC;
--text1: #1a1a1a;
--text2: #6f6f6f;
--text3: #999999;
--red: oklch(65% 0.25 30);
--blue1: oklch(50% 0.1 230);
--blue2: oklch(40% 0.1 230);
--light-gray: oklch(95% 0 0);
--white1: oklch(100% 0 0);
--text1: oklch(20% 0 0);
--text2: oklch(50% 0 0);
--text3: oklch(70% 0 0);
}
code {
background: #eff1f5;
border-radius: 0.3em;
padding: 0.1em 0.2em;
font-size: 0.9em;
}
.highlight {
border-radius: 0.3rem;
padding: 0.5em 0.5em;
margin: 1rem 0;
background: #eff1f5;
overflow: auto;
& code {
margin: 0;
padding: 0;
}
& pre {
margin: 0;
padding: 0;
}
}
body {
color: var(--text);
background: var(--background);
font-family: "eb garamond", serif;
font-family: "EB Garamond", Constantia, "Lucida Bright", Lucidabright, "Lucida Serif", Lucida, "DejaVu Serif", "Bitstream Vera Serif", "Liberation Serif", Athelas, Georgia, serif;
/* font-family: -apple-system, BlinkMacSystemFont, "Avenir Next", Avenir, "Nimbus Sans L", Roboto, Noto, "Segoe UI", Arial, Helvetica, "Helvetica Neue", sans-serif; */
font-variant-numeric: oldstyle-nums;
/* font-variant-ligatures: common-ligatures; */
line-height: 1.5;
margin: auto;
padding: 1rem;
@ -73,6 +87,10 @@ article>p:nth-of-type(2)::first-letter {
a {
color: var(--red);
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
h1 {
@ -134,21 +152,18 @@ footer {
}
.list {
color: var(--text1);
& h2 {
margin-top: 2rem;
margin-bottom: 0;
& a {
color: var(--text1);
}
}
.lead {
margin: 0;
font-size: 1rem;
text-align: left;
text-decoration: none;
}
}

View file

@ -18,19 +18,19 @@ As of [RFC ...]()
There are famously [no easter eggs](https://daniel.haxx.se/blog/2021/12/06/no-easter-eggs-in-curl/) built into `curl`. That doesn't mean I can't make my own.
I set up `txt` files to display QR codes, which you can access via `curl`.There is one for the homepage, which is kind of stupid because you have to type in the URL to get a QR code for that URL.
I set up `txt` files to display QR codes, which you can access via `curl`. There is one for the homepage, which is kind of stupid because you have to type in the URL to get a QR code for that URL.
```shell
```bash
curl https://jankremer.eu/qr.txt
```
I also set up codes for my [crypto](/tags/crypto) addresses. Just add `.txt` to the URL. Same for my [avatar](/pharmacist-0.webp). Fun fact: the `.png` file is only half the size of the `.txt` version.
```shell
```bash
curl https://jankremer.eu/xmr.txt
```
```shell
```bash
curl https://jankremer.eu/pharmacist-0.txt
```

View file

@ -3,16 +3,15 @@ languageCode = 'de'
title = 'Jan Kremer'
copyright = 'CC-BY-SA 4.0'
[markup]
[markup.highlight]
style = "catppuccin-latte"
[params]
[params.author]
name = 'Jan Kremer'
email = 'mail@jankremer.eu'
[[menus.main]]
name = 'Home'
pageRef = '/'
weight = 10
[[menus.main]]
name = 'Blog'
pageRef = '/blog'

View file

@ -1,16 +1,17 @@
{{ define "main" }}
{{ .Content }}
<h1>Neueste Beiträge</h1>
{{ $pages := .Paginate (where .Site.RegularPages "Type" "ne" "page") }}
{{ range $pages.Pages }}
<div class="list">
{{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
{{ $dateHuman := .Date | time.Format "2006-01-02" }}
<time datetime="{{ $dateMachine }}">{{ $dateHuman }}</time>
<a href="{{ .RelPermalink }}" style="display:block">
<div class="list">
{{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
{{ $dateHuman := .Date | time.Format "2006-01-02" }}
<time datetime="{{ $dateMachine }}">{{ $dateHuman }}</time>
<h2><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></h2>
<h2>{{ .Title }}</h2>
<p class="lead">{{ .Description }}</p>
</div>
<p class="lead">{{ .Description }}</p>
</div>
</a>
{{ end }}
{{ end }}

View file

@ -1,14 +1,16 @@
{{ define "main" }}
{{ .Content }}
{{ range .Pages }}
<div class="list">
{{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
{{ $dateHuman := .Date | time.Format "2006-01-02" }}
<time datetime="{{ $dateMachine }}">{{ $dateHuman }}</time>
<a href="{{ .RelPermalink }}" style="display:block">
<div class="list">
{{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}
{{ $dateHuman := .Date | time.Format "2006-01-02" }}
<time datetime="{{ $dateMachine }}">{{ $dateHuman }}</time>
<h2><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></h2>
<h2>{{ .Title }}</h2>
<p class="lead">{{ .Description }}</p>
</div>
<p class="lead">{{ .Description }}</p>
</div>
</a>
{{ end }}
{{ end }}

View file

@ -1,2 +1,2 @@
<p><a href="https://creativecommons.org/licenses/by-sa/4.0/">BY-SA 4.0</a> &emsp;&emsp; {{ site.Title }} &emsp;
<p><a href="https://creativecommons.org/licenses/by-sa/4.0/">CC-BY-SA 4.0</a> &emsp;&emsp; {{ site.Title }} &emsp;
&emsp; 2021{{ now.Year }}</p>

View file

@ -1,6 +1,9 @@
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>{{ if .IsHome }}{{ site.Title }}{{ else }}{{ printf "%s | %s" .Title site.Title }}{{ end }}</title>
<meta charset="UTF-8">
<meta name="description" content="Blog von Jan Kremer">
<meta name="keywords" content="Blog">
<meta name="author" content="Jan Kremer">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{{ if .IsHome }}{{ site.Title }}{{ else }}{{ printf "%s %s" .Title site.Title }}{{ end }}</title>
{{ partialCached "head/css.html" . }}
{{ partialCached "head/js.html" . }}
{{ partial "analytics.html" . }}