Wayfinder map: M1 editor presentation — substrate decision #16
Notifications
Due Date
No due date set.
Blocks
#19 Wayfinder map: M1 editor core — open, edit, autosave (S1.2)
AlexKucera/museion
Reference: AlexKucera/museion#16
Reference in new issue
Block a user
Destination
ADR-0010 agreed — editor substrate and presentation mode chosen, typography stance set, fork-sharing arrangement with Classis fixed, v2 upgrade path recorded — backed by three throwaway spike prototypes on branch
spike/editor-presentationthat anyone can open and compare side by side.Notes
spike/editor-presentation— prose inspike/prose/, one directory per substrate (spike/codeedit/,spike/textkit2/,spike/blocks/). Disjoint dirs; rebase before push.ref/Web-Prototype/museion-workspace.html(fix-card list, stale-anchor alert wording); tokens perref/Web-Prototype/DESIGN-HANDOFF.md.prototype(spikes),grilling+domain-modeling(verdict),swiftui+swift6-concurrency(all Swift work). Spikes stay ponytail-cheap: the least code that answers the question.AlexKucera/CodeEditSourceEditor0.15.8-helm(revision 3ce6007). Default arrangement: Museion pins the same fork.docs/AGENTS.md.Decisions so far
Spike corpus: pin the eight posts as markdown: eight posts + PERF-3k (3452 words) pinned on
spike/editor-presentation@ 3b3544e; calibration inventory corrected — no blockquote/italics in source, epigraph is plain prose in curly quotes.Spike B: NSTextView/TextKit2 with custom attributes: all criteria PASS — editing/undo/IME native and free, presentation is a flat line-kind→attribute map (no TextKit surgery), PERF-3k load ≤1.1 ms + anchor search 2.4 ms, live per-paragraph restyle with no hitching; quote-anchor highlight + exact stale-alert UX proven; reading mode lands block-aware (blank-line split + inline parse per paragraph, headings fonted) — single-Text
.fullflatten is the anti-pattern; renderer stance for the ADR. Code:spike/textkit2/@ dd3542a+d836083.Spike C: SwiftUI block editor (live preview): typography/perf/anchor PASS (mode C is the reading view itself); honest ceilings — no cross-block selection, per-block undo only, paste-merge semantics to decide. Code:
spike/blocks/@986f435.Spike A: CodeEditSourceEditor fork as prose editor (mode B, anchor proof): anchor proof CLEAN (EmphasisManager outline + scroll, 2.5 ms PERF-3k search, exact stale-alert UX); mode B works via regex highlight pass but typography is substrate-limited — one font size for everything, no paragraph spacing (EditorTheme/attributesFor), mid-word wrap at typographic apostrophe (don't-split), emphasis CATextLayer ghost-doubles any colored span (fork bug, API-unescapeable); integration traps: @preconcurrency imports, resource bundles in .app, sRGB-only theme colors, @State-during-makeNSViewController dropped. Code:
spike/codeedit/@f31af14.Verdict: substrate decision + ADR-0010: native TextKit2 mode B wins by the tie-breaker — Alexander's live side-by-side confirmed C's ceiling (bullet lists shatter into per-bullet blocks) and A can't reach typographic calm. Variable heading sizes + paragraph spacing required; reading toggle block-aware; anchor re-proof satisfied live in B; CodeEdit exits Museion, Classis pin untouched; Paper-grade polish = iterative practice, not a deferred phase. ADR-0010 in the working tree (
docs/adr/0010-native-textkit2-prose-editor.md, uncommitted; issue-asset upload 500s on this Gitea).Not yet specified
(none — the way to the destination is clear)
Out of scope
[Generated by AI]
AlexKucera referenced this issue2026-08-28 18:33:07 +02:00
M1: Editor presentation spike — substrate decisionto Wayfinder map: M1 editor presentation — substrate decision