4.6.2 • Published 5 years ago

react-dnd-ui-tree v4.6.2

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

react-dnd-ui-tree

React tree component

This project was initially developed for a webpage builder. It maintains an internal tree structure within the component through js-tree.

Demo

https://pqx.github.io/react-ui-tree

Installation

yarn add react-dnd-ui-tree

Usage

<Tree
  paddingLeft={20}              // left padding for children nodes in pixels
  tree={this.state.tree}        // tree object
  onChange={this.handleChange}  // onChange(tree) tree object changed
  renderNode={this.renderNode}  // renderNode(node) return react element
  draggable={false}
/>

// a sample tree object
// node.children, node.contracted, node.leaf properties are hardcoded
{
  "module": "react-dnd-ui-tree",
  "children": [{
    "contracted": true,
    "module": "dist",
    "children": [{
      "module": "node.js",
      "leaf": true
    }]
  }]
}

Development

License

MIT

4.6.2

5 years ago

4.6.1

5 years ago

4.6.0

5 years ago

4.5.1

5 years ago

4.4.2

5 years ago

4.5.0

6 years ago

4.4.1

6 years ago

4.4.0

6 years ago

4.3.3

6 years ago

4.3.2

6 years ago

4.3.1

6 years ago

4.3.0

6 years ago

4.2.3

6 years ago

4.2.2

6 years ago

4.2.1

6 years ago

4.2.0

6 years ago

4.1.4

6 years ago

4.1.3

6 years ago

4.1.2

6 years ago

4.1.1

6 years ago

4.1.0

6 years ago

4.0.6

6 years ago

4.0.5

6 years ago

4.0.4

6 years ago

4.0.3

6 years ago

4.0.2

6 years ago

4.0.1

6 years ago

4.0.0

6 years ago