feat(fix-cards): jump to the anchor
Jump on a Fix Card selects the anchor's span in the piece's editor and makes the main window key (#204). The span is the card's quote at its 1-based occurrence, resolved against the LIVE session text so a dirty buffer still lands, and it rides the reading flip-back's caret rail: caretHint widens from a (location, token) tuple to FixCardRevealRequest (SwiftLint large_tuple), one shared token counter so a jump and a flip-back can never collide, a zero-length range stays a bare caret and a non-zero range selects. A jump leaves reading mode first (reading = false, not exitReading, which stamps its own zero-length hint), writes nothing, and re-fires per click. The palette offers Jump on every non-stale card that still shows an action row; stale anchors have nothing to land on. The landing math is ProseTextView.landingSpan - a bare caret hops past leading blanks, a span never does (a quote that IS the leading blanks selects those blanks) - and appliedText now routes through anchorRange so Apply and Jump share one occurrence math. Two review rounds closed the view-layer gaps the pure pins could not see: a jump dropped in reading mode; a main window that never became key (NSApp.activate is a no-op once the palette's click activated the app - the Coordinator makes tv.window key instead); a cursor record taken before the scroll. +3 tests (anchorRange occurrence math with a UTF-16 fixture, the model's reveal stamp, landingSpan), each flip-verified. Rail 732/732; SwiftFormat and SwiftLint clean. DOX: Museion/AGENTS, MuseionTests/AGENTS, GLOSSARY gains Jump.
This commit is contained in:
1 parent
d183d735d7
commit
97893147a6
10 files changed
+259
-52
No files matched your search
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file. The format
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
### Added
|
||||
|
||||
- **fix cards:** **Jump** on a Fix Card selects the anchor's span in the piece's editor and makes the main window key (#204) — the borderless button sits in every non-stale card's action row (closed cards keep it; a stale anchor has nothing to land on); the span is the card's quote at its 1-based occurrence, resolved against the LIVE session text so a dirty buffer still lands, and it rides the reading flip-back's caret rail (one token counter; a zero-length hint stays a bare caret, a non-zero range selects). A jump leaves reading mode first, writes nothing, and re-fires on every click. Two review rounds closed the view-layer gaps the pure pins could not see: a jump dropped in reading mode, a main window that never became key (`NSApp.activate` is a no-op once the palette's click activated the app), a leading-blank caret hop that moved a span onto the title, and a cursor record taken before the scroll. +3 tests (`anchorRange` occurrence math with a UTF-16 fixture, the model's reveal stamp, the editor's `landingSpan`), all flip-verified. Suite 732
|
||||
|
||||
## [0.1.2] - 2026-12-03
|
||||
|
||||
Human-readable notes: [docs/releases/0.1.2.md](docs/releases/0.1.2.md).
|
||||
|
||||
Reference in new issue
Block a user