mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-05 21:48:19 +08:00
854cdb4352
* type: optimize CompoundedComponent type * chore: fix * type: fix type * chore: fix * type: fix type * type: add ts-ignore * fix: fix * chore: revert
26 lines
647 B
TypeScript
26 lines
647 B
TypeScript
import type { CheckboxRef } from 'rc-checkbox';
|
|
|
|
import InternalCheckbox from './Checkbox';
|
|
import Group from './Group';
|
|
|
|
export type { CheckboxChangeEvent, CheckboxProps } from './Checkbox';
|
|
export type { CheckboxGroupProps, CheckboxOptionType } from './Group';
|
|
export type { CheckboxRef };
|
|
|
|
type CompoundedComponent = typeof InternalCheckbox & {
|
|
Group: typeof Group;
|
|
/** @internal */
|
|
__ANT_CHECKBOX: boolean;
|
|
};
|
|
|
|
const Checkbox = InternalCheckbox as CompoundedComponent;
|
|
|
|
Checkbox.Group = Group;
|
|
Checkbox.__ANT_CHECKBOX = true;
|
|
|
|
if (process.env.NODE_ENV !== 'production') {
|
|
Checkbox.displayName = 'Checkbox';
|
|
}
|
|
|
|
export default Checkbox;
|