Browse Source

#857: + will-change on drag

will-change
Lebedev Konstantin 9 years ago
parent
commit
cb1e453fe4
  1. 2
      Sortable.js

2
Sortable.js

@ -336,6 +336,7 @@
// Make the element draggable // Make the element draggable
dragEl.draggable = true; dragEl.draggable = true;
dragEl.style.willСhange = 'transform';
// Chosen item // Chosen item
_toggleClass(dragEl, _this.options.chosenClass, true); _toggleClass(dragEl, _this.options.chosenClass, true);
@ -766,6 +767,7 @@
} }
_disableDraggable(dragEl); _disableDraggable(dragEl);
dragEl.style.willChange = '';
// Remove class's // Remove class's
_toggleClass(dragEl, this.options.ghostClass, false); _toggleClass(dragEl, this.options.ghostClass, false);

Loading…
Cancel
Save