Documentation

Properties

Property Type Default Description
source array   The list of DOM element's containers which contains draggable elements.
target array   The list of DOM element's containers which accept being dropped on.
grid array   The two-dimensional array of DOM elements. Inside arrays should contain two dom elements. Generally first link is the same containers list that is set in the source parameter. And second link is usually the list that is set in the target parameter
pixelThreshold Object desktop: 0
sensor: 0
The pixel threshold of the drag beginning. It works jointly with lapse threshold. The creation of the shape and the beginning of drag starts after lapseThreshold and pixelThreshold conditions' implementaion. If both properies are equal 0, the shape creation starts immediately on element's click.
lapseThreshold Object desktop: 0
sensor: 300
The time threshold of element's drag. It works jointly with pixelThreshold. The creation of the shape and the beginning of drag starts after lapseThreshold and pixelThreshold conditions' implementaion. If both properies are equal 0, the shape creation starts immediately on element's click.
gridGutter number 0 The distance between elements in a container, This property is should to set only if the indent between elements is set by css property margin
showScrollArea boolean false Show/hide the area scrolling container.
dropZoneTime number 50 Delay before the creation of the area for dropping a portable item

Callbacks

Property Type Description
onCreateImage function The callback function triggered when element's shape created. It can used for custom user's draggable shapes creation.
onGetDragSource function The callback function triggered when element is captured.
onDragStart function The callback function triggered when dragging starts
onDragEnd function The callback function triggered when dragging ends. It also is executed if drag and drop was aborted.
onDragOverScroll function The callback function triggered if it is necessary to scroll the conatiner's content, which over the shape moves
onDragDrop function The callback function triggered when element is dropped. It is executed on the component, on which container the element is dropped on
onGetDropTarget function The callback function triggered when the target element for drop is detected
onDragOver function The callback function triggered when an accepted draggable is dragged over the droppable object

Methods

Method Returns Description
getItemImage HTMLElement Returns the image carried by the element
setCustomDragImage HTMLElement Set custom image transferred element