import { Value } from '@tempots/dom'; import type { Renderable } from '@tempots/dom'; import type { ParseError } from '../parser/types'; import type { Library } from '../library/types'; import { type ActionEvent } from './action-context'; export interface OpenUIRendererOptions { /** The component library to resolve against. */ library: Library; /** The OpenUI Lang response text — can be static or a signal that updates as chunks stream in. */ response: Value; /** Whether the response is still streaming. */ isStreaming?: Value; /** Callback fired when a rendered component dispatches an action. */ onAction?: (event: ActionEvent) => void; /** Callback fired when parse errors occur. */ onError?: (errors: ParseError[]) => void; /** Callback fired when streaming ends (isStreaming transitions to false). */ onComplete?: () => void; /** CSS class for the renderer's root container. */ className?: Value; /** When true, render warning notices for unknown components. */ debug?: boolean; } /** * Parses OpenUI Lang text and renders the result as live BeatUI components. * * Accepts both static strings and reactive signals. When `response` is a * signal, the renderer re-parses and re-renders on each update using * `WithCtx` + `renderWithContext` to preserve the full provider chain * (Theme, Locale, BeatUII18n, etc.). */ export declare function OpenUIRenderer(options: OpenUIRendererOptions): Renderable;