src/connection-types.ts
Like DropTarget, it can be used just for subscribing to drag state information related to a particular item type or list of types. You do not have to connect it to a DOM element if that's all you want.
To create one, refer to SkyhookDndService.
Methods |
connectDragPreview | |||||||||
connectDragPreview(elementOrNode: Node, options?: DragPreviewOptions)
|
|||||||||
This function allows you to connect a DOM node to your You might use an
The subscription returned is automatically unsubscribed when the connection is made.
This may be immediate if the
Parameters :
Returns :
Subscription
|
connectDragSource | |||||||||
connectDragSource(elementOrNode: Node, options?: DragSourceOptions)
|
|||||||||
This function allows you to connect a DOM node to your The subscription returned is automatically unsubscribed when the connection is made.
This may be immediate if the
Parameters :
Returns :
Subscription
|
getHandlerId |
getHandlerId()
|
Returns the drag source ID that can be used to simulate the drag and drop events with the testing backend.
Returns :
any
|
setType | ||||||
setType(type: string | symbol)
|
||||||
Use this method to have a dynamically typed source. If no type has
previously been set, it creates the subscription and allows the
If you wish to have a dynamic type based on an
It may be more convenient or easier to understand if you write:
Parameters :
Returns :
void
|