Skip to content

Commit 5b99cac

Browse files
committed
Align TypeScript definition with PropTypes
Adds checkModel and iconsClass.
1 parent 93afb5d commit 5b99cac

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/index.d.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ declare module "react-checkbox-tree" {
3333

3434
interface CheckboxProps {
3535
nodes: Array<Node>;
36-
checked: Array<string>;
37-
expanded: Array<string>;
38-
onCheck: (checked: Array<string>) => void;
39-
onExpand: (expanded: Array<string>) => void;
4036

37+
checkModel?: string;
38+
checked?: Array<string>;
4139
disabled?: boolean;
4240
expandDisabled?: boolean;
4341
expandOnClick?: boolean;
42+
expanded?: Array<string>;
4443
icons?: Icons;
44+
iconsClass?: string;
4545
lang?: Language;
4646
name?: string;
4747
nameAsArray?: boolean;
@@ -52,7 +52,9 @@ declare module "react-checkbox-tree" {
5252
showExpandAll?: boolean;
5353
showNodeIcon?: boolean;
5454
showNodeTitles?: boolean;
55+
onCheck?: (checked: Array<string>) => void;
5556
onClick?: (event: { checked: boolean, value: any }) => void;
57+
onExpand?: (expanded: Array<string>) => void;
5658
}
5759

5860
export default class CheckboxTree extends React.Component<CheckboxProps> { }

0 commit comments

Comments
 (0)