bruce-cesium 7.9.0 → 7.9.1
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/bruce-cesium.es5.js +29 -8
- package/dist/bruce-cesium.es5.js.map +1 -1
- package/dist/bruce-cesium.umd.js +27 -6
- package/dist/bruce-cesium.umd.js.map +1 -1
- package/dist/lib/bruce-cesium.js +1 -1
- package/dist/lib/rendering/render-managers/common/entity-label.js +4 -4
- package/dist/lib/rendering/render-managers/common/entity-label.js.map +1 -1
- package/dist/lib/rendering/visuals-register.js +22 -1
- package/dist/lib/rendering/visuals-register.js.map +1 -1
- package/dist/types/bruce-cesium.d.ts +1 -1
- package/dist/types/rendering/visuals-register.d.ts +3 -0
- package/package.json +1 -1
package/dist/bruce-cesium.es5.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as Cesium from 'cesium';
|
|
2
|
-
import { Cartographic, ColorMaterialProperty, Entity, Color, ConstantProperty, CallbackProperty, Primitive, Cesium3DTileFeature,
|
|
3
|
-
import { Cartes, LRUCache, Carto, ProjectViewTile, EntityHistoricData, BruceEvent, DelayQueue, Entity as Entity$1, EntityTag, PathUtils, ClientFile, ENVIRONMENT, EntityAttachmentType, EntityRelationType, EntityType, Tileset, Calculator, DataLab, Style, ObjectUtils, MenuItem, AccountConcept, RecordChangeFeed,
|
|
2
|
+
import { Cartographic, ColorMaterialProperty, Entity, Color, ConstantProperty, CallbackProperty, Primitive, Cesium3DTileFeature, Math as Math$1, Cartesian3, JulianDate, Quaternion, Transforms, HeadingPitchRoll, HeightReference, Matrix4, ShaderSource, Ellipsoid, Geometry, GeometryAttribute, ComponentDatatype, PrimitiveType, BoundingSphere, GeometryPipeline, Cartesian2, Cartesian4, sampleTerrain, Texture, PixelFormat, Sampler, TextureWrap, TextureMinificationFilter, TextureMagnificationFilter, PixelDatatype, VertexArray, BufferUsage, ShaderProgram, RenderState, BlendingState, DrawCommand, Pass, ConstantPositionProperty, DistanceDisplayCondition, ClassificationType, ArcType, CornerType, ColorBlendMode, Model, ImageMaterialProperty, PolygonHierarchy, PolylineGraphics, Rectangle, SceneMode, IntersectionTests, Ray, SceneTransforms, HorizontalOrigin, VerticalOrigin, NearFarScalar, Matrix3, KmlDataSource, FeatureDetection, GeoJsonDataSource, Cesium3DTileStyle, HeadingPitchRange, Ion, IonResource, Cesium3DTileColorBlendMode, Cesium3DTileset, OrthographicFrustum, EasingFunction, EllipsoidTerrainProvider, IonImageryProvider, createWorldImagery, createWorldImageryAsync, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, CesiumTerrainProvider, Intersect, WebGLConstants, EllipsoidGeodesic, sampleTerrainMostDetailed, defined, PolygonPipeline, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, PrimitiveCollection, ShadowMode, PolylineCollection, LabelCollection, LabelStyle, Material, CustomDataSource, GeometryInstance, Event, CesiumInspector, ClockRange, DynamicEnvironmentMapManager, ScreenSpaceEventHandler, ScreenSpaceEventType, CameraEventType, Plane, OrientedBoundingBox, Fullscreen, CzmlDataSource } from 'cesium';
|
|
3
|
+
import { Cartes, LRUCache, Carto, ProjectViewTile, EntityHistoricData, BruceEvent, DelayQueue, Entity as Entity$1, EntityTag, PathUtils, ClientFile, ENVIRONMENT, EntityAttachmentType, EntityRelationType, EntityType, Tileset, Calculator, DataLab, Style, ObjectUtils, MenuItem, AccountConcept, RecordChangeFeed, Geometry as Geometry$1, EntityLod, UrlUtils, Bounds, ClientFileValueMap, Color as Color$1, ProjectView, ProjectViewBookmark, ZoomControl, Assembly, EntityCoords, Api, EntityRelation, BruceApi, EntitySource, Camera, ProgramKey, ProjectViewLegacyTile, Account, AccountLimits, Session, EntityAttachment, EntityAttribute, MathUtils, ProjectViewBookmarkGroup } from 'bruce-models';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Ensures a number is returned from a given value.
|
|
@@ -11116,7 +11116,7 @@ var EntityLabel;
|
|
|
11116
11116
|
* If one exists then the action is ignored.
|
|
11117
11117
|
*/
|
|
11118
11118
|
function Attach(params) {
|
|
11119
|
-
var _a, _b, _c;
|
|
11119
|
+
var _a, _b, _c, _d;
|
|
11120
11120
|
const { rego, viewer, pos3d, visualRegister, api, options, groupId } = params;
|
|
11121
11121
|
if (!rego || !viewer) {
|
|
11122
11122
|
return;
|
|
@@ -11127,8 +11127,8 @@ var EntityLabel;
|
|
|
11127
11127
|
return Attach({
|
|
11128
11128
|
...params,
|
|
11129
11129
|
pos3d: undefined,
|
|
11130
|
-
options: (_a =
|
|
11131
|
-
groupId: (
|
|
11130
|
+
options: group ? group.options : (_b = (_a = visualRegister.GetLabelDefaults) === null || _a === void 0 ? void 0 : _a.call(visualRegister)) !== null && _b !== void 0 ? _b : options,
|
|
11131
|
+
groupId: (_c = group === null || group === void 0 ? void 0 : group.groupId) !== null && _c !== void 0 ? _c : groupId,
|
|
11132
11132
|
persistent: true
|
|
11133
11133
|
});
|
|
11134
11134
|
}
|
|
@@ -11138,7 +11138,7 @@ var EntityLabel;
|
|
|
11138
11138
|
if (rego[EntityLabel.ATTACH_KEY].Persistent && params.persistent !== true && !groupId) {
|
|
11139
11139
|
return rego[EntityLabel.ATTACH_KEY];
|
|
11140
11140
|
}
|
|
11141
|
-
rego[EntityLabel.ATTACH_KEY].Persistent = (
|
|
11141
|
+
rego[EntityLabel.ATTACH_KEY].Persistent = (_d = params.persistent) !== null && _d !== void 0 ? _d : Boolean(groupId);
|
|
11142
11142
|
rego[EntityLabel.ATTACH_KEY].Configure(options, groupId);
|
|
11143
11143
|
return rego[EntityLabel.ATTACH_KEY];
|
|
11144
11144
|
}
|
|
@@ -13851,7 +13851,7 @@ function updateEntity(viewer, entityId, register, refresh, cache = {}) {
|
|
|
13851
13851
|
viewer,
|
|
13852
13852
|
api: (_b = register.ApiGetters) === null || _b === void 0 ? void 0 : _b.GetBruceApi(),
|
|
13853
13853
|
visualRegister: register,
|
|
13854
|
-
options: labelGroup
|
|
13854
|
+
options: labelGroup ? labelGroup.options : register.GetLabelDefaults(),
|
|
13855
13855
|
groupId: labelGroup === null || labelGroup === void 0 ? void 0 : labelGroup.groupId,
|
|
13856
13856
|
persistent: true
|
|
13857
13857
|
});
|
|
@@ -14038,6 +14038,8 @@ var VisualsRegister;
|
|
|
14038
14038
|
this.menuItemSources = new Map();
|
|
14039
14039
|
// Set when the data source order no longer matches the zIndexes seen, so it is re-applied once.
|
|
14040
14040
|
this.sourceOrderDirty = false;
|
|
14041
|
+
// The look of labelled Entities no label group holds.
|
|
14042
|
+
this.labelDefaults = null;
|
|
14041
14043
|
// Stops following what is simulated, so labels can read it again when it changes.
|
|
14042
14044
|
this.simulationRemoval = null;
|
|
14043
14045
|
this.shadowsRemoval = null;
|
|
@@ -16892,6 +16894,25 @@ var VisualsRegister;
|
|
|
16892
16894
|
var _a;
|
|
16893
16895
|
return (_a = this.labelGroups) === null || _a === void 0 ? void 0 : _a.Resolve(entityId, menuItemId);
|
|
16894
16896
|
}
|
|
16897
|
+
/*
|
|
16898
|
+
* How a labelled Entity in no label group is drawn, such as an account's default look; null draws plain text.
|
|
16899
|
+
*/
|
|
16900
|
+
SetLabelDefaults(options) {
|
|
16901
|
+
if (this.disposed) {
|
|
16902
|
+
return;
|
|
16903
|
+
}
|
|
16904
|
+
const next = options ? { ...options } : null;
|
|
16905
|
+
if (JSON.stringify(next) === JSON.stringify(this.labelDefaults)) {
|
|
16906
|
+
return;
|
|
16907
|
+
}
|
|
16908
|
+
this.labelDefaults = next;
|
|
16909
|
+
for (const entityId of this.GetLabelled()) {
|
|
16910
|
+
this.queueUpdate({ entityId, refresh: false });
|
|
16911
|
+
}
|
|
16912
|
+
}
|
|
16913
|
+
GetLabelDefaults() {
|
|
16914
|
+
return this.labelDefaults ? { ...this.labelDefaults } : null;
|
|
16915
|
+
}
|
|
16895
16916
|
/*
|
|
16896
16917
|
* Called by a group label once it is on screen, so its entity's default image is read only when it can be seen.
|
|
16897
16918
|
*/
|
|
@@ -61275,7 +61296,7 @@ var StyleUtils;
|
|
|
61275
61296
|
StyleUtils.ApplyTypeStyle = ApplyTypeStyle;
|
|
61276
61297
|
})(StyleUtils || (StyleUtils = {}));
|
|
61277
61298
|
|
|
61278
|
-
const VERSION = "7.9.
|
|
61299
|
+
const VERSION = "7.9.1";
|
|
61279
61300
|
/**
|
|
61280
61301
|
* Updates the environment instance used by bruce-cesium to one specified.
|
|
61281
61302
|
* This can be used to ensure that the instance a parent is referencing is shared between bruce-cesium, bruce-models, and the parent app.
|