JewelryMall/admin/node_modules/element-plus/lib/components/popconfirm/src/popconfirm.d.ts
2026-02-14 19:29:15 +08:00

114 lines
4.7 KiB
TypeScript

import type { Component, ExtractPublicPropTypes } from 'vue';
import type { ButtonType } from 'element-plus/es/components/button';
import type { ElTooltipContentProps, ElTooltipTriggerProps } from 'element-plus/es/components/tooltip';
import type Popconfirm from './popconfirm.vue';
export interface PopconfirmProps {
/**
* @description Title
*/
title?: string;
/**
* @description Confirm button text
*/
confirmButtonText?: string;
/**
* @description Cancel button text
*/
cancelButtonText?: string;
/**
* @description Confirm button type
*/
confirmButtonType?: ButtonType;
/**
* @description Cancel button type
*/
cancelButtonType?: ButtonType;
/**
* @description Icon Component
*/
icon?: string | Component;
/**
* @description Icon color
*/
iconColor?: string;
/**
* @description is hide Icon
*/
hideIcon?: boolean;
/**
* @description delay of disappear, in millisecond
*/
hideAfter?: number;
/**
* @description Tooltip theme, built-in theme: `dark` / `light`
*/
effect?: ElTooltipContentProps['effect'];
/**
* @description whether popconfirm is teleported to the body
*/
teleported?: ElTooltipContentProps['teleported'];
/**
* @description when popconfirm inactive and `persistent` is `false` , popconfirm will be destroyed
*/
persistent?: ElTooltipContentProps['persistent'];
/**
* @description popconfirm width, min width 150px
*/
width?: string | number;
/**
* @description Indicates whether virtual triggering is enabled
*/
virtualTriggering?: ElTooltipTriggerProps['virtualTriggering'];
/**
* @description Indicates the reference element to which the popper is attached
*/
virtualRef?: ElTooltipTriggerProps['virtualRef'];
}
/**
* @deprecated Removed after 3.0.0, Use `PopconfirmProps` instead.
*/
export declare const popconfirmProps: {
readonly title: StringConstructor;
readonly confirmButtonText: StringConstructor;
readonly cancelButtonText: StringConstructor;
readonly confirmButtonType: import("element-plus/es/utils").EpPropFinalized<StringConstructor, "" | "text" | "default" | "primary" | "success" | "warning" | "info" | "danger", unknown, "primary", boolean>;
readonly cancelButtonType: import("element-plus/es/utils").EpPropFinalized<StringConstructor, "" | "text" | "default" | "primary" | "success" | "warning" | "info" | "danger", unknown, "text", boolean>;
readonly icon: import("element-plus/es/utils").EpPropFinalized<(new (...args: any[]) => (string | Component) & {}) | (() => string | Component) | ((new (...args: any[]) => (string | Component) & {}) | (() => string | Component))[], unknown, unknown, () => any, boolean>;
readonly iconColor: import("element-plus/es/utils").EpPropFinalized<StringConstructor, unknown, unknown, "#f90", boolean>;
readonly hideIcon: BooleanConstructor;
readonly hideAfter: import("element-plus/es/utils").EpPropFinalized<NumberConstructor, unknown, unknown, 200, boolean>;
readonly effect: {
readonly default: "light";
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => string) | (() => import("element-plus").PopperEffect) | ((new (...args: any[]) => string) | (() => import("element-plus").PopperEffect))[], unknown, unknown>>;
readonly required: false;
readonly validator: ((val: unknown) => boolean) | undefined;
readonly __epPropKey: true;
};
readonly teleported: import("element-plus/es/utils").EpPropFinalized<BooleanConstructor, unknown, unknown, true, boolean>;
readonly persistent: BooleanConstructor;
readonly width: import("element-plus/es/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, 150, boolean>;
readonly virtualTriggering: BooleanConstructor;
readonly virtualRef: {
readonly type: import("vue").PropType<import("element-plus").Measurable>;
readonly required: false;
readonly validator: ((val: unknown) => boolean) | undefined;
__epPropKey: true;
};
};
export declare const popconfirmEmits: {
/**
* @description triggers when click confirm button
*/
confirm: (e: MouseEvent) => boolean;
/**
* @description triggers when click cancel button
*/
cancel: (e: MouseEvent) => boolean;
};
export type PopconfirmEmits = typeof popconfirmEmits;
/**
* @deprecated Removed after 3.0.0, Use `PopconfirmProps` instead.
*/
export type PopconfirmPropsPublic = ExtractPublicPropTypes<typeof popconfirmProps>;
export type PopconfirmInstance = InstanceType<typeof Popconfirm> & unknown;