diff --git a/Gruntfile.js b/Gruntfile.js index 545329df039..ac9fa9cb8e9 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -8,6 +8,7 @@ var "core.js", "widget.js", "mouse.js", + "interaction.js", "draggable.js", "droppable.js", "resizable.js", diff --git a/demos/draggable/closedhand.cur b/demos/draggable/closedhand.cur new file mode 100755 index 00000000000..41aaa62a596 Binary files /dev/null and b/demos/draggable/closedhand.cur differ diff --git a/demos/draggable/constrain-movement.html b/demos/draggable/constrain-movement.html index 1dcab0213fc..e46fb7b27ba 100644 --- a/demos/draggable/constrain-movement.html +++ b/demos/draggable/constrain-movement.html @@ -7,7 +7,7 @@ - + @@ -52,7 +61,8 @@
Constrain the movement of each draggable by defining the boundaries of the draggable area. Set the axis
option to limit the draggable's path to the x- or y-axis, or use the containment
option to specify a parent DOM element or a jQuery selector, like 'document.'
Constrain the movement of each draggable by defining the boundaries of the draggable area. The containment
option allows you to specify any element to use as a containing box; you can pass any selector or the string "parent".
The draggable element can also be constrained with custom logic inside a drag event handler. Modifying the ui.position
object's left
and/or top
properties will change where the element will be positioned. In this example, we're forcing the top or left to always be the same as where it started, resulting in the element being confined to a specific axis.