mirror of
https://github.com/ccmdi/obsidian-map-plus.git
synced 2026-07-22 06:43:14 +00:00
fix: rerender map on window change to refresh deckgl click handlers
This commit is contained in:
parent
c778b0b9c7
commit
ee7c1788b2
2 changed files with 10 additions and 0 deletions
|
|
@ -533,6 +533,7 @@ export function createMapRenderer(config: MapRendererOptions): Deck<MapViewType[
|
|||
touchRotate: false,
|
||||
keyboard: false,
|
||||
dragRotate: false,
|
||||
dragPan: true,
|
||||
},
|
||||
views: [new MapViewType({
|
||||
repeat: true,
|
||||
|
|
|
|||
|
|
@ -51,6 +51,15 @@ export class MapBasesView extends BasesView {
|
|||
this.refresh();
|
||||
})
|
||||
);
|
||||
|
||||
this.register(
|
||||
this.containerEl.onWindowMigrated(() => {
|
||||
if (this.deck) {
|
||||
this.destroyMap();
|
||||
this.renderMap();
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
refresh(): void {
|
||||
|
|
|
|||
Loading…
Reference in a new issue