Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: frontend-collective/react-sortable-tree
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: aemoe/react-sortable-tree
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 1 commit
  • 2 files changed
  • 1 contributor

Commits on May 8, 2017

  1. Replace 'react-dnd-html5-backend' to ‘react-dnd-touch-backend’, frien…

    …dly to moblie and support touch event.
    aemoe committed May 8, 2017
    Copy the full SHA
    4333d40 View commit details
Showing with 3 additions and 3 deletions.
  1. +1 −1 package.json
  2. +2 −2 src/utils/drag-and-drop-utils.js
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -33,8 +33,8 @@
"dependencies": {
"lodash.isequal": "^4.4.0",
"react-dnd": "^2.1.4",
"react-dnd-html5-backend": "^2.1.2",
"react-dnd-scrollzone": "^3.1.0",
"react-dnd-touch-backend": "^0.3.9",
"react-virtualized": "^9.3.0"
},
"peerDependencies": {
4 changes: 2 additions & 2 deletions src/utils/drag-and-drop-utils.js
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import {
DragSource as dragSource,
DropTarget as dropTarget,
} from 'react-dnd';
import HTML5Backend from 'react-dnd-html5-backend';
import TouchBackend from 'react-dnd-touch-backend';
import {
getDepth,
} from './tree-data-utils';
@@ -166,5 +166,5 @@ export function dndWrapTarget(el, type) {
}

export function dndWrapRoot(el) {
return dragDropContext(HTML5Backend)(el);
return dragDropContext(TouchBackend({ enableMouseEvents: true }))(el);
}