From 4763716990130392a9cd03242804f6e405d5add6 Mon Sep 17 00:00:00 2001 From: Sam Anthony Date: Mon, 16 Mar 2026 17:02:46 -0400 Subject: et-book font --- .gitmodules | 3 +++ assets/aoidh.css | 16 +--------------- assets/fonts/et-book | 1 + layouts/_partials/head.html | 15 ++++++++++++--- 4 files changed, 17 insertions(+), 18 deletions(-) create mode 100644 .gitmodules create mode 160000 assets/fonts/et-book diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..c1ea0b4 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "assets/fonts/et-book"] + path = assets/fonts/et-book + url = https://github.com/edwardtufte/et-book.git diff --git a/assets/aoidh.css b/assets/aoidh.css index ddc6ee4..188ffce 100644 --- a/assets/aoidh.css +++ b/assets/aoidh.css @@ -28,8 +28,7 @@ body { } body { - font-family: 'IBM Plex Serif', Charter, 'Bitstream Charter', 'Sitka Text', serif; - font-weight: 400; + font-family: et-book, Palatino, "Palatino Linotype", "Palatino LT STD", "Book Antiqua", Georgia, serif; line-height: 1.3em; text-rendering: optimizeLegibility; color: #000; @@ -71,14 +70,9 @@ nav a { } li.nav-active a { - font-weight: 600; box-shadow: .2rem .2rem var(--dark-yellow); } -li.nav-ancestor a { - font-weight: 600; -} - nav a:active { box-shadow: 0 0; text-decoration: none; @@ -93,7 +87,6 @@ p { } a { - font-weight: 450; text-decoration: none; border: 1px solid transparent; } @@ -117,17 +110,14 @@ a:active { h1 { font-size: 1.15rem; - font-weight: 700 } h2 { font-size: 1.10rem; - font-weight: 600; } h3 { font-size: 1.05rem; - font-weight: 500; } h1, h2, h3 { @@ -157,10 +147,6 @@ th, td { vertical-align: middle; } -th, th * { - font-weight: 500; -} - footer { margin-top: 2rem; } diff --git a/assets/fonts/et-book b/assets/fonts/et-book new file mode 160000 index 0000000..24d3a3b --- /dev/null +++ b/assets/fonts/et-book @@ -0,0 +1 @@ +Subproject commit 24d3a3bbfc880095d3df2b9e9d60d05819138e89 diff --git a/layouts/_partials/head.html b/layouts/_partials/head.html index 2720637..463dabb 100644 --- a/layouts/_partials/head.html +++ b/layouts/_partials/head.html @@ -1,6 +1,15 @@ {{ if .IsHome }}{{ site.Title }}{{ else }}{{ printf "%s | %s" .Title site.Title }}{{ end }} -{{- with resources.Get "aoidh.css" | minify }} - -{{- end }} + +{{ range slice "aoidh.css" "fonts/et-book/et-book.css" }} + {{- with resources.Get . }}{{ end }} +{{ end }} + +{{- range $style := slice "roman-line-figures" "display-italic-old-style-figures" "bold-line-figures" }} + {{- range $fmt := slice "eot" "woff" "ttf" "svg" }} + {{- $font := printf "fonts/et-book/et-book/et-book-%s/et-book-%s.%s" $style $style $fmt }} + {{- with resources.Get $font }}{{ .Publish }} + {{- else }}{{ errorf "font not found: %s" $font }}{{ end }} + {{- end -}} +{{- end -}} -- cgit v1.2.3