Skip to main content

Home > @jsplumbtoolkit/browser-ui > Surface > zoomToElements

Surface.zoomToElements() method#

Zooms the viewport so that all of the given elements are visible.

Signature:

zoomToElements(zParams: {        elements: Array<Element>;        fill?: number;        doNotZoomIfVisible?: boolean;        doNotAnimate?: boolean;        onComplete?: (p: PointXY) => any;        onStep?: () => any;        doNotFirePanEvent?: boolean;    }): void;

Parameters#

ParameterTypeDescription
zParams{ elements: Array<Element>; fill?: number; doNotZoomIfVisible?: boolean; doNotAnimate?: boolean; onComplete?: (p: PointXY) => any; onStep?: () => any; doNotFirePanEvent?: boolean; }

Returns:

void