Comparing version 0.22.2 to 0.23.0
# History | ||
--- | ||
## 0.23.x / 2015-12-31 | ||
- change onDataLoaded api to loadData | ||
## 0.22.x / 2015-12-30 | ||
- add expandedKeys/onExpand/filterTreeNode API | ||
## 0.21.x / 2015-12-25 | ||
- add onMouseEnter/onMouseLeave API | ||
## 0.20.0 / 2015-12-01 | ||
@@ -5,0 +14,0 @@ - add draggable feature #5 |
@@ -241,4 +241,4 @@ 'use strict'; | ||
expandedKeys.push(tnProps.eventKey); | ||
if (thisProps.onDataLoaded) { | ||
return thisProps.onDataLoaded(treeNode).then(function () { | ||
if (thisProps.loadData) { | ||
return thisProps.loadData(treeNode).then(function () { | ||
_this2.setState({ | ||
@@ -585,3 +585,3 @@ expandedKeys: expandedKeys | ||
pos: pos, | ||
onDataLoaded: props.onDataLoaded, | ||
loadData: props.loadData, | ||
onMouseEnter: props.onMouseEnter, | ||
@@ -671,3 +671,3 @@ onMouseLeave: props.onMouseLeave, | ||
onSelect: _react.PropTypes.func, | ||
onDataLoaded: _react.PropTypes.func, | ||
loadData: _react.PropTypes.func, | ||
onMouseEnter: _react.PropTypes.func, | ||
@@ -674,0 +674,0 @@ onMouseLeave: _react.PropTypes.func, |
@@ -303,3 +303,3 @@ 'use strict'; | ||
newChildren = null; | ||
if (!props.onDataLoaded || props.isLeaf) { | ||
if (!props.loadData || props.isLeaf) { | ||
canRenderSwitcher = false; | ||
@@ -310,3 +310,3 @@ } | ||
var selectHandle = function selectHandle() { | ||
var icon = props.showIcon || props.onDataLoaded && _this3.state.dataLoading ? _react2['default'].createElement('span', { className: (0, _classnames2['default'])(iconEleCls) }) : null; | ||
var icon = props.showIcon || props.loadData && _this3.state.dataLoading ? _react2['default'].createElement('span', { className: (0, _classnames2['default'])(iconEleCls) }) : null; | ||
var title = _react2['default'].createElement( | ||
@@ -313,0 +313,0 @@ 'span', |
{ | ||
"name": "rc-tree", | ||
"version": "0.22.2", | ||
"version": "0.23.0", | ||
"description": "tree ui component for react", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -77,3 +77,3 @@ # rc-tree | ||
|filterTreeNode | filter some treeNodes as you need. it should return true | function(treeNode) | - | | ||
|onDataLoaded | load data asynchronously and the return value should be a promise | function(node) | - | | ||
|loadData | load data asynchronously and the return value should be a promise | function(node) | - | | ||
|onRightClick | select current treeNode and show customized contextmenu | function({event,node}) | - | | ||
@@ -80,0 +80,0 @@ |onMouseEnter | call when mouse enter a treeNode | function({event,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
58999