fix: keep clear control alive when map controls are initialized

This commit is contained in:
Sameh Khamis committed 2026-09-12 22:37:32 -07:00
1 parent 4a3f53bfcd
commit 648041e040
2 files changed
+1 -1

No files matched your search

+1
View File
@@ -692,6 +692,7 @@ test('visual input listeners are revoked before asynchronous UI teardown', () =>
assert.match(synchronous, /this\._applicationShortcuts\?\.destroy\(\)/);
assert.match(synchronous, /this\._visualEffects\.stop\(\)/);
assert.match(synchronous, /this\._mapSourceControls\?\.destroy\(\)/);
assert.match(synchronous, /this\._clearLayersControl\?\.destroy\(\)/);
assert.match(synchronous, /this\._displayControls\?\.destroy\(\)/);
assert.match(synchronous, /this\._styleParameters\?\.destroy\(\)/);
});
-1
View File
@@ -3331,7 +3331,6 @@ export class StyleManager {
_initMapStackControl() {
if (!this.mapStackController) return;
this._mapSourceControls?.destroy();
this._clearLayersControl?.destroy();
this._mapSourceControls = createMapSourceControls({
container: this._mapStackChips,
statusElement: this._mapStackStatus,