qqabcv520
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
6 additions and
6 deletions
-
components/tree/demo/drag-debug.md
-
components/tree/demo/draggable.md
|
@ -57,9 +57,9 @@ class Demo extends React.Component { |
|
|
|
|
|
|
|
|
onDrop = info => { |
|
|
onDrop = info => { |
|
|
console.log(info); |
|
|
console.log(info); |
|
|
const dropKey = info.node.props.eventKey; |
|
|
const dropKey = info.node.key; |
|
|
const dragKey = info.dragNode.props.eventKey; |
|
|
const dragKey = info.dragNode.key; |
|
|
const dropPos = info.node.props.pos.split('-'); |
|
|
const dropPos = info.node.pos.split('-'); |
|
|
const dropPosition = info.dropPosition - Number(dropPos[dropPos.length - 1]); |
|
|
const dropPosition = info.dropPosition - Number(dropPos[dropPos.length - 1]); |
|
|
|
|
|
|
|
|
const loop = (data, key, callback) => { |
|
|
const loop = (data, key, callback) => { |
|
|
|
@ -60,9 +60,9 @@ class Demo extends React.Component { |
|
|
|
|
|
|
|
|
onDrop = info => { |
|
|
onDrop = info => { |
|
|
console.log(info); |
|
|
console.log(info); |
|
|
const dropKey = info.node.props.eventKey; |
|
|
const dropKey = info.node.key; |
|
|
const dragKey = info.dragNode.props.eventKey; |
|
|
const dragKey = info.dragNode.key; |
|
|
const dropPos = info.node.props.pos.split('-'); |
|
|
const dropPos = info.node.pos.split('-'); |
|
|
const dropPosition = info.dropPosition - Number(dropPos[dropPos.length - 1]); |
|
|
const dropPosition = info.dropPosition - Number(dropPos[dropPos.length - 1]); |
|
|
|
|
|
|
|
|
const loop = (data, key, callback) => { |
|
|
const loop = (data, key, callback) => { |
|
|