venue-js 1.2.0-next.4 → 1.2.0-next.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/dist/index.js +5 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +5 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3072,7 +3072,7 @@ var CameraManager = class {
|
|
|
3072
3072
|
return this.map.getView();
|
|
3073
3073
|
};
|
|
3074
3074
|
setView = (value) => {
|
|
3075
|
-
if (this.map) {
|
|
3075
|
+
if (this.map && Object.keys(value).length !== 0) {
|
|
3076
3076
|
this.map.setView(value);
|
|
3077
3077
|
}
|
|
3078
3078
|
};
|
|
@@ -3458,6 +3458,7 @@ var Element3DRenderer = class extends EventTarget {
|
|
|
3458
3458
|
switch (feature2.geometry.type) {
|
|
3459
3459
|
case "MultiPolygon": {
|
|
3460
3460
|
const { coordinates } = feature2.geometry;
|
|
3461
|
+
if (!coordinates) return [];
|
|
3461
3462
|
const multiMeshes = coordinates.flatMap((polygonCoordinates) => {
|
|
3462
3463
|
const meshes = createPolygon({ type: "Polygon", coordinates: polygonCoordinates }, feature2);
|
|
3463
3464
|
this.threeLayer.addMesh(meshes);
|
|
@@ -3466,6 +3467,8 @@ var Element3DRenderer = class extends EventTarget {
|
|
|
3466
3467
|
return multiMeshes;
|
|
3467
3468
|
}
|
|
3468
3469
|
case "Polygon": {
|
|
3470
|
+
const { coordinates } = feature2.geometry;
|
|
3471
|
+
if (!coordinates) return [];
|
|
3469
3472
|
const meshes = createPolygon(feature2.geometry, feature2);
|
|
3470
3473
|
this.threeLayer.addMesh(meshes);
|
|
3471
3474
|
return meshes;
|
|
@@ -4173,7 +4176,7 @@ var IndoorMap = class extends EventTarget {
|
|
|
4173
4176
|
}
|
|
4174
4177
|
set dataClient(value) {
|
|
4175
4178
|
this.#dataClient = value;
|
|
4176
|
-
if (!this.options.camera
|
|
4179
|
+
if (!this.options.camera?.defaultView?.center) {
|
|
4177
4180
|
this.#dataClient.filterByType("venue").then((venues) => {
|
|
4178
4181
|
const venueCenters = (0, import_center4.default)(featureCollection(venues));
|
|
4179
4182
|
const [x, y] = venueCenters.geometry.coordinates;
|