Swappable
Extends:
Swappable is built on top of Draggable and allows swapping of draggable elements. Order is irrelevant to Swappable.
Constructor Summary
Public Constructor | ||
public |
constructor(containers: HTMLElement[] | NodeList | HTMLElement, options: Object) Swappable constructor. |
Member Summary
Public Members | ||
public |
lastOver: HTMLElement Last draggable element that was dragged over |
Method Summary
Public Methods | ||
public |
destroy() Destroys Swappable instance. |
Private Methods | ||
private |
[onDragOver](event: DragOverEvent) Drag over handler |
|
private |
[onDragStart](event: DragStartEvent) Drag start handler |
|
private |
[onDragStop](event: DragStopEvent) Drag stop handler |
Public Constructors
Public Members
public lastOver: HTMLElement source
Last draggable element that was dragged over
Properties:
Name | Type | Attribute | Description |
lastOver | * |
Public Methods
Private Methods
private [onDragOver](event: DragOverEvent) source
Drag over handler
Params:
Name | Type | Attribute | Description |
event | DragOverEvent | Drag over event |
private [onDragStart](event: DragStartEvent) source
Drag start handler
Params:
Name | Type | Attribute | Description |
event | DragStartEvent | Drag start event |
private [onDragStop](event: DragStopEvent) source
Drag stop handler
Params:
Name | Type | Attribute | Description |
event | DragStopEvent | Drag stop event |