jiaqingjiayi-xiaochengxu/甲情_甲意/miniprogram/node_modules/antd-mini/es/SwipeAction/props.d.ts

65 lines
1.4 KiB
TypeScript
Raw Normal View History

2024-11-10 07:01:22 +00:00
import { IBaseProps } from '../_base';
interface SwipeButton {
text: string,
width?: number,
bgColor?: string,
color?: string,
confirmType?: '' | 'move' | 'tap',
confirmText?: string,
}
interface SwipeData {
direction: 'right' | 'left' | '',
btnIdx?: number,
swiped?: boolean,
}
interface ISwipeActionProps extends IBaseProps {
/**
* @description
* @default []
*/
leftButtons?: SwipeButton[];
/**
* @description
* @default []
*/
rightButtons?: SwipeButton[];
/**
* @description
* @default 70
*/
damping?: number;
/**
* @description
* @default false
*/
disabled?: boolean;
/**
* @description
* @default ''
*/
swiped?: '' | 'left' | 'right';
/**
* @description
* @default ''
*/
defaultSwiped?: '' | 'left' | 'right';
/**
* @description
* @default true
*/
elasticity?: boolean
/**
* @description
*/
onSwipeEnd: (data: SwipeData, e: Record<string, any>) => void;
/**
* @description
*/
onSwipeStart: (data: SwipeData, e: Record<string, any>) => void;
/**
* @description
*/
onButtonTap: (data: SwipeData, e: Record<string, any>) => void;
}
export declare const SwipeActionDefaultProps: Partial<ISwipeActionProps>;