Interface ElementProps

interface ElementProps {
    anchorX?: number;
    anchorY?: number;
    anid?: string;
    clipPath?: Path<PathProps>;
    draggable?: boolean | "horizontal" | "vertical";
    drift?: ((dx, dy, e?) => void);
    extra?: Dictionary<unknown>;
    globalScaleRatio?: number;
    ignore?: boolean;
    ignoreClip?: boolean;
    isGroup?: boolean;
    name?: string;
    onclick?: ElementEventCallback<unknown, unknown>;
    oncontextmenu?: ElementEventCallback<unknown, unknown>;
    ondblclick?: ElementEventCallback<unknown, unknown>;
    ondrag?: ElementEventCallback<unknown, unknown>;
    ondragend?: ElementEventCallback<unknown, unknown>;
    ondragenter?: ElementEventCallback<unknown, unknown>;
    ondragleave?: ElementEventCallback<unknown, unknown>;
    ondragover?: ElementEventCallback<unknown, unknown>;
    ondragstart?: ElementEventCallback<unknown, unknown>;
    ondrop?: ElementEventCallback<unknown, unknown>;
    onmousedown?: ElementEventCallback<unknown, unknown>;
    onmousemove?: ElementEventCallback<unknown, unknown>;
    onmouseout?: ElementEventCallback<unknown, unknown>;
    onmouseover?: ElementEventCallback<unknown, unknown>;
    onmouseup?: ElementEventCallback<unknown, unknown>;
    onmousewheel?: ElementEventCallback<unknown, unknown>;
    originX?: number;
    originY?: number;
    rotation?: number;
    scaleX?: number;
    scaleY?: number;
    silent?: boolean;
    skewX?: number;
    skewY?: number;
    textConfig?: ElementTextConfig;
    textContent?: Text;
    x?: number;
    y?: number;
}

Hierarchy (view full)

Properties

anchorX?: number

Will translated the element to the anchor position before applying other transforms.

anchorY?: number
anid?: string
clipPath?: Path<PathProps>
draggable?: boolean | "horizontal" | "vertical"
drift?: ((dx, dy, e?) => void)

Type declaration

    • (dx, dy, e?): void
    • Drift element

      Parameters

      • dx: number

        dx on the global space

      • dy: number

        dy on the global space

      • Optional e: ElementEvent

      Returns void

extra?: Dictionary<unknown>
globalScaleRatio?: number
ignore?: boolean
ignoreClip?: boolean
isGroup?: boolean
name?: string
onclick?: ElementEventCallback<unknown, unknown>
oncontextmenu?: ElementEventCallback<unknown, unknown>
ondblclick?: ElementEventCallback<unknown, unknown>
ondrag?: ElementEventCallback<unknown, unknown>
ondragend?: ElementEventCallback<unknown, unknown>
ondragenter?: ElementEventCallback<unknown, unknown>
ondragleave?: ElementEventCallback<unknown, unknown>
ondragover?: ElementEventCallback<unknown, unknown>
ondragstart?: ElementEventCallback<unknown, unknown>
ondrop?: ElementEventCallback<unknown, unknown>
onmousedown?: ElementEventCallback<unknown, unknown>
onmousemove?: ElementEventCallback<unknown, unknown>
onmouseout?: ElementEventCallback<unknown, unknown>
onmouseover?: ElementEventCallback<unknown, unknown>
onmouseup?: ElementEventCallback<unknown, unknown>
onmousewheel?: ElementEventCallback<unknown, unknown>
originX?: number

Origin of scale, rotation, skew

originY?: number
rotation?: number
scaleX?: number
scaleY?: number
silent?: boolean
skewX?: number
skewY?: number
textConfig?: ElementTextConfig
textContent?: Text
x?: number
y?: number