@arcgis/core 4.28.3 → 4.28.4
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/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{15852a47129b9e0d04c6.js → 023fc8504d032762ad82.js} +1 -1
- package/assets/esri/core/workers/chunks/{4363f2cc3909c9258064.js → 076ac767b5148357f1b5.js} +1 -1
- package/assets/esri/core/workers/chunks/1c855f091d1305b82594.js +1 -0
- package/assets/esri/core/workers/chunks/4a5d0b49a641d182b5ea.js +1 -0
- package/assets/esri/core/workers/chunks/af13150c711ba7b7f3ac.js +1 -0
- package/assets/esri/core/workers/chunks/bab0aa000c65d5c256b7.js +1 -0
- package/assets/esri/core/workers/chunks/cfa6d1b63b794febe70a.js +1 -0
- package/assets/esri/core/workers/chunks/e076c5523dfb6c53a825.js +1 -0
- package/core/date.js +1 -1
- package/kernel.js +1 -1
- package/layers/graphics/data/QueryEngineResult.js +1 -1
- package/layers/graphics/sources/geojson/geojson.js +1 -1
- package/package.json +1 -1
- package/support/revision.js +1 -1
- package/views/2d/engine/webgl/Painter.js +1 -1
- package/views/3d/layers/graphics/elevationAlignPointsInFeatures.js +1 -1
- package/views/PopupView.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
- package/views/interactive/snapping/featureSources/snappingCandidateElevationAlignment.js +1 -1
- package/widgets/FeatureForm/FieldInput.js +1 -1
- package/widgets/FeatureForm.js +1 -1
- package/widgets/Features.js +1 -1
- package/widgets/Legend/LegendViewModel.js +1 -1
- package/widgets/Popup.js +1 -1
- package/assets/esri/core/workers/chunks/423672fe765083e1a0ec.js +0 -1
- package/assets/esri/core/workers/chunks/49d958631bcd93f6333a.js +0 -1
- package/assets/esri/core/workers/chunks/7beae29abdfae23b15cc.js +0 -1
- package/assets/esri/core/workers/chunks/97fd7b82eec26449977e.js +0 -1
- package/assets/esri/core/workers/chunks/f037e4f9877ea08ced9d.js +0 -1
- package/assets/esri/core/workers/chunks/f7ccc6c681fc9218555c.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3794,8592],{48853:(e,t,s)=>{s.d(t,{Qn:()=>d,iG:()=>h});var i,r=s(19153),n=s(1542),a=s(17126);(i||(i={})).TimeZoneNotRecognized="TimeZoneNotRecognized";const o={[i.TimeZoneNotRecognized]:"Timezone identifier has not been recognized."};class l extends Error{constructor(e,t){super((0,r.gx)(o[e],t)),this.declaredRootClass="esri.arcade.arcadedate.dateerror",Error.captureStackTrace&&Error.captureStackTrace(this,l)}}function u(e,t,s){return e<t?e-t:e>s?e-s:0}function c(e,t,s){return e<t?t:e>s?s:e}class h{constructor(e){this._date=e,this.declaredRootClass="esri.arcade.arcadedate"}static fromParts(e=0,t=1,s=1,i=0,r=0,n=0,o=0,l){if(isNaN(e)||isNaN(t)||isNaN(s)||isNaN(i)||isNaN(r)||isNaN(n)||isNaN(o))return null;const m=a.ou.local(e,t).daysInMonth;let f=a.ou.fromObject({day:c(s,1,m),year:e,month:c(t,1,12),hour:c(i,0,23),minute:c(r,0,59),second:c(n,0,59),millisecond:c(o,0,999)},{zone:d(l)});return f=f.plus({months:u(t,1,12),days:u(s,1,m),hours:u(i,0,23),minutes:u(r,0,59),seconds:u(n,0,59),milliseconds:u(o,0,999)}),new h(f)}static get systemTimeZoneCanonicalName(){return Intl.DateTimeFormat().resolvedOptions().timeZone??"system"}static arcadeDateAndZoneToArcadeDate(e,t){const s=d(t);return e.isUnknownTimeZone||s===n.yV.instance?h.fromParts(e.year,e.monthJS+1,e.day,e.hour,e.minute,e.second,e.millisecond,s):new h(e._date.setZone(s))}static dateJSToArcadeDate(e){return new h(a.ou.fromJSDate(e,{zone:"system"}))}static dateJSAndZoneToArcadeDate(e,t="system"){const s=d(t);return new h(a.ou.fromJSDate(e,{zone:s}))}static unknownEpochToArcadeDate(e){return new h(a.ou.fromMillis(e,{zone:n.yV.instance}))}static unknownDateJSToArcadeDate(e){return new h(a.ou.fromMillis(e.getTime(),{zone:n.yV.instance}))}static epochToArcadeDate(e,t="system"){const s=d(t);return new h(a.ou.fromMillis(e,{zone:s}))}static dateTimeToArcadeDate(e){return new h(e)}clone(){return new h(this._date)}changeTimeZone(e){const t=d(e);return h.dateTimeToArcadeDate(this._date.setZone(t))}static dateTimeAndZoneToArcadeDate(e,t){const s=d(t);return e.zone===n.yV.instance||s===n.yV.instance?h.fromParts(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond,s):new h(e.setZone(s))}static nowToArcadeDate(e){const t=d(e);return new h(a.ou.fromJSDate(new Date,{zone:t}))}static nowUTCToArcadeDate(){return new h(a.ou.utc())}get isSystem(){return"system"===this.timeZone||this.timeZone===h.systemTimeZoneCanonicalName}equals(e){return this.isSystem&&e.isSystem?this.toNumber()===e.toNumber():this.isUnknownTimeZone===e.isUnknownTimeZone&&this._date.equals(e._date)}get isUnknownTimeZone(){return this._date.zone===n.yV.instance}get isValid(){return this._date.isValid}get hour(){return this._date.hour}get second(){return this._date.second}get day(){return this._date.day}get dayOfWeekISO(){return this._date.weekday}get dayOfWeekJS(){let e=this._date.weekday;return e>6&&(e=0),e}get millisecond(){return this._date.millisecond}get monthISO(){return this._date.month}get weekISO(){return this._date.weekNumber}get yearISO(){return this._date.weekYear}get monthJS(){return this._date.month-1}get year(){return this._date.year}get minute(){return this._date.minute}get zone(){return this._date.zone}get timeZoneOffset(){return this.isUnknownTimeZone?0:this._date.offset}get timeZone(){if(this.isUnknownTimeZone)return"unknown";if("system"===this._date.zone.type)return"system";const e=this.zone;return"fixed"===e.type?0===e.fixed?"UTC":e.formatOffset(0,"short"):e.name}stringify(){return JSON.stringify(this.toJSDate())}plus(e){return new h(this._date.plus(e))}diff(e,t="milliseconds"){return this._date.diff(e._date,t)[t]}toISODate(){return this._date.toISODate()}toISOString(e){return e?this._date.toISO({suppressMilliseconds:!0,includeOffset:!this.isUnknownTimeZone}):this._date.toISO({includeOffset:!this.isUnknownTimeZone})}toISOTime(e,t){return this._date.toISOTime({suppressMilliseconds:e,includeOffset:t&&!this.isUnknownTimeZone})}toFormat(e,t){return this.isUnknownTimeZone&&(e=e.replaceAll("Z","")),this._date.toFormat(e,t)}toJSDate(){return this._date.toJSDate()}toSQLValue(){return this._date.toFormat("yyyy-LL-dd HH:mm:ss")}toSQLWithKeyword(){return`timestamp '${this.toSQLValue()}'`}toDateTime(){return this._date}toNumber(){return this._date.toMillis()}getTime(){return this._date.toMillis()}toUTC(){return new h(this._date.toUTC())}toLocal(){return new h(this._date.toLocal())}toString(){return this.toISOString(!0)}static fromReaderAsTimeStampOffset(e){if(!e)return null;const t=a.ou.fromISO(e,{setZone:!0});return new h(t)}}function d(e,t=!0){if(e instanceof a.ld)return e;if("system"===e.toLowerCase())return"system";if("utc"===e.toLowerCase())return"UTC";if("unknown"===e.toLowerCase())return n.yV.instance;if(/^[\+\-]?[0-9]{1,2}([:][0-9]{2})?$/.test(e)){const t=a.Qf.parseSpecifier("UTC"+(e.startsWith("+")||e.startsWith("-")?"":"+")+e);if(t)return t}const s=a.vF.create(e);if(!s.isValid){if(t)throw new l(i.TimeZoneNotRecognized);return null}return s}},77286:(e,t,s)=>{s.d(t,{EI:()=>r,Lz:()=>a,SV:()=>n,U:()=>l,r1:()=>o});var i=s(6570);function r(e){if(null==e)return null;if("number"==typeof e)return e;let t=e.toLowerCase();switch(t=t.replaceAll(/\s/g,""),t=t.replaceAll("-",""),t){case"meters":case"meter":case"m":case"squaremeters":case"squaremeter":return 109404;case"miles":case"mile":case"squaremile":case"squaremiles":return 109439;case"kilometers":case"kilometer":case"squarekilometers":case"squarekilometer":case"km":return 109414;case"acres":case"acre":case"ac":return 109402;case"hectares":case"hectare":case"ha":return 109401;case"yard":case"yd":case"yards":case"squareyards":case"squareyard":return 109442;case"feet":case"ft":case"foot":case"squarefeet":case"squarefoot":return 109405;case"nmi":case"nauticalmile":case"nauticalmiles":case"squarenauticalmile":case"squarenauticalmiles":return 109409}return null}function n(e){if(null==e)return null;switch(e.type){case"polygon":case"multipoint":case"polyline":return e.extent;case"point":return new i.Z({xmin:e.x,ymin:e.y,xmax:e.x,ymax:e.y,spatialReference:e.spatialReference});case"extent":return e}return null}function a(e){if(null==e)return null;if("number"==typeof e)return e;let t=e.toLowerCase();switch(t=t.replaceAll(/\s/g,""),t=t.replaceAll("-",""),t){case"meters":case"meter":case"m":case"squaremeters":case"squaremeter":return 9001;case"miles":case"mile":case"squaremile":case"squaremiles":return 9093;case"kilometers":case"kilometer":case"squarekilometers":case"squarekilometer":case"km":return 9036;case"yard":case"yd":case"yards":case"squareyards":case"squareyard":return 9096;case"feet":case"ft":case"foot":case"squarefeet":case"squarefoot":return 9002;case"nmi":case"nauticalmile":case"nauticalmiles":case"squarenauticalmile":case"squarenauticalmiles":return 9030}return null}function o(e){if(null==e)return null;const t=e.clone();return void 0!==e.cache._geVersion&&(t.cache._geVersion=e.cache._geVersion),t}function l(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e}},88764:(e,t,s)=>{s.d(t,{q:()=>l});var i,r,n,a=s(5732),o={exports:{}};i=o,r=function(){function e(s,i,r,n,a){for(;n>r;){if(n-r>600){var o=n-r+1,l=i-r+1,u=Math.log(o),c=.5*Math.exp(2*u/3),h=.5*Math.sqrt(u*c*(o-c)/o)*(l-o/2<0?-1:1);e(s,i,Math.max(r,Math.floor(i-l*c/o+h)),Math.min(n,Math.floor(i+(o-l)*c/o+h)),a)}var d=s[i],m=r,f=n;for(t(s,r,i),a(s[n],d)>0&&t(s,r,n);m<f;){for(t(s,m,f),m++,f--;a(s[m],d)<0;)m++;for(;a(s[f],d)>0;)f--}0===a(s[r],d)?t(s,r,f):t(s,++f,n),f<=i&&(r=f+1),i<=f&&(n=f-1)}}function t(e,t,s){var i=e[t];e[t]=e[s],e[s]=i}function s(e,t){return e<t?-1:e>t?1:0}return function(t,i,r,n,a){e(t,i,r||0,n||t.length-1,a||s)}},void 0!==(n=r())&&(i.exports=n);const l=(0,a.g)(o.exports)},95528:(e,t,s)=>{s.d(t,{t:()=>o});var i=s(22974),r=s(58971),n=s(10661);class a{constructor(e,t){this._observable=new n.s,this._value=e,this._equalityFunction=t}get value(){return(0,r.it)(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 o(e,t=i.y7){return new a(e,t)}},22641:(e,t,s)=>{s.d(t,{u:()=>o});var i=s(48853),r=s(70171),n=s(17126);function a(e){e=e.replaceAll(/LTS|LT|LL?L?L?|l{1,4}/g,"[$&]");let t="";const s=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g;for(const i of e.match(s)||[])switch(i){case"D":t+="d";break;case"DD":t+="dd";break;case"DDD":t+="o";break;case"d":t+="c";break;case"ddd":t+="ccc";break;case"dddd":t+="cccc";break;case"M":t+="L";break;case"MM":t+="LL";break;case"MMM":t+="LLL";break;case"MMMM":t+="LLLL";break;case"YY":t+="yy";break;case"Y":case"YYYY":t+="yyyy";break;case"Q":t+="q";break;case"X":case"x":t+=i;break;default:i.length>=2&&"["===i.slice(0,1)&&"]"===i.slice(-1)?t+=`'${i.slice(1,-1)}'`:t+=`'${i}'`}return t}class o{constructor(e,t,s){this._year=e,this._month=t,this._day=s,this.declaredRootClass="esri.core.sql.dateonly"}get month(){return this._month}get monthJS(){return this._month-1}get year(){return this._year}get day(){return this._day}get isValid(){return this.toDateTime("unknown").isValid}equals(e){return e instanceof o&&e.day===this.day&&e.month===this.month&&e.year===this.year}clone(){return new o(this._year,this._month,this._day)}toDateTime(e){return n.ou.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.Qn)(e)})}toDateTimeLuxon(e){return n.ou.fromObject({day:this.day,month:this.month,year:this.year},{zone:(0,i.Qn)(e)})}toString(){return`${this.year.toString().padStart(4,"0")}-${this.month.toString().padStart(2,"0")}-${this.day.toString().padStart(2,"0")}`}toFormat(e=null){if(null===e||""===e)return this.toString();if(!(e=a(e)))return"";const t=this.toDateTime("unknown");return i.iG.dateTimeToArcadeDate(t).toFormat(e,{locale:(0,r.Kd)(),numberingSystem:"latn"})}toArcadeDate(){const e=this.toDateTime("unknown");return i.iG.dateTimeToArcadeDate(e)}toNumber(){return this.toDateTime("unknown").toMillis()}toJSDate(){return this.toDateTime("unknown").toJSDate()}toStorageFormat(){return this.toFormat("yyyy-LL-dd")}toSQLValue(){return this.toFormat("yyyy-LL-dd")}toSQLWithKeyword(){return"date '"+this.toFormat("yyyy-LL-dd")+"'"}plus(e,t){return o.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}toUTCDateTime(){return n.ou.utc(this.year,this.month,this.day,0,0,0,0)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}static fromMilliseconds(e){const t=n.ou.fromMillis(e,{zone:n.Qf.utcInstance});return t.isValid?o.fromParts(t.year,t.month,t.day):null}static fromSeconds(e){const t=n.ou.fromSeconds(e,{zone:n.Qf.utcInstance});return t.isValid?o.fromParts(t.year,t.month,t.day):null}static fromReader(e){if(!e)return null;const t=e.split("-");return 3!==t.length?null:new o(parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10))}static fromParts(e,t,s){const i=new o(e,t,s);return!1===i.isValid?null:i}static fromDateJS(e){return o.fromParts(e.getFullYear(),e.getMonth()+1,e.getDay())}static fromDateTime(e){return o.fromParts(e.year,e.month,e.day)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e)return null;if(null===e)return null;const s=[];if(t)(t=a(t))&&s.push(t);else if(null===t||""===t){const t=n.ou.fromISO(e,{setZone:!0});return t.isValid?o.fromParts(t.year,t.month,t.day):null}for(const i of s){const s=n.ou.fromFormat(e,t??i);if(s.isValid)return new o(s.year,s.month,s.day)}return null}static fromNow(e="system"){const t=n.ou.fromJSDate(new Date).setZone((0,i.Qn)(e));return new o(t.year,t.month,t.day)}}},53970:(e,t,s)=>{s.d(t,{n:()=>o});var i=s(77286),r=s(70171),n=s(17126);function a(e){if(!e)return"";const t=/(a|A|hh?|HH?|mm?|ss?|SSS|S|.)/g;let s="";for(const i of e.match(t)||[])switch(i){case"SSS":case"m":case"mm":case"h":case"hh":case"H":case"HH":case"s":case"ss":s+=i;break;case"A":case"a":s+="a";break;default:s+=`'${i}'`}return s}class o{constructor(e,t,s,i){this._hour=e,this._minute=t,this._second=s,this._millisecond=i,this.declaredRootClass="esri.core.sql.timeonly"}get hour(){return this._hour}get minute(){return this._minute}get second(){return this._second}get millisecond(){return this._millisecond}equals(e){return e instanceof o&&e.hour===this.hour&&e.minute===this.minute&&e.second===this.second&&e.millisecond===this.millisecond}clone(){return new o(this.hour,this.minute,this.second,this.millisecond)}isValid(){return(0,i.U)(this.hour)&&(0,i.U)(this.minute)&&(0,i.U)(this.second)&&(0,i.U)(this.millisecond)&&this.hour>=0&&this.hour<24&&this.minute>=0&&this.minute<60&&this.second>=0&&this.second<60&&this.millisecond>=0&&this.millisecond<1e3}toString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`+(this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):"")}toSQLValue(){return this.toString()}toSQLWithKeyword(){return`time '${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}${this.millisecond>0?"."+this.millisecond.toString().padStart(3,"0"):""}'`}toStorageString(){return`${this.hour.toString().padStart(2,"0")}:${this.minute.toString().padStart(2,"0")}:${this.second.toString().padStart(2,"0")}`}toFormat(e=null){return null===e||""===e?this.toString():(e=a(e))?n.ou.local(1970,1,1,this._hour,this._minute,this._second,this._millisecond).toFormat(e,{locale:(0,r.Kd)(),numberingSystem:"latn"}):""}toNumber(){return this.millisecond+1e3*this.second+1e3*this.minute*60+60*this.hour*60*1e3}static fromParts(e,t,s,i){const r=new o(e,t,s,i);return r.isValid()?r:null}static fromReader(e){if(!e)return null;const t=e.split(":");return 3!==t.length?null:new o(parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10),0)}static fromMilliseconds(e){if(e>864e5||e<0)return null;const t=Math.floor(e/1e3%60),s=Math.floor(e/6e4%60),i=Math.floor(e/36e5%24),r=Math.floor(e%1e3);return new o(i,s,t,r)}static fromDateJS(e){return new o(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}static fromDateTime(e){return new o(e.hour,e.minute,e.second,e.millisecond)}static fromSqlTimeStampOffset(e){return this.fromDateTime(e.toDateTime())}static fromString(e,t=null){if(""===e)return null;if(null===e)return null;const s=[];t?(t=a(t))&&s.push(t):null!==t&&""!==t||(s.push("HH:mm:ss"),s.push("HH:mm:ss.SSS"),s.push("hh:mm:ss a"),s.push("hh:mm:ss.SSS a"),s.push("HH:mm"),s.push("hh:mm a"),s.push("H:mm"),s.push("h:mm a"),s.push("H:mm:ss"),s.push("h:mm:ss a"),s.push("H:mm:ss.SSS"),s.push("h:mm:ss.SSS a"));for(const t of s){const s=n.ou.fromFormat(e,t);if(s.isValid)return new o(s.hour,s.minute,s.second,s.millisecond)}return null}plus(e,t){switch(e){case"days":case"years":case"months":return this.clone();case"hours":case"minutes":case"seconds":case"milliseconds":return o.fromDateTime(this.toUTCDateTime().plus({[e]:t}))}return null}toUTCDateTime(){return n.ou.utc(1970,1,1,this.hour,this.minute,this.second,this.millisecond)}difference(e,t){switch(t.toLowerCase()){case"days":case"day":case"d":return this.toUTCDateTime().diff(e.toUTCDateTime(),"days").days;case"months":case"month":return this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months;case"minutes":case"minute":case"m":return"M"===t?this.toUTCDateTime().diff(e.toUTCDateTime(),"months").months:this.toUTCDateTime().diff(e.toUTCDateTime(),"minutes").minutes;case"seconds":case"second":case"s":return this.toUTCDateTime().diff(e.toUTCDateTime(),"seconds").seconds;case"milliseconds":case"millisecond":case"ms":default:return this.toUTCDateTime().diff(e.toUTCDateTime(),"milliseconds").milliseconds;case"hours":case"hour":case"h":return this.toUTCDateTime().diff(e.toUTCDateTime(),"hours").hours;case"years":case"year":case"y":return this.toUTCDateTime().diff(e.toUTCDateTime(),"years").years}}}},1542:(e,t,s)=>{s.d(t,{A4:()=>n,L9:()=>a,Rw:()=>o,yV:()=>r});var i=s(17126);class r{}function n(e){return e instanceof i.ld?e===r.instance:"unknown"===e?.toString().toLowerCase()}function a(e){return n(e)?r.instance:e}function o(e,t){return i.ou.fromObject({day:e.day,year:e.year,month:e.month,hour:e.hour,minute:e.minute,second:e.second,millisecond:e.millisecond},{zone:t})}r.instance=new i.vF("Etc/UTC")},37455:(e,t,s)=>{s.d(t,{N:()=>i});const i={convertToGEGeometry:function(e,t){return null==t?null:e.convertJSONToGeometry(t)},exportPoint:function(e,t,s){const i=new r(e.getPointX(t),e.getPointY(t),s),n=e.hasZ(t),a=e.hasM(t);return n&&(i.z=e.getPointZ(t)),a&&(i.m=e.getPointM(t)),i},exportPolygon:function(e,t,s){return new n(e.exportPaths(t),s,e.hasZ(t),e.hasM(t))},exportPolyline:function(e,t,s){return new a(e.exportPaths(t),s,e.hasZ(t),e.hasM(t))},exportMultipoint:function(e,t,s){return new o(e.exportPoints(t),s,e.hasZ(t),e.hasM(t))},exportExtent:function(e,t,s){const i=e.hasZ(t),r=e.hasM(t),n=new l(e.getXMin(t),e.getYMin(t),e.getXMax(t),e.getYMax(t),s);if(i){const s=e.getZExtent(t);n.zmin=s.vmin,n.zmax=s.vmax}if(r){const s=e.getMExtent(t);n.mmin=s.vmin,n.mmax=s.vmax}return n}};class r{constructor(e,t,s){this.x=e,this.y=t,this.spatialReference=s,this.z=void 0,this.m=void 0}}class n{constructor(e,t,s,i){this.rings=e,this.spatialReference=t,this.hasZ=void 0,this.hasM=void 0,s&&(this.hasZ=s),i&&(this.hasM=i)}}class a{constructor(e,t,s,i){this.paths=e,this.spatialReference=t,this.hasZ=void 0,this.hasM=void 0,s&&(this.hasZ=s),i&&(this.hasM=i)}}class o{constructor(e,t,s,i){this.points=e,this.spatialReference=t,this.hasZ=void 0,this.hasM=void 0,s&&(this.hasZ=s),i&&(this.hasM=i)}}class l{constructor(e,t,s,i,r){this.xmin=e,this.ymin=t,this.xmax=s,this.ymax=i,this.spatialReference=r,this.zmin=void 0,this.zmax=void 0,this.mmin=void 0,this.mmax=void 0}}},60437:(e,t,s)=>{s.d(t,{G_:()=>_,HH:()=>a,JR:()=>f,TC:()=>o,Tn:()=>h,Ue:()=>r,al:()=>n,bZ:()=>p,cS:()=>m,dp:()=>u,fS:()=>g,is:()=>y,op:()=>c,pp:()=>l,t8:()=>d});var i=s(6570);function r(e=T){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function n(e,t,s,i,n,a,o=r()){return o[0]=e,o[1]=t,o[2]=s,o[3]=i,o[4]=n,o[5]=a,o}function a(e,t){const s=isFinite(e[2])||isFinite(e[5]);return new i.Z(s?{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 o(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 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[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}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 c(e,t,s=e){return s[0]=t[0],s[1]=t[1],s[2]=t[2],s!==e&&(s[3]=e[3],s[4]=e[4],s[5]=e[5]),s}function h(e,t,s=e){return s[3]=t[0],s[4]=t[1],s[5]=t[2],s!==e&&(s[0]=e[0],s[1]=e[1],s[2]=e[2]),e}function d(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 m(e){return e?d(e,_):r(_)}function f(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 p(e,t,s,i,r){return e[0]=t,e[1]=s,e[2]=Number.NEGATIVE_INFINITY,e[3]=i,e[4]=r,e[5]=Number.POSITIVE_INFINITY,e}function y(e){return 6===e.length}function g(e,t,s){if(null==e||null==t)return e===t;if(!y(e)||!y(t))return!1;if(s){for(let i=0;i<e.length;i++)if(!s(e[i],t[i]))return!1}else for(let s=0;s<e.length;s++)if(e[s]!==t[s])return!1;return!0}s(24470);const _=[1/0,1/0,1/0,-1/0,-1/0,-1/0],T=[0,0,0,0,0,0];r()},70272:(e,t,s)=>{s.d(t,{S6:()=>r,nd:()=>n,u_:()=>i});class i{constructor(e=null,t={},s,i){this.geometry=e,this.attributes=t,this.centroid=s,this.objectId=i,this.displayId=0,this.geohashX=0,this.geohashY=0}weakClone(){const e=new i(this.geometry,this.attributes,this.centroid,this.objectId);return e.displayId=this.displayId,e.geohashX=this.geohashX,e.geohashY=this.geohashY,e}}function r(e){return!!e.geometry?.coords?.length}class n extends i{}},44876:(e,t,s)=>{s.d(t,{Z:()=>i});class i{constructor(){this.objectIdFieldName=null,this.globalIdFieldName=null,this.geohashFieldName=null,this.geometryProperties=null,this.geometryType=null,this.spatialReference=null,this.hasZ=!1,this.hasM=!1,this.features=[],this.fields=[],this.transform=null,this.exceededTransferLimit=!1,this.uniqueIdField=null,this.queryGeometryType=null,this.queryGeometry=null}weakClone(){const e=new i;return e.objectIdFieldName=this.objectIdFieldName,e.globalIdFieldName=this.globalIdFieldName,e.geohashFieldName=this.geohashFieldName,e.geometryProperties=this.geometryProperties,e.geometryType=this.geometryType,e.spatialReference=this.spatialReference,e.hasZ=this.hasZ,e.hasM=this.hasM,e.features=this.features,e.fields=this.fields,e.transform=this.transform,e.exceededTransferLimit=this.exceededTransferLimit,e.uniqueIdField=this.uniqueIdField,e.queryGeometry=this.queryGeometry,e.queryGeometryType=this.queryGeometryType,e}}},5428:(e,t,s)=>{s.d(t,{Z:()=>i});class i{constructor(e=[],t=[],s=!1){this.lengths=e??[],this.coords=t??[],this.hasIndeterminateRingOrder=s}static fromRect(e){const[t,s,r,n]=e,a=r-t,o=n-s;return new i([5],[t,s,a,0,0,o,-a,0,0,-o])}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((e,t)=>e+t))}forEachVertex(e){let t=0;this.lengths.length||e(this.coords[0],this.coords[1]);for(let s=0;s<this.lengths.length;s++){const i=this.lengths[s];for(let s=0;s<i;s++)e(this.coords[2*(s+t)],this.coords[2*(s+t)+1]);t+=i}}clone(e){return e?(e.set(this.coords),new i(this.lengths.slice(),e,this.hasIndeterminateRingOrder)):new i(this.lengths.slice(),this.coords.slice(),this.hasIndeterminateRingOrder)}}},3489:(e,t,s)=>{s.d(t,{q:()=>Ue});var i=s(67676),r=s(20102),n=s(96674),a=s(22974),o=s(70586),l=s(69801),u=s(95330),c=s(67900),h=s(73615),d=s(60437),m=s(24470),f=s(20322),p=s(33955),y=s(16306),g=s(8744),_=s(98732),T=s(13867),S=s(8968),x=s(86719);const I=new class{constructor(e,t){this._cache=new T.z(e),this._invalidCache=new T.z(t)}get(e,t){const s=`${t.uid}:${e}`,i=this._cache.get(s);if(i)return i;if(null!=this._invalidCache.get(s))return null;try{const i=S.WhereClause.create(e,t);return this._cache.put(s,i),i}catch(e){return this._invalidCache.put(s,e),null}}getError(e,t){const s=`${t.uid}:${e}`;return this._invalidCache.get(s)??null}}(50,500),F="unsupported-query",w=" as ",R=new Set(["esriFieldTypeOID","esriFieldTypeSmallInteger","esriFieldTypeBigInteger","esriFieldTypeInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeLong"]),E=new Set(["esriFieldTypeDate","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]),b=new Set(["esriFieldTypeString","esriFieldTypeGUID","esriFieldTypeGlobalID",...R,...E]);function N(e,t,s={}){const i=v(t,e);if(!i){const s=I.getError(t,e);throw new r.Z(F,"invalid SQL expression",{expression:t,error:s})}const n=s.expressionName||"expression";if(s.validateStandardized&&!i.isStandardized)throw new r.Z(F,`${n} is not standard`,{expression:t});if(s.validateAggregate&&!i.isAggregate)throw new r.Z(F,`${n} does not contain a valid aggregate function`,{expression:t});return i.fieldNames}function A(e,t,s,i,n){if(!s)return!0;const a="having clause",o=N(e,s,{validateAggregate:!0,expressionName:a});C(e,t,o,{expressionName:a,query:n});const l=v(s,e),u=l?.getExpressions().every((t=>{const{aggregateType:s,field:r}=t,n=e.get(r)?.name;return i.some((t=>{const{onStatisticField:i,statisticType:r}=t,a=e.get(i)?.name;return a===n&&r.toLowerCase().trim()===s}))}));if(!u)throw new r.Z(F,"expressions in having clause should also exist in outStatistics",{having:s});return!0}function v(e,t){return e?I.get(e,t):null}function D(e){return/\((.*?)\)/.test(e)?e:e.split(w)[0]}function M(e){return e.split(w)[1]}function C(e,t,s,i={}){const n=new Map;if(function(e,t,s,i,r){for(const n of r)if("*"!==n)if(t.get(n))O(e,t,s,i,n);else try{const r=N(t,D(n),{validateStandardized:!0});for(const n of r)O(e,t,s,i,n)}catch(t){e.set(n,{type:"expression-error",expression:n,error:t})}}(n,e,t,i.allowedFieldTypes??b,s),n.size){const e=i.expressionName??"expression";throw new r.Z(F,`${e} contains invalid or missing fields`,{errors:Array.from(n.values()),query:i.query})}}function O(e,t,s,i,r){if("*"===r)return;const n=t.get(r);n?s.has(n.name)?!1===i?.has(n.type)&&e.set(r,{type:"invalid-type",fieldName:n.name,fieldType:x.v.fromJSON(n.type),allowedFieldTypes:Array.from(i,(e=>x.v.fromJSON(e)))}):e.set(r,{type:"missing-field",fieldName:n.name}):e.set(r,{type:"invalid-field",fieldName:r})}var P=s(42712),k=s(37427),Z=s(61159),L=s(35308),U=s(49600),G=s(82397),q=s(69165),V=s(79213),z=s(24452),Q=s(59266);class Y{constructor(e,t,s){this._fieldDataCache=new Map,this._returnDistinctMap=new Map,this.returnDistinctValues=e.returnDistinctValues??!1,this.fieldsIndex=s,this.featureAdapter=t;const i=e.outFields;if(i&&!i.includes("*")){this.outFields=i;let e=0;for(const t of i){const i=D(t),r=this.fieldsIndex.get(i),n=r?null:v(i,s),a=r?r.name:M(t)||"FIELD_EXP_"+e++;this._fieldDataCache.set(t,{alias:a,clause:n})}}}countDistinctValues(e){return this.returnDistinctValues?(e.forEach((e=>this.getAttributes(e))),this._returnDistinctMap.size):e.length}getAttributes(e){const t=this._processAttributesForOutFields(e);return this._processAttributesForDistinctValues(t)}getFieldValue(e,t,s){const i=s?s.name:t;let r=null;return this._fieldDataCache.has(i)?r=this._fieldDataCache.get(i)?.clause:s||(r=v(t,this.fieldsIndex),this._fieldDataCache.set(i,{alias:i,clause:r})),s?this.featureAdapter.getAttribute(e,i):r?.calculateValue(e,this.featureAdapter)}getDataValues(e,t,s=!0){const i=t.normalizationType,r=t.normalizationTotal,n=this.fieldsIndex.get(t.field),a=(0,q.UQ)(n)||(0,q.ig)(n),o=(0,q.sX)(n);return e.map((e=>{let n=t.field&&this.getFieldValue(e,t.field,this.fieldsIndex.get(t.field));if(t.field2?(n=`${(0,z.wk)(n)}${t.fieldDelimiter}${(0,z.wk)(this.getFieldValue(e,t.field2,this.fieldsIndex.get(t.field2)))}`,t.field3&&(n=`${n}${t.fieldDelimiter}${(0,z.wk)(this.getFieldValue(e,t.field3,this.fieldsIndex.get(t.field3)))}`)):"string"==typeof n&&s&&(a?n=n?new Date(n).getTime():null:o&&(n=n?(0,V.yO)(n):null)),i&&Number.isFinite(n)){const s="field"===i&&t.normalizationField?this.getFieldValue(e,t.normalizationField,this.fieldsIndex.get(t.normalizationField)):null;n=(0,z.fk)(n,i,s,r)}return n}))}async getExpressionValues(e,t,s,i,r){const{arcadeUtils:n}=await(0,Q.LC)(),a=n.hasGeometryOperations(t);a&&await n.enableGeometryOperations();const o=n.createFunction(t),l=n.getViewInfo(s),u={fields:this.fieldsIndex.fields};return e.map((e=>{const t={attributes:this.featureAdapter.getAttributes(e),layer:u,geometry:a?{...(0,P.Op)(i.geometryType,i.hasZ,i.hasM,this.featureAdapter.getGeometry(e)),spatialReference:s?.spatialReference}:null},c=n.createExecContext(t,l,r);return n.executeFunction(o,c)}))}validateItem(e,t){return this._fieldDataCache.has(t)||this._fieldDataCache.set(t,{alias:t,clause:v(t,this.fieldsIndex)}),this._fieldDataCache.get(t)?.clause?.testFeature(e,this.featureAdapter)??!1}validateItems(e,t){return this._fieldDataCache.has(t)||this._fieldDataCache.set(t,{alias:t,clause:v(t,this.fieldsIndex)}),this._fieldDataCache.get(t)?.clause?.testSet(e,this.featureAdapter)??!1}_processAttributesForOutFields(e){const t=this.outFields;if(!t?.length)return this.featureAdapter.getAttributes(e);const s={};for(const i of t){const{alias:t,clause:r}=this._fieldDataCache.get(i);s[t]=r?r.calculateValue(e,this.featureAdapter):this.featureAdapter.getAttribute(e,t)}return s}_processAttributesForDistinctValues(e){if(null==e||!this.returnDistinctValues)return e;const t=this.outFields,s=[];if(t)for(const i of t){const{alias:t}=this._fieldDataCache.get(i);s.push(e[t])}else for(const t in e)s.push(e[t]);const i=`${(t||["*"]).join(",")}=${s.join(",")}`;let r=this._returnDistinctMap.get(i)||0;return this._returnDistinctMap.set(i,++r),r>1?null:e}}function j(e,t,s){return{objectId:e,target:t,distance:s,type:"vertex"}}function B(e,t,s,i,r,n=!1){return{objectId:e,target:t,distance:s,type:"edge",start:i,end:r,draped:n}}class H{constructor(e,t,s){this.items=e,this.query=t,this.geometryType=s.geometryType,this.hasM=s.hasM,this.hasZ=s.hasZ,this.fieldsIndex=s.fieldsIndex,this.objectIdField=s.objectIdField,this.spatialReference=s.spatialReference,this.featureAdapter=s.featureAdapter}get size(){return this.items.length}createQueryResponseForCount(){const e=new Y(this.query,this.featureAdapter,this.fieldsIndex);if(!this.query.outStatistics)return e.countDistinctValues(this.items);const{groupByFieldsForStatistics:t,having:s,outStatistics:i}=this.query,r=t?.length;if(!r)return 1;const n=new Map,a=new Map,o=new Set;for(const r of i){const{statisticType:i}=r,l="exceedslimit"!==i?r.onStatisticField:void 0;if(!a.has(l)){const s=[];for(const i of t){const t=this._getAttributeValues(e,i,n);s.push(t)}a.set(l,this._calculateUniqueValues(s,e.returnDistinctValues))}const u=a.get(l);for(const t in u){const{data:i,items:r}=u[t],n=i.join(",");s&&!e.validateItems(r,s)||o.add(n)}}return o.size}async createQueryResponse(){let e;if(e=this.query.outStatistics?this.query.outStatistics.some((e=>"exceedslimit"===e.statisticType))?this._createExceedsLimitQueryResponse(this.query):await this._createStatisticsQueryResponse(this.query):this._createFeatureQueryResponse(this.query),this.query.returnQueryGeometry){const t=this.query.geometry;(0,g.JY)(this.query.outSR)&&!(0,g.fS)(t.spatialReference,this.query.outSR)?e.queryGeometry=(0,P.S2)({spatialReference:this.query.outSR,...(0,k.iV)(t,t.spatialReference,this.query.outSR)}):e.queryGeometry=(0,P.S2)({spatialReference:this.query.outSR,...t})}return e}createSnappingResponse(e,t){const s=this.featureAdapter,i=J(this.hasZ,this.hasM),{point:r,mode:n}=e,a="number"==typeof e.distance?e.distance:e.distance.x,o="number"==typeof e.distance?e.distance:e.distance.y,l={candidates:[]},u="esriGeometryPolygon"===this.geometryType,c=this._getPointCreator(n,this.spatialReference,t),h=new W(null,0),d=new W(null,0),m={x:0,y:0,z:0};for(const t of this.items){const n=s.getGeometry(t);if(null==n)continue;const{coords:f,lengths:p}=n;if(h.coords=f,d.coords=f,e.returnEdge){let e=0;for(let n=0;n<p.length;n++){const u=p[n];for(let n=0;n<u;n++,e+=i){const f=h;if(f.coordsIndex=e,n!==u-1){const n=d;n.coordsIndex=e+i;const u=m;$(m,r,f,n);const h=(r.x-u.x)/a,p=(r.y-u.y)/o,y=h*h+p*p;y<=1&&l.candidates.push(B(s.getObjectId(t),c(u),Math.sqrt(y),c(f),c(n)))}}}}if("none"!==e.vertexMode){const n=u?f.length-i:f.length;if("all"===e.vertexMode)for(let e=0;e<n;e+=i){const i=h;i.coordsIndex=e;const n=(r.x-i.x)/a,u=(r.y-i.y)/o,d=n*n+u*u;d<=1&&l.candidates.push(j(s.getObjectId(t),c(i),Math.sqrt(d)))}else if("ends"===e.vertexMode){const e=[0];u||e.push(f.length-i);for(const i of e){const e=h;e.coordsIndex=i;const n=(r.x-e.x)/a,u=(r.y-e.y)/o,d=n*n+u*u;d<=1&&l.candidates.push(j(s.getObjectId(t),c(e),Math.sqrt(d)))}}}}return l.candidates.sort(((e,t)=>e.distance-t.distance)),l}_getPointCreator(e,t,s){const i=null==s||(0,g.fS)(t,s)?e=>e:e=>(0,k.iV)(e,t,s),{hasZ:r}=this;return"3d"===e?r?({x:e,y:t,z:s})=>i({x:e,y:t,z:s}):({x:e,y:t})=>i({x:e,y:t,z:0}):({x:e,y:t})=>i({x:e,y:t})}async createSummaryStatisticsResponse(e){const{field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,minValue:a,maxValue:o,scale:l,timeZone:u}=e,c=this.fieldsIndex.get(t),h=(0,q.y2)(c)||(0,q.UQ)(c)||(0,q.ig)(c),d=await this._getDataValues({field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,scale:l,timeZone:u}),m=(0,z.S5)({normalizationType:r,normalizationField:i,minValue:a,maxValue:o}),f={value:.5,fieldType:c?.type},p=(0,q.qN)(c)?(0,z.H0)({values:d,supportsNullCount:m,percentileParams:f}):(0,z.i5)({values:d,minValue:a,maxValue:o,useSampleStdDev:!r,supportsNullCount:m,percentileParams:f});return(0,z.F_)(p,h)}async createUniqueValuesResponse(e){const{field:t,valueExpression:s,domains:i,returnAllCodedValues:r,scale:n,timeZone:a}=e,o=await this._getDataValues({field:t,field2:e.field2,field3:e.field3,fieldDelimiter:e.fieldDelimiter,valueExpression:s,scale:n,timeZone:a},!1),l=(0,z.eT)(o);return(0,z.Qm)(l,i,r,e.fieldDelimiter)}async createClassBreaksResponse(e){const{field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numClasses:c,scale:h,timeZone:d}=e,m=await this._getDataValues({field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,scale:h,timeZone:d}),f=(0,z.G2)(m,{field:t,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numClasses:c});return(0,z.DL)(f,a)}async createHistogramResponse(e){const{field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numBins:c,scale:h,timeZone:d}=e,m=await this._getDataValues({field:t,valueExpression:s,normalizationField:i,normalizationType:r,normalizationTotal:n,scale:h,timeZone:d});return(0,z.oF)(m,{field:t,normalizationField:i,normalizationType:r,normalizationTotal:n,classificationMethod:a,standardDeviationInterval:o,minValue:l,maxValue:u,numBins:c})}_sortFeatures(e,t,s){if(e.length>1&&t?.length)for(const i of t.reverse()){const t=i.split(" "),r=t[0],n=this.fieldsIndex.get(r),a=!!t[1]&&"desc"===t[1].toLowerCase(),o=(0,z.Lq)(n?.type,a);e.sort(((e,t)=>{const i=s(e,r,n),a=s(t,r,n);return o(i,a)}))}}_createFeatureQueryResponse(e){const t=this.items,{geometryType:s,hasM:i,hasZ:r,objectIdField:n,spatialReference:a}=this,{outFields:o,outSR:l,quantizationParameters:u,resultRecordCount:c,resultOffset:h,returnZ:d,returnM:m}=e,f=null!=c&&t.length>(h||0)+c,p=o&&(o.includes("*")?[...this.fieldsIndex.fields]:o.map((e=>this.fieldsIndex.get(e))));return{exceededTransferLimit:f,features:this._createFeatures(e,t),fields:p,geometryType:s,hasM:i&&m,hasZ:r&&d,objectIdFieldName:n,spatialReference:(0,P.S2)(l||a),transform:u&&(0,G.vY)(u)||null}}_createFeatures(e,t){const s=new Y(e,this.featureAdapter,this.fieldsIndex),{hasM:i,hasZ:r}=this,{orderByFields:n,quantizationParameters:a,returnGeometry:o,returnCentroid:l,maxAllowableOffset:u,resultOffset:c,resultRecordCount:h,returnZ:d=!1,returnM:m=!1}=e,f=r&&d,p=i&&m;let y=[],g=0;const _=[...t];if(this._sortFeatures(_,n,((e,t,i)=>s.getFieldValue(e,t,i))),this.geometryType&&(o||l)){const e=(0,G.vY)(a)??void 0;if(o&&!l)for(const t of _)y[g++]={attributes:s.getAttributes(t),geometry:(0,P.Op)(this.geometryType,this.hasZ,this.hasM,this.featureAdapter.getGeometry(t),u,e,f,p)};else if(!o&&l)for(const t of _)y[g++]={attributes:s.getAttributes(t),centroid:(0,P.EG)(this,this.featureAdapter.getCentroid(t,this),e)};else for(const t of _)y[g++]={attributes:s.getAttributes(t),centroid:(0,P.EG)(this,this.featureAdapter.getCentroid(t,this),e),geometry:(0,P.Op)(this.geometryType,this.hasZ,this.hasM,this.featureAdapter.getGeometry(t),u,e,f,p)}}else for(const e of _){const t=s.getAttributes(e);t&&(y[g++]={attributes:t})}const T=c||0;if(null!=h){const e=T+h;y=y.slice(T,Math.min(y.length,e))}return y}_createExceedsLimitQueryResponse(e){let t=!1,s=Number.POSITIVE_INFINITY,i=Number.POSITIVE_INFINITY,r=Number.POSITIVE_INFINITY;for(const t of e.outStatistics??[])if("exceedslimit"===t.statisticType){s=null!=t.maxPointCount?t.maxPointCount:Number.POSITIVE_INFINITY,i=null!=t.maxRecordCount?t.maxRecordCount:Number.POSITIVE_INFINITY,r=null!=t.maxVertexCount?t.maxVertexCount:Number.POSITIVE_INFINITY;break}if("esriGeometryPoint"===this.geometryType)t=this.items.length>s;else if(this.items.length>i)t=!0;else{const e=J(this.hasZ,this.hasM),s=this.featureAdapter;t=this.items.reduce(((e,t)=>{const i=s.getGeometry(t);return e+(null!=i&&i.coords.length||0)}),0)/e>r}return{fields:[{name:"exceedslimit",type:"esriFieldTypeInteger",alias:"exceedslimit",sqlType:"sqlTypeInteger",domain:null,defaultValue:null}],features:[{attributes:{exceedslimit:Number(t)}}]}}async _createStatisticsQueryResponse(e){const t={attributes:{}},s=[],i=new Map,r=new Map,n=new Map,a=new Map,o=new Y(e,this.featureAdapter,this.fieldsIndex),l=e.outStatistics,{groupByFieldsForStatistics:u,having:c,orderByFields:h,resultRecordCount:d}=e,m=u?.length,f=!!m,p=f?u[0]:null,y=f&&!this.fieldsIndex.get(p);for(const e of l??[]){const{outStatisticFieldName:l,statisticType:h}=e,g=e,_="exceedslimit"!==h?e.onStatisticField:void 0,T="percentile_disc"===h||"percentile_cont"===h,S="EnvelopeAggregate"===h||"CentroidAggregate"===h||"ConvexHullAggregate"===h,x=f&&1===m&&(_===p||y)&&"count"===h;if(f){if(!n.has(_)){const e=[];for(const t of u){const s=this._getAttributeValues(o,t,i);e.push(s)}n.set(_,this._calculateUniqueValues(e,!S&&o.returnDistinctValues))}const e=n.get(_);if(!e)continue;const t=Object.keys(e);d&&(t.sort(),t.length=Math.min(d,t.length));for(const s of t){const{count:t,data:r,items:n,itemPositions:h}=e[s],d=r.join(",");if(!c||o.validateItems(n,c)){const e=a.get(d)||{attributes:{}};if(S){e.aggregateGeometries||(e.aggregateGeometries={});const{aggregateGeometries:t,outStatisticFieldName:s}=await this._getAggregateGeometry(g,n);e.aggregateGeometries[s]=t}else{let s=null;if(x)s=t;else{const e=this._getAttributeValues(o,_,i),t=h.map((t=>e[t]));s=T&&"statisticParameters"in g?this._getPercentileValue(g,t):this._getStatisticValue(g,t,null,o.returnDistinctValues)}e.attributes[l]=s}let s=0;u.forEach(((t,i)=>e.attributes[this.fieldsIndex.get(t)?t:"EXPR_"+ ++s]=r[i])),a.set(d,e)}}}else if(S){t.aggregateGeometries||(t.aggregateGeometries={});const{aggregateGeometries:e,outStatisticFieldName:s}=await this._getAggregateGeometry(g,this.items);t.aggregateGeometries[s]=e}else{const e=this._getAttributeValues(o,_,i);t.attributes[l]=T&&"statisticParameters"in g?this._getPercentileValue(g,e):this._getStatisticValue(g,e,r,o.returnDistinctValues)}const I="min"!==h&&"max"!==h||!(0,q.qN)(this.fieldsIndex.get(_))&&!this._isAnyDateField(_)?null:this.fieldsIndex.get(_)?.type;s.push({name:l,alias:l,type:I||"esriFieldTypeDouble"})}const g=f?Array.from(a.values()):[t];return this._sortFeatures(g,h,((e,t)=>e.attributes[t])),{fields:s,features:g}}_isAnyDateField(e){const t=this.fieldsIndex.get(e);return(0,q.y2)(t)||(0,q.UQ)(t)||(0,q.ig)(t)||(0,q.sX)(t)}async _getAggregateGeometry(e,t){const{convexHull:i,union:r}=await Promise.all([s.e(5837),s.e(247)]).then(s.bind(s,30247)),{statisticType:n,outStatisticFieldName:a}=e,{featureAdapter:o,spatialReference:l,geometryType:u,hasZ:c,hasM:h}=this,d=t.map((e=>(0,P.Op)(u,c,h,o.getGeometry(e)))),m=i(l,d,!0)[0],f={aggregateGeometries:null,outStatisticFieldName:null};if("EnvelopeAggregate"===n){const e=m?(0,U._w)(m):(0,U.aO)(r(l,d));f.aggregateGeometries={...e,spatialReference:l},f.outStatisticFieldName=a||"extent"}else if("CentroidAggregate"===n){const e=m?(0,L.tO)(m):(0,L.$G)((0,U.aO)(r(l,d)));f.aggregateGeometries={x:e[0],y:e[1],spatialReference:l},f.outStatisticFieldName=a||"centroid"}else"ConvexHullAggregate"===n&&(f.aggregateGeometries=m,f.outStatisticFieldName=a||"convexHull");return f}_getStatisticValue(e,t,s,i){const{onStatisticField:r,statisticType:n}=e;let a=null;return a=s?.has(r)?s.get(r):(0,q.qN)(this.fieldsIndex.get(r))||this._isAnyDateField(r)?(0,z.H0)({values:t,returnDistinct:i}):(0,z.i5)({values:i?[...new Set(t)]:t,minValue:null,maxValue:null,useSampleStdDev:!0}),s&&s.set(r,a),a["var"===n?"variance":n]}_getPercentileValue(e,t){const{onStatisticField:s,statisticParameters:i,statisticType:r}=e,{value:n,orderBy:a}=i,o=this.fieldsIndex.get(s);return(0,z.XL)(t,{value:n,orderBy:a,fieldType:o?.type,isDiscrete:"percentile_disc"===r})}_getAttributeValues(e,t,s){if(s.has(t))return s.get(t);const i=this.fieldsIndex.get(t),r=this.items.map((s=>e.getFieldValue(s,t,i)));return s.set(t,r),r}_calculateUniqueValues(e,t){const s={},i=this.items,r=i.length;for(let n=0;n<r;n++){const r=i[n],a=[];for(const t of e)a.push(t[n]);const o=a.join(",");null==s[o]?s[o]={count:1,data:a,items:[r],itemPositions:[n]}:(t||s[o].count++,s[o].items.push(r),s[o].itemPositions.push(n))}return s}async _getDataValues(e,t=!0){const s=new Y(this.query,this.featureAdapter,this.fieldsIndex),{valueExpression:i,scale:r,timeZone:n}=e;return i?s.getExpressionValues(this.items,i,{viewingMode:"map",scale:r,spatialReference:this.query.outSR||this.spatialReference},{geometryType:this.geometryType,hasZ:this.hasZ,hasM:this.hasM},n):s.getDataValues(this.items,(0,a.d9)(e),t)}}function $(e,t,s,i){const r=i.x-s.x,n=i.y-s.y,a=r*r+n*n,o=(t.x-s.x)*r+(t.y-s.y)*n,l=Math.min(1,Math.max(0,o/a));e.x=s.x+r*l,e.y=s.y+n*l}function J(e,t){return e?t?4:3:t?3:2}class W{constructor(e,t){this.coords=e,this.coordsIndex=t}get x(){return this.coords[this.coordsIndex]}get y(){return this.coords[this.coordsIndex+1]}get z(){return this.coords[this.coordsIndex+2]}}var X=s(22222),K=s(10402);const ee="unsupported-query";async function te(e,{fieldsIndex:t,geometryType:s,spatialReference:i,availableFields:n}){if((e.distance??0)<0||null!=e.geometryPrecision||e.multipatchOption&&"xyFootprint"!==e.multipatchOption||e.pixelSize||e.relationParam||e.text)throw new r.Z(ee,"Unsupported query options",{query:e});return se(t,n,e),function(e,t,s){const{outStatistics:i,groupByFieldsForStatistics:n,having:a}=s,o=n?.length,l=i?.length;if(a){if(!o||!l)throw new r.Z(ee,"outStatistics and groupByFieldsForStatistics should be specified with having",{query:s});A(e,t,a,i,s)}if(l){if(null==(u=i)||!u.every((e=>"exceedslimit"!==e.statisticType)))return;const a=i.map((e=>e.onStatisticField)).filter(Boolean);C(e,t,a,{expressionName:"onStatisticFields",query:s}),o&&C(e,t,n,{expressionName:"groupByFieldsForStatistics",query:s});for(const n of i){const{onStatisticField:i,statisticType:a}=n;if("percentile_disc"!==a&&"percentile_cont"!==a||!("statisticParameters"in n))e.get(i)&&"count"!==a&&"min"!==a&&"max"!==a&&C(e,t,[i],{expressionName:`outStatistics with '${a}' statistic type`,allowedFieldTypes:ie,query:s});else{const{statisticParameters:e}=n;if(!e)throw new r.Z(ee,"statisticParameters should be set for percentile type",{definition:n,query:s})}}}var u}(t,n,e),Promise.all([(0,K.P0)(e,s,i),(0,k._W)(i,e.outSR)]).then((()=>e))}function se(e,t,s){const{outFields:i,orderByFields:n,returnDistinctValues:a,outStatistics:o}=s,l=o?o.map((e=>e.outStatisticFieldName&&e.outStatisticFieldName.toLowerCase())).filter(Boolean):[];if(n&&n.length>0){const i=" asc",r=" desc",a=n.map((e=>{const t=e.toLowerCase();return t.includes(i)?t.split(i)[0]:t.includes(r)?t.split(r)[0]:e})).filter((e=>!l.includes(e)));C(e,t,a,{expressionName:"orderByFields",query:s})}if(i&&i.length>0)C(e,t,i,{expressionName:"outFields",query:s});else if(a)throw new r.Z(ee,"outFields should be specified for returnDistinctValues",{query:s});!function(e,t,s,i){if(!s)return!0;const r="where clause";C(e,t,N(e,s,{validateStandardized:!0,expressionName:r}),{expressionName:r,query:i})}(e,t,s.where,s)}const ie=new Set([...R,...E]);async function re(e,t,s,i){let n=[];if(s.valueExpression){const{arcadeUtils:e}=await(0,Q.LC)();n=e.extractFieldNames(s.valueExpression)}if(s.field&&n.push(s.field),s.field2&&n.push(s.field2),s.field3&&n.push(s.field3),s.normalizationField&&n.push(s.normalizationField),!n.length&&!s.valueExpression)throw new r.Z(ee,"field or valueExpression is required",{params:s});C(e,t,n,{expressionName:"statistics",query:i})}var ne=s(17590),ae=s(99514),oe=s(61247),le=(s(80442),s(92604)),ue=s(54790),ce=s(44553),he=s(17445),de=s(95528),me=s(76882);class fe{constructor(){this._tasks=new Array,this._running=(0,de.t)(!1)}get length(){return this._tasks.length}get running(){return this._running.value}destroy(){this.cancelAll()}runTask(e){for(;!e.done&&this._process(e);)e.madeProgress()}push(e,t,s){return this._running.value=!0,new Promise(((i,r)=>this._tasks.push(new pe(i,r,e,t,s))))}unshift(e,t,s){return this._running.value=!0,new Promise(((i,r)=>this._tasks.unshift(new pe(i,r,e,t,s))))}_process(e){if(0===this._tasks.length)return!1;const t=this._tasks.shift();try{const s=(0,u.Hc)(t.signal);if(s&&!t.abortCallback)t.reject((0,u.zE)());else{const i=s?t.abortCallback?.((0,u.zE)()):t.callback(e);(0,u.y8)(i)?i.then(t.resolve,t.reject):t.resolve(i)}}catch(e){t.reject(e)}return this._running.value=this._tasks.length>0,!0}cancelAll(){const e=(0,u.zE)();for(const t of this._tasks)if(t.abortCallback){const s=t.abortCallback(e);t.resolve(s)}else t.reject(e);this._tasks.length=0,this._running.value=!1}}class pe{constructor(e,t,s,i=void 0,r=void 0){this.resolve=e,this.reject=t,this.callback=s,this.signal=i,this.abortCallback=r}}var ye=s(43697),ge=s(92036),_e=s(5600),Te=(s(75215),s(52011));let Se=class extends ge.Z{constructor(){super(...arguments),this.SCHEDULER_LOG_SLOW_TASKS=!1,this.FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES=!1}};(0,ye._)([(0,_e.Cb)()],Se.prototype,"SCHEDULER_LOG_SLOW_TASKS",void 0),(0,ye._)([(0,_e.Cb)()],Se.prototype,"FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES",void 0),Se=(0,ye._)([(0,Te.j)("esri.views.support.DebugFlags")],Se);const xe=new Se;var Ie,Fe,we,Re=s(95720);(we=Ie||(Ie={}))[we.YIELD=1]="YIELD",function(e){e.RESOURCE_CONTROLLER_IMMEDIATE="immediate",e.RESOURCE_CONTROLLER="schedule",e.SLIDE="slide",e.STREAM_DATA_LOADER="stream loader",e.ELEVATION_QUERY="elevation query",e.TERRAIN_SURFACE="terrain",e.SURFACE_GEOMETRY_UPDATES="surface geometry updates",e.LOD_RENDERER="LoD renderer",e.GRAPHICS_CORE="Graphics3D",e.I3S_CONTROLLER="I3S",e.POINT_CLOUD_LAYER="point cloud",e.FEATURE_TILE_FETCHER="feature fetcher",e.OVERLAY="overlay",e.STAGE="stage",e.GRAPHICS_DECONFLICTOR="graphics deconflictor",e.FILTER_VISIBILITY="Graphics3D filter visibility",e.SCALE_VISIBILITY="Graphics3D scale visibility",e.FRUSTUM_VISIBILITY="Graphics3D frustum visibility",e.POINT_OF_INTEREST_FREQUENT="POI frequent",e.POINT_OF_INTEREST_INFREQUENT="POI infrequent",e.LABELER="labeler",e.FEATURE_QUERY_ENGINE="feature query",e.FEATURE_TILE_TREE="feature tile tree",e.FEATURE_TILE_TREE_ACTIVE="fast feature tile tree",e.ELEVATION_ALIGNMENT="elevation alignment",e.TEXT_TEXTURE_ATLAS="text texture atlas",e.TEXTURE_UNLOAD="texture unload",e.LINE_OF_SIGHT_TOOL="line of sight tool",e.LINE_OF_SIGHT_TOOL_INTERACTIVE="interactive line of sight tool",e.ELEVATION_PROFILE="elevation profile",e.SNAPPING="snapping",e.SHADOW_ACCUMULATOR="shadow accumulator",e.CLOUDS_GENERATOR="clouds generator",e[e.NONE=0]="NONE",e[e.TEST_PRIO=1]="TEST_PRIO"}(Fe||(Fe={}));const Ee=new Map([[Fe.RESOURCE_CONTROLLER_IMMEDIATE,0],[Fe.RESOURCE_CONTROLLER,4],[Fe.SLIDE,0],[Fe.STREAM_DATA_LOADER,0],[Fe.ELEVATION_QUERY,0],[Fe.TERRAIN_SURFACE,1],[Fe.SURFACE_GEOMETRY_UPDATES,1],[Fe.LOD_RENDERER,2],[Fe.GRAPHICS_CORE,2],[Fe.I3S_CONTROLLER,2],[Fe.POINT_CLOUD_LAYER,2],[Fe.FEATURE_TILE_FETCHER,2],[Fe.OVERLAY,4],[Fe.STAGE,4],[Fe.GRAPHICS_DECONFLICTOR,4],[Fe.FILTER_VISIBILITY,4],[Fe.SCALE_VISIBILITY,4],[Fe.FRUSTUM_VISIBILITY,4],[Fe.CLOUDS_GENERATOR,4],[Fe.POINT_OF_INTEREST_FREQUENT,6],[Fe.POINT_OF_INTEREST_INFREQUENT,30],[Fe.LABELER,8],[Fe.FEATURE_QUERY_ENGINE,8],[Fe.FEATURE_TILE_TREE,16],[Fe.FEATURE_TILE_TREE_ACTIVE,0],[Fe.ELEVATION_ALIGNMENT,12],[Fe.TEXT_TEXTURE_ATLAS,12],[Fe.TEXTURE_UNLOAD,12],[Fe.LINE_OF_SIGHT_TOOL,16],[Fe.LINE_OF_SIGHT_TOOL_INTERACTIVE,0],[Fe.SNAPPING,0],[Fe.SHADOW_ACCUMULATOR,30]]);function be(e){return Ee.has(e)?Ee.get(e):"number"==typeof e?e:1}const Ne=(0,me.HA)(6.5),Ae=(0,me.HA)(1),ve=(0,me.HA)(30),De=(0,me.HA)(1e3/30),Me=(0,me.HA)(100);var Ce,Oe;!function(e){e.Scheduler=class{get updating(){return this._updating.value}_updatingChanged(){this._updating.value=this._tasks.some((e=>e.needsUpdate))}constructor(){this._updating=(0,de.t)(!0),this._microTaskQueued=!1,this._frameNumber=0,this.performanceInfo={total:new ue.Z("total"),tasks:new Map},this._frameTaskTimes=new Map,this._budget=new s,this._state=Re.n.INTERACTING,this._tasks=new ce.Z,this._runQueue=new ce.Z,this._load=0,this._idleStateCallbacks=new ce.Z,this._idleUpdatesStartFired=!1,this._forceTask=!1,this._debug=!1,this._debugHandle=(0,he.YP)((()=>xe.SCHEDULER_LOG_SLOW_TASKS),(e=>this._debug=e),he.nn);for(const e of Object.keys(Fe))this.performanceInfo.tasks.set(Fe[e],new ue.Z(Fe[e]));const e=this;this._test={FRAME_SAFETY_BUDGET:Ne,INTERACTING_BUDGET:De,IDLE_BUDGET:Me,get availableBudget(){return e._budget.budget},usedBudget:0,getBudget:()=>e._budget,setBudget:t=>e._budget=t,updateTask:e=>this._updateTask(e),getState:e=>this._getState(e),getRuntime:e=>this._getRuntime(e),frameTaskTimes:this._frameTaskTimes,resetRuntimes:()=>this._resetRuntimes(),getRunning:()=>this._getRunning()}}destroy(){this._tasks.toArray().forEach((e=>e.remove())),this._tasks.clear(),(0,o.hw)(this._debugHandle),this._microTaskQueued=!1,this._updatingChanged()}taskRunningChanged(e){this._updatingChanged(),e&&this._budget.remaining>0&&!this._microTaskQueued&&(this._microTaskQueued=!0,queueMicrotask((()=>{this._microTaskQueued&&(this._microTaskQueued=!1,this._budget.remaining>0&&this._schedule()&&this.frame())})))}registerTask(e,s){const i=be(e),r=new t(this,e,s,i);return this._tasks.push(r),this._updatingChanged(),this.performanceInfo.tasks.has(e)||this.performanceInfo.tasks.set(e,new ue.Z(e)),r}registerIdleStateCallbacks(e,t){const s={idleBegin:e,idleEnd:t};this._idleStateCallbacks.push(s),this.state===Re.n.IDLE&&this._idleUpdatesStartFired&&s.idleBegin();const i=this;return{remove:()=>this._removeIdleStateCallbacks(s),set idleBegin(e){i._idleUpdatesStartFired&&(s.idleEnd(),i._state===Re.n.IDLE&&e()),s.idleBegin=e},set idleEnd(e){s.idleEnd=e}}}get load(){return this._load}set state(e){this._state!==e&&(this._state=e,this.state!==Re.n.IDLE&&this._idleUpdatesStartFired&&(this._idleUpdatesStartFired=!1,this._idleStateCallbacks.forAll((e=>e.idleEnd()))))}get state(){return this._state}updateBudget(e){this._test.usedBudget=0,++this._frameNumber;let t=Ne,s=e.frameDuration,i=Ae;switch(this.state){case Re.n.IDLE:t=(0,me.HA)(0),s=(0,me.HA)(Math.max(Me,e.frameDuration)),i=ve;break;case Re.n.INTERACTING:s=(0,me.HA)(Math.max(De,e.frameDuration));case Re.n.ANIMATING:}return s=(0,me.HA)(s-e.elapsedFrameTime-t),this.state!==Re.n.IDLE&&s<Ae&&!this._forceTask?(this._forceTask=!0,!1):(s=(0,me.HA)(Math.max(s,i)),this._budget.reset(s,this.state),this._updateLoad(),this._schedule())}frame(){switch(this._forceTask=!1,this._microTaskQueued=!1,this.state){case Re.n.IDLE:this._idleUpdatesStartFired||(this._idleUpdatesStartFired=!0,this._idleStateCallbacks.forAll((e=>e.idleBegin()))),this._runIdle();break;case Re.n.INTERACTING:this._runInteracting();break;default:this._runAnimating()}this._test.usedBudget=this._budget.elapsed}stopFrame(){this._budget.reset((0,me.HA)(0),this._state),this._budget.madeProgress()}_removeIdleStateCallbacks(e){this._idleUpdatesStartFired&&e.idleEnd(),this._idleStateCallbacks.removeUnordered(e)}removeTask(e){this._tasks.removeUnordered(e),this._runQueue.removeUnordered(e),this._updatingChanged()}_updateTask(e){this._tasks.forAll((t=>{t.name===e&&t.setPriority(e)}))}_getState(e){if(this._runQueue.some((t=>t.name===e)))return Oe.SCHEDULED;let t=Oe.IDLE;return this._tasks.forAll((s=>{s.name===e&&s.needsUpdate&&(s.schedulePriority<=1?t=Oe.READY:t!==Oe.READY&&(t=Oe.WAITING))})),t}_getRuntime(e){let t=0;return this._tasks.forAll((s=>{s.name===e&&(t+=s.runtime)})),t}_resetRuntimes(){this._tasks.forAll((e=>e.runtime=0))}_getRunning(){const e=new Map;if(this._tasks.forAll((t=>{t.needsUpdate&&e.set(t.name,(e.get(t.name)||0)+1)})),0===e.size)return null;let t="";return e.forEach(((e,s)=>{t+=e>1?` ${e}x ${s}`:` ${s}`})),t}_runIdle(){this._run()}_runInteracting(){this._run()}_runAnimating(){this._run()}_updateLoad(){const e=this._tasks.reduce(((e,t)=>t.needsUpdate?++e:e),0);this._load=.9*this._load+e*(1-.9)}_schedule(){for(this._runQueue.filterInPlace((e=>!!e.needsUpdate||(e.schedulePriority=e.basePriority,!1))),this._tasks.forAll((e=>{0===e.basePriority&&e.needsUpdate&&!this._runQueue.includes(e)&&e.blockFrame!==this._frameNumber&&this._runQueue.unshift(e)}));0===this._runQueue.length;){let e=!1,t=0;if(this._tasks.forAll((s=>{s.needsUpdate&&0!==s.schedulePriority&&0!==s.basePriority&&s.blockFrame!==this._frameNumber&&(e=!0,t=Math.max(t,s.basePriority),1===s.schedulePriority?(s.schedulePriority=0,this._runQueue.push(s)):--s.schedulePriority)})),!e)return this._updatingChanged(),!1}return this._updatingChanged(),!0}_run(){const e=this._budget.now();this._startFrameTaskTimes();do{for(;this._runQueue.length>0;){const t=this._budget.now(),s=this._runQueue.pop();this._budget.resetProgress();try{s.task.runTask(this._budget)===Ie.YIELD&&(s.blockFrame=this._frameNumber)}catch(e){le.Z.getLogger("esri.views.support.Scheduler").error(`Exception in task "${s.name}"`,e),s.blockFrame=this._frameNumber}!this._budget.hasProgressed&&s.blockFrame!==this._frameNumber&&s.needsUpdate&&(s.name,Fe.I3S_CONTROLLER,s.blockFrame=this._frameNumber),s.schedulePriority=s.basePriority;const i=this._budget.now()-t;if(s.runtime+=i,this._frameTaskTimes.set(s.priority,this._frameTaskTimes.get(s.priority)+i),this._debug&&i>2*this._budget.budget&&console.log("Task",s.name,"used",i,"of max",this._budget.budget,"ms"),this._budget.remaining<=0)return this._updatingChanged(),void this._recordFrameTaskTimes(this._budget.now()-e)}}while(this._schedule());this._updatingChanged(),this._recordFrameTaskTimes(this._budget.now()-e)}_startFrameTaskTimes(){for(const e of Object.keys(Fe))this._frameTaskTimes.set(Fe[e],0)}_recordFrameTaskTimes(e){this._frameTaskTimes.forEach(((e,t)=>this.performanceInfo.tasks.get(t).record(e))),this.performanceInfo.total.record(e)}get test(){return this._test}};class t{get task(){return this._task.value}get updating(){return this._queue.running}constructor(e,t,s,i){this._scheduler=e,this.name=t,this._basePriority=i,this.blockFrame=0,this.runtime=0,this._queue=new fe,this._handles=new oe.Z,this.schedulePriority=this._basePriority,this._task=(0,de.t)(null!=s?s:this._queue),this._handles.add((0,he.gx)((()=>this.task.running),(t=>e.taskRunningChanged(t))))}remove(){this.processQueue(Pe),this._scheduler.removeTask(this),this.schedule=ke.schedule,this.reschedule=ke.reschedule,this._handles.destroy()}get basePriority(){return this._basePriority}setPriority(e){this.name=e;const t=be(e);0!==this._basePriority&&0===this.schedulePriority||(this.schedulePriority=t),this._basePriority=t}get priority(){return this.name}set priority(e){this.setPriority(e)}get needsUpdate(){return this.updating||this.task.running}schedule(e,t,s){return this._queue.push(e,t,s)}reschedule(e,t,s){return this._queue.unshift(e,t,s)}processQueue(e){this._queue.runTask(e)}}class s{constructor(){this._begin="undefined"!=typeof performance?performance.now():0,this._budget=0,this._state=Re.n.IDLE,this._done=!1,this._progressed=!1,this._enabled=!0}run(e){return!this.done&&(!0===e()&&this.madeProgress(),!0)}get done(){return this._done}get budget(){return this._budget}madeProgress(){return this._progressed=!0,this._done=this.elapsed>=this._budget&&this._enabled,this._done}get state(){return this._state}get enabled(){return this._enabled}set enabled(e){this._enabled=e}reset(e,t){this._begin=this.now(),this._budget=e,this._state=t,this.resetProgress()}get remaining(){return Math.max(this._budget-this.elapsed,0)}now(){return performance.now()}get elapsed(){return performance.now()-this._begin}resetProgress(){this._progressed=!1,this._done=!1}get hasProgressed(){return this._progressed}}e.Budget=s}(Ce||(Ce={})),function(e){e.SCHEDULED="s",e.READY="r",e.WAITING="w",e.IDLE="i"}(Oe||(Oe={}));const Pe=(()=>{const e=new Ce.Budget;return e.enabled=!1,e})(),ke=new class{remove(){}processQueue(){}schedule(e,t,s){try{if((0,u.Hc)(t)){const e=(0,u.zE)();return s?Promise.resolve(s(e)):Promise.reject(e)}return(0,u.gx)(e(Pe))}catch(e){return Promise.reject(e)}}reschedule(e,t,s){return this.schedule(e,t,s)}},Ze=new l.WJ(2e6);let Le=0;class Ue{constructor(e){this._geometryQueryCache=null,this._changeHandle=null,this.capabilities={query:Z.g},this.geometryType=e.geometryType,this.hasM=!!e.hasM,this.hasZ=!!e.hasZ,this.objectIdField=e.objectIdField,this.spatialReference=e.spatialReference,this.definitionExpression=e.definitionExpression,this.featureStore=e.featureStore,this.aggregateAdapter=e.aggregateAdapter,this._changeHandle=this.featureStore.events.on("changed",(()=>this.clearCache())),this.timeInfo=e.timeInfo,e.cacheSpatialQueries&&(this._geometryQueryCache=new l.Xq(Le+++"$$",Ze)),this.fieldsIndex=(0,n.AK)(e.fieldsIndex)?e.fieldsIndex:ae.Z.fromJSON(e.fieldsIndex),this.availableFields=null==e.availableFields?new Set(this.fieldsIndex.fields.map((e=>e.name))):new Set(e.availableFields.map((e=>this.fieldsIndex.get(e)?.name)).filter((e=>null!=e))),e.scheduler&&e.priority&&(this._frameTask=e.scheduler.registerTask(e.priority))}destroy(){this._frameTask=(0,o.hw)(this._frameTask),this.clearCache(),(0,o.SC)(this._geometryQueryCache),this._changeHandle=(0,o.hw)(this._changeHandle)}get featureAdapter(){return this.featureStore.featureAdapter}clearCache(){this._geometryQueryCache?.clear(),this._allFeaturesPromise=null,this._timeExtentPromise=null,this._fullExtentPromise=null}async executeQuery(e,t){try{return(await this._executeQuery(e,{},t)).createQueryResponse()}catch(t){if(t!==X.Ti)throw t;return new H([],e,this).createQueryResponse()}}async executeQueryForCount(e={},t){try{return(await this._executeQuery(e,{returnGeometry:!1,returnCentroid:!1,outSR:null},t)).createQueryResponseForCount()}catch(e){if(e!==X.Ti)throw e;return 0}}async executeQueryForExtent(e,t){const s=e.outSR;try{const i=await this._executeQuery(e,{returnGeometry:!0,returnCentroid:!1,outSR:null},t),r=i.size;return r?{count:r,extent:await this._getBounds(i.items,i.spatialReference,s||this.spatialReference)}:{count:0,extent:null}}catch(e){if(e===X.Ti)return{count:0,extent:null};throw e}}async executeQueryForIds(e,t){return this.executeQueryForIdSet(e,t).then((e=>Array.from(e)))}async executeQueryForIdSet(e,t){try{const s=await this._executeQuery(e,{returnGeometry:!0,returnCentroid:!1,outSR:null},t),i=s.items,r=new Set;return await this._reschedule((()=>{for(const e of i)r.add(s.featureAdapter.getObjectId(e))}),t),r}catch(e){if(e===X.Ti)return new Set;throw e}}async executeQueryForSnapping(e,t){const{point:s,distance:i,returnEdge:r,vertexMode:n}=e;if(!r&&"none"===n)return{candidates:[]};let o=(0,a.d9)(e.query);o=await this._schedule((()=>(0,X.j6)(o,this.definitionExpression,this.spatialReference)),t),o=await this._reschedule((()=>te(o,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference})),t);const l=!(0,g.fS)(s.spatialReference,this.spatialReference);l&&await(0,k._W)(s.spatialReference,this.spatialReference);const u="number"==typeof i?i:i.x,c="number"==typeof i?i:i.y,h={xmin:s.x-u,xmax:s.x+u,ymin:s.y-c,ymax:s.y+c,spatialReference:s.spatialReference},d=l?(0,k.iV)(h,this.spatialReference):h;if(!d)return{candidates:[]};const m=(await(0,y.aX)((0,p.im)(s),null,{signal:t}))[0],f=(await(0,y.aX)((0,p.im)(d),null,{signal:t}))[0];if(null==m||null==f)return{candidates:[]};const _=new H(await this._reschedule((()=>this._searchFeatures(this._getQueryBBoxes(f.toJSON()))),t),o,this);await this._reschedule((()=>this._executeObjectIdsQuery(_)),t),await this._reschedule((()=>this._executeTimeQuery(_)),t),await this._reschedule((()=>this._executeAttributesQuery(_)),t),await this._reschedule((()=>this._executeGeometryQueryForSnapping(_,t)),t);const T=m.toJSON(),S=l?(0,k.iV)(T,this.spatialReference):T,x=l?Math.max(d.xmax-d.xmin,d.ymax-d.ymin)/2:i;return _.createSnappingResponse({...e,point:S,distance:x},s.spatialReference)}async executeQueryForLatestObservations(e,t){if(!this.timeInfo?.trackIdField)throw new r.Z("unsupported-query","Missing timeInfo or timeInfo.trackIdField",{query:e,timeInfo:this.timeInfo});try{const s=await this._executeQuery(e,{},t);return await this._reschedule((()=>this._filterLatest(s)),t),s.createQueryResponse()}catch(t){if(t!==X.Ti)throw t;return new H([],e,this).createQueryResponse()}}async executeQueryForSummaryStatistics(e={},t,s){const{field:i,normalizationField:r,valueExpression:n}=t;return(await this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n},s)).createSummaryStatisticsResponse(t)}async executeQueryForUniqueValues(e={},t,s){const{field:i,field2:r,field3:n,valueExpression:a}=t;return(await this._executeQueryForStatistics(e,{field:i,field2:r,field3:n,valueExpression:a},s)).createUniqueValuesResponse(t)}async executeQueryForClassBreaks(e={},t,s){const{field:i,normalizationField:r,valueExpression:n}=t;return(await this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n},s)).createClassBreaksResponse(t)}async executeQueryForHistogram(e={},t,s){const{field:i,normalizationField:r,valueExpression:n}=t;return(await this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n},s)).createHistogramResponse(t)}async fetchRecomputedExtents(e){this._timeExtentPromise||=(0,ne.R)(this.timeInfo,this.featureStore);const[t,s]=await Promise.all([this._getFullExtent(),this._timeExtentPromise]);return(0,u.k_)(e),{fullExtent:t,timeExtent:s}}async _getBounds(e,t,s){const i=(0,d.t8)((0,d.Ue)(),d.G_);await this.featureStore.forEachBounds(e,(e=>(0,d.TC)(i,e)));const r={xmin:i[0],ymin:i[1],xmax:i[3],ymax:i[4],spatialReference:(0,P.S2)(this.spatialReference)};this.hasZ&&isFinite(i[2])&&isFinite(i[5])&&(r.zmin=i[2],r.zmax=i[5]);const n=(0,k.iV)(r,t,s);if(n.spatialReference=(0,P.S2)(s),n.xmax-n.xmin==0){const e=(0,c.c9)(n.spatialReference);n.xmin-=e,n.xmax+=e}if(n.ymax-n.ymin==0){const e=(0,c.c9)(n.spatialReference);n.ymin-=e,n.ymax+=e}if(this.hasZ&&null!=n.zmin&&null!=n.zmax&&n.zmax-n.zmin==0){const e=(0,c.c9)(n.spatialReference);n.zmin-=e,n.zmax+=e}return n}_getFullExtent(){return this._fullExtentPromise||="getFullExtent"in this.featureStore&&this.featureStore.getFullExtent?Promise.resolve(this.featureStore.getFullExtent(this.spatialReference)):this._getAllFeatures().then((e=>this._getBounds(e,this.spatialReference,this.spatialReference))),this._fullExtentPromise}async _schedule(e,t){return null!=this._frameTask?this._frameTask.schedule(e,t):e(Pe)}async _reschedule(e,t){return null!=this._frameTask?this._frameTask.reschedule(e,t):e(Pe)}async _getAllFeaturesQueryEngineResult(e){return new H(await this._getAllFeatures(),e,this)}async _getAllFeatures(){if(null==this._allFeaturesPromise){const e=[];this._allFeaturesPromise=(async()=>{await this.featureStore.forEach((t=>e.push(t)))})().then((()=>e))}const e=this._allFeaturesPromise,t=await e;return e===this._allFeaturesPromise?t.slice():this._getAllFeatures()}async _executeQuery(e,t,s){e=(0,a.d9)(e),e=await this._schedule((()=>(0,X.Up)(e,this.definitionExpression,this.spatialReference)),s),e=await this._reschedule((()=>te(e,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference})),s),e={...e,...t};const i=await this._reschedule((()=>this._executeSceneFilterQuery(e,s)),s),r=await this._reschedule((()=>this._executeGeometryQuery(e,i,s)),s);return await this._reschedule((()=>this._executeAggregateIdsQuery(r)),s),await this._reschedule((()=>this._executeObjectIdsQuery(r)),s),await this._reschedule((()=>this._executeTimeQuery(r)),s),await this._reschedule((()=>this._executeAttributesQuery(r)),s),r}async _executeSceneFilterQuery(e,t){if(null==e.sceneFilter)return null;const{outSR:s,returnGeometry:i,returnCentroid:r}=e,n=this.featureStore.featureSpatialReference,a=e.sceneFilter.geometry,o=null==n||(0,g.fS)(n,a.spatialReference)?a:(0,k.iV)(a,n);if(!o)return null;const l=i||r,u=(0,g.JY)(s)&&!(0,g.fS)(this.spatialReference,s)&&l?async e=>this._project(e,s):e=>e,c=this.featureAdapter,h=await this._reschedule((()=>this._searchFeatures(this._getQueryBBoxes(o))),t);if("disjoint"===e.sceneFilter.spatialRelationship){if(!h.length)return null;const s=new Set;for(const e of h)s.add(c.getObjectId(e));const i=await this._reschedule((()=>this._getAllFeatures()),t),r=await this._reschedule((async()=>{const r=await(0,K.cW)("esriSpatialRelDisjoint",o,this.geometryType,this.hasZ,this.hasM),n=await this._runSpatialFilter(i,(e=>!s.has(c.getObjectId(e))||r(c.getGeometry(e))),t);return new H(n,e,this)}),t);return u(r)}if(!h.length)return new H([],e,this);if(this._canExecuteSinglePass(o,e))return u(new H(h,e,this));const d=await(0,K.cW)("esriSpatialRelContains",o,this.geometryType,this.hasZ,this.hasM),m=await this._runSpatialFilter(h,(e=>d(c.getGeometry(e))),t);return u(new H(m,e,this))}async _executeGeometryQuery(e,t,s){if(null!=t&&0===t.items.length)return t;e=null!=t?t.query:e;const{geometry:r,outSR:n,spatialRel:a,returnGeometry:o,returnCentroid:l}=e,u=this.featureStore.featureSpatialReference,c=!r||null==u||(0,g.fS)(u,r.spatialReference)?r:(0,k.iV)(r,u),h=o||l,d=(0,g.JY)(n)&&!(0,g.fS)(this.spatialReference,n),m=this._geometryQueryCache&&null==t?d&&h?JSON.stringify({originalFilterGeometry:r,spatialRelationship:a,outSpatialReference:n}):JSON.stringify({originalFilterGeometry:r,spatialRelationship:a}):null,f=m?this._geometryQueryCache.get(m):null;if(null!=f)return new H(f,e,this);const p=async e=>(d&&h&&await this._project(e,n),m&&this._geometryQueryCache.put(m,e.items,e.items.length+1),e);if(!c)return p(null!=t?t:await this._getAllFeaturesQueryEngineResult(e));const y=this.featureAdapter;let _=await this._reschedule((()=>this._searchFeatures(this._getQueryBBoxes(r))),s);if("esriSpatialRelDisjoint"===a){if(!_.length)return p(null!=t?t:await this._getAllFeaturesQueryEngineResult(e));const i=new Set;for(const e of _)i.add(y.getObjectId(e));const r=null!=t?t.items:await this._reschedule((()=>this._getAllFeatures()),s),n=await this._reschedule((async()=>{const t=await(0,K.cW)(a,c,this.geometryType,this.hasZ,this.hasM),n=await this._runSpatialFilter(r,(e=>!i.has(y.getObjectId(e))||t(y.getGeometry(e))),s);return new H(n,e,this)}),s);return p(n)}if(null!=t){const e=new i.SO;_=_.filter((s=>(0,i.cq)(t.items,s,t.items.length,e)>=0))}if(!_.length){const t=new H([],e,this);return m&&this._geometryQueryCache.put(m,t.items,1),t}if(this._canExecuteSinglePass(c,e))return p(new H(_,e,this));const T=await(0,K.cW)(a,c,this.geometryType,this.hasZ,this.hasM),S=await this._runSpatialFilter(_,(e=>T(y.getGeometry(e))),s);return p(new H(S,e,this))}async _executeGeometryQueryForSnapping(e,t){const{query:s}=e,{spatialRel:i}=s;if(!e?.items?.length||!s.geometry||!i)return;const r=await(0,K.cW)(i,s.geometry,this.geometryType,this.hasZ,this.hasM),n=await this._runSpatialFilter(e.items,(e=>r(e.geometry)),t);e.items=n}_executeAggregateIdsQuery(e){if(0===e.items.length||!e.query.aggregateIds?.length||null==this.aggregateAdapter)return;const t=new Set;for(const s of e.query.aggregateIds)this.aggregateAdapter.getFeatureObjectIds(s).forEach((e=>t.add(e)));const s=this.featureAdapter.getObjectId;e.items=e.items.filter((e=>t.has(s(e))))}_executeObjectIdsQuery(e){if(0===e.items.length||!e.query.objectIds?.length)return;const t=new Set(e.query.objectIds),s=this.featureAdapter.getObjectId;e.items=e.items.filter((e=>t.has(s(e))))}_executeTimeQuery(e){if(0===e.items.length)return;const t=(0,ne.y)(this.timeInfo,e.query.timeExtent,this.featureAdapter);null!=t&&(e.items=e.items.filter(t))}_executeAttributesQuery(e){if(0===e.items.length)return;const t=v(e.query.where,this.fieldsIndex);if(t){if(!t.isStandardized)throw new TypeError("Where clause is not standardized");e.items=e.items.filter((e=>t.testFeature(e,this.featureAdapter)))}}async _runSpatialFilter(e,t,s){if(!t)return e;if(null==this._frameTask)return e.filter((e=>t(e)));let i=0;const r=new Array,n=async a=>{for(;i<e.length;){const o=e[i++];t(o)&&(r.push(o),a.madeProgress()),a.done&&await this._reschedule((e=>n(e)),s)}};return this._reschedule((e=>n(e)),s).then((()=>r))}_filterLatest(e){const{trackIdField:t,startTimeField:s,endTimeField:i}=this.timeInfo,r=i||s,n=new Map,a=this.featureAdapter.getAttribute;for(const s of e.items){const e=a(s,t),i=a(s,r),o=n.get(e);(!o||i>a(o,r))&&n.set(e,s)}e.items=Array.from(n.values())}_canExecuteSinglePass(e,t){const{spatialRel:s}=t;return(0,K.hN)(e)&&("esriSpatialRelEnvelopeIntersects"===s||"esriGeometryPoint"===this.geometryType&&("esriSpatialRelIntersects"===s||"esriSpatialRelContains"===s))}async _project(e,t){if(!t||(0,g.fS)(this.spatialReference,t))return e;const s=this.featureAdapter;let i;try{const e=await this._getFullExtent();i=(0,h.getTransformation)(this.spatialReference,t,e)}catch{}const r=await(0,k.oj)(e.items.map((e=>(0,P.Op)(this.geometryType,this.hasZ,this.hasM,s.getGeometry(e)))),this.spatialReference,t,i);return e.items=r.map(((t,i)=>s.cloneWithGeometry(e.items[i],(0,_.GH)(t,this.hasZ,this.hasM)))),e}_getQueryBBoxes(e){if((0,K.hN)(e)){if((0,p.YX)(e))return[(0,m.al)(Math.min(e.xmin,e.xmax),Math.min(e.ymin,e.ymax),Math.max(e.xmin,e.xmax),Math.max(e.ymin,e.ymax))];if((0,p.oU)(e))return e.rings.map((e=>(0,m.al)(Math.min(e[0][0],e[2][0]),Math.min(e[0][1],e[2][1]),Math.max(e[0][0],e[2][0]),Math.max(e[0][1],e[2][1]))))}return[(0,f.$P)((0,m.Ue)(),e)]}async _searchFeatures(e){const t=new Set;await Promise.all(e.map((e=>this.featureStore.forEachInBounds(e,(e=>t.add(e))))));const s=Array.from(t.values());return t.clear(),s}async _executeQueryForStatistics(e,t,s){e=(0,a.d9)(e);try{e=await this._schedule((()=>(0,X.Up)(e,this.definitionExpression,this.spatialReference)),s),e=await this._reschedule((()=>async function(e,t,{fieldsIndex:s,geometryType:i,spatialReference:n,availableFields:a}){if((e.distance??0)<0||null!=e.geometryPrecision||e.multipatchOption||e.pixelSize||e.relationParam||e.text||e.outStatistics||e.groupByFieldsForStatistics||e.having||e.orderByFields)throw new r.Z(ee,"Unsupported query options",{query:e});return se(s,a,e),Promise.all([re(s,a,t,e),(0,K.P0)(e,i,n),(0,k._W)(n,e.outSR)]).then((()=>e))}(e,t,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference})),s);const i=await this._reschedule((()=>this._executeSceneFilterQuery(e,s)),s),n=await this._reschedule((()=>this._executeGeometryQuery(e,i,s)),s);return await this._reschedule((()=>this._executeAggregateIdsQuery(n)),s),await this._reschedule((()=>this._executeObjectIdsQuery(n)),s),await this._reschedule((()=>this._executeTimeQuery(n)),s),await this._reschedule((()=>this._executeAttributesQuery(n)),s),n}catch(t){if(t!==X.Ti)throw t;return new H([],e,this)}}}},61159:(e,t,s)=>{s.d(t,{g:()=>i});const i={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCacheHint:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0}},42712:(e,t,s)=>{s.d(t,{EG:()=>u,Op:()=>c,S2:()=>h});var i=s(98732),r=s(5428);const n=new r.Z,a=new r.Z,o=new r.Z,l={esriGeometryPoint:i.fQ,esriGeometryPolyline:i.J6,esriGeometryPolygon:i.eG,esriGeometryMultipoint:i.Iv};function u(e,t,s,r=e.hasZ,n=e.hasM){if(null==t)return null;const a=e.hasZ&&r,l=e.hasM&&n;if(s){const u=(0,i.Nh)(o,t,e.hasZ,e.hasM,"esriGeometryPoint",s,r,n);return(0,i.fQ)(u,a,l)}return(0,i.fQ)(t,a,l)}function c(e,t,s,r,u,c,h=t,d=s){const m=t&&h,f=s&&d,p=null!=r?"coords"in r?r:r.geometry:null;if(null==p)return null;if(u){let r=(0,i.zj)(a,p,t,s,e,u,h,d);return c&&(r=(0,i.Nh)(o,r,m,f,e,c)),l[e]?.(r,m,f)??null}if(c){const r=(0,i.Nh)(o,p,t,s,e,c,h,d);return l[e]?.(r,m,f)??null}return(0,i.hY)(n,p,t,s,h,d),l[e]?.(n,m,f)??null}function h(e){return e&&d in e?JSON.parse(JSON.stringify(e,m)):e}const d="_geVersion",m=(e,t)=>e!==d?t:void 0},37427:(e,t,s)=>{s.d(t,{_W:()=>m,iV:()=>y,oj:()=>_});var i=s(67676),r=s(95330),n=s(73615),a=s(37455),o=s(8744),l=s(40488);const u=[0,0];function c(e,t){if(!t)return null;if("x"in t){const s={x:0,y:0};return[s.x,s.y]=e(t.x,t.y,u),null!=t.z&&(s.z=t.z),null!=t.m&&(s.m=t.m),s}if("xmin"in t){const s={xmin:0,ymin:0,xmax:0,ymax:0};return[s.xmin,s.ymin]=e(t.xmin,t.ymin,u),[s.xmax,s.ymax]=e(t.xmax,t.ymax,u),t.hasZ&&(s.zmin=t.zmin,s.zmax=t.zmax,s.hasZ=!0),t.hasM&&(s.mmin=t.mmin,s.mmax=t.mmax,s.hasM=!0),s}return"rings"in t?{rings:h(t.rings,e),hasM:t.hasM,hasZ:t.hasZ}:"paths"in t?{paths:h(t.paths,e),hasM:t.hasM,hasZ:t.hasZ}:"points"in t?{points:d(t.points,e),hasM:t.hasM,hasZ:t.hasZ}:null}function h(e,t){const s=[];for(const i of e)s.push(d(i,t));return s}function d(e,t){const s=[];for(const i of e){const e=t(i[0],i[1],[0,0]);s.push(e),i.length>2&&e.push(i[2]),i.length>3&&e.push(i[3])}return s}async function m(e,t){if(!e||!t)return;const s=Array.isArray(e)?e.map((e=>null!=e.geometry?e.geometry.spatialReference:null)).filter(i.pC):[e];await(0,n.initializeProjection)(s.map((e=>({source:e,dest:t}))))}const f=c.bind(null,l.hG),p=c.bind(null,l.R6);function y(e,t,s,i){if(!e)return e;if(s||(s=t,t=e.spatialReference),!(0,o.JY)(t)||!(0,o.JY)(s)||(0,o.fS)(t,s))return e;if((0,l.Q8)(t,s)){const t=(0,o.sS)(s)?f(e):p(e);return t.spatialReference=s,t}return(0,n.projectMany)(a.N,[e],t,s,null,i)[0]}const g=new class{constructor(){this._jobs=[],this._timer=null,this._process=this._process.bind(this)}async push(e,t,s,i){if(!e?.length||!t||!s||(0,o.fS)(t,s))return e;const n={geometries:e,inSpatialReference:t,outSpatialReference:s,geographicTransformation:i,resolve:(0,r.hh)()};return this._jobs.push(n),this._timer??=setTimeout(this._process,10),n.resolve.promise}_process(){this._timer=null;const e=this._jobs.shift();if(!e)return;const{geometries:t,inSpatialReference:s,outSpatialReference:i,resolve:r,geographicTransformation:u}=e;(0,l.Q8)(s,i)?(0,o.sS)(i)?r(t.map(f)):r(t.map(p)):r((0,n.projectMany)(a.N,t,s,i,u,null)),this._jobs.length>0&&(this._timer=setTimeout(this._process,10))}};function _(e,t,s,i){return g.push(e,t,s,i)}},22222:(e,t,s)=>{s.d(t,{Ti:()=>d,Up:()=>m,j6:()=>f});var i=s(35454),r=s(67900),n=s(73615),a=s(49600),o=s(33955),l=s(16306),u=s(8744),c=s(37427);const h=new i.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"}),d=Object.freeze({});async function m(e,t,s){const{outFields:i,orderByFields:r,groupByFieldsForStatistics:n,outStatistics:a}=e;if(i)for(let e=0;e<i.length;e++)i[e]=i[e].trim();if(r)for(let e=0;e<r.length;e++)r[e]=r[e].trim();if(n)for(let e=0;e<n.length;e++)n[e]=n[e].trim();if(a)for(let e=0;e<a.length;e++)a[e].onStatisticField&&(a[e].onStatisticField=a[e].onStatisticField.trim());return e.geometry&&!e.outSR&&(e.outSR=e.geometry.spatialReference),f(e,t,s)}async function f(e,t,i){if(!e)return null;let{where:n}=e;if(e.where=n=n?.trim(),(!n||/^1 *= *1$/.test(n)||t&&t===n)&&(e.where=null),!e.geometry)return e;let m=await async function(e){const{distance:t,units:i}=e,n=e.geometry;if(null==t||"vertexAttributes"in n)return n;const a=n.spatialReference,o=i?h.fromJSON(i):(0,r.qE)(a),l=a&&((0,u.sT)(a)||(0,u.sS)(a))?n:await(0,c._W)(a,u.Zn).then((()=>(0,c.iV)(n,u.Zn)));return(await async function(){return(await Promise.all([s.e(5837),s.e(247)]).then(s.bind(s,30247))).geodesicBuffer}())(l.spatialReference,l,t,o)}(e);if(e.distance=0,e.units=null,"esriSpatialRelEnvelopeIntersects"===e.spatialRel){const{spatialReference:t}=e.geometry;m=(0,a.aO)(m),m.spatialReference=t}if(m){await(0,c._W)(m.spatialReference,i),m=function(e,t){const s=e.spatialReference;return p(e,t)&&(0,o.YX)(e)?{spatialReference:s,rings:[[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]]}:e}(m,i);const t=(await(0,l.aX)((0,o.im)(m)))[0];if(null==t)throw d;const s="quantizationParameters"in e&&e.quantizationParameters?.tolerance||"maxAllowableOffset"in e&&e.maxAllowableOffset||0,r=s&&p(m,i)?{densificationStep:8*s}:void 0,n=t.toJSON(),a=(0,c.iV)(n,n.spatialReference,i,r);if(!a)throw d;a.spatialReference=i,e.geometry=a}return e}function p(e,t){if(!e)return!1;const s=e.spatialReference;return((0,o.YX)(e)||(0,o.oU)(e)||(0,o.l9)(e))&&!(0,u.fS)(s,t)&&!(0,n.canProjectWithoutEngine)(s,t)}},10402:(e,t,s)=>{s.d(t,{hN:()=>x,P0:()=>S,cW:()=>T});var i=s(20102),r=s(54102),n=s(87416),a=s(33955),o=s(8744);function l(e,t){return e?t?4:3:t?3:2}function u(e,t,s,i,r,n){const a=l(r,n),{coords:o,lengths:u}=i;if(!u)return!1;for(let i=0,r=0;i<u.length;i++,r+=a)if(!c(e,t,s,o[r],o[r+1]))return!1;return!0}function c(e,t,s,i,r){if(!e)return!1;const n=l(t,s),{coords:a,lengths:o}=e;let u=!1,c=0;for(const e of o)u=h(u,a,n,c,e,i,r),c+=e*n;return u}function h(e,t,s,i,r,n,a){let o=e,l=i;for(let e=i,u=i+r*s;e<u;e+=s){l=e+s,l===u&&(l=i);const r=t[e],c=t[e+1],h=t[l],d=t[l+1];(c<a&&d>=a||d<a&&c>=a)&&r+(a-c)/(d-c)*(h-r)<n&&(o=!o)}return o}var d=s(98732),m=s(5428),f=s(42712),p=s(37427);const y="unsupported-query",g={esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"intersects",esriSpatialRelIndexIntersects:null,esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:null},_={spatialRelationship:{esriSpatialRelIntersects:!0,esriSpatialRelContains:!0,esriSpatialRelWithin:!0,esriSpatialRelCrosses:!0,esriSpatialRelDisjoint:!0,esriSpatialRelTouches:!0,esriSpatialRelOverlaps:!0,esriSpatialRelEnvelopeIntersects:!0,esriSpatialRelIndexIntersects:!1,esriSpatialRelRelation:!1},queryGeometry:{esriGeometryPoint:!0,esriGeometryMultipoint:!0,esriGeometryPolyline:!0,esriGeometryPolygon:!0,esriGeometryEnvelope:!0},layerGeometry:{esriGeometryPoint:!0,esriGeometryMultipoint:!0,esriGeometryPolyline:!0,esriGeometryPolygon:!0,esriGeometryEnvelope:!1}};function T(e,t,i,o,l){if((0,a.oU)(t)&&"esriGeometryPoint"===i&&("esriSpatialRelIntersects"===e||"esriSpatialRelContains"===e)){const e=(0,d.Uy)(new m.Z,t,!1,!1);return Promise.resolve((t=>function(e,t,s,i){return c(e,!1,!1,i.coords[0],i.coords[1])}(e,0,0,t)))}if((0,a.oU)(t)&&"esriGeometryMultipoint"===i){const s=(0,d.Uy)(new m.Z,t,!1,!1);if("esriSpatialRelContains"===e)return Promise.resolve((e=>u(s,!1,!1,e,o,l)))}if((0,a.YX)(t)&&"esriGeometryPoint"===i&&("esriSpatialRelIntersects"===e||"esriSpatialRelContains"===e))return Promise.resolve((e=>(0,r.aV)(t,(0,f.Op)(i,o,l,e))));if((0,a.YX)(t)&&"esriGeometryMultipoint"===i&&"esriSpatialRelContains"===e)return Promise.resolve((e=>(0,r.lQ)(t,(0,f.Op)(i,o,l,e))));if((0,a.YX)(t)&&"esriSpatialRelIntersects"===e){const e="mesh"===(h=i)?n.h_:(0,n.IY)(h);return Promise.resolve((s=>e(t,(0,f.Op)(i,o,l,s))))}var h;return Promise.all([s.e(5837),s.e(247)]).then(s.bind(s,30247)).then((s=>{const r=s[g[e]].bind(null,t.spatialReference,t);return e=>r((0,f.Op)(i,o,l,e))}))}async function S(e,t,s){const{spatialRel:r,geometry:n}=e;if(n){if(!function(e){return null!=e&&!0===_.spatialRelationship[e]}(r))throw new i.Z(y,"Unsupported query spatial relationship",{query:e});if((0,o.JY)(n.spatialReference)&&(0,o.JY)(s)){if(!function(e){return null!=e&&!0===_.queryGeometry[(0,a.Ji)(e)]}(n))throw new i.Z(y,"Unsupported query geometry type",{query:e});if(!function(e){return null!=e&&!0===_.layerGeometry[e]}(t))throw new i.Z(y,"Unsupported layer geometry type",{query:e});if(e.outSR)return(0,p._W)(e.geometry?.spatialReference,e.outSR)}}}function x(e){if((0,a.YX)(e))return!0;if((0,a.oU)(e)){for(const t of e.rings){if(5!==t.length)return!1;if(t[0][0]!==t[1][0]||t[0][0]!==t[4][0]||t[2][0]!==t[3][0]||t[0][1]!==t[3][1]||t[0][1]!==t[4][1]||t[1][1]!==t[2][1])return!1}return!0}return!1}},17590:(e,t,s)=>{async function i(e,t){if(!e)return null;const s=t.featureAdapter,{startTimeField:i,endTimeField:r}=e;let n=Number.POSITIVE_INFINITY,a=Number.NEGATIVE_INFINITY;if(i&&r)await t.forEach((e=>{const t=s.getAttribute(e,i),o=s.getAttribute(e,r);null==t||isNaN(t)||(n=Math.min(n,t)),null==o||isNaN(o)||(a=Math.max(a,o))}));else{const e=i||r;await t.forEach((t=>{const i=s.getAttribute(t,e);null==i||isNaN(i)||(n=Math.min(n,i),a=Math.max(a,i))}))}return{start:n,end:a}}function r(e,t,s){if(!t||!e)return null;const{startTimeField:i,endTimeField:r}=e;if(!i&&!r)return null;const{start:n,end:a}=t;if(null===n&&null===a)return null;if(void 0===n&&void 0===a)return()=>!1;const o=s.getAttributeAsTimestamp?.bind(s)??s.getAttribute.bind(s);return i&&r?function(e,t,s,i,r){return null!=i&&null!=r?n=>{const a=e(n,t),o=e(n,s);return(null==a||a<=r)&&(null==o||o>=i)}:null!=i?t=>{const r=e(t,s);return null==r||r>=i}:null!=r?s=>{const i=e(s,t);return null==i||i<=r}:void 0}(o,i,r,n,a):function(e,t,s,i){return null!=s&&null!=i&&s===i?i=>e(i,t)===s:null!=s&&null!=i?r=>{const n=e(r,t);return null!=n&&n>=s&&n<=i}:null!=s?i=>{const r=e(i,t);return null!=r&&r>=s}:null!=i?s=>{const r=e(s,t);return null!=r&&r<=i}:void 0}(o,i||r,n,a)}s.d(t,{R:()=>i,y:()=>r})},98732:(e,t,s)=>{s.d(t,{$:()=>se,$g:()=>ie,EI:()=>Q,GH:()=>Y,IN:()=>x,Iv:()=>O,J6:()=>k,Jd:()=>S,Nh:()=>X,RZ:()=>W,Uy:()=>U,XA:()=>V,Yn:()=>z,cn:()=>H,dd:()=>C,di:()=>j,eG:()=>L,fQ:()=>F,hY:()=>re,h_:()=>$,lM:()=>J,lz:()=>ae,zj:()=>K});var i=s(20102),r=s(92604),n=s(70586),a=s(60437),o=s(24470),l=s(33955),u=s(70272),c=s(44876),h=s(5428);function d(e,t){return e?t?4:3:t?3:2}const m=r.Z.getLogger("esri.layers.graphics.featureConversionUtils"),f={esriGeometryPoint:0,esriGeometryPolyline:2,esriGeometryPolygon:3,esriGeometryMultipoint:0,esriGeometryEnvelope:0},p=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n},y=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n,e[s+2]=t[i+2]},g=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n,e[s+2]=t[i+3]},_=(e,t,s,i,r,n)=>{e[s]=r,e[s+1]=n,e[s+2]=t[i+2],e[s+3]=t[i+3]};function T(e,t,s,i){if(e){if(s)return t&&i?_:y;if(t&&i)return g}else if(t&&i)return y;return p}function S({scale:e,translate:t},s){return Math.round((s-t[0])/e[0])}function x({scale:e,translate:t},s){return Math.round((t[1]-s)/e[1])}function I({scale:e,translate:t},s,i){return s*e[i]+t[i]}function F(e,t,s){return e?t?s?v(e):E(e):s?N(e):w(e):null}function w(e){const t=e.coords;return{x:t[0],y:t[1]}}function R(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e}function E(e){const t=e.coords;return{x:t[0],y:t[1],z:t[2]}}function b(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.z,e}function N(e){const t=e.coords;return{x:t[0],y:t[1],m:t[2]}}function A(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.m,e}function v(e){const t=e.coords;return{x:t[0],y:t[1],z:t[2],m:t[3]}}function D(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.z,e.coords[3]=t.m,e}function M(e,t){return e&&t?D:e?b:t?A:R}function C(e,t,s=M(null!=t.z,null!=t.m)){return s(e,t)}function O(e,t,s){if(null==e)return null;const i=d(t,s),r=[];for(let t=0;t<e.coords.length;t+=i){const s=[];for(let r=0;r<i;r++)s.push(e.coords[t+r]);r.push(s)}return t?s?{points:r,hasZ:t,hasM:s}:{points:r,hasZ:t}:s?{points:r,hasM:s}:{points:r}}function P(e,t,s=d(t.hasZ,t.hasM)){e.lengths[0]=t.points.length;const i=e.coords;let r=0;for(const e of t.points)for(let t=0;t<s;t++)i[r++]=e[t];return e}function k(e,t,s){if(!e)return null;const i=d(t,s),{coords:r,lengths:n}=e,a=[];let o=0;for(const e of n){const t=[];for(let s=0;s<e;s++){const e=[];for(let t=0;t<i;t++)e.push(r[o++]);t.push(e)}a.push(t)}return t?s?{paths:a,hasZ:t,hasM:s}:{paths:a,hasZ:t}:s?{paths:a,hasM:s}:{paths:a}}function Z(e,t,s=d(t.hasZ,t.hasM)){const{lengths:i,coords:r}=e;let n=0;for(const e of t.paths){for(const t of e)for(let e=0;e<s;e++)r[n++]=t[e];i.push(e.length)}return e}function L(e,t,s){if(!e)return null;const i=d(t,s),{coords:r,lengths:n}=e,a=[];let o=0;for(const e of n){const t=[];for(let s=0;s<e;s++){const e=[];for(let t=0;t<i;t++)e.push(r[o++]);t.push(e)}a.push(t)}return t?s?{rings:a,hasZ:t,hasM:s}:{rings:a,hasZ:t}:s?{rings:a,hasM:s}:{rings:a}}function U(e,t,s=t.hasZ,i=t.hasM){return function(e,t,s,i){const r=d(s,i),{lengths:n,coords:a}=e;let o=0;oe(e);for(const e of t){for(const t of e)for(let e=0;e<r;e++)a[o++]=t[e];n.push(e.length)}return e}(e,t.rings,s,i)}const G=[],q=[];function V(e,t,s,i,r){G[0]=e;const[n]=z(q,G,t,s,i,r);return le(G),le(q),n}function z(e,t,s,r,n,a){if(le(e),!s){for(const s of t){const t=a?s.attributes[a]:void 0;e.push(new u.u_(null,s.attributes,null,t))}return e}switch(s){case"esriGeometryPoint":return function(e,t,s,i,r){const n=M(s,i);for(const{geometry:s,attributes:i}of t){const t=null!=s?n(new h.Z,s):null;e.push(new u.u_(t,i,null,r?i[r]:void 0))}return e}(e,t,r,n,a);case"esriGeometryMultipoint":return function(e,t,s,i,r){const n=d(s,i);for(const{geometry:s,attributes:i}of t){const t=null!=s?P(new h.Z,s,n):null;e.push(new u.u_(t,i,null,r?i[r]:void 0))}return e}(e,t,r,n,a);case"esriGeometryPolyline":return function(e,t,s,i,r){const n=d(s,i);for(const{geometry:s,attributes:i}of t){const t=null!=s?Z(new h.Z,s,n):null;e.push(new u.u_(t,i,null,r?i[r]:void 0))}return e}(e,t,r,n,a);case"esriGeometryPolygon":return function(e,t,s,i,r){for(const{geometry:n,centroid:a,attributes:o}of t){const t=null!=n?U(new h.Z,n,s,i):null,l=r?o[r]:void 0;null!=a?e.push(new u.u_(t,o,R(new h.Z,a),l)):e.push(new u.u_(t,o,null,l))}return e}(e,t,r,n,a);default:m.error("convertToFeatureSet:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${s}'`)),le(e)}return e}function Q(e,t,s,i){q[0]=e,B(G,q,t,s,i);const r=G[0];return le(G),le(q),r}function Y(e,t,s){if(null==e)return null;const r=new h.Z;return"hasZ"in e&&null==t&&(t=e.hasZ),"hasM"in e&&null==s&&(s=e.hasM),(0,l.wp)(e)?M(null!=t?t:null!=e.z,null!=s?s:null!=e.m)(r,e):(0,l.oU)(e)?U(r,e,t,s):(0,l.l9)(e)?Z(r,e,d(t,s)):(0,l.aW)(e)?P(r,e,d(t,s)):void m.error("convertFromGeometry:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${e}'`))}function j(e,t,s,r){const n=e&&("coords"in e?e:e.geometry);if(null==n)return null;switch(t){case"esriGeometryPoint":{let e=w;return s&&r?e=v:s?e=E:r&&(e=N),e(n)}case"esriGeometryMultipoint":return O(n,s,r);case"esriGeometryPolyline":return k(n,s,r);case"esriGeometryPolygon":return L(n,s,r);default:return m.error("convertToGeometry:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${t}'`)),null}}function B(e,t,s,r,n){if(le(e),null==s)return function(e,t){for(const s of t)e.push({attributes:s.attributes});return e}(e,t);switch(s){case"esriGeometryPoint":return function(e,t,s,i){let r=w;s&&i?r=v:s?r=E:i&&(r=N);for(const s of t){const{geometry:t,attributes:i}=s,n=null!=t?r(t):null;e.push({attributes:i,geometry:n})}return e}(e,t,r,n);case"esriGeometryMultipoint":return function(e,t,s,i){for(const{geometry:r,attributes:n}of t)e.push({attributes:n,geometry:null!=r?O(r,s,i):null});return e}(e,t,r,n);case"esriGeometryPolyline":return function(e,t,s,i){for(const{geometry:r,attributes:n}of t)e.push({attributes:n,geometry:null!=r?k(r,s,i):null});return e}(e,t,r,n);case"esriGeometryPolygon":return function(e,t,s,i){for(const{geometry:r,attributes:n,centroid:a}of t){const t=null!=r?L(r,s,i):null;if(null!=a){const s=w(a);e.push({attributes:n,centroid:s,geometry:t})}else e.push({attributes:n,geometry:t})}return e}(e,t,r,n);default:m.error("convertToFeatureSet:unknown-geometry",new i.Z(`Unable to parse unknown geometry type '${s}'`))}return e}function H(e){const{objectIdFieldName:t,spatialReference:s,transform:i,fields:r,hasM:n,hasZ:a,features:o,geometryType:l,exceededTransferLimit:u,uniqueIdField:c,queryGeometry:h,queryGeometryType:d}=e,m={features:B([],o,l,a,n),fields:r,geometryType:l,objectIdFieldName:t,spatialReference:s,uniqueIdField:c,queryGeometry:j(h,d,!1,!1)};return i&&(m.transform=i),u&&(m.exceededTransferLimit=u),n&&(m.hasM=n),a&&(m.hasZ=a),m}function $(e,t){const s=new c.Z,{hasM:r,hasZ:n,features:a,objectIdFieldName:o,spatialReference:l,geometryType:u,exceededTransferLimit:h,transform:d,fields:f}=e;return f&&(s.fields=f),s.geometryType=u??null,s.objectIdFieldName=o??t??null,s.spatialReference=l??null,s.objectIdFieldName?(a&&z(s.features,a,u,n,r,s.objectIdFieldName),h&&(s.exceededTransferLimit=h),r&&(s.hasM=r),n&&(s.hasZ=n),d&&(s.transform=d),s):(m.error(new i.Z("optimized-features:invalid-objectIdFieldName","objectIdFieldName is missing")),s)}function J(e){const{transform:t,features:s,hasM:i,hasZ:r}=e;if(!t)return e;for(const e of s)null!=e.geometry&&ie(e.geometry,e.geometry,i,r,t),null!=e.centroid&&ie(e.centroid,e.centroid,i,r,t);return e.transform=null,e}function W(e,t){const{geometryType:s,features:i,hasM:r,hasZ:n}=t;if(!e)return t;for(let t=0;t<i.length;t++){const a=i[t],o=a.weakClone();o.geometry=new h.Z,X(o.geometry,a.geometry,r,n,s,e),a.centroid&&(o.centroid=new h.Z,X(o.centroid,a.centroid,r,n,"esriGeometryPoint",e)),i[t]=o}return t.transform=e,t}function X(e,t,s,i,r,n,a=s,o=i){if(oe(e),!t?.coords.length)return null;const l=f[r],{coords:u,lengths:c}=t,h=d(s,i),m=d(s&&a,i&&o),p=T(s,i,a,o);if(!c.length)return p(e.coords,u,0,0,S(n,u[0]),x(n,u[1])),oe(e,h,0),e;let y,g,_,I,F=0,w=0,R=w;for(const t of c){if(t<l)continue;let s=0;w=R,_=y=S(n,u[F]),I=g=x(n,u[F+1]),p(e.coords,u,w,F,_,I),s++,F+=h,w+=m;for(let i=1;i<t;i++,F+=h)_=S(n,u[F]),I=x(n,u[F+1]),_===y&&I===g||(p(e.coords,u,w,F,_-y,I-g),w+=m,s++,y=_,g=I);s>=l&&(e.lengths.push(s),R=w)}return le(e.coords,R),e.coords.length?e:null}function K(e,t,s,i,r,n,a=s,o=i){if(oe(e),!t?.coords.length)return null;const l=f[r],{coords:u,lengths:c}=t,h=d(s,i),m=d(s&&a,i&&o),p=T(s,i,a,o);if(!c.length)return p(e.coords,u,0,0,u[0],u[1]),oe(e,h,0),e;let y=0;const g=n*n;for(const t of c){if(t<l){y+=t*h;continue}const s=e.coords.length/m,i=y,r=y+(t-1)*h;p(e.coords,u,e.coords.length,i,u[i],u[i+1]),te(e.coords,u,h,g,p,i,r),p(e.coords,u,e.coords.length,r,u[r],u[r+1]);const n=e.coords.length/m-s;n>=l?e.lengths.push(n):le(e.coords,s*m),y+=t*h}return e.coords.length?e:null}function ee(e,t,s,i){const r=e[t],n=e[t+1],a=e[s],o=e[s+1],l=e[i],u=e[i+1];let c=a,h=o,d=l-c,m=u-h;if(0!==d||0!==m){const e=((r-c)*d+(n-h)*m)/(d*d+m*m);e>1?(c=l,h=u):e>0&&(c+=d*e,h+=m*e)}return d=r-c,m=n-h,d*d+m*m}function te(e,t,s,i,r,n,a){let o,l=i,u=0;for(let e=n+s;e<a;e+=s)o=ee(t,e,n,a),o>l&&(u=e,l=o);l>i&&(u-n>s&&te(e,t,s,i,r,n,u),r(e,t,e.length,u,t[u],t[u+1]),a-u>s&&te(e,t,s,i,r,u,a))}function se(e,t,s,i){if(!t?.coords?.length)return null;const r=d(s,i);let n=Number.POSITIVE_INFINITY,l=Number.POSITIVE_INFINITY,u=Number.NEGATIVE_INFINITY,c=Number.NEGATIVE_INFINITY;if(t&&t.coords){const e=t.coords;for(let t=0;t<e.length;t+=r){const s=e[t],i=e[t+1];n=Math.min(n,s),u=Math.max(u,s),l=Math.min(l,i),c=Math.max(c,i)}}return(0,a.is)(e)?(0,a.bZ)(e,n,l,u,c):(0,o.al)(n,l,u,c,e),e}function ie(e,t,s,i,r){const{coords:a,lengths:o}=t,l=d(s,i);if(!a.length)return e!==t&&oe(e),e;(0,n.O3)(r);const{originPosition:u,scale:c,translate:h}=r,m=ue;m.originPosition=u;const f=m.scale;f[0]=c[0]??1,f[1]=-(c[1]??1),f[2]=c[2]??1,f[3]=c[3]??1;const p=m.translate;if(p[0]=h[0]??0,p[1]=h[1]??0,p[2]=h[2]??0,p[3]=h[3]??0,!o.length){for(let t=0;t<l;++t)e.coords[t]=I(m,a[t],t);return e!==t&&oe(e,l,0),e}let y=0;for(let t=0;t<o.length;t++){const s=o[t];e.lengths[t]=s;for(let t=0;t<l;++t)e.coords[y+t]=I(m,a[y+t],t);let i=e.coords[y],r=e.coords[y+1];y+=l;for(let t=1;t<s;t++,y+=l){i+=a[y]*f[0],r+=a[y+1]*f[1],e.coords[y]=i,e.coords[y+1]=r;for(let t=2;t<l;++t)e.coords[y+t]=I(m,a[y+t],t)}}return e!==t&&oe(e,a.length,o.length),e}function re(e,t,s,i,r,n){if(oe(e),e.lengths.push(...t.lengths),s===r&&i===n)for(let s=0;s<t.coords.length;s++)e.coords.push(t.coords[s]);else{const a=d(s,i),o=T(s,i,r,n),l=t.coords;for(let t=0;t<l.length;t+=a)o(e.coords,l,e.coords.length,t,l[t],l[t+1])}return e}function ne(e,t,s,i){let r=0,n=e[i*t],a=e[i*(t+1)];for(let o=1;o<s;o++){const s=n+e[i*(t+o)],l=a+e[i*(t+o)+1],u=(s-n)*(l+a);n=s,a=l,r+=u}return.5*r}function ae(e,t){const{coords:s,lengths:i}=e;let r=0,n=0;for(let e=0;e<i.length;e++){const a=i[e];n+=ne(s,r,a,t),r+=a}return Math.abs(n)}function oe(e,t=0,s=0){le(e.lengths,s),le(e.coords,t)}function le(e,t=0){e.length!==t&&(e.length=t)}const ue={originPosition:"lowerLeft",scale:[1,1,1,1],translate:[0,0,0,0]}},99514:(e,t,s)=>{s.d(t,{Z:()=>l});var i=s(20102),r=s(96674),n=s(92604),a=s(69165),o=s(25031);class l{static fromJSON(e){return new l(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new l(e.fields??[],d(e))}static fromLayerJSON(e){return new l(e.fields??[],d(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 s=[];for(const e of this.fields){const t=e?.name,i=c(t);if(t&&i){const r=u(t);this._fieldsMap.set(t,e),this._fieldsMap.set(r,e),this._normalizedFieldsMap.set(i,e),s.push(`${r}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,a.y2)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,a.H7)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,a.Dl)(e)||(0,a.Se)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}s.sort(),this.uid=s.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,a.Dl)(e)||(0,a.Se)(e)||e.nullable||void 0!==(0,a.os)(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(u(e))??this._normalizedFieldsMap.get(c(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?(n.Z.getLogger("esri.layers.support.FieldsIndex").error(new i.Z("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),o.pt):h.has(t.type)?o._4:null:null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,a.sX)(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,r.AK)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function u(e){return e.trim().toLowerCase()}function c(e){return(0,a.q6)(e)?.toLowerCase()??""}const h=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function d(e){const t=new Map;if(!e.fields)return t;const s=!0===e.datesInUnknownTimezone,{timeInfo:i,editFieldsInfo:r}=e,n=(i?"startField"in i?i.startField:i.startTimeField:"")??"",a=(i?"endField"in i?i.endField:i.endTimeField:"")??"",l=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,o.Jv)(e.dateFieldsTimeReference):null,c=r?function(e){return"timeZone"in e}(r)?r.timeZone??l:r.dateFieldsTimeReference?(0,o.Jv)(r.dateFieldsTimeReference):l??o.pt:null,d=i?function(e){return"timeZone"in e}(i)?i.timeZone??l:i.timeReference?(0,o.Jv)(i.timeReference):l:null,m=new Map([[u(r?.creationDateField??""),c],[u(r?.editDateField??""),c],[u(n),d],[u(a),d]]);for(const{name:i,type:r}of e.fields)if(h.has(r))t.set(i,o._4);else if("date"!==r&&"esriFieldTypeDate"!==r)t.set(i,null);else if(s)t.set(i,o._4);else{const e=m.get(u(i??""))??l;t.set(i,e)}return t}},86719:(e,t,s)=>{s.d(t,{v:()=>i});const i=new(s(35454).X)({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"})},95720:(e,t,s)=>{var i;s.d(t,{n:()=>i}),function(e){e[e.ANIMATING=0]="ANIMATING",e[e.INTERACTING=1]="INTERACTING",e[e.IDLE=2]="IDLE"}(i||(i={}))}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5245,5732,5935],{84552:(e,t,r)=>{r.d(t,{Z:()=>p});var i=r(43697),s=r(2368),n=r(96674),o=r(35463),a=r(5600),l=(r(75215),r(67676),r(80442),r(36030)),u=r(52011),d=r(78981);let c=class extends((0,s.J)(n.wq)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.rJ)(this.value,this.unit,"milliseconds")}};(0,i._)([(0,l.J)(d.v,{nonNullable:!0})],c.prototype,"unit",void 0),(0,i._)([(0,a.Cb)({type:Number,json:{write:!0},nonNullable:!0})],c.prototype,"value",void 0),c=(0,i._)([(0,u.j)("esri.TimeInterval")],c);const p=c},5732:(e,t,r)=>{r.d(t,{c:()=>i,g:()=>s});var i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function s(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}},64830:(e,t,r)=>{r.d(t,{Z:()=>n});var i=r(58971),s=r(10661);class n{constructor(e=(e=>e.values().next().value)){this._peeker=e,this._observable=new s.s,this._items=new Set}get length(){return(0,i.it)(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,i.it)(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,i.it)(this._observable),yield*this._items}}},22862:(e,t,r)=>{r.d(t,{Hg:()=>f,V7:()=>h,uD:()=>p});var i=r(92036),s=r(46791),n=r(1153);const o=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function a(e){return e instanceof i.Z}function l(e){return e instanceof s.Z?Object.keys(e.items):a(e)?(0,n.vw)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof s.Z?e.items[t]:e[t]}function d(e){return e?e.declaredClass:null}function c(e,t){const r=e.diff;if(r&&"function"==typeof r)return r(e,t);const i=l(e),s=l(t);if(0===i.length&&0===s.length)return;if(!i.length||!s.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const n=s.filter((e=>!i.includes(e))),p=i.filter((e=>!s.includes(e))),h=i.filter((r=>s.includes(r)&&u(e,r)!==u(t,r))).concat(n,p).sort(),f=d(e);if(f&&o.has(f)&&h.length)return{type:"complete",oldValue:e,newValue:t};let y;const m=a(e)&&a(t);for(const i of h){const s=u(e,i),n=u(t,i);let o;if((m||"function"!=typeof s&&"function"!=typeof n)&&s!==n&&(null!=s||null!=n)){if(r&&r[i]&&"function"==typeof r[i])o=r[i]?.(s,n);else if(s instanceof Date&&n instanceof Date){if(s.getTime()===n.getTime())continue;o={type:"complete",oldValue:s,newValue:n}}else o="object"==typeof s&&"object"==typeof n&&d(s)===d(n)?c(s,n):{type:"complete",oldValue:s,newValue:n};null!=o&&(null!=y?y.diff[i]=o:y={type:"partial",diff:{[i]:o}})}}return y}function p(e,t){if(null==e)return!1;const r=t.split(".");let i=e;for(const e of r){if("complete"===i.type)return!0;if("partial"!==i.type)return!1;{const t=i.diff[e];if(!t)return!1;i=t}}return!0}function h(e,t){for(const r of t)if(p(e,r))return!0;return!1}function f(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&d(e)!==d(t)?{type:"complete",oldValue:e,newValue:t}:c(e,t)}},20188:(e,t,r)=>{function i(e){return null!=o(e)||null!=n(e)}function s(e){return o(e)??n(e)}function n(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let r=!0;if(u&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,i=0;for(;!t&&i<=e.length;)t=!l.test(e[i]),i++;r=!t}}return r}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function o(e){const t=a.exec(e);if(!t?.groups)return null;const r=t.groups,i=+r.year,s=+r.month-1,n=+r.day,o=+(r.hours??"0"),l=+(r.minutes??"0"),u=+(r.seconds??"0");if(o>23)return null;if(l>59)return null;if(u>59)return null;const d=r.ms??"0",c=d?+d.padEnd(3,"0").substring(0,3):0;let p;if(r.isUTC||!r.offsetSign)p=Date.UTC(i,s,n,o,l,u,c);else{const e=+r.offsetHours,t=+r.offsetMinutes;p=6e4*("+"===r.offsetSign?-1:1)*(60*e+t)+Date.UTC(i,s,n,o,l,u,c)}return Number.isNaN(p)?null:p}r.d(t,{o:()=>i,s:()=>s});const a=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,l=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,u=!Number.isNaN(new Date("technology 10").getTime())},80903:(e,t,r)=>{r.d(t,{Z:()=>u});var i=r(50758),s=r(92604),n=r(95330),o=r(64830),a=r(18948),l=r(728);class u{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new o.Z}destroy(){this.close()}get closed(){return!this._clients?.length}open(e,t){return new Promise(((r,i)=>{let s=!0;const o=e=>{(0,n.k_)(t.signal),s&&(s=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let s=0;s<e.length;++s){const a=e[s];(0,n.y8)(a)?this._clientPromises[s]=a.then((e=>(this._clients[s]=new l.default(e,t,this._ongoingJobsQueue),o(r),this._clients[s])),(()=>(o(i),null))):(this._clients[s]=new l.default(a,t,this._ongoingJobsQueue),this._clientPromises[s]=Promise.resolve(this._clients[s]),o(r))}}))}broadcast(e,t,r){const i=new Array(this._clientPromises.length);for(let s=0;s<this._clientPromises.length;++s){const n=this._clientPromises[s];i[s]=n.then((i=>i?.invoke(e,t,r)))}return i}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.resolver.reject((0,n.zE)(`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,a.E)(this)}invoke(e,t,r){let i;Array.isArray(r)?(s.Z.getLogger("esri.core.workers.Connection").warn("invoke()","The transferList parameter is deprecated, use the options object instead"),i={transferList:r}):i=r;const o=(0,n.hh)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:i,resolver:o});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 o.promise}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,i.AL)(this._clients.map((r=>r.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let r=t.length;for(let i=0;i<this._clientPromises.length;++i)this._clientPromises[i].then((s=>{s&&(t[i]=s.openPort()),0==--r&&e(t)}))}))}get test(){return{numClients:this._clients.length}}}},18948:(e,t,r)=>{r.d(t,{E:()=>n,z:()=>s});const i=new FinalizationRegistry((e=>{e.close()}));function s(e,t){i.register(e,t,t)}function n(e){i.unregister(e)}},56569:(e,t,r)=>{r.d(t,{bA:()=>J});var i=r(20102),s=r(80442),n=r(95330),o=r(80903),a=r(18948),l=r(728),u=r(92604),d=r(70586),c=r(3172),p=r(17452);const h={async request(e,t){const r=e.options,i=r.responseType;r.signal=t?.signal,r.responseType="native"===i||"native-request-init"===i?"native-request-init":i&&["blob","json","text"].includes(i)&&(0,p.oh)(e.url)?.after?i:"array-buffer";const s=await(0,c.Z)(e.url,r),n={data:s.data,httpStatus:s.httpStatus,ssl:s.ssl};switch(s.requestOptions?.responseType){case"native-request-init":return delete n.data.signal,n;case"blob":n.data=await n.data.arrayBuffer();break;case"json":n.data=(new TextEncoder).encode(JSON.stringify(n.data)).buffer;break;case"text":n.data=(new TextEncoder).encode(n.data).buffer}return{result:n,transferList:[n.data]}}};var f=r(94362),y=r(99880),m=r(68773),g=(r(2587),r(40330));const b={};var w=r(41213);class v{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...r)=>e[t](...r)}))}}class _{constructor(){this._dispatcher=new v,this._workerPostMessage({type:f.MessageType.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.Y)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,r){this._dispatcher.addEventListener(e,t,r)}removeEventListener(e,t,r){this._dispatcher.removeEventListener(e,t,r)}_workerPostMessage(e){(0,w.Y)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,f.QM)(e);if(t&&t.type===f.MessageType.OPEN){const{modulePath:e,jobId:r}=t;let i=await l.default.loadWorker(e);i||(i=await import(e));const s=l.default.connect(i);this._workerPostMessage({type:f.MessageType.OPENED,jobId:r,data:s})}}}var F=r(70171),S=r(17202);const C=u.Z.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:I}=f.MessageType;let x,T;const j="Failed to create Worker. Fallback to execute module in main thread";async function O(e){return new Promise((t=>{function r(s){const n=(0,f.QM)(s);n&&n.type===I&&(e.removeEventListener("message",r),e.removeEventListener("error",i),t(e))}function i(t){t.preventDefault(),e.removeEventListener("message",r),e.removeEventListener("error",i),C.warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new _).addEventListener("message",r),e.addEventListener("error",i)}e.addEventListener("message",r),e.addEventListener("error",i)}))}let E=0;const{ABORT:R,INVOKE:P,OPEN:N,OPENED:Z,RESPONSE:k}=f.MessageType;class M{static async create(e){const t=await async function(){if(!(0,s.Z)("esri-workers"))return O(new _);if(!x&&!T)try{const e='let globalId=0;const outgoing=new Map,configuration=JSON.parse("{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++;return new Promise(((r,s)=>{if(t){if(t.aborted)return s(createAbortError());t.addEventListener("abort",(()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:ABORT,jobId:n}),s(createAbortError()))}))}outgoing.set(n,{resolve:r,reject:s}),self.postMessage({type:INVOKE,jobId:n,methodName:e,abortable:null!=t,data:o})}))}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 OPEN:let n;function t(e){const o=n.connect(e);self.postMessage({type:OPENED,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 RESPONSE: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.default.default){const t={...m.default};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(m.default));e.assetsPath=(0,p.hF)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,p.hF)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,F.Kd)(),e.has={"esri-csp-restrictions":(0,s.Z)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,s.Z)("esri-2d-update-debug"),"esri-2d-log-updating":(0,s.Z)("esri-2d-log-updating"),"featurelayer-pbf":(0,s.Z)("featurelayer-pbf"),"featurelayer-simplify-thresholds":(0,s.Z)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,s.Z)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,s.Z)("featurelayer-simplify-mobile-factor"),"esri-atomics":(0,s.Z)("esri-atomics"),"esri-shared-array-buffer":(0,s.Z)("esri-shared-array-buffer"),"esri-tiles-debug":(0,s.Z)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,s.Z)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,s.Z)("feature-polyline-generalization-factor"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,p.hF)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,p.hF)(e.workers.workerPath):e.workers.workerPath=(0,p.hF)((0,y.V)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=m.default.workers.loaderConfig,r=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:{...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=b.baseUrl),t}({baseUrl:t?.baseUrl,locale:(0,F.Kd)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),i={buildDate:S.r,fullVersion:g.bR,revision:S.$};return JSON.stringify({esriConfig:e,loaderConfig:r,kernelInfo:i})}()}'`);x=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){T=e||{}}let e;if(x)try{e=new Worker(x,{name:"esri-worker-"+E++})}catch(t){C.warn(j,T),e=new _}else C.warn(j,T),e=new _;return O(e)}();return new M(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.Z.getLogger("esri.core.workers.WorkerOwner").error(e)}))}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:r}=t,i=(0,f.jt)();return new Promise(((t,s)=>{const o={resolve:t,reject:s,abortHandle:(0,n.$F)(r,(()=>{this._outJobs.delete(i),this._post({type:R,jobId:i})}))};this._outJobs.set(i,o),this._post({type:N,jobId:i,modulePath:e})}))}_onMessage(e){const t=(0,f.QM)(e);if(t)switch(t.type){case Z:this._onOpenedMessage(t);break;case k:this._onResponseMessage(t);break;case R:this._onAbortMessage(t);break;case P:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,i=t.get(r);i&&(i.controller&&i.controller.abort(),t.delete(r))}_onInvokeMessage(e){const{methodName:t,jobId:r,data:i,abortable:s}=e,o=s?new AbortController:null,a=this._inJobs,l=h[t];let u;try{if("function"!=typeof l)throw new TypeError(`${t} is not a function`);u=l.call(null,i,{signal:o?o.signal:null})}catch(e){return void this._post({type:k,jobId:r,error:(0,f.AB)(e)})}(0,n.y8)(u)?(a.set(r,{controller:o,promise:u}),u.then((e=>{a.has(r)&&(a.delete(r),this._post({type:k,jobId:r},e))}),(e=>{a.has(r)&&(a.delete(r),e||(e={message:"Error encountered at method"+t}),(0,n.D_)(e)||this._post({type:k,jobId:r,error:(0,f.AB)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:k,jobId:r},u)}_onOpenedMessage(e){const{jobId:t,data:r}=e,i=this._outJobs.get(t);i&&(this._outJobs.delete(t),(0,d.hw)(i.abortHandle),i.resolve(r))}_onResponseMessage(e){const{jobId:t,error:r,data:s}=e,n=this._outJobs.get(t);n&&(this._outJobs.delete(t),(0,d.hw)(n.abortHandle),r?n.reject(i.Z.fromJSON(JSON.parse(r))):n.resolve(s))}_post(e,t,r){return(0,f.oi)(this.worker,e,t,r)}}const A=(0,s.Z)("host-browser")?Math.min(navigator.hardwareConcurrency-1,(0,s.Z)("workers-pool-size")):0;let q=(0,s.Z)("esri-mobile")?Math.min(A,3):A;q||(q=(0,s.Z)("safari")&&(0,s.Z)("mac")?7:2);let D=0;const L=[];async function U(e,t){const r=new o.Z,{registryTarget:i,...s}=t;return await r.open(e,s),i&&(0,a.z)(i,r),r}async function J(e,t={}){if("string"!=typeof e)throw new i.Z("workers:undefined-module","modulePath is missing");let r=t.strategy||"distributed";if((0,s.Z)("host-webworker")&&!(0,s.Z)("esri-workers")&&(r="local"),"local"===r){let r=await l.default.loadWorker(e);r||(r=await import(e)),(0,n.k_)(t.signal);const i=t.client||r;return U([l.default.connect(r)],{...t,client:i})}if(await async function(){if(z)return z;G=new AbortController;const e=[];for(let t=0;t<q;t++){const r=M.create(t).then((e=>(L[t]=e,e)));e.push(r)}return z=Promise.all(e),z}(),(0,n.k_)(t.signal),"dedicated"===r){const r=D++%q;return U([await L[r].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const r=Math.min(t.maxNumWorkers,q);if(r<q){const i=new Array(r);for(let s=0;s<r;++s){const r=D++%q;i[s]=L[r].open(e,t)}return U(i,t)}}return U(L.map((r=>r.open(e,t))),t)}let G,z=null},60437:(e,t,r)=>{r.d(t,{G_:()=>b,HH:()=>o,JR:()=>f,TC:()=>a,Tn:()=>c,Ue:()=>s,al:()=>n,bZ:()=>y,cS:()=>h,dp:()=>u,fS:()=>g,is:()=>m,op:()=>d,pp:()=>l,t8:()=>p});var i=r(6570);function s(e=w){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function n(e,t,r,i,n,o,a=s()){return a[0]=e,a[1]=t,a[2]=r,a[3]=i,a[4]=n,a[5]=o,a}function o(e,t){const r=isFinite(e[2])||isFinite(e[5]);return new i.Z(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 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[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}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[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}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 d(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 c(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 p(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?p(e,b):s(b)}function f(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 y(e,t,r,i,s){return e[0]=t,e[1]=r,e[2]=Number.NEGATIVE_INFINITY,e[3]=i,e[4]=s,e[5]=Number.POSITIVE_INFINITY,e}function m(e){return 6===e.length}function g(e,t,r){if(null==e||null==t)return e===t;if(!m(e)||!m(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(24470);const b=[1/0,1/0,1/0,-1/0,-1/0,-1/0],w=[0,0,0,0,0,0];s()},12653:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Q});var i=r(43697),s=(r(66577),r(51773)),n=(r(16050),r(12501),r(28756),r(92271),r(72529),r(5499),r(84382),r(81571),r(91423),r(32400)),o=r(16453),a=r(78286),l=r(17452),u=r(5600),d=r(75215),c=(r(67676),r(80442)),p=r(52011),h=r(30556),f=r(86973),y=r(87085),m=r(20102),g=r(83379),b=r(95330),w=r(56569),v=r(25278),_=r(78089),F=r(74889),S=r(25031),C=r(6570);let I=class extends g.Z{constructor(){super(...arguments),this._connection=null,this.capabilities=(0,v.MS)(!1,!1),this.type="wfs",this.refresh=(0,b.Ds)((async e=>{await this.load();const{extent:t}=await this._connection.invoke("refresh",e);return t&&(this.sourceJSON.extent=t),{dataChanged:!0,updates:{extent:this.sourceJSON.extent}}}))}load(e){const t=null!=e?e.signal:null;return this.addResolvingPromise(this._startWorker({signal:t})),Promise.resolve(this)}destroy(){this._connection?.close(),this._connection=null}async openPorts(){return await this.load(),this._connection.openPorts()}async queryFeatures(e,t={}){await this.load(t);const r=await this._connection.invoke("queryFeatures",e?e.toJSON():null,t);return F.Z.fromJSON(r)}async queryFeaturesJSON(e,t={}){return await this.load(t),this._connection.invoke("queryFeatures",e?e.toJSON():null,t)}async queryFeatureCount(e,t={}){return await this.load(t),this._connection.invoke("queryFeatureCount",e?e.toJSON():null,t)}async queryObjectIds(e,t={}){return await this.load(t),this._connection.invoke("queryObjectIds",e?e.toJSON():null,t)}async queryExtent(e,t={}){await this.load(t);const r=await this._connection.invoke("queryExtent",e?e.toJSON():null,t);return{count:r.count,extent:C.Z.fromJSON(r.extent)}}async querySnapping(e,t={}){return await this.load(t),this._connection.invoke("querySnapping",e,t)}async _createLoadOptions(e){const{url:t,customParameters:r,name:i,namespaceUri:s,fields:n,geometryType:o,swapXY:a}=this.layer,l="defaults"===this.layer.originOf("spatialReference")?void 0:this.layer.spatialReference;if(!t)throw new m.Z("wfs-layer:missing-url","WFSLayer must be created with a url");this.wfsCapabilities||(this.wfsCapabilities=await(0,_.FU)(t,{customParameters:r,...e}));const u=["fields","geometryType","name","namespaceUri","swapXY"].some((e=>null==this.layer[e])),d=u?await(0,_.be)(this.wfsCapabilities,i,s,{spatialReference:l,customParameters:r,signal:e?.signal}):{...(0,_.eB)(n??[]),geometryType:o,name:i,namespaceUri:s,spatialReference:l,swapXY:a},c=(0,_.ft)(this.wfsCapabilities.readFeatureTypes(),d.name,d.namespaceUri),p=f.M.toJSON(d.geometryType);return{customParameters:r,featureType:c,fields:d.fields?.map((e=>e.toJSON()))??[],geometryField:d.geometryField,geometryType:p,getFeatureUrl:this.wfsCapabilities.operations.GetFeature.url,getFeatureOutputFormat:this.wfsCapabilities.operations.GetFeature.outputFormat,objectIdField:d.objectIdField,spatialReference:d.spatialReference?.toJSON(),swapXY:!!d.swapXY}}async _startWorker(e){const[t,r]=await(0,b.as)([this._createLoadOptions(e),(0,w.bA)("WFSSourceWorker",{...e,strategy:(0,c.Z)("feature-layers-workers")?"dedicated":"local",registryTarget:this})]),i=t.error||r.error||null,s=r.value||null;if(i)throw s&&s.close(),i;const n=t.value;this._connection=r.value;const o=(await this._connection.invoke("load",n,e)).extent;this.sourceJSON={dateFieldsTimeReference:{timeZoneIANA:S.pt},extent:o,fields:n.fields,geometryType:n.geometryType,objectIdField:n.objectIdField,geometryField:n.geometryField,drawingInfo:(0,v.bU)(n.geometryType),name:n.featureType.title,wfsInfo:{name:n.featureType.name,featureUrl:n.getFeatureUrl,maxFeatures:3e3,swapXY:n.swapXY,supportedSpatialReferences:n.featureType.supportedSpatialReferences,version:"2.0.0",wfsNamespace:n.featureType.namespaceUri}}}};(0,i._)([(0,u.Cb)()],I.prototype,"capabilities",void 0),(0,i._)([(0,u.Cb)({constructOnly:!0})],I.prototype,"layer",void 0),(0,i._)([(0,u.Cb)()],I.prototype,"sourceJSON",void 0),(0,i._)([(0,u.Cb)()],I.prototype,"type",void 0),(0,i._)([(0,u.Cb)()],I.prototype,"wfsCapabilities",void 0),I=(0,i._)([(0,p.j)("esri.layers.graphics.sources.WFSSource")],I);var x,T=r(71612),j=r(17017),O=r(69637),E=r(6404),R=r(38009),P=r(68825),N=r(16859),Z=r(34760),k=r(72965),M=r(28294),A=r(21506),q=r(1231),D=r(53518),L=r(69165),U=r(54306),J=r(30707),G=r(14165),z=r(32163),H=r(82971);const V=(0,D.v)();let B=x=class extends((0,P.c)((0,j.N)((0,E.M)((0,O.b)((0,T.h)((0,M.n)((0,Z.Q)((0,k.M)((0,R.q)((0,N.I)((0,o.R)(y.Z)))))))))))){static fromWFSLayerInfo(e){const{customParameters:t,fields:r,geometryField:i,geometryType:s,name:n,namespaceUri:o,objectIdField:a,spatialReference:l,swapXY:u,url:d,wfsCapabilities:c}=e;return new x({customParameters:t,fields:r,geometryField:i,geometryType:s,name:n,namespaceUri:o,objectIdField:a,spatialReference:l,swapXY:u,url:d,wfsCapabilities:c})}constructor(e){super(e),this.copyright=null,this.customParameters=null,this.dateFieldsTimeZone=null,this.definitionExpression=null,this.displayField=null,this.elevationInfo=null,this.featureUrl=void 0,this.fields=null,this.fieldsIndex=null,this.fullExtent=null,this.geometryType=null,this.labelsVisible=!0,this.labelingInfo=null,this.legendEnabled=!0,this.objectIdField=null,this.operationalLayerType="WFS",this.maxFeatures=3e3,this.mode=0,this.name=null,this.namespaceUri=null,this.outFields=null,this.popupEnabled=!0,this.popupTemplate=null,this.screenSizePerspectiveEnabled=!0,this.source=new I({layer:this}),this.spatialReference=H.Z.WGS84,this.spatialReferences=[4326],this.swapXY=void 0,this.title="WFS",this.type="wfs",this.url=null,this.version=void 0}destroy(){this.source?.destroy()}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["WFS"]},e).then((()=>this.source.load(e))).then((()=>{this.read(this.source.sourceJSON,{origin:"service",url:this.parsedUrl}),this.revert(["objectIdField","fields","timeInfo","spatialReference","name","namespaceUri"],"service"),(0,L.YN)(this.renderer,this.fieldsIndex),(0,L.UF)(this.timeInfo,this.fieldsIndex)}))),Promise.resolve(this)}get capabilities(){return this.source?.capabilities}get createQueryVersion(){return this.commitProperty("definitionExpression"),this.commitProperty("timeExtent"),this.commitProperty("timeOffset"),this.commitProperty("geometryType"),this.commitProperty("capabilities"),(this._get("createQueryVersion")||0)+1}get defaultPopupTemplate(){return this.createPopupTemplate()}writeFields(e,t,r){const i=e.filter((e=>e.name!==_.u2));this.geometryField&&i.unshift(new q.Z({name:this.geometryField,alias:this.geometryField,type:"geometry"})),(0,a.RB)(r,i.map((e=>e.toJSON())),t)}get parsedUrl(){return(0,l.mN)(this.url)}set renderer(e){(0,L.YN)(e,this.fieldsIndex),this._set("renderer",e)}get wfsCapabilities(){return this.source?.wfsCapabilities}set wfsCapabilities(e){this.source&&(this.source.wfsCapabilities=e)}createPopupTemplate(e){return(0,z.eZ)(this,e)}createQuery(){const e=new G.Z;e.returnGeometry=!0,e.outFields=["*"],e.where=this.definitionExpression||"1=1";const{timeOffset:t,timeExtent:r}=this;return e.timeExtent=null!=t&&null!=r?r.offset(-t.value,t.unit):r||null,e}getFieldDomain(e,t){return this.getField(e)?.domain}getField(e){return this.fieldsIndex?.get(e)}queryFeatures(e,t){return this.load().then((()=>this.source.queryFeatures(G.Z.from(e)||this.createQuery(),t))).then((e=>{if(e?.features)for(const t of e.features)t.layer=t.sourceLayer=this;return e}))}queryObjectIds(e,t){return this.load().then((()=>this.source.queryObjectIds(G.Z.from(e)||this.createQuery(),t)))}queryFeatureCount(e,t){return this.load().then((()=>this.source.queryFeatureCount(G.Z.from(e)||this.createQuery(),t)))}queryExtent(e,t){return this.load().then((()=>this.source.queryExtent(G.Z.from(e)||this.createQuery(),t)))}async hasDataChanged(){try{const{dataChanged:e,updates:t}=await this.source.refresh(this.customParameters);return null!=t&&this.read(t,{origin:"service",url:this.parsedUrl,ignoreDefaults:!0}),e}catch{}return!1}};(0,i._)([(0,u.Cb)({readOnly:!0})],B.prototype,"capabilities",null),(0,i._)([(0,u.Cb)({type:String})],B.prototype,"copyright",void 0),(0,i._)([(0,u.Cb)({readOnly:!0})],B.prototype,"createQueryVersion",null),(0,i._)([(0,u.Cb)({json:{name:"wfsInfo.customParameters",write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0),ignoreOrigin:!0})}}})],B.prototype,"customParameters",void 0),(0,i._)([(0,u.Cb)((0,S.mi)("dateFieldsTimeReference"))],B.prototype,"dateFieldsTimeZone",void 0),(0,i._)([(0,u.Cb)({readOnly:!0})],B.prototype,"defaultPopupTemplate",null),(0,i._)([(0,u.Cb)({type:String,json:{name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],B.prototype,"definitionExpression",void 0),(0,i._)([(0,u.Cb)({type:String})],B.prototype,"displayField",void 0),(0,i._)([(0,u.Cb)(A.PV)],B.prototype,"elevationInfo",void 0),(0,i._)([(0,u.Cb)({type:String,readOnly:!0,json:{name:"wfsInfo.featureUrl",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"featureUrl",void 0),(0,i._)([(0,u.Cb)({type:[q.Z],json:{name:"layerDefinition.fields",write:{ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"fields"}}}})],B.prototype,"fields",void 0),(0,i._)([(0,h.c)("fields")],B.prototype,"writeFields",null),(0,i._)([(0,u.Cb)(V.fieldsIndex)],B.prototype,"fieldsIndex",void 0),(0,i._)([(0,u.Cb)({type:C.Z,json:{name:"extent"}})],B.prototype,"fullExtent",void 0),(0,i._)([(0,u.Cb)()],B.prototype,"geometryField",void 0),(0,i._)([(0,u.Cb)({type:String,json:{read:{source:"layerDefinition.geometryType",reader:f.M.read},write:{target:"layerDefinition.geometryType",writer:f.M.write,ignoreOrigin:!0},origins:{service:{read:f.M.read}}}})],B.prototype,"geometryType",void 0),(0,i._)([(0,u.Cb)({type:String})],B.prototype,"id",void 0),(0,i._)([(0,u.Cb)(A.iR)],B.prototype,"labelsVisible",void 0),(0,i._)([(0,u.Cb)({type:[U.Z],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:{reader:J.r},write:!0}})],B.prototype,"labelingInfo",void 0),(0,i._)([(0,u.Cb)(A.rn)],B.prototype,"legendEnabled",void 0),(0,i._)([(0,u.Cb)({type:["show","hide"]})],B.prototype,"listMode",void 0),(0,i._)([(0,u.Cb)({type:String})],B.prototype,"objectIdField",void 0),(0,i._)([(0,u.Cb)({type:["WFS"]})],B.prototype,"operationalLayerType",void 0),(0,i._)([(0,u.Cb)({type:d.z8,json:{name:"wfsInfo.maxFeatures",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"maxFeatures",void 0),(0,i._)([(0,u.Cb)({type:[0],readOnly:!0,json:{origins:{"web-map":{write:{ignoreOrigin:!0,isRequired:!0}}}}})],B.prototype,"mode",void 0),(0,i._)([(0,u.Cb)({type:String,json:{name:"wfsInfo.name",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"name",void 0),(0,i._)([(0,u.Cb)({type:String,json:{name:"wfsInfo.wfsNamespace",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"namespaceUri",void 0),(0,i._)([(0,u.Cb)(A.bT)],B.prototype,"opacity",void 0),(0,i._)([(0,u.Cb)(V.outFields)],B.prototype,"outFields",void 0),(0,i._)([(0,u.Cb)({readOnly:!0})],B.prototype,"parsedUrl",null),(0,i._)([(0,u.Cb)(A.C_)],B.prototype,"popupEnabled",void 0),(0,i._)([(0,u.Cb)({type:s.Z,json:{name:"popupInfo",write:!0}})],B.prototype,"popupTemplate",void 0),(0,i._)([(0,u.Cb)({types:n.A,json:{origins:{service:{name:"drawingInfo.renderer"},"web-scene":{types:n.o,name:"layerDefinition.drawingInfo.renderer",write:!0}},name:"layerDefinition.drawingInfo.renderer",write:{ignoreOrigin:!0}}})],B.prototype,"renderer",null),(0,i._)([(0,u.Cb)(A.YI)],B.prototype,"screenSizePerspectiveEnabled",void 0),(0,i._)([(0,u.Cb)({readOnly:!0})],B.prototype,"source",void 0),(0,i._)([(0,u.Cb)({type:H.Z,json:{name:"layerDefinition.spatialReference",write:{ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"extent.spatialReference"}}}})],B.prototype,"spatialReference",void 0),(0,i._)([(0,u.Cb)({readOnly:!0,type:[d.z8],json:{name:"wfsInfo.supportedSpatialReferences",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"spatialReferences",void 0),(0,i._)([(0,u.Cb)({type:Boolean,value:!1,json:{name:"wfsInfo.swapXY",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"swapXY",void 0),(0,i._)([(0,u.Cb)({json:{write:{ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"name"}}}})],B.prototype,"title",void 0),(0,i._)([(0,u.Cb)({json:{read:!1},readOnly:!0})],B.prototype,"type",void 0),(0,i._)([(0,u.Cb)(A.HQ)],B.prototype,"url",void 0),(0,i._)([(0,u.Cb)({type:String,readOnly:!0,json:{name:"wfsInfo.version",write:{ignoreOrigin:!0,isRequired:!0}}})],B.prototype,"version",void 0),(0,i._)([(0,u.Cb)()],B.prototype,"wfsCapabilities",null),B=x=(0,i._)([(0,p.j)("esri.layers.WFSLayer")],B);const Q=B},70272:(e,t,r)=>{r.d(t,{S6:()=>s,nd:()=>n,u_:()=>i});class i{constructor(e=null,t={},r,i){this.geometry=e,this.attributes=t,this.centroid=r,this.objectId=i,this.displayId=0,this.geohashX=0,this.geohashY=0}weakClone(){const e=new i(this.geometry,this.attributes,this.centroid,this.objectId);return e.displayId=this.displayId,e.geohashX=this.geohashX,e.geohashY=this.geohashY,e}}function s(e){return!!e.geometry?.coords?.length}class n extends i{}},5428:(e,t,r)=>{r.d(t,{Z:()=>i});class i{constructor(e=[],t=[],r=!1){this.lengths=e??[],this.coords=t??[],this.hasIndeterminateRingOrder=r}static fromRect(e){const[t,r,s,n]=e,o=s-t,a=n-r;return new i([5],[t,r,o,0,0,a,-o,0,0,-a])}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((e,t)=>e+t))}forEachVertex(e){let t=0;this.lengths.length||e(this.coords[0],this.coords[1]);for(let r=0;r<this.lengths.length;r++){const i=this.lengths[r];for(let r=0;r<i;r++)e(this.coords[2*(r+t)],this.coords[2*(r+t)+1]);t+=i}}clone(e){return e?(e.set(this.coords),new i(this.lengths.slice(),e,this.hasIndeterminateRingOrder)):new i(this.lengths.slice(),this.coords.slice(),this.hasIndeterminateRingOrder)}}},61159:(e,t,r)=>{r.d(t,{g:()=>i});const i={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCacheHint:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0}},25278:(e,t,r)=>{r.d(t,{Dm:()=>d,Hq:()=>c,MS:()=>p,bU:()=>a});var i=r(80442),s=r(22974),n=r(61159),o=r(58333);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.I4:"esriGeometryPolyline"===e?o.ET:o.lF}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function d(e,t){if((0,i.Z)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let r=`this.${t} = null;`;for(const t in e)r+=`this${l.test(t)?`.${t}`:`["${t}"]`} = ${JSON.stringify(e[t])};`;const i=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new i}catch(r){return()=>({[t]:null,...e})}}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,s.d9)(e)}}]}function p(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:n.g,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}}}},17017:(e,t,r)=>{r.d(t,{N:()=>o});var i=r(43697),s=r(5600),n=(r(75215),r(67676),r(80442),r(52011));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,i._)([(0,s.Cb)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,i._)([(0,n.j)("esri.layers.mixins.CustomParametersMixin")],t),t}},69637:(e,t,r)=>{r.d(t,{b:()=>T});var i,s=r(43697),n=r(5600),o=(r(75215),r(67676),r(80442),r(52011)),a=r(20102),l=r(96674),u=r(78286),d=r(72746),c=r(66577),p=r(92835),h=r(35454),f=r(22974),y=r(14165);const m=new h.X({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),g=new h.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let b=i=class extends l.wq{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:s,objectIds:n,units:o,distance:a}=this;return new y.Z({geometry:(0,f.d9)(r),objectIds:(0,f.d9)(n),spatialRelationship:i,timeExtent:(0,f.d9)(s),where:t,units:o,distance:a,...e})}clone(){const{where:e,geometry:t,spatialRelationship:r,timeExtent:s,objectIds:n,units:o,distance:a}=this;return new i({geometry:(0,f.d9)(t),objectIds:(0,f.d9)(n),spatialRelationship:r,timeExtent:(0,f.d9)(s),where:e,units:o,distance:a})}};(0,s._)([(0,n.Cb)({type:String,json:{write:!0}})],b.prototype,"where",void 0),(0,s._)([(0,n.Cb)({types:c.qM,json:{write:!0}})],b.prototype,"geometry",void 0),(0,s._)([(0,n.Cb)({type:m.apiValues,json:{name:"spatialRel",read:{reader:m.read},write:{allowNull:!1,writer:m.write,overridePolicy(){return{enabled:null!=this.geometry}}}}})],b.prototype,"spatialRelationship",void 0),(0,s._)([(0,n.Cb)({type:Number,json:{write:{overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],b.prototype,"distance",void 0),(0,s._)([(0,n.Cb)({type:[Number],json:{write:!0}})],b.prototype,"objectIds",void 0),(0,s._)([(0,n.Cb)({type:g.apiValues,json:{read:g.read,write:{writer:g.write,overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],b.prototype,"units",void 0),(0,s._)([(0,n.Cb)({type:p.Z,json:{write:!0}})],b.prototype,"timeExtent",void 0),b=i=(0,s._)([(0,o.j)("esri.layers.support.FeatureFilter")],b);const w=b;var v;const _={read:{reader:d.ij},write:{writer:d.cW,overridePolicy(){return{allowNull:null!=this.excludedEffect,isRequired:null==this.excludedEffect}}}},F={read:{reader:d.ij},write:{writer:d.cW,overridePolicy(){return{allowNull:null!=this.includedEffect,isRequired:null==this.includedEffect}}}},S={name:"showExcludedLabels",default:!0};let C=v=class extends l.wq{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 a.Z("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 a.Z("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 v({filter:null!=this.filter?this.filter.clone():null,includedEffect:this.includedEffect,excludedEffect:this.excludedEffect,excludedLabelsVisible:this.excludedLabelsVisible})}};(0,s._)([(0,n.Cb)({type:w,json:{write:{allowNull:!0,writer(e,t,r,i){const s=e?.write({},i);s&&0!==Object.keys(s).length?(0,u.RB)(r,s,t):(0,u.RB)(r,null,t)}}}})],C.prototype,"filter",void 0),(0,s._)([(0,n.Cb)({json:{write:!0,origins:{"web-map":_,"portal-item":_}}})],C.prototype,"includedEffect",void 0),(0,s._)([(0,n.Cb)({json:{write:!0,origins:{"web-map":F,"portal-item":F}}})],C.prototype,"excludedEffect",void 0),(0,s._)([(0,n.Cb)({type:Boolean,json:{write:!0,name:"showExcludedLabels",origins:{"web-map":S,"portal-item":S}}})],C.prototype,"excludedLabelsVisible",void 0),C=v=(0,s._)([(0,o.j)("esri.layers.support.FeatureEffect")],C);const I=C,x={write:{allowNull:!0}},T=e=>{let t=class extends e{constructor(){super(...arguments),this.featureEffect=null}};return(0,s._)([(0,n.Cb)({type:I,json:{origins:{"web-map":x,"portal-item":x}}})],t.prototype,"featureEffect",void 0),t=(0,s._)([(0,o.j)("esri.layers.mixins.FeatureEffectLayer")],t),t}},68825:(e,t,r)=>{r.d(t,{c:()=>y});var i,s=r(43697),n=r(78286),o=r(5600),a=(r(75215),r(67676),r(80442),r(52011)),l=r(35454),u=r(96674);const d=new l.X({asc:"ascending",desc:"descending"});let c=i=class extends u.wq{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,s._)([(0,o.Cb)({type:String,json:{write:!0}})],c.prototype,"field",void 0),(0,s._)([(0,o.Cb)({type:String,json:{write:!0}})],c.prototype,"valueExpression",void 0),(0,s._)([(0,o.Cb)({type:d.apiValues,json:{read:d.read,write:d.write}})],c.prototype,"order",void 0),c=i=(0,s._)([(0,a.j)("esri.layers.support.OrderByInfo")],c);const p=c;function h(e,t,r){if(!e)return null;const i=e.find((e=>!!e.field));if(!i)return null;const s=new p;return s.read(i,r),[s]}function f(e,t,r,i){const s=e.find((e=>!!e.field));s&&(0,n.RB)(r,[s.toJSON()],t)}const y=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,s._)([(0,o.Cb)({type:[p],json:{origins:{"web-scene":{write:!1,read:!1}},read:{source:"layerDefinition.orderBy",reader:h},write:{target:"layerDefinition.orderBy",writer:f}}})],t.prototype,"orderBy",void 0),t=(0,s._)([(0,a.j)("esri.layers.mixins.OrderedLayer")],t),t}},34760:(e,t,r)=>{r.d(t,{Q:()=>w});var i=r(43697),s=r(92604),n=r(95330),o=r(5600),a=r(90578),l=(r(67676),r(80442),r(52011)),u=r(82960),d=r(46791),c=(r(66643),r(20102),r(26258),r(87538));const p=new d.Z,h=new WeakMap;function f(e){(function(e){return null!=e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e})(e)&&p.push(new WeakRef(e))}function y(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:y(t,e%t):0}let m=0,g=0;function b(){const e=Date.now();let t=!1;for(const r of p){const i=r.deref();i?i.refreshInterval&&e-(h.get(i)??0)+5>=6e4*i.refreshInterval&&(h.set(i,e),i.refresh(e)):t=!0}if(t)for(let e=p.length-1;e>=0;e--)p.at(e).deref()||p.removeAt(e)}(0,c.EH)((()=>{const e=Date.now();let t=0;for(const r of p){const i=r.deref();i&&(t=y(Math.round(6e4*i.refreshInterval),t),i.refreshInterval?h.get(i)||h.set(i,e):h.delete(i))}if(t!==g){if(g=t,clearInterval(m),0===g)return void(m=0);m=setInterval(b,g)}}));const w=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,n.Ds)((()=>this.hasDataChanged())),this.when().then((()=>{this.destroyed||f(this)}),(()=>{}))}destroy(){!function(e){const t=p.find((t=>t.deref()===e));t&&p.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,n.R8)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{s.Z.getLogger(this).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}get test(){const e=this;return{set refreshInterval(t){e._set("refreshInterval",t)}}}};return(0,i._)([(0,o.Cb)({type:Number,json:{write:!0,origins:{"web-scene":{write:{enabled:!0,layerContainerTypes:u.C}}}}})],t.prototype,"refreshInterval",void 0),(0,i._)([(0,a.p)("refreshInterval")],t.prototype,"castRefreshInterval",null),(0,i._)([(0,o.Cb)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,i._)([(0,o.Cb)({readOnly:!0})],t.prototype,"refreshParameters",null),t=(0,i._)([(0,l.j)("esri.layers.mixins.RefreshableLayer")],t),t}},28294:(e,t,r)=>{r.d(t,{n:()=>p});var i=r(43697),s=r(92835),n=r(84552),o=r(5600),a=(r(75215),r(67676),r(80442),r(71715)),l=r(52011),u=r(69165),d=r(76259),c=r(78981);const p=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,s=c.v.fromJSON(r.timeOffsetUnits);return i&&s?new n.Z({value:i,unit:s}):null}set timeInfo(e){(0,u.UF)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,i._)([(0,o.Cb)({type:s.Z,json:{write:!1}})],t.prototype,"timeExtent",void 0),(0,i._)([(0,o.Cb)({type:n.Z})],t.prototype,"timeOffset",void 0),(0,i._)([(0,a.r)("service","timeOffset",["timeInfo.exportOptions"])],t.prototype,"readOffset",null),(0,i._)([(0,o.Cb)({value:null,type:d.Z,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],t.prototype,"timeInfo",null),(0,i._)([(0,o.Cb)({type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation"},origins:{"web-scene":{read:!1,write:!1}}}})],t.prototype,"useViewTime",void 0),t=(0,i._)([(0,l.j)("esri.layers.mixins.TemporalLayer")],t),t}},99514:(e,t,r)=>{r.d(t,{Z:()=>l});var i=r(20102),s=r(96674),n=r(92604),o=r(69165),a=r(25031);class l{static fromJSON(e){return new l(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new l(e.fields??[],p(e))}static fromLayerJSON(e){return new l(e.fields??[],p(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=d(t);if(t&&i){const s=u(t);this._fieldsMap.set(t,e),this._fieldsMap.set(s,e),this._normalizedFieldsMap.set(i,e),r.push(`${s}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,o.y2)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,o.H7)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,o.Dl)(e)||(0,o.Se)(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,o.Dl)(e)||(0,o.Se)(e)||e.nullable||void 0!==(0,o.os)(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(u(e))??this._normalizedFieldsMap.get(d(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?(n.Z.getLogger("esri.layers.support.FieldsIndex").error(new i.Z("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),a.pt):c.has(t.type)?a._4:null:null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,o.sX)(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,s.AK)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function u(e){return e.trim().toLowerCase()}function d(e){return(0,o.q6)(e)?.toLowerCase()??""}const c=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function p(e){const t=new Map;if(!e.fields)return t;const r=!0===e.datesInUnknownTimezone,{timeInfo:i,editFieldsInfo:s}=e,n=(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,a.Jv)(e.dateFieldsTimeReference):null,d=s?function(e){return"timeZone"in e}(s)?s.timeZone??l:s.dateFieldsTimeReference?(0,a.Jv)(s.dateFieldsTimeReference):l??a.pt:null,p=i?function(e){return"timeZone"in e}(i)?i.timeZone??l:i.timeReference?(0,a.Jv)(i.timeReference):l:null,h=new Map([[u(s?.creationDateField??""),d],[u(s?.editDateField??""),d],[u(n),p],[u(o),p]]);for(const{name:i,type:s}of e.fields)if(c.has(s))t.set(i,a._4);else if("date"!==s&&"esriFieldTypeDate"!==s)t.set(i,null);else if(r)t.set(i,a._4);else{const e=h.get(u(i??""))??l;t.set(i,e)}return t}},76259:(e,t,r)=>{r.d(t,{Z:()=>y});var i=r(43697),s=r(92835),n=r(84552),o=r(2368),a=r(96674),l=r(5600),u=(r(75215),r(67676),r(80442),r(71715)),d=r(52011),c=r(30556),p=r(25031);function h(e,t){return n.Z.fromJSON({value:e,unit:t})}let f=class extends((0,o.J)(a.wq)){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}readFullTimeExtent(e,t){if(!t.timeExtent||!Array.isArray(t.timeExtent)||2!==t.timeExtent.length)return null;const r=new Date(t.timeExtent[0]),i=new Date(t.timeExtent[1]);return new s.Z({start:r,end:i})}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=[e.start.getTime(),e.end.getTime()]:t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,i._)([(0,l.Cb)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],f.prototype,"cumulative",void 0),(0,i._)([(0,l.Cb)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"endField",void 0),(0,i._)([(0,l.Cb)({type:s.Z,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"fullTimeExtent",void 0),(0,i._)([(0,u.r)("fullTimeExtent",["timeExtent"])],f.prototype,"readFullTimeExtent",null),(0,i._)([(0,c.c)("fullTimeExtent")],f.prototype,"writeFullTimeExtent",null),(0,i._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],f.prototype,"hasLiveData",void 0),(0,i._)([(0,l.Cb)({type:n.Z,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"interval",void 0),(0,i._)([(0,u.r)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],f.prototype,"readInterval",null),(0,i._)([(0,c.c)("interval")],f.prototype,"writeInterval",null),(0,i._)([(0,l.Cb)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"startField",void 0),(0,i._)([(0,l.Cb)((0,p.mi)("timeReference",!0))],f.prototype,"timeZone",void 0),(0,i._)([(0,l.Cb)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"trackIdField",void 0),(0,i._)([(0,l.Cb)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],f.prototype,"useTime",void 0),f=(0,i._)([(0,d.j)("esri.layers.support.TimeInfo")],f);const y=f},45574:(e,t,r)=>{r.d(t,{JD:()=>w,Jj:()=>F,sX:()=>D,Ob:()=>U,rP:()=>N,FV:()=>C,nU:()=>q,Ci:()=>I,Fr:()=>b,HW:()=>G,gG:()=>P,uA:()=>J,SU:()=>x,KE:()=>O,VG:()=>j,tD:()=>T,kp:()=>E,C9:()=>R,rk:()=>Z,kZ:()=>k,JY:()=>M,Y5:()=>_,uj:()=>S});var i=r(40330),s=r(9790),n=r(66643),o=r(20102),a=r(35454),l=r(42033),u=r(63213),d=r(14165);async function c(e,t,r){t=t.clone(),e.capabilities.query.supportsMaxRecordCountFactor&&(t.maxRecordCountFactor=p(e));const i=function(e){return p(e)*function(e){return e.capabilities.query.maxRecordCount||2e3}(e)}(e),s=e.capabilities.query.supportsPagination;t.start=0,t.num=i;let n=null;for(;;){const o=await e.source.queryFeaturesJSON(t,r);if(null==n?n=o:n.features=n.features.concat(o.features),n.exceededTransferLimit=o.exceededTransferLimit,!s||!o.exceededTransferLimit)break;t.start+=i}return n}function p(e){return e.capabilities.query.supportsMaxRecordCountFactor?d.Z.MAX_MAX_RECORD_COUNT_FACTOR:1}var h=r(84230),f=r(84382),y=r(81571),m=r(56545),g=r(75935);const b=new a.X({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryMultiPatch:"multipatch"});async function w(e,t,r,i){const s=await A(e);if(await v(e,t,i),!s.addAttachment)throw new o.Z(i,"Layer source does not support addAttachment capability");return s.addAttachment(t,r)}function v(e,t,r){const{attributes:i}=t,{objectIdField:s}=e;return e.capabilities?.data?.supportsAttachment?t?i?s&&i[s]?Promise.resolve():Promise.reject(new o.Z(r,`feature is missing the identifying attribute ${s}`)):Promise.reject(new o.Z(r,"'attributes' are required on a feature to query attachments")):Promise.reject(new o.Z(r,"A feature is required to add/delete/update attachments")):Promise.reject(new o.Z(r,"this layer doesn't support attachments"))}async function _(e,t,r,i,s){const n=await A(e);if(await v(e,t,s),!n.updateAttachment)throw new o.Z(s,"Layer source does not support updateAttachment capability");return n.updateAttachment(t,r,i)}async function F(e,t,i){const{applyEdits:s}=await r.e(4720).then(r.bind(r,14720)),n=await e.load(),{source:o,globalIdField:a}=n;let l=i;return("feature"===n.type?n.infoFor3D:null)&&null!=t.deleteFeatures&&null!=a&&(l={...l,globalIdToObjectId:await G(e,t.deleteFeatures,a)}),s(n,o,t,i)}async function S(e,t,i){const{uploadAssets:s}=await r.e(4720).then(r.bind(r,14720)),n=await e.load();return s(n,n.source,t,i)}async function C(e,t,r,i){const s=await A(e);if(await v(e,t,i),!s.deleteAttachments)throw new o.Z(i,"Layer source does not support deleteAttachments capability");return s.deleteAttachments(t,r)}async function I(e,t,r){const i=(await e.load({signal:t?.signal})).source;if(!i.fetchRecomputedExtents)throw new o.Z(r,"Layer source does not support fetchUpdates capability");return i.fetchRecomputedExtents(t)}async function x(e,t,r,i){t=m.Z.from(t),await e.load();const s=e.source,n=e.capabilities;if(!n?.data?.supportsAttachment)throw new o.Z(i,"this layer doesn't support attachments");const{attachmentTypes:a,objectIds:l,globalIds:u,num:d,size:c,start:p,where:h}=t;if(!n?.operations?.supportsQueryAttachments&&(a?.length>0||u?.length>0||c?.length>0||d||p||h))throw new o.Z(i,"when 'capabilities.operations.supportsQueryAttachments' is false, only objectIds is supported",t);if(!(l?.length||u?.length||h))throw new o.Z(i,"'objectIds', 'globalIds', or 'where' are required to perform attachment query",t);if(!s.queryAttachments)throw new o.Z(i,"Layer source does not support queryAttachments capability",t);return s.queryAttachments(t)}async function T(e,t,r,i){const s=await A(e);if(!s.queryObjectIds)throw new o.Z(i,"Layer source does not support queryObjectIds capability");return s.queryObjectIds(d.Z.from(t)??e.createQuery(),r)}async function j(e,t,r,i){const s=await A(e);if(!s.queryFeatureCount)throw new o.Z(i,"Layer source does not support queryFeatureCount capability");return s.queryFeatureCount(d.Z.from(t)??e.createQuery(),r)}async function O(e,t,r,i){const s=await A(e);if(!s.queryExtent)throw new o.Z(i,"Layer source does not support queryExtent capability");return s.queryExtent(d.Z.from(t)??e.createQuery(),r)}async function E(e,t,r,i){const s=await A(e);if(!s.queryRelatedFeatures)throw new o.Z(i,"Layer source does not support queryRelatedFeatures capability");return s.queryRelatedFeatures(g.default.from(t),r)}async function R(e,t,r,i){const s=await A(e);if(!s.queryRelatedFeaturesCount)throw new o.Z(i,"Layer source does not support queryRelatedFeaturesCount capability");return s.queryRelatedFeaturesCount(g.default.from(t),r)}async function P(e){const t=e.source;if(t?.refresh)try{const{dataChanged:r,updates:i}=await t.refresh();if(null!=i&&(e.sourceJSON={...e.sourceJSON,...i},e.read(i,{origin:"service",url:e.parsedUrl})),r)return!0}catch{}if(e.definitionExpression)try{return(await(0,l.E)(e.definitionExpression,e.fieldsIndex)).hasDateFunctions}catch{}return!1}function N(e){const t=new d.Z,r=e.capabilities?.data,i=e.capabilities?.query;t.historicMoment=e.historicMoment,t.gdbVersion=e.gdbVersion,t.returnGeometry=!0,i&&(t.compactGeometryEnabled=i.supportsCompactGeometry,t.defaultSpatialReferenceEnabled=i.supportsDefaultSpatialReference),r&&(r.supportsZ&&null!=e.returnZ&&(t.returnZ=e.returnZ),r.supportsM&&null!=e.returnM&&(t.returnM=e.returnM)),t.outFields=["*"];const{timeOffset:s,timeExtent:n}=e;return t.timeExtent=null!=s&&null!=n?n.offset(-s.value,s.unit):n||null,t.multipatchOption="multipatch"===e.geometryType?"xyFootprint":null,t}function Z(e){const{globalIdField:t,fields:r}=e;if(t)return t;if(r)for(const e of r)if("esriFieldTypeGlobalID"===e.type)return e.name}function k(e){const{objectIdField:t,fields:r}=e;if(t)return t;if(r)for(const e of r)if("esriFieldTypeOID"===e.type)return e.name}function M(e){return e.currentVersion?e.currentVersion:e.hasOwnProperty("capabilities")||e.hasOwnProperty("drawingInfo")||e.hasOwnProperty("hasAttachments")||e.hasOwnProperty("htmlPopupType")||e.hasOwnProperty("relationships")||e.hasOwnProperty("timeInfo")||e.hasOwnProperty("typeIdField")||e.hasOwnProperty("types")?10:9.3}async function A(e){return(await e.load()).source}async function q(e,t,r){const s=e.parsedUrl?.path;s&&e.authenticationTriggerEvent===t&&await async function(e,t){if(!i.id)return;if(i.id.findCredential(e))return;let r;try{const s=await(0,h.oP)(e,t);s&&(r=await i.id.checkSignInStatus(`${s}/sharing`))}catch(e){}if(r)try{const r=null!=t?t.signal:null;await i.id.getCredential(e,{signal:r})}catch(e){}}(s,r)}function D(e){return!e.sourceJSON?.isMultiServicesView&&(e.userHasUpdateItemPrivileges||e.editingEnabled)}const L=(0,u.d)({types:s.QT});function U(e,t){if(e.defaultSymbol)return e.types?.length?new y.Z({defaultSymbol:L(e.defaultSymbol,e,t),field:e.typeIdField,uniqueValueInfos:e.types.map((e=>({id:e.id,symbol:L(e.symbol,e,t)})))}):new f.Z({symbol:L(e.defaultSymbol,e,t)})}function J(e){let t=e.sourceJSON?.cacheMaxAge;if(!t)return!1;const r=e.editingInfo?.lastEditDate?.getTime();return null==r||(t*=1e3,Date.now()-r<t)}async function G(e,t,r){if(null==t)return null;const i=[],{objectIdField:s}=e;if(t.forEach((e=>{let t=null;if("attributes"in e){const{attributes:i}=e;t={globalId:i[r],objectId:null!=i[s]&&-1!==i[s]?i[s]:null}}else t={globalId:e.globalId,objectId:null!=e.objectId&&-1!==e.objectId?e.objectId:null};null!=t.globalId&&(null!=t.objectId&&-1!==t.objectId||i.push(t.globalId))})),0===i.length)return null;const o=e.createQuery();o.where=i.map((e=>`${r}='${e}'`)).join(" OR "),o.returnGeometry=!1,o.outFields=[s,r],o.cacheHint=!1;const a=await(0,n.mt)(c(e,o));if(!a.ok)return null;const l=new Map,u=a.value.features;for(const e of u){const t=e.attributes[r],i=e.attributes[s];null!=t&&null!=i&&-1!==i&&l.set(t,i)}return l}},53518:(e,t,r)=>{r.d(t,{v:()=>l});var i=r(80442),s=r(92604),n=r(1231),o=r(99514),a=r(69165);function l(){return{fields:{type:[n.Z],value:null,set:function(e){if(e&&(0,i.Z)("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(", ");s.Z.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.Z.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||s.Z.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,a.Q0)(this.fieldsIndex,e)}}}}},86719:(e,t,r)=>{r.d(t,{v:()=>i});const i=new(r(35454).X)({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"})},78981:(e,t,r)=>{r.d(t,{v:()=>i});const i=(0,r(35454).w)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},74889:(e,t,r)=>{r.d(t,{Z:()=>w});var i,s=r(43697),n=r(66577),o=r(38171),a=r(35454),l=r(96674),u=r(22974),d=r(5600),c=(r(75215),r(71715)),p=r(52011),h=r(30556),f=r(82971),y=r(33955),m=r(1231);const g=new a.X({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let b=i=class extends l.wq{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=f.Z.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const s=e[t],n=o.Z.fromJSON(s),a=s.geometry?.spatialReference;null==n.geometry||a||(n.geometry.spatialReference=r);const l=s.aggregateGeometries,u=n.aggregateGeometries;if(l&&null!=u)for(const e in u){const t=u[e],i=l[e],s=i?.spatialReference;null==t||s||(t.spatialReference=r)}i.push(n)}return i}writeGeometryType(e,t,r,i){if(e)return void g.write(e,t,r,i);const{features:s}=this;if(s)for(const e of s)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,y.im)(e);return i&&!r&&t.spatialReference&&(i.spatialReference=f.Z.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,u.d9)({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,s]}=e,n=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-i)/t)),(e=>Math.round((s-e)/r)));for(let e=0,t=n.length;e<t;e++)o?.(n[e].geometry)||(n.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,s],scale:[n,o]}=r;let a=null,l=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;a=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;l=r=>null==r?r:r*t+e}const u=this._getHydrationFunction(e,(e=>e*n+i),(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,r){let i,s;const n=[];for(let o=0,a=e.length;o<a;o++){const a=e[o];if(o>0){const e=t(a[0]),o=r(a[1]);e===i&&o===s||(n.push([e-i,o-s]),i=e,s=o)}else i=t(a[0]),s=r(a[1]),n.push([i,s])}return n.length>0?n: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,y.oU)(e)?e.rings:e.paths,s=[];for(let e=0,n=i.length;e<n;e++){const n=i[e],o=this._quantizePoints(n,t,r);o&&s.push(o)}return s.length>0?((0,y.oU)(e)?e.rings=s:e.paths=s,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,s){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 n=(0,y.oU)(e)?e.rings:e.paths;let o,a;for(let e=0,i=n.length;e<i;e++){const i=n[e];for(let e=0,s=i.length;e<s;e++){const s=i[e];e>0?(o+=s[0],a+=s[1]):(o=s[0],a=s[1]),s[0]=t(o),s[1]=r(a)}}if(i&&s)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2]),r[3]=s(r[3])}}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2])}}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=s(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)),s&&null!=e.mmax&&null!=e.mmin&&(e.mmax=s(e.mmax),e.mmin=s(e.mmin))}:"multipoint"===e?e=>{const n=e.points;let o,a;for(let e=0,i=n.length;e<i;e++){const i=n[e];e>0?(o+=i[0],a+=i[1]):(o=i[0],a=i[1]),i[0]=t(o),i[1]=r(a)}if(i&&s)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=i(t[2]),t[3]=s(t[3])}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=i(t[2])}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2])}}:null}};(0,s._)([(0,d.Cb)({type:String,json:{write:!0}})],b.prototype,"displayFieldName",void 0),(0,s._)([(0,d.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],b.prototype,"exceededTransferLimit",void 0),(0,s._)([(0,d.Cb)({type:[o.Z],json:{write:!0}})],b.prototype,"features",void 0),(0,s._)([(0,c.r)("features")],b.prototype,"readFeatures",null),(0,s._)([(0,d.Cb)({type:[m.Z],json:{write:!0}})],b.prototype,"fields",void 0),(0,s._)([(0,d.Cb)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],b.prototype,"geometryType",void 0),(0,s._)([(0,h.c)("geometryType")],b.prototype,"writeGeometryType",null),(0,s._)([(0,d.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],b.prototype,"hasM",void 0),(0,s._)([(0,d.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],b.prototype,"hasZ",void 0),(0,s._)([(0,d.Cb)({types:n.qM,json:{write:!0}})],b.prototype,"queryGeometry",void 0),(0,s._)([(0,c.r)("queryGeometry")],b.prototype,"readQueryGeometry",null),(0,s._)([(0,d.Cb)({type:f.Z,json:{write:!0}})],b.prototype,"spatialReference",void 0),(0,s._)([(0,h.c)("spatialReference")],b.prototype,"writeSpatialReference",null),(0,s._)([(0,d.Cb)({json:{write:!0}})],b.prototype,"transform",void 0),b=i=(0,s._)([(0,p.j)("esri.rest.support.FeatureSet")],b),b.prototype.toJSON.isDefaultToJSON=!0;const w=b},75935:(e,t,r)=>{r.r(t),r.d(t,{default:()=>f});var i,s=r(43697),n=(r(66577),r(96674)),o=r(22974),a=r(5600),l=r(75215),u=r(52011),d=r(30556),c=r(10158),p=r(82971);let h=i=class extends n.wq{constructor(e){super(e),this.cacheHint=void 0,this.dynamicDataSource=void 0,this.gdbVersion=null,this.geometryPrecision=void 0,this.historicMoment=null,this.maxAllowableOffset=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.relationshipId=void 0,this.start=void 0,this.num=void 0,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.where=null}_writeHistoricMoment(e,t){t.historicMoment=e&&e.getTime()}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10,this.start>0&&null==this.where&&(t.definitionExpression="1=1")}clone(){return new i((0,o.d9)({cacheHint:this.cacheHint,dynamicDataSource:this.dynamicDataSource,gdbVersion:this.gdbVersion,geometryPrecision:this.geometryPrecision,historicMoment:this.historicMoment&&new Date(this.historicMoment.getTime()),maxAllowableOffset:this.maxAllowableOffset,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,relationshipId:this.relationshipId,start:this.start,num:this.num,returnGeometry:this.returnGeometry,where:this.where,returnZ:this.returnZ,returnM:this.returnM}))}};(0,s._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],h.prototype,"cacheHint",void 0),(0,s._)([(0,a.Cb)({type:c.n,json:{write:!0}})],h.prototype,"dynamicDataSource",void 0),(0,s._)([(0,a.Cb)({type:String,json:{write:!0}})],h.prototype,"gdbVersion",void 0),(0,s._)([(0,a.Cb)({type:Number,json:{write:!0}})],h.prototype,"geometryPrecision",void 0),(0,s._)([(0,a.Cb)({type:Date})],h.prototype,"historicMoment",void 0),(0,s._)([(0,d.c)("historicMoment")],h.prototype,"_writeHistoricMoment",null),(0,s._)([(0,a.Cb)({type:Number,json:{write:!0}})],h.prototype,"maxAllowableOffset",void 0),(0,s._)([(0,a.Cb)({type:[Number],json:{write:!0}})],h.prototype,"objectIds",void 0),(0,s._)([(0,a.Cb)({type:[String],json:{write:!0}})],h.prototype,"orderByFields",void 0),(0,s._)([(0,a.Cb)({type:[String],json:{write:!0}})],h.prototype,"outFields",void 0),(0,s._)([(0,a.Cb)({type:p.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],h.prototype,"outSpatialReference",void 0),(0,s._)([(0,a.Cb)({json:{write:!0}})],h.prototype,"relationshipId",void 0),(0,s._)([(0,a.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],h.prototype,"start",void 0),(0,s._)([(0,d.c)("start"),(0,d.c)("num")],h.prototype,"writeStart",null),(0,s._)([(0,a.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],h.prototype,"num",void 0),(0,s._)([(0,a.Cb)({json:{write:!0}})],h.prototype,"returnGeometry",void 0),(0,s._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],h.prototype,"returnM",void 0),(0,s._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],h.prototype,"returnZ",void 0),(0,s._)([(0,a.Cb)({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],h.prototype,"where",void 0),h=i=(0,s._)([(0,u.j)("esri.rest.support.RelationshipQuery")],h),h.from=(0,l.se)(h);const f=h},58333:(e,t,r)=>{r.d(t,{ET:()=>n,I4:()=>s,eG:()=>l,lF:()=>o,lj:()=>d,qP:()=>a,wW:()=>u});const i=[252,146,31,255],s={type:"esriSMS",style:"esriSMSCircle",size:6,color:i,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},n={type:"esriSLS",style:"esriSLSSolid",width:.75,color:i},o={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},l={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},u={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},d={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8089],{92722:(e,t,n)=>{n.d(t,{O3:()=>F,lG:()=>x,my:()=>C,q9:()=>c});var r=n(20188),o=n(20102),i=n(8744),a=n(70272),s=n(5428),l=n(69165);const u={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function c(e){return u[e]}function*p(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*d(e){if(e)switch(e.type){case"Point":yield e.coordinates;break;case"LineString":case"MultiPoint":yield*e.coordinates;break;case"MultiLineString":case"Polygon":for(const t of e.coordinates)yield*t;break;case"MultiPolygon":for(const t of e.coordinates)for(const e of t)yield*e}}function y(e){for(const t of e)if(t.length>2)return!0;return!1}function f(e){let t=0;for(let n=0;n<e.length;n++){const r=e[n],o=e[(n+1)%e.length];t+=r[0]*o[1]-o[0]*r[1]}return t<=0}function m(e){const t=e[0],n=e[e.length-1];return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t),e}function g(e,t,n){switch(t.type){case"LineString":case"MultiPoint":return function(e,t,n){return b(e,t.coordinates,n),e}(e,t,n);case"MultiLineString":return function(e,t,n){for(const r of t.coordinates)b(e,r,n);return e}(e,t,n);case"MultiPolygon":return function(e,t,n){for(const r of t.coordinates){h(e,r[0],n);for(let t=1;t<r.length;t++)w(e,r[t],n)}return e}(e,t,n);case"Point":return function(e,t,n){return v(e,t.coordinates,n),e}(e,t,n);case"Polygon":return function(e,t,n){const r=t.coordinates;h(e,r[0],n);for(let t=1;t<r.length;t++)w(e,r[t],n);return e}(e,t,n)}}function h(e,t,n){const r=m(t);!function(e){return!f(e)}(r)?b(e,r,n):S(e,r,n)}function w(e,t,n){const r=m(t);!function(e){return f(e)}(r)?b(e,r,n):S(e,r,n)}function b(e,t,n){for(const r of t)v(e,r,n);e.lengths.push(t.length)}function S(e,t,n){for(let r=t.length-1;r>=0;r--)v(e,t[r],n);e.lengths.push(t.length)}function v(e,t,n){const[r,o,i]=t;e.coords.push(r,o),n.hasZ&&e.coords.push(i||0)}function T(e){switch(typeof e){case"string":return(0,r.o)(e)?"esriFieldTypeDate":"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function F(e,t=4326){if(!e)throw new o.Z("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new o.Z("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});const{crs:n}=e;if(!n)return;const r="string"==typeof n?n:"name"===n.type?n.properties.name:"EPSG"===n.type?n.properties.code:null,a=(0,i.oR)({wkid:t})?new RegExp(".*(CRS84H?|4326)$","i"):new RegExp(`.*(${t})$`,"i");if(!r||!a.test(r))throw new o.Z("geojson:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:n})}function C(e,t={}){const n=[],r=new Set,o=new Set;let i,a=!1,s=null,u=!1,{geometryType:f=null}=t,m=!1;for(const t of p(e)){const{geometry:e,properties:p,id:g}=t;if((!e||(f||(f=c(e.type)),c(e.type)===f))&&(a||(a=y(d(e))),u||(u=null!=g,u&&(i=typeof g,p&&(s=Object.keys(p).filter((e=>p[e]===g))))),p&&s&&u&&null!=g&&(s.length>1?s=s.filter((e=>p[e]===g)):1===s.length&&(s=p[s[0]]===g?s:[])),!m&&p)){let e=!0;for(const t in p){if(r.has(t))continue;const i=p[t];if(null==i){e=!1,o.add(t);continue}const a=T(i);if("unknown"===a){o.add(t);continue}o.delete(t),r.add(t);const s=(0,l.q6)(t);s&&n.push({name:s,alias:t,type:a})}m=e}}const g=(0,l.q6)(1===s?.length&&s[0]||null)??void 0;if(g)for(const e of n)if(e.name===g&&(0,l.H7)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:f,hasZ:a,objectIdFieldName:g,objectIdFieldType:i,unknownFields:Array.from(o)}}function x(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:r}=t;for(const o of e){const{geometry:e,properties:i,id:l}=o;if(e&&c(e.type)!==n)continue;const u=i||{};let p;r&&(p=u[r],null==l||p||(u[r]=p=l));const d=new a.u_(e?g(new s.Z,e,t):null,u,null,p??void 0);yield d}}(p(e),t))}},78089:(e,t,n)=>{n.d(t,{Bm:()=>I,FU:()=>j,be:()=>_,eB:()=>O,fU:()=>q,ft:()=>G,u2:()=>b}),n(66577);var r=n(3172),o=n(20102),i=n(66374),a=n(17452),s=n(73615),l=n(8744),u=n(86973),c=n(92722),p=n(88724),d=n(66677),y=n(1231),f=n(69165),m=n(82971),g=n(6570);const h="xlink:href",w="2.0.0",b="__esri_wfs_id__",S="wfs-layer:getWFSLayerTypeInfo-error",v="wfs-layer:empty-service",T="wfs-layer:feature-type-not-found",F="wfs-layer:geojson-not-supported",C="wfs-layer:kvp-encoding-not-supported",x="wfs-layer:malformed-json",k="wfs-layer:unknown-geometry-type",P="wfs-layer:unknown-field-type",R="wfs-layer:unsupported-spatial-reference",N="wfs-layer:unsupported-wfs-version";async function j(e,t){const n=function(e){const t=$(e);(function(e){const t=e.firstElementChild?.getAttribute("version");if(t&&t!==w)throw new o.Z(N,`Unsupported WFS version ${t}. Supported version: ${w}`)})(t),J(t);const n=t.firstElementChild,r=(0,i.Fs)(function(e){return(0,p.H)(e,{FeatureTypeList:{FeatureType:e=>{const t={typeName:"undefined:undefined",name:"",title:"",description:"",extent:null,namespacePrefix:"",namespaceUri:"",defaultSpatialReference:4326,supportedSpatialReferences:[]},n=new Set;return(0,p.h)(e,{Name:e=>{const{name:n,prefix:r}=U(e.textContent);t.typeName=`${r}:${n}`,t.name=n,t.namespacePrefix=r,t.namespaceUri=e.lookupNamespaceURI(r)},Abstract:e=>{t.description=e.textContent},Title:e=>{t.title=e.textContent},WGS84BoundingBox:e=>{t.extent=function(e){let t,n,r,o;for(const i of e.children)switch(i.localName){case"LowerCorner":[t,n]=i.textContent.split(" ").map((e=>Number.parseFloat(e)));break;case"UpperCorner":[r,o]=i.textContent.split(" ").map((e=>Number.parseFloat(e)))}return{xmin:t,ymin:n,xmax:r,ymax:o,spatialReference:l.Zn}}(e)},DefaultCRS:e=>{const r=E(e);r&&(t.defaultSpatialReference=r,n.add(r))},OtherCRS:e=>{const t=E(e);t&&n.add(t)}}),t.title||(t.title=t.name),n.add(4326),t.supportedSpatialReferences.push(...n),t}}})}(n));return{operations:Z(n),get featureTypes(){return Array.from(r())},readFeatureTypes:r}}((await(0,r.Z)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetCapabilities",VERSION:w,...t?.customParameters},signal:t?.signal})).data);return function(e,t){(0,a.$U)(e)&&((0,a.D6)(e,t.operations.DescribeFeatureType.url,!0)&&(t.operations.DescribeFeatureType.url=(0,a.hO)(t.operations.DescribeFeatureType.url)),(0,a.D6)(e,t.operations.GetFeature.url,!0)&&(t.operations.GetFeature.url=(0,a.hO)(t.operations.GetFeature.url)))}(e,n),n}const V=new Set(["json","application/json","geojson","application/json; subtype=geojson"]);function Z(e){let t=!1;const n={GetCapabilities:{url:""},DescribeFeatureType:{url:""},GetFeature:{url:"",outputFormat:null,supportsPagination:!1}};if((0,p.h)(e,{OperationsMetadata:{Operation:e=>{switch(e.getAttribute("name")){case"GetCapabilities":return{DCP:{HTTP:{Get:e=>{n.GetCapabilities.url=e.getAttribute(h)}}}};case"DescribeFeatureType":return{DCP:{HTTP:{Get:e=>{n.DescribeFeatureType.url=e.getAttribute(h)}}}};case"GetFeature":return{DCP:{HTTP:{Get:e=>{n.GetFeature.url=e.getAttribute(h)}}},Parameter:e=>{if("outputFormat"===e.getAttribute("name"))return{AllowedValues:{Value:e=>{const t=e.textContent;t&&V.has(t.toLowerCase())&&(n.GetFeature.outputFormat=t)}}}}}}},Constraint:e=>{switch(e.getAttribute("name")){case"KVPEncoding":return{DefaultValue:e=>{t="true"===e.textContent.toLowerCase()}};case"ImplementsResultPaging":return{DefaultValue:e=>{n.GetFeature.supportsPagination="true"===e.textContent.toLowerCase()}}}}}}),!t)throw new o.Z(C,"WFS service doesn't support key/value pair (KVP) encoding");if(null==n.GetFeature.outputFormat)throw new o.Z(F,"WFS service doesn't support GeoJSON output format");return n}function E(e){const t=parseInt(e.textContent?.match(/(?<wkid>\d+$)/i)?.groups?.wkid??"",10);if(!Number.isNaN(t))return t}function G(e,t,n){return(0,i.sE)(e,(e=>n?e.name===t&&e.namespaceUri===n:e.typeName===t||e.name===t))}async function _(e,t,n,r={}){const{featureType:i,extent:a}=await async function(e,t,n,r={}){const i=e.readFeatureTypes(),a=t?G(i,t,n):i.next().value,{spatialReference:u=new m.Z({wkid:a?.defaultSpatialReference})}=r;if(null==a)throw t?new o.Z(T,`The type '${t}' could not be found in the service`):new o.Z(v,"The service is empty");let c=new g.Z({...a.extent,spatialReference:m.Z.WGS84});if(!(0,l.fS)(c.spatialReference,u))try{await(0,s.initializeProjection)(c.spatialReference,u,void 0,r),c=(0,s.project)(c,u)}catch{throw new o.Z(R,"Projection not supported")}return{extent:c,spatialReference:u,featureType:a}}(e,t,n,r),{spatialReference:u}=q(e.operations.GetFeature.url,i,r.spatialReference),{fields:c,geometryType:p,swapXY:d,objectIdField:y,geometryField:f}=await async function(e,t,n,r={}){const{typeName:i}=t,[a,s]=await Promise.allSettled([D(e.operations.DescribeFeatureType.url,i,r),A(e,i,n,r)]),l=e=>new o.Z(S,`An error occurred while getting info about the feature type '${i}'`,{error:e});if("rejected"===a.status)throw l(a.reason);if("rejected"===s.status)throw l(s.reason);const{fields:u,errors:c}=a.value??{},p=a.value?.geometryType||s.value?.geometryType,d=s.value?.swapXY??!1;if(null==p)throw new o.Z(k,`The geometry type could not be determined for type '${i}`,{typeName:i,geometryType:p,fields:u,errors:c});return{...O(u??[]),geometryType:p,swapXY:d}}(e,i,u,r);return{url:e.operations.GetCapabilities.url,name:i.name,namespaceUri:i.namespaceUri,fields:c,geometryField:f,geometryType:p,objectIdField:y,spatialReference:r.spatialReference??new m.Z({wkid:i.defaultSpatialReference}),extent:a,swapXY:d,wfsCapabilities:e,customParameters:r.customParameters}}function O(e){const t=e.find((e=>"geometry"===e.type));let n=e.find((e=>"oid"===e.type));return e=e.filter((e=>"geometry"!==e.type)),n||(n=new y.Z({name:b,type:"oid",alias:b}),e.unshift(n)),{geometryField:t?.name??null,objectIdField:n.name,fields:e}}async function A(e,t,n,o={}){let i,a=!1;const[s,l]=await Promise.all([I(e.operations.GetFeature.url,t,n,e.operations.GetFeature.outputFormat,{...o,count:1}),(0,r.Z)(e.operations.GetFeature.url,{responseType:"text",query:L(t,n,void 0,{...o,count:1}),signal:o?.signal})]),p="FeatureCollection"===s.type&&s.features[0]?.geometry;if(p){let e;switch(i=u.M.fromJSON((0,c.q9)(p.type)),p.type){case"Point":e=p.coordinates;break;case"LineString":case"MultiPoint":e=p.coordinates[0];break;case"MultiLineString":case"Polygon":e=p.coordinates[0][0];break;case"MultiPolygon":e=p.coordinates[0][0][0]}const t=/<[^>]*pos[^>]*> *(-?\d+(?:\.\d+)?) (-?\d+(?:\.\d+)?)/.exec(l.data);if(t){const n=e[0].toFixed(3),r=e[1].toFixed(3),o=parseFloat(t[1]).toFixed(3);n===parseFloat(t[2]).toFixed(3)&&r===o&&(a=!0)}}return{geometryType:i,swapXY:a}}async function D(e,t,n){return function(e,t){const{name:n}=U(e),r=$(t);J(r);const a=(0,i.sE)((0,p.H)(r.firstElementChild,{element:e=>({name:e.getAttribute("name"),typeName:U(e.getAttribute("type")).name})}),(({name:e})=>e===n));if(null!=a){const e=(0,i.sE)((0,p.H)(r.firstElementChild,{complexType:e=>e}),(e=>e.getAttribute("name")===a.typeName));if(null!=e)return function(e){const t=[],n=[];let r;const i=(0,p.H)(e,{complexContent:{extension:{sequence:{element:e=>e}}}});for(const a of i){const i=a.getAttribute("name");if(!i)continue;let s,l;if(a.hasAttribute("type")?s=U(a.getAttribute("type")).name:(0,p.h)(a,{simpleType:{restriction:e=>(s=U(e.getAttribute("base")).name,{maxLength:e=>{l=+e.getAttribute("value")}})}}),!s)continue;const u="true"===a.getAttribute("nillable");let c=!1;switch(s.toLowerCase()){case"integer":case"nonpositiveinteger":case"negativeinteger":case"long":case"int":case"short":case"byte":case"nonnegativeinteger":case"unsignedlong":case"unsignedint":case"unsignedshort":case"unsignedbyte":case"positiveinteger":n.push(new y.Z({name:i,alias:i,type:"integer",nullable:u,length:(0,f.ZR)("integer")}));break;case"float":case"double":case"decimal":n.push(new y.Z({name:i,alias:i,type:"double",nullable:u,length:(0,f.ZR)("double")}));break;case"boolean":case"string":case"gyearmonth":case"gyear":case"gmonthday":case"gday":case"gmonth":case"anyuri":case"qname":case"notation":case"normalizedstring":case"token":case"language":case"idrefs":case"entities":case"nmtoken":case"nmtokens":case"name":case"ncname":case"id":case"idref":case"entity":case"duration":case"time":n.push(new y.Z({name:i,alias:i,type:"string",nullable:u,length:l??(0,f.ZR)("string")}));break;case"datetime":case"date":n.push(new y.Z({name:i,alias:i,type:"date",nullable:u,length:l??(0,f.ZR)("date")}));break;case"pointpropertytype":r="point",c=!0;break;case"multipointpropertytype":r="multipoint",c=!0;break;case"curvepropertytype":case"multicurvepropertytype":case"multilinestringpropertytype":r="polyline",c=!0;break;case"surfacepropertytype":case"multisurfacepropertytype":case"multipolygonpropertytype":r="polygon",c=!0;break;case"geometrypropertytype":case"multigeometrypropertytype":c=!0,t.push(new o.Z(k,`geometry type '${s}' is not supported`,{type:(new XMLSerializer).serializeToString(e)}));break;default:t.push(new o.Z(P,`Unknown field type '${s}'`,{type:(new XMLSerializer).serializeToString(e)}))}c&&n.push(new y.Z({name:i,alias:i,type:"geometry",nullable:u}))}for(const e of n)if("integer"===e.type&&!e.nullable&&M.has(e.name.toLowerCase())){e.type="oid";break}return{geometryType:r,fields:n,errors:t}}(e)}throw new o.Z(T,`Type '${e}' not found in document`,{document:(new XMLSerializer).serializeToString(r)})}(t,(await(0,r.Z)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"DescribeFeatureType",VERSION:w,TYPENAME:t,...n?.customParameters},signal:n?.signal})).data)}const M=new Set(["objectid","fid"]);async function I(e,t,n,i,a){let{data:s}=await(0,r.Z)(e,{responseType:"text",query:L(t,n,i,a),signal:a?.signal});s=s.replaceAll(/": +(-?\d+),(\d+)(,)?/g,'": $1.$2$3');try{return JSON.parse(s)}catch(e){throw new o.Z(x,"Error while parsing the response",{response:s,error:e})}}function L(e,t,n,r){const o="number"==typeof t?t:t.wkid;return{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:w,TYPENAMES:e,OUTPUTFORMAT:n,SRSNAME:"EPSG:"+o,STARTINDEX:r?.startIndex,COUNT:r?.count,...r?.customParameters}}function $(e){return(new DOMParser).parseFromString(e.trim(),"text/xml")}function U(e){const[t,n]=e.split(":");return{prefix:n?t:"",name:n??t}}function J(e){let t="",n="";if((0,p.h)(e.firstElementChild,{Exception:e=>(t=e.getAttribute("exceptionCode"),{ExceptionText:e=>{n=e.textContent}})}),t)throw new o.Z(`wfs-layer:${t}`,n)}function q(e,t,n){const r={wkid:t.defaultSpatialReference},o=null!=n?.wkid?{wkid:n.wkid}:r;return{spatialReference:o,getFeatureSpatialReference:(0,d.B5)(e)||o.wkid&&t.supportedSpatialReferences.includes(o.wkid)?{wkid:o.wkid}:{wkid:t.defaultSpatialReference}}}},88724:(e,t,n)=>{function r(e,t){if(e&&t)for(const n of e.children)if(n.localName in t){const e=t[n.localName];if("function"==typeof e){const t=e(n);t&&r(n,t)}else r(n,e)}}function*o(e,t){for(const n of e.children)if(n.localName in t){const e=t[n.localName];"function"==typeof e?yield e(n):yield*o(n,e)}}n.d(t,{H:()=>o,h:()=>r})},1231:(e,t,n)=>{n.d(t,{Z:()=>g});var r,o=n(43697),i=n(35454),a=n(96674),s=n(5600),l=n(75215),u=(n(67676),n(80442),n(36030)),c=n(71715),p=n(52011),d=n(72729),y=n(86719);const f=new i.X({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=r=class extends a.wq{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?f.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.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,o._)([(0,s.Cb)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,o._)([(0,s.Cb)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,o._)([(0,s.Cb)()],m.prototype,"description",void 0),(0,o._)([(0,c.r)("description")],m.prototype,"readDescription",null),(0,o._)([(0,s.Cb)({types:d.V5,json:{read:{reader:d.im},write:!0}})],m.prototype,"domain",void 0),(0,o._)([(0,s.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,o._)([(0,s.Cb)({type:l.z8,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],m.prototype,"length",void 0),(0,o._)([(0,s.Cb)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,o._)([(0,s.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,o._)([(0,u.J)(y.v)],m.prototype,"type",void 0),(0,o._)([(0,s.Cb)()],m.prototype,"valueType",void 0),(0,o._)([(0,c.r)("valueType",["description"])],m.prototype,"readValueType",null),(0,o._)([(0,s.Cb)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=r=(0,o._)([(0,p.j)("esri.layers.support.Field")],m);const g=m},72729:(e,t,n)=>{n.d(t,{im:()=>C,V5:()=>F}),n(80442);var r,o=n(43697),i=n(22974),a=n(5600),s=(n(75215),n(36030)),l=n(52011),u=n(96674);n(67676);let c=r=class extends u.wq{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,o._)([(0,a.Cb)({type:String,json:{write:!0}})],c.prototype,"name",void 0),(0,o._)([(0,a.Cb)({type:[String,Number],json:{write:!0}})],c.prototype,"code",void 0),c=r=(0,o._)([(0,l.j)("esri.layers.support.CodedValue")],c);const p=new(n(35454).X)({inherited:"inherited",codedValue:"coded-value",range:"range"});let d=class extends u.wq{constructor(e){super(e),this.name=null,this.type=null}};(0,o._)([(0,a.Cb)({type:String,json:{write:!0}})],d.prototype,"name",void 0),(0,o._)([(0,s.J)(p)],d.prototype,"type",void 0),d=(0,o._)([(0,l.j)("esri.layers.support.Domain")],d);const y=d;var f;let m=f=class extends y{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 f({codedValues:(0,i.d9)(this.codedValues),name:this.name})}};(0,o._)([(0,a.Cb)({type:[c],json:{write:!0}})],m.prototype,"codedValues",void 0),(0,o._)([(0,s.J)({codedValue:"coded-value"})],m.prototype,"type",void 0),m=f=(0,o._)([(0,l.j)("esri.layers.support.CodedValueDomain")],m);const g=m;var h;n(92604),n(20102);let w=h=class extends y{constructor(e){super(e),this.type="inherited"}clone(){return new h}};(0,o._)([(0,s.J)({inherited:"inherited"})],w.prototype,"type",void 0),w=h=(0,o._)([(0,l.j)("esri.layers.support.InheritedDomain")],w);const b=w;var S;let v=S=class extends y{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new S({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,o._)([(0,a.Cb)({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,o._)([(0,a.Cb)({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,o._)([(0,s.J)({range:"range"})],v.prototype,"type",void 0),v=S=(0,o._)([(0,l.j)("esri.layers.support.RangeDomain")],v);const T=v,F={key:"type",base:y,typeMap:{range:v,"coded-value":g,inherited:b}};function C(e){if(!e?.type)return null;switch(e.type){case"range":return T.fromJSON(e);case"codedValue":return g.fromJSON(e);case"inherited":return b.fromJSON(e)}return null}}}]);
|