From 7db08ea821fa404d6b444a0dbbf39d02d826d5d6 Mon Sep 17 00:00:00 2001 From: Leo Vasanko Date: Mon, 17 Aug 2026 02:54:12 +0000 Subject: [PATCH] Fix new-page flow, save/delete semantics, add Cormorant font MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - New-page flow: slug placeholder shows the slug derived live from the title (placeholders keep browser-default styling; slug values no longer muted). Committing PUTs empty markdown, which now creates an empty page rendering with its title instead of 404, then hands over to the page editor (CodeMirror focuses on mount) - Saving never deletes: REST PUT and WS save store empty content as an empty page; deletion is the page editor's explicit choice — saving trimmed-empty text issues a REST DELETE - Fonts: add Cormorant (variable 300-700, normal+italic) to the serif picks, replacing single-weight Gloock; Playfair Display files kept on disk but not offered --- AGENTS.md | 13 ++- docs/design-principles.md | 6 +- frontend/src/PageEditor.vue | 12 ++- frontend/src/SiteEditor.vue | 12 ++- frontend/src/StructureTree.vue | 4 +- frontend/src/assets/fonts/cormorant-OFL.txt | 93 ++++++++++++++++++ .../src/assets/fonts/cormorant-italic.woff2 | Bin 0 -> 38140 bytes frontend/src/assets/fonts/cormorant.woff2 | Bin 0 -> 35340 bytes frontend/src/assets/fonts/fonts.css | 4 + .../src/assets/fonts/playfairdisplay-OFL.txt | 93 ++++++++++++++++++ .../assets/fonts/playfairdisplay-italic.woff2 | Bin 0 -> 38804 bytes .../src/assets/fonts/playfairdisplay.woff2 | Bin 0 -> 38404 bytes frontend/src/assets/pagerite.css | 2 + pagerite/app.py | 48 +++++---- 14 files changed, 248 insertions(+), 39 deletions(-) create mode 100644 frontend/src/assets/fonts/cormorant-OFL.txt create mode 100644 frontend/src/assets/fonts/cormorant-italic.woff2 create mode 100644 frontend/src/assets/fonts/cormorant.woff2 create mode 100644 frontend/src/assets/fonts/playfairdisplay-OFL.txt create mode 100644 frontend/src/assets/fonts/playfairdisplay-italic.woff2 create mode 100644 frontend/src/assets/fonts/playfairdisplay.woff2 diff --git a/AGENTS.md b/AGENTS.md index 055414d..91b6ace 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -94,7 +94,8 @@ not for the public pages. See `docs/design-principles.md` for the design. under `/_assets/`: `pagerite.css` (base layout + conservative variables), `themes/purple/theme.css` (the purple/dark theme override, including its own `banner.svg`), `pygments.css`, and `fonts/` (self-hosted Source - Sans 3/Source Serif 4/Fraunces/Literata/Inter/Montserrat/Fira Code + Sans 3/Source Serif 4/Fraunces/Literata/Cormorant/Playfair + Display/Inter/Montserrat/Fira Code variable woff2). The `::view-transition*` block at the end of `pagerite.css` (from termotohtori.fi) is fragile — do not tweak. - Vite builds ES-module `.js` outputs; the backend renders `