Skip to main content

Home > @jsplumbtoolkit/drop > DropManager

DropManager class#

Offers a means to configure some element in the UI to act as a source for drag/drop of new nodes/groups. This is a concrete class that can be used standalone, but note that it is extended by the SurfaceDropManager, and for the vast majority of applications, SurfaceDropManager will be the class you want to use. The difference between the two classes is that DropManager provides a means for you to respond to items being dropped onto a surface canvas, but it does not do anything when such an event occurs other than inform you, via a set of callbacks, whereas the SurfaceDropManager provides implementations of these callbacks that manipulate the canvas and the data model.

Signature:

export declare class DropManager<T> 

Constructors#

ConstructorModifiersDescription
(constructor)(params)Constructs a new instance of the DropManager class

Properties#

PropertyModifiersTypeDescription
canvasDropFilterCanvasDropFilter<T>
canvasSelectorstring
dataGeneratorDataGeneratorFunction<T>
dragDrag
dragActiveClassstring
dragHoverClassstring
dragManagerCollicat
dropFilterDropFilter<T>
edgeDropFilterEdgeDropFilter<T>
gridGrid
ignoreGridboolean
onCanvasDropCanvasDropFunction<T>
onDragDragFunction<T>
onDropDropFunction<T>
onEdgeDropEdgeDropFunction<T>
scopestring
selectorstring
sourceElement

Methods#

MethodModifiersDescription
isEffectivelyOnCanvas(e)
setEnabled(e)sets whether or not dragging is currently enabled.