bruce-cesium 4.5.2 → 4.5.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.
@@ -1,6 +1,6 @@
1
1
  import { BruceEvent, Cartes, Entity as Entity$1, Carto, Geometry, MathUtils, LRUCache, Api, Calculator, ClientFile, EntityTag, EntityType, ObjectUtils, Style, ProjectViewTile, DelayQueue, EntityLod, Bounds, ZoomControl, EntityRelationType, ENVIRONMENT, EntityHistoricData, Tileset, EntityCoords, EntitySource, MenuItem, EntityRelation, ProgramKey, ProjectView, ProjectViewBookmark, Camera, ProjectViewLegacyTile, AbstractApi, Session, EntityAttribute, EntityAttachment, EntityAttachmentType } from 'bruce-models';
2
2
  import * as Cesium from 'cesium';
3
- import { Cartographic, JulianDate, Cartesian2, Math as Math$1, Cartesian3, CallbackProperty, Color, HeightReference, Rectangle, Entity, DistanceDisplayCondition, HorizontalOrigin, VerticalOrigin, ConstantProperty, ConstantPositionProperty, ClassificationType, ArcType, CornerType, ShadowMode, PolygonHierarchy, PolylineGraphics, ColorMaterialProperty, ColorBlendMode, HeadingPitchRoll, Transforms, Model, Primitive, Cesium3DTileFeature, SceneMode, GeoJsonDataSource, Cesium3DTileColorBlendMode, HeadingPitchRange, Cesium3DTileStyle, Ion, KmlDataSource, SceneTransforms, OrthographicFrustum, EasingFunction, NearFarScalar, EllipsoidTerrainProvider, CesiumInspector, defined, ClockRange, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, IonImageryProvider, CesiumTerrainProvider, Cesium3DTileset, Matrix4, Matrix3, IonResource, EllipsoidGeodesic, sampleTerrainMostDetailed, PolygonPipeline, BoundingSphere, GeometryInstance, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, Quaternion, ScreenSpaceEventHandler, ScreenSpaceEventType, CzmlDataSource, Intersect } from 'cesium';
3
+ import { Cartographic, JulianDate, Cartesian2, Math as Math$1, Cartesian3, CallbackProperty, Color, HeightReference, Rectangle, Entity, DistanceDisplayCondition, ClassificationType, ArcType, CornerType, ShadowMode, ConstantProperty, ConstantPositionProperty, PolygonHierarchy, PolylineGraphics, ColorMaterialProperty, HorizontalOrigin, VerticalOrigin, Primitive, Cesium3DTileFeature, SceneMode, GeoJsonDataSource, Cesium3DTileColorBlendMode, HeadingPitchRange, ColorBlendMode, HeadingPitchRoll, Transforms, Model, Cesium3DTileStyle, Ion, KmlDataSource, SceneTransforms, OrthographicFrustum, EasingFunction, NearFarScalar, Cesium3DTileset, Matrix4, Matrix3, IonResource, EllipsoidTerrainProvider, CesiumInspector, defined, ClockRange, EllipsoidGeodesic, sampleTerrainMostDetailed, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, IonImageryProvider, CesiumTerrainProvider, PolygonPipeline, BoundingSphere, GeometryInstance, Quaternion, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, ScreenSpaceEventHandler, ScreenSpaceEventType, CzmlDataSource, Intersect } from 'cesium';
4
4
 
