chunk-6NQ3AA2U.js 71 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254
  1. import {
  2. v as v5
  3. } from "./chunk-524XACB7.js";
  4. import {
  5. p as p6
  6. } from "./chunk-XKHC7KKF.js";
  7. import {
  8. p as p5,
  9. p3 as p7,
  10. r as r5
  11. } from "./chunk-HGDNY7J3.js";
  12. import {
  13. l as l5
  14. } from "./chunk-ZRX5UNQH.js";
  15. import {
  16. u as u3
  17. } from "./chunk-VEAEIBHK.js";
  18. import {
  19. i
  20. } from "./chunk-JGOAMEPM.js";
  21. import {
  22. S,
  23. c as c4,
  24. d as d3
  25. } from "./chunk-Z64YKYHD.js";
  26. import {
  27. x
  28. } from "./chunk-2VFJVI2I.js";
  29. import {
  30. t as t4
  31. } from "./chunk-F37AVPUF.js";
  32. import {
  33. r as r3
  34. } from "./chunk-FUEX356Y.js";
  35. import {
  36. e as e2
  37. } from "./chunk-OSNKP4CI.js";
  38. import {
  39. a as a4
  40. } from "./chunk-435DJNTD.js";
  41. import {
  42. v as v2
  43. } from "./chunk-T3EUPDKL.js";
  44. import {
  45. p as p9
  46. } from "./chunk-VVBOYBFX.js";
  47. import {
  48. r as r4,
  49. t as t6
  50. } from "./chunk-S7R5EXHN.js";
  51. import {
  52. i as i2
  53. } from "./chunk-FMKGHOGD.js";
  54. import {
  55. p as p4
  56. } from "./chunk-6URTNEGN.js";
  57. import {
  58. n as n7,
  59. p as p8
  60. } from "./chunk-KN7TOKVN.js";
  61. import {
  62. j as j4
  63. } from "./chunk-RQJNTZAL.js";
  64. import {
  65. o as o4
  66. } from "./chunk-6B2LQBKM.js";
  67. import {
  68. d as d4
  69. } from "./chunk-MFI6BALW.js";
  70. import {
  71. n as n6,
  72. o as o3,
  73. p as p2,
  74. p2 as p3
  75. } from "./chunk-CIG5OHC7.js";
  76. import {
  77. P
  78. } from "./chunk-FUD7XO3N.js";
  79. import {
  80. g as g2
  81. } from "./chunk-RZFGRBD7.js";
  82. import {
  83. B,
  84. c as c3
  85. } from "./chunk-PUSPZYFZ.js";
  86. import {
  87. M as M2,
  88. j2 as j3
  89. } from "./chunk-EN7YGJWG.js";
  90. import {
  91. l as l4
  92. } from "./chunk-3D3QEPRE.js";
  93. import {
  94. K,
  95. b as b2
  96. } from "./chunk-UD63WBG3.js";
  97. import {
  98. L,
  99. b as b3,
  100. g,
  101. h,
  102. m as m3,
  103. y as y2
  104. } from "./chunk-X7DBH4KK.js";
  105. import {
  106. n as n3,
  107. t as t3
  108. } from "./chunk-BJHM4JNS.js";
  109. import {
  110. a as a2
  111. } from "./chunk-RMX2AZ4P.js";
  112. import {
  113. u
  114. } from "./chunk-NE3ESGA6.js";
  115. import {
  116. v as v4
  117. } from "./chunk-KHA63LLS.js";
  118. import {
  119. c as c2
  120. } from "./chunk-FGKNEJKJ.js";
  121. import {
  122. D,
  123. I,
  124. b as b4,
  125. c,
  126. d as d2,
  127. f,
  128. l as l3,
  129. m as m5,
  130. p,
  131. u as u2,
  132. v as v3
  133. } from "./chunk-PSV473TI.js";
  134. import {
  135. O
  136. } from "./chunk-I3OBGWNS.js";
  137. import {
  138. c as c5,
  139. m as m6
  140. } from "./chunk-WZQZRKNH.js";
  141. import {
  142. n as n4
  143. } from "./chunk-6A4U74YA.js";
  144. import {
  145. n as n5
  146. } from "./chunk-CYI7KFYB.js";
  147. import {
  148. a as a3
  149. } from "./chunk-5LXROFTA.js";
  150. import {
  151. t as t5
  152. } from "./chunk-W72F6AS3.js";
  153. import {
  154. fe,
  155. me
  156. } from "./chunk-O4FY3ITT.js";
  157. import {
  158. b as b5
  159. } from "./chunk-4DDBH2K5.js";
  160. import {
  161. t as t2
  162. } from "./chunk-ZOEK6QHJ.js";
  163. import {
  164. v2 as v
  165. } from "./chunk-OWVBLVP3.js";
  166. import {
  167. m as m4
  168. } from "./chunk-TBBTRX4O.js";
  169. import {
  170. m as m2
  171. } from "./chunk-YBSUITLL.js";
  172. import {
  173. j,
  174. n as n2
  175. } from "./chunk-ALDCDSPV.js";
  176. import {
  177. U
  178. } from "./chunk-VNFRAYHO.js";
  179. import {
  180. G,
  181. j as j2
  182. } from "./chunk-VBRY5KJM.js";
  183. import {
  184. s as s5
  185. } from "./chunk-PDKDCAAD.js";
  186. import {
  187. M2 as M,
  188. o as o2
  189. } from "./chunk-ECW2QABR.js";
  190. import {
  191. s as s4
  192. } from "./chunk-GCDJLKH4.js";
  193. import {
  194. k2 as k,
  195. r as r2
  196. } from "./chunk-MRJEICT6.js";
  197. import {
  198. d,
  199. e,
  200. l3 as l2,
  201. n2 as n,
  202. s2 as s3
  203. } from "./chunk-Y3WMVFTW.js";
  204. import {
  205. N,
  206. b
  207. } from "./chunk-IHXECKQQ.js";
  208. import {
  209. w,
  210. y
  211. } from "./chunk-ULGDPLM2.js";
  212. import {
  213. s,
  214. s3 as s2
  215. } from "./chunk-EMJ4ZSM2.js";
  216. import {
  217. m,
  218. o
  219. } from "./chunk-IKP3YN53.js";
  220. import {
  221. a,
  222. l,
  223. r,
  224. t
  225. } from "./chunk-GZT4BVFP.js";
  226. // node_modules/@arcgis/core/form/ExpressionInfo.js
  227. var s6;
  228. var p10 = s6 = class extends l2 {
  229. constructor(r6) {
  230. super(r6), this.expression = null, this.name = null, this.returnType = "boolean", this.title = null;
  231. }
  232. clone() {
  233. return new s6({ name: this.name, title: this.title, expression: this.expression, returnType: this.returnType });
  234. }
  235. };
  236. e([d({ type: String, json: { write: true } })], p10.prototype, "expression", void 0), e([d({ type: String, json: { write: true } })], p10.prototype, "name", void 0), e([d({ type: ["boolean", "date", "number", "string"], json: { write: true } })], p10.prototype, "returnType", void 0), e([d({ type: String, json: { write: true } })], p10.prototype, "title", void 0), p10 = s6 = e([n("esri.form.ExpressionInfo")], p10);
  237. var i3 = p10;
  238. // node_modules/@arcgis/core/form/elements/Element.js
  239. var e3 = class extends l2 {
  240. constructor(t8) {
  241. super(t8), this.description = null, this.label = null, this.type = null, this.visibilityExpression = null;
  242. }
  243. };
  244. e([d({ type: String, json: { write: true } })], e3.prototype, "description", void 0), e([d({ type: String, json: { write: true } })], e3.prototype, "label", void 0), e([d()], e3.prototype, "type", void 0), e([d({ type: String, json: { write: true } })], e3.prototype, "visibilityExpression", void 0), e3 = e([n("esri.form.elements.Element")], e3);
  245. var i4 = e3;
  246. // node_modules/@arcgis/core/form/elements/inputs/AttachmentInput.js
  247. var s7;
  248. var p11 = s7 = class extends l2 {
  249. constructor(r6) {
  250. super(r6), this.type = null;
  251. }
  252. clone() {
  253. return new s7({ type: this.type });
  254. }
  255. };
  256. e([d({ type: ["attachment", "audio", "document", "image", "signature", "video"], json: { write: true } })], p11.prototype, "type", void 0), p11 = s7 = e([n("esri.form.elements.inputs.AttachmentInput")], p11);
  257. var c6 = p11;
  258. // node_modules/@arcgis/core/form/elements/AttachmentElement.js
  259. var i5;
  260. var p12 = i5 = class extends i4 {
  261. constructor(t8) {
  262. super(t8), this.attachmentKeyword = null, this.editable = true, this.input = null, this.type = "attachment";
  263. }
  264. clone() {
  265. return new i5({ attachmentKeyword: this.attachmentKeyword, description: this.description, editable: this.editable, input: this.input, label: this.label, visibilityExpression: this.visibilityExpression });
  266. }
  267. };
  268. e([d({ type: String, json: { write: true } })], p12.prototype, "attachmentKeyword", void 0), e([d({ type: Boolean, json: { write: true } })], p12.prototype, "editable", void 0), e([d({ type: c6, json: { read: { source: "inputType" }, write: { target: "inputType" } } })], p12.prototype, "input", void 0), e([d({ type: ["attachment"], json: { read: false, write: true } })], p12.prototype, "type", void 0), p12 = i5 = e([n("esri.form.elements.AttachmentElement")], p12);
  269. var n8 = p12;
  270. // node_modules/@arcgis/core/form/elements/inputs/Input.js
  271. var e4 = class extends l2 {
  272. constructor(r6) {
  273. super(r6), this.type = null;
  274. }
  275. };
  276. e([d()], e4.prototype, "type", void 0), e4 = e([n("esri.form.elements.inputs.Input")], e4);
  277. var p13 = e4;
  278. // node_modules/@arcgis/core/form/elements/inputs/TextInput.js
  279. var e5 = class extends p13 {
  280. constructor(r6) {
  281. super(r6), this.maxLength = null, this.minLength = 0;
  282. }
  283. };
  284. e([d({ type: Number, json: { write: true } })], e5.prototype, "maxLength", void 0), e([d({ type: Number, json: { write: true } })], e5.prototype, "minLength", void 0), e5 = e([n("esri.form.elements.inputs.TextInput")], e5);
  285. var p14 = e5;
  286. // node_modules/@arcgis/core/form/elements/inputs/BarcodeScannerInput.js
  287. var o5;
  288. var c7 = o5 = class extends p14 {
  289. constructor(r6) {
  290. super(r6), this.type = "barcode-scanner";
  291. }
  292. clone() {
  293. return new o5({ maxLength: this.maxLength, minLength: this.minLength });
  294. }
  295. };
  296. e([d({ type: ["barcode-scanner"], json: { read: false, write: true } })], c7.prototype, "type", void 0), c7 = o5 = e([n("esri.form.elements.inputs.BarcodeScannerInput")], c7);
  297. var p15 = c7;
  298. // node_modules/@arcgis/core/form/elements/inputs/ComboBoxInput.js
  299. var s8;
  300. var p16 = s8 = class extends p13 {
  301. constructor(o7) {
  302. super(o7), this.noValueOptionLabel = null, this.showNoValueOption = false, this.type = "combo-box";
  303. }
  304. clone() {
  305. return new s8({ showNoValueOption: this.showNoValueOption, noValueOptionLabel: this.noValueOptionLabel });
  306. }
  307. };
  308. e([d({ type: String, json: { write: true } })], p16.prototype, "noValueOptionLabel", void 0), e([d({ type: Boolean, json: { write: true } })], p16.prototype, "showNoValueOption", void 0), e([d({ type: ["combo-box"], json: { read: false, write: true } })], p16.prototype, "type", void 0), p16 = s8 = e([n("esri.form.elements.inputs.ComboBoxInput")], p16);
  309. var i6 = p16;
  310. // node_modules/@arcgis/core/form/elements/inputs/DateTimePickerInput.js
  311. var s9;
  312. function n9(e6) {
  313. return e6 != null ? new Date(e6) : null;
  314. }
  315. function a5(e6) {
  316. return e6 ? e6.getTime() : null;
  317. }
  318. var m7 = s9 = class extends p13 {
  319. constructor(e6) {
  320. super(e6), this.includeTime = false, this.max = null, this.min = null, this.type = "datetime-picker";
  321. }
  322. readMax(e6, r6) {
  323. return n9(r6.max);
  324. }
  325. writeMax(e6, r6) {
  326. r6.max = a5(e6);
  327. }
  328. readMin(e6, r6) {
  329. return n9(r6.min);
  330. }
  331. writeMin(e6, r6) {
  332. r6.min = a5(e6);
  333. }
  334. clone() {
  335. return new s9({ includeTime: this.includeTime, max: this.max, min: this.min, type: this.type });
  336. }
  337. };
  338. e([d({ type: Boolean, json: { write: true } })], m7.prototype, "includeTime", void 0), e([d({ type: Date, json: { type: Number, write: true } })], m7.prototype, "max", void 0), e([o2("max")], m7.prototype, "readMax", null), e([r2("max")], m7.prototype, "writeMax", null), e([d({ type: Date, json: { type: Number, write: true } })], m7.prototype, "min", void 0), e([o2("min")], m7.prototype, "readMin", null), e([r2("min")], m7.prototype, "writeMin", null), e([d({ type: ["datetime-picker"], json: { read: false, write: true } })], m7.prototype, "type", void 0), m7 = s9 = e([n("esri.form.elements.inputs.DateTimePickerInput")], m7);
  339. var c8 = m7;
  340. // node_modules/@arcgis/core/form/elements/inputs/RadioButtonsInput.js
  341. var s10;
  342. var p17 = s10 = class extends p13 {
  343. constructor(o7) {
  344. super(o7), this.noValueOptionLabel = null, this.showNoValueOption = false, this.type = "radio-buttons";
  345. }
  346. clone() {
  347. return new s10({ noValueOptionLabel: this.noValueOptionLabel, showNoValueOption: this.showNoValueOption });
  348. }
  349. };
  350. e([d({ type: String, json: { write: true } })], p17.prototype, "noValueOptionLabel", void 0), e([d({ type: Boolean, json: { write: true } })], p17.prototype, "showNoValueOption", void 0), e([d({ type: ["radio-buttons"], json: { read: false, write: true } })], p17.prototype, "type", void 0), p17 = s10 = e([n("esri.form.elements.inputs.RadioButtonsInput")], p17);
  351. var i7 = p17;
  352. // node_modules/@arcgis/core/form/elements/inputs/SwitchInput.js
  353. var s11;
  354. var p18 = s11 = class extends p13 {
  355. constructor(o7) {
  356. super(o7), this.offValue = null, this.onValue = null, this.type = "switch";
  357. }
  358. clone() {
  359. return new s11({ offValue: this.offValue, onValue: this.onValue });
  360. }
  361. };
  362. e([d({ type: [String, Number], json: { write: true } })], p18.prototype, "offValue", void 0), e([d({ type: [String, Number], json: { write: true } })], p18.prototype, "onValue", void 0), e([d({ type: ["switch"], json: { read: false, write: true } })], p18.prototype, "type", void 0), p18 = s11 = e([n("esri.form.elements.inputs.SwitchInput")], p18);
  363. var i8 = p18;
  364. // node_modules/@arcgis/core/form/elements/inputs/TextAreaInput.js
  365. var o6;
  366. var p19 = o6 = class extends p14 {
  367. constructor(r6) {
  368. super(r6), this.type = "text-area";
  369. }
  370. clone() {
  371. return new o6({ maxLength: this.maxLength, minLength: this.minLength });
  372. }
  373. };
  374. e([d({ type: ["text-area"], json: { read: false, write: true } })], p19.prototype, "type", void 0), p19 = o6 = e([n("esri.form.elements.inputs.TextAreaInput")], p19);
  375. var a6 = p19;
  376. // node_modules/@arcgis/core/form/elements/inputs/TextBoxInput.js
  377. var s12;
  378. var p20 = s12 = class extends p14 {
  379. constructor(t8) {
  380. super(t8), this.type = "text-box";
  381. }
  382. clone() {
  383. return new s12({ maxLength: this.maxLength, minLength: this.minLength });
  384. }
  385. };
  386. e([d({ type: ["text-box"], json: { read: false, write: true } })], p20.prototype, "type", void 0), p20 = s12 = e([n("esri.form.elements.inputs.TextBoxInput")], p20);
  387. var c9 = p20;
  388. // node_modules/@arcgis/core/form/elements/support/inputs.js
  389. var m8 = { base: p13, key: "type", typeMap: { "barcode-scanner": p15, "combo-box": i6, "datetime-picker": c8, "radio-buttons": i7, switch: i8, "text-area": a6, "text-box": c9 } };
  390. // node_modules/@arcgis/core/form/elements/FieldElement.js
  391. var n10;
  392. var l6 = n10 = class extends i4 {
  393. constructor(e6) {
  394. super(e6), this.domain = null, this.editable = true, this.editableExpression = null, this.fieldName = null, this.hint = null, this.input = null, this.requiredExpression = null, this.type = "field", this.valueExpression = null;
  395. }
  396. clone() {
  397. return new n10({ description: this.description, domain: this.domain, editable: this.editable, editableExpression: this.editableExpression, fieldName: this.fieldName, hint: this.hint, input: this.input, label: this.label, requiredExpression: this.requiredExpression, valueExpression: this.valueExpression, visibilityExpression: this.visibilityExpression });
  398. }
  399. };
  400. e([d({ types: n3, json: { read: { reader: t3 }, write: true } })], l6.prototype, "domain", void 0), e([d({ type: Boolean, json: { write: true } })], l6.prototype, "editable", void 0), e([d({ type: String, json: { write: true } })], l6.prototype, "editableExpression", void 0), e([d({ type: String, json: { write: true } })], l6.prototype, "fieldName", void 0), e([d({ type: String, json: { write: true } })], l6.prototype, "hint", void 0), e([d({ types: m8, json: { read: { source: "inputType" }, write: { target: "inputType" } } })], l6.prototype, "input", void 0), e([d({ type: String, json: { write: true } })], l6.prototype, "requiredExpression", void 0), e([d({ type: String, json: { read: false, write: true } })], l6.prototype, "type", void 0), e([d({ type: String, json: { write: true } })], l6.prototype, "valueExpression", void 0), l6 = n10 = e([n("esri.form.elements.FieldElement")], l6);
  401. var a7 = l6;
  402. // node_modules/@arcgis/core/form/elements/RelationshipElement.js
  403. var p21;
  404. var l7 = p21 = class extends i4 {
  405. constructor(e6) {
  406. super(e6), this.displayCount = null, this.displayType = "list", this.editable = true, this.orderByFields = null, this.relationshipId = null, this.type = "relationship";
  407. }
  408. clone() {
  409. return new p21({ description: this.description, displayCount: this.displayCount, displayType: this.displayType, editable: this.editable, label: this.label, orderByFields: m(this.orderByFields), relationshipId: this.relationshipId, visibilityExpression: this.visibilityExpression });
  410. }
  411. };
  412. e([d({ type: Number, json: { write: true } })], l7.prototype, "displayCount", void 0), e([d({ type: ["list"], json: { write: true } })], l7.prototype, "displayType", void 0), e([d({ type: Boolean, json: { write: true } })], l7.prototype, "editable", void 0), e([d({ type: [c3], json: { write: true } })], l7.prototype, "orderByFields", void 0), e([d({ type: Number, json: { write: true } })], l7.prototype, "relationshipId", void 0), e([d({ type: ["relationship"], json: { read: false, write: true } })], l7.prototype, "type", void 0), l7 = p21 = e([n("esri.form.elements.RelationshipElement")], l7);
  413. var d5 = l7;
  414. // node_modules/@arcgis/core/form/support/elements.js
  415. function n11(t8) {
  416. return { typesWithGroup: { base: i4, key: "type", typeMap: { attachment: n8, field: a7, group: t8, relationship: d5 } }, typesWithoutGroup: { base: i4, key: "type", typeMap: { attachment: n8, field: a7, relationship: d5 } } };
  417. }
  418. function i9(t8, e6, p23 = true) {
  419. if (!t8)
  420. return null;
  421. const r6 = p23 ? e6.typesWithGroup.typeMap : e6.typesWithoutGroup.typeMap;
  422. return t8.filter((t9) => r6[t9.type]).map((t9) => r6[t9.type].fromJSON(t9));
  423. }
  424. function u4(t8, e6, p23 = true) {
  425. if (!t8)
  426. return null;
  427. const r6 = p23 ? e6.typesWithGroup.typeMap : e6.typesWithoutGroup.typeMap;
  428. return t8.filter((t9) => r6[t9.type]).map((t9) => t9.toJSON());
  429. }
  430. function s13(e6, p23, r6 = true) {
  431. return e6 ? e6.map((e7) => N(r6 ? p23.typesWithGroup : p23.typesWithoutGroup, e7)) : null;
  432. }
  433. // node_modules/@arcgis/core/form/elements/GroupElement.js
  434. var d6;
  435. var u5 = d6 = class extends i4 {
  436. constructor(e6) {
  437. super(e6), this.elements = null, this.initialState = "expanded", this.type = "group";
  438. }
  439. castElements(e6) {
  440. return s13(e6, f2, false);
  441. }
  442. readElements(e6, t8) {
  443. return i9(t8.formElements, f2, false);
  444. }
  445. writeElements(e6, t8) {
  446. t8.formElements = u4(e6, f2, false);
  447. }
  448. clone() {
  449. return new d6({ description: this.description, elements: m(this.elements), initialState: this.initialState, label: this.label, visibilityExpression: this.visibilityExpression });
  450. }
  451. };
  452. e([d({ json: { write: true } })], u5.prototype, "elements", void 0), e([s4("elements")], u5.prototype, "castElements", null), e([o2("elements", ["formElements"])], u5.prototype, "readElements", null), e([r2("elements")], u5.prototype, "writeElements", null), e([d({ type: ["collapsed", "expanded"], json: { write: true } })], u5.prototype, "initialState", void 0), e([d({ type: String, json: { read: false, write: true } })], u5.prototype, "type", void 0), u5 = d6 = e([n("esri.form.elements.GroupElement")], u5);
  453. var f2 = n11(u5);
  454. var y3 = u5;
  455. // node_modules/@arcgis/core/form/FormTemplate.js
  456. var d7;
  457. var j5 = n11(y3);
  458. var y4 = d7 = class extends l2 {
  459. constructor(e6) {
  460. super(e6), this.description = null, this.elements = null, this.expressionInfos = null, this.title = null;
  461. }
  462. castElements(e6) {
  463. return s13(e6, j5);
  464. }
  465. readElements(e6, t8) {
  466. return i9(t8.formElements, j5);
  467. }
  468. writeElements(e6, t8) {
  469. t8.formElements = u4(e6, j5);
  470. }
  471. clone() {
  472. return new d7({ description: this.description, expressionInfos: m(this.expressionInfos), elements: m(this.elements), title: this.title });
  473. }
  474. };
  475. e([d({ type: String, json: { write: true } })], y4.prototype, "description", void 0), e([d({ json: { write: true } })], y4.prototype, "elements", void 0), e([s4("elements")], y4.prototype, "castElements", null), e([o2("elements", ["formElements"])], y4.prototype, "readElements", null), e([r2("elements")], y4.prototype, "writeElements", null), e([d({ type: [i3], json: { write: true } })], y4.prototype, "expressionInfos", void 0), e([d({ type: String, json: { write: true } })], y4.prototype, "title", void 0), y4 = d7 = e([n("esri.form.FormTemplate")], y4);
  476. var E = y4;
  477. // node_modules/@arcgis/core/layers/graphics/sources/MemorySource.js
  478. var T = 0;
  479. var F = s.getLogger("esri.layers.graphics.sources.MemorySource");
  480. var G2 = class extends m4.LoadableMixin(m2(a2(j))) {
  481. constructor(e6) {
  482. super(e6), this._idToClientGraphic = null, this.type = "memory";
  483. }
  484. load(e6) {
  485. const t8 = r(e6) ? e6.signal : null;
  486. return this.addResolvingPromise(this._startWorker(t8)), Promise.resolve(this);
  487. }
  488. destroy() {
  489. this._connection?.close(), this._connection = null;
  490. }
  491. get workerGeometryType() {
  492. const e6 = this.layer?.geometryType;
  493. return e6 ? this._geometryTypeRequiresClientGraphicMapping(e6) ? "polygon" : e6 : null;
  494. }
  495. applyEdits(e6) {
  496. return this.load().then(() => this._applyEdits(e6));
  497. }
  498. openPorts() {
  499. return this.load().then(() => this._connection.openPorts());
  500. }
  501. async queryFeatures(e6, t8 = {}) {
  502. await this.load(t8);
  503. const r6 = await this._connection.invoke("queryFeatures", e6 ? e6.toJSON() : null, t8);
  504. r3(e6, this.layer.spatialReference, r6);
  505. const s14 = x.fromJSON(r6);
  506. if (!this._requiresClientGraphicMapping())
  507. return s14;
  508. const o7 = this.layer.objectIdField;
  509. for (const i10 of s14.features) {
  510. const e7 = i10.attributes[o7], t9 = this._idToClientGraphic.get(e7);
  511. t9 && (i10.geometry = t9.geometry);
  512. }
  513. return s14.geometryType = this.layer.geometryType, s14;
  514. }
  515. async queryFeaturesJSON(e6, t8 = {}) {
  516. if (this._requiresClientGraphicMapping())
  517. throw new s2("query-features-json:unsupported", "Cannot query in JSON format for client only geometry types (mesh and extent)");
  518. await this.load(t8);
  519. const r6 = await this._connection.invoke("queryFeatures", e6 ? e6.toJSON() : null, t8);
  520. return r3(e6, this.layer.spatialReference, r6), r6;
  521. }
  522. queryFeatureCount(e6, t8 = {}) {
  523. return this.load(t8).then(() => this._connection.invoke("queryFeatureCount", e6 ? e6.toJSON() : null, t8));
  524. }
  525. queryObjectIds(e6, t8 = {}) {
  526. return this.load(t8).then(() => this._connection.invoke("queryObjectIds", e6 ? e6.toJSON() : null, t8));
  527. }
  528. queryExtent(e6, t8 = {}) {
  529. return this.load(t8).then(() => this._connection.invoke("queryExtent", e6 ? e6.toJSON() : null, t8)).then((e7) => ({ count: e7.count, extent: M.fromJSON(e7.extent) }));
  530. }
  531. querySnapping(e6, t8 = {}) {
  532. return this.load(t8).then(() => this._connection.invoke("querySnapping", e6, t8));
  533. }
  534. async _applyEdits(e6) {
  535. if (!this._connection)
  536. throw new s2("feature-layer-source:edit-failure", "Memory source not loaded");
  537. const t8 = this.layer.objectIdField;
  538. let r6 = null;
  539. const o7 = [], i10 = [];
  540. await Promise.all([this._prepareClientMapping(e6.addFeatures, null), this._prepareClientMapping(e6.updateFeatures, null)]);
  541. const n13 = (e7) => "objectId" in e7 && e7.objectId != null ? e7.objectId : "attributes" in e7 && e7.attributes[t8] != null ? e7.attributes[t8] : null;
  542. if (e6.addFeatures && (r6 = this._prepareAddFeatures(e6.addFeatures)), e6.deleteFeatures)
  543. for (const s14 of e6.deleteFeatures) {
  544. const e7 = n13(s14);
  545. e7 != null && o7.push(e7);
  546. }
  547. const a10 = e6.updateFeatures && this._idToClientGraphic ? new Map() : null;
  548. if (e6.updateFeatures) {
  549. for (const s14 of e6.updateFeatures)
  550. if (i10.push(this._serializeFeature(s14)), a10) {
  551. const e7 = n13(s14);
  552. e7 != null && a10.set(e7, s14);
  553. }
  554. }
  555. i(r6 ? r6.features : null, i10, this.layer.spatialReference);
  556. const { fullExtent: l9, featureEditResults: u6 } = await this._connection.invoke("applyEdits", { adds: r6 ? r6.features : [], updates: i10, deletes: o7 });
  557. return this.fullExtent = l9, r6 && r6.finish(u6.uidToObjectId), this._updateClientGraphicIds(a10, u6), this._createEditsResult(u6);
  558. }
  559. async _prepareClientMapping(e6, t8) {
  560. if (this.layerOrSourceGeometryType !== "mesh" || t(e6))
  561. return;
  562. const r6 = [];
  563. for (const { geometry: s14 } of e6)
  564. !r(s14) || s14.type !== "mesh" || s14.hasExtent || s14.loaded || r6.push(s14.load({ signal: t8 }));
  565. r6.length && await Promise.all(r6);
  566. }
  567. _updateClientGraphicIds(e6, t8) {
  568. if (this._idToClientGraphic) {
  569. if (e6)
  570. for (const r6 of t8.updateResults) {
  571. if (!r6.success)
  572. continue;
  573. const t9 = e6.get(r6.objectId);
  574. t9 != null && this._addIdToClientGraphic(t9);
  575. }
  576. for (const e7 of t8.deleteResults)
  577. e7.success && this._idToClientGraphic.delete(e7.objectId);
  578. }
  579. }
  580. _createEditsResult(e6) {
  581. return { addFeatureResults: e6.addResults ? e6.addResults.map(this._createFeatureEditResult, this) : [], updateFeatureResults: e6.updateResults ? e6.updateResults.map(this._createFeatureEditResult, this) : [], deleteFeatureResults: e6.deleteResults ? e6.deleteResults.map(this._createFeatureEditResult, this) : [], addAttachmentResults: [], updateAttachmentResults: [], deleteAttachmentResults: [] };
  582. }
  583. _createFeatureEditResult(e6) {
  584. const t8 = e6.success === true ? null : e6.error || { code: void 0, description: void 0 };
  585. return { objectId: e6.objectId, globalId: e6.globalId, error: t8 ? new s2("feature-layer-source:edit-failure", t8.description, { code: t8.code }) : null };
  586. }
  587. _prepareAddFeatures(e6) {
  588. const t8 = new Map(), r6 = new Array(e6.length);
  589. let s14 = null;
  590. for (let i10 = 0; i10 < e6.length; i10++) {
  591. const o8 = e6[i10], n13 = this._serializeFeature(o8);
  592. !s14 && r(o8.geometry) && (s14 = o8.geometry.type), r6[i10] = n13, t8.set(`${n13.uid}`, o8);
  593. }
  594. const o7 = this;
  595. return { features: r6, inferredGeometryType: s14, finish(e7) {
  596. const r7 = o7.sourceJSON.objectIdField;
  597. for (const s15 in e7) {
  598. const i10 = e7[s15], n13 = t8.get(s15);
  599. n13 && (n13.attributes || (n13.attributes = {}), i10 === -1 ? delete n13.attributes[r7] : n13.attributes[r7] = i10, o7._addIdToClientGraphic(n13));
  600. }
  601. } };
  602. }
  603. _addIdToClientGraphic(e6) {
  604. if (!this._idToClientGraphic)
  605. return;
  606. const t8 = this.sourceJSON.objectIdField, r6 = e6.attributes && e6.attributes[t8];
  607. r6 != null && this._idToClientGraphic.set(r6, e6);
  608. }
  609. get layerOrSourceGeometryType() {
  610. return this.layer?.geometryType ?? this.sourceJSON?.geometryType;
  611. }
  612. _requiresClientGraphicMapping() {
  613. return this._geometryTypeRequiresClientGraphicMapping(this.layerOrSourceGeometryType);
  614. }
  615. _geometryRequiresClientGraphicMapping(e6) {
  616. return this._geometryTypeRequiresClientGraphicMapping(e6.type);
  617. }
  618. _geometryTypeRequiresClientGraphicMapping(e6) {
  619. return e6 === "mesh" || e6 === "multipatch" || e6 === "extent";
  620. }
  621. _serializeFeature(e6) {
  622. const { attributes: t8 } = e6, r6 = this._geometryForSerialization(e6), s14 = (T++).toString();
  623. return r6 ? { uid: s14, geometry: r6.toJSON(), attributes: t8 } : { uid: s14, attributes: t8 };
  624. }
  625. _geometryForSerialization(e6) {
  626. const { geometry: t8 } = e6;
  627. if (t(t8))
  628. return null;
  629. if (this._geometryRequiresClientGraphicMapping(t8)) {
  630. return t8.extent ? v.fromExtent(t8.extent) : null;
  631. }
  632. return t8;
  633. }
  634. async _startWorker(e6) {
  635. this._connection = await u3("MemorySourceWorker", { strategy: a("feature-layers-workers") ? "dedicated" : "local", signal: e6 });
  636. const { fields: t8, spatialReference: r6, objectIdField: s14, hasM: o7, hasZ: n13, timeInfo: a10 } = this.layer, l9 = this.layer.originOf("spatialReference") === "defaults";
  637. await this._prepareClientMapping(this.items, e6);
  638. const u6 = this._prepareAddFeatures(this.items);
  639. this.handles.add(this.on("before-changes", (e7) => {
  640. F.error("Source modifications will not propagate after layer has been loaded. Please use .applyEdits() instead"), e7.preventDefault();
  641. }));
  642. const p23 = { features: u6.features, fields: t8 && t8.map((e7) => e7.toJSON()), geometryType: t2.toJSON(this.workerGeometryType), hasM: this.layerOrSourceGeometryType !== "mesh" && o7, hasZ: this.layerOrSourceGeometryType === "mesh" || n13, objectIdField: s14, spatialReference: l9 ? null : r6 && r6.toJSON(), timeInfo: a10 ? a10.toJSON() : null }, d8 = await this._connection.invoke("load", p23, { signal: e6 });
  643. for (const i10 of d8.warnings)
  644. F.warn(i10.message, { layer: this.layer, warning: i10 });
  645. d8.featureErrors.length && F.warn(`Encountered ${d8.featureErrors.length} validation errors while loading features`, d8.featureErrors);
  646. const h2 = d8.layerDefinition;
  647. this._geometryTypeRequiresClientGraphicMapping(u6.inferredGeometryType) && (h2.geometryType = t2.toJSON(u6.inferredGeometryType)), this.sourceJSON = h2, this._requiresClientGraphicMapping() && (this._idToClientGraphic = new Map()), u6.finish(d8.assignedObjectIds);
  648. }
  649. };
  650. e([n2({ Type: g2, ensureType: b(g2) })], G2.prototype, "itemType", void 0), e([d()], G2.prototype, "type", void 0), e([d({ constructOnly: true })], G2.prototype, "layer", void 0), e([d({ readOnly: true })], G2.prototype, "workerGeometryType", null), e([d()], G2.prototype, "sourceJSON", void 0), G2 = e([n("esri.layers.graphics.sources.MemorySource")], G2);
  651. // node_modules/@arcgis/core/layers/support/FeatureIndex.js
  652. var t7;
  653. var c10 = t7 = class extends l2 {
  654. constructor(o7) {
  655. super(o7);
  656. }
  657. clone() {
  658. const { name: o7, fields: r6, isAscending: s14, isUnique: e6, description: c12 } = this;
  659. return new t7({ name: o7, fields: r6, isAscending: s14, isUnique: e6, description: c12 });
  660. }
  661. };
  662. e([d({ constructOnly: true })], c10.prototype, "name", void 0), e([d({ constructOnly: true })], c10.prototype, "fields", void 0), e([d({ constructOnly: true })], c10.prototype, "isAscending", void 0), e([d({ constructOnly: true })], c10.prototype, "isUnique", void 0), e([d({ constructOnly: true })], c10.prototype, "description", void 0), c10 = t7 = e([n("esri.layers.support.FeatureIndex")], c10);
  663. // node_modules/@arcgis/core/layers/support/GeometryFieldsInfo.js
  664. var a8 = class extends l4(l2) {
  665. constructor(e6) {
  666. super(e6), this.shapeAreaField = null, this.shapeLengthField = null, this.units = null;
  667. }
  668. };
  669. e([d({ type: String, json: { read: { source: "shapeAreaFieldName" } } })], a8.prototype, "shapeAreaField", void 0), e([d({ type: String, json: { read: { source: "shapeLengthFieldName" } } })], a8.prototype, "shapeLengthField", void 0), e([d({ type: String, json: { read: (e6) => me.read(e6) || fe.read(e6) } })], a8.prototype, "units", void 0), a8 = e([n("esri.layers.support.GeometryFieldsInfo")], a8);
  670. var c11 = a8;
  671. // node_modules/@arcgis/core/layers/support/Relationship.js
  672. var a9 = new s5({ esriRelCardinalityOneToOne: "one-to-one", esriRelCardinalityOneToMany: "one-to-many", esriRelCardinalityManyToMany: "many-to-many" });
  673. var n12 = new s5({ esriRelRoleOrigin: "origin", esriRelRoleDestination: "destination" });
  674. var l8 = class extends l4(l2) {
  675. constructor(e6) {
  676. super(e6), this.cardinality = null, this.composite = null, this.id = null, this.keyField = null, this.keyFieldInRelationshipTable = null, this.name = null, this.relatedTableId = null, this.relationshipTableId = null, this.role = null;
  677. }
  678. };
  679. e([d({ json: { read: a9.read, write: a9.write } })], l8.prototype, "cardinality", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "composite", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "id", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "keyField", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "keyFieldInRelationshipTable", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "name", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "relatedTableId", void 0), e([d({ json: { read: true, write: true } })], l8.prototype, "relationshipTableId", void 0), e([d({ json: { read: n12.read, write: n12.write } })], l8.prototype, "role", void 0), l8 = e([n("esri.layers.support.Relationship")], l8);
  680. var p22 = l8;
  681. // node_modules/@arcgis/core/layers/FeatureLayer.js
  682. var qe = new s5({ esriGeometryPoint: "point", esriGeometryMultipoint: "multipoint", esriGeometryPolyline: "polyline", esriGeometryPolygon: "polygon", esriGeometryMultiPatch: "multipatch" });
  683. var Qe = { name: "supportsName", size: "supportsSize", contentType: "supportsContentType", keywords: "supportsKeywords", exifInfo: "supportsExifInfo" };
  684. var Ue = "FeatureLayer";
  685. var Ge = s.getLogger("esri.layers.FeatureLayer");
  686. function Ve(e6, t8) {
  687. return new s2("layer:unsupported", `Layer (${e6.title}, ${e6.id}) of type '${e6.declaredClass}' ${t8}`, { layer: e6 });
  688. }
  689. function ze(e6) {
  690. return e6 && e6 instanceof j;
  691. }
  692. function Be(e6, t8, r6) {
  693. return !!(e6 && e6.hasOwnProperty(t8) ? e6[t8] : r6);
  694. }
  695. function ke(e6, t8, r6) {
  696. return e6 && e6.hasOwnProperty(t8) ? e6[t8] : r6;
  697. }
  698. function Ne(e6) {
  699. const t8 = e6?.supportedSpatialAggregationStatistics?.map((e7) => e7.toLowerCase());
  700. return { envelope: !!t8?.includes("envelopeaggregate"), centroid: !!t8?.includes("centroidaggregate"), convexHull: !!t8?.includes("convexhullaggregate") };
  701. }
  702. function We(e6, t8) {
  703. const r6 = e6?.supportedOperationsWithCacheHint?.map((e7) => e7.toLowerCase());
  704. return !!r6?.includes(t8.toLowerCase());
  705. }
  706. var He = l5();
  707. function Je(e6, t8, r6) {
  708. const i10 = !!r6?.writeLayerSchema;
  709. return { enabled: i10, ignoreOrigin: i10 };
  710. }
  711. var Ze = class extends p5(a3(p6(a4(t5(n5(p4(c2(v4(O(o4(i2(l4(b5))))))))))))) {
  712. constructor(...e6) {
  713. super(...e6), this._handles = new u(), this.capabilities = null, this.charts = null, this.copyright = null, this.datesInUnknownTimezone = false, this.displayField = null, this.definitionExpression = null, this.dynamicDataSource = null, this.editFieldsInfo = null, this.editingInfo = null, this.elevationInfo = null, this.featureReduction = null, this.fields = null, this.fieldsIndex = null, this.floorInfo = null, this.formTemplate = null, this.fullExtent = null, this.gdbVersion = null, this.geometryFieldsInfo = null, this.geometryType = null, this.hasM = void 0, this.hasZ = void 0, this.heightModelInfo = null, this.historicMoment = null, this.infoFor3D = null, this.isTable = false, this.labelsVisible = true, this.labelingInfo = null, this.layerId = void 0, this.legendEnabled = true, this.minScale = 0, this.maxScale = 0, this.globalIdField = null, this.objectIdField = null, this.outFields = null, this.path = null, this.popupEnabled = true, this.popupTemplate = null, this.relationships = null, this.sourceJSON = null, this.returnM = void 0, this.returnZ = void 0, this.screenSizePerspectiveEnabled = true, this.serviceDefinitionExpression = null, this.spatialReference = k.WGS84, this.subtypeCode = null, this.subtypeField = null, this.templates = null, this.timeInfo = null, this.title = null, this.sublayerTitleMode = "item-title", this.trackIdField = null, this.type = "feature", this.typeIdField = null, this.types = null, this.indexes = new (j.ofType(c10))(), this.userIsAdmin = false, this.version = void 0, this.visible = true;
  714. }
  715. destroy() {
  716. this.source?.destroy(), this._handles = l(this._handles);
  717. }
  718. normalizeCtorArgs(e6, t8) {
  719. return typeof e6 == "string" ? { url: e6, ...t8 } : e6;
  720. }
  721. load(e6) {
  722. const t8 = r(e6) ? e6.signal : null;
  723. if (this.portalItem && this.portalItem.loaded && this.source)
  724. return void this.addResolvingPromise(this.createGraphicsSource(t8).then((e7) => this._initLayerProperties(e7)));
  725. const r6 = this.loadFromPortal({ supportedTypes: ["Feature Service", "Feature Collection"] }, e6).catch(w).then(async () => {
  726. if (this.url && this.layerId == null && /FeatureServer|MapServer\/*$/i.test(this.url)) {
  727. const e7 = await this._fetchFirstLayerId(t8);
  728. e7 != null && (this.layerId = e7);
  729. }
  730. if (!this.url && !this._hasMemorySource())
  731. throw new s2("feature-layer:missing-url-or-source", "Feature layer must be created with either a url or a source");
  732. return this._initLayerProperties(await this.createGraphicsSource(t8));
  733. }).then(() => this.finishLoadEditablePortalLayer(e6));
  734. return this.addResolvingPromise(r6), Promise.resolve(this);
  735. }
  736. readCapabilities(e6, t8) {
  737. return t8 = t8.layerDefinition || t8, { analytics: this._readAnalyticsCapabilities(t8), attachment: this._readAttachmentCapabilities(t8), data: this._readDataCapabilities(t8), metadata: this._readMetadataCapabilities(t8), operations: this._readOperationsCapabilities(t8.capabilities || e6, t8), query: this._readQueryCapabilities(t8), queryRelated: this._readQueryRelatedCapabilities(t8), queryTopFeatures: this._readQueryTopFeaturesCapabilities(t8), editing: this._readEditingCapabilities(t8) };
  738. }
  739. get createQueryVersion() {
  740. return this.commitProperty("definitionExpression"), this.commitProperty("dynamicDataSource"), this.commitProperty("timeExtent"), this.commitProperty("timeOffset"), this.commitProperty("geometryType"), this.commitProperty("gdbVersion"), this.commitProperty("historicMoment"), this.commitProperty("returnZ"), this.commitProperty("capabilities"), this.commitProperty("returnM"), (this._get("createQueryVersion") || 0) + 1;
  741. }
  742. get editingEnabled() {
  743. return !(this.loaded && !this.capabilities.operations.supportsEditing) && (this._isOverridden("editingEnabled") ? this._get("editingEnabled") : this._hasMemorySource() || this.userHasEditingPrivileges);
  744. }
  745. set editingEnabled(e6) {
  746. e6 != null ? this._override("editingEnabled", e6) : this._clearOverride("editingEnabled");
  747. }
  748. readEditingEnabled(e6, t8) {
  749. return this._readEditingEnabled(t8, false);
  750. }
  751. readEditingEnabledFromWebMap(e6, t8, r6) {
  752. return this._readEditingEnabled(t8, true, r6);
  753. }
  754. writeEditingEnabled(e6, t8) {
  755. this._writeEditingEnabled(e6, t8, false);
  756. }
  757. writeEditingEnabledToWebMap(e6, t8, r6, i10) {
  758. this._writeEditingEnabled(e6, t8, true, i10);
  759. }
  760. readEditingInfo(e6, t8) {
  761. const { editingInfo: r6 } = t8;
  762. return r6 ? { lastEditDate: r6.lastEditDate != null ? new Date(r6.lastEditDate) : null } : null;
  763. }
  764. readIsTable(e6, t8) {
  765. return (t8 = t8 && t8.layerDefinition || t8).type === "Table" || !t8.geometryType;
  766. }
  767. writeIsTable(e6, t8, r6, i10) {
  768. i10?.writeLayerSchema && o(r6, e6 ? "Table" : "Feature Layer", t8);
  769. }
  770. readMinScale(e6, t8) {
  771. return t8.effectiveMinScale || e6 || 0;
  772. }
  773. readMaxScale(e6, t8) {
  774. return t8.effectiveMaxScale || e6 || 0;
  775. }
  776. readGlobalIdFieldFromService(e6, t8) {
  777. if ((t8 = t8.layerDefinition || t8).globalIdField)
  778. return t8.globalIdField;
  779. if (t8.fields) {
  780. for (const r6 of t8.fields)
  781. if (r6.type === "esriFieldTypeGlobalID")
  782. return r6.name;
  783. }
  784. }
  785. readObjectIdFieldFromService(e6, t8) {
  786. if ((t8 = t8.layerDefinition || t8).objectIdField)
  787. return t8.objectIdField;
  788. if (t8.fields) {
  789. for (const r6 of t8.fields)
  790. if (r6.type === "esriFieldTypeOID")
  791. return r6.name;
  792. }
  793. }
  794. get parsedUrl() {
  795. const e6 = this.url ? j2(this.url) : null;
  796. return e6 != null && (this.dynamicDataSource != null ? e6.path = G(e6.path, "dynamicLayer") : this.layerId != null && (e6.path = G(e6.path, this.layerId.toString()))), e6;
  797. }
  798. get defaultPopupTemplate() {
  799. return this.createPopupTemplate();
  800. }
  801. set renderer(e6) {
  802. c5(e6, this.fieldsIndex), this._set("renderer", e6);
  803. }
  804. readRenderer(e6, t8, s14) {
  805. const a10 = (t8 = t8.layerDefinition || t8).drawingInfo && t8.drawingInfo.renderer || void 0;
  806. if (a10) {
  807. const e7 = o3(a10, t8, s14) || void 0;
  808. return e7 || Ge.error("Failed to create renderer", { rendererDefinition: t8.drawingInfo.renderer, layer: this, context: s14 }), e7;
  809. }
  810. if (t8.defaultSymbol)
  811. return t8.types && t8.types.length ? new P({ defaultSymbol: $e(t8.defaultSymbol, t8, s14), field: t8.typeIdField, uniqueValueInfos: t8.types.map((e7) => ({ id: e7.id, symbol: $e(e7.symbol, e7, s14) })) }) : new p2({ symbol: $e(t8.defaultSymbol, t8, s14) });
  812. }
  813. set source(e6) {
  814. const t8 = this._get("source");
  815. t8 !== e6 && (ze(t8) && this._resetMemorySource(t8), ze(e6) && this._initMemorySource(e6), this._set("source", e6));
  816. }
  817. castSource(e6) {
  818. return e6 ? Array.isArray(e6) || e6 instanceof j ? new G2({ layer: this, items: e6 }) : e6 : null;
  819. }
  820. readSource(e6, t8) {
  821. const r6 = x.fromJSON(t8.featureSet);
  822. return new G2({ layer: this, items: r6 && r6.features || [] });
  823. }
  824. readServiceDefinitionExpression(e6, t8) {
  825. return t8.definitionQuery || t8.definitionExpression;
  826. }
  827. readTemplates(e6, t8) {
  828. const r6 = t8.editFieldsInfo, i10 = r6 && r6.creatorField, o7 = r6 && r6.editorField;
  829. return e6 = e6 && e6.map((e7) => p8.fromJSON(e7)), this._fixTemplates(e6, i10), this._fixTemplates(e6, o7), e6;
  830. }
  831. readTitle(e6, t8) {
  832. const r6 = t8.layerDefinition && t8.layerDefinition.name || t8.name, i10 = t8.title || t8.layerDefinition && t8.layerDefinition.title;
  833. if (r6) {
  834. const e7 = this.portalItem && this.portalItem.title;
  835. if (this.sublayerTitleMode === "item-title")
  836. return this.url ? y2(this.url, r6) : r6;
  837. let t9 = r6;
  838. if (!t9 && this.url) {
  839. const e8 = m3(this.url);
  840. r(e8) && (t9 = e8.title);
  841. }
  842. if (!t9)
  843. return;
  844. return this.sublayerTitleMode === "item-title-and-service-name" && e7 && e7 !== t9 && (t9 = e7 + " - " + t9), h(t9);
  845. }
  846. if (this.sublayerTitleMode === "item-title" && i10)
  847. return i10;
  848. }
  849. readTitleFromWebMap(e6, t8) {
  850. return t8.title || t8.layerDefinition && t8.layerDefinition.name;
  851. }
  852. readTypeIdField(e6, t8) {
  853. let r6 = (t8 = t8.layerDefinition || t8).typeIdField;
  854. if (r6 && t8.fields) {
  855. r6 = r6.toLowerCase();
  856. const e7 = t8.fields.find((e8) => e8.name.toLowerCase() === r6);
  857. e7 && (r6 = e7.name);
  858. }
  859. return r6;
  860. }
  861. readTypes(e6, t8) {
  862. e6 = (t8 = t8.layerDefinition || t8).types;
  863. const r6 = t8.editFieldsInfo, i10 = r6 && r6.creatorField, o7 = r6 && r6.editorField;
  864. return e6 && e6.map((e7) => (e7 = n7.fromJSON(e7), this._fixTemplates(e7.templates, i10), this._fixTemplates(e7.templates, o7), e7));
  865. }
  866. set url(e6) {
  867. const t8 = L({ layer: this, url: e6, nonStandardUrlAllowed: true, logger: Ge });
  868. this._set("url", t8.url), t8.layerId != null && this._set("layerId", t8.layerId);
  869. }
  870. writeUrl(e6, t8, r6, i10) {
  871. b3(this, e6, null, t8, i10);
  872. }
  873. readVersion(e6, t8) {
  874. return t8.currentVersion ? t8.currentVersion : t8.hasOwnProperty("capabilities") || t8.hasOwnProperty("drawingInfo") || t8.hasOwnProperty("hasAttachments") || t8.hasOwnProperty("htmlPopupType") || t8.hasOwnProperty("relationships") || t8.hasOwnProperty("timeInfo") || t8.hasOwnProperty("typeIdField") || t8.hasOwnProperty("types") ? 10 : 9.3;
  875. }
  876. readVisible(e6, t8) {
  877. return t8.layerDefinition && t8.layerDefinition.defaultVisibility != null ? !!t8.layerDefinition.defaultVisibility : t8.visibility != null ? !!t8.visibility : void 0;
  878. }
  879. addAttachment(e6, t8) {
  880. return this.load().then(() => this._checkAttachmentSupport(e6)).then(() => {
  881. if (!("addAttachment" in this.source))
  882. throw new s2(Ue, "Layer source does not support addAttachment capability");
  883. return this.source.addAttachment(e6, t8);
  884. });
  885. }
  886. updateAttachment(e6, t8, r6) {
  887. return this.load().then(() => this._checkAttachmentSupport(e6)).then(() => {
  888. if (!("updateAttachment" in this.source))
  889. throw new s2(Ue, "Layer source does not support updateAttachment capability");
  890. return this.source.updateAttachment(e6, t8, r6);
  891. });
  892. }
  893. async applyEdits(e6, t8) {
  894. const r6 = await import("./editingSupport-KL4E3VVF.js");
  895. return await this.load(), r6.applyEdits(this, this.source, e6, t8);
  896. }
  897. on(e6, t8) {
  898. return super.on(e6, t8);
  899. }
  900. createPopupTemplate(e6) {
  901. return d4(this, e6);
  902. }
  903. async createGraphicsSource(e6) {
  904. if (this._hasMemorySource())
  905. return this.source.load({ signal: e6 });
  906. const { default: t8 } = await y(import("./FeatureLayerSource-B6VXBL6Z.js"), e6);
  907. return new t8({ layer: this }).load({ signal: e6 });
  908. }
  909. createQuery() {
  910. const e6 = new b2(), t8 = this.get("capabilities.data"), r6 = this.get("capabilities.query");
  911. e6.dynamicDataSource = this.dynamicDataSource, e6.historicMoment = this.historicMoment, e6.gdbVersion = this.gdbVersion, e6.returnGeometry = true, r6 && (e6.compactGeometryEnabled = r6.supportsCompactGeometry, e6.defaultSpatialReferenceEnabled = r6.supportsDefaultSpatialReference), t8 && (t8.supportsZ && this.returnZ != null && (e6.returnZ = this.returnZ), t8.supportsM && this.returnM != null && (e6.returnM = this.returnM)), e6.outFields = ["*"];
  912. const i10 = r(this.subtypeCode) ? `${this.subtypeField} = ${this.subtypeCode}` : null, o7 = t6(this.definitionExpression, i10);
  913. e6.where = o7 || "1=1";
  914. const { timeOffset: s14, timeExtent: a10 } = this;
  915. return e6.timeExtent = s14 != null && a10 != null ? a10.offset(-s14.value, s14.unit) : a10 || null, e6.multipatchOption = this.geometryType === "multipatch" ? "xyFootprint" : null, e6;
  916. }
  917. deleteAttachments(e6, t8) {
  918. return this.load().then(() => this._checkAttachmentSupport(e6)).then(() => {
  919. if (!("deleteAttachments" in this.source))
  920. throw new s2(Ue, "Layer source does not support deleteAttachments capability");
  921. return this.source.deleteAttachments(e6, t8);
  922. });
  923. }
  924. fetchRecomputedExtents(e6) {
  925. return this.load({ signal: e6?.signal }).then(() => {
  926. if (this.source.fetchRecomputedExtents)
  927. return this.source.fetchRecomputedExtents(e6);
  928. throw new s2(Ue, "Layer source does not support fetchUpdates capability");
  929. });
  930. }
  931. getFeatureType(e6) {
  932. const { typeIdField: t8, types: r6 } = this;
  933. if (!t8 || !e6)
  934. return null;
  935. const i10 = e6.attributes ? e6.attributes[t8] : void 0;
  936. if (i10 == null)
  937. return null;
  938. let o7 = null;
  939. return r6.some((e7) => {
  940. const { id: t9 } = e7;
  941. return t9 != null && (t9.toString() === i10.toString() && (o7 = e7), !!o7);
  942. }), o7;
  943. }
  944. getFieldDomain(e6, t8) {
  945. const r6 = t8 && t8.feature, i10 = this.getFeatureType(r6);
  946. if (i10) {
  947. const t9 = i10.domains && i10.domains[e6];
  948. if (t9 && t9.type !== "inherited")
  949. return t9;
  950. }
  951. return this._getLayerDomain(e6);
  952. }
  953. getField(e6) {
  954. return this.fieldsIndex.get(e6);
  955. }
  956. queryAttachments(e6, t8) {
  957. return e6 = c4.from(e6), this.load().then(() => {
  958. if (!this.get("capabilities.data.supportsAttachment"))
  959. throw new s2(Ue, "this layer doesn't support attachments");
  960. const { attachmentTypes: t9, objectIds: r6, globalIds: i10, num: o7, size: s14, start: a10, where: n13 } = e6;
  961. if (!this.get("capabilities.operations.supportsQueryAttachments")) {
  962. const p23 = r6 && r6.length > 1, l9 = t9 && t9.length, u6 = i10 && i10.length, d8 = s14 && s14.length;
  963. if (p23 || l9 || u6 || d8 || o7 || a10 || n13)
  964. throw new s2(Ue, "when 'supportsQueryAttachments' is false, only objectIds of length 1 are supported", e6);
  965. }
  966. if (!(r6 && r6.length || n13))
  967. throw new s2(Ue, "'objectIds' or 'where' are required to perform attachment query", e6);
  968. if (!("queryAttachments" in this.source))
  969. throw new s2(Ue, "Layer source does not support queryAttachments capability", e6);
  970. return this.source.queryAttachments(e6);
  971. });
  972. }
  973. queryFeatures(e6, t8) {
  974. return this.load().then(() => this.source.queryFeatures(b2.from(e6) || this.createQuery(), t8)).then((e7) => {
  975. if (e7?.features)
  976. for (const t9 of e7.features)
  977. t9.layer = t9.sourceLayer = this;
  978. return e7;
  979. });
  980. }
  981. queryObjectIds(e6, t8) {
  982. return this.load().then(() => {
  983. if (this.source.queryObjectIds)
  984. return this.source.queryObjectIds(b2.from(e6) || this.createQuery(), t8);
  985. throw new s2(Ue, "Layer source does not support queryObjectIds capability");
  986. });
  987. }
  988. queryFeatureCount(e6, t8) {
  989. return this.load().then(() => {
  990. if (this.source.queryFeatureCount)
  991. return this.source.queryFeatureCount(b2.from(e6) || this.createQuery(), t8);
  992. throw new s2(Ue, "Layer source does not support queryFeatureCount capability");
  993. });
  994. }
  995. queryExtent(e6, t8) {
  996. return this.load().then(() => {
  997. if (this.source.queryExtent)
  998. return this.source.queryExtent(b2.from(e6) || this.createQuery(), t8);
  999. throw new s2(Ue, "Layer source does not support queryExtent capability");
  1000. });
  1001. }
  1002. queryRelatedFeatures(e6, t8) {
  1003. return this.load().then(() => {
  1004. if ("queryRelatedFeatures" in this.source)
  1005. return this.source.queryRelatedFeatures(d3.from(e6), t8);
  1006. throw new s2(Ue, "Layer source does not support queryRelatedFeatures capability");
  1007. });
  1008. }
  1009. queryRelatedFeaturesCount(e6, t8) {
  1010. return this.load().then(() => {
  1011. if ("queryRelatedFeaturesCount" in this.source)
  1012. return this.source.queryRelatedFeaturesCount(d3.from(e6), t8);
  1013. throw new s2(Ue, "Layer source does not support queryRelatedFeaturesCount capability");
  1014. });
  1015. }
  1016. queryTopFeatures(e6, t8) {
  1017. return this.load().then(() => {
  1018. if ("queryTopFeatures" in this.source && this.get("capabilities.query.supportsTopFeaturesQuery"))
  1019. return this.source.queryTopFeatures(S.from(e6), t8).then((e7) => {
  1020. if (e7?.features)
  1021. for (const t9 of e7.features)
  1022. t9.layer = t9.sourceLayer = this;
  1023. return e7;
  1024. });
  1025. throw new s2(Ue, "Layer source does not support queryTopFeatures capability");
  1026. });
  1027. }
  1028. queryTopObjectIds(e6, t8) {
  1029. return this.load().then(() => {
  1030. if ("queryTopObjectIds" in this.source && this.get("capabilities.query.supportsTopFeaturesQuery"))
  1031. return this.source.queryTopObjectIds(S.from(e6), t8);
  1032. throw new s2(Ue, "Layer source does not support queryTopObjectIds capability");
  1033. });
  1034. }
  1035. queryTopFeaturesExtent(e6, t8) {
  1036. return this.load().then(() => {
  1037. if ("queryTopExtents" in this.source && this.get("capabilities.query.supportsTopFeaturesQuery"))
  1038. return this.source.queryTopExtents(S.from(e6), t8);
  1039. throw new s2(Ue, "Layer source does not support queryTopExtents capability");
  1040. });
  1041. }
  1042. queryTopFeatureCount(e6, t8) {
  1043. return this.load().then(() => {
  1044. if ("queryTopCount" in this.source && this.get("capabilities.query.supportsTopFeaturesQuery"))
  1045. return this.source.queryTopCount(S.from(e6), t8);
  1046. throw new s2(Ue, "Layer source does not support queryFeatureCount capability");
  1047. });
  1048. }
  1049. read(e6, t8) {
  1050. const r6 = e6.featureCollection;
  1051. if (r6) {
  1052. const e7 = r6.layers;
  1053. e7 && e7.length === 1 && (super.read(e7[0], t8), r6.showLegend != null && super.read({ showLegend: r6.showLegend }, t8));
  1054. }
  1055. super.read(e6, t8), t8 && t8.origin === "service" && this.revert(["objectIdField", "fields", "timeInfo", "spatialReference"], "service");
  1056. }
  1057. write(e6, t8) {
  1058. t8 = { ...t8, writeLayerSchema: t8?.writeLayerSchema ?? this._hasMemorySource() };
  1059. const { origin: r6, layerContainerType: i10, messages: o7 } = t8;
  1060. if (this.dynamicDataSource)
  1061. return o7?.push(Ve(this, "using a dynamic data source cannot be written to web scenes, web maps and feature service items")), null;
  1062. if (this.isTable) {
  1063. if (r6 === "web-scene" || r6 === "web-map" && i10 !== "tables")
  1064. return o7?.push(Ve(this, "using a table source cannot be written to web scenes and web maps")), null;
  1065. if (this._hasMemorySource())
  1066. return o7?.push(Ve(this, "using an in-memory table source cannot be written to web scenes and web maps")), null;
  1067. } else if (this.loaded && r6 === "web-map" && i10 === "tables")
  1068. return o7?.push(Ve(this, "using a non-table source cannot be written to tables in web maps")), null;
  1069. return super.write(e6, t8);
  1070. }
  1071. clone() {
  1072. if (this._hasMemorySource())
  1073. throw new s2(Ue, `FeatureLayer (title: ${this.title}, id: ${this.id}) created using in-memory source cannot be cloned`);
  1074. return super.clone();
  1075. }
  1076. serviceSupportsSpatialReference(e6) {
  1077. return !!this.loaded && (this.source.type === "memory" || e2(this, e6));
  1078. }
  1079. async save(e6) {
  1080. return (await import("./featureLayerUtils-SGDU7QQB.js")).save(this, e6);
  1081. }
  1082. async saveAs(e6, t8) {
  1083. return (await import("./featureLayerUtils-SGDU7QQB.js")).saveAs(this, e6, t8);
  1084. }
  1085. _readEditingEnabled(e6, t8, r6) {
  1086. let i10 = e6.layerDefinition?.capabilities;
  1087. return i10 ? this._hasEditingCapability(i10) : (i10 = e6.capabilities, t8 && r6?.origin === "web-map" && !this._hasMemorySource() && i10 ? this._hasEditingCapability(i10) : void 0);
  1088. }
  1089. _hasEditingCapability(e6) {
  1090. return e6.toLowerCase().split(",").map((e7) => e7.trim()).includes("editing");
  1091. }
  1092. _writeEditingEnabled(e6, t8, r6, i10) {
  1093. if (!e6) {
  1094. const e7 = this.capabilities?.operations?.supportsSync ? "Query,Sync" : "Query";
  1095. o("layerDefinition.capabilities", e7, t8), r6 && !i10?.writeLayerSchema && (t8.capabilities = e7);
  1096. }
  1097. }
  1098. _checkAttachmentSupport(e6) {
  1099. const { attributes: t8 } = e6, { objectIdField: r6 } = this;
  1100. return this.get("capabilities.data.supportsAttachment") ? e6 ? t8 ? t8[r6] ? void 0 : Promise.reject(new s2(Ue, `feature is missing the identifying attribute ${r6}`)) : Promise.reject(new s2(Ue, "'attributes' are required on a feature to query attachments")) : Promise.reject(new s2(Ue, "A feature is required to add/delete/update attachments")) : Promise.reject(new s2(Ue, "this layer doesn't support attachments"));
  1101. }
  1102. _getLayerDomain(e6) {
  1103. const t8 = this.fieldsIndex.get(e6);
  1104. return t8 ? t8.domain : null;
  1105. }
  1106. _fetchFirstLayerId(e6) {
  1107. return U(this.url, { query: { f: "json", ...this.customParameters, token: this.apiKey }, responseType: "json", signal: e6 }).then((e7) => {
  1108. const t8 = e7.data;
  1109. if (t8)
  1110. return Array.isArray(t8.layers) && t8.layers.length > 0 ? t8.layers[0].id : Array.isArray(t8.tables) && t8.tables.length > 0 ? t8.tables[0].id : void 0;
  1111. });
  1112. }
  1113. async _initLayerProperties(e6) {
  1114. return this._set("source", e6), e6.sourceJSON && (this.sourceJSON = e6.sourceJSON, this.read(e6.sourceJSON, { origin: "service", url: this.parsedUrl })), this._verifySource(), this._verifyFields(), c5(this.renderer, this.fieldsIndex), m6(this.timeInfo, this.fieldsIndex), t4(this, { origin: "service" });
  1115. }
  1116. async hasDataChanged() {
  1117. if (this.source?.refresh)
  1118. try {
  1119. const { dataChanged: e6, updates: t8 } = await this.source?.refresh();
  1120. if (r(t8) && (this.sourceJSON = { ...this.sourceJSON, ...t8 }, this.read(t8, { origin: "service", url: this.parsedUrl })), e6)
  1121. return true;
  1122. } catch {
  1123. }
  1124. if (this.definitionExpression)
  1125. try {
  1126. return (await r4(this.definitionExpression, this.fieldsIndex)).hasDateFunctions;
  1127. } catch {
  1128. }
  1129. return false;
  1130. }
  1131. _verifyFields() {
  1132. const e6 = this.parsedUrl && this.parsedUrl.path || "undefined";
  1133. this.objectIdField || console.log("FeatureLayer: 'objectIdField' property is not defined (url: " + e6 + ")"), this.isTable || this._hasMemorySource() || e6.search(/\/FeatureServer\//i) !== -1 || this.fields?.some((e7) => e7.type === "geometry") || console.log("FeatureLayer: unable to find field of type 'geometry' in the layer 'fields' list. If you are using a map service layer, features will not have geometry (url: " + e6 + ")");
  1134. }
  1135. _fixTemplates(e6, t8) {
  1136. e6 && e6.forEach((e7) => {
  1137. const r6 = e7.prototype && e7.prototype.attributes;
  1138. r6 && t8 && delete r6[t8];
  1139. });
  1140. }
  1141. _verifySource() {
  1142. if (this._hasMemorySource()) {
  1143. if (this.url)
  1144. throw new s2("feature-layer:mixed-source-and-url", "FeatureLayer cannot be created with both an in-memory source and a url");
  1145. } else if (!this.url)
  1146. throw new s2("feature-layer:source-or-url-required", "FeatureLayer requires either a url, a valid portal item or a source");
  1147. }
  1148. _initMemorySource(e6) {
  1149. e6.forEach((e7) => {
  1150. e7.layer = this, e7.sourceLayer = this;
  1151. }), this._handles.add([e6.on("after-add", (e7) => {
  1152. e7.item.layer = this, e7.item.sourceLayer = this;
  1153. }), e6.on("after-remove", (e7) => {
  1154. e7.item.layer = null, e7.item.sourceLayer = null;
  1155. })], "fl-source");
  1156. }
  1157. _resetMemorySource(e6) {
  1158. e6.forEach((e7) => {
  1159. e7.layer = null, e7.sourceLayer = null;
  1160. }), this._handles.remove("fl-source");
  1161. }
  1162. _hasMemorySource() {
  1163. return !(this.url || !this.source);
  1164. }
  1165. _readAnalyticsCapabilities(e6) {
  1166. return { supportsCacheHint: We(e6.advancedQueryCapabilities, "queryAnalytics") };
  1167. }
  1168. _readAttachmentCapabilities(e6) {
  1169. const t8 = e6.attachmentProperties, r6 = { supportsName: false, supportsSize: false, supportsContentType: false, supportsKeywords: false, supportsExifInfo: false, supportsCacheHint: We(e6.advancedQueryCapabilities, "queryAttachments"), supportsResize: Be(e6, "supportsAttachmentsResizing", false) };
  1170. return t8 && Array.isArray(t8) && t8.forEach((e7) => {
  1171. const t9 = Qe[e7.name];
  1172. t9 && (r6[t9] = !!e7.isEnabled);
  1173. }), r6;
  1174. }
  1175. _readDataCapabilities(e6) {
  1176. return { isVersioned: Be(e6, "isDataVersioned", false), supportsAttachment: Be(e6, "hasAttachments", false), supportsM: Be(e6, "hasM", false), supportsZ: Be(e6, "hasZ", false) };
  1177. }
  1178. _readMetadataCapabilities(e6) {
  1179. return { supportsAdvancedFieldProperties: Be(e6, "supportsFieldDescriptionProperty", false) };
  1180. }
  1181. _readOperationsCapabilities(e6, t8) {
  1182. const r6 = e6 ? e6.toLowerCase().split(",").map((e7) => e7.trim()) : [], i10 = this.url ? m3(this.url) : null, o7 = r6.includes(r(i10) && i10.serverType === "MapServer" ? "data" : "query"), s14 = r6.includes("editing") && !t8.datesInUnknownTimezone;
  1183. let a10 = s14 && r6.includes("create"), n13 = s14 && r6.includes("delete"), p23 = s14 && r6.includes("update");
  1184. const l9 = r6.includes("changetracking"), u6 = t8.advancedQueryCapabilities;
  1185. return s14 && !(a10 || n13 || p23) && (a10 = n13 = p23 = true), { supportsCalculate: Be(t8, "supportsCalculate", false), supportsTruncate: Be(t8, "supportsTruncate", false), supportsValidateSql: Be(t8, "supportsValidateSql", false), supportsAdd: a10, supportsDelete: n13, supportsEditing: s14, supportsChangeTracking: l9, supportsQuery: o7, supportsQueryAnalytics: Be(u6, "supportsQueryAnalytic", false), supportsQueryAttachments: Be(u6, "supportsQueryAttachments", false), supportsQueryTopFeatures: Be(u6, "supportsTopFeaturesQuery", false), supportsResizeAttachments: Be(t8, "supportsAttachmentsResizing", false), supportsSync: r6.includes("sync"), supportsUpdate: p23, supportsExceedsLimitStatistics: Be(t8, "supportsExceedsLimitStatistics", false) };
  1186. }
  1187. _readQueryCapabilities(e6) {
  1188. const t8 = e6.advancedQueryCapabilities, r6 = e6.ownershipBasedAccessControlForFeatures, i10 = e6.archivingInfo, o7 = this.url?.includes("MapServer"), s14 = !a("mapserver-pbf-enabled") && o7 && this.version < 10.81, a10 = g(this.url), n13 = (e6.supportedQueryFormats || "").split(",").reduce((e7, t9) => {
  1189. const r7 = t9.toLowerCase().trim();
  1190. return r7 && e7.add(r7), e7;
  1191. }, new Set());
  1192. return { supportsStatistics: Be(t8, "supportsStatistics", e6.supportsStatistics), supportsPercentileStatistics: Be(t8, "supportsPercentileStatistics", false), supportsSpatialAggregationStatistics: Be(t8, "supportsSpatialAggregationStatistics", false), supportedSpatialAggregationStatistics: Ne(t8), supportsCentroid: Be(t8, "supportsReturningGeometryCentroid", false), supportsDistance: Be(t8, "supportsQueryWithDistance", false), supportsDistinct: Be(t8, "supportsDistinct", e6.supportsAdvancedQueries), supportsExtent: Be(t8, "supportsReturningQueryExtent", false), supportsGeometryProperties: Be(t8, "supportsReturningGeometryProperties", false), supportsHavingClause: Be(t8, "supportsHavingClause", false), supportsOrderBy: Be(t8, "supportsOrderBy", e6.supportsAdvancedQueries), supportsPagination: Be(t8, "supportsPagination", false), supportsQuantization: Be(e6, "supportsCoordinatesQuantization", false), supportsQuantizationEditMode: Be(e6, "supportsQuantizationEditMode", false), supportsQueryGeometry: Be(e6, "supportsReturningQueryGeometry", false), supportsResultType: Be(t8, "supportsQueryWithResultType", false), supportsMaxRecordCountFactor: Be(t8, "supportsMaxRecordCountFactor", false), supportsSqlExpression: Be(t8, "supportsSqlExpression", false), supportsStandardizedQueriesOnly: Be(e6, "useStandardizedQueries", false), supportsTopFeaturesQuery: Be(t8, "supportsTopFeaturesQuery", false), supportsQueryByOthers: Be(r6, "allowOthersToQuery", true), supportsHistoricMoment: Be(i10, "supportsQueryWithHistoricMoment", false), supportsFormatPBF: !s14 && n13.has("pbf"), supportsDisjointSpatialRelationship: Be(t8, "supportsDisjointSpatialRel", false), supportsCacheHint: Be(t8, "supportsQueryWithCacheHint", false) || We(t8, "query"), supportsDefaultSpatialReference: Be(t8, "supportsDefaultSR", false), supportsCompactGeometry: a10, maxRecordCountFactor: ke(e6, "maxRecordCountFactor", void 0), maxRecordCount: ke(e6, "maxRecordCount", void 0), standardMaxRecordCount: ke(e6, "standardMaxRecordCount", void 0), tileMaxRecordCount: ke(e6, "tileMaxRecordCount", void 0) };
  1193. }
  1194. _readQueryRelatedCapabilities(e6) {
  1195. const t8 = e6.advancedQueryCapabilities, r6 = Be(t8, "supportsAdvancedQueryRelated", false);
  1196. return { supportsPagination: Be(t8, "supportsQueryRelatedPagination", false), supportsCount: r6, supportsOrderBy: r6, supportsCacheHint: We(t8, "queryRelated") };
  1197. }
  1198. _readQueryTopFeaturesCapabilities(e6) {
  1199. return { supportsCacheHint: We(e6.advancedQueryCapabilities, "queryTopFilter") };
  1200. }
  1201. _readEditingCapabilities(e6) {
  1202. const t8 = e6.ownershipBasedAccessControlForFeatures;
  1203. return { supportsGeometryUpdate: Be(e6, "allowGeometryUpdates", true), supportsGlobalId: Be(e6, "supportsApplyEditsWithGlobalIds", false), supportsReturnServiceEditsInSourceSpatialReference: Be(e6, "supportsReturnServiceEditsInSourceSR", false), supportsRollbackOnFailure: Be(e6, "supportsRollbackOnFailureParameter", false), supportsUpdateWithoutM: Be(e6, "allowUpdateWithoutMValues", false), supportsUploadWithItemId: Be(e6, "supportsAttachmentsByUploadId", false), supportsDeleteByAnonymous: Be(t8, "allowAnonymousToDelete", true), supportsDeleteByOthers: Be(t8, "allowOthersToDelete", true), supportsUpdateByAnonymous: Be(t8, "allowAnonymousToUpdate", true), supportsUpdateByOthers: Be(t8, "allowOthersToUpdate", true) };
  1204. }
  1205. };
  1206. e([d({ readOnly: true, json: { read: false } })], Ze.prototype, "capabilities", void 0), e([o2("service", "capabilities", ["advancedQueryCapabilities", "allowGeometryUpdates", "allowUpdateWithoutMValues", "archivingInfo", "capabilities", "datesInUnknownTimezone", "hasAttachments", "hasM", "hasZ", "maxRecordCount", "maxRecordCountFactor", "ownershipBasedAccessControlForFeatures", "standardMaxRecordCount", "supportedQueryFormats", "supportsAdvancedQueries", "supportsApplyEditsWithGlobalIds", "supportsAttachmentsByUploadId", "supportsAttachmentsResizing", "supportsCalculate", "supportsCoordinatesQuantization", "supportsExceedsLimitStatistics", "supportsFieldDescriptionProperty", "supportsQuantizationEditMode", "supportsRollbackOnFailureParameter", "supportsStatistics", "supportsTruncate", "supportsValidateSql", "tileMaxRecordCount", "useStandardizedQueries"])], Ze.prototype, "readCapabilities", null), e([d({ json: { origins: { "portal-item": { write: true }, "web-map": { write: true } } } })], Ze.prototype, "charts", void 0), e([d({ readOnly: true })], Ze.prototype, "createQueryVersion", null), e([d({ type: String, json: { read: { source: "layerDefinition.copyrightText" }, origins: { service: { read: { source: "copyrightText" } } } } })], Ze.prototype, "copyright", void 0), e([d({ type: Boolean })], Ze.prototype, "datesInUnknownTimezone", void 0), e([d({ type: String, json: { read: { source: "layerDefinition.displayField" }, origins: { service: { read: { source: "displayField" } } } } })], Ze.prototype, "displayField", void 0), e([d({ type: String, json: { origins: { service: { read: false, write: false } }, name: "layerDefinition.definitionExpression", write: { enabled: true, allowNull: true } } })], Ze.prototype, "definitionExpression", void 0), e([d({ types: j3, readOnly: true })], Ze.prototype, "defaultSymbol", void 0), e([d({ type: K })], Ze.prototype, "dynamicDataSource", void 0), e([d({ readOnly: true })], Ze.prototype, "editFieldsInfo", void 0), e([d({ type: Boolean })], Ze.prototype, "editingEnabled", null), e([o2(["portal-item", "web-scene"], "editingEnabled", ["layerDefinition.capabilities"])], Ze.prototype, "readEditingEnabled", null), e([o2("web-map", "editingEnabled", ["capabilities", "layerDefinition.capabilities"])], Ze.prototype, "readEditingEnabledFromWebMap", null), e([r2(["portal-item", "web-scene"], "editingEnabled", { "layerDefinition.capabilities": { type: String } })], Ze.prototype, "writeEditingEnabled", null), e([r2("web-map", "editingEnabled", { capabilities: { type: String }, "layerDefinition.capabilities": { type: String } })], Ze.prototype, "writeEditingEnabledToWebMap", null), e([d({ readOnly: true })], Ze.prototype, "editingInfo", void 0), e([o2("editingInfo")], Ze.prototype, "readEditingInfo", null), e([d((() => {
  1207. const e6 = m(d2), t8 = e6.json.origins;
  1208. return t8["web-map"] = { read: false, write: false }, t8["portal-item"] = { read: false, write: false }, e6;
  1209. })())], Ze.prototype, "elevationInfo", void 0), e([d(p7)], Ze.prototype, "featureReduction", void 0), e([d({ ...He.fields, json: { read: { source: "layerDefinition.fields" }, origins: { service: { name: "fields" }, "web-map": { write: { target: "layerDefinition.fields", overridePolicy: Je } } } } })], Ze.prototype, "fields", void 0), e([d(He.fieldsIndex)], Ze.prototype, "fieldsIndex", void 0), e([d({ type: p9, json: { read: { source: "layerDefinition.floorInfo" }, write: { target: "layerDefinition.floorInfo" } } })], Ze.prototype, "floorInfo", void 0), e([d({ type: E, json: { name: "formInfo", write: true, origins: { "web-scene": { read: false, write: false } } } })], Ze.prototype, "formTemplate", void 0), e([d({ type: M, json: { origins: { service: { read: { source: "extent" } } }, read: { source: "layerDefinition.extent" } } })], Ze.prototype, "fullExtent", void 0), e([d()], Ze.prototype, "gdbVersion", void 0), e([d({ readOnly: true, type: c11, json: { read: { source: "geometryProperties" } } })], Ze.prototype, "geometryFieldsInfo", void 0), e([d({ type: ["point", "polygon", "polyline", "multipoint", "multipatch", "mesh"], json: { origins: { service: { read: qe.read }, "web-map": { write: { target: "layerDefinition.geometryType", overridePolicy: Je, writer(e6, t8, r6) {
  1210. const i10 = e6 ? qe.toJSON(e6) : null;
  1211. i10 && o(r6, i10, t8);
  1212. } } } }, read: { source: "layerDefinition.geometryType", reader: qe.read } } })], Ze.prototype, "geometryType", void 0), e([d({ type: Boolean, json: { origins: { service: { read: true } }, read: { source: "layerDefinition.hasM" } } })], Ze.prototype, "hasM", void 0), e([d({ type: Boolean, json: { origins: { service: { read: true } }, read: { source: "layerDefinition.hasZ" } } })], Ze.prototype, "hasZ", void 0), e([d({ readOnly: true, type: v5 })], Ze.prototype, "heightModelInfo", void 0), e([d({ type: Date })], Ze.prototype, "historicMoment", void 0), e([d(v3)], Ze.prototype, "id", void 0), e([d({ readOnly: true, json: { origins: { service: { read: true } }, read: false } })], Ze.prototype, "infoFor3D", void 0), e([d({ readOnly: true, json: { origins: { "web-map": { write: { target: "layerDefinition.type" } } } } })], Ze.prototype, "isTable", void 0), e([o2("service", "isTable", ["type", "geometryType"]), o2("isTable", ["layerDefinition.type", "layerDefinition.geometryType"])], Ze.prototype, "readIsTable", null), e([r2("web-map", "isTable")], Ze.prototype, "writeIsTable", null), e([d(m5)], Ze.prototype, "labelsVisible", void 0), e([d({ type: [j4], json: { origins: { service: { read: { source: "drawingInfo.labelingInfo", reader: r5 }, write: { target: "drawingInfo.labelingInfo", enabled: false } } }, read: { source: "layerDefinition.drawingInfo.labelingInfo", reader: r5 }, write: { target: "layerDefinition.drawingInfo.labelingInfo" } } })], Ze.prototype, "labelingInfo", void 0), e([d((() => {
  1213. const e6 = m(u2);
  1214. return e6.json.origins["portal-item"] = { write: { target: "layerDefinition.drawingInfo.transparency", writer(e7, t8, r6) {
  1215. o(r6, n4(e7), t8);
  1216. } } }, e6;
  1217. })())], Ze.prototype, "opacity", void 0), e([d({ type: Number, json: { origins: { service: { read: { source: "id" } }, "portal-item": { read: false, write: { target: "id" } } }, read: false } })], Ze.prototype, "layerId", void 0), e([d(c)], Ze.prototype, "legendEnabled", void 0), e([d({ type: ["show", "hide"], json: (() => {
  1218. const e6 = m(D.json);
  1219. return e6.origins["portal-item"] = { read: false, write: false }, e6;
  1220. })() })], Ze.prototype, "listMode", void 0), e([d(b4)], Ze.prototype, "minScale", void 0), e([o2("service", "minScale", ["minScale", "effectiveMinScale"])], Ze.prototype, "readMinScale", null), e([d(I)], Ze.prototype, "maxScale", void 0), e([o2("service", "maxScale", ["maxScale", "effectiveMaxScale"])], Ze.prototype, "readMaxScale", null), e([d({ type: String })], Ze.prototype, "globalIdField", void 0), e([o2("globalIdField", ["layerDefinition.globalIdField", "layerDefinition.fields"]), o2("service", "globalIdField", ["globalIdField", "fields"])], Ze.prototype, "readGlobalIdFieldFromService", null), e([d({ type: String, json: { origins: { "web-map": { write: { target: "layerDefinition.objectIdField", overridePolicy: Je } } } } })], Ze.prototype, "objectIdField", void 0), e([o2("objectIdField", ["layerDefinition.objectIdField", "layerDefinition.fields"]), o2("service", "objectIdField", ["objectIdField", "fields"])], Ze.prototype, "readObjectIdFieldFromService", null), e([d({ value: "ArcGISFeatureLayer", type: ["ArcGISFeatureLayer"] })], Ze.prototype, "operationalLayerType", void 0), e([d(He.outFields)], Ze.prototype, "outFields", void 0), e([d({ readOnly: true })], Ze.prototype, "parsedUrl", null), e([d({ type: String, json: { origins: { "web-scene": { read: true, write: true } }, read: false } })], Ze.prototype, "path", void 0), e([d(p)], Ze.prototype, "popupEnabled", void 0), e([d({ type: B, json: { name: "popupInfo", write: true } })], Ze.prototype, "popupTemplate", void 0), e([d({ readOnly: true })], Ze.prototype, "defaultPopupTemplate", null), e([d({ type: [p22], readOnly: true })], Ze.prototype, "relationships", void 0), e([d({ types: p3, json: { origins: { service: { write: { target: "drawingInfo.renderer", enabled: false } }, "web-scene": { types: n6, name: "layerDefinition.drawingInfo.renderer", write: { overridePolicy: (e6, t8, r6) => ({ ignoreOrigin: r6?.writeLayerSchema }) } } }, write: { target: "layerDefinition.drawingInfo.renderer", overridePolicy: (e6, t8, r6) => ({ ignoreOrigin: r6?.writeLayerSchema }) } } })], Ze.prototype, "renderer", null), e([o2("service", "renderer", ["drawingInfo.renderer", "defaultSymbol"]), o2("renderer", ["layerDefinition.drawingInfo.renderer", "layerDefinition.defaultSymbol"])], Ze.prototype, "readRenderer", null), e([d()], Ze.prototype, "sourceJSON", void 0), e([d({ type: Boolean })], Ze.prototype, "returnM", void 0), e([d({ type: Boolean })], Ze.prototype, "returnZ", void 0), e([d((() => {
  1221. const e6 = m(l3);
  1222. return e6.json.origins["portal-item"] = { read: false, write: false }, e6;
  1223. })())], Ze.prototype, "screenSizePerspectiveEnabled", void 0), e([d({ clonable: false })], Ze.prototype, "source", null), e([s4("source")], Ze.prototype, "castSource", null), e([o2("portal-item", "source", ["featureSet"]), o2("web-map", "source", ["featureSet"])], Ze.prototype, "readSource", null), e([d({ readOnly: true })], Ze.prototype, "serviceDefinitionExpression", void 0), e([o2("service", "serviceDefinitionExpression", ["definitionQuery", "definitionExpression"])], Ze.prototype, "readServiceDefinitionExpression", null), e([d({ type: k, json: { origins: { service: { read: { source: "extent.spatialReference" } } }, read: { source: "layerDefinition.extent.spatialReference" } } })], Ze.prototype, "spatialReference", void 0), e([d({ type: Number })], Ze.prototype, "subtypeCode", void 0), e([d({ type: String, json: { origins: { service: { read: true } } } })], Ze.prototype, "subtypeField", void 0), e([d({ type: [p8] })], Ze.prototype, "templates", void 0), e([o2("templates", ["editFieldsInfo", "creatorField", "editorField", "templates"])], Ze.prototype, "readTemplates", null), e([d({ type: v2 })], Ze.prototype, "timeInfo", void 0), e([d()], Ze.prototype, "title", void 0), e([o2("service", "title", ["name"]), o2("portal-item", "title", ["layerDefinition.title", "layerDefinition.name", "title"])], Ze.prototype, "readTitle", null), e([o2("web-map", "title", ["layerDefinition.name", "title"])], Ze.prototype, "readTitleFromWebMap", null), e([d({ type: String })], Ze.prototype, "sublayerTitleMode", void 0), e([d({ type: String, json: { read: { source: "timeInfo.trackIdField" } } })], Ze.prototype, "trackIdField", void 0), e([d({ json: { read: false } })], Ze.prototype, "type", void 0), e([d({ type: String })], Ze.prototype, "typeIdField", void 0), e([o2("service", "typeIdField"), o2("typeIdField", ["layerDefinition.typeIdField"])], Ze.prototype, "readTypeIdField", null), e([d({ type: [n7] })], Ze.prototype, "types", void 0), e([o2("service", "types", ["types"]), o2("types", ["layerDefinition.types"])], Ze.prototype, "readTypes", null), e([d({ readOnly: true, json: { write: false } })], Ze.prototype, "serverGens", void 0), e([d({ type: j.ofType(c10), readOnly: true })], Ze.prototype, "indexes", void 0), e([d(f)], Ze.prototype, "url", null), e([r2("url")], Ze.prototype, "writeUrl", null), e([d({ readOnly: true })], Ze.prototype, "userIsAdmin", void 0), e([d({ json: { origins: { service: { read: true } }, read: false } })], Ze.prototype, "version", void 0), e([o2("service", "version", ["currentVersion", "capabilities", "drawingInfo", "hasAttachments", "htmlPopupType", "relationships", "timeInfo", "typeIdField", "types"])], Ze.prototype, "readVersion", null), e([d({ type: Boolean, json: { origins: { "portal-item": { write: { target: "layerDefinition.defaultVisibility" } } } } })], Ze.prototype, "visible", void 0), e([o2("portal-item", "visible", ["visibility", "layerDefinition.defaultVisibility"])], Ze.prototype, "readVisible", null), Ze = e([n("esri.layers.FeatureLayer")], Ze);
  1224. var $e = s3({ types: M2 });
  1225. var Ke = Ze;
  1226. export {
  1227. Ke
  1228. };
  1229. //# sourceMappingURL=chunk-6NQ3AA2U.js.map