@arcgis/core 4.30.0-next.20240605 → 4.30.0-next.20240607
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/README.md +1 -1
- package/arcade/functions/centroid.js +1 -1
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/0062b5fc83fc67d813e0.js +1 -0
- package/assets/esri/core/workers/chunks/{288fdc4a4746d6b81687.js → 4468c2c3b489782faa5c.js} +1 -1
- package/assets/esri/core/workers/chunks/6ad7b5817a9594689716.js +1 -0
- package/assets/esri/core/workers/chunks/733a117cb420316751b9.js +1 -0
- package/assets/esri/core/workers/chunks/888ad3cf5eaa472731be.js +1 -0
- package/assets/esri/core/workers/chunks/{342426c8a8c9f5f84811.js → b62e942e675d5770ea24.js} +1 -1
- package/assets/esri/core/workers/chunks/{4faf7055457c04dc9fc1.js → cd03ad7dc45fbbeb1a2f.js} +1 -1
- package/assets/esri/rest/knowledgeGraph/wasmInterface/arcgis-knowledge-client-core-simd.wasm +0 -0
- package/assets/esri/rest/knowledgeGraph/wasmInterface/arcgis-knowledge-client-core.wasm +0 -0
- package/assets/esri/themes/base/widgets/_BasemapLayerList.scss +8 -0
- package/assets/esri/themes/base/widgets/_CatalogLayerList.scss +8 -0
- package/assets/esri/themes/base/widgets/_LayerList.scss +8 -0
- package/assets/esri/themes/base/widgets/_Print.scss +12 -0
- package/assets/esri/themes/base/widgets/_TableList.scss +8 -0
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/interfaces.d.ts +140 -28
- package/layers/CatalogLayer.js +1 -1
- package/layers/knowledgeGraph/KnowledgeGraphSublayer.js +1 -1
- package/layers/support/Sublayer.js +1 -1
- package/layers/support/arcgisLayers.js +1 -1
- package/package.json +1 -1
- package/smartMapping/renderers/size.js +1 -1
- package/support/elevationInfoUtils.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/support/styleUtils.js +1 -1
- package/views/3d/analysis/Viewshed/FieldOfViewManipulation.js +1 -1
- package/views/3d/analysis/Viewshed/ScaleOrientManipulation.js +1 -1
- package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
- package/views/3d/interactive/editingTools/manipulatorUtils.js +1 -1
- package/views/3d/interactive/editingTools/originGeometryVisualElementUtils.js +1 -1
- package/views/3d/layers/BuildingSceneLayerView3D.js +1 -1
- package/views/3d/layers/TiledLayerView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
- package/views/3d/layers/support/FeatureTileVisibility3D.js +1 -1
- package/views/3d/state/NearFarHeuristic.js +1 -1
- package/views/3d/terrain/OverlayRenderer.js +1 -1
- package/views/3d/webgl-engine/collections/Component/ElevationAgnosticBVH.js +1 -1
- package/views/3d/webgl-engine/effects/RenderPluginManager.js +1 -1
- package/views/3d/webgl-engine/lib/SortedRenderGeometryRenderer.js +1 -1
- package/webdoc/support/webdocSaveUtils.js +1 -1
- package/widgets/BasemapLayerList/css.js +1 -1
- package/widgets/BasemapLayerList.js +1 -1
- package/widgets/CatalogLayerList/css.js +1 -1
- package/widgets/CatalogLayerList.js +1 -1
- package/widgets/Feature/support/featureUtils.js +1 -1
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/FeatureTable/FieldColumn.js +1 -1
- package/widgets/FeatureTable/Grid/Column.js +1 -1
- package/widgets/FeatureTable/Grid/GridViewModel.js +1 -1
- package/widgets/FeatureTable/RelationshipColumn.js +1 -1
- package/widgets/FeatureTable/support/FeatureStore.js +1 -1
- package/widgets/FeatureTable/support/tableUtils.js +1 -1
- package/widgets/FeatureTable.js +1 -1
- package/widgets/Features/FeaturesViewModel.js +1 -1
- package/widgets/LayerList/css.js +1 -1
- package/widgets/LayerList.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/PanoramicViewer/PanoramicViewerViewModel.js +1 -1
- package/widgets/Print/PrintViewModel.js +1 -1
- package/widgets/Print.js +1 -1
- package/widgets/TableList/css.js +1 -1
- package/widgets/TableList.js +1 -1
- package/widgets/support/legacyIcon.js +1 -1
- package/assets/esri/core/workers/chunks/9f2d8940da48c864b2ca.js +0 -1
- package/assets/esri/core/workers/chunks/d03ada1212b13e76bff4.js +0 -1
- package/assets/esri/core/workers/chunks/de4f0da054e8a798dfbf.js +0 -1
- package/assets/esri/core/workers/chunks/e21d72debf45c5a33520.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6107,9377,3069,9062],{70668:(e,t,r)=>{r.d(t,{A:()=>y});var i=r(90237),n=r(69540),s=r(25482),o=r(88930),l=r(10107),a=(r(44208),r(53966),r(87811),r(93223)),d=r(40608),u=r(73133);let p=class extends((0,n.O)(s.oY)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,i._)([(0,a.e)(u.j,{nonNullable:!0})],p.prototype,"unit",void 0),(0,i._)([(0,l.MZ)({type:Number,json:{write:!0},nonNullable:!0})],p.prototype,"value",void 0),p=(0,i._)([(0,d.$)("esri.TimeInterval")],p);const y=p},32587:(e,t,r)=>{r.d(t,{A:()=>s});var i=r(62788),n=r(95488);class s{constructor(e){this._observable=new n.I,this._map=new Map(e)}get size(){return(0,i.gc)(this._observable),this._map.size}clear(){this._map.size>0&&(this._map.clear(),this._observable.notify())}delete(e){const t=this._map.delete(e);return t&&this._observable.notify(),t}entries(){return(0,i.gc)(this._observable),this._map.entries()}forEach(e,t){(0,i.gc)(this._observable),this._map.forEach(((r,i)=>e.call(t,r,i,this)),t)}get(e){return(0,i.gc)(this._observable),this._map.get(e)}has(e){return(0,i.gc)(this._observable),this._map.has(e)}keys(){return(0,i.gc)(this._observable),this._map.keys()}set(e,t){return this._map.set(e,t),this._observable.notify(),this}values(){return(0,i.gc)(this._observable),this._map.values()}[Symbol.iterator](){return(0,i.gc)(this._observable),this._map[Symbol.iterator]()}get[Symbol.toStringTag](){return this._map[Symbol.toStringTag]}}},44794:(e,t,r)=>{r.d(t,{v:()=>l});var i=r(4718),n=r(62788),s=r(95488);class o{constructor(e,t){this._observable=new s.I,this._value=e,this._equalityFunction=t}get value(){return(0,n.gc)(this._observable),this._value}set value(e){this._equalityFunction(e,this._value)||(this._value=e,this._observable.notify())}mutate(e){e(this._value),this._observable.notify()}}function l(e,t=i.gh){return new o(e,t)}},39516:(e,t,r)=>{async function i(e,t){const{WhereClause:i}=await Promise.all([r.e(835),r.e(4800)]).then(r.bind(r,50835));return i.create(e,t)}function n(e,t){return"1=1"===e?t??e:"1=1"===t?e??t:null!=e&&""!==e?null!=t&&""!==t?`(${e}) AND (${t})`:e:t}r.d(t,{G:()=>i,m:()=>n})},3330:(e,t,r)=>{r.d(t,{GB:()=>n,Qo:()=>o,Y4:()=>s});var i=r(96285);class n{}function s(e){return e instanceof i.bo?e===n.instance:"unknown"===e?.toString().toLowerCase()}function o(e){return s(e)?n.instance:e}n.instance=new i.oh("Etc/UTC")},13069:(e,t,r)=>{r.d(t,{lk:()=>n,vD:()=>o,yS:()=>s});const i="randomUUID"in crypto;function n(){if(i)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function s(){return`{${n().toUpperCase()}}`}function o(){return`{${n()}}`}},70328:(e,t,r)=>{r.d(t,{BI:()=>f,Ej:()=>u,Hq:()=>d,Ie:()=>h,Jt:()=>m,Ne:()=>p,RF:()=>l,aI:()=>_,fA:()=>s,hZ:()=>c,iT:()=>a,is:()=>g,qv:()=>v,vI:()=>y,v_:()=>w,vt:()=>n,w1:()=>o});var i=r(5443);function n(e=w){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function s(e,t,r,i,s,o,l=n()){return l[0]=e,l[1]=t,l[2]=r,l[3]=i,l[4]=s,l[5]=o,l}function o(e,t){const r=isFinite(e[2])||isFinite(e[5]);return new i.A(r?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function l(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function a(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function d(e,t,r=0,i=t.length/3){let n=e[0],s=e[1],o=e[2],l=e[3],a=e[4],d=e[5];for(let e=0;e<i;e++)n=Math.min(n,t[r+3*e]),s=Math.min(s,t[r+3*e+1]),o=Math.min(o,t[r+3*e+2]),l=Math.max(l,t[r+3*e]),a=Math.max(a,t[r+3*e+1]),d=Math.max(d,t[r+3*e+2]);e[0]=n,e[1]=s,e[2]=o,e[3]=l,e[4]=a,e[5]=d}function u(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function p(e,t,r=e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r!==e&&(r[3]=e[3],r[4]=e[4],r[5]=e[5]),r}function y(e,t,r=e){return r[3]=t[0],r[4]=t[1],r[5]=t[2],r!==e&&(r[0]=e[0],r[1]=e[1],r[2]=e[2]),e}function c(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function h(e){return e?c(e,v):n(v)}function m(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function f(e,t,r,i,n){return e[0]=t,e[1]=r,e[2]=Number.NEGATIVE_INFINITY,e[3]=i,e[4]=n,e[5]=Number.POSITIVE_INFINITY,e}function g(e){return 6===e.length}function _(e,t,r){if(null==e||null==t)return e===t;if(!g(e)||!g(t))return!1;if(r){for(let i=0;i<e.length;i++)if(!r(e[i],t[i]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}r(19419);const v=[1/0,1/0,1/0,-1/0,-1/0,-1/0],w=[0,0,0,0,0,0];n()},79003:(e,t,r)=>{r.r(t),r.d(t,{default:()=>ue});var i=r(90237),n=r(78888),s=r(5503),o=r(49186),l=r(91869),a=r(92071),d=r(74887),u=r(84952),p=r(10107),y=(r(44208),r(53966),r(87811),r(40608)),c=r(4146),h=r(36563),m=r(55359),f=r(32587),g=r(36708),_=r(44794),v=r(56507),w=r(63074),b=r(25036),M=r(10873),F=r(91880),x=r(1873);let Z=class extends((0,b.j)((0,w.dM)((0,a.P)(c.A)))){constructor(e){super(e),this._layerCache=new m.q(20,(e=>e.destroy())),this._oidToReference=new f.A,this._layerToReference=new Map,this.layers=new s.A,this.maximumVisibleSublayers=10,this.opacity=1,this.parent=null,this.persistenceEnabled=!0,this.title="Layers in view",this.type="catalog-dynamic-group",this.visible=!0}initialize(){this.addHandles([this.layers.on("after-add",(({item:e})=>{e.parent=this})),this.layers.on("after-remove",(({item:e})=>{e.parent=null})),(0,g.wB)((()=>this._orderBy),(()=>{this._updateLayerSortValues(),this._sortAllLayers()}))])}load(e){return this.addResolvingPromise(this.parent.load()),Promise.resolve(this)}destroy(){this._layerCache.destroy(),this._oidToReference.clear(),this._layerToReference.clear()}get _orderBy(){return this.parent?this.parent.orderBy?.find((e=>!e.valueExpression&&e.field))??new F.A({field:this.parent.objectIdField}):null}get _referenceComparator(){const e=this._orderBy;if(!this.parent||!e)return()=>0;const t=this.parent.fieldsIndex.get(e.field),r=(0,x.FM)(t?.toJSON().type,"descending"===e.order),i=(0,x.FM)("esriFieldTypeOID","descending"===e.order);return(e,t)=>r(t.sortValue,e.sortValue)||i(t.objectId,e.objectId)}get fullExtent(){return this.parent?.fullExtent??null}get updating(){return(0,l.Bs)(this._oidToReference,(e=>null!=e.pending))}acquireLayer(e){if(this.destroyed)return(0,h.hA)();const t=this._getLayerReference(e);return t.count++,(0,h.hA)((()=>{t.count--,t.count||this._destroyLayerReference(t)}))}_getLayerReference(e){const t=e.getObjectId();return(0,l.tE)(this._oidToReference,t,(()=>{const t=e.getObjectId(),r=`${t}`,i=e.getAttribute(this.parent.itemSourceField),n=new I(e,t,i),s=this._layerCache.pop(r);return s?(this._addLayer(n,s),n):(n.pending=this.parent.createLayerFromFootprint(e).then((e=>{n.count?this._addLayer(n,e):(this.destroyed||this._layerCache.get(r)||this._layerCache.put(r,e),n.layer=null)})).catch((()=>{})).finally((()=>{n.pending=null})),n)}))}_destroyLayerReference(e){e.layer&&(this._layerToReference.delete(e.layer),this.layers.remove(e.layer),this.destroyed?e.layer.destroy():this._layerCache.put(`${e.objectId}`,e.layer),e.layer=null),this._oidToReference.delete(e.objectId)}_addLayer(e,t){e.layer=t,t.persistenceEnabled=!1,this._layerToReference.set(t,e),this._updateLayerSortValue(e),this.layers.add(t),this._sortAllLayers()}_updateLayerSortValues(){for(const e of this._layerToReference.values())this._updateLayerSortValue(e)}_updateLayerSortValue(e){this._orderBy&&(e.sortValue=e.footprint.getAttribute(this._orderBy.field))}_sortAllLayers(){this.layers.sort(((e,t)=>this._referenceComparator(this._layerToReference.get(e),this._layerToReference.get(t))))}};(0,i._)([(0,p.MZ)()],Z.prototype,"_orderBy",null),(0,i._)([(0,p.MZ)({readOnly:!0})],Z.prototype,"_referenceComparator",null),(0,i._)([(0,p.MZ)({type:["show","hide","hide-children"],json:{write:!0}})],Z.prototype,"listMode",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],Z.prototype,"fullExtent",null),(0,i._)([(0,p.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],Z.prototype,"id",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],Z.prototype,"layers",void 0),(0,i._)([(0,p.MZ)({type:v.jz,range:{min:0,max:50},json:{write:!0,default:10}})],Z.prototype,"maximumVisibleSublayers",void 0),(0,i._)([(0,p.MZ)(M.ke)],Z.prototype,"opacity",void 0),(0,i._)([(0,p.MZ)({clonable:!1})],Z.prototype,"parent",void 0),(0,i._)([(0,p.MZ)({type:String,nonNullable:!0,json:{write:{ignoreOrigin:!0,isRequired:!0}}})],Z.prototype,"title",void 0),(0,i._)([(0,p.MZ)({json:{read:!1}})],Z.prototype,"type",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],Z.prototype,"updating",null),(0,i._)([(0,p.MZ)({type:Boolean,json:{name:"visibility",write:!0}})],Z.prototype,"visible",void 0),Z=(0,i._)([(0,y.$)("esri.layers.catalog.CatalogDynamicGroupLayer")],Z);const T=Z;class I{constructor(e,t,r){this.footprint=e,this.objectId=t,this.itemSource=r,this.count=0,this.layer=null,this.sortValue=void 0,this._pending=(0,_.v)(null)}get pending(){return this._pending.value}set pending(e){this._pending.value=e}}var S=r(13874),O=(r(86162),r(94409),r(65345),r(42980),r(39290),r(92438),r(96576)),j=(r(93618),r(65494),r(15036)),E=r(4718),A=r(35666),R=r(4206),N=r(87718),L=r(30524),V=r(81457),D=r(39383),B=r(30291),P=r(94985);let $=class extends((0,b.j)((0,N.F)((0,w.dM)((0,a.P)(c.A))))){constructor(e){super(e),this.charts=null,this.editingEnabled=!0,this.elevationInfo=null,this.formTemplate=null,this.labelingInfo=null,this.labelsVisible=!0,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.opacity=1,this.parent=null,this.persistenceEnabled=!0,this.popupEnabled=!0,this.popupTemplate=null,this.title="Footprints",this.type="catalog-footprint",this.visible=!0}load(e){return this.addResolvingPromise(this._doLoad(e)),Promise.resolve(this)}async _doLoad(e){await this.parent.load(e),(0,L.yp)(this.renderer,this.fieldsIndex),this.addHandles([this.parent.on("apply-edits",(e=>this.emit("apply-edits",e))),this.parent.on("edits",(e=>this.emit("edits",e))),this.parent.on("refresh",(e=>this.emit("refresh",e)))])}get apiKey(){return this.parent?.apiKey}get capabilities(){return this.parent?.capabilities}get customParameters(){return this.parent?.customParameters}get dateFieldsTimeZone(){return this.parent?.dateFieldsTimeZone??null}get datesInUnknownTimezone(){return this.parent?.datesInUnknownTimezone??!1}get definitionExpression(){return this.parent?.definitionExpression}get editingInfo(){return this.parent?.editingInfo}get effectiveCapabilities(){return this.parent?.effectiveCapabilities}get createQueryVersion(){return this.parent?.createQueryVersion}get defaultPopupTemplate(){return this.createPopupTemplate()}get displayField(){return this.parent?.displayField}get effectiveEditingEnabled(){return!1}get fields(){return this.parent?.fields}get fieldsIndex(){return this.parent?.fieldsIndex}get fullExtent(){return this.parent?.fullExtent}get geometryFieldsInfo(){return this.parent?.geometryFieldsInfo}get geometryType(){return this.parent?.geometryType}get globalIdField(){return this.parent?.globalIdField}get hasM(){return this.parent?.hasM??!1}get hasZ(){return this.parent?.hasZ??!1}get objectIdField(){return this.parent?.objectIdField}get orderBy(){return this.parent?.orderBy??null}get outFields(){return this.parent?.outFields}get parsedUrl(){return this.parent?.parsedUrl??null}get preferredTimeZone(){return this.parent?.preferredTimeZone??null}set renderer(e){(0,L.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){return this._isOverridden("renderer")?this._get("renderer"):function(){const e=new P.A({style:"solid",color:[0,0,0,0],outline:{style:"solid",color:[96,96,96,.75],width:.75}});return new O.A({symbol:e})}()}get returnM(){return this.parent?.returnM}get returnZ(){return this.parent?.returnZ}get source(){return this.parent?.source}get timeExtent(){return this.parent?.timeExtent}get timeInfo(){return this.parent?.timeInfo}get timeOffset(){return this.parent?.timeOffset}get typeIdField(){return this.parent?.typeIdField}get types(){return this.parent?.types}get useViewTime(){return this.parent?.useViewTime??!0}get version(){return this.parent?.version}async applyEdits(e,t){return await this.load(),this.parent.applyEdits(e,t)}createPopupTemplate(e){const t={fields:this.fields,objectIdField:this.objectIdField,title:this.title};return(0,B.tn)(t,e)}createQuery(){return this.parent?.createQuery()}getField(e){return this.parent?.getField(e)}getFieldDomain(e,t){return this.parent?.getFieldDomain(e,t)}async queryExtent(e,t){return await this.load(),this.parent.queryExtent(e,t)}async queryFeatures(e,t){return await this.load(),this.parent.queryFeatures(e,t)}async queryFeatureCount(e,t){return await this.load(),this.parent.queryFeatureCount(e,t)}async queryObjectIds(e,t){return await this.load(),this.parent.queryObjectIds(e,t)}};(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"apiKey",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"capabilities",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"customParameters",null),(0,i._)([(0,p.MZ)()],$.prototype,"dateFieldsTimeZone",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"datesInUnknownTimezone",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"definitionExpression",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"editingInfo",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"effectiveCapabilities",null),(0,i._)([(0,p.MZ)({json:{origins:{"web-scene":{write:!1}},write:!0}})],$.prototype,"charts",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"createQueryVersion",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"defaultPopupTemplate",null),(0,i._)([(0,p.MZ)()],$.prototype,"displayField",null),(0,i._)([(0,p.MZ)({type:Boolean,nonNullable:!0,json:{name:"enableEditing",write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],$.prototype,"editingEnabled",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"effectiveEditingEnabled",null),(0,i._)([(0,p.MZ)((()=>{const e=(0,E.o8)(M.Yj);return e.json.origins["web-map"]={read:!1,write:!1},e})())],$.prototype,"elevationInfo",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"fields",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"fieldsIndex",null),(0,i._)([(0,p.MZ)({type:R.A,json:{name:"formInfo",write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],$.prototype,"formTemplate",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"fullExtent",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"geometryFieldsInfo",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"geometryType",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"globalIdField",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"hasM",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"hasZ",null),(0,i._)([(0,p.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],$.prototype,"id",void 0),(0,i._)([(0,p.MZ)({type:[V.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:D.w,write:!0}})],$.prototype,"labelingInfo",void 0),(0,i._)([(0,p.MZ)(M.kF)],$.prototype,"labelsVisible",void 0),(0,i._)([(0,p.MZ)(M.fV)],$.prototype,"legendEnabled",void 0),(0,i._)([(0,p.MZ)({type:["show","hide"],json:{write:!0}})],$.prototype,"listMode",void 0),(0,i._)([(0,p.MZ)((()=>{const e=(0,E.o8)(M.hG);return e.json.origins.service.read=!1,e})())],$.prototype,"maxScale",void 0),(0,i._)([(0,p.MZ)((()=>{const e=(0,E.o8)(M.hn);return e.json.origins.service.read=!1,e})())],$.prototype,"minScale",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"objectIdField",null),(0,i._)([(0,p.MZ)(M.ke)],$.prototype,"opacity",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"orderBy",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"outFields",null),(0,i._)([(0,p.MZ)({clonable:!1})],$.prototype,"parent",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"parsedUrl",null),(0,i._)([(0,p.MZ)(M.M6)],$.prototype,"popupEnabled",void 0),(0,i._)([(0,p.MZ)({type:S.A,json:{name:"popupInfo",write:!0}})],$.prototype,"popupTemplate",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"preferredTimeZone",null),(0,i._)([(0,p.MZ)({types:j.H,json:{origins:{"web-scene":{types:j.X}},name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy(e,t){return{ignoreOrigin:this.originIdOf(t)<A.Gr.PORTAL_ITEM}}}}})],$.prototype,"renderer",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"returnM",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"returnZ",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"source",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"timeExtent",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"timeInfo",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"timeOffset",null),(0,i._)([(0,p.MZ)({type:String,nonNullable:!0,json:{write:{ignoreOrigin:!0,isRequired:!0}}})],$.prototype,"title",void 0),(0,i._)([(0,p.MZ)({json:{read:!1}})],$.prototype,"type",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"typeIdField",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"types",null),(0,i._)([(0,p.MZ)({readOnly:!0})],$.prototype,"useViewTime",null),(0,i._)([(0,p.MZ)({type:Boolean,json:{name:"visibility",write:!0}})],$.prototype,"visible",void 0),$=(0,i._)([(0,y.$)("esri.layers.catalog.CatalogFootprintLayer")],$);const q=$;var U=r(72593),C=r(52136),G=r(18768),J=r(69208),z=r(47685),k=r(87796),Q=r(16131),Y=r(32756),K=r(8303),H=r(54310),X=r(82935),W=r(15426),ee=r(33143),te=r(17036),re=r(4513),ie=r(91908),ne=r(20655),se=r(80812),oe=r(61956);const le=(0,te.p)();function ae(e,t,r,i){const n=e.write({},i);(function(e){if(null==e)return!0;const t=Object.keys(e);return!t.length||1===t.length&&"id"===t[0]})(n)||(t[r]=n)}let de=class extends((0,k.j)((0,z.w6)((0,w.dM)((0,Y.f)((0,X.e)((0,b.j)((0,H.J)((0,G.b)((0,Q.q)((0,K.A)((0,a.P)((0,J.d)((0,C.p)(c.A)))))))))))))){constructor(e){super(e),this._portals=new Map,this._layerToFootprint=new WeakMap,this.drawOrderField="cd_draworder",this.dynamicGroupLayer=new T({parent:this}),this.elevationInfo=null,this.fields=null,this.fieldsIndex=null,this.floorInfo=null,this.footprintLayer=new q({parent:this}),this.itemNameField="cd_itemname",this.itemSourceField="cd_itemsource",this.itemTypeField="cd_itemtype",this.layers=new s.A([this.dynamicGroupLayer,this.footprintLayer]),this.maxScaleField="cd_maxscale",this.minScaleField="cd_minscale",this.orderBy=null,this.outFields=null,this.supportedSourceTypes=new Set(["Catalog Layer"]),this.source=new U.default({layer:this,supportedSourceTypes:this.supportedSourceTypes}),this.type="catalog",this.typeIdField=null,this.types=null}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Feature Service"]},e).catch(d.QP).then((async()=>{const{url:e,source:r,portalItem:i}=this;if(!e)throw new o.A("catalog-layer:missing-url","Catalog layer must be created with a url");if(null==this.layerId){const r=await this._fetchFirstValidLayerId(t);if(null==r)throw new o.A("catalog-layer:missing-layerId","There is no Catalog Layer in the service",{service:e});this.layerId=r}await r.load({signal:t});const{sourceJSON:n}=r;n&&(this.sourceJSON=n,this.read(n,{origin:"service",portalItem:i,portal:i?.portal,url:this.parsedUrl}))})).then((()=>{const e=[this.itemNameField,this.itemSourceField,this.itemTypeField,this.minScaleField,this.maxScaleField],t=e.filter((e=>!this.fieldsIndex.has(e)));if(t.length)throw new o.A("catalog-layer:missing-fields","There are missing fields to operate properly",{requiredFields:e,missingFields:t})})).then((()=>(0,W.VA)(this,"load",e)));return this.addResolvingPromise(r),Promise.resolve(this)}destroy(){this.footprintLayer.destroy(),this.dynamicGroupLayer.destroy();for(const e of this._portals.values())e.destroy();this._portals.clear()}get createQueryVersion(){return this.commitProperty("definitionExpression"),this.commitProperty("timeExtent"),this.commitProperty("timeOffset"),this.commitProperty("geometryType"),this.commitProperty("capabilities"),(this._get("createQueryVersion")??0)+1}get editingEnabled(){return this.loaded&&null!=this.capabilities&&this.capabilities.operations.supportsEditing&&this.userHasEditingPrivileges}get effectiveEditingEnabled(){return!1}get parsedUrl(){const e=(0,u.An)(this.url);return null!=e&&null!=this.layerId&&(e.path=(0,u.fj)(e.path,this.layerId.toString())),e}async applyEdits(e,t){return(0,W.ct)(this,e,t)}on(e,t){return super.on(e,t)}async createLayerFromFootprint(e){const t=await this._createLayer(e);return this._configureLayer(t,e),this._layerToFootprint.set(t,e),t}createFootprintFromLayer(e){return this._layerToFootprint.get(e)?.clone()}createQuery(){const e=new oe.A,t=this.capabilities?.query;e.returnGeometry=!0,t&&(e.compactGeometryEnabled=t.supportsCompactGeometry,e.defaultSpatialReferenceEnabled=t.supportsDefaultSpatialReference),e.outFields=["*"];const{timeOffset:r,timeExtent:i}=this;return e.timeExtent=null!=r&&null!=i?i.offset(-r.value,r.unit):i||null,e.where=this.definitionExpression||"1=1",e}getFeatureType(e){return(0,W.xd)(this.types,this.typeIdField,e)}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){const r=t?.feature,i=this.getFeatureType(r);if(i){const t=i.domains&&i.domains[e];if(t&&"inherited"!==t.type)return t}return this.getField(e)?.domain}async hasDataChanged(){return(0,W.jp)(this)}async queryFeatures(e,t){const r=await this.load(),i=await r.source.queryFeatures(oe.A.from(e)??r.createQuery(),t);if(i?.features)for(const e of i.features)e.layer=e.sourceLayer=r.footprintLayer;return i}async queryObjectIds(e,t){return(await this.load()).source.queryObjectIds(oe.A.from(e)??this.createQuery(),t)}async queryFeatureCount(e,t){return(await this.load()).source.queryFeatureCount(oe.A.from(e)??this.createQuery(),t)}async queryExtent(e,t){return(await this.load()).source.queryExtent(oe.A.from(e)??this.createQuery(),t)}serviceSupportsSpatialReference(e){return this.loaded&&(0,ie.D)(this,e)}read(e,t){if(super.read(e,t),e){const{footprintLayer:r,dynamicGroupLayer:i}=e;r&&this.footprintLayer.read(r,t),i&&this.dynamicGroupLayer.read(i,t)}}async _fetchFirstValidLayerId(e){const{data:t}=await(0,n.A)(this.url,{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e});if(Array.isArray(t?.layers))return t.layers.find((({type:e})=>this.supportedSourceTypes.has(e)))?.id}async _createLayer(e){const t=e.getAttribute(this.itemSourceField);if(!t)throw new o.A("catalog-layer:item-source-missing",`The footprint is missing the "${this.itemSourceField}" attribute`);const r=JSON.parse(t);if(function(e){return"object"==typeof e&&null!=e&&"itemId"in e&&"portalUrl"in e}(r)){const{itemId:e,portalUrl:t}=r,i=(0,l.tE)(this._portals,t,(()=>new ne.A({url:t})));return c.A.fromPortalItem(new se.default({id:e,portal:i}))}return function(e){return"object"==typeof e&&null!=e&&"url"in e}(r)?c.A.fromArcGISServerUrl({url:r.url}):new(await re.S.UnsupportedLayer())}_configureLayer(e,t){const r=t.getAttribute(this.itemNameField);r&&(e.title=r);const i=t.getAttribute(this.maxScaleField);null!=i&&"maxScale"in e&&(e.maxScale=i);const n=t.getAttribute(this.minScaleField);null!=n&&"minScale"in e&&(e.minScale=n)}};(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"createQueryVersion",null),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"drawOrderField",void 0),(0,i._)([(0,p.MZ)({type:T,readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,writer:ae}}})],de.prototype,"dynamicGroupLayer",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"editingEnabled",null),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"effectiveEditingEnabled",null),(0,i._)([(0,p.MZ)({json:{origins:{"web-scene":{name:"layerDefinition.elevationInfo",read:!1,write:!1}}}})],de.prototype,"elevationInfo",void 0),(0,i._)([(0,p.MZ)({...le.fields,readOnly:!0,json:{origins:{service:{read:!0}},read:!1}})],de.prototype,"fields",void 0),(0,i._)([(0,p.MZ)(le.fieldsIndex)],de.prototype,"fieldsIndex",void 0),(0,i._)([(0,p.MZ)({json:{origins:{"web-scene":{name:"layerDefinition.floorInfo",read:!1,write:!1}}}})],de.prototype,"floorInfo",void 0),(0,i._)([(0,p.MZ)({type:q,readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,writer:ae}}})],de.prototype,"footprintLayer",void 0),(0,i._)([(0,p.MZ)(M.id)],de.prototype,"id",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"itemNameField",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"itemSourceField",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"itemTypeField",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"layers",void 0),(0,i._)([(0,p.MZ)({type:["show","hide","hide-children"]})],de.prototype,"listMode",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"maxScaleField",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"minScaleField",void 0),(0,i._)([(0,p.MZ)({value:"CatalogLayer",type:["CatalogLayer"]})],de.prototype,"operationalLayerType",void 0),(0,i._)([(0,p.MZ)({json:{origins:{"web-scene":{name:"layerDefinition.orderBy",write:!0,read:!0}}}})],de.prototype,"orderBy",void 0),(0,i._)([(0,p.MZ)(le.outFields)],de.prototype,"outFields",void 0),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"parsedUrl",null),(0,i._)([(0,p.MZ)({readOnly:!0})],de.prototype,"source",void 0),(0,i._)([(0,p.MZ)({json:{read:!1}})],de.prototype,"type",void 0),(0,i._)([(0,p.MZ)({type:String})],de.prototype,"typeIdField",void 0),(0,i._)([(0,p.MZ)({type:[ee.A]})],de.prototype,"types",void 0),de=(0,i._)([(0,y.$)("esri.layers.CatalogLayer")],de);const ue=de},87718:(e,t,r)=>{r.d(t,{F:()=>I,Y:()=>T});var i,n=r(90237),s=r(10107),o=(r(44208),r(53966),r(87811),r(40608)),l=r(49186),a=r(25482),d=r(93637),u=r(76369),p=r(59456),y=r(60945),c=r(66552),h=r(4718),m=r(61956);const f=new c.J({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),g=new c.J({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let _=i=class extends a.oY{constructor(e){super(e),this.where=null,this.geometry=null,this.spatialRelationship="intersects",this.distance=void 0,this.objectIds=null,this.units=null,this.timeExtent=null}createQuery(e={}){const{where:t,geometry:r,spatialRelationship:i,timeExtent:n,objectIds:s,units:o,distance:l}=this;return new m.A({geometry:(0,h.o8)(r),objectIds:(0,h.o8)(s),spatialRelationship:i,timeExtent:(0,h.o8)(n),where:t,units:o,distance:l,...e})}clone(){const{where:e,geometry:t,spatialRelationship:r,timeExtent:n,objectIds:s,units:o,distance:l}=this;return new i({geometry:(0,h.o8)(t),objectIds:(0,h.o8)(s),spatialRelationship:r,timeExtent:(0,h.o8)(n),where:e,units:o,distance:l})}};(0,n._)([(0,s.MZ)({type:String,json:{write:!0}})],_.prototype,"where",void 0),(0,n._)([(0,s.MZ)({types:p.yR,json:{write:!0}})],_.prototype,"geometry",void 0),(0,n._)([(0,s.MZ)({type:f.apiValues,json:{name:"spatialRel",read:{reader:f.read},write:{allowNull:!1,writer:f.write,overridePolicy(){return{enabled:null!=this.geometry}}}}})],_.prototype,"spatialRelationship",void 0),(0,n._)([(0,s.MZ)({type:Number,json:{write:{overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],_.prototype,"distance",void 0),(0,n._)([(0,s.MZ)({type:[Number],json:{write:!0}})],_.prototype,"objectIds",void 0),(0,n._)([(0,s.MZ)({type:g.apiValues,json:{read:g.read,write:{writer:g.write,overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],_.prototype,"units",void 0),(0,n._)([(0,s.MZ)({type:y.A,json:{write:!0}})],_.prototype,"timeExtent",void 0),_=i=(0,n._)([(0,o.$)("esri.layers.support.FeatureFilter")],_);const v=_;var w;const b={read:{reader:u.LF},write:{writer:u.M9,overridePolicy(){return{allowNull:null!=this.excludedEffect,isRequired:null==this.excludedEffect}}}},M={read:{reader:u.LF},write:{writer:u.M9,overridePolicy(){return{allowNull:null!=this.includedEffect,isRequired:null==this.includedEffect}}}},F={name:"showExcludedLabels",default:!0};let x=w=class extends a.oY{constructor(e){super(e),this.filter=null,this.includedEffect=null,this.excludedEffect=null,this.excludedLabelsVisible=!1}write(e,t){const r=super.write(e,t);if(t?.origin){if(r.filter){const e=Object.keys(r.filter);if(e.length>1||"where"!==e[0])return t.messages?.push(new l.A("web-document-write:unsupported-feature-effect","Invalid feature effect 'filter'. A filter can only contain a 'where' property",{layer:t.layer,effect:this})),null}if("showExcludedLabels"in r)return t.messages?.push(new l.A("web-document-write:unsupported-feature-effect","Invalid value for property 'excludedLabelsVisible' which should always be 'true'",{layer:t.layer,effect:this})),null}return r}clone(){return new w({filter:null!=this.filter?this.filter.clone():null,includedEffect:this.includedEffect,excludedEffect:this.excludedEffect,excludedLabelsVisible:this.excludedLabelsVisible})}};(0,n._)([(0,s.MZ)({type:v,json:{write:{allowNull:!0,writer(e,t,r,i){const n=e?.write({},i);n&&0!==Object.keys(n).length?(0,d.sM)(r,n,t):(0,d.sM)(r,null,t)}}}})],x.prototype,"filter",void 0),(0,n._)([(0,s.MZ)({json:{write:!0,origins:{"web-map":b,"portal-item":b}}})],x.prototype,"includedEffect",void 0),(0,n._)([(0,s.MZ)({json:{write:!0,origins:{"web-map":M,"portal-item":M}}})],x.prototype,"excludedEffect",void 0),(0,n._)([(0,s.MZ)({type:Boolean,json:{write:!0,name:"showExcludedLabels",origins:{"web-map":F,"portal-item":F}}})],x.prototype,"excludedLabelsVisible",void 0),x=w=(0,n._)([(0,o.$)("esri.layers.support.FeatureEffect")],x);const Z={write:{allowNull:!0}},T={type:x,json:{origins:{"web-map":Z,"portal-item":Z}}},I=e=>{let t=class extends e{constructor(){super(...arguments),this.featureEffect=null}};return(0,n._)([(0,s.MZ)(T)],t.prototype,"featureEffect",void 0),t=(0,n._)([(0,o.$)("esri.layers.mixins.FeatureEffectLayer")],t),t}},32756:(e,t,r)=>{r.d(t,{f:()=>d,n:()=>a});var i=r(90237),n=r(93637),s=r(10107),o=(r(44208),r(53966),r(87811),r(40608)),l=r(91880);const a={type:[l.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:function(e,t,r){if(!e)return null;const i=e.find((e=>!!e.field));if(!i)return null;const n=new l.A;return n.read(i,r),[n]}},write:{writer:function(e,t,r,i){const s=e.find((e=>!!e.field));s&&(0,n.sM)(r,[s.toJSON()],t)}}}},d=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,i._)([(0,s.MZ)(a)],t.prototype,"orderBy",void 0),t=(0,i._)([(0,o.$)("esri.layers.mixins.OrderedLayer")],t),t}},82935:(e,t,r)=>{r.d(t,{B:()=>c,e:()=>h});var i=r(90237),n=r(60945),s=r(70668),o=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),a=r(40608),d=r(89317),u=r(30524),p=r(96184),y=r(73133);const c={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:d.K}}},h=e=>{let t=class extends e{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const r=t.timeInfo.exportOptions;if(!r)return null;const i=r.timeOffset,n=y.j.fromJSON(r.timeOffsetUnits);return i&&n?new s.A({value:i,unit:n}):null}set timeInfo(e){(0,u.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,i._)([(0,o.MZ)({type:n.A,json:{write:!1}})],t.prototype,"timeExtent",void 0),(0,i._)([(0,o.MZ)({type:s.A})],t.prototype,"timeOffset",void 0),(0,i._)([(0,l.w)("service","timeOffset",["timeInfo.exportOptions"])],t.prototype,"readOffset",null),(0,i._)([(0,o.MZ)({value:null,type:p.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],t.prototype,"timeInfo",null),(0,i._)([(0,o.MZ)(c)],t.prototype,"useViewTime",void 0),t=(0,i._)([(0,a.$)("esri.layers.mixins.TemporalLayer")],t),t}},33143:(e,t,r)=>{r.d(t,{A:()=>c});var i=r(90237),n=r(69540),s=r(25482),o=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),a=r(40608),d=r(43937),u=r(72088),p=r(29005);let y=class extends((0,n.O)(s.oY)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,u.rS)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i._)([(0,o.MZ)({json:{write:!0}})],y.prototype,"id",void 0),(0,i._)([(0,o.MZ)({json:{write:!0}})],y.prototype,"name",void 0),(0,i._)([(0,o.MZ)({json:{write:!0}})],y.prototype,"domains",void 0),(0,i._)([(0,l.w)("domains")],y.prototype,"readDomains",null),(0,i._)([(0,d.K)("domains")],y.prototype,"writeDomains",null),(0,i._)([(0,o.MZ)({type:[p.A],json:{write:!0}})],y.prototype,"templates",void 0),y=(0,i._)([(0,a.$)("esri.layers.support.FeatureType")],y);const c=y},20437:(e,t,r)=>{r.d(t,{A:()=>f});var i,n=r(90237),s=r(66552),o=r(25482),l=r(10107),a=r(56507),d=(r(87811),r(44208),r(93223)),u=r(36005),p=r(40608),y=r(72088),c=r(98453);const h=new s.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",dateAndTime:"date-and-time",description:"description",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let m=i=class extends o.oY{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let r=null;try{r=t?JSON.parse(t):null}catch(e){}return r?.value??null}readValueType(e,{description:t}){let r=null;try{r=t?JSON.parse(t):null}catch(e){}return r?h.fromJSON(r.fieldValueType):null}clone(){return new i({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,n._)([(0,l.MZ)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,n._)([(0,l.MZ)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,n._)([(0,l.MZ)()],m.prototype,"description",void 0),(0,n._)([(0,u.w)("description")],m.prototype,"readDescription",null),(0,n._)([(0,l.MZ)({types:y.gK,json:{read:{reader:y.rS},write:!0}})],m.prototype,"domain",void 0),(0,n._)([(0,l.MZ)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,n._)([(0,l.MZ)({type:a.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],m.prototype,"length",void 0),(0,n._)([(0,l.MZ)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,n._)([(0,l.MZ)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,n._)([(0,d.e)(c.m)],m.prototype,"type",void 0),(0,n._)([(0,l.MZ)()],m.prototype,"valueType",void 0),(0,n._)([(0,u.w)("valueType",["description"])],m.prototype,"readValueType",null),(0,n._)([(0,l.MZ)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=i=(0,n._)([(0,p.$)("esri.layers.support.Field")],m);const f=m},95466:(e,t,r)=>{r.d(t,{A:()=>y});var i=r(49186),n=r(25482),s=r(53966),o=r(91869),l=r(3330),a=r(30524),d=r(56400),u=r(96285);const p=new Map;class y{static fromJSON(e){return new y(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new y(e.fields??[],f(e))}static fromLayerJSON(e){return new y(e.fields??[],f(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const r=[];for(const e of this.fields){const t=e?.name,i=h(t);if(t&&i){const n=c(t);this._fieldsMap.set(t,e),this._fieldsMap.set(n,e),this._normalizedFieldsMap.set(i,e),r.push(`${n}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,a.vE)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,a.WA)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,a.te)(e)||(0,a.Xz)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}r.sort(),this.uid=r.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,a.te)(e)||(0,a.Xz)(e)||e.nullable||void 0!==(0,a.lD)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(c(e))??this._normalizedFieldsMap.get(h(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(s.A.getLogger("esri.layers.support.FieldsIndex").error(new i.A("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),d.n$):m.has(t.type)?d.L5:null:null}getLuxonTimeZone(e){const t=this.getTimeZone(e);return t?t===d.L5?l.GB.instance:t===d.n$?u.mQ.utcInstance:(0,o.tE)(p,t,(()=>u.oh.create(t))):null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,a.OH)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,n.Wj)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function c(e){return e.trim().toLowerCase()}function h(e){return(0,a.rS)(e)?.toLowerCase()??""}const m=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function f(e){const t=new Map;if(!e.fields)return t;const r=!0===e.datesInUnknownTimezone,{timeInfo:i,editFieldsInfo:n}=e,s=(i?"startField"in i?i.startField:i.startTimeField:"")??"",o=(i?"endField"in i?i.endField:i.endTimeField:"")??"",l=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,d.ZS)(e.dateFieldsTimeReference):null,a=n?function(e){return"timeZone"in e}(n)?n.timeZone??l:n.dateFieldsTimeReference?(0,d.ZS)(n.dateFieldsTimeReference):l??d.n$:null,u=i?function(e){return"timeZone"in e}(i)?i.timeZone??l:i.timeReference?(0,d.ZS)(i.timeReference):l:null,p=new Map([[c(n?.creationDateField??""),a],[c(n?.editDateField??""),a],[c(s),u],[c(o),u]]);for(const{name:i,type:n}of e.fields)if(m.has(n))t.set(i,d.L5);else if("date"!==n&&"esriFieldTypeDate"!==n)t.set(i,null);else if(r)t.set(i,d.L5);else{const e=p.get(c(i??""))??l;t.set(i,e)}return t}},91880:(e,t,r)=>{r.d(t,{A:()=>p});var i,n=r(90237),s=r(66552),o=r(25482),l=r(10107),a=(r(44208),r(53966),r(87811),r(40608));const d=new s.J({asc:"ascending",desc:"descending"});let u=i=class extends o.oY{constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new i({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,n._)([(0,l.MZ)({type:String,json:{write:!0}})],u.prototype,"field",void 0),(0,n._)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],u.prototype,"valueExpression",void 0),(0,n._)([(0,l.MZ)({type:d.apiValues,json:{type:d.jsonValues,read:d.read,write:d.write}})],u.prototype,"order",void 0),u=i=(0,n._)([(0,a.$)("esri.layers.support.OrderByInfo")],u);const p=u},96184:(e,t,r)=>{r.d(t,{A:()=>m});var i=r(90237),n=r(60945),s=r(70668),o=r(69540),l=r(25482),a=r(10107),d=(r(44208),r(53966),r(87811),r(36005)),u=r(40608),p=r(43937),y=r(56400);function c(e,t){return s.A.fromJSON({value:e,unit:t})}let h=class extends((0,o.O)(l.oY)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?n.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?c(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?c(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,i._)([(0,a.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],h.prototype,"cumulative",void 0),(0,i._)([(0,a.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],h.prototype,"endField",void 0),(0,i._)([(0,a.MZ)({type:n.A,json:{write:{enabled:!0,allowNull:!0}}})],h.prototype,"fullTimeExtent",void 0),(0,i._)([(0,d.w)("fullTimeExtent",["timeExtent"])],h.prototype,"readFullTimeExtent",null),(0,i._)([(0,p.K)("fullTimeExtent")],h.prototype,"writeFullTimeExtent",null),(0,i._)([(0,a.MZ)({type:Boolean,json:{write:!0}})],h.prototype,"hasLiveData",void 0),(0,i._)([(0,a.MZ)({type:s.A,json:{write:{enabled:!0,allowNull:!0}}})],h.prototype,"interval",void 0),(0,i._)([(0,d.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],h.prototype,"readInterval",null),(0,i._)([(0,p.K)("interval")],h.prototype,"writeInterval",null),(0,i._)([(0,a.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],h.prototype,"startField",void 0),(0,i._)([(0,a.MZ)((0,y.P6)("timeReference",!0))],h.prototype,"timeZone",void 0),(0,i._)([(0,a.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],h.prototype,"trackIdField",void 0),(0,i._)([(0,a.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],h.prototype,"useTime",void 0),(0,i._)([(0,a.MZ)({type:[Date],json:{read:!1}})],h.prototype,"stops",void 0),h=(0,i._)([(0,u.$)("esri.layers.support.TimeInfo")],h);const m=h},72088:(e,t,r)=>{r.d(t,{rS:()=>x,gK:()=>F}),r(44208);var i,n=r(90237),s=r(4718),o=r(10107),l=(r(53966),r(93223)),a=r(40608),d=r(25482);r(87811);let u=i=class extends d.oY{constructor(e){super(e),this.name=null,this.code=null}clone(){return new i({name:this.name,code:this.code})}};(0,n._)([(0,o.MZ)({type:String,json:{write:!0}})],u.prototype,"name",void 0),(0,n._)([(0,o.MZ)({type:[String,Number],json:{write:!0}})],u.prototype,"code",void 0),u=i=(0,n._)([(0,a.$)("esri.layers.support.CodedValue")],u);const p=new(r(66552).J)({inherited:"inherited",codedValue:"coded-value",range:"range"});let y=class extends d.oY{constructor(e){super(e),this.name=null,this.type=null}};(0,n._)([(0,o.MZ)({type:String,json:{write:!0}})],y.prototype,"name",void 0),(0,n._)([(0,l.e)(p)],y.prototype,"type",void 0),y=(0,n._)([(0,a.$)("esri.layers.support.Domain")],y);const c=y;var h;let m=h=class extends c{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const r=String(e);this.codedValues.some((e=>(String(e.code)===r&&(t=e.name),!!t)))}return t}clone(){return new h({codedValues:(0,s.o8)(this.codedValues),name:this.name})}};(0,n._)([(0,o.MZ)({type:[u],json:{write:!0}})],m.prototype,"codedValues",void 0),(0,n._)([(0,l.e)({codedValue:"coded-value"})],m.prototype,"type",void 0),m=h=(0,n._)([(0,a.$)("esri.layers.support.CodedValueDomain")],m);const f=m;var g;r(49186);let _=g=class extends c{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,n._)([(0,l.e)({inherited:"inherited"})],_.prototype,"type",void 0),_=g=(0,n._)([(0,a.$)("esri.layers.support.InheritedDomain")],_);const v=_;var w;let b=w=class extends c{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new w({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,n._)([(0,o.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,r){t[r]=[this.minValue||0,e]}}}})],b.prototype,"maxValue",void 0),(0,n._)([(0,o.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,r){t[r]=[e,this.maxValue||0]}}}})],b.prototype,"minValue",void 0),(0,n._)([(0,l.e)({range:"range"})],b.prototype,"type",void 0),b=w=(0,n._)([(0,a.$)("esri.layers.support.RangeDomain")],b);const M=b,F={key:"type",base:c,typeMap:{range:b,"coded-value":f,inherited:v}};function x(e){if(!e?.type)return null;switch(e.type){case"range":return M.fromJSON(e);case"codedValue":return f.fromJSON(e);case"inherited":return v.fromJSON(e)}return null}},17036:(e,t,r)=>{r.d(t,{p:()=>a});var i=r(44208),n=r(53966),s=r(20437),o=r(95466),l=r(30524);function a(){return{fields:{type:[s.A],value:null,set:function(e){if(e&&(0,i.A)("big-integer-warning-enabled")){const t=e.filter((e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8));if(t.length){const e=t.map((e=>`'${e.name}'`)).join(", ");n.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return o.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const r=this.fieldsIndex?.has(t);r||n.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,l.DB)(this.fieldsIndex,e)}}}}},98453:(e,t,r)=>{r.d(t,{m:()=>i});const i=new(r(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"})},32730:(e,t,r)=>{r.d(t,{BI:()=>f,D3:()=>h,XJ:()=>m,lc:()=>c,mX:()=>_,rU:()=>g,tH:()=>F});var i=r(799);const n="__begin__",s="__end__",o=new RegExp(n,"ig"),l=new RegExp(s,"ig"),a=new RegExp("^"+n,"i"),d=new RegExp(s+"$","i"),u='"',p=u+" + ",y=" + "+u;function c(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function h(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function m(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=c(e.labelExpression),t.type="conventional"),t}function f(e){const t=m(e);if(!t)return null;switch(t.type){case"conventional":return _(t.expression);case"arcade":return t.expression}return null}function g(e){const t=m(e);if(!t)return null;switch(t.type){case"conventional":return function(e){const t=e?.match(v);return t?.[1].trim()||null}(t.expression);case"arcade":return F(t.expression)}return null}function _(e){let t;return e?(t=(0,i.HC)(e,(e=>n+'$feature["'+e+'"]'+s)),t=a.test(t)?t.replace(a,""):u+t,t=d.test(t)?t.replace(d,""):t+u,t=t.replaceAll(o,p).replaceAll(l,y)):t='""',t}const v=/^\s*\{([^}]+)\}\s*$/i,w=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,M=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function F(e){if(!e)return null;let t=w.exec(e)||b.exec(e);return t?t[1]||t[3]:(t=M.exec(e),t?t[2]:null)}},73133:(e,t,r)=>{r.d(t,{j:()=>i});const i=(0,r(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},96520:(e,t,r)=>{r.d(t,{u:()=>o});var i=r(83047),n=r(21325);function s(e,t,r){if(null==e.hasM||e.hasZ)for(const e of t)for(const t of e)t.length>2&&(t[2]*=r)}function o(e,t,r){if(!e&&!t||!r)return;const n=(0,i.G9)(r);l(e,r,n),l(t,r,n)}function l(e,t,r){if(e)for(const i of e)a(i.geometry,t,r)}function a(e,t,r){if(!e?.spatialReference||(0,n.aI)(e.spatialReference,t))return;const o=(0,i.G9)(e.spatialReference)/r;if(1!==o)if("x"in e)null!=e.z&&(e.z*=o);else if("rings"in e)s(e,e.rings,o);else if("paths"in e)s(e,e.paths,o);else if("points"in e&&(null==e.hasM||e.hasZ))for(const t of e.points)t.length>2&&(t[2]*=o)}},58501:(e,t,r)=>{r.d(t,{q:()=>n});var i=r(62815);function n(e,t,r){if(!r?.features||!r.hasZ)return;const n=(0,i.N)(r.geometryType,t,e.outSpatialReference);if(null!=n)for(const e of r.features)n(e.geometry)}},22671:(e,t,r)=>{r.d(t,{A:()=>v});var i,n=r(90237),s=r(59456),o=r(52106),l=r(66552),a=r(25482),d=r(4718),u=r(10107),p=(r(44208),r(53966),r(36005)),y=r(40608),c=r(43937),h=r(16930),m=r(65864),f=r(20437);const g=new l.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let _=i=class extends a.oY{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){const r=h.A.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const n=e[t],s=o.A.fromJSON(n),l=n.geometry?.spatialReference;null==s.geometry||l||(s.geometry.spatialReference=r);const a=n.aggregateGeometries,d=s.aggregateGeometries;if(a&&null!=d)for(const e in d){const t=d[e],i=a[e],n=i?.spatialReference;null==t||n||(t.spatialReference=r)}i.push(s)}return i}writeGeometryType(e,t,r,i){if(e)return void g.write(e,t,r,i);const{features:n}=this;if(n)for(const e of n)if(null!=e?.geometry)return void g.write(e.geometry.type,t,r,i)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,i=(0,m.rS)(e);return i&&!r&&t.spatialReference&&(i.spatialReference=h.A.fromJSON(t.spatialReference)),i}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new i(this.cloneProperties())}cloneProperties(){return(0,d.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const i=t.features[r];if(i.geometry){const t=e?.[r];i.geometry=t?.toJSON()||i.geometry}}return t}quantize(e){const{scale:[t,r],translate:[i,n]}=e,s=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-i)/t)),(e=>Math.round((n-e)/r)));for(let e=0,t=s.length;e<t;e++)o?.(s[e].geometry)||(s.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[i,n],scale:[s,o]}=r;let l=null,a=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;l=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;a=r=>null==r?r:r*t+e}const d=this._getHydrationFunction(e,(e=>e*s+i),(e=>n-e*o),l,a);for(const{geometry:e}of t)null!=e&&d&&d(e);return this.transform=null,this}_quantizePoints(e,t,r){let i,n;const s=[];for(let o=0,l=e.length;o<l;o++){const l=e[o];if(o>0){const e=t(l[0]),o=r(l[1]);e===i&&o===n||(s.push([e-i,o-n]),i=e,n=o)}else i=t(l[0]),n=r(l[1]),s.push([i,n])}return s.length>0?s:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const i=(0,m.Bi)(e)?e.rings:e.paths,n=[];for(let e=0,s=i.length;e<s;e++){const s=i[e],o=this._quantizePoints(s,t,r);o&&n.push(o)}return n.length>0?((0,m.Bi)(e)?e.rings=n:e.paths=n,e):null}:"multipoint"===e?e=>{const i=this._quantizePoints(e.points,t,r);return i&&i.length>0?(e.points=i,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,i,n){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),i&&(e.z=i(e.z))}:"polyline"===e||"polygon"===e?e=>{const s=(0,m.Bi)(e)?e.rings:e.paths;let o,l;for(let e=0,i=s.length;e<i;e++){const i=s[e];for(let e=0,n=i.length;e<n;e++){const n=i[e];e>0?(o+=n[0],l+=n[1]):(o=n[0],l=n[1]),n[0]=t(o),n[1]=r(l)}}if(i&&n)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2]),r[3]=n(r[3])}}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2])}}else if(n)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=n(r[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax),i&&null!=e.zmax&&null!=e.zmin&&(e.zmax=i(e.zmax),e.zmin=i(e.zmin)),n&&null!=e.mmax&&null!=e.mmin&&(e.mmax=n(e.mmax),e.mmin=n(e.mmin))}:"multipoint"===e?e=>{const s=e.points;let o,l;for(let e=0,i=s.length;e<i;e++){const i=s[e];e>0?(o+=i[0],l+=i[1]):(o=i[0],l=i[1]),i[0]=t(o),i[1]=r(l)}if(i&&n)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=i(t[2]),t[3]=n(t[3])}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=i(t[2])}else if(n)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=n(t[2])}}:null}};(0,n._)([(0,u.MZ)({type:String,json:{write:!0}})],_.prototype,"displayFieldName",void 0),(0,n._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"exceededTransferLimit",void 0),(0,n._)([(0,u.MZ)({type:[o.A],json:{write:!0}})],_.prototype,"features",void 0),(0,n._)([(0,p.w)("features")],_.prototype,"readFeatures",null),(0,n._)([(0,u.MZ)({type:[f.A],json:{write:!0}})],_.prototype,"fields",void 0),(0,n._)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],_.prototype,"geometryType",void 0),(0,n._)([(0,c.K)("geometryType")],_.prototype,"writeGeometryType",null),(0,n._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasM",void 0),(0,n._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasZ",void 0),(0,n._)([(0,u.MZ)({types:s.yR,json:{write:!0}})],_.prototype,"queryGeometry",void 0),(0,n._)([(0,p.w)("queryGeometry")],_.prototype,"readQueryGeometry",null),(0,n._)([(0,u.MZ)({type:h.A,json:{write:!0}})],_.prototype,"spatialReference",void 0),(0,n._)([(0,c.K)("spatialReference")],_.prototype,"writeSpatialReference",null),(0,n._)([(0,u.MZ)({json:{write:!0}})],_.prototype,"transform",void 0),_=i=(0,n._)([(0,y.$)("esri.rest.support.FeatureSet")],_),_.prototype.toJSON.isDefaultToJSON=!0;const v=_}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6289],{9775:(e,t,n)=>{n.d(t,{A:()=>i});var r=n(62788),s=n(95488);class i{constructor(e=(e=>e.values().next().value)){this._peeker=e,this._observable=new s.I,this._items=new Set}get length(){return(0,r.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let e;for(e of this._items);return e}peek(){if(0!==this.length)return this._peeker(this._items)}push(e){this.contains(e)||(this._items.add(e),this._observable.notify())}contains(e){return(0,r.gc)(this._observable),this._items.has(e)}pop(){if(0===this.length)return;const e=this.peek();return this._items.delete(e),this._observable.notify(),e}popLast(){if(0===this.length)return;const e=this.last();return this._items.delete(e),this._observable.notify(),e}remove(e){this.contains(e)&&(this._items.delete(e),this._observable.notify())}filter(e){const t=this.length;return this._items.forEach((t=>{e(t)||this._items.delete(t)})),t!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,r.gc)(this._observable),yield*this._items}}},75503:(e,t,n)=>{n.d(t,{w:()=>o});var r=n(4576),s=(n(44208),n(3694)),i=n(11006);class o{constructor(e=9,t){this._compareMinX=d,this._compareMinY=h,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),b.prune(),v.prune(),M.prune(),x.prune()}all(e){a(this._data,e)}search(e,t){let n=this._data;const r=this._toBBox;if(_(e,n))for(b.clear();n;){for(let s=0,i=n.children.length;s<i;s++){const i=n.children[s],o=n.leaf?r(i):i;_(e,o)&&(n.leaf?t(i):g(e,o)?a(i,t):b.push(i))}n=b.pop()}}collides(e){let t=this._data;const n=this._toBBox;if(!_(e,t))return!1;for(b.clear();t;){for(let r=0,s=t.children.length;r<s;r++){const s=t.children[r],i=t.leaf?n(s):s;if(_(e,i)){if(t.leaf||g(e,i))return!0;b.push(s)}}t=b.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,n=e.length;t<n;t++)this.insert(e[t]);return this}let t=this._build(e.slice(0,e.length),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new A([]),this}remove(e){if(!e)return this;let t,n=this._data,s=null,i=0,o=!1;const a=this._toBBox(e);for(M.clear(),x.clear();n||M.length>0;){if(n||(n=M.pop(),s=M.data[M.length-1],i=x.pop()??0,o=!0),n.leaf&&(t=(0,r.qh)(n.children,e,n.children.length,n.indexHint),-1!==t))return n.children.splice(t,1),M.push(n),this._condense(M),this;o||n.leaf||!g(n,a)?s?(i++,n=s.children[i],o=!1):n=null:(M.push(n),x.push(i),i=0,s=n,n=n.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,n,r){const s=n-t+1;let i=this._maxEntries;if(s<=i){const r=new A(e.slice(t,n+1));return l(r,this._toBBox),r}r||(r=Math.ceil(Math.log(s)/Math.log(i)),i=Math.ceil(s/i**(r-1)));const o=new E([]);o.height=r;const a=Math.ceil(s/i),u=a*Math.ceil(Math.sqrt(i));w(e,t,n,u,this._compareMinX);for(let s=t;s<=n;s+=u){const t=Math.min(s+u-1,n);w(e,s,t,a,this._compareMinY);for(let n=s;n<=t;n+=a){const s=Math.min(n+a-1,t);o.children.push(this._build(e,n,s,r-1))}}return l(o,this._toBBox),o}_insert(e,t,n){const r=this._toBBox,s=n?e:r(e);M.clear();const i=function(e,t,n,r){for(;r.push(t),!0!==t.leaf&&r.length-1!==n;){let n,r=1/0,s=1/0;for(let i=0,o=t.children.length;i<o;i++){const o=t.children[i],a=c(o),l=f(e,o)-a;l<s?(s=l,r=a<r?a:r,n=o):l===s&&a<r&&(r=a,n=o)}t=n||t.children[0]}return t}(s,this._data,t,M);for(i.children.push(e),p(i,s);t>=0&&M.data[t].children.length>this._maxEntries;)this._split(M,t),t--;!function(e,t,n){for(let r=n;r>=0;r--)p(t.data[r],e)}(s,M,t)}_split(e,t){const n=e.data[t],r=n.children.length,s=this._minEntries;this._chooseSplitAxis(n,s,r);const i=this._chooseSplitIndex(n,s,r);if(!i)return;const o=n.children.splice(i,n.children.length-i),a=n.leaf?new A(o):new E(o);a.height=n.height,l(n,this._toBBox),l(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(n,a)}_splitRoot(e,t){this._data=new E([e,t]),this._data.height=e.height+1,l(this._data,this._toBBox)}_chooseSplitIndex(e,t,n){let r,s,i;r=s=1/0;for(let o=t;o<=n-t;o++){const t=u(e,0,o,this._toBBox),a=u(e,o,n,this._toBBox),l=m(t,a),p=c(t)+c(a);l<r?(r=l,i=o,s=p<s?p:s):l===r&&p<s&&(s=p,i=o)}return i}_chooseSplitAxis(e,t,n){const r=e.leaf?this._compareMinX:d,s=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,n,r)<this._allDistMargin(e,t,n,s)&&e.children.sort(r)}_allDistMargin(e,t,n,r){e.children.sort(r);const s=this._toBBox,i=u(e,0,t,s),o=u(e,n-t,n,s);let a=y(i)+y(o);for(let r=t;r<n-t;r++){const t=e.children[r];p(i,e.leaf?s(t):t),a+=y(i)}for(let r=n-t-1;r>=t;r--){const t=e.children[r];p(o,e.leaf?s(t):t),a+=y(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const n=e.data[t];if(0===n.children.length)if(t>0){const s=e.data[t-1],i=s.children;i.splice((0,r.qh)(i,n,i.length,s.indexHint),1)}else this.clear();else l(n,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function a(e,t){let n=e;for(v.clear();n;){if(!0===n.leaf)for(const e of n.children)t(e);else v.pushArray(n.children);n=v.pop()??null}}function l(e,t){u(e,0,e.children.length,t,e)}function u(e,t,n,r,s){s||(s=new A([])),s.minX=1/0,s.minY=1/0,s.maxX=-1/0,s.maxY=-1/0;for(let i,o=t;o<n;o++)i=e.children[o],p(s,e.leaf?r(i):i);return s}function p(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function d(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function c(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function y(e){return e.maxX-e.minX+(e.maxY-e.minY)}function f(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function m(e,t){const n=Math.max(e.minX,t.minX),r=Math.max(e.minY,t.minY),s=Math.min(e.maxX,t.maxX),i=Math.min(e.maxY,t.maxY);return Math.max(0,s-n)*Math.max(0,i-r)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function _(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function w(e,t,n,r,s){const o=[t,n];for(;o.length;){const t=o.pop(),n=o.pop();if(t-n<=r)continue;const a=n+Math.ceil((t-n)/r/2)*r;(0,i.q)(e,a,n,t,s),o.push(n,a,a,t)}}const b=new s.A,v=new s.A,M=new s.A,x=new s.A({deallocator:void 0});class I{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class T extends I{constructor(){super(...arguments),this.height=1,this.indexHint=new r.vW}}class A extends T{constructor(e){super(),this.children=e,this.leaf=!0}}class E extends T{constructor(e){super(),this.children=e,this.leaf=!1}}},39516:(e,t,n)=>{async function r(e,t){const{WhereClause:r}=await Promise.all([n.e(835),n.e(4800)]).then(n.bind(n,50835));return r.create(e,t)}function s(e,t){return"1=1"===e?t??e:"1=1"===t?e??t:null!=e&&""!==e?null!=t&&""!==t?`(${e}) AND (${t})`:e:t}n.d(t,{G:()=>r,m:()=>s})},10382:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(36563),s=(n(44208),n(74887)),i=n(9775),o=n(72457),a=n(52268),l=n(61322);class u{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new i.A}destroy(){this.close()}get closed(){return!this._clients?.length}open(e,t){return new Promise(((n,r)=>{let i=!0;const o=e=>{(0,s.Te)(t.signal),i&&(i=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let i=0;i<e.length;++i){const a=e[i];(0,s.$X)(a)?this._clientPromises[i]=a.then((e=>(this._clients[i]=new l.default(e,t,this._ongoingJobsQueue),o(n),this._clients[i])),(()=>(o(r),null))):(this._clients[i]=new l.default(a,t,this._ongoingJobsQueue),this._clientPromises[i]=Promise.resolve(this._clients[i]),o(n))}}))}broadcast(e,t,n){const r=new Array(this._clientPromises.length);for(let s=0;s<this._clientPromises.length;++s){const i=this._clientPromises[s];r[s]=i.then((r=>r?.invoke(e,t,n)))}return r}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.resolver.reject((0,s.NK)(`Worker closing, aborting job calling '${e.methodName}'`));for(const e of this._clientPromises)e.then((e=>e?.close()));this._clients.length=0,this._clientPromises.length=0,this._inUseClients.length=0,(0,o.h)(this)}invoke(e,t,n){return this.apply(e,[t],n)}apply(e,t,n){const r=(0,s.Tw)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:n,resolver:r});for(let e=0;e<this._clientPromises.length;e++){const t=this._clients[e];t?t.jobAdded():this._clientPromises[e].then((e=>e?.jobAdded()))}return r.promise}createInvokeProxy(e){return(0,a.L)(this,e)}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,r.vE)(this._clients.map((n=>n.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let n=t.length;for(let r=0;r<this._clientPromises.length;++r)this._clientPromises[r].then((s=>{s&&(t[r]=s.openPort()),0==--n&&e(t)}))}))}get test(){}}},72457:(e,t,n)=>{n.d(t,{h:()=>i,k:()=>s});const r=new FinalizationRegistry((e=>{e.close()}));function s(e,t){r.register(e,t,t)}function i(e){r.unregister(e)}},29953:(e,t,n)=>{n.d(t,{ho:()=>G});var r=n(49186),s=n(44208),i=n(74887),o=n(10382),a=n(72457),l=n(61322),u=n(53966),p=n(97768),d=n(78888),h=n(84952);const c={async request(e,t){const n=e.options,r=n.responseType;n.signal=t?.signal,n.responseType="native"===r||"native-request-init"===r?"native-request-init":r&&["blob","json","text"].includes(r)&&(0,h.sC)(e.url)?.after?r:"array-buffer";const s=await(0,d.A)(e.url,n),i={data:s.data,httpStatus:s.httpStatus,ssl:s.ssl};switch(s.requestOptions?.responseType){case"native-request-init":return delete i.data.signal,i;case"blob":i.data=await i.data.arrayBuffer();break;case"json":i.data=(new TextEncoder).encode(JSON.stringify(i.data)).buffer;break;case"text":i.data=(new TextEncoder).encode(i.data).buffer}return{result:i,transferList:[i.data]}}};var y=n(8341),f=n(2741),m=n(92602),g=(n(47566),n(70333));const _={};var w=n(26390);class b{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...n)=>e[t](...n)}))}}class v{constructor(){this._dispatcher=new b,this._workerPostMessage({type:y.Go.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,w.d)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,n){this._dispatcher.addEventListener(e,t,n)}removeEventListener(e,t,n){this._dispatcher.removeEventListener(e,t,n)}_workerPostMessage(e){(0,w.d)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,y.VI)(e);if(t&&t.type===y.Go.OPEN){const{modulePath:e,jobId:n}=t;let r=await l.default.loadWorker(e);r||(r=await import(e));const s=l.default.connect(r);this._workerPostMessage({type:y.Go.OPENED,jobId:n,data:s})}}}var M=n(73444),x=n(18357);const I=()=>u.A.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:T}=y.Go;let A,E;const k="Failed to create Worker. Fallback to execute module in main thread";async function S(e){return new Promise((t=>{function n(s){const i=(0,y.VI)(s);i&&i.type===T&&(e.removeEventListener("message",n),e.removeEventListener("error",r),t(e))}function r(t){t.preventDefault(),e.removeEventListener("message",n),e.removeEventListener("error",r),I().warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new v).addEventListener("message",n),e.addEventListener("error",r)}e.addEventListener("message",n),e.addEventListener("error",r)}))}let N=0;const{ABORT:R,INVOKE:D,OPEN:j,OPENED:L,RESPONSE:O}=y.Go;class C{static async create(e){const t=await async function(){if(!(0,s.A)("esri-workers"))return S(new v);if(!A&&!E)try{const e='let globalId=0;const outgoing=new Map,configuration={CONFIGURATION};self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;let s=null;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());s=()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))},t.addEventListener("abort",s)}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})})).finally((()=>{t&&t.removeEventListener("abort",s)}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,fullVersion:r}=configuration.kernelInfo,{revision:t,fullVersion:n,version:s}=e.kernelInfo;esriConfig.assetsPath!==esriConfig.defaultAssetsPath&&o!==t&&console.warn(`Version mismatch detected between ArcGIS Maps SDK for JavaScript modules and assets. For more information visit https://bit.ly/3QnsuSo.\nModules version: ${r}\nAssets version: ${n??s}\nAssets path: ${esriConfig.assetsPath}`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let n;function t(e){const o=n.connect(e);self.postMessage({type:2,jobId:r,data:o},[o])}"function"==typeof define&&define.amd?require([workerPath],(e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((e=>(n=e.default,checkWorkerRevision(n),n.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):esriConfig.workers.useDynamicImport?import(workerPath).then((e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||import(o.modulePath))).then(t)})):(self.RemoteClient||importScripts(workerPath),n=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(n),n.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const s=outgoing.get(r);outgoing.delete(r),o.error?s.reject(JSON.parse(o.error)):s.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.split("{CONFIGURATION}").join(function(){let e;if(null!=m.A.default){const t={...m.A};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(m.A));e.assetsPath=(0,h.s2)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,h.s2)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,M.JK)(),e.has={"esri-csp-restrictions":(0,s.A)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,s.A)("esri-2d-update-debug"),"esri-2d-log-updating":(0,s.A)("esri-2d-log-updating"),"featurelayer-pbf":(0,s.A)("featurelayer-pbf"),"featurelayer-fast-triangulation-enabled":(0,s.A)("featurelayer-fast-triangulation-enabled"),"featurelayer-simplify-thresholds":(0,s.A)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,s.A)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,s.A)("featurelayer-simplify-mobile-factor"),"featurelayer-query-max-depth":(0,s.A)("featurelayer-query-max-depth"),"featurelayer-query-pausing-enabled":(0,s.A)("featurelayer-query-pausing-enabled"),"featurelayer-snapshot-enabled":(0,s.A)("featurelayer-snapshot-enabled"),"esri-atomics":(0,s.A)("esri-atomics"),"esri-shared-array-buffer":(0,s.A)("esri-shared-array-buffer"),"esri-tiles-debug":(0,s.A)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,s.A)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,s.A)("feature-polyline-generalization-factor"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,h.s2)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,h.s2)(e.workers.workerPath):e.workers.workerPath=(0,h.s2)((0,f.s)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=m.A.workers.loaderConfig,n=function(e){const t={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages?.concat()||[],paths:{..._.paths,...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=_.baseUrl),t}({baseUrl:t?.baseUrl,locale:(0,M.JK)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),r={buildDate:x.$,fullVersion:g.ol,revision:x.u};return JSON.stringify({esriConfig:e,loaderConfig:n,kernelInfo:r})}());A=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){E=e||{}}let e;if(A)try{e=new Worker(A,{name:"esri-worker-"+N++})}catch(t){I().warn(k,E),e=new v}else I().warn(k,E),e=new v;return S(e)}();return new C(t,e)}constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),u.A.getLogger("esri.core.workers.WorkerOwner").error(e)}))}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:n}=t,r=(0,y.Jc)();return new Promise(((t,s)=>{const o={resolve:t,reject:s,abortHandle:(0,i.NY)(n,(()=>{this._outJobs.delete(r),this._post({type:R,jobId:r})}))};this._outJobs.set(r,o),this._post({type:j,jobId:r,modulePath:e})}))}_onMessage(e){const t=(0,y.VI)(e);if(t)switch(t.type){case L:this._onOpenedMessage(t);break;case O:this._onResponseMessage(t);break;case R:this._onAbortMessage(t);break;case D:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,n=e.jobId,r=t.get(n);r&&(r.controller&&r.controller.abort(),t.delete(n))}_onInvokeMessage(e){const{methodName:t,jobId:n,data:r,abortable:s}=e,o=s?new AbortController:null,a=this._inJobs,l=c[t];let u;try{if("function"!=typeof l)throw new TypeError(`${t} is not a function`);u=l.call(null,r,{signal:o?o.signal:null})}catch(e){return void this._post({type:O,jobId:n,error:(0,y.mF)(e)})}(0,i.$X)(u)?(a.set(n,{controller:o,promise:u}),u.then((e=>{a.has(n)&&(a.delete(n),this._post({type:O,jobId:n},e))}),(e=>{a.has(n)&&(a.delete(n),e||(e={message:"Error encountered at method"+t}),(0,i.zf)(e)||this._post({type:O,jobId:n,error:(0,y.mF)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:O,jobId:n},u)}_onOpenedMessage(e){const{jobId:t,data:n}=e,r=this._outJobs.get(t);r&&(this._outJobs.delete(t),(0,p.xt)(r.abortHandle),r.resolve(n))}_onResponseMessage(e){const{jobId:t,error:n,data:s}=e,i=this._outJobs.get(t);i&&(this._outJobs.delete(t),(0,p.xt)(i.abortHandle),n?i.reject(r.A.fromJSON(JSON.parse(n))):i.resolve(s))}_post(e,t,n){return(0,y.u1)(this.worker,e,t,n)}}const B=(0,s.A)("host-browser")?Math.min(navigator.hardwareConcurrency-1,(0,s.A)("workers-pool-size")):0;let P=(0,s.A)("esri-mobile")?Math.min(B,3):B;P||(P=(0,s.A)("safari")&&(0,s.A)("mac")?7:2);let Z=0;const F=[];async function q(e,t){const n=new o.A,{registryTarget:r,...s}=t;return await n.open(e,s),r&&(0,a.k)(r,n),n}async function G(e,t={}){if("string"!=typeof e)throw new r.A("workers:undefined-module","modulePath is missing");let n=t.strategy||"distributed";if((0,s.A)("host-webworker")&&!(0,s.A)("esri-workers")&&(n="local"),"local"===n){let n=await l.default.loadWorker(e);n||(n=await import(e)),(0,i.Te)(t.signal);const r=t.client||n;return q([l.default.connect(n,t.schedule)],{...t,client:r})}if(await async function(){if(J)return J;$=new AbortController;const e=[];for(let t=0;t<P;t++){const n=C.create(t).then((e=>(F[t]=e,e)));e.push(n)}return J=Promise.all(e),J}(),(0,i.Te)(t.signal),"dedicated"===n){const n=Z++%P;return q([await F[n].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const n=Math.min(t.maxNumWorkers,P);if(n<P){const r=new Array(n);for(let s=0;s<n;++s){const n=Z++%P;r[s]=F[n].open(e,t)}return q(r,t)}}return q(F.map((n=>n.open(e,t))),t)}let $,J=null},17136:(e,t,n)=>{n.d(t,{el:()=>M});var r=n(92602),s=n(49186),i=n(53966),o=n(39829),a=n(82799),l=n(80754),u=n(21325),p=n(28735),d=(n(59456),n(78888)),h=n(65864),c=n(2272),y=n(84952),f=n(92300);const m=()=>i.A.getLogger("esri.geometry.support.normalizeUtils");function g(e){return"polygon"===e[0].type}function _(e){return"polyline"===e[0].type}function w(e,t,n){if(t){const t=function(e,t){if(!(e instanceof a.A||e instanceof o.A)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw m().error(e),new s.A(e)}const n=(0,l.r8)(e),r=[];for(const e of n){const n=[];r.push(n),n.push([e[0][0],e[0][1]]);for(let r=0;r<e.length-1;r++){const s=e[r][0],i=e[r][1],o=e[r+1][0],a=e[r+1][1],l=Math.sqrt((o-s)*(o-s)+(a-i)*(a-i)),u=(a-i)/l,p=(o-s)/l,d=l/t;if(d>1){for(let e=1;e<=d-1;e++){const r=e*t,o=p*r+s,a=u*r+i;n.push([o,a])}const e=(l+Math.floor(d-1)*t)/2,r=p*e+s,o=u*e+i;n.push([r,o])}n.push([o,a])}}return function(e){return"polygon"===e.type}(e)?new o.A({rings:r,spatialReference:e.spatialReference}):new a.A({paths:r,spatialReference:e.spatialReference})}(e,1e6);e=(0,p.ci)(t,!0)}return n&&(e=(0,l.kS)(e,n)),e}function b(e,t,n){if(Array.isArray(e)){const r=e[0];if(r>t){const n=(0,l.kd)(r,t);e[0]=r+n*(-2*t)}else if(r<n){const t=(0,l.kd)(r,n);e[0]=r+t*(-2*n)}}else{const r=e.x;if(r>t){const n=(0,l.kd)(r,t);e=e.clone().offset(n*(-2*t),0)}else if(r<n){const t=(0,l.kd)(r,n);e=e.clone().offset(t*(-2*n),0)}}return e}function v(e,t){let n=-1;for(let r=0;r<t.cutIndexes.length;r++){const s=t.cutIndexes[r],i=t.geometries[r],o=(0,l.r8)(i);for(let e=0;e<o.length;e++){const t=o[e];t.some((n=>{if(n[0]<180)return!0;{let n=0;for(let e=0;e<t.length;e++){const r=t[e][0];n=r>n?r:n}n=Number(n.toFixed(9));const r=-360*(0,l.kd)(n,180);for(let n=0;n<t.length;n++){const t=i.getPoint(e,n);i.setPoint(e,n,t.clone().offset(r,0))}return!0}}))}if(s===n){if(g(e))for(const t of(0,l.r8)(i))e[s]=e[s].addRing(t);else if(_(e))for(const t of(0,l.r8)(i))e[s]=e[s].addPath(t)}else n=s,e[s]=i}return e}async function M(e,t,n){if(!Array.isArray(e))return M([e],t);t&&"string"!=typeof t&&m().warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const s="string"==typeof t?t:t?.url??r.A.geometryServiceUrl;let i,g,_,x,I,T,A,E,k=0;const S=[],N=[];for(const t of e)if(null!=t)if(i||(i=t.spatialReference,g=(0,u.Vp)(i),_=i.isWebMercator,T=_?102100:4326,x=l.j7[T].maxX,I=l.j7[T].minX,A=l.j7[T].plus180Line,E=l.j7[T].minus180Line),g)if("mesh"===t.type)N.push(t);else if("point"===t.type)N.push(b(t.clone(),x,I));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>b(e,x,I))),N.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,g);N.push(e.rings?new o.A(e):e)}else if(t.extent){const e=t.extent,n=(0,l.kd)(e.xmin,I)*(2*x);let r=0===n?t.clone():(0,l.kS)(t.clone(),n);e.offset(n,0);let{xmin:s,xmax:i}=e;s=Number(s.toFixed(9)),i=Number(i.toFixed(9)),e.intersects(A)&&i!==x?(k=i>k?i:k,r=w(r,_),S.push(r),N.push("cut")):e.intersects(E)&&s!==I?(k=i*(2*x)>k?i*(2*x):k,r=w(r,_,360),S.push(r),N.push("cut")):N.push(r)}else N.push(t.clone());else N.push(t);else N.push(t);let R=(0,l.kd)(k,x),D=-90;const j=R,L=new a.A;for(;R>0;){const e=360*R-180;L.addPath([[e,D],[e,-1*D]]),D*=-1,R--}if(S.length>0&&j>0){const t=v(S,await async function(e,t,n,r){const s=(0,c.Dl)(e),i=t[0].spatialReference,o={...r,responseType:"json",query:{...s.query,f:"json",sr:(0,u.YX)(i),target:JSON.stringify({geometryType:(0,h.$B)(t[0]),geometries:t}),cutter:JSON.stringify(n)}},a=await(0,d.A)(s.path+"/cut",o),{cutIndexes:l,geometries:p=[]}=a.data;return{cutIndexes:l,geometries:p.map((e=>{const t=(0,h.rS)(e);return t.spatialReference=i,t}))}}(s,S,L,n)),r=[],i=[];for(let n=0;n<N.length;n++){const s=N[n];if("cut"!==s)i.push(s);else{const s=t.shift(),o=e[n];null!=o&&"polygon"===o.type&&o.rings&&o.rings.length>1&&s.rings.length>=o.rings.length?(r.push(s),i.push("simplify")):i.push(_?(0,p.Gh)(s):s)}}if(!r.length)return i;const o=await async function(e,t,n){const r="string"==typeof e?(0,y.An)(e):e,s=t[0].spatialReference,i=(0,h.$B)(t[0]),o={...n,query:{...r.query,f:"json",sr:(0,u.YX)(s),geometries:JSON.stringify((0,f.X)(t))}},{data:a}=await(0,d.A)(r.path+"/simplify",o);return(0,f.V)(a.geometries,i,s)}(s,r,n),a=[];for(let e=0;e<i.length;e++){const t=i[e];"simplify"!==t?a.push(t):a.push(_?(0,p.Gh)(o.shift()):o.shift())}return a}const O=[];for(let e=0;e<N.length;e++){const t=N[e];if("cut"!==t)O.push(t);else{const e=S.shift();O.push(!0===_?(0,p.Gh)(e):e)}}return O}},80754:(e,t,n)=>{n.d(t,{j7:()=>o,kS:()=>l,kd:()=>a,r8:()=>u});var r=n(82799),s=n(16930),i=n(65864);const o={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new r.A({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:s.A.WebMercator}),minus180Line:new r.A({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:s.A.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new r.A({paths:[[[180,-180],[180,180]]],spatialReference:s.A.WGS84}),minus180Line:new r.A({paths:[[[-180,-180],[-180,180]]],spatialReference:s.A.WGS84})}};function a(e,t){return Math.ceil((e-t)/(2*t))}function l(e,t){const n=u(e);for(const e of n)for(const n of e)n[0]+=t;return e}function u(e){return(0,i.Bi)(e)?e.rings:e.paths}},6518:(e,t,n)=>{n.d(t,{F:()=>a});var r=n(44208),s=n(75503),i=n(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s.w(9,(0,r.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((n,r)=>{e[t++]=r})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,i.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,n){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,n)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},83221:(e,t,n)=>{n.d(t,{A:()=>y});var r=n(4576),s=n(49186),i=n(65529),o=n(53966),a=n(70328),l=n(19419),u=n(90708),p=n(6518),d=n(51441),h=n(37730);const c=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new p.F,this._featuresById=new Map,this._markedIds=new Set,this.events=new i.A,this.featureAdapter=h.T}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 e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,n,r,s]=this.fullBounds;return{xmin:t,ymin:n,xmax:r,ymax:s,spatialReference:(0,d.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(r.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const n of e){const e=this._boundsStore.get(n.objectId);e&&t((0,a.Jt)(c,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}startMarkingUsedFeatures(){this._boundsStore.invalidateIndex(),this._markedIds.clear()}sweep(){let e=!1;this._featuresById.forEach(((t,n)=>{this._markedIds.has(n)||(e=!0,this._remove(t))})),this._markedIds.clear(),e&&this._emitChanged()}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const n=this._featuresById.get(t);let r;if(this._markedIds.add(t),n?(e.displayId=n.displayId,r=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);r=(0,u.jQ)(null!=r?r:(0,l.vt)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=r&&this._boundsStore.set(t,r),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const n=this._featuresById.get(t);if(!n)return this._add(e),e;this._markedIds.add(t);const{geometry:r,attributes:i}=e;for(const e in i)n.attributes[e]=i[e];return r&&(n.geometry=r,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),r,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),n}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._markedIds.delete(t),this._boundsStore.delete(t),this._featuresById.delete(t),e}}},64714:(e,t,n)=>{n.d(t,{F0:()=>a,Vx:()=>p,e2:()=>h,f:()=>c});var r=n(44208),s=n(4718),i=n(99352),o=n(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function p(e,t){if((0,r.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${d(t)} = null;`;for(const t in e)n+=`this${d(t)} = ${JSON.stringify(e[t])};`;const r=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new r}catch(n){return()=>({[t]:null,...e})}}function d(e){return l.test(e)?`.${e}`:`["${e}"]`}function h(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,s.o8)(e)}}]}function c(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:i.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},61184:(e,t,n)=>{n.d(t,{PB:()=>k,d4:()=>E,ZL:()=>T,sZ:()=>A,yC:()=>x,Vr:()=>I});var r=n(90237),s=(n(59456),n(69622)),i=n(49186),o=n(53966),a=n(91869),l=n(39516),u=n(10107),p=(n(44208),n(87811),n(40608)),d=n(39829),h=n(57251),c=n(21325),y=n(90708),f=n(43334),m=n(65864);class g{constructor(){this._featureLookup=new Map}static getInstance(){return g.instance||(g.instance=new g),g.instance}static resetInstance(){g.instance&&(g.instance=null)}deleteFromStore(e){e.forEach((e=>{this._featureLookup.delete(e)}))}readFromStoreByList(e){const t=[];return e.forEach((e=>{const n=this.readFromStoreById(e);n&&t.push(n)})),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,n){const r=[];return e.forEach((e=>{if(!e?.id)return;e.properties||(e.properties=[]);let s,i=null;if(n&&e.properties[n]&&(i=(0,y.Ux)(e.properties[n])),"originId"in e&&"destinationId"in e&&(e.properties.ESRI__ORIGIN_ID=e.originId,e.properties.ESRI__DESTINATION_ID=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const r=this._featureLookup.get(e.id),o=JSON.parse(JSON.stringify(Object.assign(r.attributes,e.properties)));n&&e.properties[n]&&(o[n]=(0,m.rS)(e.properties[n])),s=new f.Om(i?JSON.parse(JSON.stringify(i)):r?.geometry?JSON.parse(JSON.stringify(r.geometry)):null,o,null,e.properties[t])}else s=new f.Om(i?JSON.parse(JSON.stringify(i)):null,e.properties,null,e.properties[t]);this._featureLookup.set(e.id,s),r.push(s)})),r}}var _=n(45654),w=n(71932),b=n(42538),v=n(61956),M=n(5443);const x="ESRI__ID",I="ESRI__ORIGIN_ID",T="ESRI__DESTINATION_ID",A="ESRI__LAYOUT_GEOMETRY",E="ESRI__AGGREGATION_COUNT";let k=class extends s.A{constructor(e){super(e),this._processingCacheUpdatesLookup=new Map,this.knowledgeGraph=null,this.inclusionModeDefinition={generateAllSublayers:!0,namedTypeDefinitions:new Map},this.entityTypeNames=new Set,this.relationshipTypeNames=new Set,this.geographicLookup=new Map,this.sublayerCaches=new Map,this.nodeConnectionsLookup=new Map,this.relationshipConnectionsLookup=new Map,this.memberIdTypeLookup=new Map;const t=new Map;e.knowledgeGraph.dataModel.entityTypes?.forEach((n=>{n.name&&(t.set(n.name,"entity"),this._processingCacheUpdatesLookup.set(n.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(n.name),n.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(n.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.knowledgeGraph.dataModel.relationshipTypes?.forEach((n=>{n.name&&(t.set(n.name,"relationship"),this._processingCacheUpdatesLookup.set(n.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(n.name),n.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(n.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.inclusionModeDefinition?.namedTypeDefinitions.forEach(((n,r)=>{if("entity"===t.get(r))this.entityTypeNames.add(r);else{if("relationship"!==t.get(r))return o.A.getLogger(this).warn(`A named type, ${r}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(r);this.relationshipTypeNames.add(r)}const s=new Map;n.members?.forEach((e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,(()=>new Set)).add(r);const t=this.getById(e.id);t&&s.set(e.id,t)})),this.sublayerCaches.set(r,s)}))}addToLayer(e){e.forEach((({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new i.A("knowledge-graph:layer-data-manager","You cannot add to a layer's exclusion list if it was not created with an exclusion list originally");if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){const n=this.inclusionModeDefinition.namedTypeDefinitions.get(e);n.members||(n.members=new Map),n.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}else{const n=new Map;n.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:n}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}))}getById(e){return g.getInstance().readFromStoreById(e)}async getData(e,t,n){if(t.objectType.name&&this.inclusionModeDefinition?.namedTypeDefinitions&&this.inclusionModeDefinition.namedTypeDefinitions.size>0&&!this.inclusionModeDefinition.namedTypeDefinitions.has(t.objectType.name))return[];let r;if(r=e||new v.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,n=this._processingCacheUpdatesLookup.get(t.objectType.name??""),s=r.outFields;s&&1===s.length&&s[0]===x&&"1=1"===r.where||await Promise.all(n??[]);const i=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return i.forEach((n=>{this.relationshipTypeNames.has(t.objectType.name)?n.geometry=e.relationshipLinkChartDiagramLookup.get(n.attributes[t.objectIdField]):n.geometry=e.entityLinkChartDiagramLookup.get(n.attributes[t.objectIdField]),n.attributes[A]=n.geometry,o.push(n)})),o}return this.retrieveDataFromService(r,t,n)}async getConnectedRecordIds(e,t){const n=[];let r="";const s=[],i=new Map;if(e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(t))return;i.has(t)?i.get(t)?.push(e):i.set(t,[e])}})),t&&0!==t?.length){for(const e of t)r=r+e+"|";r=r.slice(0,-1)}return i.forEach(((e,i)=>{let a;a=t&&0!==t?.length?`MATCH (n:${i})-[r:${r}]-(m) WHERE id(n) IN $ids RETURN id(r), type(r), id(m), labels(m)[0]`:`MATCH (n:${i})-[r]-(m) WHERE id(n) IN $ids RETURN id(r), type(r), id(m), labels(m)[0]`;const l=new Promise((t=>{(async()=>{const t=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:a,bindParameters:{ids:e}}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:r}=await t.read();if(e)break;for(let e=0;e<r.length;e++){const t=r[e];n.push({id:t[0],typeName:t[1]}),n.push({id:t[2],typeName:t[3]})}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}})().then((()=>{t()}))}));s.push(l)})),this.refreshCacheContent(),await Promise.all(s),n}async getAttachedRelationships(e,t){const n=[],r=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:"MATCH (n)-[r]->(m) WHERE id(n) IN $nodeIds AND id(m) in $nodeIds AND NOT id(r) IN $relationshipExclusionIds return id(r), type(r)",bindParameters:{nodeIds:e,relationshipExclusionIds:t}}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:t}=await r.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];n.push({id:r[0],typeName:r[1]})}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}return n}async refreshCacheContent(e,t,n,r=!0){const s=g.getInstance(),o=[],l=new Map,u=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&u.set(e.name,e)})),this.knowledgeGraph.dataModel.relationshipTypes?.forEach((e=>{e.name&&u.set(e.name,e)})),e||this.inclusionModeDefinition?e?e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e))l.has(t)?l.get(t)?.push(e):l.set(t,[e])})):this.inclusionModeDefinition?.namedTypeDefinitions?.forEach(((e,t)=>{e.useAllData?l.set(t,null):e.members&&e.members.forEach((e=>{l.has(t)&&null!==l.get(t)?l.get(t)?.push(e.id):l.set(t,[e.id])}))})):(this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&l.set(e.name,null)})),this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&l.set(e.name,null)})));for(const[e,p]of l){const l=new Promise((o=>{(async()=>{const o=new Set,l=[];let d,h="",c=!1;if(t||u.get(e)?.properties?.forEach((e=>{e.name&&o.add(e.name)})),n&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&o.add(t)}if(this.entityTypeNames.has(e))h=`MATCH (n:${e}) ${p?"WHERE id(n) IN $ids ":""}return ID(n)`,o.forEach((e=>{h+=`, n.${e}`,l.push(e)}));else{if(!this.relationshipTypeNames.has(e))throw new i.A("knowledge-graph:layer-data-manager",`The graph type of ${e} could not be determined. Was this type set in the KG data model and inclusion definition?`);c=!0,h=`MATCH ()-[n:${e}]->() ${p?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,o.forEach((e=>{h+=`, n.${e}`,l.push(e)}))}d=new b.A(p?{openCypherQuery:h,bindParameters:{ids:p}}:{openCypherQuery:h});const y=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,d)).resultRowsStream.getReader();for(;;){const{done:t,value:n}=await y.read();if(t)break;const i=[];for(let e=0;e<n.length;e++){const t=n[e];let r=0,s=0;const o={properties:{}};for(o.id=t[r],r++,s++,c&&(o.originId=t[r],r++,s++,o.destinationId=t[r],r++,s++,(0,a.tE)(this.nodeConnectionsLookup,o.originId,(()=>new Set)).add(o.id),(0,a.tE)(this.nodeConnectionsLookup,o.destinationId,(()=>new Set)).add(o.id),(0,a.tE)(this.relationshipConnectionsLookup,o.id,(()=>[o.originId,o.destinationId])));r<t.length;r++)o.properties[l[r-s]]=t[r];i.push(o)}const o=s.writeToStore(i,x,this.geographicLookup.get(e)?.name);this.sublayerCaches.has(e)||this.sublayerCaches.set(e,new Map),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.has(e)&&this.inclusionModeDefinition?.namedTypeDefinitions.set(e,{useAllData:!1,members:new Map}),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members&&(this.inclusionModeDefinition.namedTypeDefinitions.get(e).members=new Map);const u=this.sublayerCaches.get(e);o.forEach((t=>{u?.set(t.attributes[x],t),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[x])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[x],{id:t.attributes[x]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[x],(()=>new Set)).add(e))}))}})().then((()=>{o(null)}))}));o.push(l),this._processingCacheUpdatesLookup.get(e)?.push(l)}await Promise.all(o)}removeFromLayer(e){const t=new Set,n=new Set(e.map((e=>e.id)));for(const n of e)t.add(n.typeName),1===this.memberIdTypeLookup.get(n.id)?.size?this.memberIdTypeLookup.delete(n.id):this.memberIdTypeLookup.get(n.id)?.delete(n.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach(((e,t)=>{t===n.typeName&&e.members?.has(n.id)&&e.members.delete(n.id)}));t.forEach((e=>{this.sublayerCaches.get(e)?.forEach(((t,r)=>{n.has(r)&&this.sublayerCaches.get(e)?.delete(r)}))}))}async retrieveDataFromService(e,t,n){const r=g.getInstance(),s=new Set,o=[];let a,u="",p=[];const y="relationship"===t.graphType,f=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,m=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let v=!f&&m?Array.from(m).sort():null;if(this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData)this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData&&null!=e.objectIds&&(v=e.objectIds);else if(null!=e.objectIds&&v&&v.length>0){const t=e.objectIds;e.objectIds=v.filter((e=>t.includes(e)))}else if(null!=e.objectIds)v=e.objectIds;else{if(this.inclusionModeDefinition?.namedTypeDefinitions.has(t.objectType.name)&&(!this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members||this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members?.size<1))return e.objectIds=[],[];e.objectIds=v}if(null!=e.outFields){const n=e.outFields;n.includes("*")?t.fields.forEach((e=>{s.add(e.name)})):n.forEach((e=>{e!==x&&e!==t.geometryFieldName&&s.add(e)}))}if(null!=e.geometry){const n=e.geometry;let r;const p=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,f=p?.spatialReference,m=p?.serviceCapabilities?.geometryCapabilities;let g=m?.geometryMaxBoundingRectangleSizeX,w=m?.geometryMaxBoundingRectangleSizeY;if(n?.extent?.spatialReference&&!n.spatialReference?.isWGS84?(await(0,h.initializeProjection)(n.extent.spatialReference,c.KK),r=(0,h.project)(n.extent,c.KK)):r=n.extent,g&&w&&f){if(4326!==f.wkid){const e=new M.A({spatialReference:f,xmax:g,ymax:w}),t=(0,h.project)(e,c.KK);g=t.xmax,w=t.ymax}if(r.xmax-r.xmin>g)throw new i.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${g}° latitude, limit exceeded`);if(r.ymax-r.ymin>w)throw new i.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${w}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const n=await(0,l.G)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach((e=>{n.fieldNames.includes(e.name)&&s.add(e.name)}))}u=y?`Match ()-[n:${t.objectType.name}]->() WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n), id(startNode(r)), id(endNode(r))`:`Match (n:${t.objectType.name}) WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n)`,t.geometryFieldName&&s.add(t.geometryFieldName),s.forEach((e=>{u+=`, n.${e}`,o.push(e)})),a=new b.A({openCypherQuery:u,bindParameters:{param_filter_geom:new d.A({rings:(0,_.DX)(r)})}})}else{let n="";if(null!=e.where&&"1=1"!==e.where){const r=await(0,l.G)(e.where,t.fieldsIndex);t.fields.forEach((e=>{r.fieldNames.includes(e.name)&&s.add(e.name)}));const i=new Set(["column-reference","string","number","binary-expression"]),o=new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]);let a=!1;const u=e=>{if("column-reference"===e.type)return`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&i.has(e.left.type)&&i.has(e.right.type)&&o.has(e.operator))return`${u(e.left)} ${e.operator} ${u(e.right)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let t="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)t+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return a=!0,"";t+=`lower(n.${e.left.column})`}if(t+=" CONTAINS (","string"!==e.right.type)return a=!0,"";{let n=e.right.value;"%"===n.charAt(0)&&(n=n.slice(1)),"%"===n.charAt(n.length-1)&&(n=n.slice(0,-1)),t+=`'${n.toLowerCase()}')`}return t}return a=!0,""};n=u(r.parseTree),a&&(n="")}let r="";r=y?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let i=!1;v&&(i=!0,r+=" WHERE ID(n) IN $ids"),n&&(r+=i?" AND":" WHERE",r+=` ${n}`),r+=" return ID(n)",y&&(r+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&s.add(t.geometryFieldName),s.forEach((e=>{r+=`, n.${e}`,o.push(e)})),a=new b.A(v?{openCypherQuery:r,bindParameters:{ids:v}}:{openCypherQuery:r})}const I=(await(0,w.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,n)).resultRowsStream.getReader();for(;;){const{done:e,value:n}=await I.read();if(e)break;const s=[];for(let e=0;e<n.length;e++){const t=n[e];let r=0,i=0;const a={properties:{}};for(a.id=t[r],r++,i++,y&&(a.originId=t[r],r++,i++,a.destinationId=t[r],r++,i++);r<t.length;r++)a.properties[o[r-i]]=t[r];s.push(a)}p=p.concat(r.writeToStore(s,x,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return p}};(0,r._)([(0,u.MZ)()],k.prototype,"knowledgeGraph",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"inclusionModeDefinition",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"entityTypeNames",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"relationshipTypeNames",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"geographicLookup",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"sublayerCaches",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"nodeConnectionsLookup",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"relationshipConnectionsLookup",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"memberIdTypeLookup",void 0),k=(0,r._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],k)},70643:(e,t,n)=>{n.d(t,{A:()=>H});var r=n(90237),s=(n(59456),n(13874)),i=(n(86162),n(94409),n(65345),n(42980),n(39290),n(92438),n(96576),n(93618),n(65494)),o=n(15036),a=n(4718),l=n(92071),u=(n(29953),n(10107)),p=(n(44208),n(53966),n(40608)),d=n(43937),h=n(35666),c=n(57251),y=n(16930),f=n(21325),m=n(4146),g=n(83221),_=n(17970),w=n(64714),b=n(61184);n(87811);const v=(0,n(17036).p)(),M=e=>{let t=class extends e{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,r._)([(0,u.MZ)(v.fields)],t.prototype,"fields",void 0),(0,r._)([(0,u.MZ)(v.fieldsIndex)],t.prototype,"fieldsIndex",void 0),t=(0,r._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],t),t};var x=n(63074),I=n(87718),T=n(76294),A=n(32756),E=n(54310),k=n(25036),S=n(82935),N=n(10873),R=n(13213),D=n(20437),j=n(30524),L=n(81457),O=n(39383),C=n(22671),B=n(61956),P=n(30291),Z=n(61322),F=n(5443),q=n(39829),G=n(82799),$=n(50498);function J(e){if(!e.json)return e;e.json.write=Y(e.json.write);const t=e.json.origins;if(!t)return e;let n;for(n in t){const e=t[n];e&&(e.write=Y(e.write))}return e}function Y(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:n,overridePolicy:r,...s}=e;return function(e,t){const n=Q.call(this,e,t);return n.enabled?{...s,...n}:n}}(e)),e):!0===e?V():e}function V(){return{overridePolicy:Q}}function Q(e,t){const n=!!this.geometryType;let r={enabled:n};return n&&(r={...r,...X.call(this,e,t)}),r}function X(e,t){return{ignoreOrigin:this.originIdOf(t)>h.Gr.DEFAULTS}}let U=class extends(M((0,T.J)((0,I.F)((0,x.dM)((0,A.f)((0,S.e)((0,k.j)((0,E.J)((0,l.P)(m.A)))))))))){constructor(e){super(e),this.blendMode="normal",this.capabilities=(0,w.f)(!1,!1),this.charts=null,this.definitionExpression=null,this.displayField="",this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.labelingInfo=null,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=b.yC,this.objectType=null,this.opacity=1,this.orderBy=null,this.parentCompositeLayer=null,this.popupEnabled=!0,this.popupTemplate=null,this.refreshInterval=0,this.source={openPorts:()=>this.load().then((()=>{const e=new MessageChannel;return new Z.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const n=B.A.fromJSON(e);return this.queryFeaturesJSON(n,t)}}}),[e.port2]}))},this.title=null,this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get defaultPopupTemplate(){return this.createPopupTemplate()}set featureReduction(e){const t=this._normalizeFeatureReduction(e);this._set("featureReduction",t)}get fields(){const e=[];return this.objectType?.properties?.forEach((t=>{const n="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(D.A.fromJSON({name:t.name,type:n,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))})),e.push(D.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),D.A.fromJSON({name:b.d4,type:"esriFieldTypeInteger",alias:b.d4,editable:!1})),e}get geometryType(){if("link-chart"===this.parentCompositeLayer?.type)return"relationship"===this.graphType?"polyline":"point";const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.geometryType;return t&&"esriGeometryNull"!==t?$.g.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return b.sZ;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphTypeName(){return this.objectType?.name}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,n=t?this.objectType?.properties?.[t]:null;return n?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,n=t?this.objectType?.properties?.[t]:null;return n?.hasZ??!1}set renderer(e){(0,j.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){return this._isOverridden("renderer")?this._get("renderer"):"link-chart"===this.parentCompositeLayer?.type?"relationship"===this.graphType?(0,i.r)((0,w.F0)($.g.toJSON("polyline")).renderer):(0,i.r)((0,w.F0)($.g.toJSON("point")).renderer):(0,i.r)((0,w.F0)($.g.toJSON(this.geometryType)).renderer)}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??y.A.WGS84}writeTitle(e,t){t.title=e??"Layer"}createPopupTemplate(e){return(0,P.tn)(this,e)}createQuery(){return new B.A({where:"1=1",outFields:["*"]})}getField(e){for(let t=0;t<this.fields.length;t++)if(this.fields[t].name===e)return this.fields[t];return null}getFieldDomain(e,t){return null}async queryFeatures(e,t){const{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(e),s=C.A.fromJSON(await r.executeQuery(n.toJSON(),t?.signal));return s.features.forEach((e=>{e.sourceLayer=this})),s}async queryFeaturesJSON(e,t){const{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(e);return await r.executeQuery(n.toJSON(),t?.signal)}async queryFeatureCount(e,t){const{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(e);return r.executeQueryForCount(n.toJSON(),t?.signal)}async queryExtent(e={},t){const n={...e,returnGeometry:!0},{resolvedQuery:r,queryEngine:s}=await this._setupQueryObjects(n),i=await s.executeQueryForExtent(r.toJSON(),t?.signal);let o;return o=null!=i.extent?.xmin&&null!=i.extent?.xmax&&null!=i.extent?.ymin&&null!=i.extent?.ymax?new F.A(i.extent):new F.A,{count:i.count,extent:o}}async queryObjectIds(e,t){const n=B.A.from(e);let r;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)r=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(n,this,t);r=this.loadQueryEngine(e)}return r.executeQueryForIds(n.toJSON(),t?.signal)}loadQueryEngine(e){const t=new g.A({geometryType:$.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),n=new _.d({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:$.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,objectIdField:this.objectIdField,spatialReference:this.spatialReference.toJSON(),timeInfo:null,featureStore:t});return n.featureStore.addMany(e),n}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new B.A({where:"1=1",outFields:[b.yC]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}async _setupQueryObjects(e,t){const n=B.A.from(e),r=n.geometry;let s;if(r&&!r.spatialReference?.isWGS84&&(await(0,c.initializeProjection)(r.spatialReference,f.KK),n.geometry=(0,c.project)(r instanceof q.A||r instanceof G.A?r:r.extent,f.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)s=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(n,this,t);s=this.loadQueryEngine(e)}return{resolvedQuery:n,queryEngine:s}}};(0,r._)([(0,u.MZ)(J((0,a.o8)(x.sU)))],U.prototype,"blendMode",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"capabilities",void 0),(0,r._)([(0,u.MZ)({json:{origins:{"web-scene":{write:!1}},write:V()}})],U.prototype,"charts",void 0),(0,r._)([(0,u.MZ)({readOnly:!0})],U.prototype,"defaultPopupTemplate",null),(0,r._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],U.prototype,"definitionExpression",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"displayField",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(x.LF)))],U.prototype,"effect",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"elevationInfo",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(I.Y)))],U.prototype,"featureEffect",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(R.d)))],U.prototype,"featureReduction",null),(0,r._)([(0,u.MZ)()],U.prototype,"fields",null),(0,r._)([(0,u.MZ)()],U.prototype,"geometryType",null),(0,r._)([(0,u.MZ)()],U.prototype,"geometryFieldName",null),(0,r._)([(0,u.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],U.prototype,"graphType",void 0),(0,r._)([(0,u.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],U.prototype,"graphTypeName",null),(0,r._)([(0,u.MZ)()],U.prototype,"hasM",null),(0,r._)([(0,u.MZ)()],U.prototype,"hasZ",null),(0,r._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],U.prototype,"id",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.kF)))],U.prototype,"labelsVisible",void 0),(0,r._)([(0,u.MZ)({type:[L.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:O.w,write:V()}})],U.prototype,"labelingInfo",void 0),(0,r._)([(0,u.MZ)({readOnly:!0,json:{read:!1,write:{writer(e,t){t.layerType=this.geometryType?"KnowledgeGraphSubLayer":"KnowledgeGraphSubTable"},isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],U.prototype,"layerType",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.fV)))],U.prototype,"legendEnabled",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.hG)))],U.prototype,"maxScale",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.hn)))],U.prototype,"minScale",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"objectIdField",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"objectType",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.ke)))],U.prototype,"opacity",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(A.n)))],U.prototype,"orderBy",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"parentCompositeLayer",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.M6)))],U.prototype,"popupEnabled",void 0),(0,r._)([(0,u.MZ)({type:s.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],U.prototype,"popupTemplate",void 0),(0,r._)([(0,u.MZ)({type:Number,json:{write:{overridePolicy:X}}})],U.prototype,"refreshInterval",void 0),(0,r._)([(0,u.MZ)({types:o.H,json:{name:"layerDefinition.drawingInfo.renderer",write:V()}})],U.prototype,"renderer",null),(0,r._)([(0,u.MZ)()],U.prototype,"source",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"spatialReference",null),(0,r._)([(0,u.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],U.prototype,"title",void 0),(0,r._)([(0,d.K)("title")],U.prototype,"writeTitle",null),(0,r._)([(0,u.MZ)({json:{read:!1}})],U.prototype,"type",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(S.B)))],U.prototype,"useViewTime",void 0),(0,r._)([(0,u.MZ)({type:Boolean,json:{name:"visibility",write:V()}})],U.prototype,"visible",void 0),U=(0,r._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],U);const H=U},45654:(e,t,n)=>{n.d(t,{DX:()=>_,_s:()=>b,aq:()=>w,fe:()=>v});var r,s,i,o,a=n(78888),l=n(49186),u=n(91869),p=(n(90708),n(71932)),d=n(42538);n(59456),n(16930),(s=r||(r={})).ELEMENTUID="ELEMENTUID",s.TYPENAME="TYPENAME",r.ELEMENTUID,r.TYPENAME,function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME"}(i||(i={})),function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME",e[e.FROMUID=2]="FROMUID",e[e.TOUID=3]="TOUID"}(o||(o={}));var h,c,y,f,m,g=n(45724);function _(e){if(!e.spatialReference.isWGS84)throw new l.A("knowledge-graph:layer-support-utils","The extentToInBoundsRings function only supports WGS84 spatial references.");return e.clone().normalize().map((e=>[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]))}async function w(e,t){const n=[],r=new Map,s=[];if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&r.set(e.name,[]);for(const t of e)r.has(t.typeName)&&r.get(t.typeName)?.push(t.id);for(const[e,i]of r){if(i.length<1)continue;const r=new d.A({openCypherQuery:`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $ids RETURN id(n), labels(n)[0], id(m), labels(m)[0]`,bindParameters:{ids:i}});s.push((0,p.executeQueryStreaming)(t,r).then((async e=>{const t=e.resultRowsStream.getReader();for(;;){const{done:e,value:r}=await t.read();if(e)break;for(const e of r)n.push({id:e[0],typeName:e[1]}),n.push({id:e[2],typeName:e[3]})}})))}return await Promise.all(s),n}async function b(e,t){t??=!1;const n={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,a.A)(e,{responseType:"array-buffer"}),n=await t.data;return async function(e){const t=new((await(0,g.I)()).MapOfObjectIdentifierSetsDecoder),n=t.decode(new Uint8Array(e)),r=new Map;if(0!==n.error_code)throw new l.A("knowledge-graph:layer-support-utils",n.error_message);const s=t.get_map_of_identifier_sets(),i=s.keys,o=i.size();for(let e=0;e<o;e++){const t=i.get(e),n=s.query_identifier_set(t),o=[];if(n.id_array_type.value===f.GLOBALID_ARRAY){const e=n.get_globalid_array(),t=e.count();for(let n=0;n<t;n++)o.push(e.get_globalid_at(n))}else{if(n.id_array_type.value!==f.IDENTIFIER_ARRAY)throw new l.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=n.get_identifier_array(),t=e.count();for(let n=0;n<t;n++)o.push(e.get_identifier_at(n).toString())}}r.set(t,o)}return t.delete(),r}(new Uint8Array(n))}(e).then((e=>{!function(e,t){for(const[n,r]of e){const e=(0,u.tE)(t.namedTypeDefinitions,n,(()=>({useAllData:!1,members:new Map})));for(const t of r)e.members.has(t)||e.members.set(t,{id:t})}}(e,n)})),n}async function v(e){const t=await(0,g.I)(),n=new t.MapOfObjectIdentifierSets;!function(e,t,n){for(const[r,s]of n.namedTypeDefinitions){if(!s.members||s.useAllData)continue;const n=s.members.keys(),i=new t.GlobalIdArray,o=new t.ObjectIdentifierSet;for(const e of n)i.add_globalid(e);o.set_globalid_array(i),i.delete(),e.put_identifier_set(r,o),o.delete()}}(n,t,e);const r=new t.MapOfObjectIdentifierSetsEncoder;try{r.set_map_of_identifier_sets(n),r.encode();const e=r.get_encoding_result();if(0!==e.error.error_code)throw new l.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return r.delete(),t}finally{n.delete()}}n(35448),(m=h||(h={}))[m.featureResult=0]="featureResult",m[m.countResult=1]="countResult",m[m.idsResult=2]="idsResult",function(e){e[e.upperLeft=0]="upperLeft",e[e.lowerLeft=1]="lowerLeft"}(c||(c={})),function(e){e[e.sqlTypeBigInt=0]="sqlTypeBigInt",e[e.sqlTypeBinary=1]="sqlTypeBinary",e[e.sqlTypeBit=2]="sqlTypeBit",e[e.sqlTypeChar=3]="sqlTypeChar",e[e.sqlTypeDate=4]="sqlTypeDate",e[e.sqlTypeDecimal=5]="sqlTypeDecimal",e[e.sqlTypeDouble=6]="sqlTypeDouble",e[e.sqlTypeFloat=7]="sqlTypeFloat",e[e.sqlTypeGeometry=8]="sqlTypeGeometry",e[e.sqlTypeGUID=9]="sqlTypeGUID",e[e.sqlTypeInteger=10]="sqlTypeInteger",e[e.sqlTypeLongNVarchar=11]="sqlTypeLongNVarchar",e[e.sqlTypeLongVarbinary=12]="sqlTypeLongVarbinary",e[e.sqlTypeLongVarchar=13]="sqlTypeLongVarchar",e[e.sqlTypeNChar=14]="sqlTypeNChar",e[e.sqlTypeNVarChar=15]="sqlTypeNVarChar",e[e.sqlTypeOther=16]="sqlTypeOther",e[e.sqlTypeReal=17]="sqlTypeReal",e[e.sqlTypeSmallInt=18]="sqlTypeSmallInt",e[e.sqlTypeSqlXml=19]="sqlTypeSqlXml",e[e.sqlTypeTime=20]="sqlTypeTime",e[e.sqlTypeTimestamp=21]="sqlTypeTimestamp",e[e.sqlTypeTimestamp2=22]="sqlTypeTimestamp2",e[e.sqlTypeTinyInt=23]="sqlTypeTinyInt",e[e.sqlTypeVarbinary=24]="sqlTypeVarbinary",e[e.sqlTypeVarchar=25]="sqlTypeVarchar"}(y||(y={})),function(e){e[e.OID_ARRAY=0]="OID_ARRAY",e[e.GLOBALID_ARRAY=1]="GLOBALID_ARRAY",e[e.STRING_ARRAY=2]="STRING_ARRAY",e[e.IDENTIFIER_ARRAY=3]="IDENTIFIER_ARRAY"}(f||(f={}))},32756:(e,t,n)=>{n.d(t,{f:()=>u,n:()=>l});var r=n(90237),s=n(93637),i=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),a=n(91880);const l={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:function(e,t,n){if(!e)return null;const r=e.find((e=>!!e.field));if(!r)return null;const s=new a.A;return s.read(r,n),[s]}},write:{writer:function(e,t,n,r){const i=e.find((e=>!!e.field));i&&(0,s.sM)(n,[i.toJSON()],t)}}}},u=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,r._)([(0,i.MZ)(l)],t.prototype,"orderBy",void 0),t=(0,r._)([(0,o.$)("esri.layers.mixins.OrderedLayer")],t),t}},54310:(e,t,n)=>{n.d(t,{J:()=>w});var r=n(90237),s=(n(44208),n(53966)),i=n(74887),o=n(10107),a=n(79901),l=(n(87811),n(40608)),u=n(89317),p=n(5503),d=(n(60999),n(49186),n(14012),n(80559));const h=new p.A,c=new WeakMap;function y(e){(function(e){return null!=e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e})(e)&&h.push(new WeakRef(e))}function f(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:f(t,e%t):0}let m=0,g=0;function _(){const e=Date.now();let t=!1;for(const n of h){const r=n.deref();r?r.refreshInterval&&e-(c.get(r)??0)+5>=6e4*r.refreshInterval&&(c.set(r,e),r.refresh(e)):t=!0}if(t)for(let e=h.length-1;e>=0;e--)h.at(e).deref()||h.removeAt(e)}(0,d.fm)((()=>{const e=Date.now();let t=0;for(const n of h){const r=n.deref();r&&(t=f(Math.round(6e4*r.refreshInterval),t),r.refreshInterval?c.get(r)||c.set(r,e):c.delete(r))}if(t!==g){if(g=t,clearInterval(m),0===g)return void(m=0);m=setInterval(_,g)}}));const w=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,i.sg)((()=>this.hasDataChanged())),this.when().then((()=>{this.destroyed||y(this)}),(()=>{}))}destroy(){!function(e){const t=h.find((t=>t.deref()===e));t&&h.remove(t)}(this)}castRefreshInterval(e){return e>=.1?e:e<=0?0:.1}get refreshParameters(){return{_ts:this.refreshTimestamp||null}}refresh(e=Date.now()){(0,i.QZ)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{s.A.getLogger(this).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}get test(){}};return(0,r._)([(0,o.MZ)({type:Number,json:{write:!0,origins:{"web-scene":{write:{enabled:!0,layerContainerTypes:u.K}}}}})],t.prototype,"refreshInterval",void 0),(0,r._)([(0,a.w)("refreshInterval")],t.prototype,"castRefreshInterval",null),(0,r._)([(0,o.MZ)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,r._)([(0,o.MZ)({readOnly:!0})],t.prototype,"refreshParameters",null),t=(0,r._)([(0,l.$)("esri.layers.mixins.RefreshableLayer")],t),t}},20437:(e,t,n)=>{n.d(t,{A:()=>m});var r,s=n(90237),i=n(66552),o=n(25482),a=n(10107),l=n(56507),u=(n(87811),n(44208),n(93223)),p=n(36005),d=n(40608),h=n(72088),c=n(98453);const y=new i.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",dateAndTime:"date-and-time",description:"description",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let f=r=class extends o.oY{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?.value??null}readValueType(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?y.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,s._)([(0,a.MZ)({type:String,json:{write:!0}})],f.prototype,"alias",void 0),(0,s._)([(0,a.MZ)({type:[String,Number],json:{write:{allowNull:!0}}})],f.prototype,"defaultValue",void 0),(0,s._)([(0,a.MZ)()],f.prototype,"description",void 0),(0,s._)([(0,p.w)("description")],f.prototype,"readDescription",null),(0,s._)([(0,a.MZ)({types:h.gK,json:{read:{reader:h.rS},write:!0}})],f.prototype,"domain",void 0),(0,s._)([(0,a.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"editable",void 0),(0,s._)([(0,a.MZ)({type:l.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],f.prototype,"length",void 0),(0,s._)([(0,a.MZ)({type:String,json:{write:!0}})],f.prototype,"name",void 0),(0,s._)([(0,a.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"nullable",void 0),(0,s._)([(0,u.e)(c.m)],f.prototype,"type",void 0),(0,s._)([(0,a.MZ)()],f.prototype,"valueType",void 0),(0,s._)([(0,p.w)("valueType",["description"])],f.prototype,"readValueType",null),(0,s._)([(0,a.MZ)({type:Boolean,json:{read:!1}})],f.prototype,"visible",void 0),f=r=(0,s._)([(0,d.$)("esri.layers.support.Field")],f);const m=f},91880:(e,t,n)=>{n.d(t,{A:()=>d});var r,s=n(90237),i=n(66552),o=n(25482),a=n(10107),l=(n(44208),n(53966),n(87811),n(40608));const u=new i.J({asc:"ascending",desc:"descending"});let p=r=class extends o.oY{constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new r({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,s._)([(0,a.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,s._)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,s._)([(0,a.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],p.prototype,"order",void 0),p=r=(0,s._)([(0,l.$)("esri.layers.support.OrderByInfo")],p);const d=p},72088:(e,t,n)=>{n.d(t,{rS:()=>I,gK:()=>x}),n(44208);var r,s=n(90237),i=n(4718),o=n(10107),a=(n(53966),n(93223)),l=n(40608),u=n(25482);n(87811);let p=r=class extends u.oY{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,s._)([(0,o.MZ)({type:String,json:{write:!0}})],p.prototype,"name",void 0),(0,s._)([(0,o.MZ)({type:[String,Number],json:{write:!0}})],p.prototype,"code",void 0),p=r=(0,s._)([(0,l.$)("esri.layers.support.CodedValue")],p);const d=new(n(66552).J)({inherited:"inherited",codedValue:"coded-value",range:"range"});let h=class extends u.oY{constructor(e){super(e),this.name=null,this.type=null}};(0,s._)([(0,o.MZ)({type:String,json:{write:!0}})],h.prototype,"name",void 0),(0,s._)([(0,a.e)(d)],h.prototype,"type",void 0),h=(0,s._)([(0,l.$)("esri.layers.support.Domain")],h);const c=h;var y;let f=y=class extends c{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const n=String(e);this.codedValues.some((e=>(String(e.code)===n&&(t=e.name),!!t)))}return t}clone(){return new y({codedValues:(0,i.o8)(this.codedValues),name:this.name})}};(0,s._)([(0,o.MZ)({type:[p],json:{write:!0}})],f.prototype,"codedValues",void 0),(0,s._)([(0,a.e)({codedValue:"coded-value"})],f.prototype,"type",void 0),f=y=(0,s._)([(0,l.$)("esri.layers.support.CodedValueDomain")],f);const m=f;var g;n(49186);let _=g=class extends c{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,s._)([(0,a.e)({inherited:"inherited"})],_.prototype,"type",void 0),_=g=(0,s._)([(0,l.$)("esri.layers.support.InheritedDomain")],_);const w=_;var b;let v=b=class extends c{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new b({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,s._)([(0,o.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,n){t[n]=[this.minValue||0,e]}}}})],v.prototype,"maxValue",void 0),(0,s._)([(0,o.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,n){t[n]=[e,this.maxValue||0]}}}})],v.prototype,"minValue",void 0),(0,s._)([(0,a.e)({range:"range"})],v.prototype,"type",void 0),v=b=(0,s._)([(0,l.$)("esri.layers.support.RangeDomain")],v);const M=v,x={key:"type",base:c,typeMap:{range:v,"coded-value":m,inherited:w}};function I(e){if(!e?.type)return null;switch(e.type){case"range":return M.fromJSON(e);case"codedValue":return m.fromJSON(e);case"inherited":return w.fromJSON(e)}return null}},32730:(e,t,n)=>{n.d(t,{BI:()=>m,D3:()=>y,XJ:()=>f,lc:()=>c,mX:()=>_,rU:()=>g,tH:()=>x});var r=n(799);const s="__begin__",i="__end__",o=new RegExp(s,"ig"),a=new RegExp(i,"ig"),l=new RegExp("^"+s,"i"),u=new RegExp(i+"$","i"),p='"',d=p+" + ",h=" + "+p;function c(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function y(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function f(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=c(e.labelExpression),t.type="conventional"),t}function m(e){const t=f(e);if(!t)return null;switch(t.type){case"conventional":return _(t.expression);case"arcade":return t.expression}return null}function g(e){const t=f(e);if(!t)return null;switch(t.type){case"conventional":return function(e){const t=e?.match(w);return t?.[1].trim()||null}(t.expression);case"arcade":return x(t.expression)}return null}function _(e){let t;return e?(t=(0,r.HC)(e,(e=>s+'$feature["'+e+'"]'+i)),t=l.test(t)?t.replace(l,""):p+t,t=u.test(t)?t.replace(u,""):t+p,t=t.replaceAll(o,d).replaceAll(a,h)):t='""',t}const w=/^\s*\{([^}]+)\}\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,v=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,M=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function x(e){if(!e)return null;let t=b.exec(e)||v.exec(e);return t?t[1]||t[3]:(t=M.exec(e),t?t[2]:null)}},92300:(e,t,n)=>{n.d(t,{V:()=>i,X:()=>s});var r=n(65864);function s(e){return{geometryType:(0,r.$B)(e[0]),geometries:e.map((e=>e.toJSON()))}}function i(e,t,n){const s=(0,r.xD)(t);return e.map((e=>{const t=s.fromJSON(e);return t.spatialReference=n,t}))}},25927:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(90237),s=(n(59456),n(10107)),i=(n(44208),n(53966),n(87811),n(40608)),o=n(54238),a=n(86738);let l=class extends o.A{constructor(e){super(e),this.layoutGeometry=null}};(0,r._)([(0,s.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.Entity")],l);const u=l},54238:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(90237),s=n(10107),i=(n(44208),n(53966),n(87811),n(40608)),o=n(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a);const l=a},77901:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(90237),s=n(25482),i=n(10107),o=(n(44208),n(53966),n(87811),n(40608));let a=class extends s.oY{constructor(e){super(e),this.properties=null}};(0,r._)([(0,i.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,r._)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a);const l=a},42538:(e,t,n)=>{n.d(t,{A:()=>p});var r=n(90237),s=n(10107),i=(n(44208),n(53966),n(87811),n(40608)),o=n(69622);let a=class extends o.A{constructor(e){super(e),this.openCypherQuery=""}};(0,r._)([(0,s.MZ)()],a.prototype,"openCypherQuery",void 0),a=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQuery")],a);const l=a;let u=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,r._)([(0,s.MZ)()],u.prototype,"bindParameters",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"bindGeometryQuantizationParameters",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"outputQuantizationParameters",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"outputSpatialReference",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"provenanceBehavior",void 0),u=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],u);const p=u},40662:(e,t,n)=>{n.d(t,{A:()=>a});var r=n(90237),s=(n(53966),n(44208),n(87811),n(49186),n(40608)),i=n(77901);let o=class extends i.A{constructor(e){super(e)}};o=(0,r._)([(0,s.$)("esri.rest.knowledgeGraph.ObjectValue")],o);const a=o},42095:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(90237),s=n(25482),i=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),a=n(77901);let l=class extends s.oY{constructor(e){super(e),this.path=null}};(0,r._)([(0,i.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,r._)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l);const u=l},23150:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(90237),s=(n(59456),n(10107)),i=(n(44208),n(53966),n(87811),n(40608)),o=n(54238),a=n(82799);let l=class extends o.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,r._)([(0,s.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.Relationship")],l);const u=l},22671:(e,t,n)=>{n.d(t,{A:()=>w});var r,s=n(90237),i=n(59456),o=n(52106),a=n(66552),l=n(25482),u=n(4718),p=n(10107),d=(n(44208),n(53966),n(36005)),h=n(40608),c=n(43937),y=n(16930),f=n(65864),m=n(20437);const g=new a.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let _=r=class extends l.oY{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){const n=y.A.fromJSON(t.spatialReference),r=[];for(let t=0;t<e.length;t++){const s=e[t],i=o.A.fromJSON(s),a=s.geometry?.spatialReference;null==i.geometry||a||(i.geometry.spatialReference=n);const l=s.aggregateGeometries,u=i.aggregateGeometries;if(l&&null!=u)for(const e in u){const t=u[e],r=l[e],s=r?.spatialReference;null==t||s||(t.spatialReference=n)}r.push(i)}return r}writeGeometryType(e,t,n,r){if(e)return void g.write(e,t,n,r);const{features:s}=this;if(s)for(const e of s)if(null!=e?.geometry)return void g.write(e.geometry.type,t,n,r)}readQueryGeometry(e,t){if(!e)return null;const n=!!e.spatialReference,r=(0,f.rS)(e);return r&&!n&&t.spatialReference&&(r.spatialReference=y.A.fromJSON(t.spatialReference)),r}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:n}=this;if(n)for(const e of n)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new r(this.cloneProperties())}cloneProperties(){return(0,u.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let n=0;n<t.features.length;n++){const r=t.features[n];if(r.geometry){const t=e?.[n];r.geometry=t?.toJSON()||r.geometry}}return t}quantize(e){const{scale:[t,n],translate:[r,s]}=e,i=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-r)/t)),(e=>Math.round((s-e)/n)));for(let e=0,t=i.length;e<t;e++)o?.(i[e].geometry)||(i.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:n}=this;if(!n)return this;const{translate:[r,s],scale:[i,o]}=n;let a=null,l=null;if(this.hasZ&&null!=n?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=n;a=n=>n*t+e}if(this.hasM&&null!=n?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=n;l=n=>null==n?n:n*t+e}const u=this._getHydrationFunction(e,(e=>e*i+r),(e=>s-e*o),a,l);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}_quantizePoints(e,t,n){let r,s;const i=[];for(let o=0,a=e.length;o<a;o++){const a=e[o];if(o>0){const e=t(a[0]),o=n(a[1]);e===r&&o===s||(i.push([e-r,o-s]),r=e,s=o)}else r=t(a[0]),s=n(a[1]),i.push([r,s])}return i.length>0?i:null}_getQuantizationFunction(e,t,n){return"point"===e?e=>(e.x=t(e.x),e.y=n(e.y),e):"polyline"===e||"polygon"===e?e=>{const r=(0,f.Bi)(e)?e.rings:e.paths,s=[];for(let e=0,i=r.length;e<i;e++){const i=r[e],o=this._quantizePoints(i,t,n);o&&s.push(o)}return s.length>0?((0,f.Bi)(e)?e.rings=s:e.paths=s,e):null}:"multipoint"===e?e=>{const r=this._quantizePoints(e.points,t,n);return r&&r.length>0?(e.points=r,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,n,r,s){return"point"===e?e=>{e.x=t(e.x),e.y=n(e.y),r&&(e.z=r(e.z))}:"polyline"===e||"polygon"===e?e=>{const i=(0,f.Bi)(e)?e.rings:e.paths;let o,a;for(let e=0,r=i.length;e<r;e++){const r=i[e];for(let e=0,s=r.length;e<s;e++){const s=r[e];e>0?(o+=s[0],a+=s[1]):(o=s[0],a=s[1]),s[0]=t(o),s[1]=n(a)}}if(r&&s)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2]),n[3]=s(n[3])}}else if(r)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2])}}else if(s)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=s(n[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=n(e.ymin),e.xmax=t(e.xmax),e.ymax=n(e.ymax),r&&null!=e.zmax&&null!=e.zmin&&(e.zmax=r(e.zmax),e.zmin=r(e.zmin)),s&&null!=e.mmax&&null!=e.mmin&&(e.mmax=s(e.mmax),e.mmin=s(e.mmin))}:"multipoint"===e?e=>{const i=e.points;let o,a;for(let e=0,r=i.length;e<r;e++){const r=i[e];e>0?(o+=r[0],a+=r[1]):(o=r[0],a=r[1]),r[0]=t(o),r[1]=n(a)}if(r&&s)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=r(t[2]),t[3]=s(t[3])}else if(r)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=r(t[2])}else if(s)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=s(t[2])}}:null}};(0,s._)([(0,p.MZ)({type:String,json:{write:!0}})],_.prototype,"displayFieldName",void 0),(0,s._)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"exceededTransferLimit",void 0),(0,s._)([(0,p.MZ)({type:[o.A],json:{write:!0}})],_.prototype,"features",void 0),(0,s._)([(0,d.w)("features")],_.prototype,"readFeatures",null),(0,s._)([(0,p.MZ)({type:[m.A],json:{write:!0}})],_.prototype,"fields",void 0),(0,s._)([(0,p.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],_.prototype,"geometryType",void 0),(0,s._)([(0,c.K)("geometryType")],_.prototype,"writeGeometryType",null),(0,s._)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasM",void 0),(0,s._)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasZ",void 0),(0,s._)([(0,p.MZ)({types:i.yR,json:{write:!0}})],_.prototype,"queryGeometry",void 0),(0,s._)([(0,d.w)("queryGeometry")],_.prototype,"readQueryGeometry",null),(0,s._)([(0,p.MZ)({type:y.A,json:{write:!0}})],_.prototype,"spatialReference",void 0),(0,s._)([(0,c.K)("spatialReference")],_.prototype,"writeSpatialReference",null),(0,s._)([(0,p.MZ)({json:{write:!0}})],_.prototype,"transform",void 0),_=r=(0,s._)([(0,h.$)("esri.rest.support.FeatureSet")],_),_.prototype.toJSON.isDefaultToJSON=!0;const w=_},2272:(e,t,n)=>{n.d(t,{Dl:()=>o,jV:()=>i,lF:()=>a}),n(92602),n(70333);var r=n(4718),s=n(84952);function i(e,t){return t?{...t,query:{...e??{},...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,s.An)(e):(0,r.o8)(e)}function a(e,t,n){const r={};for(const s in e){if("declaredClass"===s)continue;const i=e[s];if(null!=i&&"function"!=typeof i)if(Array.isArray(i))r[s]=i.map((e=>a(e)));else if("object"==typeof i)if(i.toJSON){const e=i.toJSON(n?.[s]);r[s]=t?e:JSON.stringify(e)}else r[s]=t?i:JSON.stringify(i);else r[s]=i}return r}n(926)}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6289],{9775:(e,t,n)=>{n.d(t,{A:()=>i});var r=n(62788),s=n(95488);class i{constructor(e=(e=>e.values().next().value)){this._peeker=e,this._observable=new s.I,this._items=new Set}get length(){return(0,r.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let e;for(e of this._items);return e}peek(){if(0!==this.length)return this._peeker(this._items)}push(e){this.contains(e)||(this._items.add(e),this._observable.notify())}contains(e){return(0,r.gc)(this._observable),this._items.has(e)}pop(){if(0===this.length)return;const e=this.peek();return this._items.delete(e),this._observable.notify(),e}popLast(){if(0===this.length)return;const e=this.last();return this._items.delete(e),this._observable.notify(),e}remove(e){this.contains(e)&&(this._items.delete(e),this._observable.notify())}filter(e){const t=this.length;return this._items.forEach((t=>{e(t)||this._items.delete(t)})),t!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,r.gc)(this._observable),yield*this._items}}},75503:(e,t,n)=>{n.d(t,{w:()=>o});var r=n(4576),s=(n(44208),n(3694)),i=n(11006);class o{constructor(e=9,t){this._compareMinX=d,this._compareMinY=h,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),b.prune(),v.prune(),M.prune(),x.prune()}all(e){a(this._data,e)}search(e,t){let n=this._data;const r=this._toBBox;if(_(e,n))for(b.clear();n;){for(let s=0,i=n.children.length;s<i;s++){const i=n.children[s],o=n.leaf?r(i):i;_(e,o)&&(n.leaf?t(i):g(e,o)?a(i,t):b.push(i))}n=b.pop()}}collides(e){let t=this._data;const n=this._toBBox;if(!_(e,t))return!1;for(b.clear();t;){for(let r=0,s=t.children.length;r<s;r++){const s=t.children[r],i=t.leaf?n(s):s;if(_(e,i)){if(t.leaf||g(e,i))return!0;b.push(s)}}t=b.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,n=e.length;t<n;t++)this.insert(e[t]);return this}let t=this._build(e.slice(0,e.length),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new A([]),this}remove(e){if(!e)return this;let t,n=this._data,s=null,i=0,o=!1;const a=this._toBBox(e);for(M.clear(),x.clear();n||M.length>0;){if(n||(n=M.pop(),s=M.data[M.length-1],i=x.pop()??0,o=!0),n.leaf&&(t=(0,r.qh)(n.children,e,n.children.length,n.indexHint),-1!==t))return n.children.splice(t,1),M.push(n),this._condense(M),this;o||n.leaf||!g(n,a)?s?(i++,n=s.children[i],o=!1):n=null:(M.push(n),x.push(i),i=0,s=n,n=n.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,n,r){const s=n-t+1;let i=this._maxEntries;if(s<=i){const r=new A(e.slice(t,n+1));return l(r,this._toBBox),r}r||(r=Math.ceil(Math.log(s)/Math.log(i)),i=Math.ceil(s/i**(r-1)));const o=new E([]);o.height=r;const a=Math.ceil(s/i),u=a*Math.ceil(Math.sqrt(i));w(e,t,n,u,this._compareMinX);for(let s=t;s<=n;s+=u){const t=Math.min(s+u-1,n);w(e,s,t,a,this._compareMinY);for(let n=s;n<=t;n+=a){const s=Math.min(n+a-1,t);o.children.push(this._build(e,n,s,r-1))}}return l(o,this._toBBox),o}_insert(e,t,n){const r=this._toBBox,s=n?e:r(e);M.clear();const i=function(e,t,n,r){for(;r.push(t),!0!==t.leaf&&r.length-1!==n;){let n,r=1/0,s=1/0;for(let i=0,o=t.children.length;i<o;i++){const o=t.children[i],a=c(o),l=f(e,o)-a;l<s?(s=l,r=a<r?a:r,n=o):l===s&&a<r&&(r=a,n=o)}t=n||t.children[0]}return t}(s,this._data,t,M);for(i.children.push(e),p(i,s);t>=0&&M.data[t].children.length>this._maxEntries;)this._split(M,t),t--;!function(e,t,n){for(let r=n;r>=0;r--)p(t.data[r],e)}(s,M,t)}_split(e,t){const n=e.data[t],r=n.children.length,s=this._minEntries;this._chooseSplitAxis(n,s,r);const i=this._chooseSplitIndex(n,s,r);if(!i)return;const o=n.children.splice(i,n.children.length-i),a=n.leaf?new A(o):new E(o);a.height=n.height,l(n,this._toBBox),l(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(n,a)}_splitRoot(e,t){this._data=new E([e,t]),this._data.height=e.height+1,l(this._data,this._toBBox)}_chooseSplitIndex(e,t,n){let r,s,i;r=s=1/0;for(let o=t;o<=n-t;o++){const t=u(e,0,o,this._toBBox),a=u(e,o,n,this._toBBox),l=m(t,a),p=c(t)+c(a);l<r?(r=l,i=o,s=p<s?p:s):l===r&&p<s&&(s=p,i=o)}return i}_chooseSplitAxis(e,t,n){const r=e.leaf?this._compareMinX:d,s=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,n,r)<this._allDistMargin(e,t,n,s)&&e.children.sort(r)}_allDistMargin(e,t,n,r){e.children.sort(r);const s=this._toBBox,i=u(e,0,t,s),o=u(e,n-t,n,s);let a=y(i)+y(o);for(let r=t;r<n-t;r++){const t=e.children[r];p(i,e.leaf?s(t):t),a+=y(i)}for(let r=n-t-1;r>=t;r--){const t=e.children[r];p(o,e.leaf?s(t):t),a+=y(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const n=e.data[t];if(0===n.children.length)if(t>0){const s=e.data[t-1],i=s.children;i.splice((0,r.qh)(i,n,i.length,s.indexHint),1)}else this.clear();else l(n,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function a(e,t){let n=e;for(v.clear();n;){if(!0===n.leaf)for(const e of n.children)t(e);else v.pushArray(n.children);n=v.pop()??null}}function l(e,t){u(e,0,e.children.length,t,e)}function u(e,t,n,r,s){s||(s=new A([])),s.minX=1/0,s.minY=1/0,s.maxX=-1/0,s.maxY=-1/0;for(let i,o=t;o<n;o++)i=e.children[o],p(s,e.leaf?r(i):i);return s}function p(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function d(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function c(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function y(e){return e.maxX-e.minX+(e.maxY-e.minY)}function f(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function m(e,t){const n=Math.max(e.minX,t.minX),r=Math.max(e.minY,t.minY),s=Math.min(e.maxX,t.maxX),i=Math.min(e.maxY,t.maxY);return Math.max(0,s-n)*Math.max(0,i-r)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function _(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function w(e,t,n,r,s){const o=[t,n];for(;o.length;){const t=o.pop(),n=o.pop();if(t-n<=r)continue;const a=n+Math.ceil((t-n)/r/2)*r;(0,i.q)(e,a,n,t,s),o.push(n,a,a,t)}}const b=new s.A,v=new s.A,M=new s.A,x=new s.A({deallocator:void 0});class I{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class T extends I{constructor(){super(...arguments),this.height=1,this.indexHint=new r.vW}}class A extends T{constructor(e){super(),this.children=e,this.leaf=!0}}class E extends T{constructor(e){super(),this.children=e,this.leaf=!1}}},39516:(e,t,n)=>{async function r(e,t){const{WhereClause:r}=await Promise.all([n.e(835),n.e(4800)]).then(n.bind(n,50835));return r.create(e,t)}function s(e,t){return"1=1"===e?t??e:"1=1"===t?e??t:null!=e&&""!==e?null!=t&&""!==t?`(${e}) AND (${t})`:e:t}n.d(t,{G:()=>r,m:()=>s})},10382:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(36563),s=(n(44208),n(74887)),i=n(9775),o=n(72457),a=n(52268),l=n(61322);class u{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new i.A}destroy(){this.close()}get closed(){return!this._clients?.length}open(e,t){return new Promise(((n,r)=>{let i=!0;const o=e=>{(0,s.Te)(t.signal),i&&(i=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let i=0;i<e.length;++i){const a=e[i];(0,s.$X)(a)?this._clientPromises[i]=a.then((e=>(this._clients[i]=new l.default(e,t,this._ongoingJobsQueue),o(n),this._clients[i])),(()=>(o(r),null))):(this._clients[i]=new l.default(a,t,this._ongoingJobsQueue),this._clientPromises[i]=Promise.resolve(this._clients[i]),o(n))}}))}broadcast(e,t,n){const r=new Array(this._clientPromises.length);for(let s=0;s<this._clientPromises.length;++s){const i=this._clientPromises[s];r[s]=i.then((r=>r?.invoke(e,t,n)))}return r}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.resolver.reject((0,s.NK)(`Worker closing, aborting job calling '${e.methodName}'`));for(const e of this._clientPromises)e.then((e=>e?.close()));this._clients.length=0,this._clientPromises.length=0,this._inUseClients.length=0,(0,o.h)(this)}invoke(e,t,n){return this.apply(e,[t],n)}apply(e,t,n){const r=(0,s.Tw)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:n,resolver:r});for(let e=0;e<this._clientPromises.length;e++){const t=this._clients[e];t?t.jobAdded():this._clientPromises[e].then((e=>e?.jobAdded()))}return r.promise}createInvokeProxy(e){return(0,a.L)(this,e)}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,r.vE)(this._clients.map((n=>n.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let n=t.length;for(let r=0;r<this._clientPromises.length;++r)this._clientPromises[r].then((s=>{s&&(t[r]=s.openPort()),0==--n&&e(t)}))}))}get test(){}}},72457:(e,t,n)=>{n.d(t,{h:()=>i,k:()=>s});const r=new FinalizationRegistry((e=>{e.close()}));function s(e,t){r.register(e,t,t)}function i(e){r.unregister(e)}},29953:(e,t,n)=>{n.d(t,{ho:()=>G});var r=n(49186),s=n(44208),i=n(74887),o=n(10382),a=n(72457),l=n(61322),u=n(53966),p=n(97768),d=n(78888),h=n(84952);const c={async request(e,t){const n=e.options,r=n.responseType;n.signal=t?.signal,n.responseType="native"===r||"native-request-init"===r?"native-request-init":r&&["blob","json","text"].includes(r)&&(0,h.sC)(e.url)?.after?r:"array-buffer";const s=await(0,d.A)(e.url,n),i={data:s.data,httpStatus:s.httpStatus,ssl:s.ssl};switch(s.requestOptions?.responseType){case"native-request-init":return delete i.data.signal,i;case"blob":i.data=await i.data.arrayBuffer();break;case"json":i.data=(new TextEncoder).encode(JSON.stringify(i.data)).buffer;break;case"text":i.data=(new TextEncoder).encode(i.data).buffer}return{result:i,transferList:[i.data]}}};var y=n(8341),f=n(2741),m=n(92602),g=(n(47566),n(70333));const _={};var w=n(26390);class b{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...n)=>e[t](...n)}))}}class v{constructor(){this._dispatcher=new b,this._workerPostMessage({type:y.Go.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,w.d)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,n){this._dispatcher.addEventListener(e,t,n)}removeEventListener(e,t,n){this._dispatcher.removeEventListener(e,t,n)}_workerPostMessage(e){(0,w.d)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,y.VI)(e);if(t&&t.type===y.Go.OPEN){const{modulePath:e,jobId:n}=t;let r=await l.default.loadWorker(e);r||(r=await import(e));const s=l.default.connect(r);this._workerPostMessage({type:y.Go.OPENED,jobId:n,data:s})}}}var M=n(73444),x=n(18357);const I=()=>u.A.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:T}=y.Go;let A,E;const k="Failed to create Worker. Fallback to execute module in main thread";async function S(e){return new Promise((t=>{function n(s){const i=(0,y.VI)(s);i&&i.type===T&&(e.removeEventListener("message",n),e.removeEventListener("error",r),t(e))}function r(t){t.preventDefault(),e.removeEventListener("message",n),e.removeEventListener("error",r),I().warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new v).addEventListener("message",n),e.addEventListener("error",r)}e.addEventListener("message",n),e.addEventListener("error",r)}))}let N=0;const{ABORT:R,INVOKE:D,OPEN:j,OPENED:L,RESPONSE:O}=y.Go;class C{static async create(e){const t=await async function(){if(!(0,s.A)("esri-workers"))return S(new v);if(!A&&!E)try{const e='let globalId=0;const outgoing=new Map,configuration={CONFIGURATION};self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;let s=null;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());s=()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))},t.addEventListener("abort",s)}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})})).finally((()=>{t&&t.removeEventListener("abort",s)}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,fullVersion:r}=configuration.kernelInfo,{revision:t,fullVersion:n,version:s}=e.kernelInfo;esriConfig.assetsPath!==esriConfig.defaultAssetsPath&&o!==t&&console.warn(`Version mismatch detected between ArcGIS Maps SDK for JavaScript modules and assets. For more information visit https://bit.ly/3QnsuSo.\nModules version: ${r}\nAssets version: ${n??s}\nAssets path: ${esriConfig.assetsPath}`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let n;function t(e){const o=n.connect(e);self.postMessage({type:2,jobId:r,data:o},[o])}"function"==typeof define&&define.amd?require([workerPath],(e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((e=>(n=e.default,checkWorkerRevision(n),n.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):esriConfig.workers.useDynamicImport?import(workerPath).then((e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||import(o.modulePath))).then(t)})):(self.RemoteClient||importScripts(workerPath),n=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(n),n.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const s=outgoing.get(r);outgoing.delete(r),o.error?s.reject(JSON.parse(o.error)):s.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.split("{CONFIGURATION}").join(function(){let e;if(null!=m.A.default){const t={...m.A};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(m.A));e.assetsPath=(0,h.s2)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,h.s2)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,M.JK)(),e.has={"esri-csp-restrictions":(0,s.A)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,s.A)("esri-2d-update-debug"),"esri-2d-log-updating":(0,s.A)("esri-2d-log-updating"),"featurelayer-pbf":(0,s.A)("featurelayer-pbf"),"featurelayer-fast-triangulation-enabled":(0,s.A)("featurelayer-fast-triangulation-enabled"),"featurelayer-simplify-thresholds":(0,s.A)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,s.A)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,s.A)("featurelayer-simplify-mobile-factor"),"featurelayer-query-max-depth":(0,s.A)("featurelayer-query-max-depth"),"featurelayer-query-pausing-enabled":(0,s.A)("featurelayer-query-pausing-enabled"),"featurelayer-snapshot-enabled":(0,s.A)("featurelayer-snapshot-enabled"),"esri-atomics":(0,s.A)("esri-atomics"),"esri-shared-array-buffer":(0,s.A)("esri-shared-array-buffer"),"esri-tiles-debug":(0,s.A)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,s.A)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,s.A)("feature-polyline-generalization-factor"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,h.s2)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,h.s2)(e.workers.workerPath):e.workers.workerPath=(0,h.s2)((0,f.s)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=m.A.workers.loaderConfig,n=function(e){const t={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages?.concat()||[],paths:{..._.paths,...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=_.baseUrl),t}({baseUrl:t?.baseUrl,locale:(0,M.JK)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),r={buildDate:x.$,fullVersion:g.ol,revision:x.u};return JSON.stringify({esriConfig:e,loaderConfig:n,kernelInfo:r})}());A=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){E=e||{}}let e;if(A)try{e=new Worker(A,{name:"esri-worker-"+N++})}catch(t){I().warn(k,E),e=new v}else I().warn(k,E),e=new v;return S(e)}();return new C(t,e)}constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),u.A.getLogger("esri.core.workers.WorkerOwner").error(e)}))}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:n}=t,r=(0,y.Jc)();return new Promise(((t,s)=>{const o={resolve:t,reject:s,abortHandle:(0,i.NY)(n,(()=>{this._outJobs.delete(r),this._post({type:R,jobId:r})}))};this._outJobs.set(r,o),this._post({type:j,jobId:r,modulePath:e})}))}_onMessage(e){const t=(0,y.VI)(e);if(t)switch(t.type){case L:this._onOpenedMessage(t);break;case O:this._onResponseMessage(t);break;case R:this._onAbortMessage(t);break;case D:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,n=e.jobId,r=t.get(n);r&&(r.controller&&r.controller.abort(),t.delete(n))}_onInvokeMessage(e){const{methodName:t,jobId:n,data:r,abortable:s}=e,o=s?new AbortController:null,a=this._inJobs,l=c[t];let u;try{if("function"!=typeof l)throw new TypeError(`${t} is not a function`);u=l.call(null,r,{signal:o?o.signal:null})}catch(e){return void this._post({type:O,jobId:n,error:(0,y.mF)(e)})}(0,i.$X)(u)?(a.set(n,{controller:o,promise:u}),u.then((e=>{a.has(n)&&(a.delete(n),this._post({type:O,jobId:n},e))}),(e=>{a.has(n)&&(a.delete(n),e||(e={message:"Error encountered at method"+t}),(0,i.zf)(e)||this._post({type:O,jobId:n,error:(0,y.mF)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:O,jobId:n},u)}_onOpenedMessage(e){const{jobId:t,data:n}=e,r=this._outJobs.get(t);r&&(this._outJobs.delete(t),(0,p.xt)(r.abortHandle),r.resolve(n))}_onResponseMessage(e){const{jobId:t,error:n,data:s}=e,i=this._outJobs.get(t);i&&(this._outJobs.delete(t),(0,p.xt)(i.abortHandle),n?i.reject(r.A.fromJSON(JSON.parse(n))):i.resolve(s))}_post(e,t,n){return(0,y.u1)(this.worker,e,t,n)}}const B=(0,s.A)("host-browser")?Math.min(navigator.hardwareConcurrency-1,(0,s.A)("workers-pool-size")):0;let P=(0,s.A)("esri-mobile")?Math.min(B,3):B;P||(P=(0,s.A)("safari")&&(0,s.A)("mac")?7:2);let Z=0;const F=[];async function q(e,t){const n=new o.A,{registryTarget:r,...s}=t;return await n.open(e,s),r&&(0,a.k)(r,n),n}async function G(e,t={}){if("string"!=typeof e)throw new r.A("workers:undefined-module","modulePath is missing");let n=t.strategy||"distributed";if((0,s.A)("host-webworker")&&!(0,s.A)("esri-workers")&&(n="local"),"local"===n){let n=await l.default.loadWorker(e);n||(n=await import(e)),(0,i.Te)(t.signal);const r=t.client||n;return q([l.default.connect(n,t.schedule)],{...t,client:r})}if(await async function(){if(J)return J;$=new AbortController;const e=[];for(let t=0;t<P;t++){const n=C.create(t).then((e=>(F[t]=e,e)));e.push(n)}return J=Promise.all(e),J}(),(0,i.Te)(t.signal),"dedicated"===n){const n=Z++%P;return q([await F[n].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const n=Math.min(t.maxNumWorkers,P);if(n<P){const r=new Array(n);for(let s=0;s<n;++s){const n=Z++%P;r[s]=F[n].open(e,t)}return q(r,t)}}return q(F.map((n=>n.open(e,t))),t)}let $,J=null},17136:(e,t,n)=>{n.d(t,{el:()=>M});var r=n(92602),s=n(49186),i=n(53966),o=n(39829),a=n(82799),l=n(80754),u=n(21325),p=n(28735),d=(n(59456),n(78888)),h=n(65864),c=n(2272),y=n(84952),f=n(92300);const m=()=>i.A.getLogger("esri.geometry.support.normalizeUtils");function g(e){return"polygon"===e[0].type}function _(e){return"polyline"===e[0].type}function w(e,t,n){if(t){const t=function(e,t){if(!(e instanceof a.A||e instanceof o.A)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw m().error(e),new s.A(e)}const n=(0,l.r8)(e),r=[];for(const e of n){const n=[];r.push(n),n.push([e[0][0],e[0][1]]);for(let r=0;r<e.length-1;r++){const s=e[r][0],i=e[r][1],o=e[r+1][0],a=e[r+1][1],l=Math.sqrt((o-s)*(o-s)+(a-i)*(a-i)),u=(a-i)/l,p=(o-s)/l,d=l/t;if(d>1){for(let e=1;e<=d-1;e++){const r=e*t,o=p*r+s,a=u*r+i;n.push([o,a])}const e=(l+Math.floor(d-1)*t)/2,r=p*e+s,o=u*e+i;n.push([r,o])}n.push([o,a])}}return function(e){return"polygon"===e.type}(e)?new o.A({rings:r,spatialReference:e.spatialReference}):new a.A({paths:r,spatialReference:e.spatialReference})}(e,1e6);e=(0,p.ci)(t,!0)}return n&&(e=(0,l.kS)(e,n)),e}function b(e,t,n){if(Array.isArray(e)){const r=e[0];if(r>t){const n=(0,l.kd)(r,t);e[0]=r+n*(-2*t)}else if(r<n){const t=(0,l.kd)(r,n);e[0]=r+t*(-2*n)}}else{const r=e.x;if(r>t){const n=(0,l.kd)(r,t);e=e.clone().offset(n*(-2*t),0)}else if(r<n){const t=(0,l.kd)(r,n);e=e.clone().offset(t*(-2*n),0)}}return e}function v(e,t){let n=-1;for(let r=0;r<t.cutIndexes.length;r++){const s=t.cutIndexes[r],i=t.geometries[r],o=(0,l.r8)(i);for(let e=0;e<o.length;e++){const t=o[e];t.some((n=>{if(n[0]<180)return!0;{let n=0;for(let e=0;e<t.length;e++){const r=t[e][0];n=r>n?r:n}n=Number(n.toFixed(9));const r=-360*(0,l.kd)(n,180);for(let n=0;n<t.length;n++){const t=i.getPoint(e,n);i.setPoint(e,n,t.clone().offset(r,0))}return!0}}))}if(s===n){if(g(e))for(const t of(0,l.r8)(i))e[s]=e[s].addRing(t);else if(_(e))for(const t of(0,l.r8)(i))e[s]=e[s].addPath(t)}else n=s,e[s]=i}return e}async function M(e,t,n){if(!Array.isArray(e))return M([e],t);t&&"string"!=typeof t&&m().warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const s="string"==typeof t?t:t?.url??r.A.geometryServiceUrl;let i,g,_,x,I,T,A,E,k=0;const S=[],N=[];for(const t of e)if(null!=t)if(i||(i=t.spatialReference,g=(0,u.Vp)(i),_=i.isWebMercator,T=_?102100:4326,x=l.j7[T].maxX,I=l.j7[T].minX,A=l.j7[T].plus180Line,E=l.j7[T].minus180Line),g)if("mesh"===t.type)N.push(t);else if("point"===t.type)N.push(b(t.clone(),x,I));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>b(e,x,I))),N.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,g);N.push(e.rings?new o.A(e):e)}else if(t.extent){const e=t.extent,n=(0,l.kd)(e.xmin,I)*(2*x);let r=0===n?t.clone():(0,l.kS)(t.clone(),n);e.offset(n,0);let{xmin:s,xmax:i}=e;s=Number(s.toFixed(9)),i=Number(i.toFixed(9)),e.intersects(A)&&i!==x?(k=i>k?i:k,r=w(r,_),S.push(r),N.push("cut")):e.intersects(E)&&s!==I?(k=i*(2*x)>k?i*(2*x):k,r=w(r,_,360),S.push(r),N.push("cut")):N.push(r)}else N.push(t.clone());else N.push(t);else N.push(t);let R=(0,l.kd)(k,x),D=-90;const j=R,L=new a.A;for(;R>0;){const e=360*R-180;L.addPath([[e,D],[e,-1*D]]),D*=-1,R--}if(S.length>0&&j>0){const t=v(S,await async function(e,t,n,r){const s=(0,c.Dl)(e),i=t[0].spatialReference,o={...r,responseType:"json",query:{...s.query,f:"json",sr:(0,u.YX)(i),target:JSON.stringify({geometryType:(0,h.$B)(t[0]),geometries:t}),cutter:JSON.stringify(n)}},a=await(0,d.A)(s.path+"/cut",o),{cutIndexes:l,geometries:p=[]}=a.data;return{cutIndexes:l,geometries:p.map((e=>{const t=(0,h.rS)(e);return t.spatialReference=i,t}))}}(s,S,L,n)),r=[],i=[];for(let n=0;n<N.length;n++){const s=N[n];if("cut"!==s)i.push(s);else{const s=t.shift(),o=e[n];null!=o&&"polygon"===o.type&&o.rings&&o.rings.length>1&&s.rings.length>=o.rings.length?(r.push(s),i.push("simplify")):i.push(_?(0,p.Gh)(s):s)}}if(!r.length)return i;const o=await async function(e,t,n){const r="string"==typeof e?(0,y.An)(e):e,s=t[0].spatialReference,i=(0,h.$B)(t[0]),o={...n,query:{...r.query,f:"json",sr:(0,u.YX)(s),geometries:JSON.stringify((0,f.X)(t))}},{data:a}=await(0,d.A)(r.path+"/simplify",o);return(0,f.V)(a.geometries,i,s)}(s,r,n),a=[];for(let e=0;e<i.length;e++){const t=i[e];"simplify"!==t?a.push(t):a.push(_?(0,p.Gh)(o.shift()):o.shift())}return a}const O=[];for(let e=0;e<N.length;e++){const t=N[e];if("cut"!==t)O.push(t);else{const e=S.shift();O.push(!0===_?(0,p.Gh)(e):e)}}return O}},80754:(e,t,n)=>{n.d(t,{j7:()=>o,kS:()=>l,kd:()=>a,r8:()=>u});var r=n(82799),s=n(16930),i=n(65864);const o={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new r.A({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:s.A.WebMercator}),minus180Line:new r.A({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:s.A.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new r.A({paths:[[[180,-180],[180,180]]],spatialReference:s.A.WGS84}),minus180Line:new r.A({paths:[[[-180,-180],[-180,180]]],spatialReference:s.A.WGS84})}};function a(e,t){return Math.ceil((e-t)/(2*t))}function l(e,t){const n=u(e);for(const e of n)for(const n of e)n[0]+=t;return e}function u(e){return(0,i.Bi)(e)?e.rings:e.paths}},6518:(e,t,n)=>{n.d(t,{F:()=>a});var r=n(44208),s=n(75503),i=n(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new s.w(9,(0,r.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((n,r)=>{e[t++]=r})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,i.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,n){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,n)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},83221:(e,t,n)=>{n.d(t,{A:()=>y});var r=n(4576),s=n(49186),i=n(65529),o=n(53966),a=n(70328),l=n(19419),u=n(90708),p=n(6518),d=n(51441),h=n(37730);const c=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new p.F,this._featuresById=new Map,this._markedIds=new Set,this.events=new i.A,this.featureAdapter=h.T}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 e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,n,r,s]=this.fullBounds;return{xmin:t,ymin:n,xmax:r,ymax:s,spatialReference:(0,d.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(r.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const n of e){const e=this._boundsStore.get(n.objectId);e&&t((0,a.Jt)(c,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}startMarkingUsedFeatures(){this._boundsStore.invalidateIndex(),this._markedIds.clear()}sweep(){let e=!1;this._featuresById.forEach(((t,n)=>{this._markedIds.has(n)||(e=!0,this._remove(t))})),this._markedIds.clear(),e&&this._emitChanged()}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const n=this._featuresById.get(t);let r;if(this._markedIds.add(t),n?(e.displayId=n.displayId,r=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);r=(0,u.jQ)(null!=r?r:(0,l.vt)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=r&&this._boundsStore.set(t,r),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new s.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const n=this._featuresById.get(t);if(!n)return this._add(e),e;this._markedIds.add(t);const{geometry:r,attributes:i}=e;for(const e in i)n.attributes[e]=i[e];return r&&(n.geometry=r,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),r,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),n}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._markedIds.delete(t),this._boundsStore.delete(t),this._featuresById.delete(t),e}}},64714:(e,t,n)=>{n.d(t,{F0:()=>a,Vx:()=>p,e2:()=>h,f:()=>c});var r=n(44208),s=n(4718),i=n(99352),o=n(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function p(e,t){if((0,r.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${d(t)} = null;`;for(const t in e)n+=`this${d(t)} = ${JSON.stringify(e[t])};`;const r=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new r}catch(n){return()=>({[t]:null,...e})}}function d(e){return l.test(e)?`.${e}`:`["${e}"]`}function h(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,s.o8)(e)}}]}function c(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:i.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},61184:(e,t,n)=>{n.d(t,{PB:()=>k,d4:()=>E,ZL:()=>T,sZ:()=>A,yC:()=>x,Vr:()=>I});var r=n(90237),s=(n(59456),n(69622)),i=n(49186),o=n(53966),a=n(91869),l=n(39516),u=n(10107),p=(n(44208),n(87811),n(40608)),d=n(39829),h=n(57251),c=n(21325),y=n(90708),f=n(43334),m=n(65864);class g{constructor(){this._featureLookup=new Map}static getInstance(){return g.instance||(g.instance=new g),g.instance}static resetInstance(){g.instance&&(g.instance=null)}deleteFromStore(e){e.forEach((e=>{this._featureLookup.delete(e)}))}readFromStoreByList(e){const t=[];return e.forEach((e=>{const n=this.readFromStoreById(e);n&&t.push(n)})),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,n){const r=[];return e.forEach((e=>{if(!e?.id)return;e.properties||(e.properties=[]);let s,i=null;if(n&&e.properties[n]&&(i=(0,y.Ux)(e.properties[n])),"originId"in e&&"destinationId"in e&&(e.properties.ESRI__ORIGIN_ID=e.originId,e.properties.ESRI__DESTINATION_ID=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const r=this._featureLookup.get(e.id),o=JSON.parse(JSON.stringify(Object.assign(r.attributes,e.properties)));n&&e.properties[n]&&(o[n]=(0,m.rS)(e.properties[n])),s=new f.Om(i?JSON.parse(JSON.stringify(i)):r?.geometry?JSON.parse(JSON.stringify(r.geometry)):null,o,null,e.properties[t])}else s=new f.Om(i?JSON.parse(JSON.stringify(i)):null,e.properties,null,e.properties[t]);this._featureLookup.set(e.id,s),r.push(s)})),r}}var _=n(45654),w=n(71932),b=n(42538),v=n(61956),M=n(5443);const x="ESRI__ID",I="ESRI__ORIGIN_ID",T="ESRI__DESTINATION_ID",A="ESRI__LAYOUT_GEOMETRY",E="ESRI__AGGREGATION_COUNT";let k=class extends s.A{constructor(e){super(e),this._processingCacheUpdatesLookup=new Map,this.knowledgeGraph=null,this.inclusionModeDefinition={generateAllSublayers:!0,namedTypeDefinitions:new Map},this.entityTypeNames=new Set,this.relationshipTypeNames=new Set,this.geographicLookup=new Map,this.sublayerCaches=new Map,this.nodeConnectionsLookup=new Map,this.relationshipConnectionsLookup=new Map,this.memberIdTypeLookup=new Map;const t=new Map;e.knowledgeGraph.dataModel.entityTypes?.forEach((n=>{n.name&&(t.set(n.name,"entity"),this._processingCacheUpdatesLookup.set(n.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(n.name),n.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(n.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.knowledgeGraph.dataModel.relationshipTypes?.forEach((n=>{n.name&&(t.set(n.name,"relationship"),this._processingCacheUpdatesLookup.set(n.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(n.name),n.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(n.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.inclusionModeDefinition?.namedTypeDefinitions.forEach(((n,r)=>{if("entity"===t.get(r))this.entityTypeNames.add(r);else{if("relationship"!==t.get(r))return o.A.getLogger(this).warn(`A named type, ${r}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(r);this.relationshipTypeNames.add(r)}const s=new Map;n.members?.forEach((e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,(()=>new Set)).add(r);const t=this.getById(e.id);t&&s.set(e.id,t)})),this.sublayerCaches.set(r,s)}))}addToLayer(e){e.forEach((({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new i.A("knowledge-graph:layer-data-manager","You cannot add to a layer's exclusion list if it was not created with an exclusion list originally");if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){const n=this.inclusionModeDefinition.namedTypeDefinitions.get(e);n.members||(n.members=new Map),n.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}else{const n=new Map;n.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:n}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}))}getById(e){return g.getInstance().readFromStoreById(e)}async getData(e,t,n){if(t.objectType.name&&this.inclusionModeDefinition?.namedTypeDefinitions&&this.inclusionModeDefinition.namedTypeDefinitions.size>0&&!this.inclusionModeDefinition.namedTypeDefinitions.has(t.objectType.name))return[];let r;if(r=e||new v.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,n=this._processingCacheUpdatesLookup.get(t.objectType.name??""),s=r.outFields;s&&1===s.length&&s[0]===x&&"1=1"===r.where||await Promise.all(n??[]);const i=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return i.forEach((n=>{this.relationshipTypeNames.has(t.objectType.name)?n.geometry=e.relationshipLinkChartDiagramLookup.get(n.attributes[t.objectIdField]):n.geometry=e.entityLinkChartDiagramLookup.get(n.attributes[t.objectIdField]),n.attributes[A]=n.geometry,o.push(n)})),o}return this.retrieveDataFromService(r,t,n)}async getConnectedRecordIds(e,t){const n=[];let r="";const s=[],i=new Map;if(e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(t))return;i.has(t)?i.get(t)?.push(e):i.set(t,[e])}})),t&&0!==t?.length){for(const e of t)r=r+e+"|";r=r.slice(0,-1)}return i.forEach(((e,i)=>{let a;a=t&&0!==t?.length?`MATCH (n:${i})-[r:${r}]-(m) WHERE id(n) IN $ids RETURN id(r), type(r), id(m), labels(m)[0]`:`MATCH (n:${i})-[r]-(m) WHERE id(n) IN $ids RETURN id(r), type(r), id(m), labels(m)[0]`;const l=new Promise((t=>{(async()=>{const t=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:a,bindParameters:{ids:e}}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:r}=await t.read();if(e)break;for(let e=0;e<r.length;e++){const t=r[e];n.push({id:t[0],typeName:t[1]}),n.push({id:t[2],typeName:t[3]})}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}})().then((()=>{t()}))}));s.push(l)})),this.refreshCacheContent(),await Promise.all(s),n}async getAttachedRelationships(e,t){const n=[],r=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new b.A({openCypherQuery:"MATCH (n)-[r]->(m) WHERE id(n) IN $nodeIds AND id(m) in $nodeIds AND NOT id(r) IN $relationshipExclusionIds return id(r), type(r)",bindParameters:{nodeIds:e,relationshipExclusionIds:t}}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:t}=await r.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];n.push({id:r[0],typeName:r[1]})}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}return n}async refreshCacheContent(e,t,n,r=!0){const s=g.getInstance(),o=[],l=new Map,u=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&u.set(e.name,e)})),this.knowledgeGraph.dataModel.relationshipTypes?.forEach((e=>{e.name&&u.set(e.name,e)})),e||this.inclusionModeDefinition?e?e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e))l.has(t)?l.get(t)?.push(e):l.set(t,[e])})):this.inclusionModeDefinition?.namedTypeDefinitions?.forEach(((e,t)=>{e.useAllData?l.set(t,null):e.members&&e.members.forEach((e=>{l.has(t)&&null!==l.get(t)?l.get(t)?.push(e.id):l.set(t,[e.id])}))})):(this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&l.set(e.name,null)})),this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&l.set(e.name,null)})));for(const[e,p]of l){const l=new Promise((o=>{(async()=>{const o=new Set,l=[];let d,h="",c=!1;if(t||u.get(e)?.properties?.forEach((e=>{e.name&&o.add(e.name)})),n&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&o.add(t)}if(this.entityTypeNames.has(e))h=`MATCH (n:${e}) ${p?"WHERE id(n) IN $ids ":""}return ID(n)`,o.forEach((e=>{h+=`, n.${e}`,l.push(e)}));else{if(!this.relationshipTypeNames.has(e))throw new i.A("knowledge-graph:layer-data-manager",`The graph type of ${e} could not be determined. Was this type set in the KG data model and inclusion definition?`);c=!0,h=`MATCH ()-[n:${e}]->() ${p?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,o.forEach((e=>{h+=`, n.${e}`,l.push(e)}))}d=new b.A(p?{openCypherQuery:h,bindParameters:{ids:p}}:{openCypherQuery:h});const y=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,d)).resultRowsStream.getReader();for(;;){const{done:t,value:n}=await y.read();if(t)break;const i=[];for(let e=0;e<n.length;e++){const t=n[e];let r=0,s=0;const o={properties:{}};for(o.id=t[r],r++,s++,c&&(o.originId=t[r],r++,s++,o.destinationId=t[r],r++,s++,(0,a.tE)(this.nodeConnectionsLookup,o.originId,(()=>new Set)).add(o.id),(0,a.tE)(this.nodeConnectionsLookup,o.destinationId,(()=>new Set)).add(o.id),(0,a.tE)(this.relationshipConnectionsLookup,o.id,(()=>[o.originId,o.destinationId])));r<t.length;r++)o.properties[l[r-s]]=t[r];i.push(o)}const o=s.writeToStore(i,x,this.geographicLookup.get(e)?.name);this.sublayerCaches.has(e)||this.sublayerCaches.set(e,new Map),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.has(e)&&this.inclusionModeDefinition?.namedTypeDefinitions.set(e,{useAllData:!1,members:new Map}),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members&&(this.inclusionModeDefinition.namedTypeDefinitions.get(e).members=new Map);const u=this.sublayerCaches.get(e);o.forEach((t=>{u?.set(t.attributes[x],t),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[x])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[x],{id:t.attributes[x]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[x],(()=>new Set)).add(e))}))}})().then((()=>{o(null)}))}));o.push(l),this._processingCacheUpdatesLookup.get(e)?.push(l)}await Promise.all(o)}removeFromLayer(e){const t=new Set,n=new Set(e.map((e=>e.id)));for(const n of e)t.add(n.typeName),1===this.memberIdTypeLookup.get(n.id)?.size?this.memberIdTypeLookup.delete(n.id):this.memberIdTypeLookup.get(n.id)?.delete(n.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach(((e,t)=>{t===n.typeName&&e.members?.has(n.id)&&e.members.delete(n.id)}));t.forEach((e=>{this.sublayerCaches.get(e)?.forEach(((t,r)=>{n.has(r)&&this.sublayerCaches.get(e)?.delete(r)}))}))}async retrieveDataFromService(e,t,n){const r=g.getInstance(),s=new Set,o=[];let a,u="",p=[];const y="relationship"===t.graphType,f=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,m=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let v=!f&&m?Array.from(m).sort():null;if(this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData)this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData&&null!=e.objectIds&&(v=e.objectIds);else if(null!=e.objectIds&&v&&v.length>0){const t=e.objectIds;e.objectIds=v.filter((e=>t.includes(e)))}else if(null!=e.objectIds)v=e.objectIds;else{if(this.inclusionModeDefinition?.namedTypeDefinitions.has(t.objectType.name)&&(!this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members||this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members?.size<1))return e.objectIds=[],[];e.objectIds=v}if(null!=e.outFields){const n=e.outFields;n.includes("*")?t.fields.forEach((e=>{s.add(e.name)})):n.forEach((e=>{e!==x&&e!==t.geometryFieldName&&s.add(e)}))}if(null!=e.geometry){const n=e.geometry;let r;const p=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,f=p?.spatialReference,m=p?.serviceCapabilities?.geometryCapabilities;let g=m?.geometryMaxBoundingRectangleSizeX,w=m?.geometryMaxBoundingRectangleSizeY;if(n?.extent?.spatialReference&&!n.spatialReference?.isWGS84?(await(0,h.initializeProjection)(n.extent.spatialReference,c.KK),r=(0,h.project)(n.extent,c.KK)):r=n.extent,g&&w&&f){if(4326!==f.wkid){const e=new M.A({spatialReference:f,xmax:g,ymax:w}),t=(0,h.project)(e,c.KK);g=t.xmax,w=t.ymax}if(r.xmax-r.xmin>g)throw new i.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${g}° latitude, limit exceeded`);if(r.ymax-r.ymin>w)throw new i.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${w}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const n=await(0,l.G)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach((e=>{n.fieldNames.includes(e.name)&&s.add(e.name)}))}u=y?`Match ()-[n:${t.objectType.name}]->() WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n), id(startNode(r)), id(endNode(r))`:`Match (n:${t.objectType.name}) WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n)`,t.geometryFieldName&&s.add(t.geometryFieldName),s.forEach((e=>{u+=`, n.${e}`,o.push(e)})),a=new b.A({openCypherQuery:u,bindParameters:{param_filter_geom:new d.A({rings:(0,_.DX)(r)})}})}else{let n="";if(null!=e.where&&"1=1"!==e.where){const r=await(0,l.G)(e.where,t.fieldsIndex);t.fields.forEach((e=>{r.fieldNames.includes(e.name)&&s.add(e.name)}));const i=new Set(["column-reference","string","number","binary-expression"]),o=new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]);let a=!1;const u=e=>{if("column-reference"===e.type)return`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&i.has(e.left.type)&&i.has(e.right.type)&&o.has(e.operator))return`${u(e.left)} ${e.operator} ${u(e.right)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let t="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)t+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return a=!0,"";t+=`lower(n.${e.left.column})`}if(t+=" CONTAINS (","string"!==e.right.type)return a=!0,"";{let n=e.right.value;"%"===n.charAt(0)&&(n=n.slice(1)),"%"===n.charAt(n.length-1)&&(n=n.slice(0,-1)),t+=`'${n.toLowerCase()}')`}return t}return a=!0,""};n=u(r.parseTree),a&&(n="")}let r="";r=y?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let i=!1;v&&(i=!0,r+=" WHERE ID(n) IN $ids"),n&&(r+=i?" AND":" WHERE",r+=` ${n}`),r+=" return ID(n)",y&&(r+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&s.add(t.geometryFieldName),s.forEach((e=>{r+=`, n.${e}`,o.push(e)})),a=new b.A(v?{openCypherQuery:r,bindParameters:{ids:v}}:{openCypherQuery:r})}const I=(await(0,w.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,n)).resultRowsStream.getReader();for(;;){const{done:e,value:n}=await I.read();if(e)break;const s=[];for(let e=0;e<n.length;e++){const t=n[e];let r=0,i=0;const a={properties:{}};for(a.id=t[r],r++,i++,y&&(a.originId=t[r],r++,i++,a.destinationId=t[r],r++,i++);r<t.length;r++)a.properties[o[r-i]]=t[r];s.push(a)}p=p.concat(r.writeToStore(s,x,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return p}};(0,r._)([(0,u.MZ)()],k.prototype,"knowledgeGraph",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"inclusionModeDefinition",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"entityTypeNames",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"relationshipTypeNames",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"geographicLookup",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"sublayerCaches",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"nodeConnectionsLookup",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"relationshipConnectionsLookup",void 0),(0,r._)([(0,u.MZ)()],k.prototype,"memberIdTypeLookup",void 0),k=(0,r._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],k)},70643:(e,t,n)=>{n.d(t,{A:()=>H});var r=n(90237),s=(n(59456),n(13874)),i=(n(86162),n(94409),n(65345),n(42980),n(39290),n(92438),n(96576),n(93618),n(65494)),o=n(15036),a=n(4718),l=n(92071),u=(n(29953),n(10107)),p=(n(44208),n(53966),n(40608)),d=n(43937),h=n(35666),c=n(57251),y=n(16930),f=n(21325),m=n(4146),g=n(83221),_=n(17970),w=n(64714),b=n(61184);n(87811);const v=(0,n(17036).p)(),M=e=>{let t=class extends e{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,r._)([(0,u.MZ)(v.fields)],t.prototype,"fields",void 0),(0,r._)([(0,u.MZ)(v.fieldsIndex)],t.prototype,"fieldsIndex",void 0),t=(0,r._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],t),t};var x=n(63074),I=n(87718),T=n(76294),A=n(32756),E=n(54310),k=n(25036),S=n(82935),N=n(10873),R=n(13213),D=n(20437),j=n(30524),L=n(81457),O=n(39383),C=n(22671),B=n(61956),P=n(30291),Z=n(61322),F=n(5443),q=n(39829),G=n(82799),$=n(50498);function J(e){if(!e.json)return e;e.json.write=Y(e.json.write);const t=e.json.origins;if(!t)return e;let n;for(n in t){const e=t[n];e&&(e.write=Y(e.write))}return e}function Y(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:n,overridePolicy:r,...s}=e;return function(e,t){const n=Q.call(this,e,t);return n.enabled?{...s,...n}:n}}(e)),e):!0===e?V():e}function V(){return{overridePolicy:Q}}function Q(e,t){const n=!!this.geometryType;let r={enabled:n};return n&&(r={...r,...X.call(this,e,t)}),r}function X(e,t){return{ignoreOrigin:this.originIdOf(t)>h.Gr.DEFAULTS}}let U=class extends(M((0,T.J)((0,I.F)((0,x.dM)((0,A.f)((0,S.e)((0,k.j)((0,E.J)((0,l.P)(m.A)))))))))){constructor(e){super(e),this.blendMode="normal",this.capabilities=(0,w.f)(!1,!1),this.charts=null,this.definitionExpression=null,this.displayField="",this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.labelingInfo=null,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=b.yC,this.objectType=null,this.opacity=1,this.orderBy=null,this.parentCompositeLayer=null,this.persistenceEnabled=!0,this.popupEnabled=!0,this.popupTemplate=null,this.refreshInterval=0,this.source={openPorts:()=>this.load().then((()=>{const e=new MessageChannel;return new Z.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const n=B.A.fromJSON(e);return this.queryFeaturesJSON(n,t)}}}),[e.port2]}))},this.title=null,this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get defaultPopupTemplate(){return this.createPopupTemplate()}set featureReduction(e){const t=this._normalizeFeatureReduction(e);this._set("featureReduction",t)}get fields(){const e=[];return this.objectType?.properties?.forEach((t=>{const n="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(D.A.fromJSON({name:t.name,type:n,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))})),e.push(D.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),D.A.fromJSON({name:b.d4,type:"esriFieldTypeInteger",alias:b.d4,editable:!1})),e}get geometryType(){if("link-chart"===this.parentCompositeLayer?.type)return"relationship"===this.graphType?"polyline":"point";const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.geometryType;return t&&"esriGeometryNull"!==t?$.g.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return b.sZ;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphTypeName(){return this.objectType?.name}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,n=t?this.objectType?.properties?.[t]:null;return n?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,n=t?this.objectType?.properties?.[t]:null;return n?.hasZ??!1}set renderer(e){(0,j.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){return this._isOverridden("renderer")?this._get("renderer"):"link-chart"===this.parentCompositeLayer?.type?"relationship"===this.graphType?(0,i.r)((0,w.F0)($.g.toJSON("polyline")).renderer):(0,i.r)((0,w.F0)($.g.toJSON("point")).renderer):(0,i.r)((0,w.F0)($.g.toJSON(this.geometryType)).renderer)}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??y.A.WGS84}writeTitle(e,t){t.title=e??"Layer"}createPopupTemplate(e){return(0,P.tn)(this,e)}createQuery(){return new B.A({where:"1=1",outFields:["*"]})}getField(e){for(let t=0;t<this.fields.length;t++)if(this.fields[t].name===e)return this.fields[t];return null}getFieldDomain(e,t){return null}async queryFeatures(e,t){const{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(e),s=C.A.fromJSON(await r.executeQuery(n.toJSON(),t?.signal));return s.features.forEach((e=>{e.sourceLayer=this})),s}async queryFeaturesJSON(e,t){const{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(e);return await r.executeQuery(n.toJSON(),t?.signal)}async queryFeatureCount(e,t){const{resolvedQuery:n,queryEngine:r}=await this._setupQueryObjects(e);return r.executeQueryForCount(n.toJSON(),t?.signal)}async queryExtent(e={},t){const n={...e,returnGeometry:!0},{resolvedQuery:r,queryEngine:s}=await this._setupQueryObjects(n),i=await s.executeQueryForExtent(r.toJSON(),t?.signal);let o;return o=null!=i.extent?.xmin&&null!=i.extent?.xmax&&null!=i.extent?.ymin&&null!=i.extent?.ymax?new F.A(i.extent):new F.A,{count:i.count,extent:o}}async queryObjectIds(e,t){const n=B.A.from(e);let r;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)r=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(n,this,t);r=this.loadQueryEngine(e)}return r.executeQueryForIds(n.toJSON(),t?.signal)}loadQueryEngine(e){const t=new g.A({geometryType:$.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),n=new _.d({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:$.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,objectIdField:this.objectIdField,spatialReference:this.spatialReference.toJSON(),timeInfo:null,featureStore:t});return n.featureStore.addMany(e),n}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new B.A({where:"1=1",outFields:[b.yC]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}async _setupQueryObjects(e,t){const n=B.A.from(e),r=n.geometry;let s;if(r&&!r.spatialReference?.isWGS84&&(await(0,c.initializeProjection)(r.spatialReference,f.KK),n.geometry=(0,c.project)(r instanceof q.A||r instanceof G.A?r:r.extent,f.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)s=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(n,this,t);s=this.loadQueryEngine(e)}return{resolvedQuery:n,queryEngine:s}}};(0,r._)([(0,u.MZ)(J((0,a.o8)(x.sU)))],U.prototype,"blendMode",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"capabilities",void 0),(0,r._)([(0,u.MZ)({json:{origins:{"web-scene":{write:!1}},write:V()}})],U.prototype,"charts",void 0),(0,r._)([(0,u.MZ)({readOnly:!0})],U.prototype,"defaultPopupTemplate",null),(0,r._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],U.prototype,"definitionExpression",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"displayField",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(x.LF)))],U.prototype,"effect",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"elevationInfo",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(I.Y)))],U.prototype,"featureEffect",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(R.d)))],U.prototype,"featureReduction",null),(0,r._)([(0,u.MZ)()],U.prototype,"fields",null),(0,r._)([(0,u.MZ)()],U.prototype,"geometryType",null),(0,r._)([(0,u.MZ)()],U.prototype,"geometryFieldName",null),(0,r._)([(0,u.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],U.prototype,"graphType",void 0),(0,r._)([(0,u.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],U.prototype,"graphTypeName",null),(0,r._)([(0,u.MZ)()],U.prototype,"hasM",null),(0,r._)([(0,u.MZ)()],U.prototype,"hasZ",null),(0,r._)([(0,u.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],U.prototype,"id",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.kF)))],U.prototype,"labelsVisible",void 0),(0,r._)([(0,u.MZ)({type:[L.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:O.w,write:V()}})],U.prototype,"labelingInfo",void 0),(0,r._)([(0,u.MZ)({readOnly:!0,json:{read:!1,write:{writer(e,t){t.layerType=this.geometryType?"KnowledgeGraphSubLayer":"KnowledgeGraphSubTable"},isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],U.prototype,"layerType",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.fV)))],U.prototype,"legendEnabled",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.hG)))],U.prototype,"maxScale",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.hn)))],U.prototype,"minScale",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"objectIdField",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"objectType",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.ke)))],U.prototype,"opacity",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(A.n)))],U.prototype,"orderBy",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"parentCompositeLayer",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(N.M6)))],U.prototype,"popupEnabled",void 0),(0,r._)([(0,u.MZ)({type:s.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],U.prototype,"popupTemplate",void 0),(0,r._)([(0,u.MZ)({type:Number,json:{write:{overridePolicy:X}}})],U.prototype,"refreshInterval",void 0),(0,r._)([(0,u.MZ)({types:o.H,json:{name:"layerDefinition.drawingInfo.renderer",write:V()}})],U.prototype,"renderer",null),(0,r._)([(0,u.MZ)()],U.prototype,"source",void 0),(0,r._)([(0,u.MZ)()],U.prototype,"spatialReference",null),(0,r._)([(0,u.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],U.prototype,"title",void 0),(0,r._)([(0,d.K)("title")],U.prototype,"writeTitle",null),(0,r._)([(0,u.MZ)({json:{read:!1}})],U.prototype,"type",void 0),(0,r._)([(0,u.MZ)(J((0,a.o8)(S.B)))],U.prototype,"useViewTime",void 0),(0,r._)([(0,u.MZ)({type:Boolean,json:{name:"visibility",write:V()}})],U.prototype,"visible",void 0),U=(0,r._)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],U);const H=U},45654:(e,t,n)=>{n.d(t,{DX:()=>_,_s:()=>b,aq:()=>w,fe:()=>v});var r,s,i,o,a=n(78888),l=n(49186),u=n(91869),p=(n(90708),n(71932)),d=n(42538);n(59456),n(16930),(s=r||(r={})).ELEMENTUID="ELEMENTUID",s.TYPENAME="TYPENAME",r.ELEMENTUID,r.TYPENAME,function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME"}(i||(i={})),function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME",e[e.FROMUID=2]="FROMUID",e[e.TOUID=3]="TOUID"}(o||(o={}));var h,c,y,f,m,g=n(45724);function _(e){if(!e.spatialReference.isWGS84)throw new l.A("knowledge-graph:layer-support-utils","The extentToInBoundsRings function only supports WGS84 spatial references.");return e.clone().normalize().map((e=>[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]))}async function w(e,t){const n=[],r=new Map,s=[];if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&r.set(e.name,[]);for(const t of e)r.has(t.typeName)&&r.get(t.typeName)?.push(t.id);for(const[e,i]of r){if(i.length<1)continue;const r=new d.A({openCypherQuery:`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $ids RETURN id(n), labels(n)[0], id(m), labels(m)[0]`,bindParameters:{ids:i}});s.push((0,p.executeQueryStreaming)(t,r).then((async e=>{const t=e.resultRowsStream.getReader();for(;;){const{done:e,value:r}=await t.read();if(e)break;for(const e of r)n.push({id:e[0],typeName:e[1]}),n.push({id:e[2],typeName:e[3]})}})))}return await Promise.all(s),n}async function b(e,t){t??=!1;const n={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,a.A)(e,{responseType:"array-buffer"}),n=await t.data;return async function(e){const t=new((await(0,g.I)()).MapOfObjectIdentifierSetsDecoder),n=t.decode(new Uint8Array(e)),r=new Map;if(0!==n.error_code)throw new l.A("knowledge-graph:layer-support-utils",n.error_message);const s=t.get_map_of_identifier_sets(),i=s.keys,o=i.size();for(let e=0;e<o;e++){const t=i.get(e),n=s.query_identifier_set(t),o=[];if(n.id_array_type.value===f.GLOBALID_ARRAY){const e=n.get_globalid_array(),t=e.count();for(let n=0;n<t;n++)o.push(e.get_globalid_at(n))}else{if(n.id_array_type.value!==f.IDENTIFIER_ARRAY)throw new l.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=n.get_identifier_array(),t=e.count();for(let n=0;n<t;n++)o.push(e.get_identifier_at(n).toString())}}r.set(t,o)}return t.delete(),r}(new Uint8Array(n))}(e).then((e=>{!function(e,t){for(const[n,r]of e){const e=(0,u.tE)(t.namedTypeDefinitions,n,(()=>({useAllData:!1,members:new Map})));for(const t of r)e.members.has(t)||e.members.set(t,{id:t})}}(e,n)})),n}async function v(e){const t=await(0,g.I)(),n=new t.MapOfObjectIdentifierSets;!function(e,t,n){for(const[r,s]of n.namedTypeDefinitions){if(!s.members||s.useAllData)continue;const n=s.members.keys(),i=new t.GlobalIdArray,o=new t.ObjectIdentifierSet;for(const e of n)i.add_globalid(e);o.set_globalid_array(i),i.delete(),e.put_identifier_set(r,o),o.delete()}}(n,t,e);const r=new t.MapOfObjectIdentifierSetsEncoder;try{r.set_map_of_identifier_sets(n),r.encode();const e=r.get_encoding_result();if(0!==e.error.error_code)throw new l.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return r.delete(),t}finally{n.delete()}}n(35448),(m=h||(h={}))[m.featureResult=0]="featureResult",m[m.countResult=1]="countResult",m[m.idsResult=2]="idsResult",function(e){e[e.upperLeft=0]="upperLeft",e[e.lowerLeft=1]="lowerLeft"}(c||(c={})),function(e){e[e.sqlTypeBigInt=0]="sqlTypeBigInt",e[e.sqlTypeBinary=1]="sqlTypeBinary",e[e.sqlTypeBit=2]="sqlTypeBit",e[e.sqlTypeChar=3]="sqlTypeChar",e[e.sqlTypeDate=4]="sqlTypeDate",e[e.sqlTypeDecimal=5]="sqlTypeDecimal",e[e.sqlTypeDouble=6]="sqlTypeDouble",e[e.sqlTypeFloat=7]="sqlTypeFloat",e[e.sqlTypeGeometry=8]="sqlTypeGeometry",e[e.sqlTypeGUID=9]="sqlTypeGUID",e[e.sqlTypeInteger=10]="sqlTypeInteger",e[e.sqlTypeLongNVarchar=11]="sqlTypeLongNVarchar",e[e.sqlTypeLongVarbinary=12]="sqlTypeLongVarbinary",e[e.sqlTypeLongVarchar=13]="sqlTypeLongVarchar",e[e.sqlTypeNChar=14]="sqlTypeNChar",e[e.sqlTypeNVarChar=15]="sqlTypeNVarChar",e[e.sqlTypeOther=16]="sqlTypeOther",e[e.sqlTypeReal=17]="sqlTypeReal",e[e.sqlTypeSmallInt=18]="sqlTypeSmallInt",e[e.sqlTypeSqlXml=19]="sqlTypeSqlXml",e[e.sqlTypeTime=20]="sqlTypeTime",e[e.sqlTypeTimestamp=21]="sqlTypeTimestamp",e[e.sqlTypeTimestamp2=22]="sqlTypeTimestamp2",e[e.sqlTypeTinyInt=23]="sqlTypeTinyInt",e[e.sqlTypeVarbinary=24]="sqlTypeVarbinary",e[e.sqlTypeVarchar=25]="sqlTypeVarchar"}(y||(y={})),function(e){e[e.OID_ARRAY=0]="OID_ARRAY",e[e.GLOBALID_ARRAY=1]="GLOBALID_ARRAY",e[e.STRING_ARRAY=2]="STRING_ARRAY",e[e.IDENTIFIER_ARRAY=3]="IDENTIFIER_ARRAY"}(f||(f={}))},32756:(e,t,n)=>{n.d(t,{f:()=>u,n:()=>l});var r=n(90237),s=n(93637),i=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),a=n(91880);const l={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:function(e,t,n){if(!e)return null;const r=e.find((e=>!!e.field));if(!r)return null;const s=new a.A;return s.read(r,n),[s]}},write:{writer:function(e,t,n,r){const i=e.find((e=>!!e.field));i&&(0,s.sM)(n,[i.toJSON()],t)}}}},u=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,r._)([(0,i.MZ)(l)],t.prototype,"orderBy",void 0),t=(0,r._)([(0,o.$)("esri.layers.mixins.OrderedLayer")],t),t}},54310:(e,t,n)=>{n.d(t,{J:()=>w});var r=n(90237),s=(n(44208),n(53966)),i=n(74887),o=n(10107),a=n(79901),l=(n(87811),n(40608)),u=n(89317),p=n(5503),d=(n(60999),n(49186),n(14012),n(80559));const h=new p.A,c=new WeakMap;function y(e){(function(e){return null!=e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e})(e)&&h.push(new WeakRef(e))}function f(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:f(t,e%t):0}let m=0,g=0;function _(){const e=Date.now();let t=!1;for(const n of h){const r=n.deref();r?r.refreshInterval&&e-(c.get(r)??0)+5>=6e4*r.refreshInterval&&(c.set(r,e),r.refresh(e)):t=!0}if(t)for(let e=h.length-1;e>=0;e--)h.at(e).deref()||h.removeAt(e)}(0,d.fm)((()=>{const e=Date.now();let t=0;for(const n of h){const r=n.deref();r&&(t=f(Math.round(6e4*r.refreshInterval),t),r.refreshInterval?c.get(r)||c.set(r,e):c.delete(r))}if(t!==g){if(g=t,clearInterval(m),0===g)return void(m=0);m=setInterval(_,g)}}));const w=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,i.sg)((()=>this.hasDataChanged())),this.when().then((()=>{this.destroyed||y(this)}),(()=>{}))}destroy(){!function(e){const t=h.find((t=>t.deref()===e));t&&h.remove(t)}(this)}castRefreshInterval(e){return e>=.1?e:e<=0?0:.1}get refreshParameters(){return{_ts:this.refreshTimestamp||null}}refresh(e=Date.now()){(0,i.QZ)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{s.A.getLogger(this).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}get test(){}};return(0,r._)([(0,o.MZ)({type:Number,json:{write:!0,origins:{"web-scene":{write:{enabled:!0,layerContainerTypes:u.K}}}}})],t.prototype,"refreshInterval",void 0),(0,r._)([(0,a.w)("refreshInterval")],t.prototype,"castRefreshInterval",null),(0,r._)([(0,o.MZ)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,r._)([(0,o.MZ)({readOnly:!0})],t.prototype,"refreshParameters",null),t=(0,r._)([(0,l.$)("esri.layers.mixins.RefreshableLayer")],t),t}},20437:(e,t,n)=>{n.d(t,{A:()=>m});var r,s=n(90237),i=n(66552),o=n(25482),a=n(10107),l=n(56507),u=(n(87811),n(44208),n(93223)),p=n(36005),d=n(40608),h=n(72088),c=n(98453);const y=new i.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",dateAndTime:"date-and-time",description:"description",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let f=r=class extends o.oY{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?.value??null}readValueType(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?y.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,s._)([(0,a.MZ)({type:String,json:{write:!0}})],f.prototype,"alias",void 0),(0,s._)([(0,a.MZ)({type:[String,Number],json:{write:{allowNull:!0}}})],f.prototype,"defaultValue",void 0),(0,s._)([(0,a.MZ)()],f.prototype,"description",void 0),(0,s._)([(0,p.w)("description")],f.prototype,"readDescription",null),(0,s._)([(0,a.MZ)({types:h.gK,json:{read:{reader:h.rS},write:!0}})],f.prototype,"domain",void 0),(0,s._)([(0,a.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"editable",void 0),(0,s._)([(0,a.MZ)({type:l.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],f.prototype,"length",void 0),(0,s._)([(0,a.MZ)({type:String,json:{write:!0}})],f.prototype,"name",void 0),(0,s._)([(0,a.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"nullable",void 0),(0,s._)([(0,u.e)(c.m)],f.prototype,"type",void 0),(0,s._)([(0,a.MZ)()],f.prototype,"valueType",void 0),(0,s._)([(0,p.w)("valueType",["description"])],f.prototype,"readValueType",null),(0,s._)([(0,a.MZ)({type:Boolean,json:{read:!1}})],f.prototype,"visible",void 0),f=r=(0,s._)([(0,d.$)("esri.layers.support.Field")],f);const m=f},91880:(e,t,n)=>{n.d(t,{A:()=>d});var r,s=n(90237),i=n(66552),o=n(25482),a=n(10107),l=(n(44208),n(53966),n(87811),n(40608));const u=new i.J({asc:"ascending",desc:"descending"});let p=r=class extends o.oY{constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new r({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,s._)([(0,a.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,s._)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,s._)([(0,a.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],p.prototype,"order",void 0),p=r=(0,s._)([(0,l.$)("esri.layers.support.OrderByInfo")],p);const d=p},72088:(e,t,n)=>{n.d(t,{rS:()=>I,gK:()=>x}),n(44208);var r,s=n(90237),i=n(4718),o=n(10107),a=(n(53966),n(93223)),l=n(40608),u=n(25482);n(87811);let p=r=class extends u.oY{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,s._)([(0,o.MZ)({type:String,json:{write:!0}})],p.prototype,"name",void 0),(0,s._)([(0,o.MZ)({type:[String,Number],json:{write:!0}})],p.prototype,"code",void 0),p=r=(0,s._)([(0,l.$)("esri.layers.support.CodedValue")],p);const d=new(n(66552).J)({inherited:"inherited",codedValue:"coded-value",range:"range"});let h=class extends u.oY{constructor(e){super(e),this.name=null,this.type=null}};(0,s._)([(0,o.MZ)({type:String,json:{write:!0}})],h.prototype,"name",void 0),(0,s._)([(0,a.e)(d)],h.prototype,"type",void 0),h=(0,s._)([(0,l.$)("esri.layers.support.Domain")],h);const c=h;var y;let f=y=class extends c{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const n=String(e);this.codedValues.some((e=>(String(e.code)===n&&(t=e.name),!!t)))}return t}clone(){return new y({codedValues:(0,i.o8)(this.codedValues),name:this.name})}};(0,s._)([(0,o.MZ)({type:[p],json:{write:!0}})],f.prototype,"codedValues",void 0),(0,s._)([(0,a.e)({codedValue:"coded-value"})],f.prototype,"type",void 0),f=y=(0,s._)([(0,l.$)("esri.layers.support.CodedValueDomain")],f);const m=f;var g;n(49186);let _=g=class extends c{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,s._)([(0,a.e)({inherited:"inherited"})],_.prototype,"type",void 0),_=g=(0,s._)([(0,l.$)("esri.layers.support.InheritedDomain")],_);const w=_;var b;let v=b=class extends c{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new b({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,s._)([(0,o.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,n){t[n]=[this.minValue||0,e]}}}})],v.prototype,"maxValue",void 0),(0,s._)([(0,o.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,n){t[n]=[e,this.maxValue||0]}}}})],v.prototype,"minValue",void 0),(0,s._)([(0,a.e)({range:"range"})],v.prototype,"type",void 0),v=b=(0,s._)([(0,l.$)("esri.layers.support.RangeDomain")],v);const M=v,x={key:"type",base:c,typeMap:{range:v,"coded-value":m,inherited:w}};function I(e){if(!e?.type)return null;switch(e.type){case"range":return M.fromJSON(e);case"codedValue":return m.fromJSON(e);case"inherited":return w.fromJSON(e)}return null}},32730:(e,t,n)=>{n.d(t,{BI:()=>m,D3:()=>y,XJ:()=>f,lc:()=>c,mX:()=>_,rU:()=>g,tH:()=>x});var r=n(799);const s="__begin__",i="__end__",o=new RegExp(s,"ig"),a=new RegExp(i,"ig"),l=new RegExp("^"+s,"i"),u=new RegExp(i+"$","i"),p='"',d=p+" + ",h=" + "+p;function c(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function y(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function f(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=c(e.labelExpression),t.type="conventional"),t}function m(e){const t=f(e);if(!t)return null;switch(t.type){case"conventional":return _(t.expression);case"arcade":return t.expression}return null}function g(e){const t=f(e);if(!t)return null;switch(t.type){case"conventional":return function(e){const t=e?.match(w);return t?.[1].trim()||null}(t.expression);case"arcade":return x(t.expression)}return null}function _(e){let t;return e?(t=(0,r.HC)(e,(e=>s+'$feature["'+e+'"]'+i)),t=l.test(t)?t.replace(l,""):p+t,t=u.test(t)?t.replace(u,""):t+p,t=t.replaceAll(o,d).replaceAll(a,h)):t='""',t}const w=/^\s*\{([^}]+)\}\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,v=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,M=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function x(e){if(!e)return null;let t=b.exec(e)||v.exec(e);return t?t[1]||t[3]:(t=M.exec(e),t?t[2]:null)}},92300:(e,t,n)=>{n.d(t,{V:()=>i,X:()=>s});var r=n(65864);function s(e){return{geometryType:(0,r.$B)(e[0]),geometries:e.map((e=>e.toJSON()))}}function i(e,t,n){const s=(0,r.xD)(t);return e.map((e=>{const t=s.fromJSON(e);return t.spatialReference=n,t}))}},25927:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(90237),s=(n(59456),n(10107)),i=(n(44208),n(53966),n(87811),n(40608)),o=n(54238),a=n(86738);let l=class extends o.A{constructor(e){super(e),this.layoutGeometry=null}};(0,r._)([(0,s.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.Entity")],l);const u=l},54238:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(90237),s=n(10107),i=(n(44208),n(53966),n(87811),n(40608)),o=n(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a);const l=a},77901:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(90237),s=n(25482),i=n(10107),o=(n(44208),n(53966),n(87811),n(40608));let a=class extends s.oY{constructor(e){super(e),this.properties=null}};(0,r._)([(0,i.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,r._)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a);const l=a},42538:(e,t,n)=>{n.d(t,{A:()=>p});var r=n(90237),s=n(10107),i=(n(44208),n(53966),n(87811),n(40608)),o=n(69622);let a=class extends o.A{constructor(e){super(e),this.openCypherQuery=""}};(0,r._)([(0,s.MZ)()],a.prototype,"openCypherQuery",void 0),a=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQuery")],a);const l=a;let u=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,r._)([(0,s.MZ)()],u.prototype,"bindParameters",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"bindGeometryQuantizationParameters",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"outputQuantizationParameters",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"outputSpatialReference",void 0),(0,r._)([(0,s.MZ)()],u.prototype,"provenanceBehavior",void 0),u=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],u);const p=u},40662:(e,t,n)=>{n.d(t,{A:()=>a});var r=n(90237),s=(n(53966),n(44208),n(87811),n(49186),n(40608)),i=n(77901);let o=class extends i.A{constructor(e){super(e)}};o=(0,r._)([(0,s.$)("esri.rest.knowledgeGraph.ObjectValue")],o);const a=o},42095:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(90237),s=n(25482),i=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),a=n(77901);let l=class extends s.oY{constructor(e){super(e),this.path=null}};(0,r._)([(0,i.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,r._)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l);const u=l},23150:(e,t,n)=>{n.d(t,{A:()=>u});var r=n(90237),s=(n(59456),n(10107)),i=(n(44208),n(53966),n(87811),n(40608)),o=n(54238),a=n(82799);let l=class extends o.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,r._)([(0,s.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,r._)([(0,s.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.Relationship")],l);const u=l},22671:(e,t,n)=>{n.d(t,{A:()=>w});var r,s=n(90237),i=n(59456),o=n(52106),a=n(66552),l=n(25482),u=n(4718),p=n(10107),d=(n(44208),n(53966),n(36005)),h=n(40608),c=n(43937),y=n(16930),f=n(65864),m=n(20437);const g=new a.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let _=r=class extends l.oY{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){const n=y.A.fromJSON(t.spatialReference),r=[];for(let t=0;t<e.length;t++){const s=e[t],i=o.A.fromJSON(s),a=s.geometry?.spatialReference;null==i.geometry||a||(i.geometry.spatialReference=n);const l=s.aggregateGeometries,u=i.aggregateGeometries;if(l&&null!=u)for(const e in u){const t=u[e],r=l[e],s=r?.spatialReference;null==t||s||(t.spatialReference=n)}r.push(i)}return r}writeGeometryType(e,t,n,r){if(e)return void g.write(e,t,n,r);const{features:s}=this;if(s)for(const e of s)if(null!=e?.geometry)return void g.write(e.geometry.type,t,n,r)}readQueryGeometry(e,t){if(!e)return null;const n=!!e.spatialReference,r=(0,f.rS)(e);return r&&!n&&t.spatialReference&&(r.spatialReference=y.A.fromJSON(t.spatialReference)),r}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:n}=this;if(n)for(const e of n)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new r(this.cloneProperties())}cloneProperties(){return(0,u.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let n=0;n<t.features.length;n++){const r=t.features[n];if(r.geometry){const t=e?.[n];r.geometry=t?.toJSON()||r.geometry}}return t}quantize(e){const{scale:[t,n],translate:[r,s]}=e,i=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-r)/t)),(e=>Math.round((s-e)/n)));for(let e=0,t=i.length;e<t;e++)o?.(i[e].geometry)||(i.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:n}=this;if(!n)return this;const{translate:[r,s],scale:[i,o]}=n;let a=null,l=null;if(this.hasZ&&null!=n?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=n;a=n=>n*t+e}if(this.hasM&&null!=n?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=n;l=n=>null==n?n:n*t+e}const u=this._getHydrationFunction(e,(e=>e*i+r),(e=>s-e*o),a,l);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}_quantizePoints(e,t,n){let r,s;const i=[];for(let o=0,a=e.length;o<a;o++){const a=e[o];if(o>0){const e=t(a[0]),o=n(a[1]);e===r&&o===s||(i.push([e-r,o-s]),r=e,s=o)}else r=t(a[0]),s=n(a[1]),i.push([r,s])}return i.length>0?i:null}_getQuantizationFunction(e,t,n){return"point"===e?e=>(e.x=t(e.x),e.y=n(e.y),e):"polyline"===e||"polygon"===e?e=>{const r=(0,f.Bi)(e)?e.rings:e.paths,s=[];for(let e=0,i=r.length;e<i;e++){const i=r[e],o=this._quantizePoints(i,t,n);o&&s.push(o)}return s.length>0?((0,f.Bi)(e)?e.rings=s:e.paths=s,e):null}:"multipoint"===e?e=>{const r=this._quantizePoints(e.points,t,n);return r&&r.length>0?(e.points=r,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,n,r,s){return"point"===e?e=>{e.x=t(e.x),e.y=n(e.y),r&&(e.z=r(e.z))}:"polyline"===e||"polygon"===e?e=>{const i=(0,f.Bi)(e)?e.rings:e.paths;let o,a;for(let e=0,r=i.length;e<r;e++){const r=i[e];for(let e=0,s=r.length;e<s;e++){const s=r[e];e>0?(o+=s[0],a+=s[1]):(o=s[0],a=s[1]),s[0]=t(o),s[1]=n(a)}}if(r&&s)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2]),n[3]=s(n[3])}}else if(r)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2])}}else if(s)for(let e=0,t=i.length;e<t;e++){const t=i[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=s(n[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=n(e.ymin),e.xmax=t(e.xmax),e.ymax=n(e.ymax),r&&null!=e.zmax&&null!=e.zmin&&(e.zmax=r(e.zmax),e.zmin=r(e.zmin)),s&&null!=e.mmax&&null!=e.mmin&&(e.mmax=s(e.mmax),e.mmin=s(e.mmin))}:"multipoint"===e?e=>{const i=e.points;let o,a;for(let e=0,r=i.length;e<r;e++){const r=i[e];e>0?(o+=r[0],a+=r[1]):(o=r[0],a=r[1]),r[0]=t(o),r[1]=n(a)}if(r&&s)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=r(t[2]),t[3]=s(t[3])}else if(r)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=r(t[2])}else if(s)for(let e=0,t=i.length;e<t;e++){const t=i[e];t[2]=s(t[2])}}:null}};(0,s._)([(0,p.MZ)({type:String,json:{write:!0}})],_.prototype,"displayFieldName",void 0),(0,s._)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"exceededTransferLimit",void 0),(0,s._)([(0,p.MZ)({type:[o.A],json:{write:!0}})],_.prototype,"features",void 0),(0,s._)([(0,d.w)("features")],_.prototype,"readFeatures",null),(0,s._)([(0,p.MZ)({type:[m.A],json:{write:!0}})],_.prototype,"fields",void 0),(0,s._)([(0,p.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],_.prototype,"geometryType",void 0),(0,s._)([(0,c.K)("geometryType")],_.prototype,"writeGeometryType",null),(0,s._)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasM",void 0),(0,s._)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasZ",void 0),(0,s._)([(0,p.MZ)({types:i.yR,json:{write:!0}})],_.prototype,"queryGeometry",void 0),(0,s._)([(0,d.w)("queryGeometry")],_.prototype,"readQueryGeometry",null),(0,s._)([(0,p.MZ)({type:y.A,json:{write:!0}})],_.prototype,"spatialReference",void 0),(0,s._)([(0,c.K)("spatialReference")],_.prototype,"writeSpatialReference",null),(0,s._)([(0,p.MZ)({json:{write:!0}})],_.prototype,"transform",void 0),_=r=(0,s._)([(0,h.$)("esri.rest.support.FeatureSet")],_),_.prototype.toJSON.isDefaultToJSON=!0;const w=_},2272:(e,t,n)=>{n.d(t,{Dl:()=>o,jV:()=>i,lF:()=>a}),n(92602),n(70333);var r=n(4718),s=n(84952);function i(e,t){return t?{...t,query:{...e??{},...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,s.An)(e):(0,r.o8)(e)}function a(e,t,n){const r={};for(const s in e){if("declaredClass"===s)continue;const i=e[s];if(null!=i&&"function"!=typeof i)if(Array.isArray(i))r[s]=i.map((e=>a(e)));else if("object"==typeof i)if(i.toJSON){const e=i.toJSON(n?.[s]);r[s]=t?e:JSON.stringify(e)}else r[s]=t?i:JSON.stringify(i);else r[s]=i}return r}n(926)}}]);
|