Home Reference Source
public class | source

ResizeMirror

Extends:

* → ResizeMirror

The ResizeMirror plugin resizes the mirror element to the dimensions of the draggable element that the mirror is hovering over

Constructor Summary

Public Constructor
public

constructor(draggable: Draggable)

ResizeMirror constructor.

Member Summary

Public Members
public

ResizeMirror remembers the last height when resizing the mirror to avoid additional writes to the DOM

public

ResizeMirror remembers the last width when resizing the mirror to avoid additional writes to the DOM

public

mirror: *

Keeps track of the mirror element

public

ResizeMirror options

Method Summary

Public Methods
public

attach()

Attaches plugins event listeners

public

detach()

Detaches plugins event listeners

public

Returns options passed through draggable

Private Methods
private

[onDragOver](dragEvent: DragOverEvent | DragOverContainer)

Drag over handler

private

Mirror created handler

private

Mirror destroy handler

private

[resize](dragEvent: DragOverEvent | DragOverContainer)

Resize function for

Public Constructors

public constructor(draggable: Draggable) source

ResizeMirror constructor.

Params:

NameTypeAttributeDescription
draggable Draggable

Draggable instance

Public Members

public lastHeight: number source

ResizeMirror remembers the last height when resizing the mirror to avoid additional writes to the DOM

Properties:

NameTypeAttributeDescription
lastHeight number

public lastWidth: number source

ResizeMirror remembers the last width when resizing the mirror to avoid additional writes to the DOM

Properties:

NameTypeAttributeDescription
lastWidth number

public mirror: * source

Keeps track of the mirror element

Properties:

NameTypeAttributeDescription
mirror HTMLElement

public options: Object source

ResizeMirror options

Properties:

NameTypeAttributeDescription
options Object

Public Methods

public attach() source

Attaches plugins event listeners

public detach() source

Detaches plugins event listeners

public getOptions(): Object source

Returns options passed through draggable

Return:

Object

Private Methods

private [onDragOver](dragEvent: DragOverEvent | DragOverContainer) source

Drag over handler

Params:

NameTypeAttributeDescription
dragEvent DragOverEvent | DragOverContainer

private [onMirrorCreated](mirrorEvent: MirrorCreatedEvent) source

Mirror created handler

Params:

NameTypeAttributeDescription
mirrorEvent MirrorCreatedEvent

private [onMirrorDestroy](mirrorEvent: MirrorDestroyEvent) source

Mirror destroy handler

Params:

NameTypeAttributeDescription
mirrorEvent MirrorDestroyEvent

private [resize](dragEvent: DragOverEvent | DragOverContainer) source

Resize function for

Params:

NameTypeAttributeDescription
dragEvent DragOverEvent | DragOverContainer