Skip to main content

Variable: svgResize

const svgResize: (workspace) => void = common.svgResize;

Defined in: packages/blockly/core/blockly.ts:301

Size the SVG image to completely fill its container. Call this when the view actually changes sizes (e.g. on a window resize/device orientation change). See workspace.resizeContents to resize the workspace when the contents change (e.g. when a block is added or removed). Record the height/width of the SVG image.

Size the SVG image to completely fill its container. Call this when the view actually changes sizes (e.g. on a window resize/device orientation change). See workspace.resizeContents to resize the workspace when the contents change (e.g. when a block is added or removed). Record the height/width of the SVG image.

Parameters​

ParameterTypeDescription
workspaceWorkspaceSvgAny workspace in the SVG.

Returns​

void

Param​

workspace

Any workspace in the SVG.

See​

Blockly.common.svgResize