jenesius-vue-modal
Version:
The progressive and simple modal system for Vue.js v3
64 lines (63 loc) • 2.67 kB
TypeScript
/**
* last change: 25.11.2021
*
* STATE ПРЕДНАЗНАЧЕН ДЛЯ ВНУТРЕННЕГО ХРАНИЛИЩА ДАННЫХ
* НЕПУТАТЬ С КОНФИГУРАЦИЕЙ, ЕЁ ЗАДАЁТ ПОЛЬЗОВАТЕЛЬ
*
* initialized - параметра принимает true, когда приложение было проинициализировано, то есть WidgetModalContainer
* был добавлен на страницу
*
* */
import { INamespaceKey } from "./NamespaceStore";
import { IBeforeEachCallback, IStoreComponentConfiguration, IStoreElement } from "./types";
/**
* @description Метод для получения Namespace.
* */
export declare function getNamespace(name?: INamespaceKey): import("./NamespaceStore").INamespaceState;
export declare const configuration: ConfigInterface;
export interface ConfigInterface {
/**
* @description Disable scrolling in time when modal is open.
* */
scrollLock: boolean;
/**
* @description Animation name for transition-group.
* */
animation: string;
/**
* @description Closing on click back area of modal.
* */
backgroundClose: boolean;
/**
* @description Closing on press ESC key
* */
escClose: boolean;
/**
* @description Disable throwing the error when the container has not been initialized.
* */
skipInitCheck: boolean;
/**
* @description If set to true, all modal windows will be draggable. If a string is set, then this string will be
* used as the name of the css class by default for all modular windows. Which will be used to move the window.
*/
draggable: boolean | string;
/**
* @description TransitionGroup appear prop. For more details https://vuejs.org/guide/built-ins/transition.html#transition-on-appear
*/
appear: boolean;
/**
* @description A hook that will fire before opening each modal window. In this hook, you can cancel closing by
* passing the value false.
*/
beforeEach: IBeforeEachCallback;
/**
* @description If the value is set to true, then only one modal window will be shown. If several are opened
* (using pushModal), only the last one will be shown, and the rest will be hidden using `v-show`.
*/
singleShow: boolean;
store: Record<string, IStoreElement>;
}
/**
* @description The function determines whether the transferred data is an extended configuration of a storage element
*/
export declare function isStoreComponentConfiguration(element: unknown): element is IStoreComponentConfiguration;