Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

modified: time -->map.on #7

Merged
merged 3 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions dist/index-ChqpbeXL.mjs → dist/index-Cx8g3h7b.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -58966,7 +58966,7 @@ function(n) {
*/
function(n) {
function e() {
return (Rn.canvg ? Promise.resolve(Rn.canvg) : import("./index.es-BWyxJuJN-FEZKbvRu.mjs")).catch(function(t) {
return (Rn.canvg ? Promise.resolve(Rn.canvg) : import("./index.es-BWyxJuJN-DdIdVRyF.mjs")).catch(function(t) {
return Promise.reject(new Error("Could not load canvg: " + t));
}).then(function(t) {
return t.default ? t.default : t;
Expand Down Expand Up @@ -64729,11 +64729,11 @@ let Ah, $f, Sr, gi, oW = class {
on(e, t) {
setTimeout(() => {
try {
this.map.on(e, t);
return this.map.on(e, t);
} catch (i) {
console.error(`Error adding event ON listener: ${i.message}`);
}
}, 500);
}, 100);
}
/**
* Sets the style of the map.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { p as Ui } from "./index-ChqpbeXL.mjs";
import { p as Ui } from "./index-Cx8g3h7b.mjs";
var Zt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
function No(i) {
return i && i.__esModule && Object.prototype.hasOwnProperty.call(i, "default") ? i.default : i;
Expand Down
2 changes: 1 addition & 1 deletion dist/mapicgc-gl.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/mapicgc-gl.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { C as p, a as s, M as r } from "./index-ChqpbeXL.mjs";
import { C as p, a as s, M as r } from "./index-Cx8g3h7b.mjs";
export {
p as CompareMaps,
s as Config,
Expand Down
2 changes: 1 addition & 1 deletion dist/mapicgc-gl.umd.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "mapicgc-gl-js",
"homepage": "https://openicgc.github.io/mapicgc-doc/",
"version": "0.0.86",
"version": "0.0.87",
"description": "mapicgc-gl-js library",
"author": "Institut Cartogràfic i Geològic de Catalunya",
"license": "BSD-3-Clause",
Expand Down
4 changes: 2 additions & 2 deletions src/map/Map.js
Original file line number Diff line number Diff line change
Expand Up @@ -868,11 +868,11 @@ export default class Map {
on(type, func) {
setTimeout(() => {
try {
this.map.on(type, func);
return this.map.on(type, func);
} catch (error) {
console.error(`Error adding event ON listener: ${error.message}`);
}
}, 500);
}, 100);
}

/**
Expand Down
1 change: 1 addition & 0 deletions test/exemples/addControl.html
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
pitch: 0,
});
map.on("load", () => {
console.log('map', map)
// mapicgc-gl-js library:
map.addGeolocateControl(
{
Expand Down