@vcmap/ui 5.2.1 → 5.2.3

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.
@@ -1828,6 +1828,24 @@
1828
1828
  }
1829
1829
  ],
1830
1830
  "plugins": [
1831
+ {
1832
+ "name": "@vcmap/link-button",
1833
+ "entry": "plugins/@vcmap/link-button/index.js",
1834
+ "buttons": [
1835
+ {
1836
+ "buttonLocation": 5,
1837
+ "templateUrl": "https://new.virtualcitymap.de/?state=[[[{{cameraPosition}}],[{{groundPosition}}],{{distance}},{{heading}},{{pitch}},{{roll}}],\"cesium\",[\"VC Map Demo\"]]",
1838
+ "title": "Zweites Fenster öffnen",
1839
+ "projection": {}
1840
+ },
1841
+ {
1842
+ "buttonLocation": 5,
1843
+ "templateUrl": "https://www.virtualcitymap.de/?cameraPosition={{cameraPosition}}&groundPosition={{groundPosition}}&distance={{distance}}&pitch={{pitch}}&heading={{heading}}&roll={{roll}}#/",
1844
+ "title": "Alte 4.3 Map öffnen",
1845
+ "projection": {}
1846
+ }
1847
+ ]
1848
+ },
1831
1849
  {
1832
1850
  "name": "@vcmap/create-link",
1833
1851
  "entry": "plugins/@vcmap/create-link/index.js"
@@ -1 +1 @@
1
- export * from "./cesium.1b488a.js";
1
+ export * from "./cesium.e80583.js";
@@ -1,8 +1,8 @@
1
1
  var Hu = Object.defineProperty;
2
2
  var ju = (i, t, e) => t in i ? Hu(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
3
3
  var h = (i, t, e) => (ju(i, typeof t != "symbol" ? t + "" : t, e), e);
4
- import { ol$proj$getTransform as Ae, ol$proj$get as Vu, ol$proj$equivalent as $u, ol$proj$proj4$register as Yo, ol$geom$Circle as bt, ol$geom$GeometryCollection as Dr, ol$style$Style as ee, ol$style$Fill as st, ol$style$Stroke as Ve, ol$style$Text as fo, ol$style$Icon as wi, ol$style$Circle as Mi, ol$style$RegularShape as Ar, ol$has$DEVICE_PIXEL_RATIO as Bu, ol$style$Image as Ih, ol$Feature as ae, ol$extent$containsCoordinate as za, ol$Map as Uu, ol$interaction$defaults as qu, ol$Observable$unByKey as re, ol$View as go, ol$easing$inAndOut as Wu, ol$extent$containsXY as Lh, ol$extent$boundingExtent as rr, ol$layer$Vector as Th, ol$extent$getBottomLeft as mo, ol$geom$SimpleGeometry as Xu, ol$geom$Point as Nt, ol$geom$LineString as Ut, ol$geom$Polygon as Dt, ol$geom$MultiPoint as Nh, ol$geom$MultiLineString as Dh, ol$geom$MultiPolygon as nr, ol$sphere$offset as un, ol$geom$Polygon$fromCircle as Ah, ol$geom$Polygon$circular as Yu, ol$colorlike$asColorLike as Zu, Feature as At, ol$ImageState as Kr, ol$extent$getBottomRight as Fh, ol$extent$getTopRight as Rh, ol$extent$getTopLeft as Jn, ol$proj$transform as Ri, ol$source$Vector as ar, ol$tilegrid$createXYZ as Gh, ol$TileState as kh, ol$proj$Projection as Ku, ol$tilegrid$TileGrid as zh, ol$source$TileImage as Ju, ol$layer$Tile as bs, ol$extent$buffer as Hh, ol$extent$getCenter as or, ol$geom$Polygon$fromExtent as Qu, ol$proj$transformExtent as Zo, ol$sphere$getDistance as ed, ol$format$GeoJSON as jh, ol$extent$getWidth as Ha, ol$source$TileWMS as td, ol$source$ImageWMS as id, ol$format$GML2 as ja, ol$format$WFS as Va, ol$format$GML3 as $a, ol$extent$createEmpty as _s, ol$structs$LRUCache as sd, ol$extent$createOrUpdateFromCoordinate as rd, ol$render$canvas$Immediate as nd, ol$geom$flat$transform$transform2D as ad, ol$extent$intersects as od, ol$geom$SimpleGeometry$transformGeom2D as ld, ol$transform$scale as hd, ol$transform$create as cd, ol$transform$compose as ud, ol$extent$extend as lr, ol$source$OSM as dd, ol$layer$Image as Vh, ol$source$ImageStatic as fd, ol$source$TileDebug as gd, ol$source$XYZ as md, ol$source$VectorTile as pd, ol$layer$VectorTile as yd, ol$tilegrid$WMTS as _d, ol$source$WMTS as vd, ol$format$MVT as Sd, ol$coordinate$equals as wd, ol$interaction$DragPan as Md, ol$extent$isEmpty as Ba, ol$geom$LinearRing as Cd } from "./ol.7488a7.js";
5
- import { Math as N, Cartesian3 as _, Cartographic as se, Cesium3DTileStyle as Mn, Cesium3DTileColorBlendMode as dn, Color as U, TrustedServers as Xt, VerticalOrigin as gt, Cesium3DTileFeature as qi, Cesium3DTilePointFeature as Wi, Entity as Xi, Material as Ft, Cartesian2 as H, Matrix3 as X, Quaternion as Cn, Primitive as pt, GeometryInstance as ct, FrustumGeometry as xd, ColorGeometryInstanceAttribute as hr, PerInstanceColorAppearance as vs, FrustumOutlineGeometry as bd, destroyObject as Od, EasingFunction as Ed, ConditionsExpression as Pd, Expression as Id, HeightReference as Le, ClassificationType as gs, NearFarScalar as Js, SplitDirection as Me, SceneTransforms as Ld, MaterialAppearance as xn, ShadowMode as Fr, ClassificationPrimitive as $h, GroundPrimitive as Ko, PolylineMaterialAppearance as Ua, GroundPolylinePrimitive as Jo, PolygonGeometry as Td, PolygonOutlineGeometry as Nd, GroundPolylineGeometry as po, PolylineGeometry as Gi, PolygonHierarchy as qa, CircleGeometry as Dd, CircleOutlineGeometry as Ad, HeadingPitchRoll as zi, Matrix4 as R, Transforms as Ci, Model as yo, sampleTerrainMostDetailed as Qn, ModelAnimationLoop as Fd, CylinderOutlineGeometry as Rd, CylinderGeometry as Bh, EllipsoidOutlineGeometry as Gd, EllipsoidGeometry as Uh, SphereOutlineGeometry as kd, SphereGeometry as zd, BoxOutlineGeometry as Hd, BoxGeometry as qh, WallGeometry as jd, WallOutlineGeometry as Vd, LabelStyle as ga, HorizontalOrigin as ma, CatmullRomSpline as Wh, ArcType as bn, PrimitiveCollection as xi, BillboardCollection as $d, LabelCollection as Bd, Resource as Ud, CesiumTerrainProvider as Qo, Cartesian4 as el, sampleTerrain as qd, Ellipsoid as Wa, Clock as Wd, DataSourceClock as Xd, JulianDate as Xh, KeyboardEventModifier as pa, ScreenSpaceEventType as gi, CesiumWidget as Yd, DataSourceDisplay as tl, DataSourceCollection as il, RequestScheduler as Zd, ScreenSpaceEventHandler as Kd, Ray as Yh, Camera as Zh, ImageryLayer as Yi, CustomDataSource as Kh, BoundingSphere as Jh, Intersect as Jd, BillboardVisualizer as Qd, LabelVisualizer as ef, PointVisualizer as tf, WebMercatorTilingScheme as _o, GeographicTilingScheme as Qh, Rectangle as yt, Cesium3DTileset as On, Composite3DTileContent as sf, HeadingPitchRange as rf, BoundingSphereState as sl, OpenStreetMapImageryProvider as nf, SingleTileImageryProvider as af, TileMapServiceImageryProvider as of, Event as rl, WebMapServiceImageryProvider as lf, WebMapTileServiceImageryProvider as hf, EntityCollection as cf, CzmlDataSource as uf, Plane as ie, ClippingPlaneCollection as cr, ClippingPlane as ur, ConstantProperty as df, Globe as ff, LinearSpline as gf, QuaternionSpline as mf, CoplanarPolygonGeometry as pf, IntersectionTests as yf } from "./cesium.1b488a.js";
4
+ import { ol$proj$getTransform as Ae, ol$proj$get as Vu, ol$proj$equivalent as $u, ol$proj$proj4$register as Yo, ol$geom$Circle as bt, ol$geom$GeometryCollection as Dr, ol$style$Style as ee, ol$style$Fill as st, ol$style$Stroke as Ve, ol$style$Text as fo, ol$style$Icon as wi, ol$style$Circle as Mi, ol$style$RegularShape as Ar, ol$has$DEVICE_PIXEL_RATIO as Bu, ol$style$Image as Ih, ol$Feature as ae, ol$extent$containsCoordinate as za, ol$Map as Uu, ol$interaction$defaults as qu, ol$Observable$unByKey as re, ol$View as go, ol$easing$inAndOut as Wu, ol$extent$containsXY as Lh, ol$extent$boundingExtent as rr, ol$layer$Vector as Th, ol$extent$getBottomLeft as mo, ol$geom$SimpleGeometry as Xu, ol$geom$Point as Nt, ol$geom$LineString as Ut, ol$geom$Polygon as Dt, ol$geom$MultiPoint as Nh, ol$geom$MultiLineString as Dh, ol$geom$MultiPolygon as nr, ol$sphere$offset as un, ol$geom$Polygon$fromCircle as Ah, ol$geom$Polygon$circular as Yu, ol$colorlike$asColorLike as Zu, Feature as At, ol$ImageState as Kr, ol$extent$getBottomRight as Fh, ol$extent$getTopRight as Rh, ol$extent$getTopLeft as Jn, ol$proj$transform as Ri, ol$source$Vector as ar, ol$tilegrid$createXYZ as Gh, ol$TileState as kh, ol$proj$Projection as Ku, ol$tilegrid$TileGrid as zh, ol$source$TileImage as Ju, ol$layer$Tile as bs, ol$extent$buffer as Hh, ol$extent$getCenter as or, ol$geom$Polygon$fromExtent as Qu, ol$proj$transformExtent as Zo, ol$sphere$getDistance as ed, ol$format$GeoJSON as jh, ol$extent$getWidth as Ha, ol$source$TileWMS as td, ol$source$ImageWMS as id, ol$format$GML2 as ja, ol$format$WFS as Va, ol$format$GML3 as $a, ol$extent$createEmpty as _s, ol$structs$LRUCache as sd, ol$extent$createOrUpdateFromCoordinate as rd, ol$render$canvas$Immediate as nd, ol$geom$flat$transform$transform2D as ad, ol$extent$intersects as od, ol$geom$SimpleGeometry$transformGeom2D as ld, ol$transform$scale as hd, ol$transform$create as cd, ol$transform$compose as ud, ol$extent$extend as lr, ol$source$OSM as dd, ol$layer$Image as Vh, ol$source$ImageStatic as fd, ol$source$TileDebug as gd, ol$source$XYZ as md, ol$source$VectorTile as pd, ol$layer$VectorTile as yd, ol$tilegrid$WMTS as _d, ol$source$WMTS as vd, ol$format$MVT as Sd, ol$coordinate$equals as wd, ol$interaction$DragPan as Md, ol$extent$isEmpty as Ba, ol$geom$LinearRing as Cd } from "./ol.7d1686.js";
5
+ import { Math as N, Cartesian3 as _, Cartographic as se, Cesium3DTileStyle as Mn, Cesium3DTileColorBlendMode as dn, Color as U, TrustedServers as Xt, VerticalOrigin as gt, Cesium3DTileFeature as qi, Cesium3DTilePointFeature as Wi, Entity as Xi, Material as Ft, Cartesian2 as H, Matrix3 as X, Quaternion as Cn, Primitive as pt, GeometryInstance as ct, FrustumGeometry as xd, ColorGeometryInstanceAttribute as hr, PerInstanceColorAppearance as vs, FrustumOutlineGeometry as bd, destroyObject as Od, EasingFunction as Ed, ConditionsExpression as Pd, Expression as Id, HeightReference as Le, ClassificationType as gs, NearFarScalar as Js, SplitDirection as Me, SceneTransforms as Ld, MaterialAppearance as xn, ShadowMode as Fr, ClassificationPrimitive as $h, GroundPrimitive as Ko, PolylineMaterialAppearance as Ua, GroundPolylinePrimitive as Jo, PolygonGeometry as Td, PolygonOutlineGeometry as Nd, GroundPolylineGeometry as po, PolylineGeometry as Gi, PolygonHierarchy as qa, CircleGeometry as Dd, CircleOutlineGeometry as Ad, HeadingPitchRoll as zi, Matrix4 as R, Transforms as Ci, Model as yo, sampleTerrainMostDetailed as Qn, ModelAnimationLoop as Fd, CylinderOutlineGeometry as Rd, CylinderGeometry as Bh, EllipsoidOutlineGeometry as Gd, EllipsoidGeometry as Uh, SphereOutlineGeometry as kd, SphereGeometry as zd, BoxOutlineGeometry as Hd, BoxGeometry as qh, WallGeometry as jd, WallOutlineGeometry as Vd, LabelStyle as ga, HorizontalOrigin as ma, CatmullRomSpline as Wh, ArcType as bn, PrimitiveCollection as xi, BillboardCollection as $d, LabelCollection as Bd, Resource as Ud, CesiumTerrainProvider as Qo, Cartesian4 as el, sampleTerrain as qd, Ellipsoid as Wa, Clock as Wd, DataSourceClock as Xd, JulianDate as Xh, KeyboardEventModifier as pa, ScreenSpaceEventType as gi, CesiumWidget as Yd, DataSourceDisplay as tl, DataSourceCollection as il, RequestScheduler as Zd, ScreenSpaceEventHandler as Kd, Ray as Yh, Camera as Zh, ImageryLayer as Yi, CustomDataSource as Kh, BoundingSphere as Jh, Intersect as Jd, BillboardVisualizer as Qd, LabelVisualizer as ef, PointVisualizer as tf, WebMercatorTilingScheme as _o, GeographicTilingScheme as Qh, Rectangle as yt, Cesium3DTileset as On, Composite3DTileContent as sf, HeadingPitchRange as rf, BoundingSphereState as sl, OpenStreetMapImageryProvider as nf, SingleTileImageryProvider as af, TileMapServiceImageryProvider as of, Event as rl, WebMapServiceImageryProvider as lf, WebMapTileServiceImageryProvider as hf, EntityCollection as cf, CzmlDataSource as uf, Plane as ie, ClippingPlaneCollection as cr, ClippingPlane as ur, ConstantProperty as df, Globe as ff, LinearSpline as gf, QuaternionSpline as mf, CoplanarPolygonGeometry as pf, IntersectionTests as yf } from "./cesium.e80583.js";
6
6
  const Zi = Symbol("isMatcher"), _f = Symbol("Integer"), vf = Symbol("NonEmptyString"), vo = /* @__PURE__ */ new Map();
7
7
  [
8
8
  [String, "string"],
@@ -17897,13 +17897,13 @@ class Lu {
17897
17897
  h(this, "_categoryClassRegistry");
17898
17898
  h(this, "_categories");
17899
17899
  h(this, "_destroyed");
17900
- h(this, "_moduleMutationPromise");
17900
+ h(this, "_moduleMutationChain");
17901
17901
  h(this, "_categoryItemClassRegistry");
17902
17902
  h(this, "_tileProviderClassRegistry");
17903
17903
  h(this, "_featureProviderClassRegistry");
17904
17904
  this._id = (t == null ? void 0 : t._id) || Ue(), this.name = t.name ?? this._id, this.description = t.description, this.properties = t.properties, this._defaultDynamicModule = new hh({ _id: NS }), this._dynamicModule = this._defaultDynamicModule;
17905
17905
  const e = () => this._dynamicModule._id;
17906
- this._dynamicModuleIdChanged = new E(), this._locale = bS(), this._localeChanged = new E(), this._mapClassRegistry = new Kt(Is), this._maps = Qt(new Uo(), e, void 0, z_.bind(null, this), Pi), this._layerClassRegistry = new Kt(De), this._layers = Qt(this._maps.layerCollection, e, V_.bind(null, this), j_.bind(null, this), Ze, $_), this._layers.locale = this.locale, this._obliqueCollections = Qt(new Tt(), e, void 0, (s) => new Bi(s), Bi), this._viewpoints = Qt(new Tt(), e, void 0, H_, mt), this._styleClassRegistry = new Kt(Vr), this._styles = Qt(new Tt(), e, void 0, (s) => si(this._styleClassRegistry, s), Wt), this._modules = new Ei("_id"), this._modules.add(this._dynamicModule), this._hiddenObjects = OS(e, this._layers.globalHider), this._flights = Qt(new TS(this), e, void 0, (s) => new xs(s)), this._categoryClassRegistry = new Kt(Ic), this._categories = new Tv(this), this._destroyed = new E(), this._moduleMutationPromise = Promise.resolve(), this._categoryItemClassRegistry = new Kt(new Li()), this._tileProviderClassRegistry = new Kt(Ps), this._featureProviderClassRegistry = new Kt(Po), Yn.set(this._id, this);
17906
+ this._dynamicModuleIdChanged = new E(), this._locale = bS(), this._localeChanged = new E(), this._mapClassRegistry = new Kt(Is), this._maps = Qt(new Uo(), e, void 0, z_.bind(null, this), Pi), this._layerClassRegistry = new Kt(De), this._layers = Qt(this._maps.layerCollection, e, V_.bind(null, this), j_.bind(null, this), Ze, $_), this._layers.locale = this.locale, this._obliqueCollections = Qt(new Tt(), e, void 0, (s) => new Bi(s), Bi), this._viewpoints = Qt(new Tt(), e, void 0, H_, mt), this._styleClassRegistry = new Kt(Vr), this._styles = Qt(new Tt(), e, void 0, (s) => si(this._styleClassRegistry, s), Wt), this._modules = new Ei("_id"), this._modules.add(this._dynamicModule), this._hiddenObjects = OS(e, this._layers.globalHider), this._flights = Qt(new TS(this), e, void 0, (s) => new xs(s)), this._categoryClassRegistry = new Kt(Ic), this._categories = new Tv(this), this._destroyed = new E(), this._moduleMutationChain = { running: !1, items: [] }, this._categoryItemClassRegistry = new Kt(new Li()), this._tileProviderClassRegistry = new Kt(Ps), this._featureProviderClassRegistry = new Kt(Po), Yn.set(this._id, this);
17907
17907
  }
17908
17908
  get id() {
17909
17909
  return this._id;
@@ -18006,23 +18006,52 @@ class Lu {
18006
18006
  });
18007
18007
  }), e.startingObliqueCollectionName) {
18008
18008
  const s = this._obliqueCollections.getByKey(e.startingObliqueCollectionName);
18009
- s && [...this._maps].filter((r) => r instanceof Ne).forEach((r) => {
18010
- r.setCollection(s);
18011
- });
18009
+ s && await Promise.all([...this._maps].filter((r) => r instanceof Ne).map((r) => r.setCollection(s)));
18012
18010
  }
18013
18011
  if (e.startingMapName ? await this._maps.setActiveMap(e.startingMapName) : !this._maps.activeMap && this._maps.size > 0 && await this._maps.setActiveMap([...this._maps][0].name), e.startingViewpointName && this._maps.activeMap) {
18014
18012
  const s = this._viewpoints.getByKey(e.startingViewpointName);
18015
18013
  s && await this._maps.activeMap.gotoViewpoint(s);
18016
18014
  }
18017
18015
  }
