import { type Mountable } from './build-context.js'; import type { Renderable } from './element.js'; import type { TransitionOptions } from '../types.js'; /** Condition source for `signalShow` / discriminant source for `signalBranch`: an * accessor plus its dep paths. */ export interface ShowCond { produce: (state: unknown) => unknown; deps: readonly string[]; /** See {@link BindingSpec.componentRooted}: `true` when the condition reads the * COMPONENT state (so inside a row it's fed `ctx.state`, not the combined ctx). * Set by the authoring layer from the cond handle; unbranded → string inference. */ componentRooted?: boolean; } /** * Conditional render. Mounts `render`'s content when the condition is truthy; if * an `orElse` arm is given, mounts it when falsy (otherwise nothing). The mounted * arm is its OWN scope that reads the owning component's state, registered as a * child of the owning scope — so while mounted it receives state updates (its * bindings re-run when THEIR deps change, not just when the condition flips). * Toggling the condition swaps arms; a same-truthiness update does NOT remount. */ export declare function signalShow(cond: ShowCond, render: () => Renderable, orElse?: () => Renderable, transition?: TransitionOptions): Mountable; /** * Discriminated-union render. Mounts the arm matching the discriminant's current * value; swaps arms when it changes (the old arm unmounts, the new one mounts as * a child scope). Same-value updates do NOT remount — the mounted arm's child * scope handles its own inner reactivity. An absent arm renders nothing. */ export declare function signalBranch(disc: ShowCond, arms: Readonly Renderable>>, transition?: TransitionOptions): Mountable; //# sourceMappingURL=show-branch.d.ts.map