import type { JSX, FunctionComponent } from 'react'; import type { ViewCore, ChromeState } from '../core/view/contract.js'; import { type IntentTap } from './runtime.js'; type ViewPropsWeb = { state: unknown; dispatch: (intent: string, payload?: unknown) => void; chrome: ChromeState; }; type WebComponent = FunctionComponent; export interface UseViewCoreOptions { /** Frozen options map handed to core.init. */ options?: Record; /** Bridge endpoint for the HTTP transport; defaults to /__crtr/source. */ endpoint?: string; /** The host TAP (§5): observe/intercept dispatched intents. */ onIntent?: IntentTap; } export interface ViewCoreHandle { state: unknown; chrome: ChromeState; dispatch: (intent: string, payload?: unknown) => void; /** Force an immediate refresh — the seam the shell calls on an SSE * invalidation (Wave 3). */ refresh: () => void; } /** Run a view core client-side and bind it to React. Returns the live state + * chrome + a dispatch (and a refresh seam). The onIntent tap is read fresh on * every render, so a parent can change it without tearing down the view. */ export declare function useViewCore(core: ViewCore, opts?: UseViewCoreOptions): ViewCoreHandle; /** Host any dual-target view as a React component: its web component wrapped in * , driven by useViewCore. Pass onIntent to tap its intents. */ export declare function ViewPane({ core, View, options, endpoint, onIntent }: { core: ViewCore; View: WebComponent; options?: Record; endpoint?: string; onIntent?: IntentTap; }): JSX.Element; export {};