@ui5/webcomponents-react
Version:
React Wrapper for UI5 Web Components and additional components
21 lines (20 loc) • 757 B
TypeScript
import type { ComponentType, RefCallback, RefObject } from 'react';
import type { PopoverPropTypes } from '../webComponents/Popover/index.js';
export type IModal = {
Component: ComponentType;
props: Record<string, unknown>;
ref: RefObject<unknown> | RefCallback<unknown>;
container?: Element | DocumentFragment;
id: string;
};
declare function getSnapshot(): IModal[];
declare function subscribe(listener: () => void): () => void;
export declare const ModalStore: {
subscribe: typeof subscribe;
getSnapshot: typeof getSnapshot;
getServerSnapshot: () => IModal[];
addModal(config: IModal): void;
removeModal(id: string): void;
getPopoversWithSameOpener(opener: PopoverPropTypes["opener"]): IModal[];
};
export {};