export interface Selection { /** Spread (`[...selected]`) to hand ids to a bulk action. */ selected: ReadonlySet; has: (id: string) => boolean; /** Across pages: the running total a `SelectionBar` shows. */ count: number; /** Sets explicitly when `on` is passed (a row checkbox's `onChange`). */ toggle: (id: string, on?: boolean) => void; /** The select-all `onChange(on)`. */ setAll: (ids: readonly string[], on: boolean) => void; /** A select-all's `checked`; false for an empty set. */ allSelected: (ids: readonly string[]) => boolean; /** A select-all's `indeterminate`. */ indeterminate: (ids: readonly string[]) => boolean; clear: () => void; } /** Always-on multi-select for a register with `Table` + `SelectionBar`. Gating stays with the caller: pass * only selectable ids to `setAll`/`allSelected`/`indeterminate`. Persists across pages. (Tap-and-hold * selection mode is `useSelectionMode`.) A changed `scope` drops the selection, since a bulk act must not * run over rows out of view; it is read in the render that changes it, not an effect, so no committed * render counts gone rows. */ export declare function useSelection(scope?: string): Selection;