fix: Error when a zoomable element is removed during zoom initialization (#2624)

- Closes: #2410
This commit is contained in:
Dermot Duffy authored and GitHub committed 2026-07-26 20:54:07 -07:00
1 parent ad89aa9538
commit 231e3087b7
4 files changed
+12 -7

No files matched your search

+3 -1
View File
@@ -18,7 +18,7 @@ import {
export class ZoomController {
private _element: HTMLElement;
private _panzoom?: PanzoomObject;
private _panzoom: PanzoomObject | null = null;
// Is the controller zoomed in at all?
private _zoomed = false;
@@ -184,6 +184,8 @@ export class ZoomController {
this._resizeObserver.disconnect();
this._element.removeEventListener('panzoomchange', this._debouncedChangeHandler);
this._panzoom = null;
}
public setDefaultSettings(config: PartialZoomSettings | null): void {