uniforms-antd
Version:
Ant Design UI components for uniforms.
24 lines • 1.09 kB
TypeScript
import CheckboxGroup, { CheckboxGroupProps } from 'antd/lib/checkbox/Group';
import { RadioGroupProps } from 'antd/lib/radio';
import RadioGroup from 'antd/lib/radio/group';
import SelectAntD, { SelectProps as SelectAntDProps } from 'antd/lib/select';
import { Ref } from 'react';
import { FieldProps } from 'uniforms';
import type { Option } from './types';
type CheckboxesProps = FieldProps<SelectFieldValue, CheckboxGroupProps | RadioGroupProps, {
options?: Option<string>[];
checkboxes: true;
inputRef?: Ref<typeof CheckboxGroup | typeof RadioGroup>;
required?: boolean;
}>;
type SelectProps = FieldProps<SelectFieldValue, SelectAntDProps<string | string[]>, {
options?: Option<string>[];
checkboxes?: false;
inputRef?: Ref<typeof SelectAntD>;
required?: boolean;
}>;
type SelectFieldValue = (string | undefined)[];
export type SelectFieldProps = CheckboxesProps | SelectProps;
declare const _default: import("uniforms").ConnectedField<SelectFieldProps, SelectFieldValue | undefined>;
export default _default;
//# sourceMappingURL=SelectField.d.ts.map