antd-mobile
Version:
<img src="https://gw.alipayobjects.com/mdn/rms_ee68a8/afts/img/A*hjjDS5Yy-ooAAAAAAAAAAAAAARQnAQ" alt="logo" width="100%" />
21 lines (20 loc) • 1.07 kB
TypeScript
import React, { ReactNode } from 'react';
import { PopupProps } from '../popup';
import { NativeProps } from '../../utils/native-props';
import { PickerColumn, PickerColumnItem, PickerValue, PickerValueExtend } from './index';
export declare type PickerProps = {
columns: PickerColumn[] | ((value: PickerValue[]) => PickerColumn[]);
value?: PickerValue[];
defaultValue?: PickerValue[];
onSelect?: (value: PickerValue[], extend: PickerValueExtend) => void;
onConfirm?: (value: PickerValue[], extend: PickerValueExtend) => void;
onCancel?: () => void;
onClose?: () => void;
closeOnMaskClick?: boolean;
visible?: boolean;
title?: ReactNode;
confirmText?: ReactNode;
cancelText?: ReactNode;
children?: (items: (PickerColumnItem | null)[]) => ReactNode;
} & Pick<PopupProps, 'getContainer' | 'afterShow' | 'afterClose' | 'onClick' | 'stopPropagation'> & NativeProps<'--header-button-font-size' | '--title-font-size' | '--item-font-size' | '--item-height'>;
export declare const Picker: React.NamedExoticComponent<PickerProps>;