返回 DeepSeek-Reasonix
BrowserPanelEntry.tsx
根目录 / desktop / frontend / src / components / BrowserPanelEntry.tsx
1 import "./BrowserPanel.css";
2
3 import { BrowserDockTab, BrowserPanel } from "./BrowserPanel";
4
5 export type BrowserSurfaceProps =
6 | { surface: "tab"; active: boolean; onSelect: () => void }
7 | { surface: "panel"; taskId: string | undefined };
8
9 // One lazy boundary for the whole dock surface: the tab button and the panel
10 // share this chunk, so the initial bundle carries no browser code at all.
11 export default function BrowserSurface(props: BrowserSurfaceProps) {
12 return props.surface === "tab" ? <BrowserDockTab active={props.active} onSelect={props.onSelect} /> : <BrowserPanel taskId={props.taskId} />;
13 }
14
14 lines Plain Text