@types/rc-tree
Advanced tools
Comparing version 1.4.7 to 1.10.0
@@ -1,13 +0,24 @@ | ||
// Type definitions for rc-tree 1.4 | ||
// Type definitions for rc-tree 1.10 | ||
// Project: https://github.com/react-component/tree | ||
// Definitions by: John Reilly <https://github.com/johnnyreilly> | ||
// Definitions by: John Reilly <https://github.com/johnnyreilly>, Methuselah96 <https://github.com/Methuselah96> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
// TypeScript Version: 2.6 | ||
// TypeScript Version: 2.7 | ||
import { | ||
Component, | ||
Props | ||
} from "react"; | ||
import { Component } from "react"; | ||
export interface TreeNodeProps extends Props<TreeNode> { | ||
export interface InternalTreeNodeProps extends TreeNodeProps { | ||
eventKey: string; | ||
expanded: boolean; | ||
selected: boolean; | ||
checked: boolean; | ||
halfChecked: boolean; | ||
pos: string; | ||
dragOver: boolean; | ||
dragOverGapTop: boolean; | ||
dragOverGapBottom: boolean; | ||
} | ||
export interface InternalTreeNode extends Component<InternalTreeNodeProps> { } | ||
export interface TreeNodeProps { | ||
/** | ||
@@ -30,6 +41,2 @@ * additional css class for treeNode | ||
/** | ||
* it's used with tree props (default)ExpandedKeys / (default)CheckedKeys / (default)SelectedKeys. You'd better set it, and it must be unique in the tree's all treeNodes | ||
*/ | ||
key?: string | number; | ||
/** | ||
* whether it is a leaf node | ||
@@ -44,3 +51,3 @@ */ | ||
expanded: boolean; | ||
node: TreeNode; | ||
node: InternalTreeNode; | ||
} | ||
@@ -50,5 +57,5 @@ | ||
checked: boolean; | ||
checkedNodes: TreeNode[]; | ||
checkedNodes: InternalTreeNode[]; | ||
halfCheckedKeys: string[]; | ||
node: TreeNode; | ||
node: InternalTreeNode; | ||
event: "check"; | ||
@@ -59,4 +66,4 @@ } | ||
selected: boolean; | ||
selectedNodes: TreeNode[]; | ||
node: TreeNode; | ||
selectedNodes: InternalTreeNode[]; | ||
node: InternalTreeNode; | ||
event: "select"; | ||
@@ -67,3 +74,3 @@ } | ||
event: Event; | ||
node: TreeNode; | ||
node: InternalTreeNode; | ||
} | ||
@@ -73,3 +80,3 @@ | ||
event: Event; | ||
node: TreeNode; | ||
node: InternalTreeNode; | ||
expandedKeys: string[]; | ||
@@ -80,8 +87,8 @@ } | ||
event: Event; | ||
node: TreeNode; | ||
dragNode: TreeNode; | ||
node: InternalTreeNode; | ||
dragNode: InternalTreeNode; | ||
dragNodesKeys: string[]; | ||
} | ||
export interface TreeProps extends Props<Tree> { | ||
export interface TreeProps { | ||
/** | ||
@@ -168,7 +175,7 @@ * additional css class of root dom node | ||
*/ | ||
filterTreeNode?(node: TreeNode): boolean; | ||
filterTreeNode?(node: InternalTreeNode): boolean; | ||
/** | ||
* load data asynchronously | ||
*/ | ||
loadData?(node: TreeNode): Promise<any>; | ||
loadData?(node: InternalTreeNode): Promise<any>; | ||
/** | ||
@@ -175,0 +182,0 @@ * whether can drag treeNode. |
{ | ||
"name": "@types/rc-tree", | ||
"version": "1.4.7", | ||
"version": "1.10.0", | ||
"description": "TypeScript definitions for rc-tree", | ||
@@ -11,2 +11,7 @@ "license": "MIT", | ||
"githubUsername": "johnnyreilly" | ||
}, | ||
{ | ||
"name": "Methuselah96", | ||
"url": "https://github.com/Methuselah96", | ||
"githubUsername": "Methuselah96" | ||
} | ||
@@ -23,4 +28,4 @@ ], | ||
}, | ||
"typesPublisherContentHash": "d06fe4967ad4a3a1f2977475522848ec573013dbfb0b0c04edf3eca1aca4ea59", | ||
"typeScriptVersion": "2.6" | ||
"typesPublisherContentHash": "5222d22f96bc3c6e8dc43e9170cdbef823812945a39813f3ad4da268dc5aa28e", | ||
"typeScriptVersion": "2.7" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
Additional Details | ||
* Last updated: Mon, 12 Feb 2018 20:53:17 GMT | ||
* Last updated: Thu, 26 Apr 2018 22:26:56 GMT | ||
* Dependencies: react | ||
@@ -17,2 +17,2 @@ * Global values: none | ||
# Credits | ||
These definitions were written by John Reilly <https://github.com/johnnyreilly>. | ||
These definitions were written by John Reilly <https://github.com/johnnyreilly>, Methuselah96 <https://github.com/Methuselah96>. |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7394
178