@arcgis/core 4.34.0-next.48 → 4.34.0-next.49
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/analysis/ElevationProfileUnits.js +1 -1
- package/analysis/support/elevationProfileLineTypes.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{6ce2f86b9b1d2f2b8675.js → 0874b88d5ae7c2b78b3b.js} +1 -1
- package/assets/esri/core/workers/chunks/{90a97ffba604c1c35532.js → 0b52c0ca432761076076.js} +65 -65
- package/assets/esri/core/workers/chunks/0c129b78e5cfe96795e1.js +1 -0
- package/assets/esri/core/workers/chunks/{9f869b331dff505b6b55.js → 1d234c057a6671acc59f.js} +1 -1
- package/assets/esri/core/workers/chunks/4cc982c99d84e896d535.js +1 -0
- package/assets/esri/core/workers/chunks/4e2b125e6e3945985a54.js +1 -0
- package/assets/esri/core/workers/chunks/5a016dcd3192d42d363e.js +1 -0
- package/assets/esri/core/workers/chunks/{574ea32d6c257e0d2079.js → 5b0c42bb95d81085061d.js} +1 -1
- package/assets/esri/core/workers/chunks/72ecf49d03bb24bf0998.js +1 -0
- package/assets/esri/core/workers/chunks/781b59ba0cabe78bc122.js +1 -0
- package/assets/esri/core/workers/chunks/{28a85997c9003cacdefb.js → 8e3c09c3524654830b14.js} +1 -1
- package/assets/esri/core/workers/chunks/bd7e303dd64a27ba6846.js +1 -0
- package/assets/esri/core/workers/chunks/cb8f2ce22274990b359c.js +1 -0
- package/assets/esri/core/workers/chunks/{0b67b16d7e6c030bcfc7.js → d4766c97d97554b3b408.js} +1 -1
- package/assets/esri/core/workers/chunks/ddd6597a66ec6b972f9c.js +1 -0
- package/chunks/LineSeries.js +1 -1
- package/chunks/Theme.js +1 -1
- package/chunks/chartUtilsAm5.js +1 -1
- package/config.js +1 -1
- package/core/lang.js +1 -1
- package/core/timeUtils.js +1 -1
- package/editing/sharedTemplates/support/sharedTemplateErrors.js +1 -1
- package/interfaces.d.ts +44 -10
- package/kernel.js +1 -1
- package/layers/LinkChartLayer.js +1 -1
- package/layers/orientedImagery/transformations/updateElevationUtils.js +1 -1
- package/layers/orientedImagery/transformations/utils.js +1 -1
- package/layers/support/rasterDatasets/pixelReader.js +1 -1
- package/libs/linkchartlayout/LinkChartLayout.js +1 -1
- package/libs/parquet/parquet.js +1 -1
- package/networks/UtilityNetwork.js +1 -1
- package/networks/support/UtilityNetworkLookupHelper.js +1 -1
- package/networks/support/networkFieldUtils.js +1 -1
- package/networks/support/typeUtils.js +1 -1
- package/package.json +4 -4
- package/rest/networks/support/CircuitLocation.js +5 -0
- package/rest/networks/support/CircuitSection.js +5 -0
- package/rest/support/Query.js +1 -1
- package/rest/support/RelationshipQuery.js +1 -1
- package/rest/utils.js +1 -1
- package/support/revision.js +1 -1
- package/support/webSceneUtils.js +1 -1
- package/symbols/cim/utils.js +1 -1
- package/views/2d/LabelManager.js +1 -1
- package/views/2d/engine/flow/utils.js +1 -1
- package/views/2d/engine/imagery/RasterBitmap.js +1 -1
- package/views/2d/engine/webgl/DisplayId.js +1 -1
- package/views/2d/engine/webgl/animations/instructions.js +1 -1
- package/views/2d/engine/webgl/mesh/templates/templateUtils.js +1 -1
- package/views/2d/interactive/editingTools.js +1 -1
- package/views/2d/layers/FeatureLayerView2D.js +1 -1
- package/views/2d/layers/features/FeatureContainer.js +1 -1
- package/views/2d/layers/features/RenderState.js +1 -1
- package/views/2d/layers/features/processor/TrackStrategy.js +1 -1
- package/views/2d/layers/features/sources/strategies/chunks/ParquetSourceChunk.js +1 -1
- package/views/2d/layers/features/support/FeatureSetReader.js +1 -1
- package/views/2d/layers/features/support/FeatureSetReaderIndirect.js +1 -1
- package/views/3d/analysis/ElevationProfile/ElevationProfileLineSceneComputation.js +5 -0
- package/views/3d/analysis/ElevationProfileAnalysisView3D.js +1 -1
- package/views/3d/environment/SunLighting.js +1 -1
- package/views/3d/layers/FlowSubView3D.js +1 -1
- package/views/3d/layers/I3SMeshView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DSymbolLayerFactory.js +1 -1
- package/views/3d/layers/support/MediaLayerInteraction.js +1 -1
- package/views/3d/terrain/terrainUtils.js +1 -1
- package/views/3d/webgl-engine/core/FBOCacheFormats.js +1 -1
- package/views/3d/webgl-engine/core/shaderModules/Matrix4sDrawUniform.js +1 -1
- package/views/3d/webgl-engine/core/shaderModules/Matrix4sPassUniform.js +1 -1
- package/views/3d/webgl-engine/lib/Program.js +1 -1
- package/views/3d/webgl-engine/lib/ShadowMap.js +1 -1
- package/views/3d/webgl-engine/materials/DefaultLayouts.js +1 -1
- package/views/3d/webgl-engine/shaders/ImageMaterialTechnique.js +1 -1
- package/views/analysis/ElevationProfile/ElevationProfileController.js +5 -0
- package/views/analysis/ElevationProfile/ElevationProfileLineComputation.js +5 -0
- package/views/analysis/ElevationProfile/ElevationProfileLineGroundComputation.js +5 -0
- package/views/analysis/ElevationProfile/ElevationProfileLineInputComputation.js +5 -0
- package/views/analysis/ElevationProfile/ElevationProfileLineQueryComputation.js +5 -0
- package/views/analysis/ElevationProfile/ProfileGenerationError.js +5 -0
- package/views/analysis/ElevationProfile/constants.js +5 -0
- package/views/analysis/ElevationProfile/elevationQuerySourceUtils.js +5 -0
- package/views/analysis/ElevationProfile/geometryUtils.js +5 -0
- package/views/analysis/ElevationProfile/profileUtils.js +5 -0
- package/views/analysis/ElevationProfile/statisticsUtils.js +5 -0
- package/views/analysis/ElevationProfile/traversalUtils.js +5 -0
- package/views/analysis/ElevationProfile/unitUtils.js +5 -0
- package/views/analysis/ElevationProfileResult.js +1 -1
- package/views/support/LayerLayerViewInfo.js +1 -1
- package/views/support/highlightOptionsUtils.js +1 -1
- package/views/webgl/Program.js +1 -1
- package/views/webgl/textureUtils.js +1 -1
- package/webscene/SunLighting.js +1 -1
- package/widgets/Daylight/DaylightViewModel.js +1 -1
- package/widgets/Daylight/support/daylightUtils.js +1 -1
- package/widgets/Editor/EditorViewModel.js +1 -1
- package/widgets/Editor/support/SketchController.js +1 -1
- package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
- package/widgets/Features/FeaturesViewModel.js +1 -1
- package/widgets/Legend/support/sizeRampUtils.js +1 -1
- package/widgets/OrientedImageryViewer/constants.js +1 -1
- package/widgets/OrientedImageryViewer/navigation/errors.js +1 -1
- package/widgets/OrientedImageryViewer.js +1 -1
- package/widgets/ShadowCast/css.js +1 -1
- package/widgets/TimeSlider/TimeSliderViewModel.js +1 -1
- package/widgets/UtilityNetworkAssociations/UtilityNetworkAssociationsViewModel.js +1 -1
- package/widgets/UtilityNetworkTraceAnalysis/UtilityNetworkTraceAnalysisViewModel.js +1 -1
- package/widgets/smartMapping/SmartMappingSliderViewModel.js +1 -1
- package/widgets/support/GridControls/GridControlsViewModel.js +1 -1
- package/arcade/credentials.js +0 -5
- package/arcade/featureset/support/Guid.js +0 -5
- package/arcade/request.js +0 -5
- package/arcade/serviceAreaMetaData.js +0 -5
- package/assets/esri/core/workers/chunks/45b450c045d5fadf71b6.js +0 -1
- package/assets/esri/core/workers/chunks/4f5e72993a4f5180d703.js +0 -1
- package/assets/esri/core/workers/chunks/516b30778cd54d29e362.js +0 -1
- package/assets/esri/core/workers/chunks/576792b5e1e13084adba.js +0 -1
- package/assets/esri/core/workers/chunks/5f7dc9657803ae3140a6.js +0 -1
- package/assets/esri/core/workers/chunks/8d51b6823ef5d290c670.js +0 -1
- package/assets/esri/core/workers/chunks/947085d176bd3a930e6f.js +0 -1
- package/assets/esri/core/workers/chunks/d09ded9fb621491e2466.js +0 -1
- package/assets/esri/core/workers/chunks/eb61b47df99a54a364c8.js +0 -1
- package/rest/versionManagement/support/GetVersionInfosResult.js +0 -5
- package/symbols/cim/quantizeTime.js +0 -5
- package/undoredo/support/DataEditingContext.js +0 -5
- package/views/2d/engine/webgl/shaderGraph/techniques/mesh/WriterRegistry.js +0 -5
- package/views/2d/interactive/editingTools/MediaTransformToolsWrapper.js +0 -5
- package/views/2d/layers/features/sources/strategies/chunks/FeatureSourceEndChunk.js +0 -5
- package/views/3d/webgl-engine/core/shaderLibrary/util/RgbaFloat16Encoding.glsl.js +0 -25
- package/webscene/spec-certification/index.js +0 -5
- package/widgets/HighlightConfigurator.js +0 -5
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import e from"../../core/Collection.js";import{EventedAccessor as i}from"../../core/Evented.js";import n from"../../core/Logger.js";import{after as s,isAbortError as r}from"../../core/promiseUtils.js";import{watch as o,initial as l,syncAndInitial as a,whenOnce as m}from"../../core/reactiveUtils.js";import{offsetDate as u}from"../../core/timeUtils.js";import{property as p}from"../../core/accessorSupport/decorators/property.js";import{ensureType as h}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as d}from"../../core/accessorSupport/decorators/subclass.js";import{T as c}from"../../chunks/TimeExtent.js";import{T as f}from"../../chunks/TimeInterval.js";import w from"../../webdoc/Widgets.js";import g from"../../webdoc/widgets/TimeSlider.js";const v=1e4;function T(t){return null!=t&&void 0!==t.count}function x(t){return null!=t&&void 0!==t.interval}function E(t){return null!=t&&void 0!==t.dates}let _=class extends i{constructor(t){super(t),this._animationController=null,this._isViewTimeExtentInitialized=!1,this._timerId=null,this.actions=new e,this.fullTimeExtent=null,this.loop=!1,this.mode="time-window",this.stops={count:10},this.timeExtent=null,this.view=null}initialize(){this.addHandles([o(()=>this.effectiveStops,()=>{this.timeExtent??=this._getDefaultTimeExtent()},l),o(()=>this.view,(t,e)=>{this._unregisterWidget(e),this._registerWidget(t)},a),o(()=>this.timeExtent,t=>{if(!this.view)return;const e=this.view.timeExtent;(t&&!t.isAllTime||e&&!e.isAllTime)&&(t&&e&&t.equals(e)||(this.view.timeExtent=t))},l),o(()=>this.view?.timeExtent,t=>{this._isViewTimeExtentInitialized?(t&&!t.isAllTime||this.timeExtent&&!this.timeExtent.isAllTime)&&(t&&this.timeExtent&&t.equals(this.timeExtent)||(this.timeExtent=t)):this._isViewTimeExtentInitialized=!0})])}destroy(){null!=this._timerId&&(clearInterval(this._timerId),this._timerId=null),this._unregisterWidget(this.view),this.view=null,this._animationController&&(this._animationController.abort(),this._animationController=null)}get effectiveStops(){const{fullTimeExtent:t,stops:e}=this;if(E(e)){const{dates:i}=e;if(!i?.length)return null;const n=i.sort((t,e)=>t.getTime()-e.getTime());if(!t)return n;const{start:s,end:r}=t;if(!s||!r)return n;return n.filter(t=>!(t.getTime()<s.getTime()||t.getTime()>r.getTime()))}if(T(e)){const i=e.timeExtent??t;return this._divideTimeExtentByCount(i,e.count)}if(x(e)){const i=e.timeExtent??t;return this._divideTimeExtentByInterval(i,e.interval)}return[]}set playRate(t){t<=0||t>36e5||("playing"===this.state&&this._startAnimation(),this._set("playRate",t))}get state(){return this.fullTimeExtent?this._animationController?"playing":"ready":"disabled"}get timeExtentValues(){const{mode:t,timeExtent:e}=this;if(!e||e.isAllTime||e.isEmpty)return null;const{start:i,end:n}=e;switch(t){case"cumulative-from-end":case"instant":return i?[i.getTime()]:null;case"cumulative-from-start":return n?[n.getTime()]:null;case"time-window":return i&&n?[i.getTime(),n.getTime()]:null}}next(){this._step({forward:!0,allowRestart:!1})}play(){this._startAnimation()}previous(){this._step({forward:!1,allowRestart:!1})}stop(){this._stopAnimation()}triggerAction(t){this.emit("trigger-action",{action:t})}updateWebDocument(t){const e=new g({currentTimeExtent:this.timeExtent,fullTimeExtent:this.fullTimeExtent,loop:this.loop,numStops:T(this.stops)?this.stops.count:null,numThumbs:"time-window"===this.mode?2:1,stopDelay:this.playRate,stopInterval:x(this.stops)?this.stops.interval:null,stops:E(this.stops)?this.stops.dates:null});t.widgets?t.widgets.timeSlider=e:t.widgets=new w({timeSlider:e})}valuesToTimeExtent(t){if(!t)return null;const e=t.sort((t,e)=>t-e).map(t=>new Date(t)),i=e.length>0?e[0]:null,n=e.length>1?e[1]:null;switch(this.mode){case"time-window":return new c({start:i,end:n});case"instant":return new c({start:i,end:i});case"cumulative-from-start":return new c({start:null,end:i});case"cumulative-from-end":return new c({start:i,end:null});default:return c.allTime}}async _animate(){try{const t=this.view,e=this._animationController?.signal;await Promise.all([s(this.playRate,null,e),t&&m(()=>!t.updating,e)])}catch(t){return r(t)||n.getLogger(this).error(t),void(this._animationController=null)}this._step({forward:!0,allowRestart:!1}),this._animationController&&this._animate()}_divideTimeExtentByCount(t,e=10){if(!t||!e)return[];const{start:i,end:n}=t;if(!i||!n)return[];if(e>v)return this._divideTimeExtentByCount(t);const s=[],r=i.getTime(),o=n.getTime()-r;for(let l=0;l<=e;l++)s.push(new Date(r+l/e*o));return s}_divideTimeExtentByInterval(t,e,i=v){if(!t||!e)return[];const{start:n,end:s}=t;if(!n||!s)return[];const r=s.getTime()-n.getTime(),o=e.toMilliseconds();if(o<=0||r/o>i)return this._divideTimeExtentByCount(t);const l=[],{value:a,unit:m}=e;let p=n;for(;p.getTime()<=s.getTime();)l.push(new Date(p
|
|
5
|
+
import{__decorate as t}from"tslib";import e from"../../core/Collection.js";import{EventedAccessor as i}from"../../core/Evented.js";import n from"../../core/Logger.js";import{after as s,isAbortError as r}from"../../core/promiseUtils.js";import{watch as o,initial as l,syncAndInitial as a,whenOnce as m}from"../../core/reactiveUtils.js";import{offsetDate as u}from"../../core/timeUtils.js";import{property as p}from"../../core/accessorSupport/decorators/property.js";import{ensureType as h}from"../../core/accessorSupport/ensureType.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as d}from"../../core/accessorSupport/decorators/subclass.js";import{T as c}from"../../chunks/TimeExtent.js";import{T as f}from"../../chunks/TimeInterval.js";import w from"../../webdoc/Widgets.js";import g from"../../webdoc/widgets/TimeSlider.js";const v=1e4;function T(t){return null!=t&&void 0!==t.count}function x(t){return null!=t&&void 0!==t.interval}function E(t){return null!=t&&void 0!==t.dates}let _=class extends i{constructor(t){super(t),this._animationController=null,this._isViewTimeExtentInitialized=!1,this._timerId=null,this.actions=new e,this.fullTimeExtent=null,this.loop=!1,this.mode="time-window",this.stops={count:10},this.timeExtent=null,this.view=null}initialize(){this.addHandles([o(()=>this.effectiveStops,()=>{this.timeExtent??=this._getDefaultTimeExtent()},l),o(()=>this.view,(t,e)=>{this._unregisterWidget(e),this._registerWidget(t)},a),o(()=>this.timeExtent,t=>{if(!this.view)return;const e=this.view.timeExtent;(t&&!t.isAllTime||e&&!e.isAllTime)&&(t&&e&&t.equals(e)||(this.view.timeExtent=t))},l),o(()=>this.view?.timeExtent,t=>{this._isViewTimeExtentInitialized?(t&&!t.isAllTime||this.timeExtent&&!this.timeExtent.isAllTime)&&(t&&this.timeExtent&&t.equals(this.timeExtent)||(this.timeExtent=t)):this._isViewTimeExtentInitialized=!0})])}destroy(){null!=this._timerId&&(clearInterval(this._timerId),this._timerId=null),this._unregisterWidget(this.view),this.view=null,this._animationController&&(this._animationController.abort(),this._animationController=null)}get effectiveStops(){const{fullTimeExtent:t,stops:e}=this;if(E(e)){const{dates:i}=e;if(!i?.length)return null;const n=i.sort((t,e)=>t.getTime()-e.getTime());if(!t)return n;const{start:s,end:r}=t;if(!s||!r)return n;return n.filter(t=>!(t.getTime()<s.getTime()||t.getTime()>r.getTime()))}if(T(e)){const i=e.timeExtent??t;return this._divideTimeExtentByCount(i,e.count)}if(x(e)){const i=e.timeExtent??t;return this._divideTimeExtentByInterval(i,e.interval)}return[]}set playRate(t){t<=0||t>36e5||("playing"===this.state&&this._startAnimation(),this._set("playRate",t))}get state(){return this.fullTimeExtent?this._animationController?"playing":"ready":"disabled"}get timeExtentValues(){const{mode:t,timeExtent:e}=this;if(!e||e.isAllTime||e.isEmpty)return null;const{start:i,end:n}=e;switch(t){case"cumulative-from-end":case"instant":return i?[i.getTime()]:null;case"cumulative-from-start":return n?[n.getTime()]:null;case"time-window":return i&&n?[i.getTime(),n.getTime()]:null}}next(){this._step({forward:!0,allowRestart:!1})}play(){this._startAnimation()}previous(){this._step({forward:!1,allowRestart:!1})}stop(){this._stopAnimation()}triggerAction(t){this.emit("trigger-action",{action:t})}updateWebDocument(t){const e=new g({currentTimeExtent:this.timeExtent,fullTimeExtent:this.fullTimeExtent,loop:this.loop,numStops:T(this.stops)?this.stops.count:null,numThumbs:"time-window"===this.mode?2:1,stopDelay:this.playRate,stopInterval:x(this.stops)?this.stops.interval:null,stops:E(this.stops)?this.stops.dates:null});t.widgets?t.widgets.timeSlider=e:t.widgets=new w({timeSlider:e})}valuesToTimeExtent(t){if(!t)return null;const e=t.sort((t,e)=>t-e).map(t=>new Date(t)),i=e.length>0?e[0]:null,n=e.length>1?e[1]:null;switch(this.mode){case"time-window":return new c({start:i,end:n});case"instant":return new c({start:i,end:i});case"cumulative-from-start":return new c({start:null,end:i});case"cumulative-from-end":return new c({start:i,end:null});default:return c.allTime}}async _animate(){try{const t=this.view,e=this._animationController?.signal;await Promise.all([s(this.playRate,null,e),t&&m(()=>!t.updating,e)])}catch(t){return r(t)||n.getLogger(this).error(t),void(this._animationController=null)}this._step({forward:!0,allowRestart:!1}),this._animationController&&this._animate()}_divideTimeExtentByCount(t,e=10){if(!t||!e)return[];const{start:i,end:n}=t;if(!i||!n)return[];if(e>v)return this._divideTimeExtentByCount(t);const s=[],r=i.getTime(),o=n.getTime()-r;for(let l=0;l<=e;l++)s.push(new Date(r+l/e*o));return s}_divideTimeExtentByInterval(t,e,i=v){if(!t||!e)return[];const{start:n,end:s}=t;if(!n||!s)return[];const r=s.getTime()-n.getTime(),o=e.toMilliseconds();if(o<=0||r/o>i)return this._divideTimeExtentByCount(t);const l=[],{value:a,unit:m}=e;let p=n;for(;p.getTime()<=s.getTime();)l.push(new Date(p)),p=u(p,a,m);return l}_getDefaultTimeExtent(){const{effectiveStops:t,mode:e}=this;if(!t||!e)return null;switch(e){case"time-window":return t.length>1?new c({start:t[0],end:t[1]}):null;case"cumulative-from-start":return t.length>0?new c({start:null,end:t[0]}):null;case"cumulative-from-end":return t.length>0?new c({start:t[0],end:null}):null;case"instant":return t.length>0?new c({start:t[0],end:t[0]}):null;default:return null}}_registerWidget(t){if(t){t.persistableViewModels.includes(this)||t.persistableViewModels.add(this)}}_startAnimation(){this._stopAnimation(),this._animationController=new AbortController,this._step({forward:!0,allowRestart:!0}),this._animate()}_step(t){const{forward:e,allowRestart:i}=t,{effectiveStops:n}=this;if(!this.timeExtentValues||!n)return;const s=n.map(t=>t.getTime()),r=this.timeExtentValues.map(t=>{const e=s.indexOf(t);if(-1!==e)return e;const i=s.reduce((e,i)=>Math.abs(i-t)<Math.abs(e-t)?i:e);return s.indexOf(i)}),o=r.map(t=>t+(e?1:-1)),l=o.some(t=>t<0||t>s.length-1),{loop:a,state:m}=this;if(l)if(a||i){const t=Math.min(...r),i=Math.max(...r),n=(e?r.map(e=>e-t):r.map(t=>t+(s.length-1-i))).map(t=>s[t]);this.timeExtent=this.valuesToTimeExtent(n)}else"playing"===m&&this.stop();else{const t=o.map(t=>s[t]);this.timeExtent=this.valuesToTimeExtent(t)}}_stopAnimation(){null!=this._animationController&&(this._animationController.abort(),this._animationController=null)}_unregisterWidget(t){null!=t&&t.persistableViewModels.remove(this)}};t([p()],_.prototype,"_animationController",void 0),t([p({type:e})],_.prototype,"actions",void 0),t([p({readOnly:!0})],_.prototype,"effectiveStops",null),t([p({type:c})],_.prototype,"fullTimeExtent",void 0),t([p({nonNullable:!0})],_.prototype,"loop",void 0),t([p({nonNullable:!0})],_.prototype,"mode",void 0),t([p({nonNullable:!0,value:1e3})],_.prototype,"playRate",null),t([p({readOnly:!0})],_.prototype,"state",null),t([p({cast:t=>t?(x(t)&&(t.interval=h(f,t.interval)),(x(t)||T(t))&&(t.timeExtent=h(c,t.timeExtent)),t):null})],_.prototype,"stops",void 0),t([p({type:c})],_.prototype,"timeExtent",void 0),t([p({readOnly:!0})],_.prototype,"timeExtentValues",null),t([p()],_.prototype,"view",void 0),t([p()],_.prototype,"next",null),t([p()],_.prototype,"play",null),t([p()],_.prototype,"previous",null),t([p()],_.prototype,"stop",null),t([p()],_.prototype,"updateWebDocument",null),_=t([d("esri.widgets.TimeSlider.TimeSliderViewModel")],_);const y=_;export{y as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import i from"../../Graphic.js";import"../../intl.js";import s from"../../core/Accessor.js";import o from"../../core/Collection.js";import e from"../../core/Error.js";import r from"../../core/Logger.js";import{watch as n}from"../../core/reactiveUtils.js";import{property as a}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as c}from"../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as l}from"../../core/support/UpdatingHandles.js";import h from"../../layers/GraphicsLayer.js";import y from"../../symbols/LineSymbolMarker.js";import m from"../../symbols/SimpleLineSymbol.js";import{addUniqueLayer as u}from"../../views/draw/support/layerUtils.js";import{onLocaleChange as p}from"../../intl/locale.js";import{fetchMessageBundle as A}from"../../intl/messages.js";const w={noAssociationTypeSpecified:-2147208504};let d=class extends s{constructor(t){super(t),this._internalGraphicsLayerConnectivity=this._createInternalGraphicsLayer("Connectivity Associations (Internal)"),this._internalGraphicsLayerStructuralAttachment=this._createInternalGraphicsLayer("Structural Attachment Associations (Internal)"),this._initialValidationsFinished=!1,this._updatingHandles=new l,this.autoRefreshAssociations=!1,this.connectivityAssociationsLineSymbol=new m({style:"short-dash",width:2,color:[190,159,159,1]}),this.executionError="",this.loadErrors=new o,this.maxAllowableAssociations=250,this.showAssociationsEnabled=!1,this.showArrowsConnectivity=!1,this.showArrowsStructuralAttachment=!1,this.structuralAttachmentAssociationsLineSymbol=new m({style:"short-dash",width:2,color:[159,190,159,1]})}initialize(){const t=async()=>{this.messages||(this.messages=await A("esri/widgets/UtilityNetworkAssociations/t9n/UtilityNetworkAssociations"))};t().then(()=>{this.view||(this.view=null),this.utilityNetwork||(this.utilityNetwork=null),this.addHandles([n(()=>[this.view,this.utilityNetwork],async()=>{const{loadErrors:t,messages:{info:{noUtilityNetwork:i,noView:s}}}=this;this._initialValidationsFinished=!1,t.removeAll();let o=!1,n=!1;this.removeAssociations(),"2d"===this.view?.type?(u(this.view,this._internalGraphicsLayerConnectivity),u(this.view,this._internalGraphicsLayerStructuralAttachment),o=!0):(this.loadErrors.push(s),r.getLogger(this).error(new e("utilityNetworkAssociations:missing-property",s))),"utility"===this.utilityNetwork?.type?n=!0:(this.loadErrors.push(i),r.getLogger(this).error(new e("utilityNetworkAssociations:missing-property",i))),o&&n&&this.showAssociationsEnabled&&await this.showAssociations(),this._internalGraphicsLayerConnectivity.visible=this.includeConnectivityAssociations,this._internalGraphicsLayerStructuralAttachment.visible=this.includeStructuralAttachmentAssociations,this._initialValidationsFinished=!0},{initial:!0}),n(()=>[this.view?.stationary,this.showAssociationsEnabled,this.maxAllowableAssociations],async()=>{this.view?.stationary&&this.showAssociationsEnabled&&(this.includeConnectivityAssociations||this.includeStructuralAttachmentAssociations)&&await this.showAssociations()}),n(()=>[this.showArrowsConnectivity],()=>{const t=this.connectivityAssociationsLineSymbol.clone();t.marker=null,this.showArrowsConnectivity&&(t.marker=new y({color:this.connectivityAssociationsLineSymbol.color,placement:"end",style:"arrow"}));for(const i of this._internalGraphicsLayerConnectivity.graphics)i.symbol=t}),n(()=>[this.showArrowsStructuralAttachment],()=>{const t=this.structuralAttachmentAssociationsLineSymbol.clone();t.marker=null,this.showArrowsStructuralAttachment&&(t.marker=new y({color:this.structuralAttachmentAssociationsLineSymbol.color,placement:"end",style:"arrow"}));for(const i of this._internalGraphicsLayerStructuralAttachment.graphics)i.symbol=t}),n(()=>{const{cap:t,color:i,style:s,width:o,marker:e}=this.connectivityAssociationsLineSymbol;return[t,i,s,o,e]},()=>{const t=this.connectivityAssociationsLineSymbol.clone();for(const i of this._internalGraphicsLayerConnectivity.graphics)i.symbol=t;this.showArrowsConnectivity=!1,t.marker=null,this.connectivityAssociationsLineSymbol.marker&&(this.showArrowsConnectivity=!0,t.marker=new y({color:this.connectivityAssociationsLineSymbol.color,placement:"end",style:"arrow"}))}),n(()=>{const{cap:t,color:i,style:s,width:o,marker:e}=this.structuralAttachmentAssociationsLineSymbol;return[t,i,s,o,e]},()=>{const t=this.structuralAttachmentAssociationsLineSymbol.clone();for(const i of this._internalGraphicsLayerStructuralAttachment.graphics)i.symbol=t;this.showArrowsStructuralAttachment=!1,t.marker=null,this.structuralAttachmentAssociationsLineSymbol.marker&&(this.showArrowsStructuralAttachment=!0,t.marker=new y({color:this.structuralAttachmentAssociationsLineSymbol.color,placement:"end",style:"arrow"}))}),p(t)])})}destroy(){this._updatingHandles.destroy(),this.view=null,this._removeInternalGraphicsLayers()}set includeConnectivityAssociations(t){this._set("includeConnectivityAssociations",t),this._internalGraphicsLayerConnectivity.visible=t}set includeStructuralAttachmentAssociations(t){this._set("includeStructuralAttachmentAssociations",t),this._internalGraphicsLayerStructuralAttachment.visible=t}get state(){return this.loadErrors.length?"disabled":this._updatingHandles.updating?"executing":""!==this.executionError?"warning":this._initialValidationsFinished?"ready":"loading"}get utilityNetwork(){return this.utilityNetwork}set utilityNetwork(t){this._get("utilityNetwork")!==t&&this._set("utilityNetwork",t)}get view(){return this.view}set view(t){this._get("view")!==t&&this._set("view",t)}removeAssociations(){this._internalGraphicsLayerConnectivity.removeAll(),this._internalGraphicsLayerStructuralAttachment.removeAll()}async showAssociations(){const{messages:{info:{maxAllowableAssociationsExceeded:t,noAssociationsFound:s,noAssociationTypeSpecified:o}},utilityNetwork:r}=this;this._set("executionError","");const n={extent:this.view?.extent,gdbVersion:this.utilityNetwork?.gdbVersion,maxGeometryCount:this.maxAllowableAssociations,moment:this.utilityNetwork?.historicMoment,outSpatialReference:this.view?.spatialReference.clone(),returnConnectivityAssociations:this.includeConnectivityAssociations,returnAttachmentAssociations:this.includeStructuralAttachmentAssociations};this._updatingHandles.addPromise(r?.synthesizeAssociationGeometries(n).then(o=>{let e=[],r=[];return o?.maxGeometryCountExceeded?(this.removeAssociations(),void this._set("executionError",t)):0===o?.associations.length?(this.removeAssociations(),void this._set("executionError",s)):void(o&&(e=o?.associations.filter(({associationType:t})=>"connectivity"===t).map(t=>(this.connectivityAssociationsLineSymbol.marker=null,this.showArrowsConnectivity&&(this.connectivityAssociationsLineSymbol.marker=new y({color:this.connectivityAssociationsLineSymbol.color,placement:"end",style:"arrow"})),new i({geometry:t.geometry.clone(),symbol:this.connectivityAssociationsLineSymbol}))),r=o.associations.filter(({associationType:t})=>"attachment"===t).map(t=>(this.structuralAttachmentAssociationsLineSymbol.marker=null,this.showArrowsStructuralAttachment&&(this.structuralAttachmentAssociationsLineSymbol.marker=new y({color:this.structuralAttachmentAssociationsLineSymbol.color,placement:"end",style:"arrow"})),new i({geometry:t.geometry.clone(),symbol:this.structuralAttachmentAssociationsLineSymbol}))),this._internalGraphicsLayerConnectivity.removeAll(),e.length>0&&this._internalGraphicsLayerConnectivity.addMany(e),this._internalGraphicsLayerStructuralAttachment.removeAll(),r.length>0&&this._internalGraphicsLayerStructuralAttachment.addMany(r)))},t=>{let i="Error: "+t;if(t instanceof e&&t.details?.raw)if(t.details.raw.extendedCode===w.noAssociationTypeSpecified)i=o;else i=t.details.message;this._set("executionError",i)}))}_createInternalGraphicsLayer(t){return new h({listMode:"hide",internal:!0,title:t})}_removeInternalGraphicsLayers(){this._internalGraphicsLayerConnectivity&&this._internalGraphicsLayerStructuralAttachment&&this.view?.map&&(this.view.map.remove(this._internalGraphicsLayerConnectivity),this.view.map.remove(this._internalGraphicsLayerStructuralAttachment))}};t([a()],d.prototype,"_initialValidationsFinished",void 0),t([a()],d.prototype,"autoRefreshAssociations",void 0),t([a({type:m,nonNullable:!0})],d.prototype,"connectivityAssociationsLineSymbol",void 0),t([a({readOnly:!0})],d.prototype,"executionError",void 0),t([a({type:Boolean,value:!0})],d.prototype,"includeConnectivityAssociations",null),t([a({type:Boolean,value:!0})],d.prototype,"includeStructuralAttachmentAssociations",null),t([a()],d.prototype,"loadErrors",void 0),t([a()],d.prototype,"maxAllowableAssociations",void 0),t([a()],d.prototype,"messages",void 0),t([a()],d.prototype,"showAssociationsEnabled",void 0),t([a()],d.prototype,"showArrowsConnectivity",void 0),t([a()],d.prototype,"showArrowsStructuralAttachment",void 0),t([a({readOnly:!0})],d.prototype,"state",null),t([a({type:m,nonNullable:!0})],d.prototype,"structuralAttachmentAssociationsLineSymbol",void 0),t([a()],d.prototype,"utilityNetwork",null),t([a()],d.prototype,"view",null),d=t([c("esri.widgets.UtilityNetworkAssociations.UtilityNetworkAssociationsViewModel")],d);const v=d;export{v as default};
|
|
5
|
+
import{__decorate as t}from"tslib";import i from"../../Graphic.js";import"../../intl.js";import s from"../../core/Accessor.js";import o from"../../core/Collection.js";import e from"../../core/Error.js";import r from"../../core/Logger.js";import{watch as n}from"../../core/reactiveUtils.js";import{property as a}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as c}from"../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as l}from"../../core/support/UpdatingHandles.js";import h from"../../layers/GraphicsLayer.js";import y from"../../symbols/LineSymbolMarker.js";import m from"../../symbols/SimpleLineSymbol.js";import{addUniqueLayer as u}from"../../views/draw/support/layerUtils.js";import{onLocaleChange as p}from"../../intl/locale.js";import{fetchMessageBundle as A}from"../../intl/messages.js";const w={noAssociationTypeSpecified:-2147208504};let d=class extends s{constructor(t){super(t),this._internalGraphicsLayerConnectivity=this._createInternalGraphicsLayer("Connectivity Associations (Internal)"),this._internalGraphicsLayerStructuralAttachment=this._createInternalGraphicsLayer("Structural Attachment Associations (Internal)"),this._initialValidationsFinished=!1,this._updatingHandles=new l,this.autoRefreshAssociations=!1,this.connectivityAssociationsLineSymbol=new m({style:"short-dash",width:2,color:[190,159,159,1]}),this.executionError="",this.loadErrors=new o,this.maxAllowableAssociations=250,this.showAssociationsEnabled=!1,this.showArrowsConnectivity=!1,this.showArrowsStructuralAttachment=!1,this.structuralAttachmentAssociationsLineSymbol=new m({style:"short-dash",width:2,color:[159,190,159,1]})}initialize(){const t=async()=>{this.messages||(this.messages=await A("esri/widgets/UtilityNetworkAssociations/t9n/UtilityNetworkAssociations"))};t().then(()=>{this.view||(this.view=null),this.utilityNetwork||(this.utilityNetwork=null),this.addHandles([n(()=>[this.view,this.utilityNetwork],async()=>{const{loadErrors:t,messages:{info:{noUtilityNetwork:i,noView:s}}}=this;this._initialValidationsFinished=!1,t.removeAll();let o=!1,n=!1;this.removeAssociations(),"2d"===this.view?.type?(u(this.view,this._internalGraphicsLayerConnectivity),u(this.view,this._internalGraphicsLayerStructuralAttachment),o=!0):(this.loadErrors.push(s),r.getLogger(this).error(new e("utilityNetworkAssociations:missing-property",s))),"utility"===this.utilityNetwork?.type?n=!0:(this.loadErrors.push(i),r.getLogger(this).error(new e("utilityNetworkAssociations:missing-property",i))),o&&n&&this.showAssociationsEnabled&&await this.showAssociations(),this._internalGraphicsLayerConnectivity.visible=this.includeConnectivityAssociations,this._internalGraphicsLayerStructuralAttachment.visible=this.includeStructuralAttachmentAssociations,this._initialValidationsFinished=!0},{initial:!0}),n(()=>[this.view?.stationary,this.showAssociationsEnabled,this.maxAllowableAssociations],async()=>{this.view?.stationary&&this.showAssociationsEnabled&&(this.includeConnectivityAssociations||this.includeStructuralAttachmentAssociations)&&await this.showAssociations()}),n(()=>[this.showArrowsConnectivity],()=>{const t=this.connectivityAssociationsLineSymbol.clone();t.marker=null,this.showArrowsConnectivity&&(t.marker=new y({color:this.connectivityAssociationsLineSymbol.color,placement:"end",style:"arrow"}));for(const i of this._internalGraphicsLayerConnectivity.graphics)i.symbol=t}),n(()=>[this.showArrowsStructuralAttachment],()=>{const t=this.structuralAttachmentAssociationsLineSymbol.clone();t.marker=null,this.showArrowsStructuralAttachment&&(t.marker=new y({color:this.structuralAttachmentAssociationsLineSymbol.color,placement:"end",style:"arrow"}));for(const i of this._internalGraphicsLayerStructuralAttachment.graphics)i.symbol=t}),n(()=>{const{cap:t,color:i,style:s,width:o,marker:e}=this.connectivityAssociationsLineSymbol;return[t,i,s,o,e]},()=>{const t=this.connectivityAssociationsLineSymbol.clone();for(const i of this._internalGraphicsLayerConnectivity.graphics)i.symbol=t;this.showArrowsConnectivity=!1,t.marker=null,this.connectivityAssociationsLineSymbol.marker&&(this.showArrowsConnectivity=!0,t.marker=new y({color:this.connectivityAssociationsLineSymbol.color,placement:"end",style:"arrow"}))}),n(()=>{const{cap:t,color:i,style:s,width:o,marker:e}=this.structuralAttachmentAssociationsLineSymbol;return[t,i,s,o,e]},()=>{const t=this.structuralAttachmentAssociationsLineSymbol.clone();for(const i of this._internalGraphicsLayerStructuralAttachment.graphics)i.symbol=t;this.showArrowsStructuralAttachment=!1,t.marker=null,this.structuralAttachmentAssociationsLineSymbol.marker&&(this.showArrowsStructuralAttachment=!0,t.marker=new y({color:this.structuralAttachmentAssociationsLineSymbol.color,placement:"end",style:"arrow"}))}),p(t)])})}destroy(){this._updatingHandles.destroy(),this.view=null,this._removeInternalGraphicsLayers()}set includeConnectivityAssociations(t){this._set("includeConnectivityAssociations",t),this._internalGraphicsLayerConnectivity.visible=t}set includeStructuralAttachmentAssociations(t){this._set("includeStructuralAttachmentAssociations",t),this._internalGraphicsLayerStructuralAttachment.visible=t}get state(){return this.loadErrors.length?"disabled":this._updatingHandles.updating?"executing":""!==this.executionError?"warning":this._initialValidationsFinished?"ready":"loading"}get utilityNetwork(){return this._get("utilityNetwork")}set utilityNetwork(t){this._get("utilityNetwork")!==t&&this._set("utilityNetwork",t)}get view(){return this._get("view")}set view(t){this._get("view")!==t&&this._set("view",t)}removeAssociations(){this._internalGraphicsLayerConnectivity.removeAll(),this._internalGraphicsLayerStructuralAttachment.removeAll()}async showAssociations(){const{messages:{info:{maxAllowableAssociationsExceeded:t,noAssociationsFound:s,noAssociationTypeSpecified:o}},utilityNetwork:r}=this;this._set("executionError","");const n={extent:this.view?.extent,gdbVersion:this.utilityNetwork?.gdbVersion,maxGeometryCount:this.maxAllowableAssociations,moment:this.utilityNetwork?.historicMoment,outSpatialReference:this.view?.spatialReference.clone(),returnConnectivityAssociations:this.includeConnectivityAssociations,returnAttachmentAssociations:this.includeStructuralAttachmentAssociations};this._updatingHandles.addPromise(r?.synthesizeAssociationGeometries(n).then(o=>{let e=[],r=[];return o?.maxGeometryCountExceeded?(this.removeAssociations(),void this._set("executionError",t)):0===o?.associations.length?(this.removeAssociations(),void this._set("executionError",s)):void(o&&(e=o?.associations.filter(({associationType:t})=>"connectivity"===t).map(t=>(this.connectivityAssociationsLineSymbol.marker=null,this.showArrowsConnectivity&&(this.connectivityAssociationsLineSymbol.marker=new y({color:this.connectivityAssociationsLineSymbol.color,placement:"end",style:"arrow"})),new i({geometry:t.geometry.clone(),symbol:this.connectivityAssociationsLineSymbol}))),r=o.associations.filter(({associationType:t})=>"attachment"===t).map(t=>(this.structuralAttachmentAssociationsLineSymbol.marker=null,this.showArrowsStructuralAttachment&&(this.structuralAttachmentAssociationsLineSymbol.marker=new y({color:this.structuralAttachmentAssociationsLineSymbol.color,placement:"end",style:"arrow"})),new i({geometry:t.geometry.clone(),symbol:this.structuralAttachmentAssociationsLineSymbol}))),this._internalGraphicsLayerConnectivity.removeAll(),e.length>0&&this._internalGraphicsLayerConnectivity.addMany(e),this._internalGraphicsLayerStructuralAttachment.removeAll(),r.length>0&&this._internalGraphicsLayerStructuralAttachment.addMany(r)))},t=>{let i="Error: "+t;if(t instanceof e&&t.details?.raw)if(t.details.raw.extendedCode===w.noAssociationTypeSpecified)i=o;else i=t.details.message;this._set("executionError",i)}))}_createInternalGraphicsLayer(t){return new h({listMode:"hide",internal:!0,title:t})}_removeInternalGraphicsLayers(){this._internalGraphicsLayerConnectivity&&this._internalGraphicsLayerStructuralAttachment&&this.view?.map&&(this.view.map.remove(this._internalGraphicsLayerConnectivity),this.view.map.remove(this._internalGraphicsLayerStructuralAttachment))}};t([a()],d.prototype,"_initialValidationsFinished",void 0),t([a()],d.prototype,"autoRefreshAssociations",void 0),t([a({type:m,nonNullable:!0})],d.prototype,"connectivityAssociationsLineSymbol",void 0),t([a({readOnly:!0})],d.prototype,"executionError",void 0),t([a({type:Boolean,value:!0})],d.prototype,"includeConnectivityAssociations",null),t([a({type:Boolean,value:!0})],d.prototype,"includeStructuralAttachmentAssociations",null),t([a()],d.prototype,"loadErrors",void 0),t([a()],d.prototype,"maxAllowableAssociations",void 0),t([a()],d.prototype,"messages",void 0),t([a()],d.prototype,"showAssociationsEnabled",void 0),t([a()],d.prototype,"showArrowsConnectivity",void 0),t([a()],d.prototype,"showArrowsStructuralAttachment",void 0),t([a({readOnly:!0})],d.prototype,"state",null),t([a({type:m,nonNullable:!0})],d.prototype,"structuralAttachmentAssociationsLineSymbol",void 0),t([a()],d.prototype,"utilityNetwork",null),t([a()],d.prototype,"view",null),d=t([c("esri.widgets.UtilityNetworkAssociations.UtilityNetworkAssociationsViewModel")],d);const v=d;export{v as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as r}from"tslib";import t from"../../core/Accessor.js";import o from"../../core/Error.js";import e from"../../core/Logger.js";import{watch as i}from"../../core/reactiveUtils.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as l}from"../../core/support/UpdatingHandles.js";import n from"../../layers/FeatureLayer.js";import{getOwningPortalUrl as d}from"../../layers/support/layerUtils.js";import c from"../../portal/Portal.js";import{hasUserTypeExtension as u}from"../../portal/support/utils.js";let h=class extends t{constructor(r){super(r),this._updatingHandlesLoad=new l,this._updatingHandlesExecute=new l}initialize(){this.addHandles([i(()=>[this.utilityNetwork,this.view],()=>{this._setUp()},{initial:!0})])}destroy(){this._updatingHandlesLoad.destroy(),this._updatingHandlesExecute.destroy()}get executionError(){return this._executionError}get loadError(){return this._loadError}get state(){return this._updatingHandlesLoad.updating?"loading":this.loadError?"disabled":this._updatingHandlesExecute.updating?"executing":"ready"}get utilityNetwork(){return this.utilityNetwork}set utilityNetwork(r){this._get("utilityNetwork")!==r&&this._set("utilityNetwork",r)}get view(){return this.view}set view(r){this._get("view")!==r&&this._set("view",r)}async executeNamedTraceConfiguration(r){return this._updatingHandlesExecute.addPromise(this._executeNamedTraceConfiguration(r))}async executeTraceConfiguration(r){return this._updatingHandlesExecute.addPromise(this._executeTraceConfiguration(r))}async _executeNamedTraceConfiguration(r){if("disabled"===this.state){const r="trace-analysis-view-model:load-error";throw this._logError(r,this.loadError),new o(r,this.loadError??"")}this._executionError=null;return await this.utilityNetwork.trace(r).catch(r=>{throw this._executionError="trace-error",this._logError("trace-analysis-view-model:execution-error",this.executionError),r})}async _executeTraceConfiguration(r){if("disabled"===this.state){const r="trace-analysis-view-model:load-error";throw this._logError(r,this.loadError),new o(r,this.loadError??"")}this._executionError=null;return await this.utilityNetwork.trace(r).catch(r=>{throw this._executionError="trace-error",this._logError("trace-analysis-view-model:execution-error",this.executionError),r})}_logError(r,t){e.getLogger(this).error(new o(r,t??""))}async _setUp(){const{utilityNetwork:r,view:t}=this;this._updatingHandlesLoad.addPromise((async()=>{this._loadError=null;const e="trace-analysis-view-model:load-error";if(!t)throw this._loadError="no-view",this._logError(e,this.loadError),new o(e,this.loadError??"");if("2d"!==t.type)throw this._loadError="sceneView-not-supported",this._logError(e,this._loadError),new o(e,this.loadError??"");if("utility"!==r?.type)throw this._loadError="no-utility-network",this._logError(e,this.loadError),new o(e,this.loadError??"");r.loaded||await r.load().catch(r=>{throw this._loadError="no-utility-network",this._logError(e,this.loadError),r}),await this._checkUserTypeExtension(r)})())}async _checkUserTypeExtension(r){const t=new n({url:r.networkSystemLayers.dirtyAreasLayerUrl});await t.load();const e=t.version;if(Number(e)<=11.1){const t=await d(r.layerUrl),e=new c({url:t});await e.load();const i=e.user?.username??"";if(!await u(e,i,"utilityNetwork")){const r="trace-analysis-view-model:load-error";throw this._loadError="no-user-type-extension",this._logError(r,this.loadError),new o(r,this.loadError??"")}}}};r([s()],h.prototype,"_executionError",void 0),r([s()],h.prototype,"_loadError",void 0),r([s()],h.prototype,"executionError",null),r([s()],h.prototype,"loadError",null),r([s({readOnly:!0})],h.prototype,"state",null),r([s()],h.prototype,"utilityNetwork",null),r([s()],h.prototype,"view",null),h=r([a("esri.widgets.UtilityNetworkTraceAnalysis.UtilityNetworkTraceAnalysisViewModel")],h);const p=h;export{p as default};
|
|
5
|
+
import{__decorate as r}from"tslib";import t from"../../core/Accessor.js";import o from"../../core/Error.js";import e from"../../core/Logger.js";import{watch as i}from"../../core/reactiveUtils.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/RandomLCG.js";import{subclass as a}from"../../core/accessorSupport/decorators/subclass.js";import{UpdatingHandles as l}from"../../core/support/UpdatingHandles.js";import n from"../../layers/FeatureLayer.js";import{getOwningPortalUrl as d}from"../../layers/support/layerUtils.js";import c from"../../portal/Portal.js";import{hasUserTypeExtension as u}from"../../portal/support/utils.js";let h=class extends t{constructor(r){super(r),this._updatingHandlesLoad=new l,this._updatingHandlesExecute=new l}initialize(){this.addHandles([i(()=>[this.utilityNetwork,this.view],()=>{this._setUp()},{initial:!0})])}destroy(){this._updatingHandlesLoad.destroy(),this._updatingHandlesExecute.destroy()}get executionError(){return this._executionError}get loadError(){return this._loadError}get state(){return this._updatingHandlesLoad.updating?"loading":this.loadError?"disabled":this._updatingHandlesExecute.updating?"executing":"ready"}get utilityNetwork(){return this._get("utilityNetwork")}set utilityNetwork(r){this._get("utilityNetwork")!==r&&this._set("utilityNetwork",r)}get view(){return this._get("view")}set view(r){this._get("view")!==r&&this._set("view",r)}async executeNamedTraceConfiguration(r){return this._updatingHandlesExecute.addPromise(this._executeNamedTraceConfiguration(r))}async executeTraceConfiguration(r){return this._updatingHandlesExecute.addPromise(this._executeTraceConfiguration(r))}async _executeNamedTraceConfiguration(r){if("disabled"===this.state){const r="trace-analysis-view-model:load-error";throw this._logError(r,this.loadError),new o(r,this.loadError??"")}this._executionError=null;return await this.utilityNetwork.trace(r).catch(r=>{throw this._executionError="trace-error",this._logError("trace-analysis-view-model:execution-error",this.executionError),r})}async _executeTraceConfiguration(r){if("disabled"===this.state){const r="trace-analysis-view-model:load-error";throw this._logError(r,this.loadError),new o(r,this.loadError??"")}this._executionError=null;return await this.utilityNetwork.trace(r).catch(r=>{throw this._executionError="trace-error",this._logError("trace-analysis-view-model:execution-error",this.executionError),r})}_logError(r,t){e.getLogger(this).error(new o(r,t??""))}async _setUp(){const{utilityNetwork:r,view:t}=this;this._updatingHandlesLoad.addPromise((async()=>{this._loadError=null;const e="trace-analysis-view-model:load-error";if(!t)throw this._loadError="no-view",this._logError(e,this.loadError),new o(e,this.loadError??"");if("2d"!==t.type)throw this._loadError="sceneView-not-supported",this._logError(e,this._loadError),new o(e,this.loadError??"");if("utility"!==r?.type)throw this._loadError="no-utility-network",this._logError(e,this.loadError),new o(e,this.loadError??"");r.loaded||await r.load().catch(r=>{throw this._loadError="no-utility-network",this._logError(e,this.loadError),r}),await this._checkUserTypeExtension(r)})())}async _checkUserTypeExtension(r){const t=new n({url:r.networkSystemLayers.dirtyAreasLayerUrl});await t.load();const e=t.version;if(Number(e)<=11.1){const t=await d(r.layerUrl),e=new c({url:t});await e.load();const i=e.user?.username??"";if(!await u(e,i,"utilityNetwork")){const r="trace-analysis-view-model:load-error";throw this._loadError="no-user-type-extension",this._logError(r,this.loadError),new o(r,this.loadError??"")}}}};r([s()],h.prototype,"_executionError",void 0),r([s()],h.prototype,"_loadError",void 0),r([s()],h.prototype,"executionError",null),r([s()],h.prototype,"loadError",null),r([s({readOnly:!0})],h.prototype,"state",null),r([s()],h.prototype,"utilityNetwork",null),r([s()],h.prototype,"view",null),h=r([a("esri.widgets.UtilityNetworkTraceAnalysis.UtilityNetworkTraceAnalysisViewModel")],h);const p=h;export{p as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import i from"../Slider/SliderViewModel.js";import{formatDateLabel as o,formatNumberLabel as n,getStopChanges as a}from"./support/utils.js";let l=class extends i{constructor(t){super(t),this._initialStopValues=[],this._max=null,this._min=null,this.hasTimeData=!1,this.inputFormatFunction=(t,s)=>"max"===s?this.getUnzoomedMax().toString():"min"===s?this.getUnzoomedMin().toString():t.toString(),this.inputParseFunction=null,this.labelFormatFunction=t=>{if(this.hasTimeData)return o(t);const{max:s,min:e,precision:i}=this,a=s-e>10?2:i;return n(parseFloat(t.toFixed(a)))},this.thumbsConstrained=!1,this.zoomingEnabled=!0}set breaks(t){this._set("breaks",t),this.notifyChange("max"),this.notifyChange("min")}set stops(t){if(t?.length){const{max:s,min:e}=this,i=this.getValuesFromStops(t),o={};null!=e&&i.some(t=>t<e)&&(o.min=Math.min(...i)),null!=s&&i.some(t=>t>s)&&(o.max=Math.max(...i)),this.set({...o}),this._initialStopValues=i}else this._initialStopValues=null;this._set("stops",t||null),this.notifyChange("values")}get labels(){const{values:t}=this,s=t&&t.length?t.map((t,s)=>this.getLabelForValue(t,"value",s)):[],e=this.getUnzoomedMax(),i=this.getUnzoomedMin();return{max:this.getLabelForValue(e,"max"),min:this.getLabelForValue(i,"min"),values:s}}get max(){const{breaks:t}=this;return t?.length?t[t.length-1].max:this.max}set max(t){const{zoomOptions:s}=this;if(null!=s?.max){const e=this.values;let i=s.max;if(t<i&&(i=t,s.max=t),e&&e.length)for(let s=0;s<e.length;s++)t<e[s]&&this.setValue(s,t);this._storeZoomMax(i,t)}else this.updateBreakMax(t),this.setMax(t);this.notifyChange("labels")}get min(){const{breaks:t}=this;return t?.length?t[0].min:this.min}set min(t){const{zoomOptions:s}=this;if(null!=s?.min){const e=this.values;let i=s.min;if(t>i&&(i=t,s.min=t),e&&e.length)for(let s=0;s<e.length;s++)t>e[s]&&this.setValue(s,t);this._storeZoomMin(i,t)}else this.updateBreakMin(t),this.setMin(t);this.notifyChange("labels")}get state(){const{max:t,min:s,values:e}=this;return null!=t&&null!=s&&e.length>0?"ready":"disabled"}get values(){const{breaks:t,stops:s}=this;if(!t&&!s)return[];if(t?.length){const s=t.map(t=>t.max);return s.pop(),s}if(s?.length<2)return[];const e=this.getValuesFromStops();return[e[0],e[e.length-1]]}set zoomOptions(t){const{zoomingEnabled:s,zoomOptions:e}=this;if(s){if(e){const s=null!=this._max?this._max:this.max,e=null!=this._min?this._min:this.min;if(t){const{max:i,min:o}=t,n=null!=i,a=null!=o,l=a?t.min:e,r=a?e:null,h=n?t.max:s,m=n?s:null;this._storeZoomMin(l,r),this._storeZoomMax(h,m)}else this.setMax(s),this.setMin(e),this._min=null,this._max=null}else if(t){const{max:s,min:e}=t;null!=e&&this._storeZoomMin(t.min,this.min),null!=s&&this._storeZoomMax(t.max,this.max)}this._set("zoomOptions",t),this.notifyChange("max"),this.notifyChange("min")}}getStopIndexFromValueIndex(t){const{stops:s}=this,e=this.values[t];if(0===t){return e<=this.values[1]?0:s.length-1}if(1===t){return this.values[0]>=e?0:s.length-1}return null}getStopChanges(t,s){const e=this.stops,i=this.getStopIndexFromValueIndex(t),o=this.getValuesFromStops();o[i]=s;const[n,a]=[o[0],o[o.length-1]].sort((t,s)=>t>s?1:-1),l=a-n,r=e.length-1;return o.map((t,s)=>({index:s,value:this.toPrecision(n+s*l/r)}))}setValue(t,s){const{max:e,min:i,values:o}=this,n=o[t];if(isNaN(s)||n===s||s>e||s<i)return;o[t]=this.toPrecision(s),this._set("values",[...o]);const l=o.slice().sort((t,s)=>t>s?1:-1),r=l[0],h=l[l.length-1],m=a(r,h,this._initialStopValues??[]);this.updateStops(m),this.updateBreaks(),this.notifyChange("labels")}getValuesFromStops(t){const s=t||this.stops;return s?.map(t=>t.hasOwnProperty("ratio")?t.ratio:t.value)}updateBreaks(){const{breaks:t,values:s}=this;t?.length&&s.slice().sort((t,s)=>t>s?1:-1).forEach((s,e)=>{t[e].max=s,null!=t[e+1]&&(t[e+1].min=s)})}updateBreakMax(t){const{breaks:s,max:e,min:i}=this;!isNaN(t)&&e!==t&&null!=i&&t>i&&s?.length&&(s[s.length-1].max=t)}updateBreakMin(t){const{breaks:s,max:e,min:i}=this;!isNaN(t)&&i!==t&&null!=e&&t<e&&s?.length&&(s[0].min=t)}updateStops(t){const{stops:s}=this,e=this.getValuesFromStops();if(e?.length){for(const s of t)e[s.index]=s.value;s.forEach((t,s)=>{t.hasOwnProperty("ratio")?t.ratio=e[s]:t.value=e[s]})}}getUnzoomedMax(){return this.zoomOptions&&null!=this._max?this._max:this.max}getUnzoomedMin(){return this.zoomOptions&&null!=this._min?this._min:this.min}_storeZoomMax(t,s){this._max=s,this.setMax(t)}_storeZoomMin(t,s){this._min=s,this.setMin(t)}};t([s()],l.prototype,"breaks",null),t([s()],l.prototype,"stops",null),t([s()],l.prototype,"hasTimeData",void 0),t([s()],l.prototype,"inputFormatFunction",void 0),t([s()],l.prototype,"inputParseFunction",void 0),t([s()],l.prototype,"labelFormatFunction",void 0),t([s({readOnly:!0})],l.prototype,"labels",null),t([s()],l.prototype,"max",null),t([s()],l.prototype,"min",null),t([s({readOnly:!0})],l.prototype,"state",null),t([s()],l.prototype,"thumbsConstrained",void 0),t([s({readOnly:!0})],l.prototype,"values",null),t([s()],l.prototype,"zoomingEnabled",void 0),t([s()],l.prototype,"zoomOptions",null),l=t([e("esri.widgets.smartMapping.SmartMappingSliderViewModel")],l);const r=l;export{r as default};
|
|
5
|
+
import{__decorate as t}from"tslib";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as e}from"../../core/accessorSupport/decorators/subclass.js";import i from"../Slider/SliderViewModel.js";import{formatDateLabel as o,formatNumberLabel as n,getStopChanges as a}from"./support/utils.js";let l=class extends i{constructor(t){super(t),this._initialStopValues=[],this._max=null,this._min=null,this.hasTimeData=!1,this.inputFormatFunction=(t,s)=>"max"===s?this.getUnzoomedMax().toString():"min"===s?this.getUnzoomedMin().toString():t.toString(),this.inputParseFunction=null,this.labelFormatFunction=t=>{if(this.hasTimeData)return o(t);const{max:s,min:e,precision:i}=this,a=s-e>10?2:i;return n(parseFloat(t.toFixed(a)))},this.thumbsConstrained=!1,this.zoomingEnabled=!0}set breaks(t){this._set("breaks",t),this.notifyChange("max"),this.notifyChange("min")}set stops(t){if(t?.length){const{max:s,min:e}=this,i=this.getValuesFromStops(t),o={};null!=e&&i.some(t=>t<e)&&(o.min=Math.min(...i)),null!=s&&i.some(t=>t>s)&&(o.max=Math.max(...i)),this.set({...o}),this._initialStopValues=i}else this._initialStopValues=null;this._set("stops",t||null),this.notifyChange("values")}get labels(){const{values:t}=this,s=t&&t.length?t.map((t,s)=>this.getLabelForValue(t,"value",s)):[],e=this.getUnzoomedMax(),i=this.getUnzoomedMin();return{max:this.getLabelForValue(e,"max"),min:this.getLabelForValue(i,"min"),values:s}}get max(){const{breaks:t}=this;return t?.length?t[t.length-1].max:this._get("max")}set max(t){const{zoomOptions:s}=this;if(null!=s?.max){const e=this.values;let i=s.max;if(t<i&&(i=t,s.max=t),e&&e.length)for(let s=0;s<e.length;s++)t<e[s]&&this.setValue(s,t);this._storeZoomMax(i,t)}else this.updateBreakMax(t),this.setMax(t);this.notifyChange("labels")}get min(){const{breaks:t}=this;return t?.length?t[0].min:this._get("min")}set min(t){const{zoomOptions:s}=this;if(null!=s?.min){const e=this.values;let i=s.min;if(t>i&&(i=t,s.min=t),e&&e.length)for(let s=0;s<e.length;s++)t>e[s]&&this.setValue(s,t);this._storeZoomMin(i,t)}else this.updateBreakMin(t),this.setMin(t);this.notifyChange("labels")}get state(){const{max:t,min:s,values:e}=this;return null!=t&&null!=s&&e.length>0?"ready":"disabled"}get values(){const{breaks:t,stops:s}=this;if(!t&&!s)return[];if(t?.length){const s=t.map(t=>t.max);return s.pop(),s}if(s?.length<2)return[];const e=this.getValuesFromStops();return[e[0],e[e.length-1]]}set zoomOptions(t){const{zoomingEnabled:s,zoomOptions:e}=this;if(s){if(e){const s=null!=this._max?this._max:this.max,e=null!=this._min?this._min:this.min;if(t){const{max:i,min:o}=t,n=null!=i,a=null!=o,l=a?t.min:e,r=a?e:null,h=n?t.max:s,m=n?s:null;this._storeZoomMin(l,r),this._storeZoomMax(h,m)}else this.setMax(s),this.setMin(e),this._min=null,this._max=null}else if(t){const{max:s,min:e}=t;null!=e&&this._storeZoomMin(t.min,this.min),null!=s&&this._storeZoomMax(t.max,this.max)}this._set("zoomOptions",t),this.notifyChange("max"),this.notifyChange("min")}}getStopIndexFromValueIndex(t){const{stops:s}=this,e=this.values[t];if(0===t){return e<=this.values[1]?0:s.length-1}if(1===t){return this.values[0]>=e?0:s.length-1}return null}getStopChanges(t,s){const e=this.stops,i=this.getStopIndexFromValueIndex(t),o=this.getValuesFromStops();o[i]=s;const[n,a]=[o[0],o[o.length-1]].sort((t,s)=>t>s?1:-1),l=a-n,r=e.length-1;return o.map((t,s)=>({index:s,value:this.toPrecision(n+s*l/r)}))}setValue(t,s){const{max:e,min:i,values:o}=this,n=o[t];if(isNaN(s)||n===s||s>e||s<i)return;o[t]=this.toPrecision(s),this._set("values",[...o]);const l=o.slice().sort((t,s)=>t>s?1:-1),r=l[0],h=l[l.length-1],m=a(r,h,this._initialStopValues??[]);this.updateStops(m),this.updateBreaks(),this.notifyChange("labels")}getValuesFromStops(t){const s=t||this.stops;return s?.map(t=>t.hasOwnProperty("ratio")?t.ratio:t.value)}updateBreaks(){const{breaks:t,values:s}=this;t?.length&&s.slice().sort((t,s)=>t>s?1:-1).forEach((s,e)=>{t[e].max=s,null!=t[e+1]&&(t[e+1].min=s)})}updateBreakMax(t){const{breaks:s,max:e,min:i}=this;!isNaN(t)&&e!==t&&null!=i&&t>i&&s?.length&&(s[s.length-1].max=t)}updateBreakMin(t){const{breaks:s,max:e,min:i}=this;!isNaN(t)&&i!==t&&null!=e&&t<e&&s?.length&&(s[0].min=t)}updateStops(t){const{stops:s}=this,e=this.getValuesFromStops();if(e?.length){for(const s of t)e[s.index]=s.value;s.forEach((t,s)=>{t.hasOwnProperty("ratio")?t.ratio=e[s]:t.value=e[s]})}}getUnzoomedMax(){return this.zoomOptions&&null!=this._max?this._max:this.max}getUnzoomedMin(){return this.zoomOptions&&null!=this._min?this._min:this.min}_storeZoomMax(t,s){this._max=s,this.setMax(t)}_storeZoomMin(t,s){this._min=s,this.setMin(t)}};t([s()],l.prototype,"breaks",null),t([s()],l.prototype,"stops",null),t([s()],l.prototype,"hasTimeData",void 0),t([s()],l.prototype,"inputFormatFunction",void 0),t([s()],l.prototype,"inputParseFunction",void 0),t([s()],l.prototype,"labelFormatFunction",void 0),t([s({readOnly:!0})],l.prototype,"labels",null),t([s()],l.prototype,"max",null),t([s()],l.prototype,"min",null),t([s({readOnly:!0})],l.prototype,"state",null),t([s()],l.prototype,"thumbsConstrained",void 0),t([s({readOnly:!0})],l.prototype,"values",null),t([s()],l.prototype,"zoomingEnabled",void 0),t([s()],l.prototype,"zoomOptions",null),l=t([e("esri.widgets.smartMapping.SmartMappingSliderViewModel")],l);const r=l;export{r as default};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import e from"../../../Color.js";import{EventedAccessor as i}from"../../../core/Evented.js";import r from"../../../core/Logger.js";import{rad2deg as s}from"../../../core/mathUtils.js";import{destroyMaybe as o}from"../../../core/maybe.js";import{when as n,watch as a}from"../../../core/reactiveUtils.js";import{convertUnit as l}from"../../../core/unitUtils.js";import{property as c}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/RandomLCG.js";import{subclass as h}from"../../../core/accessorSupport/decorators/subclass.js";import p from"../../../geometry/Point.js";import{isLoadedOrLoadFor as d,project as m}from"../../../geometry/projectionUtils.js";import{getResolutionForScale as g}from"../../../geometry/support/scaleUtils.js";import{MeasuredGrid as u}from"../../../grids/MeasuredGrid.js";import{makeDehydratedPoint as v}from"../../../layers/graphics/dehydratedPoint.js";import{defaultUnitPropertyMetadata as y}from"../../../properties/defaultUnit.js";import _ from"../../../symbols/SimpleLineSymbol.js";import w from"../../../symbols/SimpleMarkerSymbol.js";import{minimumPixelsPerStrideForDisplayWhenScalingOff as f}from"../../../views/2d/grid/constants.js";import{getScaleFactor as S,shouldUsePlanar as b,measureMetersPerUnitAtReferencePoint as P}from"../../../views/2d/grid/gridUtils.js";import{DrawGraphicTool2D as j}from"../../../views/2d/interactive/editingTools/draw/DrawGraphicTool2D.js";import"../../../views/2d/interactive/editingTools/ControlPointsTransformTool.js";import"../../../views/2d/interactive/editingTools/TransformTool.js";import"../../../views/2d/interactive/editingTools/MediaTransformToolsWrapper.js";import{ViewEventPriorities as T}from"../../../views/input/InputManager.js";import{KeyBindings as C,sketchKeys as x}from"../../../views/interactive/keybindings.js";import G from"../../../views/interactive/snapping/SnappingOptions.js";import{gridPlacementGraphicSymbol as O}from"../../../views/interactive/snapping/snappingUtils.js";import R from"../../../views/overlay/CrosshairOverlayItem.js";import M from"../../../views/overlay/TextOverlayItem.js";import{loadAutomaticAreaMeasurementUtils as L}from"../../../views/support/automaticAreaMeasurementUtils.js";import{loadAutomaticLengthMeasurementUtils as I}from"../../../views/support/automaticLengthMeasurementUtils.js";import{degreeSymbol as k}from"../../CoordinateConversion/support/formatUtils.js";import{applyColorToGrid as U,gridRotationToDegrees as E}from"./gridUtils.js";const V=Symbol("grid-interactivity");let A=class extends i{constructor(t){super(t),this._drawGraphicTool=null,this._keybindings=null,this._crosshairLabel=null,this._crosshairItem=null,this.snappingManager=null,this.snappingOptions=null,this.view=null,this.placementDisabled=!1,this._mostRecentlyShownGrid=null,this._sketchedVertexCount=0}initialize(){this.addHandles([n(()=>!this.displayEnabled,()=>{this.interactivePlacementState=null}),a(()=>this.view?.viewpoint,()=>{this._renderOverlays()}),a(()=>this.snappingOptions?.gridEnabled,t=>{null!=t&&this.trySetDisplayEnabled(t)}),a(()=>this.view?.grid,(t,e)=>{this._mostRecentlyShownGrid=!t&&e?e:null})])}destroy(){this._resetGridPlacementState(),this._crosshairItem&&(this.view?.overlay?.removeItem(this._crosshairItem),this._crosshairItem=o(this._crosshairItem)),this._crosshairLabel&&(this.view?.overlay?.removeItem(this._crosshairLabel),this._crosshairLabel=o(this._crosshairLabel))}get displayEnabled(){return!!this.view?.grid}get dynamicScaling(){return this.grid?.dynamicScaling??!1}set dynamicScaling(t){this.grid&&(this.grid.dynamicScaling=t)}get grid(){return this.view?.grid??this._mostRecentlyShownGrid}set gridColor(t){if(t?.equals(this.grid?.majorLineColor))return;if(!t)return;const[e,i,r,s]=t.toArray();U(this.grid,[e,i,r,s/255])}get gridColor(){return this.grid?.majorLineColor}get gridControlsEnabled(){return this.displayEnabled&&!this.interactivePlacementState}set interactivePlacementState(t){this._set("interactivePlacementState",t),this._resetGridPlacementState(),t&&this._startGridManipulation(t)}get majorLineInterval(){return this.grid?.majorLineInterval??10}set majorLineInterval(t){this.grid&&(this.grid.majorLineInterval=t<1?1:t>15?15:t)}get rotateWithMap(){return this.grid?.rotateWithMap??!1}set rotateWithMap(t){this.grid&&(this.grid.rotateWithMap=t)}get rotation(){return this.grid?.rotation??-180}set rotation(t){this.grid&&(this.grid.rotation=t)}get snappingEnabled(){return(this.grid&&this.snappingOptions?.gridEnabled)??!1}set snappingEnabled(t){const{snappingOptions:e}=this;e&&(e.gridEnabled=t)}get spacing(){return this.grid?.spacing??1}set spacing(t){this.grid&&t>0&&(this.grid.spacing=t)}get unit(){return this.grid?.units}set unit(t){this.grid&&(this.grid.units=t)}get gridOutOfScale(){return!this.dynamicScaling&&null!=this._pixelsPerStride&&this._pixelsPerStride<f}get effectiveSpacingAfterDynamicScaling(){return this.majorLineInterval<1||!this.dynamicScaling||!this.view||null==this._pixelsPerStride||!this.grid?.spacing?null:this.grid.spacing*S(this.majorLineInterval,this._pixelsPerStride,this.dynamicScaling)}get numericSpacingInputShouldBeVisible(){return!!this.view?.spatialReference&&b(this.view.spatialReference)}get _metersPerSRUnit(){if(!(this.view&&this.displayEnabled&&this.grid&&d(this.grid.center.spatialReference,this.view.spatialReference)))return null;const t=m(this.grid.center,this.view.spatialReference);return P(t)}get _pixelsPerStride(){if(!this.view?.scale||!this.displayEnabled||!this.grid||null==this._metersPerSRUnit)return null;const t=this.grid,{scale:e,spatialReference:i}=this.view;return l(t.spacing,t.units,"meters")/(this._metersPerSRUnit*g(e,i))}get _isPlacing(){if(!this._drawGraphicTool)return!1;const t=this.interactivePlacementState;return"place"===t||"interactive"===t&&0===this._sketchedVertexCount}get _isRotating(){if(!this._drawGraphicTool)return!1;const t=this.interactivePlacementState;return"rotate"===t||"interactive"===t&&1===this._sketchedVertexCount}get _isScaling(){if(!this._drawGraphicTool)return!1;return"interactive"===this.interactivePlacementState&&1===this._sketchedVertexCount}togglePlacementState(t){this.interactivePlacementState=this.interactivePlacementState===t?null:t}trySetDisplayEnabled(t){const{view:e}=this;if(e?.ready)if(!e.grid&&t)if(this._mostRecentlyShownGrid)e.grid=this._mostRecentlyShownGrid;else{const t="imperial"===this.defaultUnit?"feet":"meters";e.grid=new u({units:t,center:e.center??new p,rotateWithMap:!0}),U(this.grid,[115,115,115])}else t||(e.grid=null);else r.getLogger(this).warn("Attempting to enable grid display while view is not ready")}async startPlacement(t){const{view:e,snappingManager:i}=this;if(!e)return;this._set("interactivePlacementState",t),this._sketchedVertexCount=0;const r=new j({view:e,graphicProperties:{attributes:{[O]:O}},sketchOptions:{tooltips:{enabled:!0,visibleElements:{direction:!1,rotation:!1,totalLength:!1,elevation:!1,distance:!1,area:!1}}},geometryType:"polyline",mode:"click",snapToScene:!1,snappingManager:i,forceUniformSize:!0,centered:!1,cursor:"interactive"===this.interactivePlacementState||"place"===this.interactivePlacementState?"none":null,regularVerticesSymbol:void 0,activeVertexSymbol:W,activeLineSymbol:D,graphicSymbol:D,automaticAreaMeasurementUtils:await L(),automaticLengthMeasurementUtils:await I()});if(this._drawGraphicTool=r,e.addAndActivateTool(r),this._renderOverlays(),!this._keybindings){const t=new C;t.add(x.complete,()=>this._onDrawComplete()),t.add(x.vertexAdd,()=>this._drawGraphicTool?.drawOperation.commitStagedVertex()),this._keybindings=t}this.addHandles([r.on("cursor-update",t=>this._onCursorUpdate(t)),r.on("complete",()=>this._onDrawComplete()),r.on("vertex-add",e=>this._onVertexAdd(e,t)),this._keybindings.register(e,T.WIDGET)],V)}async _startGridManipulation(t){const{view:e}=this;if(!e)return void(this.interactivePlacementState=null);const i=new CustomEvent("before-placement",{cancelable:!0});this.emit("before-placement",i),i.defaultPrevented||await this.startPlacement(t)}_onCursorUpdate(t){try{if(this._isPlacing){const e=t.vertices[0].coordinates;return void this._handlePlace(e)}if(this._drawGraphicTool.cursor=null,this._isRotating&&this._handleRotate(t.vertices[0].coordinates),this._isScaling){const t=this._drawGraphicTool?.drawOperation.cursorVertex;this._handleScale(t)}}finally{this._renderOverlays()}}_onDrawComplete(){this._drawGraphicTool.cursor=null,this.interactivePlacementState=null}_onVertexAdd(t,e){const i=t.vertices[0].coordinates;this._isPlacing&&this._handlePlace(i),this._isRotating&&this._sketchedVertexCount>0&&this._handleRotate(i),this._isScaling&&this._sketchedVertexCount>0&&this._handleScale(v(i[0],i[1],void 0,this.view.spatialReference)),this._sketchedVertexCount++,this._drawGraphicTool.cursor=null,2!==this._sketchedVertexCount&&"interactive"===e||(this.interactivePlacementState=null),this._renderOverlays()}_handlePlace(t){const{grid:e,view:i}=this;e&&i&&(e.center=new p({x:t[0],y:t[1],spatialReference:i.spatialReference}))}_handleRotate(t){const{grid:e,view:i}=this;if(!e||!i)return;this._drawGraphicTool?.sketchOptions.tooltips.set("enabled",!1);const{x:r,y:o}=e.center,[n,a]=t,l=i.toScreen(e.center,{pickClosestTarget:!0}),c=l&&i.toMap(l),h=i.toScreen(v(n,a,void 0,i.spatialReference),{pickClosestTarget:!0}),p=h&&i.toMap(h),d=c?c.x:r,m=c?c.y:o,g=d-(p?p.x:n),u=m-(p?p.y:a);if(0===g&&0===u)return;const y=Math.atan2(u,g),_=s(y),w=e.rotateWithMap,f=i.viewpoint.rotation??0,S=w?_:_-f;e.rotation=Math.fround(S)%360}_handleScale(t){const{view:e,grid:i,_drawGraphicTool:r,interactivePlacementState:s,_metersPerSRUnit:o}=this;if(!(t&&e&&i&&r&&o))return;r.sketchOptions.tooltips.enabled=!1;const n="interactive"===s?i.center:r.drawOperation.firstVertex;if(!n||!t)return;const a=e?.toScreen(n),c=a&&e.toMap(a),h=e?.toScreen(t),p=c??n,d=(h&&e.toMap(h))??t,m=Math.sqrt((p.x-d.x)**2+(p.y-d.y)**2),g=l(m*o,"meters",i.units);this.spacing=g}_renderOverlays(){this._renderCrosshairOverlay(),this._renderTextOverlay()}_renderTextOverlay(){const{grid:t,view:e,_drawGraphicTool:i}=this,r=this._getCrosshairLabel();if(!(t&&e?.overlay&&i&&r))return;const s=e.toScreen(t.center,{pickClosestTarget:!0});s&&(r.position=[s.x+12,s.y+12]),this._isRotating?(r.text=`${E(t.rotation)}${k}`,r.visible=!0):r.visible=!1}_renderCrosshairOverlay(){const{grid:t,view:e,_drawGraphicTool:i}=this;if(!t||!e?.overlay||!i)return;const r=this._getCrosshair();if(!r)return;const s=e.toScreen(t.center);s&&(r.x=s.x,r.y=s.y,r.rotation=t.rotateWithMap?e.viewpoint.rotation-t.rotation:-t.rotation,r.visible=!!i)}_getCrosshairLabel(){if(this._crosshairLabel)return this._crosshairLabel;const{grid:t,view:i,_drawGraphicTool:r}=this;if(!t||!i?.overlay||!r)return null;const s=new M({anchor:"top-left",fontSize:10,textColor:new e([21,21,21]),backgroundColor:new e([248,248,248]),padding:8,borderRadius:20});return i.overlay.addItem(s),this._crosshairLabel=s,s}_getCrosshair(){const{_crosshairItem:t,view:e}=this;return e?.overlay?t&&e.overlay.items.includes(t)?t:(this._crosshairItem=new R({color:e.effectiveTheme.accentColor,thickness:4,length:36,visible:!0}),e.overlay?.addItem(this._crosshairItem),this._crosshairItem):null}_resetGridPlacementState(){this.removeHandles(V),this._crosshairItem&&(this._crosshairItem.visible=!1),this._crosshairLabel&&(this._crosshairLabel.visible=!1),this._drawGraphicTool&&(this.view?.activeTool===this._drawGraphicTool&&(this.view.activeTool=null),this.view?.tools.remove(this._drawGraphicTool)),this._drawGraphicTool=o(this._drawGraphicTool)}};t([c(y)],A.prototype,"defaultUnit",void 0),t([c({readOnly:!0})],A.prototype,"displayEnabled",null),t([c()],A.prototype,"dynamicScaling",null),t([c()],A.prototype,"grid",null),t([c()],A.prototype,"gridColor",null),t([c({readOnly:!0})],A.prototype,"gridControlsEnabled",null),t([c()],A.prototype,"interactivePlacementState",null),t([c()],A.prototype,"majorLineInterval",null),t([c()],A.prototype,"rotateWithMap",null),t([c()],A.prototype,"rotation",null),t([c()],A.prototype,"snappingEnabled",null),t([c()],A.prototype,"snappingManager",void 0),t([c({type:G})],A.prototype,"snappingOptions",void 0),t([c()],A.prototype,"spacing",null),t([c()],A.prototype,"unit",null),t([c()],A.prototype,"view",void 0),t([c({readOnly:!0})],A.prototype,"gridOutOfScale",null),t([c({readOnly:!0})],A.prototype,"effectiveSpacingAfterDynamicScaling",null),t([c({readOnly:!0})],A.prototype,"numericSpacingInputShouldBeVisible",null),t([c()],A.prototype,"placementDisabled",void 0),t([c()],A.prototype,"_metersPerSRUnit",null),t([c()],A.prototype,"_pixelsPerStride",null),t([c()],A.prototype,"_isPlacing",null),t([c()],A.prototype,"_isRotating",null),t([c()],A.prototype,"_isScaling",null),t([c()],A.prototype,"_mostRecentlyShownGrid",void 0),t([c()],A.prototype,"_sketchedVertexCount",void 0),A=t([h("esri.widgets.support.GridControls.GridControlsViewModel")],A);const D=new _({width:0}),W=new w({color:e.fromArray([0,0,0,0]),outline:new _({color:e.fromArray([0,0,0,0])})});export{A as default};
|
|
5
|
+
import{__decorate as t}from"tslib";import e from"../../../Color.js";import{EventedAccessor as i}from"../../../core/Evented.js";import r from"../../../core/Logger.js";import{rad2deg as s}from"../../../core/mathUtils.js";import{destroyMaybe as o}from"../../../core/maybe.js";import{when as n,watch as a}from"../../../core/reactiveUtils.js";import{convertUnit as l}from"../../../core/unitUtils.js";import{property as c}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/RandomLCG.js";import{subclass as h}from"../../../core/accessorSupport/decorators/subclass.js";import p from"../../../geometry/Point.js";import{isLoadedOrLoadFor as d,project as m}from"../../../geometry/projectionUtils.js";import{getResolutionForScale as g}from"../../../geometry/support/scaleUtils.js";import{MeasuredGrid as u}from"../../../grids/MeasuredGrid.js";import{makeDehydratedPoint as v}from"../../../layers/graphics/dehydratedPoint.js";import{defaultUnitPropertyMetadata as y}from"../../../properties/defaultUnit.js";import _ from"../../../symbols/SimpleLineSymbol.js";import w from"../../../symbols/SimpleMarkerSymbol.js";import{minimumPixelsPerStrideForDisplayWhenScalingOff as f}from"../../../views/2d/grid/constants.js";import{getScaleFactor as S,shouldUsePlanar as b,measureMetersPerUnitAtReferencePoint as P}from"../../../views/2d/grid/gridUtils.js";import{DrawGraphicTool2D as j}from"../../../views/2d/interactive/editingTools/draw/DrawGraphicTool2D.js";import"../../../views/2d/interactive/editingTools/ControlPointsTransformTool.js";import"../../../views/2d/interactive/editingTools/TransformTool.js";import{ViewEventPriorities as C}from"../../../views/input/InputManager.js";import{KeyBindings as T,sketchKeys as x}from"../../../views/interactive/keybindings.js";import G from"../../../views/interactive/snapping/SnappingOptions.js";import{gridPlacementGraphicSymbol as O}from"../../../views/interactive/snapping/snappingUtils.js";import R from"../../../views/overlay/CrosshairOverlayItem.js";import L from"../../../views/overlay/TextOverlayItem.js";import{loadAutomaticAreaMeasurementUtils as M}from"../../../views/support/automaticAreaMeasurementUtils.js";import{loadAutomaticLengthMeasurementUtils as I}from"../../../views/support/automaticLengthMeasurementUtils.js";import{degreeSymbol as k}from"../../CoordinateConversion/support/formatUtils.js";import{applyColorToGrid as U,gridRotationToDegrees as E}from"./gridUtils.js";const V=Symbol("grid-interactivity");let A=class extends i{constructor(t){super(t),this._drawGraphicTool=null,this._keybindings=null,this._crosshairLabel=null,this._crosshairItem=null,this.snappingManager=null,this.snappingOptions=null,this.view=null,this.placementDisabled=!1,this._mostRecentlyShownGrid=null,this._sketchedVertexCount=0}initialize(){this.addHandles([n(()=>!this.displayEnabled,()=>{this.interactivePlacementState=null}),a(()=>this.view?.viewpoint,()=>{this._renderOverlays()}),a(()=>this.snappingOptions?.gridEnabled,t=>{null!=t&&this.trySetDisplayEnabled(t)}),a(()=>this.view?.grid,(t,e)=>{this._mostRecentlyShownGrid=!t&&e?e:null})])}destroy(){this._resetGridPlacementState(),this._crosshairItem&&(this.view?.overlay?.removeItem(this._crosshairItem),this._crosshairItem=o(this._crosshairItem)),this._crosshairLabel&&(this.view?.overlay?.removeItem(this._crosshairLabel),this._crosshairLabel=o(this._crosshairLabel))}get displayEnabled(){return!!this.view?.grid}get dynamicScaling(){return this.grid?.dynamicScaling??!1}set dynamicScaling(t){this.grid&&(this.grid.dynamicScaling=t)}get grid(){return this.view?.grid??this._mostRecentlyShownGrid}set gridColor(t){if(t?.equals(this.grid?.majorLineColor))return;if(!t)return;const[e,i,r,s]=t.toArray();U(this.grid,[e,i,r,s/255])}get gridColor(){return this.grid?.majorLineColor}get gridControlsEnabled(){return this.displayEnabled&&!this.interactivePlacementState}set interactivePlacementState(t){this._set("interactivePlacementState",t),this._resetGridPlacementState(),t&&this._startGridManipulation(t)}get majorLineInterval(){return this.grid?.majorLineInterval??10}set majorLineInterval(t){this.grid&&(this.grid.majorLineInterval=t<1?1:t>15?15:t)}get rotateWithMap(){return this.grid?.rotateWithMap??!1}set rotateWithMap(t){this.grid&&(this.grid.rotateWithMap=t)}get rotation(){return this.grid?.rotation??-180}set rotation(t){this.grid&&(this.grid.rotation=t)}get snappingEnabled(){return(this.grid&&this.snappingOptions?.gridEnabled)??!1}set snappingEnabled(t){const{snappingOptions:e}=this;e&&(e.gridEnabled=t)}get spacing(){return this.grid?.spacing??1}set spacing(t){this.grid&&t>0&&(this.grid.spacing=t)}get unit(){return this.grid?.units}set unit(t){this.grid&&(this.grid.units=t)}get gridOutOfScale(){return!this.dynamicScaling&&null!=this._pixelsPerStride&&this._pixelsPerStride<f}get effectiveSpacingAfterDynamicScaling(){return this.majorLineInterval<1||!this.dynamicScaling||!this.view||null==this._pixelsPerStride||!this.grid?.spacing?null:this.grid.spacing*S(this.majorLineInterval,this._pixelsPerStride,this.dynamicScaling)}get numericSpacingInputShouldBeVisible(){return!!this.view?.spatialReference&&b(this.view.spatialReference)}get _metersPerSRUnit(){if(!(this.view&&this.displayEnabled&&this.grid&&d(this.grid.center.spatialReference,this.view.spatialReference)))return null;const t=m(this.grid.center,this.view.spatialReference);return P(t)}get _pixelsPerStride(){if(!this.view?.scale||!this.displayEnabled||!this.grid||null==this._metersPerSRUnit)return null;const t=this.grid,{scale:e,spatialReference:i}=this.view;return l(t.spacing,t.units,"meters")/(this._metersPerSRUnit*g(e,i))}get _isPlacing(){if(!this._drawGraphicTool)return!1;const t=this.interactivePlacementState;return"place"===t||"interactive"===t&&0===this._sketchedVertexCount}get _isRotating(){if(!this._drawGraphicTool)return!1;const t=this.interactivePlacementState;return"rotate"===t||"interactive"===t&&1===this._sketchedVertexCount}get _isScaling(){if(!this._drawGraphicTool)return!1;return"interactive"===this.interactivePlacementState&&1===this._sketchedVertexCount}togglePlacementState(t){this.interactivePlacementState=this.interactivePlacementState===t?null:t}trySetDisplayEnabled(t){const{view:e}=this;if(e?.ready)if(!e.grid&&t)if(this._mostRecentlyShownGrid)e.grid=this._mostRecentlyShownGrid;else{const t="imperial"===this.defaultUnit?"feet":"meters";e.grid=new u({units:t,center:e.center??new p,rotateWithMap:!0}),U(this.grid,[115,115,115])}else t||(e.grid=null);else r.getLogger(this).warn("Attempting to enable grid display while view is not ready")}async startPlacement(t){const{view:e,snappingManager:i}=this;if(!e)return;this._set("interactivePlacementState",t),this._sketchedVertexCount=0;const r=new j({view:e,graphicProperties:{attributes:{[O]:O}},sketchOptions:{tooltips:{enabled:!0,visibleElements:{direction:!1,rotation:!1,totalLength:!1,elevation:!1,distance:!1,area:!1}}},geometryType:"polyline",mode:"click",snapToScene:!1,snappingManager:i,forceUniformSize:!0,centered:!1,cursor:"interactive"===this.interactivePlacementState||"place"===this.interactivePlacementState?"none":null,regularVerticesSymbol:void 0,activeVertexSymbol:W,activeLineSymbol:D,graphicSymbol:D,automaticAreaMeasurementUtils:await M(),automaticLengthMeasurementUtils:await I()});if(this._drawGraphicTool=r,e.addAndActivateTool(r),this._renderOverlays(),!this._keybindings){const t=new T;t.add(x.complete,()=>this._onDrawComplete()),t.add(x.vertexAdd,()=>this._drawGraphicTool?.drawOperation.commitStagedVertex()),this._keybindings=t}this.addHandles([r.on("cursor-update",t=>this._onCursorUpdate(t)),r.on("complete",()=>this._onDrawComplete()),r.on("vertex-add",e=>this._onVertexAdd(e,t)),this._keybindings.register(e,C.WIDGET)],V)}async _startGridManipulation(t){const{view:e}=this;if(!e)return void(this.interactivePlacementState=null);const i=new CustomEvent("before-placement",{cancelable:!0});this.emit("before-placement",i),i.defaultPrevented||await this.startPlacement(t)}_onCursorUpdate(t){try{if(this._isPlacing){const e=t.vertices[0].coordinates;return void this._handlePlace(e)}if(this._drawGraphicTool.cursor=null,this._isRotating&&this._handleRotate(t.vertices[0].coordinates),this._isScaling){const t=this._drawGraphicTool?.drawOperation.cursorVertex;this._handleScale(t)}}finally{this._renderOverlays()}}_onDrawComplete(){this._drawGraphicTool.cursor=null,this.interactivePlacementState=null}_onVertexAdd(t,e){const i=t.vertices[0].coordinates;this._isPlacing&&this._handlePlace(i),this._isRotating&&this._sketchedVertexCount>0&&this._handleRotate(i),this._isScaling&&this._sketchedVertexCount>0&&this._handleScale(v(i[0],i[1],void 0,this.view.spatialReference)),this._sketchedVertexCount++,this._drawGraphicTool.cursor=null,2!==this._sketchedVertexCount&&"interactive"===e||(this.interactivePlacementState=null),this._renderOverlays()}_handlePlace(t){const{grid:e,view:i}=this;e&&i&&(e.center=new p({x:t[0],y:t[1],spatialReference:i.spatialReference}))}_handleRotate(t){const{grid:e,view:i}=this;if(!e||!i)return;this._drawGraphicTool?.sketchOptions.tooltips.set("enabled",!1);const{x:r,y:o}=e.center,[n,a]=t,l=i.toScreen(e.center,{pickClosestTarget:!0}),c=l&&i.toMap(l),h=i.toScreen(v(n,a,void 0,i.spatialReference),{pickClosestTarget:!0}),p=h&&i.toMap(h),d=c?c.x:r,m=c?c.y:o,g=d-(p?p.x:n),u=m-(p?p.y:a);if(0===g&&0===u)return;const y=Math.atan2(u,g),_=s(y),w=e.rotateWithMap,f=i.viewpoint.rotation??0,S=w?_:_-f;e.rotation=Math.fround(S)%360}_handleScale(t){const{view:e,grid:i,_drawGraphicTool:r,interactivePlacementState:s,_metersPerSRUnit:o}=this;if(!(t&&e&&i&&r&&o))return;r.sketchOptions.tooltips.enabled=!1;const n="interactive"===s?i.center:r.drawOperation.firstVertex;if(!n||!t)return;const a=e?.toScreen(n),c=a&&e.toMap(a),h=e?.toScreen(t),p=c??n,d=(h&&e.toMap(h))??t,m=Math.sqrt((p.x-d.x)**2+(p.y-d.y)**2),g=l(m*o,"meters",i.units);this.spacing=g}_renderOverlays(){this._renderCrosshairOverlay(),this._renderTextOverlay()}_renderTextOverlay(){const{grid:t,view:e,_drawGraphicTool:i}=this,r=this._getCrosshairLabel();if(!(t&&e?.overlay&&i&&r))return;const s=e.toScreen(t.center,{pickClosestTarget:!0});s&&(r.position=[s.x+12,s.y+12]),this._isRotating?(r.text=`${E(t.rotation)}${k}`,r.visible=!0):r.visible=!1}_renderCrosshairOverlay(){const{grid:t,view:e,_drawGraphicTool:i}=this;if(!t||!e?.overlay||!i)return;const r=this._getCrosshair();if(!r)return;const s=e.toScreen(t.center);s&&(r.x=s.x,r.y=s.y,r.rotation=t.rotateWithMap?e.viewpoint.rotation-t.rotation:-t.rotation,r.visible=!!i)}_getCrosshairLabel(){if(this._crosshairLabel)return this._crosshairLabel;const{grid:t,view:i,_drawGraphicTool:r}=this;if(!t||!i?.overlay||!r)return null;const s=new L({anchor:"top-left",fontSize:10,textColor:new e([21,21,21]),backgroundColor:new e([248,248,248]),padding:8,borderRadius:20});return i.overlay.addItem(s),this._crosshairLabel=s,s}_getCrosshair(){const{_crosshairItem:t,view:e}=this;return e?.overlay?t&&e.overlay.items.includes(t)?t:(this._crosshairItem=new R({color:e.effectiveTheme.accentColor,thickness:4,length:36,visible:!0}),e.overlay?.addItem(this._crosshairItem),this._crosshairItem):null}_resetGridPlacementState(){this.removeHandles(V),this._crosshairItem&&(this._crosshairItem.visible=!1),this._crosshairLabel&&(this._crosshairLabel.visible=!1),this._drawGraphicTool&&(this.view?.activeTool===this._drawGraphicTool&&(this.view.activeTool=null),this.view?.tools.remove(this._drawGraphicTool)),this._drawGraphicTool=o(this._drawGraphicTool)}};t([c(y)],A.prototype,"defaultUnit",void 0),t([c({readOnly:!0})],A.prototype,"displayEnabled",null),t([c()],A.prototype,"dynamicScaling",null),t([c()],A.prototype,"grid",null),t([c()],A.prototype,"gridColor",null),t([c({readOnly:!0})],A.prototype,"gridControlsEnabled",null),t([c()],A.prototype,"interactivePlacementState",null),t([c()],A.prototype,"majorLineInterval",null),t([c()],A.prototype,"rotateWithMap",null),t([c()],A.prototype,"rotation",null),t([c()],A.prototype,"snappingEnabled",null),t([c()],A.prototype,"snappingManager",void 0),t([c({type:G})],A.prototype,"snappingOptions",void 0),t([c()],A.prototype,"spacing",null),t([c()],A.prototype,"unit",null),t([c()],A.prototype,"view",void 0),t([c({readOnly:!0})],A.prototype,"gridOutOfScale",null),t([c({readOnly:!0})],A.prototype,"effectiveSpacingAfterDynamicScaling",null),t([c({readOnly:!0})],A.prototype,"numericSpacingInputShouldBeVisible",null),t([c()],A.prototype,"placementDisabled",void 0),t([c()],A.prototype,"_metersPerSRUnit",null),t([c()],A.prototype,"_pixelsPerStride",null),t([c()],A.prototype,"_isPlacing",null),t([c()],A.prototype,"_isRotating",null),t([c()],A.prototype,"_isScaling",null),t([c()],A.prototype,"_mostRecentlyShownGrid",void 0),t([c()],A.prototype,"_sketchedVertexCount",void 0),A=t([h("esri.widgets.support.GridControls.GridControlsViewModel")],A);const D=new _({width:0}),W=new w({color:e.fromArray([0,0,0,0]),outline:new _({color:e.fromArray([0,0,0,0])})});export{A as default};
|
package/arcade/credentials.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
-
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
|
-
*/
|
|
5
|
-
class e{constructor(){this._username="",this._password="",this._token=null}static fromUserName(s,t){const n=new e;return n._username=s,n._password=t,n._token=null,n}static fromArcadeDictionary(s){const t=new e;return s.hasField("username")&&(t._username=s.field("username")),s.hasField("password")&&(t._password=s.field("password")),s.hasField("token")&&(t._token=s.field("token")),t}static fromToken(s){const t=new e;return t._token=s,t}get username(){return this._username}get password(){return this._password}async getToken(){return null===this._token?"No Token Provided":this._token}}export{e as default};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
-
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
|
-
*/
|
|
5
|
-
const t=new RegExp("^[a-z0-9]{8}-[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{12}$","i");function e(t){let e="";for(let i=0;i<t;i++)e+=(65536*(1+Math.random())|0).toString(16).slice(1);return e}class i{constructor(t){if(this._value="",!t)throw new TypeError("Invalid argument; `value` has no value.");this._value=i.EMPTY,t&&t instanceof i?this._value=t.toString():t&&"[object String]"===Object.prototype.toString.call(t)&&i.isGuid(t)&&(this._value=t)}equals(t){return i.isGuid(t)&&this._value===t}isEmpty(){return this._value===i.EMPTY}toString(){return this._value}toJSON(){return this._value}static{this.EMPTY="00000000-0000-0000-0000-000000000000"}static isGuid(e){return e&&(e instanceof i||t.test(e.toString()))}static create(){return new i([e(2),e(1),e(1),e(1),e(3)].join("-"))}static raw(){return[e(2),e(1),e(1),e(1),e(3)].join("-")}}export{i as default};
|
package/arcade/request.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
-
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
|
-
*/
|
|
5
|
-
import e from"../request.js";async function o(o,n,t,r,s=null){if(null!==s){if(o=o+="?token="+await s.getToken(),"get"===r.toLowerCase())return e(o,{responseType:"json",query:n});if(n)for(const e in n)o.includes("?")?o+="&":o+="?",o+=encodeURIComponent(e)+"="+encodeURIComponent(n[e]);return e(o,{method:"post",query:t,responseType:"json"})}if("get"===r.toLowerCase())return e(o,{responseType:"json",query:n});if(n)for(const e in n)o.includes("?")?o+="&":o+="?",o+=encodeURIComponent(e)+"="+encodeURIComponent(n[e]);return await e(o,{method:"post",responseType:"json",query:t})}export{o as serviceRequest};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
-
See https://js.arcgis.com/4.34/esri/copyright.txt for details.
|
|
4
|
-
*/
|
|
5
|
-
class e{constructor(e=null){this.url="//route.arcgis.com/arcgis/rest/services/World/ServiceAreas/NAServer/ServiceArea_World/solveServiceArea",this.credentials=null,this.impedanceAttributeNames=[{serviceValue:"TravelTime",entryName:"traveltime"},{serviceValue:"TruckTravelTime",entryName:"trucktraveltime"},{serviceValue:"WalkTime",entryName:"walktime"},{serviceValue:"Miles",entryName:"miles"},{serviceValue:"Kilometers",entryName:"kilometers"}],this.defaultImpledanceAttributeName="TravelTime",this.credentials=e}}export{e as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4307],{2272:(t,e,n)=>{n.d(e,{Dl:()=>u,gf:()=>c,jV:()=>a,lF:()=>h});var i=n(92602),s=n(70333),r=n(4718),o=n(84952),l=n(926);function a(t,e){return e?{...e,query:{...t??{},...e.query}}:{query:t}}function u(t){return"string"==typeof t?(0,o.An)(t):(0,r.o8)(t)}function h(t,e,n){const i={};for(const s in t){if("declaredClass"===s)continue;const r=t[s];if(null!=r&&"function"!=typeof r)if(Array.isArray(r))i[s]=r.map(t=>h(t));else if("object"==typeof r)if(r.toJSON){const t=r.toJSON(n?.[s]);i[s]=e?t:JSON.stringify(t)}else i[s]=e?r:JSON.stringify(r);else i[s]=r}return i}async function c(t,e,r){const o=function(t,e){return t?e&&(0,l.Qc)(t)?e:(0,l.CG)(t)??s.id?.findCredential(t)?.token:null}(t,e);if(o)return o;!s.id&&i.A.request.useIdentity&&await Promise.all([n.e(7330),n.e(4813),n.e(3747)]).then(n.bind(n,73747));const a=await s.id.getCredential(t,r);return a?.token}},6518:(t,e,n)=>{n.d(e,{F:()=>l});var i=n(44208),s=n(75503),r=n(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class l{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s.wq(9,(0,i.A)("esri-csp-restrictions")?t=>({minX:t[0],minY:t[1],maxX:t[2],maxY:t[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const t=new Array(this._idByBounds.size);let e=0;this._idByBounds.forEach((n,i)=>{t[e++]=i}),this._indexInvalid=!1,this._index.clear(),this._index.load(t)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter(t=>this._idByBounds.has(t))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const t=(0,r.Ie)();for(const e of this._boundsById.values())e&&(t[0]=Math.min(e[0],t[0]),t[1]=Math.min(e[1],t[1]),t[2]=Math.max(e[2],t[2]),t[3]=Math.max(e[3],t[3]));return t}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(t){const e=this._boundsById.get(t);this._boundsById.delete(t),e&&(this._idByBounds.delete(e),this._indexInvalid||this._index.remove(e))}forEachInBounds(t,e){this._loadIndex(),function(t,e,n){(function(t){o.minX=t[0],o.minY=t[1],o.maxX=t[2],o.maxY=t[3]})(e),t.search(o,n)}(this._index,t,t=>e(this._idByBounds.get(t)))}get(t){return this._boundsById.get(t)}has(t){return this._boundsById.has(t)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(t,e){if(!this._indexInvalid){const e=this._boundsById.get(t);e&&(this._index.remove(e),this._idByBounds.delete(e))}this._boundsById.set(t,e),e&&(this._idByBounds.set(e,t),this._indexInvalid||(this._boundsToLoad.push(e),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},9762:(t,e,n)=>{n.r(e),n.d(e,{projectBuffer:()=>s});var i=n(37539);function s(t,e,n,s,r,o,l=Math.floor(t.length/3)){const a=(0,i.jd)(e,r);if(null==a)return!1;if(a===i.pO){if(t===s&&n===o)return!0;const e=n+3*l;for(let i=n,r=o;i<e;i++,r++)s[r]=t[i];return!0}const u=n+3*l;for(let e=n,i=o;e<u;e+=3,i+=3)a(t,e,s,i);return!0}},36708:(t,e,n)=>{n.d(e,{C_:()=>d,OH:()=>_,Vh:()=>p,on:()=>c,pc:()=>g,wB:()=>a,z7:()=>u});var i=n(37955),s=n(36563),r=n(97768),o=n(74887),l=n(14012);function a(t,e,n={}){return h(t,e,n,f)}function u(t,e,n={}){return h(t,e,n,m)}function h(t,e,n={},i){let s=null;const o=n.once?(t,n)=>{i(t)&&((0,r.xt)(s),e(t,n))}:(t,n)=>{i(t)&&e(t,n)};if(s=(0,l.Cn)(t,o,n.sync,n.equals),n.initial){const e=t();o(e,e)}return s}function c(t,e,n,o={}){let l=null,u=null,h=null;function c(){l&&u&&(u.remove(),o.onListenerRemove?.(l),l=null,u=null)}function d(t){o.once&&o.once&&(0,r.xt)(h),n(t)}const f=a(t,(t,n)=>{c(),(0,i.wb)(t)&&(l=t,u=(0,i.on)(t,e,d),o.onListenerAdd?.(t))},{sync:o.sync,initial:!0});return h=(0,s.hA)(()=>{f.remove(),c()}),h}function d(t,e){return function(t,e,n){if((0,o.G4)(n))return Promise.reject((0,o.NK)());const i=t();if(e?.(i))return Promise.resolve(i);let l=null;function a(){l=(0,r.xt)(l)}return new Promise((i,r)=>{l=(0,s.vE)([(0,o.u7)(n,()=>{a(),r((0,o.NK)())}),h(t,t=>{a(),i(t)},{sync:!1,once:!0},e??f)])})}(t,m,e)}function f(t){return!0}function m(t){return!!t}n(80559);const _={sync:!0},p={initial:!0},g={sync:!0,initial:!0}},37539:(t,e,n)=>{n.d(e,{pO:()=>_,jd:()=>d,Tp:()=>f,w5:()=>c});var i=n(34727),s=n(83047),r=n(73941),o=n(79258);Math.PI;const l=o.$O.radius,a=o.$O.eccentricitySquared,u={a1:l*a,a2:l*a*l*a,a3:l*a*a/2,a4:l*a*l*a*2.5,a5:l*a+l*a*a/2,a6:1-a};o.$O.radius,o.$O.flattening,o.Sw.radius,o.Sw.flattening,o.sH.radius,o.sH.flattening,o.sH.radius;var h=n(21325);const c={2:{5:_,7:null,9:null,10:_,1:v,6:null,8:null,0:null,3:g,11:y,2:_,4:S},5:{5:_,7:null,9:null,10:_,1:v,6:null,8:null,0:null,3:g,11:y,2:_,4:S},7:{5:null,7:_,9:null,10:_,1:null,6:I,8:null,0:null,3:null,11:null,2:null,4:null},9:{5:null,7:null,9:_,10:_,1:null,6:null,8:w,0:null,3:null,11:null,2:null,4:null},3:{5:p,7:null,9:null,10:p,1:function(t,e,n,i){const s=t[e]/Y,r=F-2*Math.atan(Math.exp(-t[e+1]/Y)),o=Y+t[e+2],l=Math.cos(r)*o;n[i]=Math.cos(s)*l,n[i+1]=Math.sin(s)*l,n[i+2]=Math.sin(r)*o},6:null,8:null,0:null,3:_,11:function(t,e,n,i){p(t,e,n,i),y(n,i,n,i)},2:p,4:function(t,e,n,i){p(t,e,n,i),S(n,i,n,i)}},4:{5:k,7:null,9:null,10:k,1:function(t,e,n,i){k(t,e,n,i),v(n,i,n,i)},6:null,8:null,0:null,3:function(t,e,n,i){k(t,e,n,i),g(n,i,n,i)},11:function(t,e,n,i){k(t,e,n,i),y(n,i,n,i)},2:k,4:_},1:{5:R,7:null,9:null,10:R,1:_,6:null,8:null,0:null,3:function(t,e,n,i){R(t,e,n,i),g(n,i,n,i)},11:function(t,e,n,i){R(t,e,n,i),y(n,i,n,i)},2:R,4:function(t,e,n,i){R(t,e,n,i),S(n,i,n,i)}},6:{5:null,7:B,9:null,10:B,1:null,6:_,8:null,0:null,3:null,11:null,2:null,4:null},8:{5:null,7:null,9:z,10:z,1:null,6:null,8:_,0:null,3:null,11:null,2:null,4:null},0:{5:null,7:null,9:null,10:null,1:null,6:null,8:null,0:_,3:null,11:null,2:null,4:null},10:{5:_,7:_,9:_,10:_,1:v,6:I,8:w,0:null,3:g,11:y,2:_,4:S},11:{5:x,7:null,9:null,10:x,1:function(t,e,n,i){x(t,e,n,i),v(n,i,n,i)},6:null,8:null,0:null,3:function(t,e,n,i){x(t,e,n,i),g(n,i,n,i)},11:_,2:x,4:function(t,e,n,i){x(t,e,n,i),S(n,i,n,i)}}};function d(t,e){return f(t,e)?.projector}function f(t,e){if(null==t||null==e)return null;if(j.source.spatialReference===t&&j.dest.spatialReference===e)return j;const n=m(t,j.source),i=m(e,j.dest);return 0===n&&0===i?(0,h.aI)(t,e)?j.projector=_:j.projector=null:j.projector=c[n][i],j}function m(t,e){return t?e.spatialReference===t?e.spatialReferenceId:(e.spatialReference=t,"metersPerUnit"in e&&(e.metersPerUnit=(0,s.GA)(t,1)),(0,r.jA)(t)?e.spatialReferenceId=1:(0,h.oT)(t)?e.spatialReferenceId=2:(0,h.K8)(t)?e.spatialReferenceId=3:(0,h.r1)(t)?e.spatialReferenceId=11:t.wkt===r.Ro.wkt?e.spatialReferenceId=4:4490===t.wkid?e.spatialReferenceId=5:t.wkt===r.FY.wkt?e.spatialReferenceId=6:t.wkt===r.LJ.wkt?e.spatialReferenceId=8:(0,h.q8)(t)?e.spatialReferenceId=7:(0,h.KQ)(t)?e.spatialReferenceId=9:e.spatialReferenceId=0):0}function _(t,e,n,i){t!==n&&(n[i++]=t[e++],n[i++]=t[e++],n[i]=t[e])}function p(t,e,n,i){n[i]=T*(t[e]/Y),n[i+1]=T*(F-2*Math.atan(Math.exp(-t[e+1]/Y))),n[i+2]=t[e+2]}function g(t,e,n,s){!function(t,e,n,s,r){const o=.4999999*Math.PI,l=(0,i.qE)(A*t[e+1],-o,o),a=Math.sin(l);n[s++]=A*t[e]*r.radius,n[s++]=r.halfSemiMajorAxis*Math.log((1+a)/(1-a)),n[s]=t[e+2]}(t,e,n,s,o.$O)}function y(t,e,n,i){n[i]=t[e]*X,n[i+1]=t[e+1]*X,n[i+2]=t[e+2]}function x(t,e,n,i){n[i]=t[e]*E,n[i+1]=t[e+1]*E,n[i+2]=t[e+2]}function M(t,e,n,i,s){const r=s+t[e+2],o=A*t[e+1],l=A*t[e],a=Math.cos(o)*r;n[i]=Math.cos(l)*a,n[i+1]=Math.sin(l)*a,n[i+2]=Math.sin(o)*r}function w(t,e,n,i){M(t,e,n,i,o.Sw.radius)}function I(t,e,n,i){M(t,e,n,i,o.sH.radius)}function v(t,e,n,i){M(t,e,n,i,o.$O.radius)}function b(t,e,n,s,r){const o=t[e],l=t[e+1],a=t[e+2],u=Math.sqrt(o*o+l*l+a*a),h=(0,i.YN)(a/(0===u?1:u)),c=Math.atan2(l,o);n[s++]=T*c,n[s++]=T*h,n[s]=u-r}function z(t,e,n,i){b(t,e,n,i,o.Sw.radius)}function B(t,e,n,i){b(t,e,n,i,o.sH.radius)}function R(t,e,n,i){b(t,e,n,i,o.$O.radius)}function S(t,e,n,i){!function(t,e,n,i,s){const r=A*t[e],o=A*t[e+1],l=t[e+2],a=Math.sin(o),u=Math.cos(o),h=s.radius/Math.sqrt(1-s.eccentricitySquared*a*a);n[i++]=(h+l)*u*Math.cos(r),n[i++]=(h+l)*u*Math.sin(r),n[i++]=(h*(1-s.eccentricitySquared)+l)*a}(t,e,n,i,o.$O)}function k(t,e,n,i){const s=u,r=t[e],l=t[e+1],a=t[e+2];let h,c,d,f,m,_,p,g,y,x,M,w,I,v,b,z,B,R,S,k,j;h=Math.abs(a),c=r*r+l*l,d=Math.sqrt(c),f=c+a*a,m=Math.sqrt(f),k=Math.atan2(l,r),_=a*a/f,p=c/f,v=s.a2/m,b=s.a3-s.a4/m,p>.3?(g=h/m*(1+p*(s.a1+v+_*b)/m),S=Math.asin(g),x=g*g,y=Math.sqrt(1-x)):(y=d/m*(1-_*(s.a5-v-p*b)/m),S=Math.acos(y),x=1-y*y,g=Math.sqrt(x)),M=1-o.$O.eccentricitySquared*x,w=o.$O.radius/Math.sqrt(M),I=s.a6*w,v=d-w*y,b=h-I*g,B=y*v+g*b,z=y*b-g*v,R=z/(I/M+B),S+=R,j=B+z*R/2,a<0&&(S=-S),n[i++]=T*k,n[i++]=T*S,n[i]=j}const j={source:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},dest:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},projector:_},A=(0,i.kU)(1),T=(0,i.KJ)(1),F=.5*Math.PI,Y=o.$O.radius,X=Y*Math.PI/180,E=180/(Y*Math.PI)},37730:(t,e,n)=>{n.d(e,{T:()=>s});var i=n(43334);const s={getObjectId:t=>t.objectId,getAttributes:t=>t.attributes,getAttribute:(t,e)=>t.attributes[e],cloneWithGeometry:(t,e)=>new i.Om(e,t.attributes,null,t.objectId),getGeometry:t=>t.geometry,getCentroid:(t,e)=>t.ensureCentroid(e)}},58376:(t,e,n)=>{n.d(e,{J:()=>m});var i=n(4718),s=n(74887),r=n(65864),o=n(17136),l=n(21325),a=n(31464),u=n(95422),h=n(8384),c=n(58727),d=n(62798),f=n(62660);async function m(t,e,n){const m=(0,s.Mq)(n),{point:_,distance:p,returnEdge:g,vertexMode:y}=e;if(!g&&"none"===y)return{candidates:[]};let x=(0,i.o8)(e.query);x=await t.schedule(()=>(0,c.T2)(x,t.definitionExpression,t.spatialReference),m),x=await t.reschedule(()=>(0,d.B4)(x,{availableFields:t.availableFields,fieldsIndex:t.fieldsIndex,geometryType:t.geometryType,spatialReference:t.spatialReference}),m);const M=!(0,l.aI)(_.spatialReference,t.spatialReference);M&&await(0,a.Nk)(_.spatialReference,t.spatialReference);const w="number"==typeof p?p:p.x,I="number"==typeof p?p:p.y,v={xmin:_.x-w,xmax:_.x+w,ymin:_.y-I,ymax:_.y+I,spatialReference:_.spatialReference},b=M?(0,a.Cv)(v,t.spatialReference):v;if(!b)return{candidates:[]};const z=(await(0,o.el)((0,r.rS)(_),null,{signal:m}))[0],B=(await(0,o.el)((0,r.rS)(b),null,{signal:m}))[0];if(null==z||null==B)return{candidates:[]};const R=new h.G(await t.reschedule(()=>t.searchFeatures((0,u.ux)(B.toJSON())),m),x,t);await t.reschedule(()=>t.executeObjectIdsQuery(R),m),await t.reschedule(()=>t.executeTimeQuery(R),m),await t.reschedule(()=>t.executeAttributesQuery(R),m),await t.reschedule(()=>async function(t,e,n){const{query:i}=e,{spatialRel:s}=i;if(!e?.items?.length||!i.geometry||!s)return;const r=await(0,f.xt)(s,i.geometry,t.geometryType,t.hasZ,t.hasM),o=await t.runSpatialFilter(e.items,t=>r(t.geometry),n);e.items=o}(t,R,m),m);const S=z.toJSON(),k=M?(0,a.Cv)(S,t.spatialReference):S,j=M?Math.max(b.xmax-b.xmin,b.ymax-b.ymin)/2:p;return R.createSnappingResponse({...e,point:k,distance:j},x.returnZ,_.spatialReference)}},62815:(t,e,n)=>{n.d(e,{N:()=>o});var i=n(83047),s=n(73941),r=n(21325);function o(t,e,n){if(null==e||null==n||n.vcsWkid||(0,r.aI)(e,n)||(0,s.xP)(e)||(0,s.xP)(n))return null;const o=(0,i.G9)(e)/(0,i.G9)(n);if(1===o)return null;switch(t){case"point":case"esriGeometryPoint":return t=>function(t,e){null!=t?.z&&(t.z*=e)}(t,o);case"polyline":case"esriGeometryPolyline":return t=>function(t,e){if(t)for(const n of t.paths)for(const t of n)t.length>2&&(t[2]*=e)}(t,o);case"polygon":case"esriGeometryPolygon":return t=>function(t,e){if(t)for(const n of t.rings)for(const t of n)t.length>2&&(t[2]*=e)}(t,o);case"multipoint":case"esriGeometryMultipoint":return t=>function(t,e){if(t)for(const n of t.points)n.length>2&&(n[2]*=e)}(t,o);case"extent":case"esriGeometryEnvelope":return t=>function(t,e){t&&null!=t.zmin&&null!=t.zmax&&(t.zmin*=e,t.zmax*=e)}(t,o);default:return null}}},66344:(t,e,n)=>{n.d(e,{q:()=>l});const i=!!(0,n(44208).A)("esri-tests-disable-gpu-memory-measurements");Symbol.iterator;class s{get size(){return this._size}constructor(t=10485760){this._maxSize=t,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._users=new Map,this._sizeLimits=new Map}destroy(){this.clearAll(),this._sizeLimits.clear(),this._users.clear(),this._db=null}register(t){this._users.set(t.id.slice(0,-1),t)}deregister(t){this.clear(t),this._sizeLimits.delete(t),this._users.delete(t.id.slice(0,-1))}get maxSize(){return this._maxSize}set maxSize(t){this._maxSize=Math.max(t,-1),this._checkSize()}getSize(t,e){const n=this._db.get(t.id+e);return n?.size??0}put(t,e,n,s,o){e=t.id+e;const l=this._db.get(e);if(l&&(this._size-=l.size,t.size-=l.size,this._db.delete(e),l.entry!==n&&this._notifyRemove(e,l.entry,l.size,0)),s>this._maxSize)return void this._notifyRemove(e,n,s,0);if(void 0===n)return void console.warn("Refusing to cache undefined entry ");if(!s||s<0)return i||console.warn(`Refusing to cache entry with size ${s} for key ${e}`),void this._notifyRemove(e,n,0,0);const a=1+Math.max(o,-4)- -3;this._db.set(e,new r(n,s,a)),this._size+=s,t.size+=s,this._checkSize()}updateSize(t,e,n,i){e=t.id+e;const s=this._db.get(e);if(s&&s.entry===n){for(this._size-=s.size,t.size-=s.size;i>this._maxSize;){const t=this._notifyRemove(e,n,i,1);if(!(null!=t&&t>0))return void this._db.delete(e);i=t}s.size=i,this._size+=i,t.size+=i,this._checkSize()}}pop(t,e){e=t.id+e;const n=this._db.get(e);if(n)return this._size-=n.size,t.size-=n.size,this._db.delete(e),++this._hit,n.entry;++this._miss}get(t,e){e=t.id+e;const n=this._db.get(e);if(void 0!==n)return this._db.delete(e),n.lives=n.lifetime,this._db.set(e,n),++this._hit,n.entry;++this._miss}peek(t,e){const n=this._db.get(t.id+e);return n?++this._hit:++this._miss,n?.entry}get performanceInfo(){const t={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},e={},n=new Array;this._db.forEach((t,i)=>{const s=t.lifetime;n[s]=(n[s]||0)+t.size,this._users.forEach(n=>{const{id:s,name:r}=n;if(i.startsWith(s)){const n=e[r]||0;e[r]=n+t.size}})});const i={};this._users.forEach(t=>{const n=t.name;if("hitRate"in t&&"number"==typeof t.hitRate&&!isNaN(t.hitRate)&&t.hitRate>0){const s=e[n]||0;e[n]=s,i[n]=Math.round(100*t.hitRate)+"%"}else i[n]="0%"});const s=Object.keys(e);s.sort((t,n)=>e[n]-e[t]),s.forEach(n=>t[n]=Math.round(e[n]/2**20)+"MB / "+i[n]);for(let e=n.length-1;e>=0;--e){const i=n[e];i&&(t["Priority "+(e+-3-1)]=Math.round(i/this._size*100)+"%")}return t}resetStats(){this._hit=this._miss=0,this._users.forEach(t=>t.resetHitRate())}clear(t){const e=t.id;this._db.forEach((t,n)=>{n.startsWith(e)&&(this._size-=t.size,this._db.delete(n),this._notifyRemove(n,t.entry,t.size,0))}),t.size=0}clearAll(){this._db.forEach((t,e)=>this._notifyRemove(e,t.entry,t.size,0)),this._users.forEach(t=>t.size=0),this._size=0,this._db.clear()}*values(t){for(const[e,n]of this._db)e.startsWith(t.id)&&(yield n.entry)}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(t,e,n,i){const s=this._users.get(t.split(o)[0])?.removeFunc,r=s?.(e,i,n);return"number"==typeof r?r:null}_checkSize(){this._sizeLimits.forEach((t,e)=>this._checkSizeLimits(t,e)),this._checkSizeLimits(this.maxSize)}setMaxSize(t,e){null==e||e<=0?this._sizeLimits.delete(t):this._sizeLimits.set(t,e)}_checkSizeLimits(t,e){const n=e??this;if(n.size<=t)return;const i=e?.id;let s=!0;for(;s;){s=!1;for(const[r,l]of this._db)if(0===l.lifetime&&(!i||r.startsWith(i))){const i=e??this._users.get(r.split(o)[0]);if(this._purgeItem(r,l,i),n.size<=.9*t)return;s||=this._db.has(r)}}for(const[s,r]of this._db)if(!i||s.startsWith(i)){const i=e??this._users.get(s.split(o)[0]);if(this._purgeItem(s,r,i),n.size<=.9*t)return}}_purgeItem(t,e,n){if(this._db.delete(t),e.lives<=1){this._size-=e.size,n&&(n.size-=e.size);const i=this._notifyRemove(t,e.entry,e.size,1);null!=i&&i>0&&(this._size+=i,n&&(n.size+=i),e.lives=e.lifetime,e.size=i,this._db.set(t,e))}else--e.lives,this._db.set(t,e)}}class r{constructor(t,e,n){this.entry=t,this.size=e,this.lifetime=n,this.lives=n}}const o=":";class l{constructor(t,e){this.removeFunc=e,this._storage=new s,this.id="",this.name="",this.size=0,this._storage.maxSize=t,this._storage.register(this)}destroy(){this._storage.deregister(this),this._storage.destroy(),this._storage=null}put(t,e,n=1){this._storage.put(this,t,e,n,1)}pop(t){return this._storage.pop(this,t)}get(t){return this._storage.get(this,t)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(t){this._storage.maxSize=t}resetHitRate(){}}},69540:(t,e,n)=>{n.d(e,{O:()=>u,P:()=>h});var i=n(31635),s=n(65008),r=(n(44208),n(4718)),o=(n(53966),n(97768)),l=n(88620),a=n(40608);const u=t=>{const e=t;let n=class extends e{clone(t){const e=(0,l.oY)(this);(0,o.Lw)(e,"unable to clone instance of non-accessor class");const n=e.metadata,i=e.store,s={},a=new Map;for(const e in n){const o=n[e],l=i?.originOf(e),u=o.clonable;if(o.readOnly||!1===u||7!==l&&0!==l&&5!==l&&4!==l)continue;const h=this[e];let c=null;if("function"==typeof u)c=u(h,t);else if("reference"===u)c=h;else if(c=(0,r.TU)(h,t),null!=h&&null==c)continue;0===l?a.set(e,c):s[e]=c}const u=new(0,Object.getPrototypeOf(this).constructor)(s);if(a.size){const t=(0,l.oY)(u)?.store;if(t)for(const[e,n]of a)t.set(e,n,0)}return u}};return n=(0,i.Cg)([(0,a.$)("esri.core.Clonable")],n),n},h=u(s.A)},75503:(t,e,n)=>{n.d(e,{EC:()=>z,wq:()=>l});var i=n(4576),s=n(21818),r=(n(44208),n(15142)),o=n(11006);class l{constructor(t=9,e){this._compareMinX=d,this._compareMinY=f,this._toBBox=t=>t,this._maxEntries=Math.max(4,t||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),e&&("function"==typeof e?this._toBBox=e:this._initFormat(e)),this.clear()}destroy(){this.clear(),w.prune(),I.prune(),v.prune(),b.prune()}all(t){a(this._data,t)}search(t,e){let n=this._data;const i=this._toBBox;if(x(t,n))for(w.clear();n;){for(let s=0,r=n.children.length;s<r;s++){const r=n.children[s],o=n.leaf?i(r):r;x(t,o)&&(n.leaf?e(r):y(t,o)?a(r,e):w.push(r))}n=w.pop()}}collides(t){let e=this._data;const n=this._toBBox;if(!x(t,e))return!1;for(w.clear();e;){for(let i=0,s=e.children.length;i<s;i++){const s=e.children[i],r=e.leaf?n(s):s;if(x(t,r)){if(e.leaf||y(t,r))return!0;w.push(s)}}e=w.pop()}return!1}load(t){if(!t.length)return this;if(t.length<this._minEntries){for(let e=0,n=t.length;e<n;e++)this.insert(t[e]);return this}let e=this._build(t.slice(),0,t.length-1,0);if(this._data.children.length)if(this._data.height===e.height)this._splitRoot(this._data,e);else{if(this._data.height<e.height){const t=this._data;this._data=e,e=t}this._insert(e,this._data.height-e.height-1,!0)}else this._data=e;return this}insert(t){return t&&this._insert(t,this._data.height-1),this}clear(){return this._data=new R([]),this}remove(t){if(!t)return this;let e,n=this._data,r=null,o=0,l=!1;const a=this._toBBox(t);for(v.clear(),b.clear();n||v.length>0;){if(n||(n=v.pop(),r=v.data[v.length-1],o=b.pop()??0,l=!0),n.leaf&&(e=(0,i.qh)(n.children,(0,s.zI)(t),n.children.length,n.indexHint),-1!==e))return n.children.splice(e,1),v.push(n),this._condense(v),this;l||n.leaf||!y(n,a)?r?(o++,n=r.children[o],l=!1):n=null:(v.push(n),b.push(o),o=0,r=n,n=n.children[0])}return this}toJSON(){return this._data}fromJSON(t){return this._data=t,this}_build(t,e,n,i){const s=n-e+1;let r=this._maxEntries;if(s<=r){const i=new R(t.slice(e,n+1));return u(i,this._toBBox),i}i||(i=Math.ceil(Math.log(s)/Math.log(r)),r=Math.ceil(s/r**(i-1)));const o=new S([]);o.height=i;const l=Math.ceil(s/r),a=l*Math.ceil(Math.sqrt(r));M(t,e,n,a,this._compareMinX);for(let s=e;s<=n;s+=a){const e=Math.min(s+a-1,n);M(t,s,e,l,this._compareMinY);for(let n=s;n<=e;n+=l){const s=Math.min(n+l-1,e);o.children.push(this._build(t,n,s,i-1))}}return u(o,this._toBBox),o}_insert(t,e,n){const i=this._toBBox,s=n?t:i(t);v.clear();const r=function(t,e,n,i){for(;i.push(e),!0!==e.leaf&&i.length-1!==n;){let n,i=1/0,s=1/0;for(let r=0,o=e.children.length;r<o;r++){const o=e.children[r],l=m(o),a=p(t,o)-l;a<s?(s=a,i=l<i?l:i,n=o):a===s&&l<i&&(i=l,n=o)}e=n||e.children[0]}return e}(s,this._data,e,v);for(r.children.push(t),c(r,s);e>=0&&v.data[e].children.length>this._maxEntries;)this._split(v,e),e--;!function(t,e,n){for(let i=n;i>=0;i--)c(e.data[i],t)}(s,v,e)}_split(t,e){const n=t.data[e],i=n.children.length,s=this._minEntries;this._chooseSplitAxis(n,s,i);const r=this._chooseSplitIndex(n,s,i);if(!r)return;const o=n.children.splice(r,n.children.length-r),l=n.leaf?new R(o):new S(o);l.height=n.height,u(n,this._toBBox),u(l,this._toBBox),e?t.data[e-1].children.push(l):this._splitRoot(n,l)}_splitRoot(t,e){this._data=new S([t,e]),this._data.height=t.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(t,e,n){let i,s,r;i=s=1/0;for(let o=e;o<=n-e;o++){const e=h(t,0,o,this._toBBox),l=h(t,o,n,this._toBBox),a=g(e,l),u=m(e)+m(l);a<i?(i=a,r=o,s=u<s?u:s):a===i&&u<s&&(s=u,r=o)}return r}_chooseSplitAxis(t,e,n){const i=t.leaf?this._compareMinX:d,s=t.leaf?this._compareMinY:f;this._allDistMargin(t,e,n,i)<this._allDistMargin(t,e,n,s)&&t.children.sort(i)}_allDistMargin(t,e,n,i){t.children.sort(i);const s=this._toBBox,r=h(t,0,e,s),o=h(t,n-e,n,s);let l=_(r)+_(o);for(let i=e;i<n-e;i++){const e=t.children[i];c(r,t.leaf?s(e):e),l+=_(r)}for(let i=n-e-1;i>=e;i--){const e=t.children[i];c(o,t.leaf?s(e):e),l+=_(o)}return l}_condense(t){for(let e=t.length-1;e>=0;e--){const n=t.data[e];if(0===n.children.length)if(e>0){const s=t.data[e-1],r=s.children;r.splice((0,i.qh)(r,n,r.length,s.indexHint),1)}else this.clear();else u(n,this._toBBox)}}_initFormat(t){const e=["return a"," - b",";"];this._compareMinX=new Function("a","b",e.join(t[0])),this._compareMinY=new Function("a","b",e.join(t[1])),this._toBBox=new Function("a","return {minX: a"+t[0]+", minY: a"+t[1]+", maxX: a"+t[2]+", maxY: a"+t[3]+"};")}}function a(t,e){let n=t;for(I.clear();n;){if(!0===n.leaf)for(const t of n.children)e((0,s.zI)(t));else I.pushArray(n.children);n=I.pop()??null}}function u(t,e){h(t,0,t.children.length,e,t)}function h(t,e,n,i,s){s||(s=new R([])),s.minX=1/0,s.minY=1/0,s.maxX=-1/0,s.maxY=-1/0;for(let r,o=e;o<n;o++)r=t.children[o],c(s,t.leaf?i(r):r);return s}function c(t,e){t.minX=Math.min(t.minX,e.minX),t.minY=Math.min(t.minY,e.minY),t.maxX=Math.max(t.maxX,e.maxX),t.maxY=Math.max(t.maxY,e.maxY)}function d(t,e){return t.minX-e.minX}function f(t,e){return t.minY-e.minY}function m(t){return(t.maxX-t.minX)*(t.maxY-t.minY)}function _(t){return t.maxX-t.minX+(t.maxY-t.minY)}function p(t,e){return(Math.max(e.maxX,t.maxX)-Math.min(e.minX,t.minX))*(Math.max(e.maxY,t.maxY)-Math.min(e.minY,t.minY))}function g(t,e){const n=Math.max(t.minX,e.minX),i=Math.max(t.minY,e.minY),s=Math.min(t.maxX,e.maxX),r=Math.min(t.maxY,e.maxY);return Math.max(0,s-n)*Math.max(0,r-i)}function y(t,e){return t.minX<=e.minX&&t.minY<=e.minY&&e.maxX<=t.maxX&&e.maxY<=t.maxY}function x(t,e){return e.minX<=t.maxX&&e.minY<=t.maxY&&e.maxX>=t.minX&&e.maxY>=t.minY}function M(t,e,n,i,s){const r=[e,n];for(;r.length;){const e=r.pop(),n=r.pop();if(e-n<=i)continue;const l=n+Math.ceil((e-n)/i/2)*i;(0,o.q)(t,l,n,e,s),r.push(n,l,l,e)}}const w=new r.A,I=new r.A,v=new r.A,b=new r.A({deallocator:void 0});class z{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class B extends z{constructor(){super(...arguments),this.height=1,this.indexHint=new i.vW}}class R extends B{constructor(t){super(),this.children=t,this.leaf=!0}}class S extends B{constructor(t){super(),this.children=t,this.leaf=!1}}},83221:(t,e,n)=>{n.d(e,{A:()=>m});var i=n(4576),s=n(49186),r=n(65529),o=n(53966),l=n(70328),a=n(19419),u=n(90708),h=n(6518),c=n(51441),d=n(37730);const f=(0,l.vt)();class m{constructor(t){this.geometryInfo=t,this._boundsStore=new h.F,this._featuresById=new Map,this._usedMemory=0,this.events=new r.bk,this.featureAdapter=d.T}get usedMemory(){return this._usedMemory}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let t=0;return this._featuresById.forEach(e=>{null!=e.geometry&&e.geometry.coords&&(t+=e.geometry.coords.length)}),{featureCount:this._featuresById.size,vertexCount:t/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(t){if(null==this.fullBounds)return null;const[e,n,i,s]=this.fullBounds;return{xmin:e,ymin:n,xmax:i,ymax:s,spatialReference:(0,c.ag)(t)}}add(t){this._add(t),this._emitChanged()}addMany(t){for(const e of t)this._add(e);this._emitChanged()}upsertMany(t){const e=t.map(t=>this._upsert(t));return this._emitChanged(),e.filter(i.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged(),this._usedMemory=0}removeById(t){const e=this._featuresById.get(t);return e?(this._remove(e),this._emitChanged(),e):null}removeManyById(t){this._boundsStore.invalidateIndex();for(const e of t){const t=this._featuresById.get(e);t&&this._remove(t)}this._emitChanged()}forEachBounds(t,e){for(const n of t){const t=this._boundsStore.get(n.objectId);t&&e((0,l.Jt)(f,t))}}getFeature(t){return this._featuresById.get(t)}has(t){return this._featuresById.has(t)}forEach(t){this._featuresById.forEach(e=>t(e))}forEachInBounds(t,e){this._boundsStore.forEachInBounds(t,t=>{e(this._featuresById.get(t))})}_emitChanged(){this.events.emit("changed",void 0)}_add(t){if(!t)return;const e=t.objectId;if(null==e)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:t}));const n=this._featuresById.get(e);let i;if(n?(t.displayId=n.displayId,i=this._boundsStore.get(e),this._boundsStore.delete(e),this._usedMemory-=this.estimateFeatureUsedMemory?.(n)??0):null!=this.onFeatureAdd&&this.onFeatureAdd(t),!t.geometry?.coords?.length)return this._boundsStore.set(e,null),void this._featuresById.set(e,t);i=(0,u.jQ)(null!=i?i:(0,a.vt)(),t.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=i&&this._boundsStore.set(e,i),this._featuresById.set(e,t),this._usedMemory+=this.estimateFeatureUsedMemory?.(t)??0}_upsert(t){const e=t?.objectId;if(null==e)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:t})),null;const n=this._featuresById.get(e);if(!n)return this._add(t),t;this._usedMemory-=this.estimateFeatureUsedMemory?.(n)??0;const{geometry:i,attributes:r}=t;for(const t in r)n.attributes[t]=r[t];return i&&(n.geometry=i,this._boundsStore.set(e,(0,u.jQ)((0,a.vt)(),i,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),this._usedMemory+=this.estimateFeatureUsedMemory?.(n)??0,n}_remove(t){null!=this.onFeatureRemove&&this.onFeatureRemove(t);const e=t.objectId;return this._boundsStore.delete(e),this._featuresById.delete(e),this._usedMemory-=this.estimateFeatureUsedMemory?.(t)??0,t}}},98453:(t,e,n)=>{n.d(e,{m:()=>i});const i=new(n(66552).J)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})},98988:(t,e,n)=>{n.r(e),n.d(e,{canProjectWithoutEngine:()=>$,getTransformation:()=>C,getTransformations:()=>q,initializeProjection:()=>U,isEqualBaseGCS:()=>J,isLoaded:()=>A,isLoadedOrLoad:()=>T,isLoadedOrLoadFor:()=>F,load:()=>X,project:()=>E,projectExtent:()=>rt,projectMany:()=>P,projectMultipoint:()=>V,projectOrLoad:()=>O,projectOrLoadMany:()=>L,projectPoint:()=>D,projectPolygon:()=>it,projectPolyline:()=>et,projectWithZConversion:()=>W,projectWithoutEngine:()=>K,requiresLoad:()=>Y,test:()=>Z,tryProjectWithZConversion:()=>H,unload:()=>N});var i=n(49186),s=n(74887),r=n(62788),o=n(95488),l=n(51850),a=n(21276),u=n(73941),h=n(5443),c=n(48526),d=n(83290),f=n(86738),m=n(39829),_=n(82799),p=n(16930),g=n(9762),y=n(37539);function x(t,e,n,i,s,r){return M[0]=t,M[1]=e,M[2]=n,(0,g.projectBuffer)(M,i,0,s,r,0)}const M=(0,l.vt)();let w=0;class I{static fromGE(t){const e=new I;return e._wkt=t.wkt,e._wkid=t.wkid,e._isInverse=t.isInverse,e}constructor(t){this.uid=w++,t?(this._wkt=null!=t.wkt?t.wkt:null,this._wkid=null!=t.wkid?t.wkid:-1,this._isInverse=null!=t.isInverse&&!0===t.isInverse):(this._wkt=null,this._wkid=-1,this._isInverse=!1)}get wkt(){return this._wkt}set wkt(t){this._wkt=t,this.uid=w++}get wkid(){return this._wkid}set wkid(t){this._wkid=t,this.uid=w++}get isInverse(){return this._isInverse}set isInverse(t){this._isInverse=t,this.uid=w++}getInverse(){const t=new I;return t._wkt=this.wkt,t._wkid=this._wkid,t._isInverse=!this.isInverse,t}}class v{static cacheKey(t,e){return[t.wkid?.toString()??"-1",t.wkt?.toString()??"",t.wkt2?.toString()??"",e.wkid?.toString()??"-1",e.wkt?.toString()??"",e.wkt2?.toString()??""].join()}static fromGE(t){const e=new v;let n="";for(const i of t.steps){const t=I.fromGE(i);e.steps.push(t),n+=t.uid.toString()+","}return e._cachedProjection={},e._gtlistentry=null,e._chain=n,e}constructor(t){if(this.steps=[],this._cachedProjection={},this._chain="",this._gtlistentry=null,t?.steps)for(const e of t.steps)e instanceof I?this.steps.push(e):this.steps.push(new I({wkid:e.wkid,wkt:e.wkt,isInverse:e.isInverse}))}getInverse(){const t=new v;t.steps=[];for(let e=this.steps.length-1;e>=0;e--){const n=this.steps[e];t.steps.push(n.getInverse())}return t}getGTListEntry(){let t="";for(const e of this.steps)t+=e.uid.toString()+",";return t!==this._chain&&(this._gtlistentry=null,this._cachedProjection={},this._chain=t),this._gtlistentry}assignCachedGe(t,e,n){this._cachedProjection[v.cacheKey(t,e)]=n}getCachedGeTransformation(t,e){let n="";for(const t of this.steps)n+=t.uid.toString()+",";n!==this._chain&&(this._gtlistentry=null,this._cachedProjection={},this._chain=n);const i=this._cachedProjection[v.cacheKey(t,e)];return void 0===i?null:i}}var b=n(21325),z=n(62815);let B=null,R=null,S=null,k={};const j=new o.I;function A(){return!!B&&(0,d.i)()}function T(){return!!A()||((0,r.gc)(j),X(),!1)}function F(t,e){return!t||!e||$(t,e)||T()}function Y(t,e){return!$(t,e)&&!A()}function X(t){return null==S&&(S=Promise.all([(0,d.l)(),n.e(9930).then(n.bind(n,49930)).then(t=>t.g),n.e(2731).then(n.bind(n,12731))])),S.then(([,e,{hydratedAdapter:n}])=>{(0,s.Te)(t),R=n,B=e.default,B._enableProjection(d.p),j.notify()})}function E(t,e,n=null,i=null){return Array.isArray(t)?0===t.length?[]:((0,a.H)(t),P(R,t,t[0].spatialReference,e,n,i)):((0,a.f)(t),P(R,[t],t.spatialReference,e,n,i)[0])}function P(t,e,n,i,s=null,r=null){if(null==n||null==i)return e;if($(n,i,s))return e.map(t=>K(t,n,i));if(null==s&&(0,u.jA)(n))return e.map(t=>K(t,n,p.A.WGS84)).map(t=>H(t,i));if(null==s&&(0,u.jA)(i))return e.map(t=>H(t,p.A.WGS84)).map(t=>K(t,p.A.WGS84,i));if(null==s){const t=v.cacheKey(n,i);void 0!==k[t]?s=k[t]:(null==(s=C(n,i,void 0))&&(s=new v),k[t]=s)}if(null==B||null==t)throw new G;return null!=r?B._project(t,e,n,i,s,r):B._project(t,e,n,i,s)}function O(t,e){const n=L([t],e);return null!=n.pending?{pending:n.pending,geometry:null}:null!=n.geometries?{pending:null,geometry:n.geometries[0]}:{pending:null,geometry:null}}function L(t,e){if(!A())for(const n of t)if(null!=n&&!(0,b.aI)(n.spatialReference,e)&&(0,b.fn)(n.spatialReference)&&(0,b.fn)(e)&&!$(n.spatialReference,e))return(0,r.gc)(j),{pending:X(),geometries:null};return{pending:null,geometries:t.map(t=>null==t?null:(0,b.aI)(t.spatialReference,e)?t:(0,b.fn)(t.spatialReference)&&(0,b.fn)(e)?H(t,e):null)}}function C(t,e,n=null){if(null==t||null==e)return null;if(null==B||null==R)throw new G;const i=B._getTransformation(R,t,e,n,n?.spatialReference);return null!==i?v.fromGE(i):null}function q(t,e,n=null){if(null==B||null==R)throw new G;const i=B._getTransformationBySuitability(R,t,e,n,n?.spatialReference);if(null!==i){const t=[];for(const e of i)t.push(v.fromGE(e));return t}return[]}class G extends i.A{constructor(){super("projection:not-loaded","projection engine not fully loaded yet, please call load()")}}function N(){B=null,R=null,S=null,k={}}const Z={get loadPromise(){return S}};function H(t,e){try{const n=E(t,e);if(null==n)return null;"xmin"in t&&"xmin"in n&&(n.zmin=t.zmin,n.zmax=t.zmax);const i=(0,z.N)(n.type,t.spatialReference,e);return null!=i&&i(n),n}catch(t){if(!(t instanceof G))throw t;return null}}async function W(t,e,n){const i=t.spatialReference;return null!=i&&null!=e&&await U(i,e,null,n),H(t,e)}function $(t,e,n){return!n&&(!!(0,b.aI)(t,e)||(0,b.fn)(t)&&(0,b.fn)(e)&&!!(0,y.jd)(t,e))}function J(t,e){if((0,b.aI)(t,e))return!0;if(!(0,b.fn)(t)||!(0,b.fn)(e))return!1;const n=(0,b.oT)(t)||(0,b.K8)(t)||(0,b.x1)(t),i=(0,b.oT)(e)||(0,b.K8)(e)||(0,b.x1)(e);return n&&i}async function U(t,e,n,i){if(A())return(0,s.NO)(i);if(Array.isArray(t)){for(const{source:e,dest:n,geographicTransformation:s}of t)if(e&&n&&!$(e,n,s))return X(i)}else if(t&&e&&!$(t,e,n))return X(i);return(0,s.NO)(i)}function K(t,e,n){return t?"x"in t?Q(t,e,new f.A,n,0):"xmin"in t?ot(t,e,new h.A,n,0):"rings"in t?st(t,e,new m.A,n,0):"paths"in t?nt(t,e,new _.A,n,0):"points"in t?tt(t,e,new c.A,n,0):null:null}function D(t,e,n=e.spatialReference,i=0){return null!=n&&null!=t.spatialReference&&null!=Q(t,t.spatialReference,e,n,i)}function Q(t,e,n,i,s){at[0]=t.x,at[1]=t.y;const r=t.z;return at[2]=void 0!==r?r:s,(0,g.projectBuffer)(at,e,0,at,i,0)?(n.x=at[0],n.y=at[1],n.spatialReference=i,void 0!==r||(0,u.xP)(i)?(n.z=at[2],n.hasZ=!0):(n.z=void 0,n.hasZ=!1),void 0===t.m?(n.m=void 0,n.hasM=!1):(n.m=t.m,n.hasM=!0),n):null}function V(t,e,n=e.spatialReference,i=0){return null!=t.spatialReference&&null!=n&&null!=tt(t,t.spatialReference,e,n,i)}function tt(t,e,n,i,s){const{points:r,hasZ:o,hasM:l}=t,a=[],h=r.length,c=[];for(const t of r)c.push(t[0],t[1],o?t[2]:s);if(!(0,g.projectBuffer)(c,e,0,c,i,0,h))return null;const d=o||(0,u.xP)(i);for(let t=0;t<h;++t){const e=3*t,n=c[e],i=c[e+1];d&&l?a.push([n,i,c[e+2],r[t][3]]):d?a.push([n,i,c[e+2]]):l?a.push([n,i,r[t][2]]):a.push([n,i])}return n.points=a,n.spatialReference=i,n.hasZ=o,n.hasM=l,n}function et(t,e,n=e.spatialReference,i=0){return null!=t.spatialReference&&null!=n&&null!=nt(t,t.spatialReference,e,n,i)}function nt(t,e,n,i,s){const{paths:r,hasZ:o,hasM:l}=t,a=[];if(!lt(r,o??!1,l??!1,e,a,i,s))return null;const h=o||(0,u.xP)(i);return n.paths=a,n.spatialReference=i,n.hasZ=h,n.hasM=l,n}function it(t,e,n=e.spatialReference,i=0){return null!=t.spatialReference&&null!=n&&null!=st(t,t.spatialReference,e,n,i)}function st(t,e,n,i,s){const{rings:r,hasZ:o,hasM:l}=t,a=[];if(!lt(r,o??!1,l??!1,e,a,i,s))return null;const h=o||(0,u.xP)(i);return n.rings=a,n.spatialReference=i,n.hasZ=h,n.hasM=l,n}function rt(t,e,n=e.spatialReference,i=0){return null!=t.spatialReference&&null!=n&&null!=ot(t,t.spatialReference,e,n,i)}function ot(t,e,n,i,s){const{xmin:r,ymin:o,xmax:l,ymax:a,hasZ:h,hasM:c}=t;if(!x(r,o,h?t.zmin:s,e,at,i))return null;const d=h||(0,u.xP)(i);return n.xmin=at[0],n.ymin=at[1],d&&(n.zmin=at[2]),x(l,a,h?t.zmax:s,e,at,i)?(n.xmax=at[0],n.ymax=at[1],d&&(n.zmax=at[2]),c&&(n.mmin=t.mmin,n.mmax=t.mmax),n.spatialReference=i,n):null}function lt(t,e,n,i,s,r,o=0){const l=new Array;for(const n of t)for(const t of n)l.push(t[0],t[1],e?t[2]:o);if(!(0,g.projectBuffer)(l,i,0,l,r,0))return!1;let a=0;s.length=0;const h=e||(0,u.xP)(r);for(const e of t){const t=new Array;for(const i of e)h&&n?t.push([l[a++],l[a++],l[a++],i[3]]):h?t.push([l[a++],l[a++],l[a++]]):n?(t.push([l[a++],l[a++],i[2]]),a++):(t.push([l[a++],l[a++]]),a++);s.push(t)}return!0}const at=(0,l.vt)()}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9423],{15585:(t,e,r)=>{r.d(e,{F:()=>a,l:()=>u});var n=r(2741),i=r(44208);const o=128e3;let s=null,x=null;async function a(){return s||(s=async function(){const t=(0,i.A)("esri-csp-restrictions")?await r.e(177).then(r.bind(r,50177)).then(t=>t.l):await r.e(3091).then(r.bind(r,13091)).then(t=>t.l);x=await t.default({locateFile:t=>(0,n.s)(`esri/core/libs/libtess/${t}`)})}()),s}function u(t,e){const r=Math.max(t.length,o);return x.triangulate(t,e,r)}},18989:(t,e,r)=>{r.d(e,{A:()=>n});class n{constructor(t=0,e=0,r=0,n=0){this.x=t,this.y=e,this.width=r,this.height=n}get isEmpty(){return this.width<=0||this.height<=0}union(t){this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.width=Math.max(this.width,t.width),this.height=Math.max(this.height,t.height)}}},32488:(t,e,r)=>{r.d(e,{A:()=>b});const n=[["(",")"],[")","("],["<",">"],[">","<"],["[","]"],["]","["],["{","}"],["}","{"],["«","»"],["»","«"],["‹","›"],["›","‹"],["⁽","⁾"],["⁾","⁽"],["₍","₎"],["₎","₍"],["≤","≥"],["≥","≤"],["〈","〉"],["〉","〈"],["﹙","﹚"],["﹚","﹙"],["﹛","﹜"],["﹜","﹛"],["﹝","﹞"],["﹞","﹝"],["﹤","﹥"],["﹥","﹤"]],i=["آ","أ","إ","ا"],o=["ﻵ","ﻷ","ﻹ","ﻻ"],s=["ﻶ","ﻸ","ﻺ","ﻼ"],x=["ا","ب","ت","ث","ج","ح","خ","د","ذ","ر","ز","س","ش","ص","ض","ط","ظ","ع","غ","ف","ق","ك","ل","م","ن","ه","و","ي","إ","أ","آ","ة","ى","ل","م","ن","ه","و","ي","إ","أ","آ","ة","ى","ی","ئ","ؤ"],a=["ﺍ","ﺏ","ﺕ","ﺙ","ﺝ","ﺡ","ﺥ","ﺩ","ﺫ","ﺭ","ﺯ","ﺱ","ﺵ","ﺹ","ﺽ","ﻁ","ﻅ","ﻉ","ﻍ","ﻑ","ﻕ","ﻙ","ﻝ","ﻡ","ﻥ","ﻩ","ﻭ","ﻱ","ﺇ","ﺃ","ﺁ","ﺓ","ﻯ","ﯼ","ﺉ","ﺅ","ﹰ","ﹲ","ﹴ","ﹶ","ﹸ","ﹺ","ﹼ","ﹾ","ﺀ","ﺉ","ﺅ"],u=["ﺎ","ﺐ","ﺖ","ﺚ","ﺞ","ﺢ","ﺦ","ﺪ","ﺬ","ﺮ","ﺰ","ﺲ","ﺶ","ﺺ","ﺾ","ﻂ","ﻆ","ﻊ","ﻎ","ﻒ","ﻖ","ﻚ","ﻞ","ﻢ","ﻦ","ﻪ","ﻮ","ﻲ","ﺈ","ﺄ","ﺂ","ﺔ","ﻰ","ﯽ","ﺊ","ﺆ","ﹰ","ﹲ","ﹴ","ﹶ","ﹸ","ﹺ","ﹼ","ﹾ","ﺀ","ﺊ","ﺆ"],l=["ﺎ","ﺒ","ﺘ","ﺜ","ﺠ","ﺤ","ﺨ","ﺪ","ﺬ","ﺮ","ﺰ","ﺴ","ﺸ","ﺼ","ﻀ","ﻄ","ﻈ","ﻌ","ﻐ","ﻔ","ﻘ","ﻜ","ﻠ","ﻤ","ﻨ","ﻬ","ﻮ","ﻴ","ﺈ","ﺄ","ﺂ","ﺔ","ﻰ","ﯿ","ﺌ","ﺆ","ﹱ","ﹲ","ﹴ","ﹷ","ﹹ","ﹻ","ﹽ","ﹿ","ﺀ","ﺌ","ﺆ"],h=["ﺍ","ﺑ","ﺗ","ﺛ","ﺟ","ﺣ","ﺧ","ﺩ","ﺫ","ﺭ","ﺯ","ﺳ","ﺷ","ﺻ","ﺿ","ﻃ","ﻇ","ﻋ","ﻏ","ﻓ","ﻗ","ﻛ","ﻟ","ﻣ","ﻧ","ﻫ","ﻭ","ﻳ","ﺇ","ﺃ","ﺁ","ﺓ","ﻯ","ﯾ","ﺋ","ﺅ","ﹰ","ﹲ","ﹴ","ﹶ","ﹸ","ﹺ","ﹼ","ﹾ","ﺀ","ﺋ","ﺅ"],f=["ء","آ","أ","ؤ","إ","ا","ة","د","ذ","ر","ز","و","ى"],y=["ً","ً","ٌ","؟","ٍ","؟","َ","َ","ُ","ُ","ِ","ِ","ّ","ّ","ْ","ْ","ء","آ","آ","أ","أ","ؤ","ؤ","إ","إ","ئ","ئ","ئ","ئ","ا","ا","ب","ب","ب","ب","ة","ة","ت","ت","ت","ت","ث","ث","ث","ث","ج","ج","ج","ج","ح","ح","ح","ح","خ","خ","خ","خ","د","د","ذ","ذ","ر","ر","ز","ز","س","س","س","س","ش","ش","ش","ش","ص","ص","ص","ص","ض","ض","ض","ض","ط","ط","ط","ط","ظ","ظ","ظ","ظ","ع","ع","ع","ع","غ","غ","غ","غ","ف","ف","ف","ف","ق","ق","ق","ق","ك","ك","ك","ك","ل","ل","ل","ل","م","م","م","م","ن","ن","ن","ن","ه","ه","ه","ه","و","و","ى","ى","ي","ي","ي","ي","ﻵ","ﻶ","ﻷ","ﻸ","ﻹ","ﻺ","ﻻ","ﻼ","؟","؟","؟"],c=["ء","ف"],v=["غ","ي"],_=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],d=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],p=10,T=11,g=12,w=18,A=["UBAT_L","UBAT_R","UBAT_EN","UBAT_AN","UBAT_ON","UBAT_B","UBAT_S","UBAT_AL","UBAT_WS","UBAT_CS","UBAT_ES","UBAT_ET","UBAT_NSM","UBAT_LRE","UBAT_RLE","UBAT_PDF","UBAT_LRO","UBAT_RLO","UBAT_BN"],m=[100,0,0,0,0,101,102,103,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,104,4,4,4,0,4,0,4,0,4,4,4,0,0,4,4,0,0,0,0,0,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,4,4,0,0,4,4,0,0,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,0,0,0,105,7,7,106,107],L=[[w,w,w,w,w,w,w,w,w,6,5,6,8,5,w,w,w,w,w,w,w,w,w,w,w,w,w,w,5,5,5,6,8,4,4,T,T,T,4,4,4,4,4,p,9,p,9,9,2,2,2,2,2,2,2,2,2,2,9,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,w,w,w,w,w,w,5,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,w,9,4,T,T,T,T,4,4,4,4,0,4,4,w,4,4,T,T,2,2,4,0,4,4,4,2,0,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,0,0,0,0,0,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,0,0,0,0,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,4,4,4,4,4,4,4,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,1,g,1,g,g,1,g,g,1,g,4,4,4,4,4,4,4,4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,4,4,4,4,4,1,1,1,1,1,4,4,4,4,4,4,4,4,4,4,4],[3,3,3,3,4,4,4,4,7,T,T,7,9,7,4,4,g,g,g,g,g,g,g,g,g,g,g,7,4,4,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,3,3,3,3,3,3,3,3,3,3,T,3,3,7,7,7,g,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,g,g,g,g,g,g,g,3,4,g,g,g,g,g,g,7,7,g,g,4,g,g,g,g,7,7,2,2,2,2,2,2,2,2,2,2,7,7,7,7,7,7],[7,7,7,7,7,7,7,7,7,7,7,7,7,7,4,7,7,g,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,4,4,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,g,g,g,g,g,g,g,g,g,g,g,7,4,4,4,4,4,4,4,4,4,4,4,4,4,4,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,g,g,g,g,g,g,g,g,g,1,1,4,4,4,4,1,4,4,4,4,4],[8,8,8,8,8,8,8,8,8,8,8,w,w,w,0,1,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,8,5,13,14,15,16,17,9,T,T,T,T,T,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,9,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,8,w,w,w,w,w,4,4,4,4,4,w,w,w,w,w,w,2,0,4,4,2,2,2,2,2,2,p,p,4,4,4,0,2,2,2,2,2,2,2,2,2,2,p,p,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,T,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4],[0,0,0,0,0,0,0,4,4,4,4,4,4,4,4,4,4,4,4,0,0,0,0,0,4,4,4,4,4,1,g,1,1,1,1,1,1,1,1,1,1,p,1,1,1,1,1,1,1,1,1,1,1,1,1,4,1,1,1,1,1,4,1,4,1,1,4,1,1,4,1,1,1,1,1,1,1,1,1,1,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7],[g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,g,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,g,g,g,g,g,g,g,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,9,4,9,4,4,9,4,4,4,4,4,4,4,4,4,T,4,4,p,p,4,4,4,4,4,T,T,4,4,4,4,4,7,7,7,7,7,4,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,4,4,w],[4,4,4,T,T,T,4,4,4,4,4,p,9,p,9,9,2,2,2,2,2,2,2,2,2,2,9,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,4,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,0,0,0,0,0,0,4,4,0,0,0,0,0,0,4,4,0,0,0,0,0,0,4,4,0,0,0,4,4,4,T,T,4,4,4,T,T,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4]];class b{constructor(){this.inputFormat="ILYNN",this.outputFormat="VLNNN",this.sourceToTarget=[],this.targetToSource=[],this.levels=[]}bidiTransform(t,e,r){if(this.sourceToTarget=[],this.targetToSource=[],!t)return"";if(function(t,e,r){X=[],G=[];for(let n=0;n<r;n++)t[n]=n,e[n]=n,X[n]=n}(this.sourceToTarget,this.targetToSource,t.length),!this.checkParameters(e,r))return t;e=this.inputFormat,r=this.outputFormat;let n=t;const x=H,l=W(e.charAt(1)),f=W(r.charAt(1)),c=(e.startsWith("I")?"L":e.charAt(0))+l,v=(r.startsWith("I")?"L":r.charAt(0))+f,_=e.charAt(2)+r.charAt(2);x.defInFormat=c,x.defOutFormat=v,x.defSwap=_;const d=B(t,c,v,_,x);let p=!1;return"R"===r.charAt(1)?p=!0:"C"!==r.charAt(1)&&"D"!==r.charAt(1)||(p="rtl"===this.checkContextual(d)),this.sourceToTarget=X,this.targetToSource=function(t){const e=new Array(t.length);for(let r=0;r<t.length;r++)e[t[r]]=r;return e}(this.sourceToTarget),$=this.targetToSource,n=e.charAt(3)===r.charAt(3)?d:"S"===r.charAt(3)?function(t,e){if(0===e.length)return"";void 0===t&&(t=!0);const r=(e=String(e)).split("");let n=0,i=1,x=r.length;t||(n=r.length-1,i=-1,x=1);const l=function(t,e,r,n){let i=0;const x=[];let l=0;for(let f=e;f*r<n;f+=r)if(Z(t[f])||P(t[f])){if("ل"===t[f]&&k(t,f+r,r,n)){t[f]=Y(t[f+r],0===i?o:s),f+=r,I(t,f,r,n),x[l]=f,l++,i=0;continue}const e=t[f];1===i?t[f]=M(t,f+r,r,n)?D(t[f]):O(t[f],u):!0===M(t,f+r,r,n)?t[f]=O(t[f],h):t[f]=O(t[f],a),P(e)||(i=1),!0===j(e)&&(i=0)}else i=0;return x}(r,n,i,x);let f="";for(let e=0;e<r.length;e++)S(l,l.length,e)>-1?(q($,e,!t,-1),X.splice(e,1)):f+=r[e];return f}(p,d):function(t,e){if(0===t.length)return"";void 0===e&&(e=!0);let r="";const n=(t=String(t)).split("");for(let o=0;o<t.length;o++){let s=!1;if(n[o]>="ﹰ"&&n[o]<"\ufeff"){const x=t.charCodeAt(o);n[o]>="ﻵ"&&n[o]<="ﻼ"?(e?(o>0&&" "===n[o-1]?r=r.slice(0,-1)+"ل":(r+="ل",s=!0),r+=i[(x-65269)/2]):(r+=i[(x-65269)/2],r+="ل",o+1<t.length&&" "===n[o+1]?o++:s=!0),s&&(q($,o,!0,1),X.splice(o,0,X[o]))):r+=y[x-65136]}else r+=n[o]}return r}(d,p),this.sourceToTarget=X,this.targetToSource=$,this.levels=G,n}_inputFormatSetter(t){if(!et.test(t))throw new Error("dojox/string/BidiEngine: the bidi layout string is wrong!");this.inputFormat=t}_outputFormatSetter(t){if(!et.test(t))throw new Error("dojox/string/BidiEngine: the bidi layout string is wrong!");this.outputFormat=t}checkParameters(t,e){return t?this._inputFormatSetter(t):t=this.inputFormat,e?this._outputFormatSetter(e):e=this.outputFormat,t!==e}checkContextual(t){let e=U(t);if("ltr"!==e&&"rtl"!==e){try{e=document.dir.toLowerCase()}catch(t){}"ltr"!==e&&"rtl"!==e&&(e="ltr")}return e}hasBidiChar(t){return rt.test(t)}}function B(t,e,r,n,i){const o=function(t,e,r){if(void 0===e.inFormat&&(e.inFormat=r.defInFormat),void 0===e.outFormat&&(e.outFormat=r.defOutFormat),void 0===e.swap&&(e.swap=r.defSwap),e.inFormat===e.outFormat)return e;const n=e.inFormat.slice(0,1),i=e.outFormat.slice(0,1);let o,s=e.inFormat.slice(1,4),x=e.outFormat.slice(1,4);return s.startsWith("C")&&(o=U(t),s="ltr"===o||"rtl"===o?o.toUpperCase():"L"===e.inFormat.charAt(2)?"LTR":"RTL",e.inFormat=n+s),x.startsWith("C")&&(o=U(t),"rtl"===o?x="RTL":"ltr"===o?(o=function(t){const e=t.split("");return e.reverse(),U(e.join(""))}(t),x=o.toUpperCase()):x="L"===e.outFormat.charAt(2)?"LTR":"RTL",e.outFormat=i+x),e}(t,{inFormat:e,outFormat:r,swap:n},i);if(o.inFormat===o.outFormat)return t;e=o.inFormat,r=o.outFormat,n=o.swap;const s=e.slice(0,1),x=e.slice(1,4),a=r.slice(0,1),u=r.slice(1,4);if(i.inFormat=e,i.outFormat=r,i.swap=n,"L"===s&&"VLTR"===r){if("LTR"===x)return i.dir=Q,R(t,i);if("RTL"===x)return i.dir=tt,R(t,i)}if("V"===s&&"V"===a)return i.dir="RTL"===x?tt:Q,V(t,i);if("L"===s&&"VRTL"===r)return"LTR"===x?(i.dir=Q,t=R(t,i)):(i.dir=tt,t=R(t,i)),V(t);if("VLTR"===e&&"LLTR"===r)return i.dir=Q,R(t,i);if("V"===s&&"L"===a&&x!==u)return t=V(t),"RTL"===x?B(t,"LLTR","VLTR",n,i):B(t,"LRTL","VRTL",n,i);if("VRTL"===e&&"LRTL"===r)return B(t,"LRTL","VRTL",n,i);if("L"===s&&"L"===a){const e=i.swap;return i.swap=e.slice(0,1)+"N","RTL"===x?(i.dir=tt,t=R(t,i),i.swap="N"+e.slice(1,3),i.dir=Q,t=R(t,i)):(i.dir=Q,t=R(t,i),i.swap="N"+e.slice(1,3),t=B(t,"VLTR","LRTL",i.swap,i)),t}return t}function U(t){const e=/[A-Za-z\u05d0-\u065f\u066a-\u06ef\u06fa-\u07ff\ufb1d-\ufdff\ufe70-\ufefc]/.exec(t);return e?e[0]<="z"?"ltr":"rtl":""}function R(t,e){const r=t.split(""),n=[];return F(r,n,e),function(t,e,r){if(0!==r.hiLevel&&r.swap[0]!==r.swap[1])for(let r=0;r<t.length;r++)1===e[r]&&(t[r]=z(t[r]))}(r,n,e),C(2,r,n,e),C(1,r,n,e),G=n,r.join("")}function F(t,e,r){const n=t.length,i=r.dir?d:_;let o=0,s=-1;const x=[],a=[];r.hiLevel=r.dir,r.lastArabic=!1,r.hasUbatAl=!1,r.hasUbatB=!1,r.hasUbatS=!1;for(let e=0;e<n;e++)x[e]=N(t[e]);for(let u=0;u<n;u++){const n=o,l=E(t,x,a,u,r);a[u]=l,o=i[n][l];const h=240&o;o&=15;const f=i[o][J];if(e[u]=f,h>0)if(16===h){for(let t=s;t<u;t++)e[t]=1;s=-1}else s=-1;if(i[o][K])-1===s&&(s=u);else if(s>-1){for(let t=s;t<u;t++)e[t]=f;s=-1}5===x[u]&&(e[u]=0),r.hiLevel|=f}r.hasUbatS&&function(t,e,r,n){for(let i=0;i<r;i++)if(6===t[i]){e[i]=n.dir;for(let r=i-1;r>=0&&8===t[r];r--)e[r]=n.dir}}(x,e,n,r)}function N(t){const e=t.charCodeAt(0),r=m[e>>8];return r<100?r:L[r-100][255&e]}function V(t,e){const r=t.split("");if(e){const t=[];F(r,t,e),G=t}return r.reverse(),X.reverse(),r.join("")}function S(t,e,r){for(let n=0;n<e;n++)if(t[n]===r)return n;return-1}function Z(t){for(let e=0;e<c.length;e++)if(t>=c[e]&&t<=v[e])return!0;return!1}function M(t,e,r,n){for(;e*r<n&&P(t[e]);)e+=r;return!!(e*r<n&&Z(t[e]))}function k(t,e,r,n){for(;e*r<n&&P(t[e]);)e+=r;let o=" ";if(!(e*r<n))return!1;o=t[e];for(let t=0;t<i.length;t++)if(i[t]===o)return!0;return!1}function C(t,e,r,n){if(n.hiLevel<t)return;if(1===t&&n.dir===tt&&!n.hasUbatB)return e.reverse(),void X.reverse();const i=e.length;let o,s,x,a,u,l=0;for(;l<i;){if(r[l]>=t){for(o=l+1;o<i&&r[o]>=t;)o++;for(s=l,x=o-1;s<x;s++,x--)a=e[s],e[s]=e[x],e[x]=a,u=X[s],X[s]=X[x],X[x]=u;l=o}l++}}function E(t,e,r,n,i){const o=e[n];return{UBAT_L:()=>(i.lastArabic=!1,0),UBAT_R:()=>(i.lastArabic=!1,1),UBAT_ON:()=>4,UBAT_AN:()=>3,UBAT_EN:()=>i.lastArabic?3:2,UBAT_AL:()=>(i.lastArabic=!0,i.hasUbatAl=!0,1),UBAT_WS:()=>4,UBAT_CS:()=>{let t,o;return n<1||n+1>=e.length||2!==(t=r[n-1])&&3!==t||2!==(o=e[n+1])&&3!==o?4:(i.lastArabic&&(o=3),o===t?o:4)},UBAT_ES:()=>2===(n>0?r[n-1]:5)&&n+1<e.length&&2===e[n+1]?2:4,UBAT_ET:()=>{if(n>0&&2===r[n-1])return 2;if(i.lastArabic)return 4;let t=n+1;const o=e.length;for(;t<o&&e[t]===T;)t++;return t<o&&2===e[t]?2:4},UBAT_NSM:()=>{if("VLTR"===i.inFormat){const r=e.length;let i=n+1;for(;i<r&&e[i]===g;)i++;if(i<r){const r=t[n].charCodeAt(0),o=r>=1425&&r<=2303||64286===r,s=e[i];if(o&&(1===s||7===s))return 1}}return n<1||5===e[n-1]?4:r[n-1]},UBAT_B:()=>(i.lastArabic=!0,i.hasUbatB=!0,i.dir),UBAT_S:()=>(i.hasUbatS=!0,4),UBAT_LRE:()=>(i.lastArabic=!1,4),UBAT_RLE:()=>(i.lastArabic=!1,4),UBAT_LRO:()=>(i.lastArabic=!1,4),UBAT_RLO:()=>(i.lastArabic=!1,4),UBAT_PDF:()=>(i.lastArabic=!1,4),UBAT_BN:()=>4}[A[o]]()}function z(t){let e,r=0,i=n.length-1;for(;r<=i;)if(e=Math.floor((r+i)/2),t<n[e][0])i=e-1;else{if(!(t>n[e][0]))return n[e][1];r=e+1}return t}function j(t){for(let e=0;e<f.length;e++)if(f[e]===t)return!0;return!1}function D(t){for(let e=0;e<x.length;e++)if(t===x[e])return l[e];return t}function O(t,e){for(let r=0;r<x.length;r++)if(t===x[r])return e[r];return t}function P(t){return t>="ً"&&t<="ٕ"}function W(t){return"L"===t?"LTR":"R"===t?"RTL":"C"===t?"CLR":"D"===t?"CRL":""}function I(t,e,r,n){for(;e*r<n&&P(t[e]);)e+=r;return e*r<n&&(t[e]=" ",!0)}function Y(t,e){for(let r=0;r<i.length;r++)if(t===i[r])return e[r];return t}function q(t,e,r,n){for(let i=0;i<t.length;i++)(t[i]>e||!r&&t[i]===e)&&(t[i]+=n)}let X=[],$=[],G=[];const H={dir:0,defInFormat:"LLTR",defSwap:"YN",inFormat:"LLTR",outFormat:"VLTR",swap:"YN",hiLevel:0,lastArabic:!1,hasUbatAl:!1,defOutFormat:""},J=5,K=6,Q=0,tt=1,et=/^[(I|V)][(L|RCD)][(Y|N)][(S|N)]N$/,rt=/[\u0591-\u06ff\ufb1d-\ufefc]/},83349:(t,e,r)=>{function n(t,e,r){r=r||2;var n,o,x,a,u,l,f,y=e&&e.length,c=y?e[0]*r:t.length,v=i(t,0,c,r,!0),_=[];if(!v||v.next===v.prev)return _;if(y&&(v=h(t,e,v,r)),t.length>80*r){n=x=t[0],o=a=t[1];for(var d=r;d<c;d+=r)(u=t[d])<n&&(n=u),(l=t[d+1])<o&&(o=l),u>x&&(x=u),l>a&&(a=l);f=0!==(f=Math.max(x-n,a-o))?1/f:0}return s(v,_,r,n,o,f),_}function i(t,e,r,n,i){var o,s;if(i===V(t,e,r,n)>0)for(o=e;o<r;o+=n)s=R(o,t[o],t[o+1],s);else for(o=r-n;o>=e;o-=n)s=R(o,t[o],t[o+1],s);if(s&&A(s,s.next)){var x=s.next;F(s),s=x}return s}function o(t,e){if(!t)return t;e||(e=t);var r,n=t;do{if(r=!1,n.steiner||!A(n,n.next)&&0!==w(n.prev,n,n.next))n=n.next;else{var i=n.prev;if(F(n),(n=e=i)===n.next)break;r=!0}}while(r||n!==e);return e}function s(t,e,r,n,i,h,f){if(t){!f&&h&&_(t,n,i,h);for(var y,c,v=t;t.prev!==t.next;)if(y=t.prev,c=t.next,h?a(t,n,i,h):x(t))e.push(y.i/r),e.push(t.i/r),e.push(c.i/r),F(t),t=c.next,v=c.next;else if((t=c)===v){f?1===f?s(t=u(o(t),e,r),e,r,n,i,h,2):2===f&&l(t,e,r,n,i,h):s(o(t),e,r,n,i,h,1);break}}}function x(t){var e=t.prev,r=t,n=t.next;if(w(e,r,n)>=0)return!1;for(var i=t.next.next;i!==t.prev;){if(T(e.x,e.y,r.x,r.y,n.x,n.y,i.x,i.y)&&w(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function a(t,e,r,n){var i=t.prev,o=t,s=t.next;if(w(i,o,s)>=0)return!1;for(var x=i.x<o.x?i.x<s.x?i.x:s.x:o.x<s.x?o.x:s.x,a=i.y<o.y?i.y<s.y?i.y:s.y:o.y<s.y?o.y:s.y,u=i.x>o.x?i.x>s.x?i.x:s.x:o.x>s.x?o.x:s.x,l=i.y>o.y?i.y>s.y?i.y:s.y:o.y>s.y?o.y:s.y,h=d(x,a,e,r,n),f=d(u,l,e,r,n),y=t.prevZ,c=t.nextZ;y&&y.z>=h&&c&&c.z<=f;){if(y!==t.prev&&y!==t.next&&T(i.x,i.y,o.x,o.y,s.x,s.y,y.x,y.y)&&w(y.prev,y,y.next)>=0)return!1;if(y=y.prevZ,c!==t.prev&&c!==t.next&&T(i.x,i.y,o.x,o.y,s.x,s.y,c.x,c.y)&&w(c.prev,c,c.next)>=0)return!1;c=c.nextZ}for(;y&&y.z>=h;){if(y!==t.prev&&y!==t.next&&T(i.x,i.y,o.x,o.y,s.x,s.y,y.x,y.y)&&w(y.prev,y,y.next)>=0)return!1;y=y.prevZ}for(;c&&c.z<=f;){if(c!==t.prev&&c!==t.next&&T(i.x,i.y,o.x,o.y,s.x,s.y,c.x,c.y)&&w(c.prev,c,c.next)>=0)return!1;c=c.nextZ}return!0}function u(t,e,r){var n=t;do{var i=n.prev,s=n.next.next;!A(i,s)&&m(i,n,n.next,s)&&B(i,s)&&B(s,i)&&(e.push(i.i/r),e.push(n.i/r),e.push(s.i/r),F(n),F(n.next),n=t=s),n=n.next}while(n!==t);return o(n)}function l(t,e,r,n,i,x){var a=t;do{for(var u=a.next.next;u!==a.prev;){if(a.i!==u.i&&g(a,u)){var l=U(a,u);return a=o(a,a.next),l=o(l,l.next),s(a,e,r,n,i,x),void s(l,e,r,n,i,x)}u=u.next}a=a.next}while(a!==t)}function h(t,e,r,n){var s,x,a,u=[];for(s=0,x=e.length;s<x;s++)(a=i(t,e[s]*n,s<x-1?e[s+1]*n:t.length,n,!1))===a.next&&(a.steiner=!0),u.push(p(a));for(u.sort(f),s=0;s<u.length;s++)r=o(r=c(u[s],r),r.next);return r}function f(t,e){return t.x-e.x}function y(t){if(t.next.prev===t)return t;let e=t;for(;;){const r=e.next;if(r.prev===e||r===e||r===t)break;e=r}return e}function c(t,e){var r=function(t,e){var r,n=e,i=t.x,o=t.y,s=-1/0;do{if(o<=n.y&&o>=n.next.y&&n.next.y!==n.y){var x=n.x+(o-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(x<=i&&x>s){if(s=x,x===i){if(o===n.y)return n;if(o===n.next.y)return n.next}r=n.x<n.next.x?n:n.next}}n=n.next}while(n!==e);if(!r)return null;if(i===s)return r;var a,u=r,l=r.x,h=r.y,f=1/0;n=r;do{i>=n.x&&n.x>=l&&i!==n.x&&T(o<h?i:s,o,l,h,o<h?s:i,o,n.x,n.y)&&(a=Math.abs(o-n.y)/(i-n.x),B(n,t)&&(a<f||a===f&&(n.x>r.x||n.x===r.x&&v(r,n)))&&(r=n,f=a)),n=n.next}while(n!==u);return r}(t,e);if(!r)return e;var n=U(r,t),i=o(r,r.next);let s=y(n);return o(s,s.next),i=y(i),y(e===r?i:e)}function v(t,e){return w(t.prev,t,e.prev)<0&&w(e.next,t,t.next)<0}function _(t,e,r,n){var i=t;do{null===i.z&&(i.z=d(i.x,i.y,e,r,n)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,r,n,i,o,s,x,a,u=1;do{for(r=t,t=null,o=null,s=0;r;){for(s++,n=r,x=0,e=0;e<u&&(x++,n=n.nextZ);e++);for(a=u;x>0||a>0&&n;)0!==x&&(0===a||!n||r.z<=n.z)?(i=r,r=r.nextZ,x--):(i=n,n=n.nextZ,a--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;r=n}o.nextZ=null,u*=2}while(s>1)}(i)}function d(t,e,r,n,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)*i)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-n)*i)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function p(t){var e=t,r=t;do{(e.x<r.x||e.x===r.x&&e.y<r.y)&&(r=e),e=e.next}while(e!==t);return r}function T(t,e,r,n,i,o,s,x){return(i-s)*(e-x)-(t-s)*(o-x)>=0&&(t-s)*(n-x)-(r-s)*(e-x)>=0&&(r-s)*(o-x)-(i-s)*(n-x)>=0}function g(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var r=t;do{if(r.i!==t.i&&r.next.i!==t.i&&r.i!==e.i&&r.next.i!==e.i&&m(r,r.next,t,e))return!0;r=r.next}while(r!==t);return!1}(t,e)&&(B(t,e)&&B(e,t)&&function(t,e){var r=t,n=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{r.y>o!=r.next.y>o&&r.next.y!==r.y&&i<(r.next.x-r.x)*(o-r.y)/(r.next.y-r.y)+r.x&&(n=!n),r=r.next}while(r!==t);return n}(t,e)&&(w(t.prev,t,e.prev)||w(t,e.prev,e))||A(t,e)&&w(t.prev,t,t.next)>0&&w(e.prev,e,e.next)>0)}function w(t,e,r){return(e.y-t.y)*(r.x-e.x)-(e.x-t.x)*(r.y-e.y)}function A(t,e){return t.x===e.x&&t.y===e.y}function m(t,e,r,n){var i=b(w(t,e,r)),o=b(w(t,e,n)),s=b(w(r,n,t)),x=b(w(r,n,e));return i!==o&&s!==x||!(0!==i||!L(t,r,e))||!(0!==o||!L(t,n,e))||!(0!==s||!L(r,t,n))||!(0!==x||!L(r,e,n))}function L(t,e,r){return e.x<=Math.max(t.x,r.x)&&e.x>=Math.min(t.x,r.x)&&e.y<=Math.max(t.y,r.y)&&e.y>=Math.min(t.y,r.y)}function b(t){return t>0?1:t<0?-1:0}function B(t,e){return w(t.prev,t,t.next)<0?w(t,e,t.next)>=0&&w(t,t.prev,e)>=0:w(t,e,t.prev)<0||w(t,t.next,e)<0}function U(t,e){var r=new N(t.i,t.x,t.y),n=new N(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,r.next=i,i.prev=r,n.next=r,r.prev=n,o.next=n,n.prev=o,n}function R(t,e,r,n){var i=new N(t,e,r);return n?(i.next=n.next,i.prev=n,n.next.prev=i,n.next=i):(i.prev=i,i.next=i),i}function F(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function N(t,e,r){this.i=t,this.x=e,this.y=r,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function V(t,e,r,n){for(var i=0,o=e,s=r-n;o<r;o+=n)i+=(t[s]-t[o])*(t[o+1]+t[s+1]),s=o;return i}r.d(e,{e:()=>n}),n.deviation=function(t,e,r,n){var i=e&&e.length,o=i?e[0]*r:t.length,s=Math.abs(V(t,0,o,r));if(i)for(var x=0,a=e.length;x<a;x++){var u=e[x]*r,l=x<a-1?e[x+1]*r:t.length;s-=Math.abs(V(t,u,l,r))}var h=0;for(x=0;x<n.length;x+=3){var f=n[x]*r,y=n[x+1]*r,c=n[x+2]*r;h+=Math.abs((t[f]-t[c])*(t[y+1]-t[f+1])-(t[f]-t[y])*(t[c+1]-t[f+1]))}return 0===s&&0===h?0:Math.abs((h-s)/s)},n.flatten=function(t){for(var e=t[0][0].length,r={vertices:[],holes:[],dimensions:e},n=0,i=0;i<t.length;i++){for(var o=0;o<t[i].length;o++)for(var s=0;s<e;s++)r.vertices.push(t[i][o][s]);i>0&&(n+=t[i-1].length,r.holes.push(n))}return r}},83773:(t,e,r)=>{r.d(e,{i:()=>c});var n=r(76213);function i(t,e){return t.x===e.x&&t.y===e.y}function o(t){if(!t)return;const e=t.length;if(e<=1)return;let r=0;for(let n=1;n<e;n++)i(t[n],t[r])||++r===n||(t[r]=t[n]);t.length=r+1}function s(t,e){return t.x=e.y,t.y=-e.x,t}function x(t,e){return t.x=-e.y,t.y=e.x,t}function a(t,e){return t.x=e.x,t.y=e.y,t}function u(t,e){return t.x=-e.x,t.y=-e.y,t}function l(t){return Math.sqrt(t.x*t.x+t.y*t.y)}function h(t,e){return t.x*e.y-t.y*e.x}function f(t,e){return t.x*e.x+t.y*e.y}function y(t,e,r,n){return t.x=e.x*r+e.y*n,t.y=e.x*n-e.y*r,t}class c{constructor(t,e,r){this._writeVertex=t,this._writeTriangle=e,this._canUseThinTessellation=r,this._prevNormal={x:void 0,y:void 0},this._nextNormal={x:void 0,y:void 0},this._textureNormalLeft={x:0,y:1},this._textureNormalRight={x:0,y:-1},this._textureNormal={x:void 0,y:void 0},this._joinNormal={x:void 0,y:void 0},this._inner={x:void 0,y:void 0},this._outer={x:void 0,y:void 0},this._roundStart={x:void 0,y:void 0},this._roundEnd={x:void 0,y:void 0},this._startBreak={x:void 0,y:void 0},this._endBreak={x:void 0,y:void 0},this._innerPrev={x:void 0,y:void 0},this._innerNext={x:void 0,y:void 0},this._bevelStart={x:void 0,y:void 0},this._bevelEnd={x:void 0,y:void 0},this._bevelMiddle={x:void 0,y:void 0}}tessellate(t,e,r=this._canUseThinTessellation){o(t),r&&e.halfWidth<n.Gh&&!e.offset?this._tessellateThin(t,e):this._tessellate(t,e)}_tessellateThin(t,e){if(t.length<2)return;const r=e.wrapDistance||65535;let n=e.initialDistance||0,i=!1,o=t[0].x,s=t[0].y;const x=t.length;for(let e=1;e<x;++e){i&&(i=!1,n=0);let x=t[e].x,a=t[e].y,u=x-o,l=a-s,h=Math.sqrt(u*u+l*l);if(u/=h,l/=h,n+h>r){i=!0;const t=(r-n)/h;h=r-n,x=(1-t)*o+t*x,a=(1-t)*s+t*a,--e}const f=this._writeVertex(o,s,0,0,u,l,l,-u,0,-1,n),y=this._writeVertex(o,s,0,0,u,l,-l,u,0,1,n);n+=h;const c=this._writeVertex(x,a,0,0,u,l,l,-u,0,-1,n),v=this._writeVertex(x,a,0,0,u,l,-l,u,0,1,n);this._writeTriangle(f,y,c),this._writeTriangle(y,c,v),o=x,s=a}}_tessellate(t,e){const r=t[0],n=t[t.length-1],o=i(r,n),c=o?3:2;if(t.length<c)return;const v=e.pixelCoordRatio,_=null!=e.capType?e.capType:0,d=null!=e.joinType?e.joinType:2,p=null!=e.miterLimit?Math.min(e.miterLimit,4):2,T=null!=e.roundLimit?Math.min(e.roundLimit,1.05):1.05,g=null!=e.halfWidth?e.halfWidth:2,w=!!e.textured;let A,m,L,b=null;const B=this._prevNormal,U=this._nextNormal;let R=-1,F=-1;const N=this._joinNormal;let V,S;const Z=this._textureNormalLeft,M=this._textureNormalRight,k=this._textureNormal;let C=-1,E=-1;const z=e.wrapDistance||65535;let j=e.initialDistance||0;const D=this._writeVertex,O=this._writeTriangle,P=(t,e,r,n,i,o)=>{const s=D(m,L,V,S,r,n,t,e,i,o,j);return C>=0&&E>=0&&s>=0&&O(C,E,s),C=E,E=s,s};o&&(A=t[t.length-2],U.x=n.x-A.x,U.y=n.y-A.y,F=l(U),U.x/=F,U.y/=F);let W=!1;for(let e=0;e<t.length;++e){if(W&&(W=!1,j=0),A&&(B.x=-U.x,B.y=-U.y,R=F,j+R>z&&(W=!0)),W){const r=(z-j)/R;R=z-j,A={x:(1-r)*A.x+r*t[e].x,y:(1-r)*A.y+r*t[e].y},--e}else A=t[e];m=A.x,L=A.y;const r=e<=0&&!W,n=e===t.length-1;if(r||(j+=R),b=n?o?t[1]:null:t[e+1],b?(U.x=b.x-m,U.y=b.y-L,F=l(U),U.x/=F,U.y/=F):(U.x=void 0,U.y=void 0),!o){if(r){x(N,U),V=N.x,S=N.y,2===_&&(P(-U.y-U.x,U.x-U.y,U.x,U.y,0,-1),P(U.y-U.x,-U.x-U.y,U.x,U.y,0,1)),1===_&&(P(-U.y-U.x,U.x-U.y,U.x,U.y,-1,-1),P(U.y-U.x,-U.x-U.y,U.x,U.y,-1,1)),1!==_&&0!==_||(P(-U.y,U.x,U.x,U.y,0,-1),P(U.y,-U.x,U.x,U.y,0,1));continue}if(n){s(N,B),V=N.x,S=N.y,1!==_&&0!==_||(P(B.y,-B.x,-B.x,-B.y,0,-1),P(-B.y,B.x,-B.x,-B.y,0,1)),2===_&&(P(B.y-B.x,-B.x-B.y,-B.x,-B.y,0,-1),P(-B.y-B.x,B.x-B.y,-B.x,-B.y,0,1)),1===_&&(P(B.y-B.x,-B.x-B.y,-B.x,-B.y,1,-1),P(-B.y-B.x,B.x-B.y,-B.x,-B.y,1,1));continue}}let i,c,D=-h(B,U);if(Math.abs(D)<.01)f(B,U)>0?(N.x=B.x,N.y=B.y,D=1,i=Number.MAX_VALUE,c=!0):(x(N,U),D=1,i=1,c=!1);else{N.x=(B.x+U.x)/D,N.y=(B.y+U.y)/D,i=l(N);const t=(i-1)*g*v;c=i>4||t>R&&t>F}V=N.x,S=N.y;let O=d;switch(d){case 0:i<1.05&&(O=2);break;case 1:i<T&&(O=2);break;case 2:i>p&&(O=0)}switch(O){case 2:if(P(N.x,N.y,-B.x,-B.y,0,-1),P(-N.x,-N.y,-B.x,-B.y,0,1),n)break;if(w){const t=W?0:j;C=this._writeVertex(m,L,V,S,U.x,U.y,N.x,N.y,0,-1,t),E=this._writeVertex(m,L,V,S,U.x,U.y,-N.x,-N.y,0,1,t)}break;case 0:{const t=D<0;let e,r,i,o;if(t){const t=C;C=E,E=t,e=Z,r=M}else e=M,r=Z;if(c)i=t?x(this._innerPrev,B):s(this._innerPrev,B),o=t?s(this._innerNext,U):x(this._innerNext,U);else{const e=t?u(this._inner,N):a(this._inner,N);i=e,o=e}const l=t?s(this._bevelStart,B):x(this._bevelStart,B);P(i.x,i.y,-B.x,-B.y,e.x,e.y);const h=P(l.x,l.y,-B.x,-B.y,r.x,r.y);if(n)break;const f=t?x(this._bevelEnd,U):s(this._bevelEnd,U);if(c){const t=this._writeVertex(m,L,V,S,-B.x,-B.y,0,0,0,0,j);C=this._writeVertex(m,L,V,S,U.x,U.y,o.x,o.y,e.x,e.y,j),E=this._writeVertex(m,L,V,S,U.x,U.y,f.x,f.y,r.x,r.y,j),this._writeTriangle(h,t,E)}else{if(w){const t=this._bevelMiddle;t.x=(l.x+f.x)/2,t.y=(l.y+f.y)/2,y(k,t,-B.x,-B.y),P(t.x,t.y,-B.x,-B.y,k.x,k.y),y(k,t,U.x,U.y),C=this._writeVertex(m,L,V,S,U.x,U.y,t.x,t.y,k.x,k.y,j),E=this._writeVertex(m,L,V,S,U.x,U.y,o.x,o.y,e.x,e.y,j)}else{const t=C;C=E,E=t}P(f.x,f.y,U.x,U.y,r.x,r.y)}if(t){const t=C;C=E,E=t}break}case 1:{const t=D<0;let e,r;if(t){const t=C;C=E,E=t,e=Z,r=M}else e=M,r=Z;const o=t?u(this._inner,N):a(this._inner,N);let l,h;c?(l=t?x(this._innerPrev,B):s(this._innerPrev,B),h=t?s(this._innerNext,U):x(this._innerNext,U)):(l=o,h=o);const v=t?s(this._roundStart,B):x(this._roundStart,B),_=t?x(this._roundEnd,U):s(this._roundEnd,U),d=P(l.x,l.y,-B.x,-B.y,e.x,e.y),p=P(v.x,v.y,-B.x,-B.y,r.x,r.y);if(n)break;const T=this._writeVertex(m,L,V,S,-B.x,-B.y,0,0,0,0,j);c||this._writeTriangle(C,E,T);const g=u(this._outer,o),A=this._writeVertex(m,L,V,S,U.x,U.y,_.x,_.y,r.x,r.y,j);let b,R;const F=i>2;if(F){let e;i!==Number.MAX_VALUE?(g.x/=i,g.y/=i,e=f(B,g),e=(i*(e*e-1)+1)/e):e=-1,b=t?s(this._startBreak,B):x(this._startBreak,B),b.x+=B.x*e,b.y+=B.y*e,R=t?x(this._endBreak,U):s(this._endBreak,U),R.x+=U.x*e,R.y+=U.y*e}y(k,g,-B.x,-B.y);const z=this._writeVertex(m,L,V,S,-B.x,-B.y,g.x,g.y,k.x,k.y,j);y(k,g,U.x,U.y);const O=w?this._writeVertex(m,L,V,S,U.x,U.y,g.x,g.y,k.x,k.y,j):z,W=T,I=w?this._writeVertex(m,L,V,S,U.x,U.y,0,0,0,0,j):T;let Y=-1,q=-1;if(F&&(y(k,b,-B.x,-B.y),Y=this._writeVertex(m,L,V,S,-B.x,-B.y,b.x,b.y,k.x,k.y,j),y(k,R,U.x,U.y),q=this._writeVertex(m,L,V,S,U.x,U.y,R.x,R.y,k.x,k.y,j)),w?F?(this._writeTriangle(W,p,Y),this._writeTriangle(W,Y,z),this._writeTriangle(I,O,q),this._writeTriangle(I,q,A)):(this._writeTriangle(W,p,z),this._writeTriangle(I,O,A)):F?(this._writeTriangle(T,p,Y),this._writeTriangle(T,Y,q),this._writeTriangle(T,q,A)):(this._writeTriangle(T,p,z),this._writeTriangle(T,O,A)),c?(C=this._writeVertex(m,L,V,S,U.x,U.y,h.x,h.y,e.x,e.y,j),E=A):(C=w?this._writeVertex(m,L,V,S,U.x,U.y,h.x,h.y,e.x,e.y,j):d,this._writeTriangle(C,I,A),E=A),t){const t=C;C=E,E=t}break}}}}}}}]);
|