1 | import * as i0 from "@angular/core";
|
2 | /**
|
3 | * A FocusTrap managed by FocusTrapManager.
|
4 | * Implemented by ConfigurableFocusTrap to avoid circular dependency.
|
5 | */
|
6 | export interface ManagedFocusTrap {
|
7 | _enable(): void;
|
8 | _disable(): void;
|
9 | focusInitialElementWhenReady(): Promise<boolean>;
|
10 | }
|
11 | /** Injectable that ensures only the most recently enabled FocusTrap is active. */
|
12 | export declare class FocusTrapManager {
|
13 | private _focusTrapStack;
|
14 | /**
|
15 | * Disables the FocusTrap at the top of the stack, and then pushes
|
16 | * the new FocusTrap onto the stack.
|
17 | */
|
18 | register(focusTrap: ManagedFocusTrap): void;
|
19 | /**
|
20 | * Removes the FocusTrap from the stack, and activates the
|
21 | * FocusTrap that is the new top of the stack.
|
22 | */
|
23 | deregister(focusTrap: ManagedFocusTrap): void;
|
24 | static ɵfac: i0.ɵɵFactoryDeclaration<FocusTrapManager, never>;
|
25 | static ɵprov: i0.ɵɵInjectableDeclaration<FocusTrapManager>;
|
26 | }
|