also looking at this
feat: finish native customization and platform seams
#401
21 files
+707
-17
Review threads live on the whole diff, not on one commit, so none are shown here - a thread's line means something in the branch's final form, and painting it into an intermediate step would put it on code it is not about.
| @@ -2629,6 +2629,8 @@ describe('Craft iOS builder', () => { | ||
| 2629 | 2629 | expect(watch).toContain('protocolVersion') |
| 2630 | 2630 | expect(watch).toContain('requestId') |
| 2631 | 2631 | expect(watch).toContain('stateVersion') |
| 2632 | expect(watch).toContain('guard incomingVersion >= stateVersion else { return }') | |
| 2633 | expect(watch).toContain('stateVersion = incomingVersion') | |
| 2632 | 2634 | expect(watch).toContain('planned-session') |
| 2633 | 2635 | expect(watch).toContain('craft.watch.state.v1') |
| 2634 | 2636 | expect(watch).toContain('updateApplicationContext(state)') |
| @@ -117,6 +117,10 @@ final class CraftWatchSession: NSObject, ObservableObject { | ||
| 117 | 117 | } |
| 118 | 118 | |
| 119 | 119 | private func apply(_ payload: [String: Any]) { |
| 120 | if let incomingVersion = payload["stateVersion"] as? Int { | |
| 121 | guard incomingVersion >= stateVersion else { return } | |
| 122 | stateVersion = incomingVersion | |
| 123 | } | |
| 120 | 124 | if let plan = payload["plan"] as? [String: Any], payload["type"] as? String == "planned-session" { |
| 121 | 125 | plannedSession = plan |
| 122 | 126 | status = "Plan ready" |