aboutsummaryrefslogtreecommitdiffhomepage
path: root/addon
diff options
context:
space:
mode:
authorHsieh Chin Fan <pham@topo.tw>2024-10-17 23:22:21 +0800
committerHsieh Chin Fan <pham@topo.tw>2024-10-17 23:31:11 +0800
commit57da0e9a53c178aafdfac369abc32e0998162982 (patch)
tree33ffb9606a983d110b136d2edb738a1bbc329179 /addon
parent4dd0fa87859e6ffa1b230eedd1388098a8ba81a1 (diff)
parent5867b4fb5d64ce3922e8bb2aae7d47ede1c753e8 (diff)
Merge branch from "addon"
Diffstat (limited to 'addon')
-rw-r--r--addon/index.mjs16
-rw-r--r--addon/manifest.json3
2 files changed, 11 insertions, 8 deletions
diff --git a/addon/index.mjs b/addon/index.mjs
index 77716b6..d138775 100644
--- a/addon/index.mjs
+++ b/addon/index.mjs
@@ -34,10 +34,12 @@ const simpleRender = window.mapclay.renderWith(config => ({
34 }, 34 },
35})) 35}))
36 36
37window.generateMaps(document.querySelector('main') ?? document.body, { 37if (!document.querySelector('.Dumby')) {
38 crs: url.searchParams.get('crs') ?? 'EPSG:4326', 38 window.generateMaps(document.querySelector('main') ?? document.body, {
39 addBlocks, 39 crs: url.searchParams.get('crs') ?? 'EPSG:4326',
40 initialLayout: 'sticky', 40 addBlocks,
41 render: simpleRender, 41 initialLayout: 'sticky',
42 autoMap: true, 42 render: simpleRender,
43}) 43 autoMap: true,
44 })
45}
diff --git a/addon/manifest.json b/addon/manifest.json
index 2d7b1ed..93b0b65 100644
--- a/addon/manifest.json
+++ b/addon/manifest.json
@@ -30,6 +30,7 @@
30 "activeTab", 30 "activeTab",
31 "tabs", 31 "tabs",
32 "scripting", 32 "scripting",
33 "https://epsg.io/*" 33 "https://epsg.io/*",
34 "https://cdn.jsdelivr.net/*"
34 ] 35 ]
35} 36}