From 83bcab8a672c9e8d997f6026e5e5f8ae769c7fed Mon Sep 17 00:00:00 2001 From: itanka9 Date: Tue, 17 Sep 2024 17:40:32 +0300 Subject: [PATCH] fix link --- src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 237d278..27b54da 100644 --- a/src/main.ts +++ b/src/main.ts @@ -22,7 +22,7 @@ load().then(mapgl => { }); new ShareControl(map, { - urlMaker: (center, zoom, rotation, pitch) => `${self.origin}?m=${encodeURIComponent(`${center.toString()}/${zoom}/p/${pitch}/r/${rotation}`)}`, + urlMaker: (center, zoom, rotation, pitch) => `${self.origin}${location.pathname}?m=${encodeURIComponent(`${center.toString()}/${zoom}/p/${pitch}/r/${rotation}`)}`, mapCodeMaker: (center, zoom, rotation, pitch) => { const id =`map-${Math.trunc(Math.random() * 10**9)}`; return `