All Projects → wuyuedefeng → vue-sortable-tree

wuyuedefeng / vue-sortable-tree

Licence: other
vue tree draggable, drag item sort

Programming Languages

Vue
7211 projects
javascript
184084 projects - #8 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to vue-sortable-tree

vue2-data-tree
A tree that data is lazy loaded. Support dragging node, checking node, editing node's name and selecting node.
Stars: ✭ 41 (-52.87%)
Mutual labels:  tree, drag, draggable
Dsladapter
🔥 Kotlin时代的Adapter, Dsl 的形式使用 RecyclerView.Adapter, 支持折叠展开, 树结构,悬停,情感图状态切换, 加载更多, 多类型Item,侧滑菜单等
Stars: ✭ 231 (+165.52%)
Mutual labels:  tree, drag
Vue Drag Tree
基于Vue的拖拽组织树
Stars: ✭ 98 (+12.64%)
Mutual labels:  tree, drag
react-native-dnd-board
A drag and drop Kanban board for React Native.
Stars: ✭ 41 (-52.87%)
Mutual labels:  drag, draggable
Vue Drag Tree Table
vue 可以拖拽排序的树形表格
Stars: ✭ 488 (+460.92%)
Mutual labels:  tree, drag
React Ui Tree
React tree component with drag & drop
Stars: ✭ 720 (+727.59%)
Mutual labels:  tree, draggable
Angular Tree Dnd
Display tree table (or list) & event Drap & Drop (allow drag multi tree-table include all type: table, ol, ul) by AngularJS
Stars: ✭ 146 (+67.82%)
Mutual labels:  tree, drag
el-table-draggable
让element-ui的table可拖动排序,支持 行,列,跨表格等特性
Stars: ✭ 68 (-21.84%)
Mutual labels:  drag, draggable
v-drag
The simplest way to integrate dragging on Vue.js
Stars: ✭ 71 (-18.39%)
Mutual labels:  drag, draggable
drag-to-close
Android library that provides a view group which allows to finish an activity by dragging a view.
Stars: ✭ 69 (-20.69%)
Mutual labels:  drag, draggable
Gijgo
Gijgo - Free Javascript Controls
Stars: ✭ 424 (+387.36%)
Mutual labels:  tree, draggable
twtree
a highly customizable tree component for vue 2
Stars: ✭ 27 (-68.97%)
Mutual labels:  tree, draggable
Vue Drag Tree
🌴🌳a Vue's drag and drop tree component || 🌾Demo
Stars: ✭ 337 (+287.36%)
Mutual labels:  tree, drag
Angular Draggable Mat Tree
Example implementation of drag and drop on Angular Material Tree
Stars: ✭ 47 (-45.98%)
Mutual labels:  tree, draggable
React Rnd
🖱 A resizable and draggable component for React.
Stars: ✭ 2,560 (+2842.53%)
Mutual labels:  drag, draggable
Vue3 Draggable Resizable
[Vue3 组件] 用于拖拽调整位置和大小的的组件,同时支持冲突检测,元素吸附对齐,实时参考线。
Stars: ✭ 159 (+82.76%)
Mutual labels:  drag, draggable
Luy Dragger
dragger with a render props
Stars: ✭ 135 (+55.17%)
Mutual labels:  drag, draggable
Ngx Smooth Dnd
angular wrapper for smooth-dnd
Stars: ✭ 152 (+74.71%)
Mutual labels:  drag, draggable
draggable-polyfill
🌈a beautify polyfill for native drag!
Stars: ✭ 49 (-43.68%)
Mutual labels:  drag, draggable
vue-component-creater-ui
拖拽式Vue组件代码生成编辑器(VCC)
Stars: ✭ 383 (+340.23%)
Mutual labels:  drag, draggable

vue-sortable-tree

npm

Demo Link

Demo Link Source Code

QQ交流群: 424580388

Install

vue version < 2.5

$ npm install [email protected] --save [must < 1.2.0]

vue version >= 2.5

$ npm install vue-sortable-tree --save

Global register

import SortableTree from 'vue-sortable-tree'
Vue.component(SortableTree.name, SortableTree)

Partial register

import SortableTree from 'vue-sortable-tree'

// then in component
components: {
  [SortableTree.name]: SortableTree
}

Usage

<template>
  <sortable-tree :data="treeData">
    <template slot-scope="{item}">
      <span>{{item.name}}</span>
    </template>
  </sortable-tree>
</template>

Params

<sortable-tree :data="treeData" attr="name" childrenAttr="children" mixinParentKey="$parent" @changePosition="changePosition">
  <template slot-scope="{item}">
    <span>{{item.name}}</span>
  </template>
</sortable-tree>
Property Type Default Description
data Object - Tree data source.
attr String 'name' A name of property in data source that will be display.
childrenAttr String children A name of property in data source that contain children node.
mixinParentKey String '' A name of property that contain parent data.
closeStateKey String '' A name of property to determine the open/close state.
draggable Boolean true Enable dragging the tree node.
Event Parameter Description
changePosition {beforeParent, data, afterParent} Trigger when node position has been changed.

依赖 sass[scss] support

if your project can't support scss please add below dependence

npm install node-sass --save-dev
npm install sass-loader --save-dev

Project demo image

img

You can design your style easily with custom template.

eg:

img

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].