@nutui/nutui-react-taro
Version:
京东风格的轻量级移动端 React 组件库,支持一套代码生成 H5 和小程序
23 lines (22 loc) • 869 B
TypeScript
import { default as React, FunctionComponent, ReactNode } from 'react';
import { default as CheckboxGroup } from '../checkboxgroup';
import { BasicComponent } from '../../utils/typings';
import { CheckboxLabelPosition } from '../checkboxgroup/types';
export type CheckboxShape = 'button' | 'round';
export interface CheckboxProps extends BasicComponent {
checked: boolean;
disabled: boolean;
defaultChecked: boolean;
shape: CheckboxShape;
labelPosition: CheckboxLabelPosition;
icon: ReactNode;
activeIcon: ReactNode;
indeterminateIcon: ReactNode;
value: string | number;
indeterminate: boolean;
label: ReactNode;
onChange: (value: boolean) => void;
}
export declare const Checkbox: FunctionComponent<Partial<CheckboxProps> & Omit<React.HTMLAttributes<HTMLDivElement>, 'onChange'>> & {
Group: typeof CheckboxGroup;
};