2023-03-01 10:18:34 +00:00
|
|
|
/**
|
|
|
|
*
|
|
|
|
* Dialog is a container to display content in an overlay window.
|
|
|
|
*
|
|
|
|
* [Live Demo](https://www.primevue.org/dialog)
|
|
|
|
*
|
|
|
|
* @module dialog
|
|
|
|
*
|
|
|
|
*/
|
2023-08-02 14:07:22 +00:00
|
|
|
import { HTMLAttributes, TransitionProps, VNode } from 'vue';
|
2023-07-06 11:17:08 +00:00
|
|
|
import { ComponentHooks } from '../basecomponent';
|
2024-04-15 08:08:42 +00:00
|
|
|
import { ButtonPassThroughOptions, ButtonProps } from '../button';
|
2023-09-05 08:50:46 +00:00
|
|
|
import { PassThroughOptions } from '../passthrough';
|
2024-04-02 08:24:31 +00:00
|
|
|
import { ClassComponent, DesignToken, GlobalComponentConstructor, HintedString, PassThrough } from '../ts-helpers';
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2023-12-05 07:06:55 +00:00
|
|
|
export declare type DialogPassThroughOptionType<T = any> = DialogPassThroughAttributes | ((options: DialogPassThroughMethodOptions<T>) => DialogPassThroughAttributes | string) | string | null | undefined;
|
2023-04-24 09:59:20 +00:00
|
|
|
|
2023-12-05 07:06:55 +00:00
|
|
|
export declare type DialogPassThroughTransitionType<T = any> = TransitionProps | ((options: DialogPassThroughMethodOptions<T>) => TransitionProps) | undefined;
|
2023-08-02 14:07:22 +00:00
|
|
|
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
|
|
|
* Custom passthrough(pt) option method.
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
export interface DialogPassThroughMethodOptions<T> {
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines instance.
|
|
|
|
*/
|
2023-07-06 12:01:33 +00:00
|
|
|
instance: any;
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines valid properties.
|
|
|
|
*/
|
2023-04-24 09:59:20 +00:00
|
|
|
props: DialogProps;
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines current inline state.
|
|
|
|
*/
|
2023-04-24 09:59:20 +00:00
|
|
|
state: DialogState;
|
2023-12-05 07:06:55 +00:00
|
|
|
/**
|
|
|
|
* Defines parent instance.
|
|
|
|
*/
|
|
|
|
parent: T;
|
2023-09-05 08:50:46 +00:00
|
|
|
/**
|
|
|
|
* Defines passthrough(pt) options in global config.
|
|
|
|
*/
|
|
|
|
global: object | undefined;
|
2023-04-24 09:59:20 +00:00
|
|
|
}
|
|
|
|
|
2024-04-15 08:08:42 +00:00
|
|
|
/**
|
|
|
|
* Custom shared passthrough(pt) option method.
|
|
|
|
*/
|
|
|
|
export interface DialogSharedPassThroughMethodOptions {
|
|
|
|
/**
|
|
|
|
* Defines valid properties.
|
|
|
|
*/
|
|
|
|
props: DialogProps;
|
|
|
|
/**
|
|
|
|
* Defines current inline state.
|
|
|
|
*/
|
|
|
|
state: DialogState;
|
|
|
|
}
|
|
|
|
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
|
|
|
* Custom passthrough(pt) options.
|
|
|
|
* @see {@link DialogProps.pt}
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
export interface DialogPassThroughOptions<T = any> {
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the root's DOM element.
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
root?: DialogPassThroughOptionType<T>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the header's DOM element.
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
header?: DialogPassThroughOptionType<T>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the header title's DOM element.
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
title?: DialogPassThroughOptionType<T>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2024-04-30 09:58:12 +00:00
|
|
|
* Used to pass attributes to the header actions' DOM element.
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2024-04-30 09:58:12 +00:00
|
|
|
headerActions?: DialogPassThroughOptionType<T>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2024-05-06 13:10:13 +00:00
|
|
|
* Used to pass attributes to the maximize Button component.
|
2024-04-15 08:08:42 +00:00
|
|
|
* @see {@link ButtonPassThroughOptions}
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2024-05-06 13:10:13 +00:00
|
|
|
maximizeButton?: ButtonPassThroughOptions<DialogSharedPassThroughMethodOptions>;
|
2023-05-03 14:16:11 +00:00
|
|
|
/**
|
2024-04-15 08:08:42 +00:00
|
|
|
* Used to pass attributes to the close Button component.
|
|
|
|
* @see {@link ButtonPassThroughOptions}
|
2023-05-03 14:16:11 +00:00
|
|
|
*/
|
2024-04-15 08:08:42 +00:00
|
|
|
closeButton?: ButtonPassThroughOptions<DialogSharedPassThroughMethodOptions>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the content's DOM element.
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
content?: DialogPassThroughOptionType<T>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the footer's DOM element.
|
2023-04-24 09:59:20 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
footer?: DialogPassThroughOptionType<T>;
|
2023-04-26 13:41:27 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the mask's DOM element.
|
2023-04-26 13:41:27 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
mask?: DialogPassThroughOptionType<T>;
|
2023-07-06 11:09:01 +00:00
|
|
|
/**
|
2023-11-07 06:16:39 +00:00
|
|
|
* Used to manage all lifecycle hooks.
|
2023-07-06 11:09:01 +00:00
|
|
|
* @see {@link BaseComponent.ComponentHooks}
|
|
|
|
*/
|
|
|
|
hooks?: ComponentHooks;
|
2023-08-02 12:00:42 +00:00
|
|
|
/**
|
|
|
|
* Used to control Vue Transition API.
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
transition?: DialogPassThroughTransitionType<T>;
|
2023-04-24 09:59:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Custom passthrough attributes for each DOM elements
|
|
|
|
*/
|
|
|
|
export interface DialogPassThroughAttributes {
|
|
|
|
[key: string]: any;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Defines current inline state in Dialog component.
|
|
|
|
*/
|
|
|
|
export interface DialogState {
|
|
|
|
/**
|
|
|
|
* Current visible state of the container as a boolean.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
containerVisible: boolean;
|
|
|
|
/**
|
|
|
|
* Current maximized state as a boolean.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
maximized: boolean;
|
|
|
|
}
|
|
|
|
|
2023-03-01 10:18:34 +00:00
|
|
|
/**
|
|
|
|
* Custom breakpoint metadata.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface DialogBreakpoints {
|
|
|
|
/**
|
|
|
|
* Breakpoint for responsive mode.
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
*
|
|
|
|
* <Dialog :breakpoints="{'960px': '75vw', '640px': '100vw'}" ... />
|
|
|
|
*
|
|
|
|
* Result:
|
|
|
|
*
|
|
|
|
* @media screen and (max-width: ${breakpoint[key]}) {
|
|
|
|
* .p-dialog[attributeSelector] {
|
2023-12-21 07:56:38 +00:00
|
|
|
* width: ${breakpoint[value]} !important;
|
2022-09-06 12:03:37 +00:00
|
|
|
* }
|
|
|
|
* }
|
|
|
|
*/
|
|
|
|
[key: string]: string;
|
|
|
|
}
|
|
|
|
|
2023-03-01 10:18:34 +00:00
|
|
|
/**
|
|
|
|
* Defines valid properties in Dialog component.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface DialogProps {
|
|
|
|
/**
|
|
|
|
* Title content of the dialog.
|
|
|
|
*/
|
|
|
|
header?: string | undefined;
|
|
|
|
/**
|
|
|
|
* Footer content of the dialog.
|
|
|
|
*/
|
|
|
|
footer?: string | undefined;
|
|
|
|
/**
|
|
|
|
* Specifies the visibility of the dialog.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue false
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
visible?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Defines if background should be blocked when dialog is displayed.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue false
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
modal?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Style of the content section.
|
|
|
|
*/
|
|
|
|
contentStyle?: any;
|
|
|
|
/**
|
|
|
|
* Style class of the content section.
|
|
|
|
*/
|
|
|
|
contentClass?: any;
|
2022-12-08 11:04:25 +00:00
|
|
|
/**
|
2024-04-15 08:08:42 +00:00
|
|
|
* Used to pass all properties of the HTMLDivElement to the overlay Dialog inside the component.
|
2022-12-08 11:04:25 +00:00
|
|
|
*/
|
|
|
|
contentProps?: HTMLAttributes | undefined;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* When enabled dialog is displayed in RTL direction.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue false
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
rtl?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Adds a close icon to the header to hide the dialog.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
closable?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Specifies if clicking the modal background should hide the dialog.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue false
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
dismissableMask?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Specifies if pressing escape key should hide the dialog.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
closeOnEscape?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Whether to show the header or not.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
showHeader?: boolean | undefined;
|
2023-09-18 09:14:52 +00:00
|
|
|
/**
|
|
|
|
* Whether background scroll should be blocked when dialog is visible.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
blockScroll?: boolean | undefined;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Base zIndex value to use in layering.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue 0
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
baseZIndex?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Whether to automatically manage layering.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
autoZIndex?: boolean | undefined;
|
|
|
|
/**
|
2023-03-01 10:18:34 +00:00
|
|
|
* Position of the dialog.
|
2023-03-08 10:51:52 +00:00
|
|
|
* @defaultValue center
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
position?: 'center' | 'top' | 'bottom' | 'left' | 'right' | 'topleft' | 'topright' | 'bottomleft' | 'bottomright' | undefined;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Whether the dialog can be displayed full screen.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue false
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
maximizable?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Object literal to define widths per screen size.
|
|
|
|
*/
|
|
|
|
breakpoints?: DialogBreakpoints;
|
|
|
|
/**
|
|
|
|
* Enables dragging to change the position using header.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
draggable?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Keeps dialog in the viewport when dragging.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
keepInViewPort?: boolean | undefined;
|
|
|
|
/**
|
|
|
|
* Minimum value for the left coordinate of dialog in dragging.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue 0.
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
minX?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Minimum value for the top coordinate of dialog in dragging.
|
2023-03-01 10:18:34 +00:00
|
|
|
* @defaultValue 0
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
minY?: number | undefined;
|
|
|
|
/**
|
2023-03-01 10:18:34 +00:00
|
|
|
* A valid query selector or an HTMLElement to specify where the dialog gets attached.
|
2023-03-08 10:51:52 +00:00
|
|
|
* @defaultValue body
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
2024-02-23 08:38:50 +00:00
|
|
|
appendTo?: HintedString<'body' | 'self'> | undefined | HTMLElement;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Style of the dynamic dialog.
|
|
|
|
*/
|
|
|
|
style?: any;
|
2022-12-08 11:04:25 +00:00
|
|
|
/**
|
|
|
|
* Icon to display in the dialog close button.
|
2023-04-18 10:51:10 +00:00
|
|
|
* @deprecated since v3.27.0. Use 'closeicon' slot.
|
2022-12-08 11:04:25 +00:00
|
|
|
*/
|
|
|
|
closeIcon?: string | undefined;
|
|
|
|
/**
|
|
|
|
* Icon to display in the dialog maximize button when dialog is not maximized.
|
2023-04-18 10:51:10 +00:00
|
|
|
* @deprecated since v3.27.0. Use 'maximizeicon' slot.
|
2022-12-08 11:04:25 +00:00
|
|
|
*/
|
|
|
|
maximizeIcon?: string | undefined;
|
|
|
|
/**
|
2023-04-18 10:51:10 +00:00
|
|
|
* Icon to display in the dialog maximize button when dialog is minimized.
|
|
|
|
* @deprecated since v3.27.0. Use 'minimizeicon' slot.
|
2022-12-08 11:04:25 +00:00
|
|
|
*/
|
|
|
|
minimizeIcon?: string | undefined;
|
2024-04-15 08:08:42 +00:00
|
|
|
/**
|
|
|
|
* Used to pass all properties of the ButtonProps to the Button component.
|
|
|
|
* @type {ButtonProps}
|
|
|
|
* @defaultValue { severity: 'secondary', rounded: true, text: true }
|
|
|
|
*/
|
|
|
|
closeButtonProps?: object | undefined;
|
|
|
|
/**
|
|
|
|
* Used to pass all properties of the ButtonProps to the Button component.
|
|
|
|
* @type {ButtonProps}
|
|
|
|
* @defaultValue { severity: 'secondary', rounded: true, text: true }
|
|
|
|
*/
|
|
|
|
maximizeButtonProps?: object | undefined;
|
2024-04-02 08:24:31 +00:00
|
|
|
/**
|
|
|
|
* It generates scoped CSS variables using design tokens for the component.
|
|
|
|
*/
|
|
|
|
dt?: DesignToken<any>;
|
2023-04-24 09:59:20 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to DOM elements inside the component.
|
2023-04-24 09:59:20 +00:00
|
|
|
* @type {DialogPassThroughOptions}
|
|
|
|
*/
|
2023-09-05 11:28:04 +00:00
|
|
|
pt?: PassThrough<DialogPassThroughOptions>;
|
2023-09-05 08:50:46 +00:00
|
|
|
/**
|
|
|
|
* Used to configure passthrough(pt) options of the component.
|
|
|
|
* @type {PassThroughOptions}
|
|
|
|
*/
|
|
|
|
ptOptions?: PassThroughOptions;
|
2023-05-29 10:59:47 +00:00
|
|
|
/**
|
|
|
|
* When enabled, it removes component related styles in the core.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
unstyled?: boolean;
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
|
2023-03-01 10:18:34 +00:00
|
|
|
/**
|
|
|
|
* Defines valid slots in Dialog component.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface DialogSlots {
|
|
|
|
/**
|
|
|
|
* Default content slot.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
default(): VNode[];
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Custom header template.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
header(): VNode[];
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Custom footer template.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
footer(): VNode[];
|
2023-04-11 21:00:21 +00:00
|
|
|
/**
|
|
|
|
* Custom close icon template.
|
2023-08-23 06:39:17 +00:00
|
|
|
* @param {Object} scope - close icon slot's params.
|
2023-04-11 21:00:21 +00:00
|
|
|
*/
|
2023-08-23 06:39:17 +00:00
|
|
|
closeicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the close icon
|
|
|
|
*/
|
|
|
|
class: any;
|
|
|
|
}): VNode[];
|
2023-04-11 21:00:21 +00:00
|
|
|
/**
|
2023-04-18 10:51:10 +00:00
|
|
|
* Custom maximize icon template of dialog.
|
|
|
|
* @param {Object} scope - maximize icon slot's params.
|
2023-04-11 21:00:21 +00:00
|
|
|
*/
|
|
|
|
maximizeicon(scope: {
|
|
|
|
/**
|
|
|
|
* Maximized state as a boolean
|
|
|
|
*/
|
|
|
|
maximized: boolean;
|
2023-08-23 06:39:17 +00:00
|
|
|
/**
|
|
|
|
* Style class of the maximize icon
|
|
|
|
*/
|
|
|
|
class: any;
|
2023-04-11 21:00:21 +00:00
|
|
|
}): VNode[];
|
2023-09-19 09:36:33 +00:00
|
|
|
/**
|
|
|
|
* Custom container slot.
|
|
|
|
* @param {Object} scope - container slot's params.
|
|
|
|
*/
|
|
|
|
container(scope: {
|
|
|
|
/**
|
|
|
|
* Close dialog function.
|
2023-10-31 12:52:10 +00:00
|
|
|
* @deprecated since v3.39.0. Use 'closeCallback' property instead.
|
2023-09-19 09:36:33 +00:00
|
|
|
*/
|
|
|
|
onClose: () => void;
|
|
|
|
/**
|
|
|
|
* Maximize/minimize dialog function.
|
|
|
|
* @param {Event} event - Browser event
|
2023-10-31 12:52:10 +00:00
|
|
|
* @deprecated since v3.39.0. Use 'maximizeCallback' property instead.
|
2023-09-19 09:36:33 +00:00
|
|
|
*/
|
|
|
|
onMaximize: (event: Event) => void;
|
2023-10-31 12:52:10 +00:00
|
|
|
/**
|
|
|
|
* Close dialog function.
|
|
|
|
*/
|
|
|
|
closeCallback: () => void;
|
|
|
|
/**
|
|
|
|
* Maximize/minimize dialog function.
|
|
|
|
* @param {Event} event - Browser event
|
|
|
|
*/
|
|
|
|
maximizeCallback: (event: Event) => void;
|
2023-09-19 09:36:33 +00:00
|
|
|
}): VNode[];
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
|
2023-03-01 10:18:34 +00:00
|
|
|
/**
|
|
|
|
* Defines valid emits in Dialog component.
|
|
|
|
*/
|
|
|
|
export interface DialogEmits {
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Emitted when the visible changes.
|
|
|
|
* @param {boolean} value - New value.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
'update:visible'(value: boolean): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Callback to invoke when dialog is hidden.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
hide(): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Callback to invoke after dialog is hidden.
|
2022-09-14 11:26:01 +00:00
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
'after-hide'(): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Callback to invoke when dialog is shown.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
show(): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Fired when a dialog gets maximized.
|
|
|
|
* @param {event} event - Browser event.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
maximize(event: Event): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Fired when a dialog gets unmaximized.
|
|
|
|
* @param {event} event - Browser event.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
unmaximize(event: Event): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Fired when a dialog drag completes.
|
|
|
|
* @param {event} event - Browser event.
|
|
|
|
*/
|
2023-03-01 10:18:34 +00:00
|
|
|
dragend(event: Event): void;
|
|
|
|
}
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2023-03-01 10:18:34 +00:00
|
|
|
/**
|
|
|
|
* **PrimeVue - Dialog**
|
|
|
|
*
|
|
|
|
* _Dialog is a container to display content in an overlay window._
|
|
|
|
*
|
|
|
|
* [Live Demo](https://www.primevue.org/dialog/)
|
|
|
|
* --- ---
|
|
|
|
* ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
|
|
|
|
*
|
|
|
|
* @group Component
|
|
|
|
*/
|
2023-03-01 14:48:23 +00:00
|
|
|
declare class Dialog extends ClassComponent<DialogProps, DialogSlots, DialogEmits> {}
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2024-03-14 22:58:11 +00:00
|
|
|
declare module 'vue' {
|
|
|
|
export interface GlobalComponents {
|
2022-09-14 11:26:01 +00:00
|
|
|
Dialog: GlobalComponentConstructor<Dialog>;
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export default Dialog;
|