File tree Expand file tree Collapse file tree 2 files changed +34
-0
lines changed Expand file tree Collapse file tree 2 files changed +34
-0
lines changed Original file line number Diff line number Diff line change 44 "description" : " A simple and elegant checkbox tree for React." ,
55 "author" : " Jake Zatecky" ,
66 "license" : " MIT" ,
7+ "types" : " src/index.d.ts" ,
78 "keywords" : [
89 " react" ,
910 " checkbox" ,
Original file line number Diff line number Diff line change 1+ declare module "react-checkbox-tree" {
2+ interface Node {
3+ label : string ;
4+ value : string ;
5+ children ?: Array < Node > ;
6+ className ?: string ;
7+ disabled ?: boolean ;
8+ icon ?: JSX . Element ;
9+ showCheckbox ?: boolean ;
10+ }
11+
12+ interface CheckboxProps {
13+ nodes : Array < Node > ;
14+ checked : Array < string > ;
15+ expanded : Array < string > ;
16+ onCheck : ( checked : Array < string > ) => void ;
17+ onExpand : ( expanded : Array < string > ) => void ;
18+
19+ disabled ?: boolean ;
20+ expandDisabled ?: boolean ;
21+ expandOnClick ?: boolean ;
22+ name ?: string ;
23+ nameAsArray ?: boolean ;
24+ nativeCheckboxes ?: boolean ;
25+ noCascade ?: boolean ;
26+ onlyLeafCheckboxes ?: boolean ;
27+ optimisticToggle ?: boolean ;
28+ showNodeIcon ?: boolean ;
29+ onClick ?: ( event : { checked : boolean , value : any } ) => void ;
30+ }
31+
32+ export default class CheckboxTree extends React . Component < CheckboxProps > { }
33+ }
You can’t perform that action at this time.
0 commit comments