This commit is contained in:
Fathardie 2016-10-06 05:08:54 +00:00 committed by GitHub
commit 46e8c12282

View file

@ -1056,6 +1056,8 @@
var dragOrResize = function(event, ui) {
var x = Math.round(ui.position.left / cellWidth);
var y = Math.floor((ui.position.top + cellHeight / 2) / cellHeight);
var yTop = Math.floor(ui.position.top / cellHeight);
var yBottom = Math.floor((ui.position.top + cellHeight) / cellHeight);
var width;
var height;
@ -1065,7 +1067,7 @@
}
if (event.type == 'drag') {
if (x < 0 || x >= self.grid.width || y < 0) {
if (x < 0 || x >= self.grid.width || yTop < 0 || yBottom > self.grid.height) {
if (self.opts.removable === true) {
self._setupRemovingTimeout(el);
}