Grilling: pivot reading renderer to apex HTML pipeline #73
Notifications
Due Date
No due date set.
Blocks
#72 Grilling: calibration pass — rule calm or not
AlexKucera/museion
Reference: AlexKucera/museion#73
Reference in new issue
Block a user
Part of #20
Question
Pivot the reading renderer from hand-rolled TextKit to apex → HTML → WKWebView + our CSS? Edit mode stays TextKit (ADR-0010 mode B untouched); only the reading half is in play. Resolves: the pivot verdict itself, apex bundling strategy, fate of the TextKit reading renderer (+ the known stale-flow defect), the source-position mapping mechanism for click-to-edit/scroll-sync, and the execution-extension of this map (spike → verdict ADR → rebuild chain replacing the TextKit renderer work, with #72 remaining the terminal gate).
Facts pinned 2026-10-06 (probed live, apex 1.1.17 via brew):
1. 1. 1.auto-renumbering, table alignment, quotes, fenced code all render correctly — #69's entire rendered scope plus footnotes/math/metadata we never hand-rolled.data-source-lineon top-level elements — paragraph-level granularity, matching #68's "caret at paragraph start" contract.[Generated by AI]
AlexKucera referenced this issue2026-10-06 15:30:27 +02:00
Resolution
The pivot lands. Reading renderer = apex → HTML → WKWebView + our CSS; editing side stays TextKit (ADR-0010 mode B). Ruled by Alexander 2026-10-06:
Probed facts (apex 1.1.17, live): MIT license; kitchen-sink 1.4K → 17 ms wall incl. spawn; PERF-3k 21K → 19 ms; no source positions in any output format (HTML/pandoc JSON/ast-json) — click-to-edit + scroll-sync map via our blank-line chunker stamping
data-source-linepost-pass, paragraph granularity, matching #68's "caret at paragraph start" contract. Apex plugins (pandoc-style filters) cannot recover positions the AST never carries.Folded (no veto): typography slots + flow knobs become CSS custom properties injected at load, Settings pane unchanged; WKWebView specifics (baseURL, CSP, ⌘-click, first-paint) are spike-scope details.
[Generated by AI]