The Background tab fills in — facets rendered to order, eight hues in a carousel

Claude-Session: https://claude.ai/code/session_01SR4XGjmBE16ZUYWpfFHXwY
This commit is contained in:
2026-08-07 16:08:29 -04:00
parent 56e37be158
commit fb96e30df0
19 changed files with 3031 additions and 38 deletions
+3 -1
View File
@@ -271,6 +271,8 @@ public final class CardWindowUndo {
return .path(url.standardizedFileURL)
}
private static let fieldOrder: [ExpectedField.Kind] = [.title, .order, .width, .background, .icon, .body]
private static let fieldOrder: [ExpectedField.Kind] = [
.title, .order, .width, .background, .backgroundImage, .icon, .body,
]
}
}
+12
View File
@@ -30,6 +30,15 @@ public enum ExpectedField: Sendable, Equatable {
/// `background` the styling gesture's colour dimension.
case background(String?)
/// The `background` mapping's **`image` subkey** the generated-background gesture's other half
/// (`BoardStore.applyGeneratedBackground`).
///
/// Its own case rather than a second reading of `.background`, because they are two independent
/// values under one key: a board can have its colour changed from the wells while its image
/// stays, and the step that wrote the image must not stale because somebody picked a colour
/// afterwards. `nil` is the absent subkey, exactly as everywhere else here.
case backgroundImage(String?)
/// `icon` the styling gesture's symbol dimension.
case icon(String?)
@@ -46,6 +55,7 @@ public enum ExpectedField: Sendable, Equatable {
case .order: .order
case .width: .width
case .background: .background
case .backgroundImage: .backgroundImage
case .icon: .icon
case .body: .body
}
@@ -58,6 +68,7 @@ public enum ExpectedField: Sendable, Equatable {
case order
case width
case background
case backgroundImage
case icon
case body
}
@@ -319,6 +330,7 @@ public enum HistoryStaleness {
case let .order(expected): document.order.value == expected
case let .width(expected): equal(document.width, expected)
case let .background(expected): equal(document.background, expected)
case let .backgroundImage(expected): equal(document.backgroundImage, expected)
case let .icon(expected): equal(document.icon, expected)
case let .body(expected): document.body == expected
}