mobility-toolbox-js 3.0.1-beta.5 → 3.0.1-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/mbt.js +0 -11
- package/mbt.js.map +2 -2
- package/mbt.min.js +1 -1
- package/mbt.min.js.map +3 -3
- package/ol/layers/MaplibreStyleLayer.js +0 -11
- package/package.json +1 -1
|
@@ -226,21 +226,10 @@ class MaplibreStyleLayer extends Layer {
|
|
|
226
226
|
* @override
|
|
227
227
|
*/
|
|
228
228
|
attachToMap(map) {
|
|
229
|
-
if (this.maplibreLayer && !this.maplibreLayer.getMapInternal()) {
|
|
230
|
-
map.addLayer(this.maplibreLayer);
|
|
231
|
-
}
|
|
232
229
|
const mapInternal = this.getMapInternal();
|
|
233
230
|
if (!mapInternal || !this.maplibreLayer) {
|
|
234
231
|
return;
|
|
235
232
|
}
|
|
236
|
-
if (!mapInternal.getTargetElement()) {
|
|
237
|
-
// If ther e is no target element the mapLibreMap is not yet created, we
|
|
238
|
-
// relaunch the initialisation when it's the case.
|
|
239
|
-
this.olEventsKeys.push(mapInternal.on('change:target', () => {
|
|
240
|
-
this.attachToMap(map);
|
|
241
|
-
}));
|
|
242
|
-
return;
|
|
243
|
-
}
|
|
244
233
|
// Apply the initial visibility if possible otherwise we wait for the load event of the layer
|
|
245
234
|
const { mapLibreMap } = this.maplibreLayer;
|
|
246
235
|
if (mapLibreMap) {
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "mobility-toolbox-js",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"description": "Toolbox for JavaScript applications in the domains of mobility and logistics.",
|
|
5
|
-
"version": "3.0.1-beta.
|
|
5
|
+
"version": "3.0.1-beta.6",
|
|
6
6
|
"homepage": "https://mobility-toolbox-js.geops.io/",
|
|
7
7
|
"exports": {
|
|
8
8
|
".": "./index.js",
|