Skip to content

Commit 9aa296f

Browse files
hyperpolymathclaude
andcommitted
fix: wire VideoCoordination panel into TEA architecture (108 panels)
VideoCoordination was orphaned — component/engine/commands existed but were not integrated into the core loop. Now fully wired: - Model.res: include + field + init - Msg.res: videoCoordinationMsg type + dispatch variant - PanelSwitcherModel: PanelVideoCoordination variant - PanelRegistry: metadata entry - View.res: routing - Update.res: dispatch to UpdateVideoCoordination - New: src/update/UpdateVideoCoordination.res Oo7Toolchain was already fully wired — verified, no changes needed. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent c2056e6 commit 9aa296f

10 files changed

Lines changed: 64 additions & 6 deletions

File tree

src/Model.res

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ include ProvenanceModel
105105

106106
/// Re-export 007 Toolchain types for agentic compiler and high-rigor execution.
107107
include Oo7ToolchainModel
108+
include VideoCoordinationModel
108109

109110
/// Re-export AI types (aiProviderId, aiProviderConfig, aiProviderStatus,
110111
/// aiMessage, aiCategory, aiState) for the multi-provider AI neural interface
@@ -418,6 +419,8 @@ type model = {
418419
aerie: aerieState,
419420
// 007 Toolchain — agentic compiler and high-rigor execution (Groove)
420421
oo7toolchain: oo7State,
422+
// VideoCoordination — Drive-to-Photos batch transfer dashboard
423+
videoCoordination: videoCoordinationState,
421424
// Interfaces — Idris2 ABI + Zig FFI inventory + binding coverage
422425
interfaces: interfacesState,
423426
// Playgrounds — code sandbox + NQC console + tutorials
@@ -1123,6 +1126,7 @@ let init = (): model => {
11231126
activeCategory: Oo7Dashboard,
11241127
nesyStatus: "Waiting for analysis...",
11251128
},
1129+
videoCoordination: VideoCoordinationEngine.defaultState,
11261130
interfaces: InterfacesEngine.defaultState,
11271131
playgrounds: PlaygroundsEngine.defaultState,
11281132
hypatia: HypatiaEngine.defaultState,

src/Msg.res

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2734,6 +2734,15 @@ type oo7Msg =
27342734
| LoadToolchain
27352735
| ClearError
27362736

2737+
/// Messages for the VideoCoordination panel — Drive-to-Photos batch transfers.
2738+
type videoCoordinationMsg =
2739+
| StartTransfer(string, string) // source, destination
2740+
| PauseTransfer(string) // batchId
2741+
| RefreshStatus
2742+
| StatusResult(result<string, string>)
2743+
| TransferResult(result<string, string>)
2744+
| ClearError
2745+
27372746
/// The unified message type
27382747
type msg =
27392748
| PaneL(paneLMsg)
@@ -2755,6 +2764,7 @@ type msg =
27552764
| Reposystem(reposystemMsg) // RSR compliance auditing
27562765
| Aerie(aerieMsg) // Network diagnostics
27572766
| Oo7Toolchain(oo7Msg) // Agentic compiler and high-rigor execution
2767+
| VideoCoordination(videoCoordinationMsg) // Drive-to-Photos batch transfer dashboard
27582768
| Interfaces(interfacesMsg) // ABI/FFI inventory
27592769
| Playgrounds(playgroundsMsg) // Code sandbox
27602770
| Minter(minterMsg) // Panel Minter wizard

src/Update.res

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ let update = (model: model, msg: msg): (model, Tea_Cmd.t<msg>) => {
141141
| Reposystem(subMsg) => updateReposystem(model, subMsg)
142142
| Aerie(subMsg) => updateAerie(model, subMsg)
143143
| Oo7Toolchain(subMsg) => updateOo7Toolchain(model, subMsg)
144+
| VideoCoordination(subMsg) => UpdateVideoCoordination.updateVideoCoordination(model, subMsg)
144145
| Interfaces(subMsg) => updateInterfaces(model, subMsg)
145146
| Playgrounds(subMsg) => updatePlaygrounds(model, subMsg)
146147
| Minter(subMsg) => updateMinter(model, subMsg)

src/View.res

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -484,6 +484,7 @@ let renderActivePanel = (model: model): Tea_Vdom.t<msg> => {
484484
| Some(PanelDatabases) => Databases.view(model.databases)
485485
| Some(PanelAerie) => Aerie.view(model.aerie)
486486
| Some(PanelOo7Toolchain) => Oo7Toolchain.view(model.oo7toolchain)
487+
| Some(PanelVideoCoordination) => VideoCoordination.view(model.videoCoordination)
487488
| Some(PanelInterfaces) => Interfaces.view(model.interfaces)
488489
| Some(PanelPlaygrounds) => Playgrounds.view(model.playgrounds)
489490
| Some(PanelMinter) => Minter.view(model.minter)

src/components/VideoCoordination.res

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
/// - Quota usage visualisation (Daily 750GB limit)
88
/// - ARIA-live regions for status updates
99

10-
open Model
11-
open Msg
1210
open Tea.Html
1311
open VideoCoordinationModel
1412
open VideoCoordinationEngine

src/model/PanelSwitcherModel.res

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,8 @@ type panelId =
191191
| PanelIdaptikPlayerOverview
192192
/// 007 Toolchain — agentic compiler and high-rigor execution (Groove).
193193
| PanelOo7Toolchain
194+
/// VideoCoordination — Drive-to-Photos batch transfer dashboard.
195+
| PanelVideoCoordination
194196

195197
/// Connection status for panels backed by external services.
196198
type connectionStatus =

src/modules/PanelRegistry.res

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,16 @@ let allPanels: array<panelMeta> = [
111111
hasBackend: true,
112112
cladeId: Some("oo7-toolchain"),
113113
},
114+
{
115+
id: PanelVideoCoordination,
116+
name: "Video Coordination",
117+
shortName: "Video",
118+
description: "Drive-to-Photos batch transfer dashboard",
119+
icon: "video",
120+
connectionStatus: ServiceDisconnected,
121+
hasBackend: true,
122+
cladeId: Some("video-coordination"),
123+
},
114124
{
115125
id: PanelInterfaces,
116126
name: "Interfaces",
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
// SPDX-License-Identifier: PMPL-1.0-or-later
2+
3+
/// Extracted sub-updater for VideoCoordination panel.
4+
/// Manages batch transfer lifecycle, status polling, and error handling.
5+
6+
open Model
7+
open Msg
8+
9+
let updateVideoCoordination = (model: model, subMsg: videoCoordinationMsg): (model, Tea_Cmd.t<msg>) => {
10+
let vc = model.videoCoordination
11+
switch subMsg {
12+
| StartTransfer(source, destination) =>
13+
let newState = VideoCoordinationEngine.addBatch(vc, source, destination, 0)
14+
({...model, videoCoordination: {...newState, loading: true}}, Tea_Cmd.none)
15+
| PauseTransfer(_batchId) => (model, Tea_Cmd.none)
16+
| RefreshStatus => ({...model, videoCoordination: {...vc, loading: true}}, Tea_Cmd.none)
17+
| StatusResult(Ok(_json)) => ({...model, videoCoordination: {...vc, loading: false}}, Tea_Cmd.none)
18+
| StatusResult(Error(err)) => (
19+
{...model, videoCoordination: {...vc, loading: false, error: Some(err)}},
20+
Tea_Cmd.none,
21+
)
22+
| TransferResult(Ok(_json)) => (
23+
{...model, videoCoordination: {...vc, loading: false}},
24+
Tea_Cmd.none,
25+
)
26+
| TransferResult(Error(err)) => (
27+
{...model, videoCoordination: {...vc, loading: false, error: Some(err)}},
28+
Tea_Cmd.none,
29+
)
30+
| ClearError => ({...model, videoCoordination: {...vc, error: None}}, Tea_Cmd.none)
31+
}
32+
}

tests/e2e_panel_lifecycle_test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,8 @@ Deno.test("E2E: Model.init() busRegistry exists", () => {
102102
// 2. Panel Registry — every panel can be looked up
103103
// ============================================================================
104104

105-
Deno.test("E2E: PanelRegistry has all 107 registered panels", () => {
106-
assertEquals(allPanels.length, 107);
105+
Deno.test("E2E: PanelRegistry has all 108 registered panels", () => {
106+
assertEquals(allPanels.length, 108);
107107
});
108108

109109
Deno.test("E2E: Every registered panel can be found by ID", () => {

tests/panel_registry_test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ import {
1717
init,
1818
} from "../src/modules/PanelRegistry.res.js";
1919

20-
Deno.test("allPanels has 107 entries", () => {
21-
assertEquals(allPanels.length, 107);
20+
Deno.test("allPanels has 108 entries", () => {
21+
assertEquals(allPanels.length, 108);
2222
});
2323

2424
Deno.test("every panel has required fields", () => {

0 commit comments

Comments
 (0)