Comparing version 1.0.0 to 1.0.1
# History | ||
--- | ||
## 1.0.x / 2016-01-15 | ||
- change onSelect/onCheck params | ||
## 0.26.x / 2016-01-13 | ||
@@ -5,0 +8,0 @@ - change drag api (from `onTreeXX` to `onXX`) |
@@ -235,3 +235,3 @@ 'use strict'; | ||
checked: checked, | ||
checkedNodesKeys: checkKeys.checkedNodesKeys | ||
checkedNodes: checkKeys.checkedNodes | ||
}; | ||
@@ -264,6 +264,15 @@ checkedKeys = checkKeys.checkedKeys; | ||
} | ||
var selectedNodes = []; | ||
if (selectedKeys.length) { | ||
(0, _util.loopAllChildren)(this.props.children, function (item) { | ||
if (selectedKeys.indexOf(item.key) !== -1) { | ||
selectedNodes.push(item); | ||
} | ||
}); | ||
} | ||
var newSt = { | ||
event: 'select', | ||
node: treeNode, | ||
selected: selected | ||
selected: selected, | ||
selectedNodes: selectedNodes | ||
}; | ||
@@ -270,0 +279,0 @@ if (!('selectedKeys' in this.props)) { |
{ | ||
"name": "rc-tree", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "tree ui component for react", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -76,4 +76,4 @@ # rc-tree | ||
|onExpand | fire on treeNode expand or not | function(node, expanded, expandedKeys) | - | | ||
|onCheck | click the treeNode/checkbox to fire | function(checkedKeys, e:{checked:bool, node, event}) | - | | ||
|onSelect | click the treeNode to fire | function(selectedKeys, e:{selected:bool, node, event}) | - | | ||
|onCheck | click the treeNode/checkbox to fire | function(checkedKeys, e:{checked: bool, checkedNodes, node, event}) | - | | ||
|onSelect | click the treeNode to fire | function(selectedKeys, e:{selected: bool, selectedNodes, node, event}) | - | | ||
|filterTreeNode | filter some treeNodes as you need. it should return true | function(node) | - | | ||
@@ -80,0 +80,0 @@ |loadData | load data asynchronously and the return value should be a promise | function(node) | - | |
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
61452
1543