From aaced8796bb45d151833e12bc1cc17fc5090ef6d Mon Sep 17 00:00:00 2001 From: weichen Date: Sun, 11 Oct 2026 14:49:10 +0000 Subject: [PATCH] Fix the surface action callback to match SurfaceView's single-parameter signature Why: U5 (#367) introduced a two-parameter callback but SurfaceView (@ui) expects (id: string) => void; TypeScript build fails on main. Evidence: SELF tsc --noEmit zero errors after fix. Impact: PreviewPane.tsx one-line type fix; no behavior change (payload path dormant until @ui widens the interface). Refs: Dev #367 --- src/components/PreviewPane.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/PreviewPane.tsx b/src/components/PreviewPane.tsx index 0c60d05..8bfe7bc 100644 --- a/src/components/PreviewPane.tsx +++ b/src/components/PreviewPane.tsx @@ -56,7 +56,7 @@ export function PreviewPane() {
{surfaceSnap - ? store.handleSurfaceAction(String(surfaceSnap?.identity.surfaceId), actionId, payload as Record)} docBridge={{ onOpenDoc: docId => { + ? store.handleSurfaceAction(String(surfaceSnap?.identity.surfaceId), id, {})} docBridge={{ onOpenDoc: docId => { const art = artifacts.find(a => a.id === docId) if (art) store.requestPreview(art) } }} />