import { type Readable } from '@vielzeug/ripple'; /** Position in the 2D grid model (0-based row/col indices). */ export type GridCellPos = { col: number; row: number; }; /** Handle returned by createGridNav for programmatic control. */ export type GridNavHandle = { /** Current active cell position. Reactive signal. */ readonly activeCell: Readable; /** * Move focus to a specific cell by position. * Clamps to valid grid bounds; no-ops for invalid positions. */ focusCell(pos: GridCellPos): void; }; /** * Keyboard navigation for the ARIA grid pattern (roving tabindex). * * - Arrow keys move focus between cells. * - Home/End move to the first/last cell in the row. * - Ctrl+Home/Ctrl+End move to the first/last cell in the grid. * - Only the active cell has `tabindex="0"`; all others have `"-1"`. * * @param table - The `.dg-table` element to attach the keydown listener to. * @param shadow - The shadow root containing the grid cells. * @returns A handle with `focusCell` and a reactive `activeCell` signal, plus a cleanup fn. */ export declare function createGridNav(table: HTMLElement, shadow: ShadowRoot): { cleanup: () => void; handle: GridNavHandle; }; //# sourceMappingURL=datagrid-nav.d.ts.map