Skip to content

Interface: SelectionWatcherOptions

Defined in: aiui-intent-runtime/src/selection.ts:77

Properties

debounceMs?

optional debounceMs?: number

Defined in: aiui-intent-runtime/src/selection.ts:86

Debounce for the selectionchange listener, in ms (default 150).


ignoreWithin?

optional ignoreWithin?: Node[]

Defined in: aiui-intent-runtime/src/selection.ts:82

Nodes whose selections to ignore — the intent tool's own shadow host, so interacting with the widget never captures a "selection" of the widget.


onChange?

optional onChange?: (snapshot) => void

Defined in: aiui-intent-runtime/src/selection.ts:84

Called whenever the snapshot changes (a new capture, or a clear).

Parameters

snapshot

SelectionSnapshot | undefined

Returns

void


ttlMs?

optional ttlMs?: number

Defined in: aiui-intent-runtime/src/selection.ts:88

How long a snapshot stays valid, in ms (default 120000).