18018
- addModule(t) {
18019
- return v(t, hh), this._moduleMutationPromise = this._moduleMutationPromise.then(async () => {
18020
- if (this._modules.hasKey(t._id)) {
18021
- Vs().info(`module with id ${t._id} already loaded`);
18022
- return;
18016
+ /**
18017
+ * When adding multiple modules, adding of previous modules are awaited.
18018
+ * If an invalid module is added an error is thrown and already added items of invalid module are removed.
18019
+ * @param module
18020
+ */
18021
+ async addModule(t) {
18022
+ v(t, hh);
18023
+ const e = async () => {
18024
+ try {
18025
+ if (this._modules.hasKey(t._id)) {
18026
+ Vs().info(`module with id ${t._id} already loaded`);
18027
+ return;
18028
+ }
18029
+ await this._parseModule(t), await this._setModuleState(t), this._modules.add(t);
18030
+ } catch (s) {
18031
+ throw await this._removeModule(t._id), s;
18023
18032
  }
18024
- await this._parseModule(t), await this._setModuleState(t), this._modules.add(t);
18025
- }), this._moduleMutationPromise;
18033
+ };
18034
+ return new Promise((s, r) => {
18035
+ this._moduleMutationChain.items.push({
18036
+ moduleId: t._id,
18037
+ mutation: e,
18038
+ resolve: s,
18039
+ reject: r
18040
+ }), this._startModuleMutationChain();
18041
+ });
18042
+ }
18043
+ _startModuleMutationChain() {
18044
+ if (!this._moduleMutationChain.running) {
18045
+ const t = this._moduleMutationChain.items.shift();
18046
+ if (t)
18047
+ try {
18048
+ this._moduleMutationChain.running = !0, t.mutation().then(() => t.resolve()).catch((e) => t.reject(e)).finally(() => {
18049
+ this._moduleMutationChain.running = !1, this._startModuleMutationChain();
18050
+ });
18051
+ } catch (e) {
18052
+ t.reject(e), this._moduleMutationChain.running = !1, this._startModuleMutationChain();
18053
+ }
18054
+ }
18026
18055
  }
18027
18056
  serializeModule(t) {
18028
18057
  if (v(t, String), !this._modules.hasKey(t))
@@ -18056,21 +18085,29 @@ class Lu {
18056
18085
  this._flights.removeModule(t)
18057
18086
  ]);
18058
18087
  }
18059
- removeModule(t) {
18060
- return this._moduleMutationPromise = this._moduleMutationPromise.then(async () => {
18061
- const e = this._modules.getByKey(t);
18062
- if (!e) {
18088
+ async removeModule(t) {
18089
+ const e = async () => {
18090
+ const s = this._modules.getByKey(t);
18091
+ if (!s) {
18063
18092
  Vs().info(`module with id ${t} has already been removed`);
18064
18093
  return;
18065
18094
  }
18066
- await this._removeModule(t), this._modules.remove(e);
18067
- }), this._moduleMutationPromise;
18095
+ await this._removeModule(t), this._modules.remove(s);
18096
+ };
18097
+ return new Promise((s, r) => {
18098
+ this._moduleMutationChain.items.push({
18099
+ moduleId: t,
18100
+ mutation: e,
18101
+ resolve: s,
18102
+ reject: r
18103
+ }), this._startModuleMutationChain();
18104
+ });
18068
18105
  }
18069
18106
  /**
18070
18107
  * Destroys the app and all its collections, their content and ui managers.
18071
18108
  */
18072
18109
  destroy() {
18073
- Object.defineProperty(this, "_moduleMutationPromise", {
18110
+ this._moduleMutationChain.running = !1, this._moduleMutationChain.items.splice(0), Object.defineProperty(this, "_moduleMutationChain", {
18074
18111
  get() {
18075
18112
  throw new Error("VcsApp was destroyed");
18076
18113
  }
@@ -1 +1 @@
1
- export * from "./core.a8552c.js";
1
+ export * from "./core.e4557f.js";
@@ -0,0 +1 @@
1
+ import{initAppFromAppConfig as p}from"./ui.855663.js";p("#app","app.config.json");
package/dist/assets/ol.js CHANGED
@@ -1 +1 @@
1
- export * from "./ol.7488a7.js";
1
+ export * from "./ol.7d1686.js";