1 | export interface ModalInstance {
|
2 | dialog: Element;
|
3 | backdrop: Element;
|
4 | }
|
5 | export declare type ContainerState = Record<string, any> & {
|
6 | isOverflowing?: boolean;
|
7 | style?: Partial<CSSStyleDeclaration>;
|
8 | modals: ModalInstance[];
|
9 | };
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 | declare class ModalManager {
|
16 | readonly hideSiblingNodes: boolean;
|
17 | readonly handleContainerOverflow: boolean;
|
18 | readonly modals: ModalInstance[];
|
19 | readonly containers: HTMLElement[];
|
20 | readonly data: ContainerState[];
|
21 | readonly scrollbarSize: number;
|
22 | constructor({ hideSiblingNodes, handleContainerOverflow, }?: {
|
23 | hideSiblingNodes?: boolean | undefined;
|
24 | handleContainerOverflow?: boolean | undefined;
|
25 | });
|
26 | isContainerOverflowing(modal: ModalInstance): any;
|
27 | containerIndexFromModal(modal: ModalInstance): number;
|
28 | setContainerStyle(containerState: ContainerState, container: HTMLElement): void;
|
29 | removeContainerStyle(containerState: ContainerState, container: HTMLElement): void;
|
30 | add(modal: ModalInstance, container: HTMLElement, className?: string): number;
|
31 | remove(modal: ModalInstance): void;
|
32 | isTopModal(modal: ModalInstance): boolean;
|
33 | }
|
34 | export default ModalManager;
|