import { PropType, CSSProperties, TeleportProps } from 'vue'; import { truthProp, unknownProp } from '../utils'; import type { Interceptor } from '../utils/interceptor'; export const popupSharedProps = { // whether to show popup show: Boolean, // z-index zIndex: [Number, String], // whether to show overlay overlay: truthProp, // transition duration duration: [Number, String], // teleport teleport: [String, Object] as PropType, // prevent body scroll lockScroll: truthProp, // whether to lazy render lazyRender: truthProp, // callback function before close beforeClose: Function as PropType, // overlay custom style overlayStyle: Object as PropType, // overlay custom class name overlayClass: unknownProp, // Initial rendering animation transitionAppear: Boolean, // whether to close popup when overlay is clicked closeOnClickOverlay: truthProp, }; export type PopupSharedPropKeys = Array; export const popupSharedPropKeys = Object.keys( popupSharedProps ) as PopupSharedPropKeys;