Skip to content

Commit 52929d2

Browse files
committed
Use outerHeight/outerWidth on dragged items
Padded/bordered items that were dragged and sized using height/width were incorrectly sized.
1 parent ce2da2f commit 52929d2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

source/js/jquery-sortable.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@
9494
// Therefore it might not be the container, that actually contains the item.
9595
onDragStart: function ($item, container, _super, event) {
9696
$item.css({
97-
height: $item.height(),
98-
width: $item.width()
97+
height: $item.outerHeight(),
98+
width: $item.outerWidth()
9999
})
100100
$item.addClass(container.group.options.draggedClass)
101101
$("body").addClass(container.group.options.bodyClass)

0 commit comments

Comments
 (0)