5
5
  /*! *****************************************************************************
6
6
  Copyright (c) Microsoft Corporation. All rights reserved.
@@ -24254,7 +24254,7 @@ var WidgetLeftPanel = /** @class */ (function (_super) {
24254
24254
  var breaker = document.createElement("div");
24255
24255
  breaker.className = "NextspaceLeftPanelBreaker";
24256
24256
  this._element.appendChild(breaker);
24257
- this._addPanelTab("bookmarks", "Bookmarks", "\n <svg width=\"32\" height=\"32\" viewBox=\"0 0 32 32\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M23 25V7H9V25L16 18L23 25Z\" fill=\"white\" stroke=\"white\" stroke-linecap=\"round\" stroke-linejoin=\"round\"></path>\n </svg>\n ");
24257
+ this._addPanelTab("bookmarks", "Bookmarks", "\n <svg width=\"32\" height=\"32\" viewBox=\"0 0 32 32\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M23 25V7H9V25L16 18L23 25Z\" fill=\"white\" stroke=\"white\" stroke-linecap=\"round\" stroke-linejoin=\"round\"></path>\n </svg>\n ", "svg");
24258
24258
  var bottomBreaker = document.createElement("div");
24259
24259
  bottomBreaker.className = "NextspaceLeftPanelBottomBreaker";
24260
24260
  this._element.appendChild(bottomBreaker);
@@ -24283,9 +24283,23 @@ var WidgetLeftPanel = /** @class */ (function (_super) {
24283
24283
  // We insert before the bottom breaker.
24284
24284
  var bottomBreaker = this._element.querySelector(".NextspaceLeftPanelBottomBreaker");
24285
24285
  var afterElement = bottomBreaker ? bottomBreaker.previousElementSibling : null;
24286
- this._addPanelTab(params.tab, params.title, params.svgStr, afterElement);
24286
+ var icon;
24287
+ var iconSource;
24288
+ if (params.iconSvgStr) {
24289
+ icon = params.iconSvgStr;
24290
+ iconSource = "svg";
24291
+ }
24292
+ else if (params.iconImgUrl) {
24293
+ icon = params.iconImgUrl;
24294
+ iconSource = "file-url";
24295
+ }
24296
+ else if (params.svgStr) {
24297
+ icon = params.svgStr;
24298
+ iconSource = "svg";
24299
+ }
24300
+ this._addPanelTab(params.tab, params.title, icon, iconSource, afterElement);
24287
24301
  };
24288
- WidgetLeftPanel.prototype._addPanelTab = function (tab, title, svgStr, afterElement) {
24302
+ WidgetLeftPanel.prototype._addPanelTab = function (tab, title, icon, iconSource, afterElement) {
24289
24303
  var _this = this;
24290
24304
  var tabButton = document.createElement("div");
24291
24305
  tabButton.setAttribute("widget-left-panel-tab", tab);
@@ -24293,12 +24307,20 @@ var WidgetLeftPanel = /** @class */ (function (_super) {
24293
24307
  tabButton.title = title;
24294
24308
  var buttonBookmarksIcon = document.createElement("div");
24295
24309
  buttonBookmarksIcon.className = "NextspaceLeftPanelButtonIcon";
24296
- var buttonBookmarksIconSvg = document.createElementNS("http://www.w3.org/2000/svg", "svg");
24297
- buttonBookmarksIconSvg.setAttribute("viewBox", "0 0 32 32");
24298
- buttonBookmarksIconSvg.setAttribute("width", "32");
24299
- buttonBookmarksIconSvg.setAttribute("height", "32");
24300
- buttonBookmarksIconSvg.innerHTML = svgStr;
24301
- buttonBookmarksIcon.appendChild(buttonBookmarksIconSvg);
24310
+ if (iconSource == "svg") {
24311
+ var buttonBookmarksIconSvg = document.createElementNS("http://www.w3.org/2000/svg", "svg");
24312
+ buttonBookmarksIconSvg.setAttribute("viewBox", "0 0 32 32");
24313
+ buttonBookmarksIconSvg.setAttribute("width", "32");
24314
+ buttonBookmarksIconSvg.setAttribute("height", "32");
24315
+ buttonBookmarksIconSvg.innerHTML = icon;
24316
+ buttonBookmarksIcon.appendChild(buttonBookmarksIconSvg);
24317
+ }
24318
+ else if (iconSource == "file-url") {
24319
+ var buttonBookmarksIconImg = document.createElement("img");
24320
+ buttonBookmarksIconImg.src = icon;
24321
+ buttonBookmarksIcon.appendChild(buttonBookmarksIconImg);
24322
+ buttonBookmarksIcon.setAttribute("style", "\n max-width: 32px;\n max-height: 32px;\n ");
24323
+ }
24302
24324
  tabButton.appendChild(buttonBookmarksIcon);
24303
24325
  tabButton.onclick = function () {
24304
24326
  if (_this._enabledPanelTab === tab) {
@@ -27439,7 +27461,7 @@ var ViewerUtils;
27439
27461
  ViewerUtils.GetEventTracker = GetEventTracker;
27440
27462
  })(ViewerUtils || (ViewerUtils = {}));
27441
27463
 
27442
- var VERSION = "4.5.2";
27464
+ var VERSION = "4.5.3";
27443
27465
 
27444
27466
  export { VERSION, CesiumViewMonitor, ViewerUtils, ViewerEventTracker, MenuItemManager, EntityRenderEngine, EntityRenderEnginePoint, EntityRenderEnginePolyline, EntityRenderEnginePolygon, EntityRenderEngineModel3d, MenuItemCreator, VisualsRegister, RenderManager, EntitiesIdsRenderManager, EntitiesLoadedRenderManager, EntitiesRenderManager, EntityRenderManager, TilesetCadRenderManager, TilesetArbRenderManager, TilesetEntitiesRenderManager, TilesetOsmRenderManager, TilesetPointcloudRenderManager, TilesetGooglePhotosRenderManager, DataSourceStaticKmlManager, GoogleSearchRenderManager, RelationsRenderManager, SharedGetters, CesiumParabola, EntityLabel, ViewRenderEngine, TileRenderEngine, TilesetRenderEngine, CESIUM_INSPECTOR_KEY, CESIUM_TIMELINE_KEY, ViewUtils, DrawingUtils, MeasureUtils, EntityUtils, CesiumEntityStyler, CesiumAnimatedProperty, CesiumAnimatedInOut, Draw3dPolygon, Draw3dPolyline, MeasureCreator, Widget, VIEWER_BOOKMARKS_WIDGET_KEY, WidgetBookmarks, WidgetBranding, WidgetCursorBar, WidgetEmbeddedInfoView, WidgetInfoView, WidgetNavCompass$$1 as WidgetNavCompass, WidgetSearchBar, VIEWER_LEFT_PANEL_WIDGET_KEY, VIEWER_LEFT_PANEL_CSS_VAR_LEFT, WidgetLeftPanel, WidgetLeftPanelTab, WidgetLeftPanelTabBookmarks };
27445
27467
  //# sourceMappingURL=bruce-cesium.es5.js.map