AlexKucera
4cb753d17f
feat(reading): polish typography, externalize CSS
...
Critique-directed polish of the reading surface (#72 ruling: pipeline
calm, surface not-calm) plus the single-user typography rework:
- Flow: leading 1.5, paragraph gap tightened; heading ladder rescaled
(h1 1.15x / h2 0.85x / h3 body-face semibold) with cling margins,
hN+hN suppression, no title dead space
- Constructs: confident blockquote (near-ink text, 3px rail, nesting
degrades), booktabs tables, tinted code panels, relative inline code
- Fonts hardcoded for Alexander's faces: Valkyrie OT B 17 body,
Concourse OT Semibold headings, UbuntuMono 14 code; 66ch measure
- Stylesheet moved to Museion/Resources/reading.css, read fresh per
page build — Debug builds load the repo copy (#filePath), so CSS
edits hot-reload on the next reading toggle
- Settings Typography/Text Flow sections and all flow-key plumbing
deleted (56 insertions, 417 deletions)
Refs #72 , #78 . Detector: 192 findings -> 0. Build + 93 tests green.
[Generated by AI]
2026-10-07 17:02:10 +02:00
AlexKucera
6d7d1411a2
feat(editor): configurable text flow — line height + spacing knobs ( #71 follow-up 7)
...
Three UserDefaults-backed knobs in ProseTypography (line-height multiple,
space-after-¶ and space-after-heading in body lines, clamped), surfaced
in Settings → Text Flow. Also fixes two real bugs from the last commit:
paragraphSpacing was set to 1.25 POINTS (now lines × linePoints), and
reading-mode body paragraphs never received the rhythm at all (they rode
the editing surface's fixed 10pt) — both surfaces now share one rhythm.
2026-10-06 13:43:43 +02:00
AlexKucera
4c91733e78
feat(editor): land reading toggle — render, interact, typography slots (S1.2 #71 )
...
Map #20 execution child, built per decisions #68/#69/#70:
- ReadingPresenter: block-aware renderer (ADR-0010 stance) — blank-line
split, one block per chunk; lists (bullets + ordered + nesting +
auto-renumber via per-level counters — one rendering path), headings
by level (h1 = slot size, h2 = 0.77x, ### = body+1, #### floors at
bold body), HR via the editing syntaxOnly predicate, fenced code,
blockquotes (QuoteTextBlock hairline), tables (NSTextTable 1px
border, delimiter-row alignment), images (hover payload), links
styled + retained. Footnotes stay fallback. Source ranges ride every
block (click→edit map).
- ReadingSurface: read-only selectable NSTextView canvas (#68 : a
presentation of the same TextKit2 document). Tap with no selection
after mouseDown returns = edit intent at the clicked block (the
tracking-loop fix); ⌘-click opens links; scroll tracking feeds the
flip-back caret; image hover NSPopover loads off-main.
- ProseTypography (#70 ): three role slots — Body / Headings / Code —
each {face, size}, UserDefaults six values, member-based font
resolution (family+weight lookup misresolves Concourse Book→Thin),
silent system fallback; both prose surfaces read them; editing
presenter's headings + dimmed syntax rewired through the slots.
- PostEditorView: Read⇄Edit toolbar button (far left) + View menu
"Toggle Reading Mode" + ⌘R; reading state transient per open; drafts
included (draft mirror); flip-back caret hint applied once per token.
- SettingsPaneView: Typography section — three slot rows (family
picker incl. current face not in the installed list + size field).
- kitchen-sink.md (+png): corpus piece exercising constructs absent
from the eight posts, per #69 .
Verified: 94 unit tests (renderer classification, renumbering, source
ranges, fallbacks) + UI smoke; PERF-3k renders 128 blocks in ~17 ms;
live-app probe — Read renders kitchen-sink markers-hidden, renumbered,
byte-stable file after full round-trip; click-to-edit flips at the
clicked paragraph; typography ladder pixel-verified (20/15 ink px).
2026-10-05 15:51:28 +02:00