mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-25 08:43:57 +08:00
74492676f7
* fix: fix Checkbox.Group type * fix: fix Checkbox.Group type * fix: fix Checkbox.Group type * fix: remove type * fix: any
17 lines
419 B
TypeScript
17 lines
419 B
TypeScript
import React from 'react';
|
|
|
|
import type { CheckboxOptionType } from './Group';
|
|
|
|
export interface CheckboxGroupContext<T = any> {
|
|
name?: string;
|
|
toggleOption?: (option: CheckboxOptionType<T>) => void;
|
|
value?: any;
|
|
disabled?: boolean;
|
|
registerValue: (val: T) => void;
|
|
cancelValue: (val: T) => void;
|
|
}
|
|
|
|
const GroupContext = React.createContext<CheckboxGroupContext | null>(null);
|
|
|
|
export default GroupContext;
|