/** An element on the way up from the row, and its siblings nearest first. */ interface Level { element: Element; after: Element[]; before: Element[]; } /** What a dialog notes as it opens about the row its action may remove: what was around it, * which a removed row no longer knows, and what in it opened the dialog. */ export interface RemovalPlan { row: Element; /** The row, its list and so on up, so a row that goes with its list, such as the last in a * group, still finds the next group's rows. */ levels: Level[]; opener: HTMLElement | null; /** The opener's place among the row's controls, to find its match in another row. */ slot: number; /** The kind of popup the opener opens, such as `menu`, which matches more surely than a * place when rows hold different controls. */ popup: string | null; } /** Notes, as the dialog opens, where focus goes if `row` is gone once it closes. */ export declare function planRemoval(row: Element): RemovalPlan; /** What takes focus once the row is gone: the nearest row left, after it first, then before; * else what held it, such as the list. Null while the row is still there, or when nothing * that held it is left. */ export declare function removalTarget(plan: RemovalPlan): HTMLElement | null; /** Moves focus on as `removalTarget` would if the row goes after the dialog has closed, as when * the list updates on a later fetch, and focus fell with it. It lets go once focus leaves the * row. Returns a function that lets go. */ export declare function focusOnRemoval(plan: RemovalPlan): () => void; export {};