Skip to main content

Home > blockly > blockRendering > Renderer > refreshDom

blockRendering.Renderer.refreshDom() method

Refresh the renderer after a theme change.

Signature:

refreshDom(svg: SVGElement, theme: Theme, injectionDivIfIsParent?: HTMLElement): void;

Parameters

ParameterTypeDescription
svgSVGElementThe root of the workspace's SVG.
themeThemeThe workspace theme object.
injectionDivIfIsParentHTMLElement(Optional) The div containing the parent workspace and all related workspaces and block containers, if this renderer is for the parent workspace. CSS variables representing SVG patterns will be scoped to this container. Child workspaces should not override the CSS variables created by the parent and thus do not need access to the injection div.

Returns:

void