GeoJSON format is used in GIS tools such as QGIS. Check out wiki-page for guidance
-
-
Generator uses pop-up window to download files. Please ensure your browser does not block popups.
-
-
It's also possible to export map to Foundry VTT, see the module.
+
GeoJSON format is used in GIS tools such as QGIS. Check out wiki-page for guidance.
+
Generator uses pop-up window to download files. Please ensure your browser does not block popups.
+
It's also possible to export map to Foundry VTT, see the module.
@@ -4572,9 +4570,9 @@
Save map to
-
+
-
Maps are saved in .map format, that can be loaded back via 'Load' in menu. Please keep noted that we do not keep any data on our side. There is no way to restore the progress if .map file is lost. Please keep old .map files on your machine or cloud storage as backups.
+
Maps are saved in .map format, that can be loaded back via the Load in menu. There is no way to restore the progress if file is lost. Please keep old .map files on your machine or cloud storage as backups.
@@ -4584,12 +4582,11 @@
-
-
From your Dropbox account:
-
+
+ From your Dropbox account
+
-
+
@@ -4601,7 +4598,7 @@
-
Map will be split into tiles and downloaded as a single zip file. Avoid saving to big images
+
Map will be split into tiles and downloaded as a single zip file. Avoid saving to big images
Columns:
diff --git a/modules/load.js b/modules/load.js
index f28c6d17..afe1e89b 100644
--- a/modules/load.js
+++ b/modules/load.js
@@ -12,9 +12,10 @@ function quickLoad() {
});
}
-async function loadFromDropbox(fileName) {
- const map = document.querySelector("#loadFromDropbox select").value;
- console.log('loading dropbox map', map);
+async function loadFromDropbox() {
+ const mapPath = document.getElementById("#loadFromDropboxSelect")?.value;
+
+ DEBUG && console.log("Loading map from Dropbox:", mapPath);
const blob = await Cloud.providers.dropbox.load(map);
uploadMap(blob);
}
@@ -23,18 +24,18 @@ async function createSharableDropboxLink() {
const mapFile = document.querySelector("#loadFromDropbox select").value;
const sharableLink = document.getElementById("sharableLink");
const sharableLinkContainer = document.getElementById("sharableLinkContainer");
- let url
+ let url;
try {
url = await Cloud.providers.dropbox.getLink(mapFile);
} catch {
tip("Dropbox API error. Can not create link.", true, "error", 2000);
- return
+ return;
}
const fmg = window.location.href.split("?")[0];
- const reallink= `${fmg}?maplink=${url}`;
+ const reallink = `${fmg}?maplink=${url}`;
// voodoo magic required by the yellow god of CORS
- const link = reallink.replace('www.dropbox.com/s/', 'dl.dropboxusercontent.com/1/view/')
+ const link = reallink.replace("www.dropbox.com/s/", "dl.dropboxusercontent.com/1/view/");
const shortLink = link.slice(0, 50) + "...";
sharableLinkContainer.style.display = "block";