Socket
Socket
Sign inDemoInstall

rc-tree

Package Overview
Dependencies
Maintainers
2
Versions
306
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rc-tree - npm Package Compare versions

Comparing version 0.22.2 to 0.23.0

9

HISTORY.md
# 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

8

lib/Tree.js

@@ -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}) | - |

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc