Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions packages/blockly/core/block_svg.ts
Original file line number Diff line number Diff line change
Expand Up @@ -354,8 +354,8 @@ export class BlockSvg
* @returns Object with .x and .y properties in workspace coordinates.
*/
override getRelativeToSurfaceXY(): Coordinate {
const layerManger = this.workspace.getLayerManager();
if (!layerManger) {
const layerManager = this.workspace.getLayerManager();
if (!layerManager) {
throw new Error(
'Cannot calculate position because the workspace has not been appended',
);
Expand All @@ -371,7 +371,7 @@ export class BlockSvg
x += xy.x;
y += xy.y;
element = element.parentNode as SVGElement;
} while (element && !layerManger.hasLayer(element));
} while (element && !layerManager.hasLayer(element));
}
return new Coordinate(x, y);
}
Expand Down