Materialize the trash — store, undo, and the container universe

Phase 2 swaps every consumer: Liveness and its ancestor walk are gone,
replaced by ItemContainer — a UUID set plus the container side it
lives on, presence the whole test, one selection boundary instead of
the old liveness law. Deletion stages by place: board cards move to
the trash at a store-minted head rank, trash-side delete is permanent
behind its confirmation, Delete Immediately skips the trash from
anywhere, lane delete captures the subtree and removes the folder.
Restore has no method at all — moveCards resolves members in either
container, so drag-out and cut-paste are the ordinary moves 13 calls
them, registering ordinary Move steps. The delete inverse moves the
card back to its captured lane and rank; redo replays the captured
trash rank, a value the gesture actually wrote; lane undo recreates
the subtree byte-faithfully in session. Purges register nothing —
where 13's trash section contradicts its own Rules on that, Rules
wins, filed for ruling. Staleness collapsed to present-or-absent: a
container is a path, so a foreign restore fails the delete step's
expectation structurally. Legacy tombstones migrate on the loose-file
tail hook, cards oldest-first so minting above top reproduces the
retired newest-first column, lanes returning live, one folded loss
row naming both directions. Put Back, restoreByDrag,
receiveRestoredCards, TrashEntry, and the kind machinery are deleted;
the trash column renders the container correctly with its full face
rework left to phase 3.

Claude-Session: https://claude.ai/code/session_01SR4XGjmBE16ZUYWpfFHXwY
This commit is contained in:
2026-07-28 17:47:56 -04:00
parent 16c10d61c3
commit 53bc71f7fb
53 changed files with 3459 additions and 3655 deletions
+6 -6
View File
@@ -30,7 +30,7 @@ final class MarqueeSession {
private(set) var current: CGPoint = .zero
/// The side of the live/trash boundary this band selects on, frozen at `begin`.
private(set) var side: Liveness = .live
private(set) var container: ItemContainer = .board
/// How far the pointer must travel before a drag on empty space becomes a band. Larger than the
/// lane header's threshold because this gesture arms on *any* empty surface, and a click that
@@ -51,10 +51,10 @@ final class MarqueeSession {
)
}
func begin(at point: CGPoint, side: Liveness) {
func begin(at point: CGPoint, in container: ItemContainer) {
origin = point
current = point
self.side = side
self.container = container
}
func update(to point: CGPoint) {
@@ -81,9 +81,9 @@ final class MarqueeSession {
/// is on screen. It is also what makes the band correct for free across a lane resize, a reorder in
/// flight, and a foreign reload the frames simply re-register.
///
/// **Lanes are never registered.** The band selects cards, and trash rows on the trash side; a lane
/// has no entry here at all, which is 04-interactions.md § Selection's "click-drag rubber-bands
/// across lanes" made structural rather than filtered.
/// **Lanes are never registered.** The band selects cards board cards or trash cards; a lane has
/// no entry here at all, which is 04-interactions.md § Selection's "click-drag rubber-bands across
/// lanes" made structural rather than filtered.
///
/// It is also the **begin guard's** universe: a drag that starts inside a registered frame belongs
/// to that item's own gesture (a card drag, a drag out of the trash), never to the band. Deciding