@arcgis/map-components 5.1.2 → 5.1.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.
Files changed (242) hide show
  1. package/dist/cdn/{3LUAFLYH.js → 2ESR6HXK.js} +1 -1
  2. package/dist/cdn/{KQGEFVQX.js → 2GLH5PUC.js} +1 -1
  3. package/dist/cdn/{DKPPAY7S.js → 2PA6LDHI.js} +1 -1
  4. package/dist/cdn/{7UTPZBBS.js → 2PORQMMM.js} +1 -1
  5. package/dist/cdn/{FUSXXX2H.js → 2YLQST6F.js} +1 -1
  6. package/dist/cdn/{EVSYTEQK.js → 33VJMWDL.js} +1 -1
  7. package/dist/cdn/{DFKYJ3TJ.js → 36MLS24H.js} +1 -1
  8. package/dist/cdn/{SILCE4O4.js → 3GMSKHTZ.js} +1 -1
  9. package/dist/cdn/{FMEISWZH.js → 3NUB4VDM.js} +1 -1
  10. package/dist/cdn/{UEQHIK7T.js → 3SIYO7ZN.js} +1 -1
  11. package/dist/cdn/{GY4THDW6.js → 3V5DH2CM.js} +1 -1
  12. package/dist/cdn/{F56R6NNL.js → 43BKUZZE.js} +1 -1
  13. package/dist/cdn/{DX5IW4LD.js → 4DPPQD2Z.js} +1 -1
  14. package/dist/cdn/{XC5JKO2J.js → 4Y7BN2L3.js} +1 -1
  15. package/dist/cdn/{SDXUPDBK.js → 4YPMLEH3.js} +1 -1
  16. package/dist/cdn/{DQSUSD33.js → 573HDEUM.js} +1 -1
  17. package/dist/cdn/{Q7KIJ3P5.js → 5GLXBFTG.js} +1 -1
  18. package/dist/cdn/{7SUBS4HT.js → 5JEBFB6A.js} +1 -1
  19. package/dist/cdn/{Y2R2Z5YV.js → 5NFUN7TZ.js} +1 -1
  20. package/dist/cdn/5NYBDYMA.js +2 -0
  21. package/dist/cdn/{ONBIIQSD.js → 5UCEBVXR.js} +1 -1
  22. package/dist/cdn/{6JPTHKPG.js → 5UIAH4FZ.js} +1 -1
  23. package/dist/cdn/{WAY7FVQT.js → 6DQLBG5Q.js} +1 -1
  24. package/dist/cdn/6NACBAL7.js +2 -0
  25. package/dist/cdn/{P7XVSVLJ.js → 6NWA6WEA.js} +1 -1
  26. package/dist/cdn/{OA3H52O2.js → 6O5CGO2B.js} +1 -1
  27. package/dist/cdn/{PYF4Y6SP.js → 6OM3S3VY.js} +1 -1
  28. package/dist/cdn/{7ZVCWVJ4.js → 6RMUSGTH.js} +1 -1
  29. package/dist/cdn/{GW4KIJTE.js → 7BSWFIVR.js} +1 -1
  30. package/dist/cdn/{UMOM6TOJ.js → 7DS4S4OL.js} +1 -1
  31. package/dist/cdn/{SEV6YOS5.js → 7F5OYOAD.js} +1 -1
  32. package/dist/cdn/{TK4Q74KL.js → 7LN27COB.js} +1 -1
  33. package/dist/cdn/{WHWRXOOY.js → 7N5OXSRE.js} +1 -1
  34. package/dist/cdn/{KGXW3NCW.js → 7P4SZTMT.js} +1 -1
  35. package/dist/cdn/{ETOHKNYW.js → 7RTMHA5A.js} +1 -1
  36. package/dist/cdn/{WHGRCGYI.js → 7ST4RWKI.js} +1 -1
  37. package/dist/cdn/{THWNQRP5.js → A76EYHCS.js} +1 -1
  38. package/dist/cdn/{EA3H5LNK.js → ABE4L2X7.js} +1 -1
  39. package/dist/cdn/{CON3M6Z5.js → AU6P56XQ.js} +1 -1
  40. package/dist/cdn/{QSU3LQPB.js → BBDC5ATP.js} +1 -1
  41. package/dist/cdn/{Y3MUXO2N.js → BJ7M3LN3.js} +1 -1
  42. package/dist/cdn/{H7LJBN7J.js → BK5IYTR7.js} +1 -1
  43. package/dist/cdn/{KOSEAFDF.js → BQSHES4R.js} +1 -1
  44. package/dist/cdn/{EQSJ5YJJ.js → BUTHXRHI.js} +1 -1
  45. package/dist/cdn/{TBUQX27Z.js → BVC4AGUC.js} +1 -1
  46. package/dist/cdn/{GVHLQK4X.js → BYUG46SX.js} +1 -1
  47. package/dist/cdn/{U7ME6ZY2.js → BZ4IIPLI.js} +1 -1
  48. package/dist/cdn/{ARE6XXZN.js → C6IELZJH.js} +1 -1
  49. package/dist/cdn/{6UIQON4J.js → CBYEYXQC.js} +1 -1
  50. package/dist/cdn/{ULAPVDLG.js → CCYZ3O3F.js} +1 -1
  51. package/dist/cdn/{PTDDLSKF.js → CFCOLB4A.js} +1 -1
  52. package/dist/cdn/{5AKUQIOQ.js → CFL7WBUR.js} +1 -1
  53. package/dist/cdn/{RVQMNX4D.js → CJGGAMVX.js} +1 -1
  54. package/dist/cdn/CSU3RGEL.js +2 -0
  55. package/dist/cdn/{J2U5EPDT.js → CUGAOVOP.js} +1 -1
  56. package/dist/cdn/{DJFGZDPY.js → CXNASRAI.js} +1 -1
  57. package/dist/cdn/{C46USWU3.js → DBB3S5HF.js} +1 -1
  58. package/dist/cdn/{WSGEYDSY.js → DD7PYQG3.js} +1 -1
  59. package/dist/cdn/{5EO7L5PZ.js → DLNZZWWI.js} +1 -1
  60. package/dist/cdn/{AG6YMYYG.js → DMHSTNBW.js} +1 -1
  61. package/dist/cdn/{2HOCZD2I.js → DVXPNVSG.js} +1 -1
  62. package/dist/cdn/DYAZ6LMG.js +2 -0
  63. package/dist/cdn/{BI6C5QWY.js → E33WGWET.js} +1 -1
  64. package/dist/cdn/{CCWC5JAB.js → E7RA2AH4.js} +1 -1
  65. package/dist/cdn/{LHN2QDKV.js → EFDENXSZ.js} +1 -1
  66. package/dist/cdn/{RXZTEC5Z.js → EFEF5BPC.js} +1 -1
  67. package/dist/cdn/{TM3BGDCH.js → EFN4FRL5.js} +1 -1
  68. package/dist/cdn/{ECLPZ5RI.js → EIHGISPV.js} +1 -1
  69. package/dist/cdn/{TVG3G3CQ.js → ENBH27M3.js} +1 -1
  70. package/dist/cdn/{PIWGSAQF.js → ENQCIUCH.js} +1 -1
  71. package/dist/cdn/{4NETFLDI.js → EPIT7U5X.js} +1 -1
  72. package/dist/cdn/{HOTRPDNE.js → EUFWFKTY.js} +1 -1
  73. package/dist/cdn/{3Q6H4RYO.js → EZ67DXSF.js} +1 -1
  74. package/dist/cdn/{QP6IONYI.js → F3UZD22N.js} +1 -1
  75. package/dist/cdn/{W257I7HW.js → FDWADAQF.js} +1 -1
  76. package/dist/cdn/{D2YGTQUJ.js → FGLF4QBF.js} +1 -1
  77. package/dist/cdn/{IKSX6FKO.js → FINEGGPR.js} +1 -1
  78. package/dist/cdn/{7BJ2XF54.js → FOZLLHZ2.js} +1 -1
  79. package/dist/cdn/{XW3G7QDY.js → FYURKKPO.js} +1 -1
  80. package/dist/cdn/{2JTPRZNY.js → G53RVHMO.js} +1 -1
  81. package/dist/cdn/{7WLS3KJQ.js → GNNMPXCN.js} +1 -1
  82. package/dist/cdn/{LJBJBQNB.js → HMNUDV6B.js} +1 -1
  83. package/dist/cdn/{5ALJO7UH.js → HPRP3IKV.js} +1 -1
  84. package/dist/cdn/{KLSSO2IB.js → HS2QCKGL.js} +1 -1
  85. package/dist/cdn/{ATQJXHRC.js → HSL5NISC.js} +1 -1
  86. package/dist/cdn/{HIZGTBQP.js → HU2C27BQ.js} +1 -1
  87. package/dist/cdn/{GIEH2633.js → HUFVEIMR.js} +1 -1
  88. package/dist/cdn/{6UZI5Y3V.js → HVYYARZW.js} +1 -1
  89. package/dist/cdn/{LH5EEOUE.js → HWQ5TP4Y.js} +1 -1
  90. package/dist/cdn/{BJFYUEWF.js → HZAC5NDN.js} +1 -1
  91. package/dist/cdn/{LJ4STQXJ.js → ICEZC2TQ.js} +1 -1
  92. package/dist/cdn/{N7UWJZJN.js → IE4VI6Q5.js} +1 -1
  93. package/dist/cdn/{5EXHPG7W.js → IMSF5AEZ.js} +1 -1
  94. package/dist/cdn/{XBVK56RR.js → INLVO3GL.js} +1 -1
  95. package/dist/cdn/{YALHHW5A.js → IO7J23AF.js} +1 -1
  96. package/dist/cdn/{CSP2FJKC.js → IO7L24I5.js} +1 -1
  97. package/dist/cdn/{BPQEFPAB.js → IPAXUWEW.js} +1 -1
  98. package/dist/cdn/{QVABJ2GG.js → ISLSKQVK.js} +1 -1
  99. package/dist/cdn/{BQGAXWJH.js → IWVQBLWT.js} +1 -1
  100. package/dist/cdn/{GXNR2JOT.js → J6N7WN2Y.js} +1 -1
  101. package/dist/cdn/{SF2STORW.js → JB2ROPSD.js} +1 -1
  102. package/dist/cdn/{56HPXBAX.js → JOUMSSLR.js} +1 -1
  103. package/dist/cdn/{CKTJHIDM.js → K4LQ4LWP.js} +1 -1
  104. package/dist/cdn/{7TTB6IBQ.js → KOHPKB7T.js} +1 -1
  105. package/dist/cdn/{6MQTAMXU.js → KQLKJSEY.js} +1 -1
  106. package/dist/cdn/{H5AYWCIW.js → KRADCNV2.js} +1 -1
  107. package/dist/cdn/{S6MIUB7T.js → KV3OYCZ7.js} +1 -1
  108. package/dist/cdn/{ROQ3ZMNX.js → KZZIMABM.js} +1 -1
  109. package/dist/cdn/L33NG2CB.js +2 -0
  110. package/dist/cdn/{BQRQUB7L.js → L4ZKVFNO.js} +1 -1
  111. package/dist/cdn/{Q776G7X5.js → L7J3QTQK.js} +1 -1
  112. package/dist/cdn/{OG6DSDF4.js → LER6RQ75.js} +1 -1
  113. package/dist/cdn/{WP6IZGJG.js → LKYMB7CE.js} +1 -1
  114. package/dist/cdn/{PLB2IOFI.js → LL6W64KR.js} +1 -1
  115. package/dist/cdn/{6RZSTHRB.js → LPW2YGBS.js} +1 -1
  116. package/dist/cdn/{CF4W2DNT.js → LVKNCPIL.js} +1 -1
  117. package/dist/cdn/{ZAQBVTA2.js → M2SMYCYM.js} +1 -1
  118. package/dist/cdn/{6ZHIODBL.js → MBJVE6CP.js} +1 -1
  119. package/dist/cdn/{VC3ODN5I.js → MDR5OYC4.js} +1 -1
  120. package/dist/cdn/{KL6P26PU.js → MEKADOT3.js} +1 -1
  121. package/dist/cdn/{KG6NYEKA.js → MI5MWEFP.js} +1 -1
  122. package/dist/cdn/{UXO5X7OY.js → MJ2DQQWP.js} +1 -1
  123. package/dist/cdn/{IH57AOIE.js → MLK57Q43.js} +1 -1
  124. package/dist/cdn/{CVFALL4S.js → MORGXLED.js} +1 -1
  125. package/dist/cdn/{44CYTUO7.js → N3KQRLEY.js} +1 -1
  126. package/dist/cdn/{FKQZ5V6R.js → N3MO46HF.js} +1 -1
  127. package/dist/cdn/{VDTJT5WM.js → N752J3UV.js} +1 -1
  128. package/dist/cdn/{Y6F5INEC.js → NE62JPBM.js} +1 -1
  129. package/dist/cdn/{J2XCQDID.js → NGKCLUQ2.js} +1 -1
  130. package/dist/cdn/{SL2D573Y.js → NJE3P4JX.js} +1 -1
  131. package/dist/cdn/{QWP4PXBX.js → NKLK7WBU.js} +1 -1
  132. package/dist/cdn/{RCODAEH5.js → NUB6LAXA.js} +1 -1
  133. package/dist/cdn/NUBDURYZ.js +2 -0
  134. package/dist/cdn/{6SWLNG5U.js → NV4G572Q.js} +1 -1
  135. package/dist/cdn/{QQGP2YSG.js → O3J3HY24.js} +1 -1
  136. package/dist/cdn/{OT62GDM7.js → OE5V4MI6.js} +1 -1
  137. package/dist/cdn/{ITHFRHDS.js → OLCPC6NR.js} +1 -1
  138. package/dist/cdn/{5WWVWTLV.js → ONJTK4SF.js} +1 -1
  139. package/dist/cdn/{YPK7YXNJ.js → OPP5I5AI.js} +1 -1
  140. package/dist/cdn/{QODAKOAD.js → OUKN3YHU.js} +1 -1
  141. package/dist/cdn/{MWIYHELY.js → OYTZB4RW.js} +1 -1
  142. package/dist/cdn/{FGCLPEYP.js → OZH33NYW.js} +1 -1
  143. package/dist/cdn/{PLFEJPQ4.js → PEMIUFB2.js} +1 -1
  144. package/dist/cdn/{7UAUOLPG.js → PIIE2ZOR.js} +1 -1
  145. package/dist/cdn/{DOCOL5GC.js → PX2BP3QJ.js} +1 -1
  146. package/dist/cdn/{4WV4BCZL.js → PZP5NOWP.js} +1 -1
  147. package/dist/cdn/{MEXVYRBT.js → Q5DGZBR4.js} +1 -1
  148. package/dist/cdn/QA74OQK6.js +2 -0
  149. package/dist/cdn/{JSBX7T66.js → QCFJQKFF.js} +1 -1
  150. package/dist/cdn/{T5PK3CSG.js → QDR5ZVG6.js} +1 -1
  151. package/dist/cdn/{6APQBBDM.js → QH4GJ2BO.js} +1 -1
  152. package/dist/cdn/{MBIHEJP7.js → QMUOLA2P.js} +1 -1
  153. package/dist/cdn/{EXJC56IX.js → QO2ZEPIF.js} +1 -1
  154. package/dist/cdn/{XOPYGAIJ.js → QU76OLVX.js} +1 -1
  155. package/dist/cdn/{ENJ32A62.js → QUHWDL3G.js} +1 -1
  156. package/dist/cdn/{LN5UJQQN.js → QUREQ3LI.js} +1 -1
  157. package/dist/cdn/QVL2OFCK.js +2 -0
  158. package/dist/cdn/{WS6O6JDT.js → R4FF5IWV.js} +1 -1
  159. package/dist/cdn/{LTIOECNS.js → R4SLSV5W.js} +1 -1
  160. package/dist/cdn/{IOJPGOON.js → RGWLIQYJ.js} +1 -1
  161. package/dist/cdn/{VDI6V7A7.js → RH77SOXE.js} +1 -1
  162. package/dist/cdn/{DYN47Y7R.js → RN2CZHVZ.js} +1 -1
  163. package/dist/cdn/{P32YELXJ.js → RWSG4OQ6.js} +1 -1
  164. package/dist/cdn/{I3ZPH7M5.js → RXVD7ZU6.js} +1 -1
  165. package/dist/cdn/{4PFCZYCL.js → SGHG7AJJ.js} +1 -1
  166. package/dist/cdn/{YCVGEU74.js → SVZ2LPMF.js} +1 -1
  167. package/dist/cdn/{OBAYSCIU.js → SWY3JKKX.js} +1 -1
  168. package/dist/cdn/{YFOSZSWF.js → SZ2MBNWL.js} +1 -1
  169. package/dist/cdn/{DYIGVLWT.js → TKGODW54.js} +1 -1
  170. package/dist/cdn/{XUHASJUA.js → TNIPSP6H.js} +1 -1
  171. package/dist/cdn/{7DOKGLVM.js → TO4GLHLM.js} +1 -1
  172. package/dist/cdn/{QVGTWFEN.js → TOVVPICH.js} +1 -1
  173. package/dist/cdn/{JNHR22ZB.js → TSJALH7D.js} +1 -1
  174. package/dist/cdn/TYBW347N.js +2 -0
  175. package/dist/cdn/{JWFUYNQL.js → U2G76MLM.js} +1 -1
  176. package/dist/cdn/{LLPQYUPW.js → U5KGWKHD.js} +1 -1
  177. package/dist/cdn/{2YMZU2DI.js → UA5YO7NO.js} +1 -1
  178. package/dist/cdn/{D3J2KBQF.js → UBKX3LIA.js} +1 -1
  179. package/dist/cdn/{TP3HEJQL.js → UCU2ER3C.js} +1 -1
  180. package/dist/cdn/{OBGINW7D.js → UKE3QTSI.js} +1 -1
  181. package/dist/cdn/{2PMBQVDJ.js → UKM575AX.js} +1 -1
  182. package/dist/cdn/{MLYJ4SA5.js → ULKZFCQF.js} +1 -1
  183. package/dist/cdn/{UL3AN5J2.js → UODGE27P.js} +1 -1
  184. package/dist/cdn/{A2Y4L3CO.js → UOVNWT76.js} +1 -1
  185. package/dist/cdn/{N3775HAR.js → UWBE2BAD.js} +1 -1
  186. package/dist/cdn/{O6U4WH4G.js → V2P7YNIS.js} +1 -1
  187. package/dist/cdn/{EFEEI6XK.js → VMFNOF52.js} +1 -1
  188. package/dist/cdn/{CWQJJUOX.js → VPIXVAXC.js} +1 -1
  189. package/dist/cdn/{JQBG6N6T.js → VSSJMGPA.js} +1 -1
  190. package/dist/cdn/{34KX2CZ2.js → VVKGMQUS.js} +1 -1
  191. package/dist/cdn/{LV5WJ5J7.js → VXWCNLKB.js} +1 -1
  192. package/dist/cdn/{Z2ZUNDTK.js → VYCRAT4K.js} +1 -1
  193. package/dist/cdn/{NPRZRV7N.js → WBKMEMM2.js} +1 -1
  194. package/dist/cdn/{CWFQYXQG.js → WFEURO7O.js} +1 -1
  195. package/dist/cdn/{YXJZ4BLP.js → WM2OOJ6V.js} +1 -1
  196. package/dist/cdn/{DOXOIFUY.js → WMNSCSAQ.js} +1 -1
  197. package/dist/cdn/{OG6CGCQR.js → X4664GHQ.js} +1 -1
  198. package/dist/cdn/{RVLWTZAT.js → XGY6ORJL.js} +1 -1
  199. package/dist/cdn/{MQOSO6YX.js → XISYCTAZ.js} +1 -1
  200. package/dist/cdn/{JO5GGDBR.js → XJH3BCSR.js} +1 -1
  201. package/dist/cdn/{2AKK5ZKG.js → XNBSD7VT.js} +1 -1
  202. package/dist/cdn/{CU6D4FDO.js → XU25D2RJ.js} +1 -1
  203. package/dist/cdn/{IYBSQOCK.js → YLANW6EI.js} +1 -1
  204. package/dist/cdn/{KDS4IULF.js → YMVHM5OZ.js} +1 -1
  205. package/dist/cdn/{LEIE3RAW.js → YYCNECYH.js} +1 -1
  206. package/dist/cdn/{P3LUQEUB.js → Z63J3RPC.js} +1 -1
  207. package/dist/cdn/{DFXZ77W6.js → Z6JYZ2A2.js} +1 -1
  208. package/dist/cdn/{BHRMN454.js → ZBMGDCTS.js} +1 -1
  209. package/dist/cdn/{OTKIXRQV.js → ZDQXM6XT.js} +1 -1
  210. package/dist/cdn/{ZJEARGVC.js → ZEQYZ4ZW.js} +1 -1
  211. package/dist/cdn/{MNV6C5ZE.js → ZFSB47NV.js} +1 -1
  212. package/dist/cdn/{BFOAKOBV.js → ZNFSD3IC.js} +1 -1
  213. package/dist/cdn/{KUHZAASH.js → ZSUE4VY6.js} +1 -1
  214. package/dist/cdn/{PYTF3K7R.js → ZUXIFYIP.js} +1 -1
  215. package/dist/cdn/index.js +1 -1
  216. package/dist/chunks/earth-utils.js +21 -0
  217. package/dist/chunks/runtime.js +1 -1
  218. package/dist/components/arcgis-daylight/customElement.js +174 -190
  219. package/dist/components/arcgis-feature-table/customElement.js +34 -34
  220. package/dist/components/arcgis-popup/customElement.d.ts +2 -3
  221. package/dist/components/arcgis-popup/customElement.js +27 -27
  222. package/dist/components/arcgis-shadow-cast/customElement.js +96 -85
  223. package/dist/components/arcgis-sketch/customElement.d.ts +16 -1
  224. package/dist/components/arcgis-sketch/customElement.js +25 -19
  225. package/dist/docs/api.json +1 -1
  226. package/dist/docs/docs.json +1 -1
  227. package/dist/docs/vscode.html-custom-data.json +1 -1
  228. package/dist/docs/web-types.json +1 -1
  229. package/dist/loader.js +1 -1
  230. package/dist/types/lumina.d.ts +1 -0
  231. package/dist/types/preact.d.ts +1 -0
  232. package/dist/types/react.d.ts +1 -0
  233. package/dist/types/stencil.d.ts +1 -0
  234. package/package.json +4 -4
  235. package/dist/cdn/37ZP4563.js +0 -2
  236. package/dist/cdn/765ALWKM.js +0 -2
  237. package/dist/cdn/BHEPSUS4.js +0 -2
  238. package/dist/cdn/LS254AGB.js +0 -2
  239. package/dist/cdn/N5TOUUMP.js +0 -2
  240. package/dist/cdn/RI54YWGC.js +0 -2
  241. package/dist/cdn/XMF2WHDG.js +0 -2
  242. package/dist/cdn/ZK7PHXMP.js +0 -2
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as M}from"./ZJEARGVC.js";import{a as z}from"./KLSSO2IB.js";import{c as S}from"./S4I3X6AX.js";import e from"./DOCOL5GC.js";import{a as C}from"./SL2D573Y.js";import d from"./CKTJHIDM.js";import b from"./LLPQYUPW.js";import{h as k}from"./DFXZ77W6.js";import"./LEIE3RAW.js";import a from"./KGXW3NCW.js";import"./PYF4Y6SP.js";import{M as u,N as h,O as $,P as _,U as y,a as x,b as n,f as c,q as g,x as v}from"./6MQTAMXU.js";import"./3TTFCHAA.js";export default $arcgis.t(([{convertUnit:D},{getDefaultUnitForView:U},{hasDisplayProperties:b},I,O,f,A,,,,P])=>{var V=x`[class^=esri-icon-],[class*=" esri-icon-"]{speak:none;font-variant:normal;text-transform:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-style:normal;font-weight:var(--calcite-font-weight-normal);line-height:1;font-family:CalciteWebCoreIcons!important}.esri-icon-close:before{content:"";color:inherit}.esri-icon-drag-horizontal:before{content:"";color:inherit}.esri-icon-drag-vertical:before{content:"";color:inherit}.esri-icon-handle-horizontal:before{content:"";color:inherit}.esri-icon-handle-vertical:before{content:"";color:inherit}.esri-icon-check-mark:before{content:"";color:inherit}.esri-icon-left-triangle-arrow:before{content:"";color:inherit}.esri-icon-right-triangle-arrow:before{content:"";color:inherit}.esri-icon-down-arrow:before{content:"";color:inherit}.esri-icon-up-arrow:before{content:"";color:inherit}.esri-icon-overview-arrow-bottom-left:before{content:"";color:inherit}.esri-icon-overview-arrow-bottom-right:before{content:"";color:inherit}.esri-icon-overview-arrow-top-left:before{content:"";color:inherit}.esri-icon-overview-arrow-top-right:before{content:"";color:inherit}.esri-icon-maximize:before{content:"";color:inherit}.esri-icon-minimize:before{content:"";color:inherit}.esri-icon-checkbox-unchecked:before{content:"";color:inherit}.esri-icon-checkbox-checked:before{content:"";color:inherit}.esri-icon-radio-unchecked:before{content:"";color:inherit}.esri-icon-radio-checked:before{content:"";color:inherit}.esri-icon-up-arrow-circled:before{content:"";color:inherit}.esri-icon-down-arrow-circled:before{content:"";color:inherit}.esri-icon-left-arrow-circled:before{content:"";color:inherit}.esri-icon-right-arrow-circled:before{content:"";color:inherit}.esri-icon-zoom-out-fixed:before{content:"";color:inherit}.esri-icon-zoom-in-fixed:before{content:"";color:inherit}.esri-icon-refresh:before{content:"";color:inherit}.esri-icon-edit:before{content:"";color:inherit}.esri-icon-authorize:before{content:"";color:inherit}.esri-icon-map-pin:before{content:"";color:inherit}.esri-icon-blank-map-pin:before{content:"";color:inherit}.esri-icon-table:before{content:"";color:inherit}.esri-icon-plus:before{content:"";color:inherit}.esri-icon-minus:before{content:"";color:inherit}.esri-icon-beginning:before{content:"";color:inherit}.esri-icon-reverse:before{content:"";color:inherit}.esri-icon-pause:before{content:"";color:inherit}.esri-icon-play:before{content:"";color:inherit}.esri-icon-forward:before{content:"";color:inherit}.esri-icon-end:before{content:"";color:inherit}.esri-icon-erase:before{content:"";color:inherit}.esri-icon-up-down-arrows:before{content:"";color:inherit}.esri-icon-left:before{content:"";color:inherit}.esri-icon-right:before{content:"";color:inherit}.esri-icon-announcement:before{content:"";color:inherit}.esri-icon-notice-round:before{content:"";color:inherit}.esri-icon-notice-triangle:before{content:"";color:inherit}.esri-icon-home:before{content:"";color:inherit}.esri-icon-locate:before{content:"";color:inherit}.esri-icon-expand:before{content:"";color:inherit}.esri-icon-collapse:before{content:"";color:inherit}.esri-icon-layer-list:before{content:"";color:inherit}.esri-icon-basemap:before{content:"";color:inherit}.esri-icon-globe:before{content:"";color:inherit}.esri-icon-applications:before{content:"";color:inherit}.esri-icon-arrow-up-circled:before{content:"";color:inherit}.esri-icon-arrow-down-circled:before{content:"";color:inherit}.esri-icon-arrow-left-circled:before{content:"";color:inherit}.esri-icon-arrow-right-circled:before{content:"";color:inherit}.esri-icon-minus-circled:before{content:"";color:inherit}.esri-icon-plus-circled:before{content:"";color:inherit}.esri-icon-add-attachment:before{content:"";color:inherit}.esri-icon-attachment:before{content:"";color:inherit}.esri-icon-calendar:before{content:"";color:inherit}.esri-icon-close-circled:before{content:"";color:inherit}.esri-icon-browser:before{content:"";color:inherit}.esri-icon-collection:before{content:"";color:inherit}.esri-icon-comment:before{content:"";color:inherit}.esri-icon-configure-popup:before{content:"";color:inherit}.esri-icon-contact:before{content:"";color:inherit}.esri-icon-dashboard:before{content:"";color:inherit}.esri-icon-deny:before{content:"";color:inherit}.esri-icon-description:before{content:"";color:inherit}.esri-icon-directions:before{content:"";color:inherit}.esri-icon-directions2:before{content:"";color:inherit}.esri-icon-documentation:before{content:"";color:inherit}.esri-icon-duplicate:before{content:"";color:inherit}.esri-icon-review:before{content:"";color:inherit}.esri-icon-environment-settings:before{content:"";color:inherit}.esri-icon-error:before{content:"";color:inherit}.esri-icon-error2:before{content:"";color:inherit}.esri-icon-experimental:before{content:"";color:inherit}.esri-icon-feature-layer:before{content:"";color:inherit}.esri-icon-filter:before{content:"";color:inherit}.esri-icon-grant:before{content:"";color:inherit}.esri-icon-group:before{content:"";color:inherit}.esri-icon-key:before{content:"";color:inherit}.esri-icon-labels:before{content:"";color:inherit}.esri-icon-tag:before{content:"";color:inherit}.esri-icon-layers:before{content:"";color:inherit}.esri-icon-left-arrow:before{content:"";color:inherit}.esri-icon-right-arrow:before{content:"";color:inherit}.esri-icon-link-external:before{content:"";color:inherit}.esri-icon-link:before{content:"";color:inherit}.esri-icon-loading-indicator:before{content:"";color:inherit}.esri-icon-maps:before{content:"";color:inherit}.esri-icon-marketplace:before{content:"";color:inherit}.esri-icon-media:before{content:"";color:inherit}.esri-icon-media2:before{content:"";color:inherit}.esri-icon-menu:before{content:"";color:inherit}.esri-icon-mobile:before{content:"";color:inherit}.esri-icon-phone:before{content:"";color:inherit}.esri-icon-navigation:before{content:"";color:inherit}.esri-icon-pan:before{content:"";color:inherit}.esri-icon-printer:before{content:"";color:inherit}.esri-icon-pie-chart:before{content:"";color:inherit}.esri-icon-chart:before{content:"";color:inherit}.esri-icon-line-chart:before{content:"";color:inherit}.esri-icon-question:before{content:"";color:inherit}.esri-icon-resend-invitation:before{content:"";color:inherit}.esri-icon-rotate:before{content:"";color:inherit}.esri-icon-save:before{content:"";color:inherit}.esri-icon-settings:before{content:"";color:inherit}.esri-icon-settings2:before{content:"";color:inherit}.esri-icon-share:before{content:"";color:inherit}.esri-icon-sign-out:before{content:"";color:inherit}.esri-icon-support:before{content:"";color:inherit}.esri-icon-user:before{content:"";color:inherit}.esri-icon-time-clock:before{content:"";color:inherit}.esri-icon-trash:before{content:"";color:inherit}.esri-icon-upload:before{content:"";color:inherit}.esri-icon-download:before{content:"";color:inherit}.esri-icon-zoom-in-magnifying-glass:before{content:"";color:#6e6e6e}.esri-icon-search:before{content:"";color:inherit}.esri-icon-zoom-out-magnifying-glass:before{content:"";color:#6e6e6e}.esri-icon-locked:before{content:"";color:inherit}.esri-icon-unlocked:before{content:"";color:inherit}.esri-icon-favorites:before{content:"";color:inherit}.esri-icon-compass:before{content:"";color:inherit}.esri-icon-down:before{content:"";color:inherit}.esri-icon-up:before{content:"";color:inherit}.esri-icon-chat:before{content:"";color:inherit}.esri-icon-dock-bottom:before{content:"";color:inherit}.esri-icon-dock-left:before{content:"";color:inherit}.esri-icon-dock-right:before{content:"";color:inherit}.esri-icon-organization:before{content:"";color:inherit}.esri-icon-north-navigation:before{content:"";color:inherit}.esri-icon-locate-circled:before{content:"";color:inherit}.esri-icon-dial:before{content:"";color:inherit}.esri-icon-polygon:before{content:"";color:inherit}.esri-icon-polyline:before{content:"";color:inherit}.esri-icon-visible:before{content:"";color:inherit}.esri-icon-non-visible:before{content:"";color:inherit}.esri-icon-link-vertical:before{content:"";color:inherit}.esri-icon-unlocked-link-vertical:before{content:"";color:inherit}.esri-icon-link-horizontal:before{content:"";color:inherit}.esri-icon-unlocked-link-horizontal:before{content:"";color:inherit}.esri-icon-swap:before{content:"";color:inherit}.esri-icon-cta-link-external:before{content:"";color:inherit}.esri-icon-reply:before{content:"";color:inherit}.esri-icon-public:before{content:"";color:inherit}.esri-icon-share2:before{content:"";color:inherit}.esri-icon-launch-link-external:before{content:"";color:inherit}.esri-icon-rotate-back:before{content:"";color:inherit}.esri-icon-pan2:before{content:"";color:inherit}.esri-icon-tracking:before{content:"";color:inherit}.esri-icon-expand2:before{content:"";color:inherit}.esri-icon-arrow-down:before{content:"";color:inherit}.esri-icon-arrow-up:before{content:"";color:inherit}.esri-icon-hollow-eye:before{content:"";color:inherit}.esri-icon-play-circled:before{content:"";color:inherit}.esri-icon-volume-off:before{content:"";color:inherit}.esri-icon-volume-on:before{content:"";color:inherit}.esri-icon-bookmark:before{content:"";color:inherit}.esri-icon-lightbulb:before{content:"";color:inherit}.esri-icon-sketch-rectangle:before{content:"";color:inherit}.esri-icon-north-navigation-filled:before{content:"";color:inherit}.esri-icon-default-action:before{content:"";color:inherit}.esri-icon-undo:before{content:"";color:inherit}.esri-icon-redo:before{content:"";color:inherit}.esri-icon-cursor:before{content:"";color:inherit}.esri-icon-cursor-filled:before{content:"";color:inherit}.esri-icon-measure:before{content:"";color:inherit}.esri-icon-measure-line:before{content:"";color:inherit}.esri-icon-measure-area:before{content:"";color:inherit}.esri-icon-legend:before{content:"";color:inherit}.esri-icon-sliders:before{content:"";color:inherit}.esri-icon-sliders-horizontal:before{content:"";color:inherit}.esri-icon-cursor-marquee:before{content:"";color:inherit}.esri-icon-lasso:before{content:"";color:inherit}.esri-icon-elevation-profile:before{content:"";color:inherit}.esri-icon-slice:before{content:"";color:inherit}.esri-icon-line-of-sight:before{content:"";color:inherit}.esri-icon-zoom-to-object:before{content:"";color:inherit}.esri-icon-urban-model:before{content:"";color:inherit}.esri-icon-measure-building-height-shadow:before{content:"";color:inherit}.esri-icon-partly-cloudy:before{content:"";color:inherit}.esri-widget__heading{color:var(--calcite-color-text-2);margin:0 0 .5rem;font-weight:var(--calcite-font-weight-semibold)}h1.esri-widget__heading{font-size:var(--calcite-font-size-xl)}h2.esri-widget__heading{font-size:var(--calcite-font-size-md)}h3.esri-widget__heading,h4.esri-widget__heading,h5.esri-widget__heading,h6.esri-widget__heading{font-size:var(--calcite-font-size)}.esri-widget{box-sizing:border-box;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size);line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget *,.esri-widget :before,.esri-widget :after{box-sizing:inherit}.esri-widget.esri-widget--disabled>*{opacity:.4;pointer-events:none}.esri-widget.esri-widget--compact{--esri-widget-padding-y: 0;--esri-widget-padding-x: 0}.esri-widget__anchor{color:var(--calcite-color-text-2)}.esri-widget__anchor:hover{color:var(--calcite-color-text-3)}.esri-widget__anchor:hover,.esri-widget__anchor:focus{text-decoration:underline}.esri-widget__anchor--disabled{opacity:.4;pointer-events:none}.esri-widget__header{background-color:var(--calcite-color-foreground-1);flex:1 0 100%;justify-content:space-between;align-items:center;width:100%;min-height:48px;padding:12px 0 12px 15px;display:flex}.esri-widget__heading{word-break:break-word}.esri-widget__header .esri-widget__heading{width:calc(100% - 48px);text-align:initial;color:var(--calcite-color-text-1);align-items:center;margin:0;padding:0;display:flex}.esri-widget__header-button{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);border:none;flex:0 0 48px;justify-content:center;align-self:stretch;align-items:center;width:48px;padding:0;display:flex}.esri-widget__footer{background-color:var(--calcite-color-foreground-1);justify-content:center;align-items:center;width:100%;min-height:48px;display:flex}.esri-widget__footer-pagination{color:var(--calcite-color-text-2);justify-content:space-between;align-items:center;display:flex}.esri-widget__footer-pagination-previous-button,.esri-widget__footer-pagination-next-button{cursor:pointer;background-color:var(--calcite-color-foreground-1);border:0;margin:0 7px;padding:12px 15px;transition:background-color .125s ease-in-out}.esri-widget__footer-pagination-previous-button:hover,.esri-widget__footer-pagination-previous-button:focus,.esri-widget__footer-pagination-next-button:hover,.esri-widget__footer-pagination-next-button:focus{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-menu{visibility:hidden;z-index:1;background-clip:padding;background-color:var(--calcite-color-foreground-1);background-clip:padding-box;width:100%;max-height:0;margin:2px 0 0;padding:0;font-size:var(--calcite-font-size);line-height:var(--calcite-spacing-xl);position:absolute;top:100%;left:0;overflow:hidden;box-shadow:0 1px 2px #0000004d}.esri-menu .esri-menu__header{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-inverse);padding:6px 12px}.esri-menu__list{margin:0;padding:0;list-style:none}.esri-menu__list-item{cursor:pointer;border-top:1px solid #adadad4d;border-left:3px solid #0000;padding:.8em 1em}.esri-menu__list-item [class^=esri-icon-],.esri-menu__list-item [class*=" esri-icon-"]{padding-right:2.8px}.esri-menu__list-item:first-child{border-top:none}.esri-menu__list-item--focus,.esri-menu__list-item:hover,.esri-menu__list-item:focus{background-color:var(--calcite-color-foreground-1)}.esri-menu__list-item:active{background-color:var(--calcite-color-foreground-current)}.esri-menu__list-item--active,.esri-menu__list-item--active:hover,.esri-menu__list-item--active:focus{background-color:var(--calcite-color-foreground-1);border-left-color:var(--calcite-color-brand)}.esri-widget__table{border-collapse:collapse;color:var(--calcite-color-text-1);border:none;width:100%;line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget__table tr:nth-child(odd){background-color:var(--calcite-color-transparent)}.esri-widget__table tr:nth-child(2n){background-color:var(--calcite-color-transparent-press)}.esri-widget__table tr a{color:var(--calcite-color-text-2)}.esri-widget__table tr a:hover,.esri-widget__table tr a:focus{color:var(--calcite-color-text-1)}.esri-widget__table tr td,.esri-widget__table tr th{vertical-align:top;word-break:break-word;padding:.5em .7em;font-size:var(--calcite-font-size-sm);font-weight:var(--calcite-font-weight-regular)}.esri-widget__table tr th{text-align:left;border-right:3px solid #0000000d;width:50%}.esri-widget__table tr td{width:50%}.esri-input{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1);border:1px solid #959595;font-size:var(--calcite-font-size)}.esri-input::-ms-clear{display:none}.esri-input::placeholder{opacity:1;color:var(--calcite-color-text-2)}.esri-input:placeholder-shown{text-overflow:ellipsis}.esri-input[type=text],.esri-input[type=password],.esri-input[type=number]{height:32px;padding:0 .5em}calcite-combobox.esri-input{border:none}.esri-widget__content--empty{text-align:center;color:var(--calcite-color-border-input);flex-flow:column wrap;align-items:center;padding:18px 22px;display:flex}.esri-widget__content--empty h1.esri-widget__heading,.esri-widget__content--empty h2.esri-widget__heading,.esri-widget__content--empty h3.esri-widget__heading,.esri-widget__content--empty h4.esri-widget__heading,.esri-widget__content--empty h5.esri-widget__heading{font-weight:var(--calcite-font-weight-regular)}.esri-widget__content-illustration--empty{width:128px;padding:1rem 0}.esri-widget__content-icon--empty{width:32px;padding:.5rem 0}.esri-select{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background:var(--calcite-color-foreground-1) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 32 32' width='32' height='32'%3E%3Cpath d='M8 11.207l-4-4V5.793l4 4 4-4v1.414z' fill='%23adadad' fillrule='nonzero'/%3E%3C/svg%3E") 100% no-repeat;border:1px solid #959595;border-radius:0;width:100%;height:32px;margin:0;padding:0 .5em;font-family:inherit;font-size:.85em;display:block}.esri-select[disabled]{cursor:auto}.esri-select::-ms-expand{display:none}.esri-disabled a,.esri-disabled [role=menu],.esri-disabled [role=checkbox],.esri-disabled [class^=esri-icon-],.esri-disabled [class*=" esri-icon-"]{color:var(--calcite-color-text-3)}.keynav-mode .esri-widget:focus,.keynav-mode .esri-widget :focus{z-index:1;outline-offset:2px;outline:2px solid #adadad}.esri-widget__loader-animation{border:.15em solid #adadad4d;border-top-color:var(--calcite-color-border-input);border-radius:100%;width:1em;height:1em;font-size:var(--calcite-font-size-md);animation:1.25s linear infinite esri-rotate;display:block;transform:translateZ(0)}:dir(rtl) .esri-widget__table th{text-align:right;border-left:3px solid #0000000d;border-right:none}:dir(rtl) .esri-select{background-position:0}:dir(rtl) .esri-menu__list-item{border-left:none;border-right:3px solid #0000}:dir(rtl) .esri-menu__list-item [class^=esri-icon-],:dir(rtl) .esri-menu__list-item [class*=" esri-icon-"]{padding-left:2px;padding-right:0}:dir(rtl) .esri-menu__list-item--active{border-right-color:var(--calcite-color-brand)}.esri-icon-font-fallback-text{clip:rect(0 0 0 0);width:1px;height:1px;position:absolute;overflow:hidden}.esri-rotating{animation:1.25s linear infinite esri-rotate;transform:translateZ(0)}.esri-clearfix:before,.esri-clearfix:after{content:" ";display:table}.esri-clearfix:after{clear:both}.esri-interactive{cursor:pointer}.esri-hidden{display:none!important}.esri-invisible{visibility:hidden!important}.esri-offscreen{position:absolute;top:-999em;left:-999em}.esri-match-height{flex-direction:column;flex:auto;display:flex;overflow:hidden}.esri-button{box-sizing:border-box;cursor:pointer;white-space:normal;word-break:normal;color:var(--calcite-color-text-1);background-color:var(--calcite-color-status-info);border:var(--calcite-spacing-px) solid var(--calcite-color-status-info);justify-content:center;align-items:center;width:100%;min-height:var(--calcite-spacing-xxxl);padding:6px 7px;font-family:inherit;font-size:var(--calcite-font-size);transition:background-color .125s ease-in-out,border .125s ease-in-out;display:flex;overflow:hidden;&:hover{color:var(--calcite-color-text-1);background-color:var(--calcite-color-status-info-hover);border:var(--calcite-spacing-px) solid var(--calcite-color-status-info-hover)}}.esri-button:hover{color:var(--calcite-color-text-1);background-color:var(--calcite-color-text-2);border:1px solid var(--calcite-color-text-2)}.esri-button.esri-button--small{min-height:var(--calcite-spacing-xl);font-size:var(--calcite-font-size-sm)}.esri-button.esri-button--half{width:50%;display:inline-block}.esri-button.esri-button--third{width:33%;display:inline-block}.esri-button--secondary{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-button--tertiary{color:var(--calcite-color-brand);background-color:var(--calcite-color-transparent);border-color:var(--calcite-color-transparent)}.esri-button--tertiary:hover{color:var(--calcite-color-brand-hover);background-color:var(--calcite-color-foreground-2);border-color:var(--calcite-color-transparent)}.esri-button--disabled{opacity:.4;pointer-events:none}.esri-button--drill-in{outline-offset:-4px;cursor:pointer;text-align:unset;background-color:var(--calcite-color-foreground-1);border:none;border-radius:2px;justify-content:space-between;align-items:center;margin:var(--calcite-spacing-md) 7px;padding:var(--calcite-spacing-md) 7px;text-decoration:none;transition:background-color .125s ease-in-out;display:flex;box-shadow:0 0 0 1px #adadad4d}.esri-button--drill-in:hover,.esri-button--drill-in:focus{background-color:var(--calcite-color-foreground-2)}.esri-button--drill-in__title{font-size:var(--calcite-font-size)}.esri-button--drill-in [class^=esri-icon-],.esri-button--drill-in [class*=" esri-icon-"]{padding:0 7px}.esri-widget--button{cursor:pointer;text-align:center;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);flex-flow:row;justify-content:center;align-items:center;width:var(--calcite-spacing-xxxl);height:var(--calcite-spacing-xxxl);margin:0;padding:0;font-size:var(--calcite-font-size);transition:background-color .125s ease-in-out;display:flex;overflow:hidden}.esri-widget--button:is(calcite-button):not(:hover){--calcite-icon-color: var(--calcite-color-text-3)}.esri-widget--button:not([appearance]),.esri-widget--button[appearance=solid]{--calcite-color-foreground-3: var(--calcite-color-foreground-1)}.esri-widget--button:is(calcite-button){--calcite-offset-invert-focus: 1}.esri-widget--button calcite-loader[inline]{margin:auto}.esri-button--secondary{color:var(--calcite-color-brand);background-color:var(--calcite-color-foreground-1);&:hover{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-status-info);border:1px solid var(--calcite-color-status-info)}}:host{background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);padding-block-start:var(--arcgis-coordinate-conversion-padding-y);width:var(--arcgis-coordinate-conversion-width, 280px)}.root{background-color:var(--calcite-color-foreground-1)}calcite-alert{--calcite-alert-offset-size: var(--calcite-spacing-sm)}calcite-notice[open]{padding:var(--calcite-spacing-sm)}calcite-block{--calcite-block-content-space: 0;margin:0;padding-inline:var(--arcgis-coordinate-conversion-padding-x)}calcite-block:last-of-type{padding-block-end:var(--arcgis-coordinate-conversion-padding-y, var(--calcite-spacing-sm))}.conversion-popover{--calcite-popover-max-size-x: var(--arcgis-coordinate-conversion-settings-block-size, 250px)}.go-to-input-holder{display:flex}.go-to-input-holder calcite-input{flex:1}.conversions-block{border:none;padding-bottom:var(--calcite-spacing-sm)}.live-mode-block{--calcite-label-margin-bottom: 0;padding-block:var(--calcite-spacing-sm);padding-inline:var(--arcgis-coordinate-conversion-padding-x, var(--calcite-spacing-sm))}.live-mode-label{width:fit-content;margin-inline-start:auto}.font-size-small{font-size:var(--calcite-font-size--2)}.format-radio-label{display:flex;flex-direction:column}.radio-label{font-weight:var(--calcite-font-weight-medium);font-size:var(--calcite-font-size--2)}.radio-description{font-weight:var(--calcite-font-weight-light);font-size:var(--calcite-font-size--3)}.unit-select-panel{--calcite-panel-space: var(--calcite-spacing-md)}.popover-footer{padding:var(--calcite-spacing-sm);border-top:1px solid var(--calcite-color-border-3)}.input-form-group{display:flex;flex-direction:column;align-items:flex-start;padding:var(--calcite-spacing-sm)}.add-conversion-trigger{margin-inline-start:var(--calcite-spacing-sm);margin-block-start:var(--calcite-spacing-sm)}.input-form-group calcite-label{width:100%}.settings{padding:var(--calcite-spacing-md);display:flex;flex-direction:column;align-items:center;background-color:var(--calcite-color-foreground-1);width:calc(var(--arcgis-coordinate-conversion-settings-block-size, 250px) - (2 * var(--calcite-spacing-md)) - 2px)}.settings calcite-label{width:100%}.settings calcite-input{flex:1}.settings-form-group-horizontal{display:flex}`,q=2500,B=new I({x:0,y:0}),l={copy:"copy",gear:"gear",goTo:"zoom-to-object",lightbulb:"lightbulb",plus:"plus",refresh:"refresh",warning:"exclamation-mark-triangle"},j=P(O),m=class extends ${constructor(){super(...arguments),this._alertTimer=-1,this._conversionPopoverMap=new Map,this._coordinateInput=u(),this.messages=C({name:"coordinate-conversion-next",blocking:!0}),this._multipleConversionsDisabled=!1,this.quantityFormatter=new A,this.viewModel=j(this),this.clearAlertTimeout=()=>{window.clearTimeout(this._alertTimer),this.alertProperties={...this.alertProperties,open:!1}},this.onElevationPopoverTriggerMount=e=>{this._elevationPopoverTrigger=e},this.onFormatPopoverTriggerMount=e=>{this._formatsPopoverTrigger=e},this.handleFormatComboboxChange=e=>{let i=e.target.selectedItems[0].value,o=this.formats.find(t=>t.name===i);if(o){let t=this.activeConversion??this.conversions.at(0)??null,r=new f({format:o});t&&this.transferConversionPopoverState(t,r),this.conversions.splice(0,1,r),this.activeConversion=r,this.setPreviewConversion()}},this.alertProperties={kind:"brand",message:null,title:null,open:!1},this.elevationPopoverOpen=!1,this.formatsPopoverOpen=!1,this.invalidInput=!1,this.view=this.viewModel.view,this.autoDestroyDisabled=!1,this.conversions=this.viewModel.conversions,this.currentLocation=this.viewModel.currentLocation,this.formats=this.viewModel.formats,this.goToOverride=this.viewModel.goToOverride,this.headingLevel=4,this.hideCaptureSection=!1,this.hideInputSection=!1,this.hideSettingsButton=!1,this.icon="coordinate-system",this.label=this.messages.componentLabel,this.locationSymbol=this.viewModel.locationSymbol,this.mode=this.viewModel.mode,this.removeLeadingZeros=this.viewModel.removeLeadingZeros,this.visualScale="s",this.showElevation=!1,this.state=this.viewModel.state,this.storageType=this.viewModel.storageType,this.arcgisConversionChange=v(),this.arcgisPropertyChange=k()("currentLocation","state","mode","verticalUnit"),this.arcgisReady=v(),this.renderConversionView=(e,i)=>{let{messages:o}=this,{format:t}=e,r=t?.label??"",s=i===0&&!e.displayCoordinate?o.noLocation:e.displayCoordinate,a=this._renderConversionActions(e,s);return z(e?.format?.name,n`<calcite-list-item class="conversion-list-item" .description=${r.toUpperCase()} .label=${this.getDisplayCoordinate(s)} .scale=${this.visualScale} title=${s??void 0??c}>${a}</calcite-list-item>`)},this.renderLiveModeSection=()=>{let{messages:e}=this,i=this.mode==="idle"?this.viewModel.mode:this.mode;return n`<calcite-block class="live-mode-block" .disabled=${this.disabled} expanded .headingLevel=${this.headingLevel} .label=${e.captureMode} .scale=${this.visualScale}><calcite-label alignment=end class="live-mode-label" layout=inline .scale=${this.visualScale}>${e.captureMode}<calcite-switch .checked=${i==="capture"} @calciteSwitchChange=${this.toggleMode}></calcite-switch></calcite-label></calcite-block>`}}static{this.properties={activeConversion:16,alertProperties:16,defaultMeasurementSystem:16,disabled:16,displayedElevation:16,elevationPopoverOpen:16,formatsPopoverOpen:16,invalidInput:16,inputFormat:16,previewConversion:16,view:0,autoDestroyDisabled:5,conversions:0,currentLocation:0,formats:0,goToOverride:0,headingLevel:9,hideCaptureSection:7,hideInputSection:7,hideSettingsButton:7,icon:1,ignoreCoordinatePrecision:5,label:1,locationSymbol:0,mode:3,multipleConversionsDisabled:7,referenceElement:1,removeLeadingZeros:7,visualScale:1,showElevation:7,state:32,storageDisabled:7,storageType:1,verticalUnit:1}}static{this.styles=V}get defaultMeasurementSystem(){return this.view?.ready?U(this.view):"metric"}get disabled(){return this.viewModel.state==="disabled"}get displayedElevation(){let{currentLocation:e,verticalUnit:i,messages:o}=this;if(e?.z===void 0||e.z===null)return o.noElevation;{let t=D(e.z,"meters",i);return this.quantityFormatter.formatLength({value:t,unit:i,type:"length"},2,"plural")}}get ignoreCoordinatePrecision(){return!this.viewModel.calculateCoordinatePrecision}set ignoreCoordinatePrecision(e){this.viewModel.calculateCoordinatePrecision=!e}get multipleConversionsDisabled(){return this._multipleConversionsDisabled}set multipleConversionsDisabled(e){e&&this.conversions.splice(1,this.conversions.length-1),this._multipleConversionsDisabled=e}get storageDisabled(){return!this.viewModel.storageEnabled}set storageDisabled(e){this.viewModel.storageEnabled=!e}get verticalUnit(){return this.viewModel.verticalUnit??(this.defaultMeasurementSystem==="imperial"?"feet":"meters")}set verticalUnit(e){this.viewModel.verticalUnit=e}async destroy(){this.clearAlertTimeout(),await this.manager.destroy()}async reverseConvert(e,i){return await this.viewModel.reverseConvert(e,i)}load(){this.manager.onLifecycle(()=>[this.conversions.on("change",()=>this.arcgisConversionChange.emit())])}willUpdate(e){if(e.has("mode")&&this.mode==="idle"){this.viewModel.setLocation(this.currentLocation);return}if(e.has("currentLocation")){let i=e.get("currentLocation");this.mode==="idle"&&!this.currentLocation?.equals(i)&&this.viewModel.setLocation(this.currentLocation)}}closeAllPopovers(){for(let e of this._conversionPopoverMap.values())e.open=!1;this.elevationPopoverOpen=!1,this.formatsPopoverOpen=!1,this.requestUpdate()}async copyToClipboard(e){e&&(e=e.replace(/‎/gu,""),await navigator.clipboard.writeText(e))}findSettingsFormat(){return this.activeConversion?.format||this.conversions.reduceRight((e,i)=>{let o=i.format;return o&&b(o)?o:e},null)||this.formats.find(e=>b(e))||null}getConversionPopoverState(e){let i=this._conversionPopoverMap.get(e);return i||(i={triggerRef:u(),open:!1},this._conversionPopoverMap.set(e,i)),i}getDisplayCoordinate(e){return e?e.includes(",")?e.replace(/, /gu,",\xA0\u200B").replace(/ /gu,"\xA0"):e:"\u200B"}getFormatDescription(e){let{messages:i}=this;return i.formatDescriptions[e.name]??i.formatDescriptions.custom}getId(e){return`arcgis-coordinate-conversion-${e}`}openConversionSettings(e,i){let o=this.getConversionPopoverState(e),t=this.activeConversion!==e||!o.open;this.closeAllPopovers(),o.open=t,this._conversionPopoverTrigger=t?i.currentTarget:void 0,this.activeConversion=t?e:void 0,t&&this.setPreviewConversion(),this.requestUpdate(),i.stopPropagation()}async processUserInput(e,i,o){let{viewModel:t}=this;try{let r=await this._reverseConvert(e,i);if(r)o&&t.goToLocation(r).catch(s=>{g(this)(s),this.showAlertMessage(null,this.messages.locationOffBasemap,"warning")});else throw new Error("failed to process user input");this.mode==="capture"?t.resume():this.mode="capture",this.invalidInput=!1,this.currentLocation=r??void 0,t.setLocation(r)}catch(r){g(this)(r),this.showAlertMessage(null,this.messages.invalidCoordinate,"warning"),this.invalidInput=!0}}async processUserKeyboardInput(e){let{key:i}=e;if(i==="Enter"){let o=this.inputFormat||this.conversions.at(0)?.format,t=this._coordinateInput.value?.value;if(!o||!t)return;await this.processUserInput(t,o,!0)}else this.invalidInput=!1}async processUserMouseInput(e){let i=this.inputFormat||this.conversions.at(0)?.format,o=this._coordinateInput.value?.value;!i||!o||await this.processUserInput(o,i,e)}async _reverseConvert(e,i){return await i.reverseConvert(e)}setDefaultPattern(e){e.stopPropagation();let i=this.findSettingsFormat();i?.defaultPattern&&(i.currentPattern=i.defaultPattern)}setInputFormat(e){let i=e.target.selectedOption.value;i!==null&&(this.inputFormat=i)}setPreviewConversion(){let e=this.findSettingsFormat(),i=this.viewModel;if(e){let o=this.conversions.find(t=>t.format===e);this.previewConversion=new f({format:e,position:{location:this.currentLocation,coordinate:o?.position?.coordinate}}),this.previewConversion.position?.coordinate||i.previewConversion(this.previewConversion,i.currentLocation??B)}}showAlertMessage(e,i,o,t=q){this.alertProperties={...this.alertProperties,title:e,message:i,kind:o,open:!0},window.clearTimeout(this._alertTimer),this._alertTimer=window.setTimeout(()=>{this.alertProperties={...this.alertProperties,open:!1}},t)}toggleConversion(e){let i=e.target,o=this.formats.find(t=>t.name===i.getAttribute("data-format"));if(o){let t=this.conversions.find(r=>r.format===o);if(t){if(this.conversions.length>1){let r=this._conversionPopoverMap.get(t);r&&(r.open=!1,this._conversionPopoverMap.delete(t)),this.activeConversion===t&&(this.activeConversion=void 0),this.conversions.remove(t)}}else{let r=new f({format:o});this.conversions.add(r)}}}toggleMode(){this.mode=this.viewModel.mode==="live"?"capture":"live"}transferConversionPopoverState(e,i){let o=this.getConversionPopoverState(e),t=this.getConversionPopoverState(i);t.open=o.open,this._conversionPopoverMap.delete(e)}updateCurrentPattern(e){e.stopPropagation();let i=e.target,o=this.findSettingsFormat();o&&(o.currentPattern=i.value)}render(){let{headingLevel:e}=this,i=this.renderConversionPopover();return n`<calcite-panel class=root .headingLevel=${e} .scale=${this.visualScale}>${this.renderConversionsView()}${this.renderAlert()}</calcite-panel>${i}`}renderAlert(){let{messages:e}=this,{open:i,message:o,title:t,kind:r}=this.alertProperties;return n`<calcite-alert class="alert" .kind=${r} .label=${e.alertLabel} @calciteAlertClose=${this.clearAlertTimeout} .open=${i} placement=top .scale=${this.visualScale} slot=alerts>${t?n`<div slot=title>${t}</div>`:null}${o?n`<div slot=message>${o}</div>`:null}</calcite-alert>`}_renderConversionActions(e,i){let{messages:o}=this,t=this.getConversionPopoverState(e),r=o.settingsTitleWithFormat.replace("{formatName}",e.format?.name?.toUpperCase()??""),s=e.displayCoordinate&&this.mode!=="live";return n`<calcite-action-group layout=horizontal .scale=${this.visualScale} slot=actions-end>${s?n`<calcite-action .icon=${l.copy} .label=${o.copyLabel} @click=${()=>this.copyToClipboard(i)} .scale=${this.visualScale} .text=${o.copyLabel} title=${o.copyLabel??c}></calcite-action>`:null}${this.hideSettingsButton?null:n`<calcite-action data-format=${e.format?.name??c} .icon=${l.gear} .label=${r} @click=${a=>this.openConversionSettings(e,a)} .scale=${this.visualScale} .text=${r} title=${r??c} ${h(t.triggerRef)}></calcite-action>`}</calcite-action-group>`}renderConversionOptions(e,i){return e.map(o=>n`<calcite-option .label=${o.label.toUpperCase()} .selected=${o===i} .value=${o}>${o.label}</calcite-option>`)}renderConversionPopover(){let{activeConversion:e,messages:i}=this;if(!e)return null;let o=this.getConversionPopoverState(e),t=i.settingsTitleWithFormat.replace("{formatName}",e.format?.name?.toUpperCase()??"");return this.renderPopover({class:"conversion-popover",content:this.renderSettingsView(),getPopoverOpenProperty:()=>o.open,heading:t,includeFooter:!0,label:t,setPopoverOpenProperty:r=>{o.open=r,r||(this._conversionPopoverTrigger=void 0,this.activeConversion=void 0),this.requestUpdate()},trigger:null,triggerElement:o.triggerRef.value??this._conversionPopoverTrigger??void 0})}renderConversionsView(){if(!this.conversions)return;let{messages:e,multipleConversionsDisabled:i}=this,o=(i?this.conversions.slice(0,1):this.conversions).map(this.renderConversionView).reverse(),t=this.showElevation?this.renderElevation():null,r=this.hideCaptureSection?null:this.renderLiveModeSection(),s=this.hideInputSection?null:this.renderCoordinateInputView(),a=this.multipleConversionsDisabled?null:this.renderFormatDropdown(),d=this.disabled?n`<calcite-notice .icon=${l.lightbulb} .open=${this.disabled} width=full><div class="font-size-small" slot=message>${e.noBasemap}</div></calcite-notice>`:null;return n`${r}${d}${s}<calcite-block class="conversions-block" .disabled=${this.disabled} expanded .heading=${e.coordinates} .headingLevel=${this.headingLevel} .scale=${this.visualScale}><calcite-list interaction-mode=static .label=${e.coordinates} .scale=${this.visualScale}>${o}</calcite-list>${a}</calcite-block>${t}`}renderCoordinateInputView(){let{messages:e}=this,i=this.inputFormat??this.conversions.at(0)?.format,o=this.getId("coordinate-input"),t=this.renderConversionOptions(this.formats,i??void 0),r=n`<calcite-action .icon=${l.goTo} .label=${e.convertAndGoTo} @click=${()=>this.processUserMouseInput(!0)} .scale=${this.visualScale} .text=${e.convertAndGoTo} title=${e.convertAndGoTo??c}></calcite-action>`;return n`<calcite-block collapsible data-testid=input-block .disabled=${this.disabled} .heading=${e.input} .headingLevel=${this.headingLevel} .scale=${this.visualScale}><div class="input-form-group"><calcite-label .scale=${this.visualScale}>${e.inputFormat}<calcite-select aria-controls=${o??c} class="input-select" .label=${e.inputFormat} @calciteSelectChange=${this.setInputFormat} .scale=${this.visualScale}>${t}</calcite-select></calcite-label><calcite-label .scale=${this.visualScale}>${e.inputCoordTitle}<div class="go-to-input-holder"><calcite-input class="coordinate-input" data-format=${i??c} data-testid=coordinate-input id=${o??c} @keydown=${this.processUserKeyboardInput} .placeholder=${e.inputCoordTitle} required .scale=${this.visualScale} .status=${this.invalidInput?"invalid":"idle"} ${h(this._coordinateInput)}></calcite-input>${r}</div></calcite-label><calcite-button appearance=outline data-testid=convert-button kind=neutral @click=${()=>this.processUserMouseInput(!1)} type=button .scale=${this.visualScale} width=auto>${e.convert}</calcite-button></div></calcite-block>`}renderElevation(){let{messages:e}=this,i=this.displayedElevation??e.noElevation,o=this.renderElevationActions(),t=this.hideSettingsButton?null:this.renderElevationSettingsDropdown();return n`<calcite-block .disabled=${this.disabled} expanded .heading=${e.elevation} .headingLevel=${this.headingLevel} .scale=${this.visualScale}><calcite-list interaction-mode=static .label=${e.elevation} .scale=${this.visualScale}><calcite-list-item class="elevation-list-item" .label=${i} .scale=${this.visualScale} title=${i??c}>${o}</calcite-list-item></calcite-list>${t}</calcite-block>`}renderElevationActions(){let{messages:e}=this,i=this.currentLocation?.z!==void 0&&this.mode!=="live",o=this.displayedElevation??e.noElevation;return n`<calcite-action-group layout=horizontal .scale=${this.visualScale} slot=actions-end>${i?n`<calcite-action .icon=${l.copy} .label=${e.copyElevationLabel} @click=${()=>i&&this.copyToClipboard(o)} .scale=${this.visualScale} .text=${e.copyElevationLabel} title=${e.copyElevationLabel??c}></calcite-action>`:null}${this.hideSettingsButton?null:n`<calcite-action .icon=${l.gear} .label=${e.selectElevationUnit} .scale=${this.visualScale} .text=${e.selectElevationUnit} title=${e.selectElevationUnit??c} ${h(this.onElevationPopoverTriggerMount)}></calcite-action>`}</calcite-action-group>`}renderElevationSettingsDropdown(){let{messages:e}=this,i=n`<arcgis-unit-radio-button-group @arcgisUnitSelectChange=${o=>this.verticalUnit=o.detail} .options=${S} .name=${e.selectElevationUnit} .scale=${this.visualScale} .value=${this.verticalUnit}></arcgis-unit-radio-button-group>`;return this.renderPopover({content:i,closeOnEnter:!0,getPopoverOpenProperty:()=>this.elevationPopoverOpen,includeFooter:!1,label:e.selectElevationUnit,setPopoverOpenProperty:o=>this.elevationPopoverOpen=o,trigger:null,triggerElement:this._elevationPopoverTrigger})}renderFormatDropdown(){let{messages:e}=this,i=n`<calcite-list .label=${e.addConversion} .scale=${this.visualScale} selection-mode=multiple>${M(this.formats,t=>t,t=>{let r=!!this.conversions.find(a=>a.format===t),s=this.getFormatDescription(t);return n`<calcite-list-item data-format=${t.name??c} .description=${s} .disabled=${r&&this.conversions.length===1} .label=${t.label.toUpperCase()} @calciteListItemSelect=${this.toggleConversion} .selected=${r}></calcite-list-item>`})}</calcite-list>`,o=n`<calcite-button appearance=outline class="add-conversion-trigger" .iconStart=${l.plus} kind=neutral .label=${e.selectFormats} round .scale=${this.visualScale} ${h(this.onFormatPopoverTriggerMount)}>${e.selectFormats}</calcite-button>`;return this.renderPopover({content:i,includeFooter:!0,getPopoverOpenProperty:()=>this.formatsPopoverOpen,label:e.selectFormats,setPopoverOpenProperty:t=>this.formatsPopoverOpen=t,trigger:o,triggerElement:this._formatsPopoverTrigger})}renderPopover({content:e,class:i,closeOnEnter:o,heading:t,getPopoverOpenProperty:r,includeFooter:s,label:a,setPopoverOpenProperty:d,slot:L,trigger:E,triggerDisabled:T,triggerElement:w}){let{messages:F}=this;return n`${E}${w?n`<calcite-popover auto-close class=${_(i)} .heading=${t} .headingLevel=${this.headingLevel} .label=${a} @calcitePopoverBeforeOpen=${()=>{d(!0)}} @calcitePopoverClose=${p=>{d(!1),p.stopPropagation()}} @keydown=${p=>{o&&(p.key==="Enter"||p.key===" ")&&d(!1)}} .open=${r()} .referenceElement=${w} .scale=${this.visualScale} slot=${L??c} .triggerDisabled=${T}>${e}${s?n`<div class="popover-footer"><calcite-button appearance=solid class="popover-done-button" kind=brand @click=${()=>d(!1)} .scale=${this.visualScale} width=full>${F.done}</calcite-button></div>`:null}</calcite-popover>`:null}`}renderSettingsView(){let{messages:e}=this,i=this.findSettingsFormat(),o=this.getId("pattern-input"),t=this.getId("preview-coordinate"),r=i?.currentPattern,s=this.multipleConversionsDisabled?this.renderSingleFormatDropdown():null;if(!i||!b(i))return n`<div class="settings"><calcite-label .scale=${this.visualScale}>${e.format}${s??n`<calcite-notice class="no-display-properties-notice" .icon=${l.warning} open .scale=${this.visualScale}><div class="font-size-small" slot=message>${e.noDisplayProperties}</div></calcite-notice>`}</calcite-label></div>`;let a=n`<calcite-action .icon=${l.refresh} .label=${e.defaultPattern} @click=${this.setDefaultPattern} .scale=${this.visualScale} .text=${e.defaultPattern} title=${e.defaultPattern??c}></calcite-action>`;return n`<div class="settings"><calcite-label .scale=${this.visualScale}>${e.format}${s}</calcite-label><calcite-label .for=${o} .scale=${this.visualScale}>${e.display}<div class="settings-form-group-horizontal"><calcite-input aria-controls=${t??c} class="pattern-input" id=${o??c} @calciteInputInput=${this.updateCurrentPattern} .scale=${this.visualScale} type=text .value=${r}></calcite-input>${a}</div></calcite-label><calcite-label .scale=${this.visualScale}>${e.preview}<calcite-input read-only .scale=${this.visualScale} type=text .value=${this.previewConversion?.displayCoordinate??void 0}></calcite-input></calcite-label></div>`}renderSingleFormatDropdown(){let{messages:e}=this;return n`<calcite-combobox data-testid=single-format-combobox .label=${e.selectFormat} @calciteComboboxChange=${this.handleFormatComboboxChange} .scale=${this.visualScale} selection-mode=single-persist>${this.formats?.map(i=>n`<calcite-combobox-item .description=${this.getFormatDescription(i)} .heading=${i.label.toUpperCase()} .selected=${this.conversions.at(0)?.format===i} .value=${i.name}></calcite-combobox-item>`)}</calcite-combobox>`}};y("arcgis-coordinate-conversion-next",m);return m},"applications/Components/unitUtils","applications/Components/getDefaultUnits","applications/Components/formatUtils","geometry/Point","widgets/CoordinateConversion/CoordinateConversionViewModel","widgets/CoordinateConversion/support/Conversion","applications/Components/QuantityFormatter",a,b,d,e)
2
+ import{a as M}from"./ZEQYZ4ZW.js";import{a as z}from"./HS2QCKGL.js";import{c as S}from"./S4I3X6AX.js";import e from"./PX2BP3QJ.js";import{a as C}from"./NJE3P4JX.js";import d from"./K4LQ4LWP.js";import b from"./U5KGWKHD.js";import{h as k}from"./Z6JYZ2A2.js";import"./YYCNECYH.js";import a from"./7P4SZTMT.js";import"./6OM3S3VY.js";import{M as u,N as h,O as $,P as _,U as y,a as x,b as n,f as c,q as g,x as v}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{convertUnit:D},{getDefaultUnitForView:U},{hasDisplayProperties:b},I,O,f,A,,,,P])=>{var V=x`[class^=esri-icon-],[class*=" esri-icon-"]{speak:none;font-variant:normal;text-transform:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-style:normal;font-weight:var(--calcite-font-weight-normal);line-height:1;font-family:CalciteWebCoreIcons!important}.esri-icon-close:before{content:"";color:inherit}.esri-icon-drag-horizontal:before{content:"";color:inherit}.esri-icon-drag-vertical:before{content:"";color:inherit}.esri-icon-handle-horizontal:before{content:"";color:inherit}.esri-icon-handle-vertical:before{content:"";color:inherit}.esri-icon-check-mark:before{content:"";color:inherit}.esri-icon-left-triangle-arrow:before{content:"";color:inherit}.esri-icon-right-triangle-arrow:before{content:"";color:inherit}.esri-icon-down-arrow:before{content:"";color:inherit}.esri-icon-up-arrow:before{content:"";color:inherit}.esri-icon-overview-arrow-bottom-left:before{content:"";color:inherit}.esri-icon-overview-arrow-bottom-right:before{content:"";color:inherit}.esri-icon-overview-arrow-top-left:before{content:"";color:inherit}.esri-icon-overview-arrow-top-right:before{content:"";color:inherit}.esri-icon-maximize:before{content:"";color:inherit}.esri-icon-minimize:before{content:"";color:inherit}.esri-icon-checkbox-unchecked:before{content:"";color:inherit}.esri-icon-checkbox-checked:before{content:"";color:inherit}.esri-icon-radio-unchecked:before{content:"";color:inherit}.esri-icon-radio-checked:before{content:"";color:inherit}.esri-icon-up-arrow-circled:before{content:"";color:inherit}.esri-icon-down-arrow-circled:before{content:"";color:inherit}.esri-icon-left-arrow-circled:before{content:"";color:inherit}.esri-icon-right-arrow-circled:before{content:"";color:inherit}.esri-icon-zoom-out-fixed:before{content:"";color:inherit}.esri-icon-zoom-in-fixed:before{content:"";color:inherit}.esri-icon-refresh:before{content:"";color:inherit}.esri-icon-edit:before{content:"";color:inherit}.esri-icon-authorize:before{content:"";color:inherit}.esri-icon-map-pin:before{content:"";color:inherit}.esri-icon-blank-map-pin:before{content:"";color:inherit}.esri-icon-table:before{content:"";color:inherit}.esri-icon-plus:before{content:"";color:inherit}.esri-icon-minus:before{content:"";color:inherit}.esri-icon-beginning:before{content:"";color:inherit}.esri-icon-reverse:before{content:"";color:inherit}.esri-icon-pause:before{content:"";color:inherit}.esri-icon-play:before{content:"";color:inherit}.esri-icon-forward:before{content:"";color:inherit}.esri-icon-end:before{content:"";color:inherit}.esri-icon-erase:before{content:"";color:inherit}.esri-icon-up-down-arrows:before{content:"";color:inherit}.esri-icon-left:before{content:"";color:inherit}.esri-icon-right:before{content:"";color:inherit}.esri-icon-announcement:before{content:"";color:inherit}.esri-icon-notice-round:before{content:"";color:inherit}.esri-icon-notice-triangle:before{content:"";color:inherit}.esri-icon-home:before{content:"";color:inherit}.esri-icon-locate:before{content:"";color:inherit}.esri-icon-expand:before{content:"";color:inherit}.esri-icon-collapse:before{content:"";color:inherit}.esri-icon-layer-list:before{content:"";color:inherit}.esri-icon-basemap:before{content:"";color:inherit}.esri-icon-globe:before{content:"";color:inherit}.esri-icon-applications:before{content:"";color:inherit}.esri-icon-arrow-up-circled:before{content:"";color:inherit}.esri-icon-arrow-down-circled:before{content:"";color:inherit}.esri-icon-arrow-left-circled:before{content:"";color:inherit}.esri-icon-arrow-right-circled:before{content:"";color:inherit}.esri-icon-minus-circled:before{content:"";color:inherit}.esri-icon-plus-circled:before{content:"";color:inherit}.esri-icon-add-attachment:before{content:"";color:inherit}.esri-icon-attachment:before{content:"";color:inherit}.esri-icon-calendar:before{content:"";color:inherit}.esri-icon-close-circled:before{content:"";color:inherit}.esri-icon-browser:before{content:"";color:inherit}.esri-icon-collection:before{content:"";color:inherit}.esri-icon-comment:before{content:"";color:inherit}.esri-icon-configure-popup:before{content:"";color:inherit}.esri-icon-contact:before{content:"";color:inherit}.esri-icon-dashboard:before{content:"";color:inherit}.esri-icon-deny:before{content:"";color:inherit}.esri-icon-description:before{content:"";color:inherit}.esri-icon-directions:before{content:"";color:inherit}.esri-icon-directions2:before{content:"";color:inherit}.esri-icon-documentation:before{content:"";color:inherit}.esri-icon-duplicate:before{content:"";color:inherit}.esri-icon-review:before{content:"";color:inherit}.esri-icon-environment-settings:before{content:"";color:inherit}.esri-icon-error:before{content:"";color:inherit}.esri-icon-error2:before{content:"";color:inherit}.esri-icon-experimental:before{content:"";color:inherit}.esri-icon-feature-layer:before{content:"";color:inherit}.esri-icon-filter:before{content:"";color:inherit}.esri-icon-grant:before{content:"";color:inherit}.esri-icon-group:before{content:"";color:inherit}.esri-icon-key:before{content:"";color:inherit}.esri-icon-labels:before{content:"";color:inherit}.esri-icon-tag:before{content:"";color:inherit}.esri-icon-layers:before{content:"";color:inherit}.esri-icon-left-arrow:before{content:"";color:inherit}.esri-icon-right-arrow:before{content:"";color:inherit}.esri-icon-link-external:before{content:"";color:inherit}.esri-icon-link:before{content:"";color:inherit}.esri-icon-loading-indicator:before{content:"";color:inherit}.esri-icon-maps:before{content:"";color:inherit}.esri-icon-marketplace:before{content:"";color:inherit}.esri-icon-media:before{content:"";color:inherit}.esri-icon-media2:before{content:"";color:inherit}.esri-icon-menu:before{content:"";color:inherit}.esri-icon-mobile:before{content:"";color:inherit}.esri-icon-phone:before{content:"";color:inherit}.esri-icon-navigation:before{content:"";color:inherit}.esri-icon-pan:before{content:"";color:inherit}.esri-icon-printer:before{content:"";color:inherit}.esri-icon-pie-chart:before{content:"";color:inherit}.esri-icon-chart:before{content:"";color:inherit}.esri-icon-line-chart:before{content:"";color:inherit}.esri-icon-question:before{content:"";color:inherit}.esri-icon-resend-invitation:before{content:"";color:inherit}.esri-icon-rotate:before{content:"";color:inherit}.esri-icon-save:before{content:"";color:inherit}.esri-icon-settings:before{content:"";color:inherit}.esri-icon-settings2:before{content:"";color:inherit}.esri-icon-share:before{content:"";color:inherit}.esri-icon-sign-out:before{content:"";color:inherit}.esri-icon-support:before{content:"";color:inherit}.esri-icon-user:before{content:"";color:inherit}.esri-icon-time-clock:before{content:"";color:inherit}.esri-icon-trash:before{content:"";color:inherit}.esri-icon-upload:before{content:"";color:inherit}.esri-icon-download:before{content:"";color:inherit}.esri-icon-zoom-in-magnifying-glass:before{content:"";color:#6e6e6e}.esri-icon-search:before{content:"";color:inherit}.esri-icon-zoom-out-magnifying-glass:before{content:"";color:#6e6e6e}.esri-icon-locked:before{content:"";color:inherit}.esri-icon-unlocked:before{content:"";color:inherit}.esri-icon-favorites:before{content:"";color:inherit}.esri-icon-compass:before{content:"";color:inherit}.esri-icon-down:before{content:"";color:inherit}.esri-icon-up:before{content:"";color:inherit}.esri-icon-chat:before{content:"";color:inherit}.esri-icon-dock-bottom:before{content:"";color:inherit}.esri-icon-dock-left:before{content:"";color:inherit}.esri-icon-dock-right:before{content:"";color:inherit}.esri-icon-organization:before{content:"";color:inherit}.esri-icon-north-navigation:before{content:"";color:inherit}.esri-icon-locate-circled:before{content:"";color:inherit}.esri-icon-dial:before{content:"";color:inherit}.esri-icon-polygon:before{content:"";color:inherit}.esri-icon-polyline:before{content:"";color:inherit}.esri-icon-visible:before{content:"";color:inherit}.esri-icon-non-visible:before{content:"";color:inherit}.esri-icon-link-vertical:before{content:"";color:inherit}.esri-icon-unlocked-link-vertical:before{content:"";color:inherit}.esri-icon-link-horizontal:before{content:"";color:inherit}.esri-icon-unlocked-link-horizontal:before{content:"";color:inherit}.esri-icon-swap:before{content:"";color:inherit}.esri-icon-cta-link-external:before{content:"";color:inherit}.esri-icon-reply:before{content:"";color:inherit}.esri-icon-public:before{content:"";color:inherit}.esri-icon-share2:before{content:"";color:inherit}.esri-icon-launch-link-external:before{content:"";color:inherit}.esri-icon-rotate-back:before{content:"";color:inherit}.esri-icon-pan2:before{content:"";color:inherit}.esri-icon-tracking:before{content:"";color:inherit}.esri-icon-expand2:before{content:"";color:inherit}.esri-icon-arrow-down:before{content:"";color:inherit}.esri-icon-arrow-up:before{content:"";color:inherit}.esri-icon-hollow-eye:before{content:"";color:inherit}.esri-icon-play-circled:before{content:"";color:inherit}.esri-icon-volume-off:before{content:"";color:inherit}.esri-icon-volume-on:before{content:"";color:inherit}.esri-icon-bookmark:before{content:"";color:inherit}.esri-icon-lightbulb:before{content:"";color:inherit}.esri-icon-sketch-rectangle:before{content:"";color:inherit}.esri-icon-north-navigation-filled:before{content:"";color:inherit}.esri-icon-default-action:before{content:"";color:inherit}.esri-icon-undo:before{content:"";color:inherit}.esri-icon-redo:before{content:"";color:inherit}.esri-icon-cursor:before{content:"";color:inherit}.esri-icon-cursor-filled:before{content:"";color:inherit}.esri-icon-measure:before{content:"";color:inherit}.esri-icon-measure-line:before{content:"";color:inherit}.esri-icon-measure-area:before{content:"";color:inherit}.esri-icon-legend:before{content:"";color:inherit}.esri-icon-sliders:before{content:"";color:inherit}.esri-icon-sliders-horizontal:before{content:"";color:inherit}.esri-icon-cursor-marquee:before{content:"";color:inherit}.esri-icon-lasso:before{content:"";color:inherit}.esri-icon-elevation-profile:before{content:"";color:inherit}.esri-icon-slice:before{content:"";color:inherit}.esri-icon-line-of-sight:before{content:"";color:inherit}.esri-icon-zoom-to-object:before{content:"";color:inherit}.esri-icon-urban-model:before{content:"";color:inherit}.esri-icon-measure-building-height-shadow:before{content:"";color:inherit}.esri-icon-partly-cloudy:before{content:"";color:inherit}.esri-widget__heading{color:var(--calcite-color-text-2);margin:0 0 .5rem;font-weight:var(--calcite-font-weight-semibold)}h1.esri-widget__heading{font-size:var(--calcite-font-size-xl)}h2.esri-widget__heading{font-size:var(--calcite-font-size-md)}h3.esri-widget__heading,h4.esri-widget__heading,h5.esri-widget__heading,h6.esri-widget__heading{font-size:var(--calcite-font-size)}.esri-widget{box-sizing:border-box;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size);line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget *,.esri-widget :before,.esri-widget :after{box-sizing:inherit}.esri-widget.esri-widget--disabled>*{opacity:.4;pointer-events:none}.esri-widget.esri-widget--compact{--esri-widget-padding-y: 0;--esri-widget-padding-x: 0}.esri-widget__anchor{color:var(--calcite-color-text-2)}.esri-widget__anchor:hover{color:var(--calcite-color-text-3)}.esri-widget__anchor:hover,.esri-widget__anchor:focus{text-decoration:underline}.esri-widget__anchor--disabled{opacity:.4;pointer-events:none}.esri-widget__header{background-color:var(--calcite-color-foreground-1);flex:1 0 100%;justify-content:space-between;align-items:center;width:100%;min-height:48px;padding:12px 0 12px 15px;display:flex}.esri-widget__heading{word-break:break-word}.esri-widget__header .esri-widget__heading{width:calc(100% - 48px);text-align:initial;color:var(--calcite-color-text-1);align-items:center;margin:0;padding:0;display:flex}.esri-widget__header-button{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);border:none;flex:0 0 48px;justify-content:center;align-self:stretch;align-items:center;width:48px;padding:0;display:flex}.esri-widget__footer{background-color:var(--calcite-color-foreground-1);justify-content:center;align-items:center;width:100%;min-height:48px;display:flex}.esri-widget__footer-pagination{color:var(--calcite-color-text-2);justify-content:space-between;align-items:center;display:flex}.esri-widget__footer-pagination-previous-button,.esri-widget__footer-pagination-next-button{cursor:pointer;background-color:var(--calcite-color-foreground-1);border:0;margin:0 7px;padding:12px 15px;transition:background-color .125s ease-in-out}.esri-widget__footer-pagination-previous-button:hover,.esri-widget__footer-pagination-previous-button:focus,.esri-widget__footer-pagination-next-button:hover,.esri-widget__footer-pagination-next-button:focus{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-menu{visibility:hidden;z-index:1;background-clip:padding;background-color:var(--calcite-color-foreground-1);background-clip:padding-box;width:100%;max-height:0;margin:2px 0 0;padding:0;font-size:var(--calcite-font-size);line-height:var(--calcite-spacing-xl);position:absolute;top:100%;left:0;overflow:hidden;box-shadow:0 1px 2px #0000004d}.esri-menu .esri-menu__header{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-inverse);padding:6px 12px}.esri-menu__list{margin:0;padding:0;list-style:none}.esri-menu__list-item{cursor:pointer;border-top:1px solid #adadad4d;border-left:3px solid #0000;padding:.8em 1em}.esri-menu__list-item [class^=esri-icon-],.esri-menu__list-item [class*=" esri-icon-"]{padding-right:2.8px}.esri-menu__list-item:first-child{border-top:none}.esri-menu__list-item--focus,.esri-menu__list-item:hover,.esri-menu__list-item:focus{background-color:var(--calcite-color-foreground-1)}.esri-menu__list-item:active{background-color:var(--calcite-color-foreground-current)}.esri-menu__list-item--active,.esri-menu__list-item--active:hover,.esri-menu__list-item--active:focus{background-color:var(--calcite-color-foreground-1);border-left-color:var(--calcite-color-brand)}.esri-widget__table{border-collapse:collapse;color:var(--calcite-color-text-1);border:none;width:100%;line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget__table tr:nth-child(odd){background-color:var(--calcite-color-transparent)}.esri-widget__table tr:nth-child(2n){background-color:var(--calcite-color-transparent-press)}.esri-widget__table tr a{color:var(--calcite-color-text-2)}.esri-widget__table tr a:hover,.esri-widget__table tr a:focus{color:var(--calcite-color-text-1)}.esri-widget__table tr td,.esri-widget__table tr th{vertical-align:top;word-break:break-word;padding:.5em .7em;font-size:var(--calcite-font-size-sm);font-weight:var(--calcite-font-weight-regular)}.esri-widget__table tr th{text-align:left;border-right:3px solid #0000000d;width:50%}.esri-widget__table tr td{width:50%}.esri-input{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1);border:1px solid #959595;font-size:var(--calcite-font-size)}.esri-input::-ms-clear{display:none}.esri-input::placeholder{opacity:1;color:var(--calcite-color-text-2)}.esri-input:placeholder-shown{text-overflow:ellipsis}.esri-input[type=text],.esri-input[type=password],.esri-input[type=number]{height:32px;padding:0 .5em}calcite-combobox.esri-input{border:none}.esri-widget__content--empty{text-align:center;color:var(--calcite-color-border-input);flex-flow:column wrap;align-items:center;padding:18px 22px;display:flex}.esri-widget__content--empty h1.esri-widget__heading,.esri-widget__content--empty h2.esri-widget__heading,.esri-widget__content--empty h3.esri-widget__heading,.esri-widget__content--empty h4.esri-widget__heading,.esri-widget__content--empty h5.esri-widget__heading{font-weight:var(--calcite-font-weight-regular)}.esri-widget__content-illustration--empty{width:128px;padding:1rem 0}.esri-widget__content-icon--empty{width:32px;padding:.5rem 0}.esri-select{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background:var(--calcite-color-foreground-1) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 32 32' width='32' height='32'%3E%3Cpath d='M8 11.207l-4-4V5.793l4 4 4-4v1.414z' fill='%23adadad' fillrule='nonzero'/%3E%3C/svg%3E") 100% no-repeat;border:1px solid #959595;border-radius:0;width:100%;height:32px;margin:0;padding:0 .5em;font-family:inherit;font-size:.85em;display:block}.esri-select[disabled]{cursor:auto}.esri-select::-ms-expand{display:none}.esri-disabled a,.esri-disabled [role=menu],.esri-disabled [role=checkbox],.esri-disabled [class^=esri-icon-],.esri-disabled [class*=" esri-icon-"]{color:var(--calcite-color-text-3)}.keynav-mode .esri-widget:focus,.keynav-mode .esri-widget :focus{z-index:1;outline-offset:2px;outline:2px solid #adadad}.esri-widget__loader-animation{border:.15em solid #adadad4d;border-top-color:var(--calcite-color-border-input);border-radius:100%;width:1em;height:1em;font-size:var(--calcite-font-size-md);animation:1.25s linear infinite esri-rotate;display:block;transform:translateZ(0)}:dir(rtl) .esri-widget__table th{text-align:right;border-left:3px solid #0000000d;border-right:none}:dir(rtl) .esri-select{background-position:0}:dir(rtl) .esri-menu__list-item{border-left:none;border-right:3px solid #0000}:dir(rtl) .esri-menu__list-item [class^=esri-icon-],:dir(rtl) .esri-menu__list-item [class*=" esri-icon-"]{padding-left:2px;padding-right:0}:dir(rtl) .esri-menu__list-item--active{border-right-color:var(--calcite-color-brand)}.esri-icon-font-fallback-text{clip:rect(0 0 0 0);width:1px;height:1px;position:absolute;overflow:hidden}.esri-rotating{animation:1.25s linear infinite esri-rotate;transform:translateZ(0)}.esri-clearfix:before,.esri-clearfix:after{content:" ";display:table}.esri-clearfix:after{clear:both}.esri-interactive{cursor:pointer}.esri-hidden{display:none!important}.esri-invisible{visibility:hidden!important}.esri-offscreen{position:absolute;top:-999em;left:-999em}.esri-match-height{flex-direction:column;flex:auto;display:flex;overflow:hidden}.esri-button{box-sizing:border-box;cursor:pointer;white-space:normal;word-break:normal;color:var(--calcite-color-text-1);background-color:var(--calcite-color-status-info);border:var(--calcite-spacing-px) solid var(--calcite-color-status-info);justify-content:center;align-items:center;width:100%;min-height:var(--calcite-spacing-xxxl);padding:6px 7px;font-family:inherit;font-size:var(--calcite-font-size);transition:background-color .125s ease-in-out,border .125s ease-in-out;display:flex;overflow:hidden;&:hover{color:var(--calcite-color-text-1);background-color:var(--calcite-color-status-info-hover);border:var(--calcite-spacing-px) solid var(--calcite-color-status-info-hover)}}.esri-button:hover{color:var(--calcite-color-text-1);background-color:var(--calcite-color-text-2);border:1px solid var(--calcite-color-text-2)}.esri-button.esri-button--small{min-height:var(--calcite-spacing-xl);font-size:var(--calcite-font-size-sm)}.esri-button.esri-button--half{width:50%;display:inline-block}.esri-button.esri-button--third{width:33%;display:inline-block}.esri-button--secondary{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-button--tertiary{color:var(--calcite-color-brand);background-color:var(--calcite-color-transparent);border-color:var(--calcite-color-transparent)}.esri-button--tertiary:hover{color:var(--calcite-color-brand-hover);background-color:var(--calcite-color-foreground-2);border-color:var(--calcite-color-transparent)}.esri-button--disabled{opacity:.4;pointer-events:none}.esri-button--drill-in{outline-offset:-4px;cursor:pointer;text-align:unset;background-color:var(--calcite-color-foreground-1);border:none;border-radius:2px;justify-content:space-between;align-items:center;margin:var(--calcite-spacing-md) 7px;padding:var(--calcite-spacing-md) 7px;text-decoration:none;transition:background-color .125s ease-in-out;display:flex;box-shadow:0 0 0 1px #adadad4d}.esri-button--drill-in:hover,.esri-button--drill-in:focus{background-color:var(--calcite-color-foreground-2)}.esri-button--drill-in__title{font-size:var(--calcite-font-size)}.esri-button--drill-in [class^=esri-icon-],.esri-button--drill-in [class*=" esri-icon-"]{padding:0 7px}.esri-widget--button{cursor:pointer;text-align:center;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);flex-flow:row;justify-content:center;align-items:center;width:var(--calcite-spacing-xxxl);height:var(--calcite-spacing-xxxl);margin:0;padding:0;font-size:var(--calcite-font-size);transition:background-color .125s ease-in-out;display:flex;overflow:hidden}.esri-widget--button:is(calcite-button):not(:hover){--calcite-icon-color: var(--calcite-color-text-3)}.esri-widget--button:not([appearance]),.esri-widget--button[appearance=solid]{--calcite-color-foreground-3: var(--calcite-color-foreground-1)}.esri-widget--button:is(calcite-button){--calcite-offset-invert-focus: 1}.esri-widget--button calcite-loader[inline]{margin:auto}.esri-button--secondary{color:var(--calcite-color-brand);background-color:var(--calcite-color-foreground-1);&:hover{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-status-info);border:1px solid var(--calcite-color-status-info)}}:host{background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);padding-block-start:var(--arcgis-coordinate-conversion-padding-y);width:var(--arcgis-coordinate-conversion-width, 280px)}.root{background-color:var(--calcite-color-foreground-1)}calcite-alert{--calcite-alert-offset-size: var(--calcite-spacing-sm)}calcite-notice[open]{padding:var(--calcite-spacing-sm)}calcite-block{--calcite-block-content-space: 0;margin:0;padding-inline:var(--arcgis-coordinate-conversion-padding-x)}calcite-block:last-of-type{padding-block-end:var(--arcgis-coordinate-conversion-padding-y, var(--calcite-spacing-sm))}.conversion-popover{--calcite-popover-max-size-x: var(--arcgis-coordinate-conversion-settings-block-size, 250px)}.go-to-input-holder{display:flex}.go-to-input-holder calcite-input{flex:1}.conversions-block{border:none;padding-bottom:var(--calcite-spacing-sm)}.live-mode-block{--calcite-label-margin-bottom: 0;padding-block:var(--calcite-spacing-sm);padding-inline:var(--arcgis-coordinate-conversion-padding-x, var(--calcite-spacing-sm))}.live-mode-label{width:fit-content;margin-inline-start:auto}.font-size-small{font-size:var(--calcite-font-size--2)}.format-radio-label{display:flex;flex-direction:column}.radio-label{font-weight:var(--calcite-font-weight-medium);font-size:var(--calcite-font-size--2)}.radio-description{font-weight:var(--calcite-font-weight-light);font-size:var(--calcite-font-size--3)}.unit-select-panel{--calcite-panel-space: var(--calcite-spacing-md)}.popover-footer{padding:var(--calcite-spacing-sm);border-top:1px solid var(--calcite-color-border-3)}.input-form-group{display:flex;flex-direction:column;align-items:flex-start;padding:var(--calcite-spacing-sm)}.add-conversion-trigger{margin-inline-start:var(--calcite-spacing-sm);margin-block-start:var(--calcite-spacing-sm)}.input-form-group calcite-label{width:100%}.settings{padding:var(--calcite-spacing-md);display:flex;flex-direction:column;align-items:center;background-color:var(--calcite-color-foreground-1);width:calc(var(--arcgis-coordinate-conversion-settings-block-size, 250px) - (2 * var(--calcite-spacing-md)) - 2px)}.settings calcite-label{width:100%}.settings calcite-input{flex:1}.settings-form-group-horizontal{display:flex}`,q=2500,B=new I({x:0,y:0}),l={copy:"copy",gear:"gear",goTo:"zoom-to-object",lightbulb:"lightbulb",plus:"plus",refresh:"refresh",warning:"exclamation-mark-triangle"},j=P(O),m=class extends ${constructor(){super(...arguments),this._alertTimer=-1,this._conversionPopoverMap=new Map,this._coordinateInput=u(),this.messages=C({name:"coordinate-conversion-next",blocking:!0}),this._multipleConversionsDisabled=!1,this.quantityFormatter=new A,this.viewModel=j(this),this.clearAlertTimeout=()=>{window.clearTimeout(this._alertTimer),this.alertProperties={...this.alertProperties,open:!1}},this.onElevationPopoverTriggerMount=e=>{this._elevationPopoverTrigger=e},this.onFormatPopoverTriggerMount=e=>{this._formatsPopoverTrigger=e},this.handleFormatComboboxChange=e=>{let i=e.target.selectedItems[0].value,o=this.formats.find(t=>t.name===i);if(o){let t=this.activeConversion??this.conversions.at(0)??null,r=new f({format:o});t&&this.transferConversionPopoverState(t,r),this.conversions.splice(0,1,r),this.activeConversion=r,this.setPreviewConversion()}},this.alertProperties={kind:"brand",message:null,title:null,open:!1},this.elevationPopoverOpen=!1,this.formatsPopoverOpen=!1,this.invalidInput=!1,this.view=this.viewModel.view,this.autoDestroyDisabled=!1,this.conversions=this.viewModel.conversions,this.currentLocation=this.viewModel.currentLocation,this.formats=this.viewModel.formats,this.goToOverride=this.viewModel.goToOverride,this.headingLevel=4,this.hideCaptureSection=!1,this.hideInputSection=!1,this.hideSettingsButton=!1,this.icon="coordinate-system",this.label=this.messages.componentLabel,this.locationSymbol=this.viewModel.locationSymbol,this.mode=this.viewModel.mode,this.removeLeadingZeros=this.viewModel.removeLeadingZeros,this.visualScale="s",this.showElevation=!1,this.state=this.viewModel.state,this.storageType=this.viewModel.storageType,this.arcgisConversionChange=v(),this.arcgisPropertyChange=k()("currentLocation","state","mode","verticalUnit"),this.arcgisReady=v(),this.renderConversionView=(e,i)=>{let{messages:o}=this,{format:t}=e,r=t?.label??"",s=i===0&&!e.displayCoordinate?o.noLocation:e.displayCoordinate,a=this._renderConversionActions(e,s);return z(e?.format?.name,n`<calcite-list-item class="conversion-list-item" .description=${r.toUpperCase()} .label=${this.getDisplayCoordinate(s)} .scale=${this.visualScale} title=${s??void 0??c}>${a}</calcite-list-item>`)},this.renderLiveModeSection=()=>{let{messages:e}=this,i=this.mode==="idle"?this.viewModel.mode:this.mode;return n`<calcite-block class="live-mode-block" .disabled=${this.disabled} expanded .headingLevel=${this.headingLevel} .label=${e.captureMode} .scale=${this.visualScale}><calcite-label alignment=end class="live-mode-label" layout=inline .scale=${this.visualScale}>${e.captureMode}<calcite-switch .checked=${i==="capture"} @calciteSwitchChange=${this.toggleMode}></calcite-switch></calcite-label></calcite-block>`}}static{this.properties={activeConversion:16,alertProperties:16,defaultMeasurementSystem:16,disabled:16,displayedElevation:16,elevationPopoverOpen:16,formatsPopoverOpen:16,invalidInput:16,inputFormat:16,previewConversion:16,view:0,autoDestroyDisabled:5,conversions:0,currentLocation:0,formats:0,goToOverride:0,headingLevel:9,hideCaptureSection:7,hideInputSection:7,hideSettingsButton:7,icon:1,ignoreCoordinatePrecision:5,label:1,locationSymbol:0,mode:3,multipleConversionsDisabled:7,referenceElement:1,removeLeadingZeros:7,visualScale:1,showElevation:7,state:32,storageDisabled:7,storageType:1,verticalUnit:1}}static{this.styles=V}get defaultMeasurementSystem(){return this.view?.ready?U(this.view):"metric"}get disabled(){return this.viewModel.state==="disabled"}get displayedElevation(){let{currentLocation:e,verticalUnit:i,messages:o}=this;if(e?.z===void 0||e.z===null)return o.noElevation;{let t=D(e.z,"meters",i);return this.quantityFormatter.formatLength({value:t,unit:i,type:"length"},2,"plural")}}get ignoreCoordinatePrecision(){return!this.viewModel.calculateCoordinatePrecision}set ignoreCoordinatePrecision(e){this.viewModel.calculateCoordinatePrecision=!e}get multipleConversionsDisabled(){return this._multipleConversionsDisabled}set multipleConversionsDisabled(e){e&&this.conversions.splice(1,this.conversions.length-1),this._multipleConversionsDisabled=e}get storageDisabled(){return!this.viewModel.storageEnabled}set storageDisabled(e){this.viewModel.storageEnabled=!e}get verticalUnit(){return this.viewModel.verticalUnit??(this.defaultMeasurementSystem==="imperial"?"feet":"meters")}set verticalUnit(e){this.viewModel.verticalUnit=e}async destroy(){this.clearAlertTimeout(),await this.manager.destroy()}async reverseConvert(e,i){return await this.viewModel.reverseConvert(e,i)}load(){this.manager.onLifecycle(()=>[this.conversions.on("change",()=>this.arcgisConversionChange.emit())])}willUpdate(e){if(e.has("mode")&&this.mode==="idle"){this.viewModel.setLocation(this.currentLocation);return}if(e.has("currentLocation")){let i=e.get("currentLocation");this.mode==="idle"&&!this.currentLocation?.equals(i)&&this.viewModel.setLocation(this.currentLocation)}}closeAllPopovers(){for(let e of this._conversionPopoverMap.values())e.open=!1;this.elevationPopoverOpen=!1,this.formatsPopoverOpen=!1,this.requestUpdate()}async copyToClipboard(e){e&&(e=e.replace(/‎/gu,""),await navigator.clipboard.writeText(e))}findSettingsFormat(){return this.activeConversion?.format||this.conversions.reduceRight((e,i)=>{let o=i.format;return o&&b(o)?o:e},null)||this.formats.find(e=>b(e))||null}getConversionPopoverState(e){let i=this._conversionPopoverMap.get(e);return i||(i={triggerRef:u(),open:!1},this._conversionPopoverMap.set(e,i)),i}getDisplayCoordinate(e){return e?e.includes(",")?e.replace(/, /gu,",\xA0\u200B").replace(/ /gu,"\xA0"):e:"\u200B"}getFormatDescription(e){let{messages:i}=this;return i.formatDescriptions[e.name]??i.formatDescriptions.custom}getId(e){return`arcgis-coordinate-conversion-${e}`}openConversionSettings(e,i){let o=this.getConversionPopoverState(e),t=this.activeConversion!==e||!o.open;this.closeAllPopovers(),o.open=t,this._conversionPopoverTrigger=t?i.currentTarget:void 0,this.activeConversion=t?e:void 0,t&&this.setPreviewConversion(),this.requestUpdate(),i.stopPropagation()}async processUserInput(e,i,o){let{viewModel:t}=this;try{let r=await this._reverseConvert(e,i);if(r)o&&t.goToLocation(r).catch(s=>{g(this)(s),this.showAlertMessage(null,this.messages.locationOffBasemap,"warning")});else throw new Error("failed to process user input");this.mode==="capture"?t.resume():this.mode="capture",this.invalidInput=!1,this.currentLocation=r??void 0,t.setLocation(r)}catch(r){g(this)(r),this.showAlertMessage(null,this.messages.invalidCoordinate,"warning"),this.invalidInput=!0}}async processUserKeyboardInput(e){let{key:i}=e;if(i==="Enter"){let o=this.inputFormat||this.conversions.at(0)?.format,t=this._coordinateInput.value?.value;if(!o||!t)return;await this.processUserInput(t,o,!0)}else this.invalidInput=!1}async processUserMouseInput(e){let i=this.inputFormat||this.conversions.at(0)?.format,o=this._coordinateInput.value?.value;!i||!o||await this.processUserInput(o,i,e)}async _reverseConvert(e,i){return await i.reverseConvert(e)}setDefaultPattern(e){e.stopPropagation();let i=this.findSettingsFormat();i?.defaultPattern&&(i.currentPattern=i.defaultPattern)}setInputFormat(e){let i=e.target.selectedOption.value;i!==null&&(this.inputFormat=i)}setPreviewConversion(){let e=this.findSettingsFormat(),i=this.viewModel;if(e){let o=this.conversions.find(t=>t.format===e);this.previewConversion=new f({format:e,position:{location:this.currentLocation,coordinate:o?.position?.coordinate}}),this.previewConversion.position?.coordinate||i.previewConversion(this.previewConversion,i.currentLocation??B)}}showAlertMessage(e,i,o,t=q){this.alertProperties={...this.alertProperties,title:e,message:i,kind:o,open:!0},window.clearTimeout(this._alertTimer),this._alertTimer=window.setTimeout(()=>{this.alertProperties={...this.alertProperties,open:!1}},t)}toggleConversion(e){let i=e.target,o=this.formats.find(t=>t.name===i.getAttribute("data-format"));if(o){let t=this.conversions.find(r=>r.format===o);if(t){if(this.conversions.length>1){let r=this._conversionPopoverMap.get(t);r&&(r.open=!1,this._conversionPopoverMap.delete(t)),this.activeConversion===t&&(this.activeConversion=void 0),this.conversions.remove(t)}}else{let r=new f({format:o});this.conversions.add(r)}}}toggleMode(){this.mode=this.viewModel.mode==="live"?"capture":"live"}transferConversionPopoverState(e,i){let o=this.getConversionPopoverState(e),t=this.getConversionPopoverState(i);t.open=o.open,this._conversionPopoverMap.delete(e)}updateCurrentPattern(e){e.stopPropagation();let i=e.target,o=this.findSettingsFormat();o&&(o.currentPattern=i.value)}render(){let{headingLevel:e}=this,i=this.renderConversionPopover();return n`<calcite-panel class=root .headingLevel=${e} .scale=${this.visualScale}>${this.renderConversionsView()}${this.renderAlert()}</calcite-panel>${i}`}renderAlert(){let{messages:e}=this,{open:i,message:o,title:t,kind:r}=this.alertProperties;return n`<calcite-alert class="alert" .kind=${r} .label=${e.alertLabel} @calciteAlertClose=${this.clearAlertTimeout} .open=${i} placement=top .scale=${this.visualScale} slot=alerts>${t?n`<div slot=title>${t}</div>`:null}${o?n`<div slot=message>${o}</div>`:null}</calcite-alert>`}_renderConversionActions(e,i){let{messages:o}=this,t=this.getConversionPopoverState(e),r=o.settingsTitleWithFormat.replace("{formatName}",e.format?.name?.toUpperCase()??""),s=e.displayCoordinate&&this.mode!=="live";return n`<calcite-action-group layout=horizontal .scale=${this.visualScale} slot=actions-end>${s?n`<calcite-action .icon=${l.copy} .label=${o.copyLabel} @click=${()=>this.copyToClipboard(i)} .scale=${this.visualScale} .text=${o.copyLabel} title=${o.copyLabel??c}></calcite-action>`:null}${this.hideSettingsButton?null:n`<calcite-action data-format=${e.format?.name??c} .icon=${l.gear} .label=${r} @click=${a=>this.openConversionSettings(e,a)} .scale=${this.visualScale} .text=${r} title=${r??c} ${h(t.triggerRef)}></calcite-action>`}</calcite-action-group>`}renderConversionOptions(e,i){return e.map(o=>n`<calcite-option .label=${o.label.toUpperCase()} .selected=${o===i} .value=${o}>${o.label}</calcite-option>`)}renderConversionPopover(){let{activeConversion:e,messages:i}=this;if(!e)return null;let o=this.getConversionPopoverState(e),t=i.settingsTitleWithFormat.replace("{formatName}",e.format?.name?.toUpperCase()??"");return this.renderPopover({class:"conversion-popover",content:this.renderSettingsView(),getPopoverOpenProperty:()=>o.open,heading:t,includeFooter:!0,label:t,setPopoverOpenProperty:r=>{o.open=r,r||(this._conversionPopoverTrigger=void 0,this.activeConversion=void 0),this.requestUpdate()},trigger:null,triggerElement:o.triggerRef.value??this._conversionPopoverTrigger??void 0})}renderConversionsView(){if(!this.conversions)return;let{messages:e,multipleConversionsDisabled:i}=this,o=(i?this.conversions.slice(0,1):this.conversions).map(this.renderConversionView).reverse(),t=this.showElevation?this.renderElevation():null,r=this.hideCaptureSection?null:this.renderLiveModeSection(),s=this.hideInputSection?null:this.renderCoordinateInputView(),a=this.multipleConversionsDisabled?null:this.renderFormatDropdown(),d=this.disabled?n`<calcite-notice .icon=${l.lightbulb} .open=${this.disabled} width=full><div class="font-size-small" slot=message>${e.noBasemap}</div></calcite-notice>`:null;return n`${r}${d}${s}<calcite-block class="conversions-block" .disabled=${this.disabled} expanded .heading=${e.coordinates} .headingLevel=${this.headingLevel} .scale=${this.visualScale}><calcite-list interaction-mode=static .label=${e.coordinates} .scale=${this.visualScale}>${o}</calcite-list>${a}</calcite-block>${t}`}renderCoordinateInputView(){let{messages:e}=this,i=this.inputFormat??this.conversions.at(0)?.format,o=this.getId("coordinate-input"),t=this.renderConversionOptions(this.formats,i??void 0),r=n`<calcite-action .icon=${l.goTo} .label=${e.convertAndGoTo} @click=${()=>this.processUserMouseInput(!0)} .scale=${this.visualScale} .text=${e.convertAndGoTo} title=${e.convertAndGoTo??c}></calcite-action>`;return n`<calcite-block collapsible data-testid=input-block .disabled=${this.disabled} .heading=${e.input} .headingLevel=${this.headingLevel} .scale=${this.visualScale}><div class="input-form-group"><calcite-label .scale=${this.visualScale}>${e.inputFormat}<calcite-select aria-controls=${o??c} class="input-select" .label=${e.inputFormat} @calciteSelectChange=${this.setInputFormat} .scale=${this.visualScale}>${t}</calcite-select></calcite-label><calcite-label .scale=${this.visualScale}>${e.inputCoordTitle}<div class="go-to-input-holder"><calcite-input class="coordinate-input" data-format=${i??c} data-testid=coordinate-input id=${o??c} @keydown=${this.processUserKeyboardInput} .placeholder=${e.inputCoordTitle} required .scale=${this.visualScale} .status=${this.invalidInput?"invalid":"idle"} ${h(this._coordinateInput)}></calcite-input>${r}</div></calcite-label><calcite-button appearance=outline data-testid=convert-button kind=neutral @click=${()=>this.processUserMouseInput(!1)} type=button .scale=${this.visualScale} width=auto>${e.convert}</calcite-button></div></calcite-block>`}renderElevation(){let{messages:e}=this,i=this.displayedElevation??e.noElevation,o=this.renderElevationActions(),t=this.hideSettingsButton?null:this.renderElevationSettingsDropdown();return n`<calcite-block .disabled=${this.disabled} expanded .heading=${e.elevation} .headingLevel=${this.headingLevel} .scale=${this.visualScale}><calcite-list interaction-mode=static .label=${e.elevation} .scale=${this.visualScale}><calcite-list-item class="elevation-list-item" .label=${i} .scale=${this.visualScale} title=${i??c}>${o}</calcite-list-item></calcite-list>${t}</calcite-block>`}renderElevationActions(){let{messages:e}=this,i=this.currentLocation?.z!==void 0&&this.mode!=="live",o=this.displayedElevation??e.noElevation;return n`<calcite-action-group layout=horizontal .scale=${this.visualScale} slot=actions-end>${i?n`<calcite-action .icon=${l.copy} .label=${e.copyElevationLabel} @click=${()=>i&&this.copyToClipboard(o)} .scale=${this.visualScale} .text=${e.copyElevationLabel} title=${e.copyElevationLabel??c}></calcite-action>`:null}${this.hideSettingsButton?null:n`<calcite-action .icon=${l.gear} .label=${e.selectElevationUnit} .scale=${this.visualScale} .text=${e.selectElevationUnit} title=${e.selectElevationUnit??c} ${h(this.onElevationPopoverTriggerMount)}></calcite-action>`}</calcite-action-group>`}renderElevationSettingsDropdown(){let{messages:e}=this,i=n`<arcgis-unit-radio-button-group @arcgisUnitSelectChange=${o=>this.verticalUnit=o.detail} .options=${S} .name=${e.selectElevationUnit} .scale=${this.visualScale} .value=${this.verticalUnit}></arcgis-unit-radio-button-group>`;return this.renderPopover({content:i,closeOnEnter:!0,getPopoverOpenProperty:()=>this.elevationPopoverOpen,includeFooter:!1,label:e.selectElevationUnit,setPopoverOpenProperty:o=>this.elevationPopoverOpen=o,trigger:null,triggerElement:this._elevationPopoverTrigger})}renderFormatDropdown(){let{messages:e}=this,i=n`<calcite-list .label=${e.addConversion} .scale=${this.visualScale} selection-mode=multiple>${M(this.formats,t=>t,t=>{let r=!!this.conversions.find(a=>a.format===t),s=this.getFormatDescription(t);return n`<calcite-list-item data-format=${t.name??c} .description=${s} .disabled=${r&&this.conversions.length===1} .label=${t.label.toUpperCase()} @calciteListItemSelect=${this.toggleConversion} .selected=${r}></calcite-list-item>`})}</calcite-list>`,o=n`<calcite-button appearance=outline class="add-conversion-trigger" .iconStart=${l.plus} kind=neutral .label=${e.selectFormats} round .scale=${this.visualScale} ${h(this.onFormatPopoverTriggerMount)}>${e.selectFormats}</calcite-button>`;return this.renderPopover({content:i,includeFooter:!0,getPopoverOpenProperty:()=>this.formatsPopoverOpen,label:e.selectFormats,setPopoverOpenProperty:t=>this.formatsPopoverOpen=t,trigger:o,triggerElement:this._formatsPopoverTrigger})}renderPopover({content:e,class:i,closeOnEnter:o,heading:t,getPopoverOpenProperty:r,includeFooter:s,label:a,setPopoverOpenProperty:d,slot:L,trigger:E,triggerDisabled:T,triggerElement:w}){let{messages:F}=this;return n`${E}${w?n`<calcite-popover auto-close class=${_(i)} .heading=${t} .headingLevel=${this.headingLevel} .label=${a} @calcitePopoverBeforeOpen=${()=>{d(!0)}} @calcitePopoverClose=${p=>{d(!1),p.stopPropagation()}} @keydown=${p=>{o&&(p.key==="Enter"||p.key===" ")&&d(!1)}} .open=${r()} .referenceElement=${w} .scale=${this.visualScale} slot=${L??c} .triggerDisabled=${T}>${e}${s?n`<div class="popover-footer"><calcite-button appearance=solid class="popover-done-button" kind=brand @click=${()=>d(!1)} .scale=${this.visualScale} width=full>${F.done}</calcite-button></div>`:null}</calcite-popover>`:null}`}renderSettingsView(){let{messages:e}=this,i=this.findSettingsFormat(),o=this.getId("pattern-input"),t=this.getId("preview-coordinate"),r=i?.currentPattern,s=this.multipleConversionsDisabled?this.renderSingleFormatDropdown():null;if(!i||!b(i))return n`<div class="settings"><calcite-label .scale=${this.visualScale}>${e.format}${s??n`<calcite-notice class="no-display-properties-notice" .icon=${l.warning} open .scale=${this.visualScale}><div class="font-size-small" slot=message>${e.noDisplayProperties}</div></calcite-notice>`}</calcite-label></div>`;let a=n`<calcite-action .icon=${l.refresh} .label=${e.defaultPattern} @click=${this.setDefaultPattern} .scale=${this.visualScale} .text=${e.defaultPattern} title=${e.defaultPattern??c}></calcite-action>`;return n`<div class="settings"><calcite-label .scale=${this.visualScale}>${e.format}${s}</calcite-label><calcite-label .for=${o} .scale=${this.visualScale}>${e.display}<div class="settings-form-group-horizontal"><calcite-input aria-controls=${t??c} class="pattern-input" id=${o??c} @calciteInputInput=${this.updateCurrentPattern} .scale=${this.visualScale} type=text .value=${r}></calcite-input>${a}</div></calcite-label><calcite-label .scale=${this.visualScale}>${e.preview}<calcite-input read-only .scale=${this.visualScale} type=text .value=${this.previewConversion?.displayCoordinate??void 0}></calcite-input></calcite-label></div>`}renderSingleFormatDropdown(){let{messages:e}=this;return n`<calcite-combobox data-testid=single-format-combobox .label=${e.selectFormat} @calciteComboboxChange=${this.handleFormatComboboxChange} .scale=${this.visualScale} selection-mode=single-persist>${this.formats?.map(i=>n`<calcite-combobox-item .description=${this.getFormatDescription(i)} .heading=${i.label.toUpperCase()} .selected=${this.conversions.at(0)?.format===i} .value=${i.name}></calcite-combobox-item>`)}</calcite-combobox>`}};y("arcgis-coordinate-conversion-next",m);return m},"applications/Components/unitUtils","applications/Components/getDefaultUnits","applications/Components/formatUtils","geometry/Point","widgets/CoordinateConversion/CoordinateConversionViewModel","widgets/CoordinateConversion/support/Conversion","applications/Components/QuantityFormatter",a,b,d,e)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as E}from"./GFQGSSBN.js";import h from"./KUHZAASH.js";import{d as y,k as w}from"./S4I3X6AX.js";import e from"./3Q6H4RYO.js";import{a as M}from"./PC4PAQXQ.js";import d from"./DOCOL5GC.js";import{a as D}from"./SL2D573Y.js";import{a as u}from"./54VXNFQ4.js";import c from"./CKTJHIDM.js";import b from"./LLPQYUPW.js";import{h as B}from"./DFXZ77W6.js";import"./LEIE3RAW.js";import a from"./KGXW3NCW.js";import{a as f}from"./PYF4Y6SP.js";import{N as S,O as k,P as v,R as g,U,a as x,b as l,x as C}from"./6MQTAMXU.js";import"./3TTFCHAA.js";export default $arcgis.t(([{createChart:F},{signal:A},{ignoreAbortErrors:P},{watch:m},I,{property:a,subclass:T},,,,$,{b:O,e:_},z])=>{var L=x`.esri-widget__heading{color:var(--calcite-color-text-2);margin:0 0 .5rem;font-weight:var(--calcite-font-weight-semibold)}h1.esri-widget__heading{font-size:var(--calcite-font-size-xl)}h2.esri-widget__heading{font-size:var(--calcite-font-size-md)}h3.esri-widget__heading,h4.esri-widget__heading,h5.esri-widget__heading,h6.esri-widget__heading{font-size:var(--calcite-font-size)}.esri-widget{box-sizing:border-box;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size);line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget *,.esri-widget :before,.esri-widget :after{box-sizing:inherit}.esri-widget.esri-widget--disabled>*{opacity:.4;pointer-events:none}.esri-widget.esri-widget--compact{--esri-widget-padding-y: 0;--esri-widget-padding-x: 0}.esri-widget__anchor{color:var(--calcite-color-text-2)}.esri-widget__anchor:hover{color:var(--calcite-color-text-3)}.esri-widget__anchor:hover,.esri-widget__anchor:focus{text-decoration:underline}.esri-widget__anchor--disabled{opacity:.4;pointer-events:none}.esri-widget__header{background-color:var(--calcite-color-foreground-1);flex:1 0 100%;justify-content:space-between;align-items:center;width:100%;min-height:48px;padding:12px 0 12px 15px;display:flex}.esri-widget__heading{word-break:break-word}.esri-widget__header .esri-widget__heading{width:calc(100% - 48px);text-align:initial;color:var(--calcite-color-text-1);align-items:center;margin:0;padding:0;display:flex}.esri-widget__header-button{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);border:none;flex:0 0 48px;justify-content:center;align-self:stretch;align-items:center;width:48px;padding:0;display:flex}.esri-widget__footer{background-color:var(--calcite-color-foreground-1);justify-content:center;align-items:center;width:100%;min-height:48px;display:flex}.esri-widget__footer-pagination{color:var(--calcite-color-text-2);justify-content:space-between;align-items:center;display:flex}.esri-widget__footer-pagination-previous-button,.esri-widget__footer-pagination-next-button{cursor:pointer;background-color:var(--calcite-color-foreground-1);border:0;margin:0 7px;padding:12px 15px;transition:background-color .125s ease-in-out}.esri-widget__footer-pagination-previous-button:hover,.esri-widget__footer-pagination-previous-button:focus,.esri-widget__footer-pagination-next-button:hover,.esri-widget__footer-pagination-next-button:focus{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-menu{visibility:hidden;z-index:1;background-clip:padding;background-color:var(--calcite-color-foreground-1);background-clip:padding-box;width:100%;max-height:0;margin:2px 0 0;padding:0;font-size:var(--calcite-font-size);line-height:var(--calcite-spacing-xl);position:absolute;top:100%;left:0;overflow:hidden;box-shadow:0 1px 2px #0000004d}.esri-menu .esri-menu__header{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-inverse);padding:6px 12px}.esri-menu__list{margin:0;padding:0;list-style:none}.esri-menu__list-item{cursor:pointer;border-top:1px solid #adadad4d;border-left:3px solid #0000;padding:.8em 1em}.esri-menu__list-item [class^=esri-icon-],.esri-menu__list-item [class*=" esri-icon-"]{padding-right:2.8px}.esri-menu__list-item:first-child{border-top:none}.esri-menu__list-item--focus,.esri-menu__list-item:hover,.esri-menu__list-item:focus{background-color:var(--calcite-color-foreground-1)}.esri-menu__list-item:active{background-color:var(--calcite-color-foreground-current)}.esri-menu__list-item--active,.esri-menu__list-item--active:hover,.esri-menu__list-item--active:focus{background-color:var(--calcite-color-foreground-1);border-left-color:var(--calcite-color-brand)}.esri-widget__table{border-collapse:collapse;color:var(--calcite-color-text-1);border:none;width:100%;line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget__table tr:nth-child(odd){background-color:var(--calcite-color-transparent)}.esri-widget__table tr:nth-child(2n){background-color:var(--calcite-color-transparent-press)}.esri-widget__table tr a{color:var(--calcite-color-text-2)}.esri-widget__table tr a:hover,.esri-widget__table tr a:focus{color:var(--calcite-color-text-1)}.esri-widget__table tr td,.esri-widget__table tr th{vertical-align:top;word-break:break-word;padding:.5em .7em;font-size:var(--calcite-font-size-sm);font-weight:var(--calcite-font-weight-regular)}.esri-widget__table tr th{text-align:left;border-right:3px solid #0000000d;width:50%}.esri-widget__table tr td{width:50%}.esri-input{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1);border:1px solid #959595;font-size:var(--calcite-font-size)}.esri-input::-ms-clear{display:none}.esri-input::placeholder{opacity:1;color:var(--calcite-color-text-2)}.esri-input:placeholder-shown{text-overflow:ellipsis}.esri-input[type=text],.esri-input[type=password],.esri-input[type=number]{height:32px;padding:0 .5em}calcite-combobox.esri-input{border:none}.esri-widget__content--empty{text-align:center;color:var(--calcite-color-border-input);flex-flow:column wrap;align-items:center;padding:18px 22px;display:flex}.esri-widget__content--empty h1.esri-widget__heading,.esri-widget__content--empty h2.esri-widget__heading,.esri-widget__content--empty h3.esri-widget__heading,.esri-widget__content--empty h4.esri-widget__heading,.esri-widget__content--empty h5.esri-widget__heading{font-weight:var(--calcite-font-weight-regular)}.esri-widget__content-illustration--empty{width:128px;padding:1rem 0}.esri-widget__content-icon--empty{width:32px;padding:.5rem 0}.esri-select{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background:var(--calcite-color-foreground-1) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 32 32' width='32' height='32'%3E%3Cpath d='M8 11.207l-4-4V5.793l4 4 4-4v1.414z' fill='%23adadad' fillrule='nonzero'/%3E%3C/svg%3E") 100% no-repeat;border:1px solid #959595;border-radius:0;width:100%;height:32px;margin:0;padding:0 .5em;font-family:inherit;font-size:.85em;display:block}.esri-select[disabled]{cursor:auto}.esri-select::-ms-expand{display:none}.esri-disabled a,.esri-disabled [role=menu],.esri-disabled [role=checkbox],.esri-disabled [class^=esri-icon-],.esri-disabled [class*=" esri-icon-"]{color:var(--calcite-color-text-3)}.keynav-mode .esri-widget:focus,.keynav-mode .esri-widget :focus{z-index:1;outline-offset:2px;outline:2px solid #adadad}.esri-widget__loader-animation{border:.15em solid #adadad4d;border-top-color:var(--calcite-color-border-input);border-radius:100%;width:1em;height:1em;font-size:var(--calcite-font-size-md);animation:1.25s linear infinite esri-rotate;display:block;transform:translateZ(0)}:dir(rtl) .esri-widget__table th{text-align:right;border-left:3px solid #0000000d;border-right:none}:dir(rtl) .esri-select{background-position:0}:dir(rtl) .esri-menu__list-item{border-left:none;border-right:3px solid #0000}:dir(rtl) .esri-menu__list-item [class^=esri-icon-],:dir(rtl) .esri-menu__list-item [class*=" esri-icon-"]{padding-left:2px;padding-right:0}:dir(rtl) .esri-menu__list-item--active{border-right-color:var(--calcite-color-brand)}.esri-icon-font-fallback-text{clip:rect(0 0 0 0);width:1px;height:1px;position:absolute;overflow:hidden}.esri-rotating{animation:1.25s linear infinite esri-rotate;transform:translateZ(0)}.esri-clearfix:before,.esri-clearfix:after{content:" ";display:table}.esri-clearfix:after{clear:both}.esri-interactive{cursor:pointer}.esri-hidden{display:none!important}.esri-invisible{visibility:hidden!important}.esri-offscreen{position:absolute;top:-999em;left:-999em}.esri-match-height{flex-direction:column;flex:auto;display:flex;overflow:hidden}.esri-widget--panel{min-width:300px;min-height:32px;padding:var(--arcgis-internal-padding);transition:max-height .25s ease-in-out;overflow-y:auto}:host{--internal-chart-height: 180px;--internal-gap: var(--calcite-spacing-sm-plus);width:550px;isolation:isolate;position:relative;container-type:inline-size}.root{display:flex;flex-direction:column;width:100%;min-width:0;gap:var(--internal-gap)}.header{display:flex;flex-direction:row;align-items:center;justify-content:flex-end;margin-bottom:calc(var(--internal-gap) * -1)}.actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:var(--calcite-spacing-xs)}.action-button{width:auto;min-height:32px}.main-container{display:flex;position:relative;flex-flow:column;width:100%;height:var(--internal-chart-height)}.chart-container{position:relative;width:100%;height:100%}.prompt-container{box-sizing:border-box;display:grid;place-content:center;padding-inline:var(--calcite-spacing-md);height:100%;text-align:center}.prompt-message{margin:0;width:100%}.spinner{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transition:opacity .15s ease-in-out;transition-delay:0;opacity:0;&.visible{transition-delay:50ms;opacity:1}&.small{inset-inline-start:0;inset-block-start:-24px;left:unset;transform:none;color:var(--calcite-color-brand)}}@container (max-width: 400px){.esri-widget--panel{height:auto}.actions{flex-direction:column}.action-button{align-self:stretch}}`;async function R(t,e,i){let r=await H(t,e);return O(i),Z(r)?r.highlight(e):E()}async function H(t,e){let i=e?.layer;if(!(!i||i.type==="subtype-sublayer"||i.type==="sublayer"||i.type==="building-component"))return await t.whenLayerView(i)}function Z(t){return t!=null&&"highlight"in t&&typeof t.highlight=="function"}function j({geometry:t}){return t?.type==="polyline"&&t.paths.length>0&&t.paths.every(e=>e.length>=2)}function q({geometry:t}){return t?.type==="polyline"&&t.paths.reduce((e,i)=>e+i.length,0)>0}function G(t){return t?.samples?.some(e=>e.z!=null)??!1}function J(t){return t?.type==="polyline"}var K=Object.defineProperty,N=Object.getOwnPropertyDescriptor,o=(t,e,i,r)=>{for(var n=r>1?void 0:r?N(e,i):e,c=t.length-1,d;c>=0;c--)(d=t[c])&&(n=(r?d(e,i,n):d(n))||n);return r&&n&&K(e,i,n),n},s=class extends z{constructor(){super(...arguments),this.highlightDisabled=!1,this.uniformChartScaling=!1,this.shouldForceInteractive=!1,this.supportedViewType="both",this.unsupportedErrorMessage=""}get _hasSamples(){let{progress:t}=this;return!!this.analysisView?.results?.some(e=>e.available&&(t<1||G(e)))}get doneButtonAvailable(){if(this.featureIsSelected)return!1;let{geometry:t}=this.analysis;return J(t)&&t.paths.length>0&&t.paths[0].length>2}get effectiveDisplayUnits(){return this.analysisView?.effectiveDisplayUnits}get errorState(){if(!j(this.analysis))return"no-valid-input";let t=this.analysisView?.error;if(t)switch(t.name){case"too-complex":return"too-complex";case"elevation-query-error":return"no-valid-input";default:return"unknown"}return this._hasSamples?"none":"no-available-profiles"}get feature(){return this._selectedFeature}set feature(t){t?t!==this.feature&&(this.analysis.setGeometryFromFeature(t),this._selectedFeature=t):this._selectedFeature=void 0}get featureIsSelected(){return this.feature!=null}get hasVertices(){return q(this.analysis)}get indicatorRelativePosition(){return this.analysisView?.indicatorRelativePosition??void 0}get geometry(){return this.analysis.geometry}set geometry(t){this.analysis.geometry=t}get elevationInfo(){return this.analysis.elevationInfo}set elevationInfo(t){this.analysis.elevationInfo=t}get profiles(){return this.analysis.profiles}set profiles(t){this.analysis.profiles=t}get progress(){return this.analysisView?.progress??0}get results(){return this.analysisView?.results??[]}get selectButtonAvailable(){for(let t of this.view?.map?.allLayers.toArray()??[])if(t.type==="graphics"&&!("internal"in t&&t.internal)&&t.graphics.some(e=>e.geometry?.type==="polyline")||"geometryType"in t&&t.geometryType==="polyline")return!0;return!!this.view?.graphics?.some(t=>t.geometry?.type==="polyline")}get state(){return this.disabled||!this.ready?"disabled":this._selectingPromise?"selecting":this.operationState==="active"?"creating":this.analysis.valid?this.featureIsSelected?"selected":"created":"ready"}get distanceUnit(){return w(this._userDistanceUnit,this.analysis.displayUnits?.distance,this.distanceUnitOptions,this.defaultMeasurementSystem)}set distanceUnit(t){this._userDistanceUnit=t}get distanceUnitOptions(){return V(this._userDistanceUnitOptions)}set distanceUnitOptions(t){this._userDistanceUnitOptions=t}get elevationUnit(){return w(this._userElevationUnit,this.analysis.displayUnits?.elevation,this.elevationUnitOptions,this.defaultMeasurementSystem)}set elevationUnit(t){this._userElevationUnit=t}get elevationUnitOptions(){return V(this._userElevationUnitOptions)}set elevationUnitOptions(t){this._userElevationUnitOptions=t}initialize(){this.addHandles([m(()=>({analysis:this.analysis,unitDistance:this._userDistanceUnit,unitElevation:this._userElevationUnit}),({analysis:t,unitDistance:e,unitElevation:i})=>{i&&(t.displayUnits.elevation=i),e&&(t.displayUnits.distance=e)},{sync:!0,initial:!0}),m(()=>({selectedFeature:this.feature,profiles:this.analysis.profiles.toArray()}),({selectedFeature:t,profiles:e},i)=>{this._highlightSelectedFeature(this.highlightDisabled?void 0:t),this.analysis.viewOptions.geometryVisualizationVisible=!this.highlightDisabled&&t==null;let r=i?.selectedFeature;e.forEach(n=>{switch(n.type){case"scene":this._excludeSelectedFeatureFromProfile(n,t,r);break;case"input":n.chartOptions.lineVisible=t!=null,n.viewOptions.lineVisible=t!=null;break}})},{initial:!0})])}destroy(){this._removeSelectionHighlight()}async select(){let t=this.analysisView;if(!t)return;this.clear();let e=super.start({operation:async i=>{let r=await t.pickFeature(i);i?.signal?.aborted||(t.interactive=!1,this.feature=r.feature)},clear:!1});e.finally(()=>{this._selectingPromise===e&&(this._selectingPromise=void 0)}),this._selectingPromise=e,await e.catch(()=>{})}async place(t){await this.analysisView?.place(t)}clearAnalysis(){this.geometry=null,this.elevationInfo=null,this.feature=void 0}constructAnalysis(){return new I}_highlightSelectedFeature(t){this._removeSelectionHighlight();let e=this.view;!e||!t||(this._selectionHighlightTask=_(async i=>await R(e,t,{signal:i})))}_removeSelectionHighlight(){this._selectionHighlightTask?.value?.remove(),this._selectionHighlightTask=M(this._selectionHighlightTask)}_excludeSelectedFeatureFromProfile(t,e,i){let r=new Set(t.exclude??[]);i&&r.delete(i),e&&r.add(e),t.exclude=Array.from(r)}};o([a()],s.prototype,"_userDistanceUnit",2);o([a()],s.prototype,"_userDistanceUnitOptions",2);o([a()],s.prototype,"_userElevationUnit",2);o([a()],s.prototype,"_userElevationUnitOptions",2);o([a()],s.prototype,"_selectingPromise",2);o([a()],s.prototype,"_selectedFeature",2);o([a()],s.prototype,"_selectionHighlightTask",2);o([a()],s.prototype,"_hasSamples",1);o([a()],s.prototype,"doneButtonAvailable",1);o([a({readOnly:!0})],s.prototype,"effectiveDisplayUnits",1);o([a({readOnly:!0})],s.prototype,"errorState",1);o([a()],s.prototype,"feature",1);o([a()],s.prototype,"featureIsSelected",1);o([a({readOnly:!0})],s.prototype,"hasVertices",1);o([a()],s.prototype,"highlightDisabled",2);o([a()],s.prototype,"indicatorRelativePosition",1);o([a()],s.prototype,"geometry",1);o([a()],s.prototype,"elevationInfo",1);o([a()],s.prototype,"profiles",1);o([a({readOnly:!0})],s.prototype,"progress",1);o([a({readOnly:!0})],s.prototype,"results",1);o([a({readOnly:!0})],s.prototype,"selectButtonAvailable",1);o([a({readOnly:!0})],s.prototype,"state",1);o([a()],s.prototype,"uniformChartScaling",2);o([a()],s.prototype,"distanceUnit",1);o([a()],s.prototype,"distanceUnitOptions",1);o([a()],s.prototype,"elevationUnit",1);o([a()],s.prototype,"elevationUnitOptions",1);s=o([T("components.elevation-profile.ElevationProfileViewModel")],s);function V(t){let e=t?.filter(i=>y.includes(i));return e&&e.length>0?e:y.slice()}var W=$(s),b=class extends k{constructor(){super(...arguments),this.viewModel=W(this),this._messages=D(),this._chartInitializationTask=A(void 0),this._hideZoomOutButton=!0,this._hasSettingsStartContent=!1,this._hasSettingsEndContent=!1,this.analysis=this.viewModel.analysis,this.view=this.viewModel.view,this.autoDestroyDisabled=!1,this.effectiveDisplayUnits=this.viewModel.effectiveDisplayUnits,this.feature=this.viewModel.feature,this.hideChart=!1,this.hideClearButton=!1,this.hideLegend=!1,this.hideSelectButton=!1,this.hideSettingsButton=!1,this.hideStartButton=!1,this.hideUniformChartScalingToggle=!1,this.hideDistanceDisplayUnitSelect=!1,this.hideElevationDisplayUnitSelect=!1,this.hideVisualization=this.viewModel.hideVisualization,this.highlightDisabled=this.viewModel.highlightDisabled,this.icon="altitude",this.indicatorRelativePosition=this.viewModel.indicatorRelativePosition,this.geometry=this.viewModel.geometry,this.elevationInfo=this.viewModel.elevationInfo,this.profiles=this.viewModel.profiles,this.progress=this.viewModel.progress,this.state=this.viewModel.state,this.uniformChartScaling=this.viewModel.uniformChartScaling,this.distanceUnit=this.viewModel.distanceUnit,this.distanceUnitOptions=this.viewModel.distanceUnitOptions,this.elevationUnit=this.viewModel.elevationUnit,this.elevationUnitOptions=this.viewModel.elevationUnitOptions,this.arcgisPropertyChange=B()("analysis","effectiveDisplayUnits","elevationInfo","feature","geometry","indicatorRelativePosition","progress","state"),this.arcgisReady=C()}static{this.properties={_hideZoomOutButton:16,_chartContainer:16,_hasSettingsStartContent:16,_hasSettingsEndContent:16,analysis:0,view:0,autoDestroyDisabled:5,effectiveDisplayUnits:32,feature:0,hideChart:5,hideClearButton:5,hideLegend:5,hideSelectButton:5,hideSettingsButton:5,hideStartButton:5,hideUniformChartScalingToggle:5,hideDistanceDisplayUnitSelect:5,hideElevationDisplayUnitSelect:5,hideVisualization:5,highlightDisabled:5,icon:3,indicatorRelativePosition:40,geometry:0,elevationInfo:0,label:1,messageOverrides:0,referenceElement:1,profiles:0,progress:40,state:32,uniformChartScaling:5,distanceUnit:1,distanceUnitOptions:0,elevationUnit:1,elevationUnitOptions:0}}static{this.styles=L}get _selectButtonVisible(){return!this.hideSelectButton&&this.viewModel.selectButtonAvailable}get _chart(){return this._chartInitializationTask.value?.value}async destroy(){await this.manager.destroy()}async select(){P(this.viewModel.select())}async start(){P(this.viewModel.start())}async stop(){this.viewModel.stop()}async clear(){this.viewModel.clear()}load(){this.manager.onLifecycle(()=>[m(()=>({container:this._chartContainer}),({container:e})=>{this._destroyChart(),e&&(this._chartInitializationTask.value=_(async i=>await F({view:this.viewModel.view,analysisView:this.viewModel.analysisView,container:e,messages:this._messages,signal:i,uniformScaling:this.viewModel.uniformChartScaling,onRangeChange:(r,n)=>{this._hideZoomOutButton=r===1&&n===1},onCursorPositionChange:(r,n)=>{let{analysisView:c}=this.viewModel;c&&(c.indicatorRelativePosition=r)}})))},{sync:!0,initial:!0}),m(()=>({chart:this._chart,view:this.viewModel.view,analysisView:this.viewModel.analysisView,uniformScaling:this.viewModel.uniformChartScaling}),({chart:e,view:i,analysisView:r,uniformScaling:n})=>{e&&(e.view=i,e.analysisView=r,e.uniformScaling=n)},{sync:!0,initial:!0}),{remove:()=>this._destroyChart()}])}_destroyChart(){let e=this._chart;this._chartInitializationTask.value?.abort(),this._chartInitializationTask.value=void 0,e?.destroy()}_onCancelButtonClick(){this.viewModel.stop(),this.viewModel.clear()}_onDoneButtonClick(){this.viewModel.stop()}_getErrorMessage(){let e=X[this.viewModel.errorState];return e?this._messages?.errors?.[e]:void 0}_onClearButtonClick(){this.viewModel.clear()}_onZoomOutButtonClick(){this._chart?.zoomOut()}_onChartContainerRef(e){this._chartContainer=e}render(){return l`<div aria-label=${this._messages.componentLabel??g} class=${v({root:!0,[u.widget]:!0,[u.widgetDisabled]:this.viewModel.state==="disabled",[u.panel]:!0})} role=presentation>${this._renderContentForState()}</div>`}_renderContentForState(){switch(this.viewModel.state){case"ready":return this._renderContentForReadyState();case"selecting":return this._renderContentForSelectingState();case"creating":return this._renderContentForCreatingState();case"selected":return this._renderContentForSelectedState();case"created":return this._renderContentForCreatedState();case"disabled":return this._renderContentForReadyState()}}_renderContentForReadyState(){let{_messages:e,hideSelectButton:i,hideStartButton:r}=this,{selectButtonAvailable:n}=this.viewModel,c=!i&&n,d;return!r&&c?d=e.readyPrompt:r?c?d=e.readyPromptSelectOnly:d=e.errors?.noProfile:d=e.readyPromptCreateOnly,this._renderContent({prompt:d,chart:!1,actions:p})}_renderContentForSelectingState(){let{view:e}=this.viewModel;if(!e)return;let i=this._messages[`selectingPrompt-${e.type}`];return this._renderContent({prompt:i,chart:!1,actions:[{type:"select-cancel"}]})}_renderContentForCreatingState(){let{viewModel:e}=this,{view:i}=e;if(!i)return;let r=e.hasVertices?[{type:"sketch-cancel"},{type:"sketch-done",disabled:!e.doneButtonAvailable}]:[{type:"select"},{type:"sketch",disabled:!0}];if(e.errorState==="no-valid-input"){let c=this._messages[`creatingPrompt-${i.type}`];return this._renderContent({chart:!1,actions:r,prompt:c})}let n=this._getErrorMessage();return n?this._renderContent({chart:!1,actions:r,prompt:n}):this._renderContent({chart:!0,actions:r})}_renderContentForSelectedState(){let e=this._getErrorMessage();return e?this._renderContent({chart:!1,actions:p,prompt:e}):this._renderContent({chart:!0,actions:p})}_renderContentForCreatedState(){let e=this._getErrorMessage();return e?this._renderContent({chart:!1,actions:p,prompt:e}):this._renderContent({chart:!0,actions:p})}_renderContent(e){let{viewModel:i}=this,r=i.geometry!=null;return l`<header class="header">${h({hidden:this._hideZoomOutButton,children:this._renderZoomOutButton()})}${h({hidden:this.hideClearButton||!r,children:this._renderClearButton()})}${h({hidden:this.hideSettingsButton,children:this._renderSettingsButton()})}</header><div class="main-container">${e.prompt!=null?this._renderPrompt(e.prompt):e.chart?this._renderChart():void 0}</div>${h({hidden:this.hideLegend,children:this._renderLegend()})}${this._renderActions(e)}`}_renderPrompt(e){return[l`<div class="prompt-container"><p class="prompt-message">${e}</p></div>`]}_renderZoomOutButton(){let e=this._messages.zoomOut??"";return l`<calcite-action icon=magnifying-glass-minus @click=${this._onZoomOutButtonClick} .text=${e} title=${e??g}></calcite-action>`}_renderChart(){if(this.hideChart)return;let e=this._chart;return l`${this._renderSpinner({size:e?.chartVisible?"small":"large",visible:e?.spinnerVisible??!1})}<div class="chart-container" ${S(this._onChartContainerRef)}></div>`}_renderSpinner(e){let i=e.size==="small",r=e.visible??!0;return l`<calcite-loader class=${v({spinner:!0,small:i,visible:r})} .inline=${i} label></calcite-loader>`}_renderClearButton(){let e=this._messages.clearProfile??"";return l`<calcite-action icon=trash @click=${this._onClearButtonClick} .text=${e} title=${e??g}></calcite-action>`}_renderLegend(){return l`<arcgis-elevation-profile-legend .effectiveDisplayUnits=${this.viewModel.effectiveDisplayUnits} .featureSelected=${this.viewModel.featureIsSelected} .messages=${this._messages} .profiles=${this.profiles} .results=${this.viewModel.results}></arcgis-elevation-profile-legend>`}_renderSettingsButton(){return l`<arcgis-elevation-profile-settings .hasCustomStartContent=${this._hasSettingsStartContent} .hasCustomEndContent=${this._hasSettingsEndContent} .viewModel=${this.viewModel} .hideUniformChartScalingToggle=${this.hideUniformChartScalingToggle} .hideDistanceDisplayUnitSelect=${this.hideDistanceDisplayUnitSelect} .hideElevationDisplayUnitSelect=${this.hideElevationDisplayUnitSelect} .messages=${this._messages} .uniformChartScaling=${this.viewModel.uniformChartScaling} .unitOptionsDistance=${this.viewModel.distanceUnitOptions} .unitOptionsElevation=${this.viewModel.elevationUnitOptions} @arcgisElevationProfileSettingsUniformChartScalingChange=${e=>{this.viewModel.uniformChartScaling=e.detail}}><slot name=settings-start slot=settings-start @slotchange=${e=>{this._hasSettingsStartContent=f(e)}}></slot><slot name=settings-end slot=settings-end @slotchange=${e=>{this._hasSettingsEndContent=f(e)}}></slot></arcgis-elevation-profile-settings>`}_renderActions({actions:e}){let i=this._messages,r=e.map(n=>{switch(n.type){case"sketch":return h({hidden:this.hideStartButton,children:this._renderAction({action:n,label:i.sketchButtonLabel,primary:!0,onClick:()=>{this.start()}})});case"sketch-cancel":return h({hidden:this.hideStartButton,children:this._renderAction({action:n,label:i.cancelButtonLabel,primary:!1,onClick:this._onCancelButtonClick})});case"sketch-done":return h({hidden:this.hideStartButton,children:this._renderAction({action:n,label:i.doneButtonLabel,primary:!0,onClick:this._onDoneButtonClick})});case"select":return h({hidden:!this._selectButtonVisible,children:this._renderAction({action:n,label:i.selectButtonLabel,primary:!1,onClick:()=>{this.select()}})});case"select-cancel":return h({hidden:!this._selectButtonVisible,children:this._renderAction({action:n,label:i.cancelButtonLabel,primary:!1,onClick:this._onCancelButtonClick})});default:return}}).filter(Boolean);return r.length?l`<footer class="actions">${r}</footer>`:void 0}_renderAction({action:e,label:i,onClick:r,primary:n}){return l`<calcite-button .appearance=${n?"solid":"outline-fill"} class="action-button" .disabled=${e.disabled||void 0} @click=${r}>${i}</calcite-button>`}};function h(t){return t.hidden?void 0:t.children}var p=[{type:"select"},{type:"sketch"}],X={none:void 0,"no-valid-input":"noProfile","no-available-profiles":"noProfile","too-complex":"tooComplex",unknown:"unknown"};U("arcgis-elevation-profile",b);return b},"applications/Components/analysisUtils","applications/Components/reactiveUtils","core/promiseUtils","core/reactiveUtils","analysis/ElevationProfileAnalysis","core/accessorSupport/decorators",a,b,c,d,e,h)
2
+ import{a as E}from"./GFQGSSBN.js";import h from"./ZSUE4VY6.js";import{d as y,k as w}from"./S4I3X6AX.js";import e from"./EZ67DXSF.js";import{a as M}from"./PC4PAQXQ.js";import d from"./PX2BP3QJ.js";import{a as D}from"./NJE3P4JX.js";import{a as u}from"./54VXNFQ4.js";import c from"./K4LQ4LWP.js";import b from"./U5KGWKHD.js";import{h as B}from"./Z6JYZ2A2.js";import"./YYCNECYH.js";import a from"./7P4SZTMT.js";import{a as f}from"./6OM3S3VY.js";import{N as S,O as k,P as v,R as g,U,a as x,b as l,x as C}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{createChart:F},{signal:A},{ignoreAbortErrors:P},{watch:m},I,{property:a,subclass:T},,,,$,{b:O,e:_},z])=>{var L=x`.esri-widget__heading{color:var(--calcite-color-text-2);margin:0 0 .5rem;font-weight:var(--calcite-font-weight-semibold)}h1.esri-widget__heading{font-size:var(--calcite-font-size-xl)}h2.esri-widget__heading{font-size:var(--calcite-font-size-md)}h3.esri-widget__heading,h4.esri-widget__heading,h5.esri-widget__heading,h6.esri-widget__heading{font-size:var(--calcite-font-size)}.esri-widget{box-sizing:border-box;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size);line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget *,.esri-widget :before,.esri-widget :after{box-sizing:inherit}.esri-widget.esri-widget--disabled>*{opacity:.4;pointer-events:none}.esri-widget.esri-widget--compact{--esri-widget-padding-y: 0;--esri-widget-padding-x: 0}.esri-widget__anchor{color:var(--calcite-color-text-2)}.esri-widget__anchor:hover{color:var(--calcite-color-text-3)}.esri-widget__anchor:hover,.esri-widget__anchor:focus{text-decoration:underline}.esri-widget__anchor--disabled{opacity:.4;pointer-events:none}.esri-widget__header{background-color:var(--calcite-color-foreground-1);flex:1 0 100%;justify-content:space-between;align-items:center;width:100%;min-height:48px;padding:12px 0 12px 15px;display:flex}.esri-widget__heading{word-break:break-word}.esri-widget__header .esri-widget__heading{width:calc(100% - 48px);text-align:initial;color:var(--calcite-color-text-1);align-items:center;margin:0;padding:0;display:flex}.esri-widget__header-button{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);border:none;flex:0 0 48px;justify-content:center;align-self:stretch;align-items:center;width:48px;padding:0;display:flex}.esri-widget__footer{background-color:var(--calcite-color-foreground-1);justify-content:center;align-items:center;width:100%;min-height:48px;display:flex}.esri-widget__footer-pagination{color:var(--calcite-color-text-2);justify-content:space-between;align-items:center;display:flex}.esri-widget__footer-pagination-previous-button,.esri-widget__footer-pagination-next-button{cursor:pointer;background-color:var(--calcite-color-foreground-1);border:0;margin:0 7px;padding:12px 15px;transition:background-color .125s ease-in-out}.esri-widget__footer-pagination-previous-button:hover,.esri-widget__footer-pagination-previous-button:focus,.esri-widget__footer-pagination-next-button:hover,.esri-widget__footer-pagination-next-button:focus{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-menu{visibility:hidden;z-index:1;background-clip:padding;background-color:var(--calcite-color-foreground-1);background-clip:padding-box;width:100%;max-height:0;margin:2px 0 0;padding:0;font-size:var(--calcite-font-size);line-height:var(--calcite-spacing-xl);position:absolute;top:100%;left:0;overflow:hidden;box-shadow:0 1px 2px #0000004d}.esri-menu .esri-menu__header{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-inverse);padding:6px 12px}.esri-menu__list{margin:0;padding:0;list-style:none}.esri-menu__list-item{cursor:pointer;border-top:1px solid #adadad4d;border-left:3px solid #0000;padding:.8em 1em}.esri-menu__list-item [class^=esri-icon-],.esri-menu__list-item [class*=" esri-icon-"]{padding-right:2.8px}.esri-menu__list-item:first-child{border-top:none}.esri-menu__list-item--focus,.esri-menu__list-item:hover,.esri-menu__list-item:focus{background-color:var(--calcite-color-foreground-1)}.esri-menu__list-item:active{background-color:var(--calcite-color-foreground-current)}.esri-menu__list-item--active,.esri-menu__list-item--active:hover,.esri-menu__list-item--active:focus{background-color:var(--calcite-color-foreground-1);border-left-color:var(--calcite-color-brand)}.esri-widget__table{border-collapse:collapse;color:var(--calcite-color-text-1);border:none;width:100%;line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget__table tr:nth-child(odd){background-color:var(--calcite-color-transparent)}.esri-widget__table tr:nth-child(2n){background-color:var(--calcite-color-transparent-press)}.esri-widget__table tr a{color:var(--calcite-color-text-2)}.esri-widget__table tr a:hover,.esri-widget__table tr a:focus{color:var(--calcite-color-text-1)}.esri-widget__table tr td,.esri-widget__table tr th{vertical-align:top;word-break:break-word;padding:.5em .7em;font-size:var(--calcite-font-size-sm);font-weight:var(--calcite-font-weight-regular)}.esri-widget__table tr th{text-align:left;border-right:3px solid #0000000d;width:50%}.esri-widget__table tr td{width:50%}.esri-input{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1);border:1px solid #959595;font-size:var(--calcite-font-size)}.esri-input::-ms-clear{display:none}.esri-input::placeholder{opacity:1;color:var(--calcite-color-text-2)}.esri-input:placeholder-shown{text-overflow:ellipsis}.esri-input[type=text],.esri-input[type=password],.esri-input[type=number]{height:32px;padding:0 .5em}calcite-combobox.esri-input{border:none}.esri-widget__content--empty{text-align:center;color:var(--calcite-color-border-input);flex-flow:column wrap;align-items:center;padding:18px 22px;display:flex}.esri-widget__content--empty h1.esri-widget__heading,.esri-widget__content--empty h2.esri-widget__heading,.esri-widget__content--empty h3.esri-widget__heading,.esri-widget__content--empty h4.esri-widget__heading,.esri-widget__content--empty h5.esri-widget__heading{font-weight:var(--calcite-font-weight-regular)}.esri-widget__content-illustration--empty{width:128px;padding:1rem 0}.esri-widget__content-icon--empty{width:32px;padding:.5rem 0}.esri-select{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background:var(--calcite-color-foreground-1) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 32 32' width='32' height='32'%3E%3Cpath d='M8 11.207l-4-4V5.793l4 4 4-4v1.414z' fill='%23adadad' fillrule='nonzero'/%3E%3C/svg%3E") 100% no-repeat;border:1px solid #959595;border-radius:0;width:100%;height:32px;margin:0;padding:0 .5em;font-family:inherit;font-size:.85em;display:block}.esri-select[disabled]{cursor:auto}.esri-select::-ms-expand{display:none}.esri-disabled a,.esri-disabled [role=menu],.esri-disabled [role=checkbox],.esri-disabled [class^=esri-icon-],.esri-disabled [class*=" esri-icon-"]{color:var(--calcite-color-text-3)}.keynav-mode .esri-widget:focus,.keynav-mode .esri-widget :focus{z-index:1;outline-offset:2px;outline:2px solid #adadad}.esri-widget__loader-animation{border:.15em solid #adadad4d;border-top-color:var(--calcite-color-border-input);border-radius:100%;width:1em;height:1em;font-size:var(--calcite-font-size-md);animation:1.25s linear infinite esri-rotate;display:block;transform:translateZ(0)}:dir(rtl) .esri-widget__table th{text-align:right;border-left:3px solid #0000000d;border-right:none}:dir(rtl) .esri-select{background-position:0}:dir(rtl) .esri-menu__list-item{border-left:none;border-right:3px solid #0000}:dir(rtl) .esri-menu__list-item [class^=esri-icon-],:dir(rtl) .esri-menu__list-item [class*=" esri-icon-"]{padding-left:2px;padding-right:0}:dir(rtl) .esri-menu__list-item--active{border-right-color:var(--calcite-color-brand)}.esri-icon-font-fallback-text{clip:rect(0 0 0 0);width:1px;height:1px;position:absolute;overflow:hidden}.esri-rotating{animation:1.25s linear infinite esri-rotate;transform:translateZ(0)}.esri-clearfix:before,.esri-clearfix:after{content:" ";display:table}.esri-clearfix:after{clear:both}.esri-interactive{cursor:pointer}.esri-hidden{display:none!important}.esri-invisible{visibility:hidden!important}.esri-offscreen{position:absolute;top:-999em;left:-999em}.esri-match-height{flex-direction:column;flex:auto;display:flex;overflow:hidden}.esri-widget--panel{min-width:300px;min-height:32px;padding:var(--arcgis-internal-padding);transition:max-height .25s ease-in-out;overflow-y:auto}:host{--internal-chart-height: 180px;--internal-gap: var(--calcite-spacing-sm-plus);width:550px;isolation:isolate;position:relative;container-type:inline-size}.root{display:flex;flex-direction:column;width:100%;min-width:0;gap:var(--internal-gap)}.header{display:flex;flex-direction:row;align-items:center;justify-content:flex-end;margin-bottom:calc(var(--internal-gap) * -1)}.actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:var(--calcite-spacing-xs)}.action-button{width:auto;min-height:32px}.main-container{display:flex;position:relative;flex-flow:column;width:100%;height:var(--internal-chart-height)}.chart-container{position:relative;width:100%;height:100%}.prompt-container{box-sizing:border-box;display:grid;place-content:center;padding-inline:var(--calcite-spacing-md);height:100%;text-align:center}.prompt-message{margin:0;width:100%}.spinner{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transition:opacity .15s ease-in-out;transition-delay:0;opacity:0;&.visible{transition-delay:50ms;opacity:1}&.small{inset-inline-start:0;inset-block-start:-24px;left:unset;transform:none;color:var(--calcite-color-brand)}}@container (max-width: 400px){.esri-widget--panel{height:auto}.actions{flex-direction:column}.action-button{align-self:stretch}}`;async function R(t,e,i){let r=await H(t,e);return O(i),Z(r)?r.highlight(e):E()}async function H(t,e){let i=e?.layer;if(!(!i||i.type==="subtype-sublayer"||i.type==="sublayer"||i.type==="building-component"))return await t.whenLayerView(i)}function Z(t){return t!=null&&"highlight"in t&&typeof t.highlight=="function"}function j({geometry:t}){return t?.type==="polyline"&&t.paths.length>0&&t.paths.every(e=>e.length>=2)}function q({geometry:t}){return t?.type==="polyline"&&t.paths.reduce((e,i)=>e+i.length,0)>0}function G(t){return t?.samples?.some(e=>e.z!=null)??!1}function J(t){return t?.type==="polyline"}var K=Object.defineProperty,N=Object.getOwnPropertyDescriptor,o=(t,e,i,r)=>{for(var n=r>1?void 0:r?N(e,i):e,c=t.length-1,d;c>=0;c--)(d=t[c])&&(n=(r?d(e,i,n):d(n))||n);return r&&n&&K(e,i,n),n},s=class extends z{constructor(){super(...arguments),this.highlightDisabled=!1,this.uniformChartScaling=!1,this.shouldForceInteractive=!1,this.supportedViewType="both",this.unsupportedErrorMessage=""}get _hasSamples(){let{progress:t}=this;return!!this.analysisView?.results?.some(e=>e.available&&(t<1||G(e)))}get doneButtonAvailable(){if(this.featureIsSelected)return!1;let{geometry:t}=this.analysis;return J(t)&&t.paths.length>0&&t.paths[0].length>2}get effectiveDisplayUnits(){return this.analysisView?.effectiveDisplayUnits}get errorState(){if(!j(this.analysis))return"no-valid-input";let t=this.analysisView?.error;if(t)switch(t.name){case"too-complex":return"too-complex";case"elevation-query-error":return"no-valid-input";default:return"unknown"}return this._hasSamples?"none":"no-available-profiles"}get feature(){return this._selectedFeature}set feature(t){t?t!==this.feature&&(this.analysis.setGeometryFromFeature(t),this._selectedFeature=t):this._selectedFeature=void 0}get featureIsSelected(){return this.feature!=null}get hasVertices(){return q(this.analysis)}get indicatorRelativePosition(){return this.analysisView?.indicatorRelativePosition??void 0}get geometry(){return this.analysis.geometry}set geometry(t){this.analysis.geometry=t}get elevationInfo(){return this.analysis.elevationInfo}set elevationInfo(t){this.analysis.elevationInfo=t}get profiles(){return this.analysis.profiles}set profiles(t){this.analysis.profiles=t}get progress(){return this.analysisView?.progress??0}get results(){return this.analysisView?.results??[]}get selectButtonAvailable(){for(let t of this.view?.map?.allLayers.toArray()??[])if(t.type==="graphics"&&!("internal"in t&&t.internal)&&t.graphics.some(e=>e.geometry?.type==="polyline")||"geometryType"in t&&t.geometryType==="polyline")return!0;return!!this.view?.graphics?.some(t=>t.geometry?.type==="polyline")}get state(){return this.disabled||!this.ready?"disabled":this._selectingPromise?"selecting":this.operationState==="active"?"creating":this.analysis.valid?this.featureIsSelected?"selected":"created":"ready"}get distanceUnit(){return w(this._userDistanceUnit,this.analysis.displayUnits?.distance,this.distanceUnitOptions,this.defaultMeasurementSystem)}set distanceUnit(t){this._userDistanceUnit=t}get distanceUnitOptions(){return V(this._userDistanceUnitOptions)}set distanceUnitOptions(t){this._userDistanceUnitOptions=t}get elevationUnit(){return w(this._userElevationUnit,this.analysis.displayUnits?.elevation,this.elevationUnitOptions,this.defaultMeasurementSystem)}set elevationUnit(t){this._userElevationUnit=t}get elevationUnitOptions(){return V(this._userElevationUnitOptions)}set elevationUnitOptions(t){this._userElevationUnitOptions=t}initialize(){this.addHandles([m(()=>({analysis:this.analysis,unitDistance:this._userDistanceUnit,unitElevation:this._userElevationUnit}),({analysis:t,unitDistance:e,unitElevation:i})=>{i&&(t.displayUnits.elevation=i),e&&(t.displayUnits.distance=e)},{sync:!0,initial:!0}),m(()=>({selectedFeature:this.feature,profiles:this.analysis.profiles.toArray()}),({selectedFeature:t,profiles:e},i)=>{this._highlightSelectedFeature(this.highlightDisabled?void 0:t),this.analysis.viewOptions.geometryVisualizationVisible=!this.highlightDisabled&&t==null;let r=i?.selectedFeature;e.forEach(n=>{switch(n.type){case"scene":this._excludeSelectedFeatureFromProfile(n,t,r);break;case"input":n.chartOptions.lineVisible=t!=null,n.viewOptions.lineVisible=t!=null;break}})},{initial:!0})])}destroy(){this._removeSelectionHighlight()}async select(){let t=this.analysisView;if(!t)return;this.clear();let e=super.start({operation:async i=>{let r=await t.pickFeature(i);i?.signal?.aborted||(t.interactive=!1,this.feature=r.feature)},clear:!1});e.finally(()=>{this._selectingPromise===e&&(this._selectingPromise=void 0)}),this._selectingPromise=e,await e.catch(()=>{})}async place(t){await this.analysisView?.place(t)}clearAnalysis(){this.geometry=null,this.elevationInfo=null,this.feature=void 0}constructAnalysis(){return new I}_highlightSelectedFeature(t){this._removeSelectionHighlight();let e=this.view;!e||!t||(this._selectionHighlightTask=_(async i=>await R(e,t,{signal:i})))}_removeSelectionHighlight(){this._selectionHighlightTask?.value?.remove(),this._selectionHighlightTask=M(this._selectionHighlightTask)}_excludeSelectedFeatureFromProfile(t,e,i){let r=new Set(t.exclude??[]);i&&r.delete(i),e&&r.add(e),t.exclude=Array.from(r)}};o([a()],s.prototype,"_userDistanceUnit",2);o([a()],s.prototype,"_userDistanceUnitOptions",2);o([a()],s.prototype,"_userElevationUnit",2);o([a()],s.prototype,"_userElevationUnitOptions",2);o([a()],s.prototype,"_selectingPromise",2);o([a()],s.prototype,"_selectedFeature",2);o([a()],s.prototype,"_selectionHighlightTask",2);o([a()],s.prototype,"_hasSamples",1);o([a()],s.prototype,"doneButtonAvailable",1);o([a({readOnly:!0})],s.prototype,"effectiveDisplayUnits",1);o([a({readOnly:!0})],s.prototype,"errorState",1);o([a()],s.prototype,"feature",1);o([a()],s.prototype,"featureIsSelected",1);o([a({readOnly:!0})],s.prototype,"hasVertices",1);o([a()],s.prototype,"highlightDisabled",2);o([a()],s.prototype,"indicatorRelativePosition",1);o([a()],s.prototype,"geometry",1);o([a()],s.prototype,"elevationInfo",1);o([a()],s.prototype,"profiles",1);o([a({readOnly:!0})],s.prototype,"progress",1);o([a({readOnly:!0})],s.prototype,"results",1);o([a({readOnly:!0})],s.prototype,"selectButtonAvailable",1);o([a({readOnly:!0})],s.prototype,"state",1);o([a()],s.prototype,"uniformChartScaling",2);o([a()],s.prototype,"distanceUnit",1);o([a()],s.prototype,"distanceUnitOptions",1);o([a()],s.prototype,"elevationUnit",1);o([a()],s.prototype,"elevationUnitOptions",1);s=o([T("components.elevation-profile.ElevationProfileViewModel")],s);function V(t){let e=t?.filter(i=>y.includes(i));return e&&e.length>0?e:y.slice()}var W=$(s),b=class extends k{constructor(){super(...arguments),this.viewModel=W(this),this._messages=D(),this._chartInitializationTask=A(void 0),this._hideZoomOutButton=!0,this._hasSettingsStartContent=!1,this._hasSettingsEndContent=!1,this.analysis=this.viewModel.analysis,this.view=this.viewModel.view,this.autoDestroyDisabled=!1,this.effectiveDisplayUnits=this.viewModel.effectiveDisplayUnits,this.feature=this.viewModel.feature,this.hideChart=!1,this.hideClearButton=!1,this.hideLegend=!1,this.hideSelectButton=!1,this.hideSettingsButton=!1,this.hideStartButton=!1,this.hideUniformChartScalingToggle=!1,this.hideDistanceDisplayUnitSelect=!1,this.hideElevationDisplayUnitSelect=!1,this.hideVisualization=this.viewModel.hideVisualization,this.highlightDisabled=this.viewModel.highlightDisabled,this.icon="altitude",this.indicatorRelativePosition=this.viewModel.indicatorRelativePosition,this.geometry=this.viewModel.geometry,this.elevationInfo=this.viewModel.elevationInfo,this.profiles=this.viewModel.profiles,this.progress=this.viewModel.progress,this.state=this.viewModel.state,this.uniformChartScaling=this.viewModel.uniformChartScaling,this.distanceUnit=this.viewModel.distanceUnit,this.distanceUnitOptions=this.viewModel.distanceUnitOptions,this.elevationUnit=this.viewModel.elevationUnit,this.elevationUnitOptions=this.viewModel.elevationUnitOptions,this.arcgisPropertyChange=B()("analysis","effectiveDisplayUnits","elevationInfo","feature","geometry","indicatorRelativePosition","progress","state"),this.arcgisReady=C()}static{this.properties={_hideZoomOutButton:16,_chartContainer:16,_hasSettingsStartContent:16,_hasSettingsEndContent:16,analysis:0,view:0,autoDestroyDisabled:5,effectiveDisplayUnits:32,feature:0,hideChart:5,hideClearButton:5,hideLegend:5,hideSelectButton:5,hideSettingsButton:5,hideStartButton:5,hideUniformChartScalingToggle:5,hideDistanceDisplayUnitSelect:5,hideElevationDisplayUnitSelect:5,hideVisualization:5,highlightDisabled:5,icon:3,indicatorRelativePosition:40,geometry:0,elevationInfo:0,label:1,messageOverrides:0,referenceElement:1,profiles:0,progress:40,state:32,uniformChartScaling:5,distanceUnit:1,distanceUnitOptions:0,elevationUnit:1,elevationUnitOptions:0}}static{this.styles=L}get _selectButtonVisible(){return!this.hideSelectButton&&this.viewModel.selectButtonAvailable}get _chart(){return this._chartInitializationTask.value?.value}async destroy(){await this.manager.destroy()}async select(){P(this.viewModel.select())}async start(){P(this.viewModel.start())}async stop(){this.viewModel.stop()}async clear(){this.viewModel.clear()}load(){this.manager.onLifecycle(()=>[m(()=>({container:this._chartContainer}),({container:e})=>{this._destroyChart(),e&&(this._chartInitializationTask.value=_(async i=>await F({view:this.viewModel.view,analysisView:this.viewModel.analysisView,container:e,messages:this._messages,signal:i,uniformScaling:this.viewModel.uniformChartScaling,onRangeChange:(r,n)=>{this._hideZoomOutButton=r===1&&n===1},onCursorPositionChange:(r,n)=>{let{analysisView:c}=this.viewModel;c&&(c.indicatorRelativePosition=r)}})))},{sync:!0,initial:!0}),m(()=>({chart:this._chart,view:this.viewModel.view,analysisView:this.viewModel.analysisView,uniformScaling:this.viewModel.uniformChartScaling}),({chart:e,view:i,analysisView:r,uniformScaling:n})=>{e&&(e.view=i,e.analysisView=r,e.uniformScaling=n)},{sync:!0,initial:!0}),{remove:()=>this._destroyChart()}])}_destroyChart(){let e=this._chart;this._chartInitializationTask.value?.abort(),this._chartInitializationTask.value=void 0,e?.destroy()}_onCancelButtonClick(){this.viewModel.stop(),this.viewModel.clear()}_onDoneButtonClick(){this.viewModel.stop()}_getErrorMessage(){let e=X[this.viewModel.errorState];return e?this._messages?.errors?.[e]:void 0}_onClearButtonClick(){this.viewModel.clear()}_onZoomOutButtonClick(){this._chart?.zoomOut()}_onChartContainerRef(e){this._chartContainer=e}render(){return l`<div aria-label=${this._messages.componentLabel??g} class=${v({root:!0,[u.widget]:!0,[u.widgetDisabled]:this.viewModel.state==="disabled",[u.panel]:!0})} role=presentation>${this._renderContentForState()}</div>`}_renderContentForState(){switch(this.viewModel.state){case"ready":return this._renderContentForReadyState();case"selecting":return this._renderContentForSelectingState();case"creating":return this._renderContentForCreatingState();case"selected":return this._renderContentForSelectedState();case"created":return this._renderContentForCreatedState();case"disabled":return this._renderContentForReadyState()}}_renderContentForReadyState(){let{_messages:e,hideSelectButton:i,hideStartButton:r}=this,{selectButtonAvailable:n}=this.viewModel,c=!i&&n,d;return!r&&c?d=e.readyPrompt:r?c?d=e.readyPromptSelectOnly:d=e.errors?.noProfile:d=e.readyPromptCreateOnly,this._renderContent({prompt:d,chart:!1,actions:p})}_renderContentForSelectingState(){let{view:e}=this.viewModel;if(!e)return;let i=this._messages[`selectingPrompt-${e.type}`];return this._renderContent({prompt:i,chart:!1,actions:[{type:"select-cancel"}]})}_renderContentForCreatingState(){let{viewModel:e}=this,{view:i}=e;if(!i)return;let r=e.hasVertices?[{type:"sketch-cancel"},{type:"sketch-done",disabled:!e.doneButtonAvailable}]:[{type:"select"},{type:"sketch",disabled:!0}];if(e.errorState==="no-valid-input"){let c=this._messages[`creatingPrompt-${i.type}`];return this._renderContent({chart:!1,actions:r,prompt:c})}let n=this._getErrorMessage();return n?this._renderContent({chart:!1,actions:r,prompt:n}):this._renderContent({chart:!0,actions:r})}_renderContentForSelectedState(){let e=this._getErrorMessage();return e?this._renderContent({chart:!1,actions:p,prompt:e}):this._renderContent({chart:!0,actions:p})}_renderContentForCreatedState(){let e=this._getErrorMessage();return e?this._renderContent({chart:!1,actions:p,prompt:e}):this._renderContent({chart:!0,actions:p})}_renderContent(e){let{viewModel:i}=this,r=i.geometry!=null;return l`<header class="header">${h({hidden:this._hideZoomOutButton,children:this._renderZoomOutButton()})}${h({hidden:this.hideClearButton||!r,children:this._renderClearButton()})}${h({hidden:this.hideSettingsButton,children:this._renderSettingsButton()})}</header><div class="main-container">${e.prompt!=null?this._renderPrompt(e.prompt):e.chart?this._renderChart():void 0}</div>${h({hidden:this.hideLegend,children:this._renderLegend()})}${this._renderActions(e)}`}_renderPrompt(e){return[l`<div class="prompt-container"><p class="prompt-message">${e}</p></div>`]}_renderZoomOutButton(){let e=this._messages.zoomOut??"";return l`<calcite-action icon=magnifying-glass-minus @click=${this._onZoomOutButtonClick} .text=${e} title=${e??g}></calcite-action>`}_renderChart(){if(this.hideChart)return;let e=this._chart;return l`${this._renderSpinner({size:e?.chartVisible?"small":"large",visible:e?.spinnerVisible??!1})}<div class="chart-container" ${S(this._onChartContainerRef)}></div>`}_renderSpinner(e){let i=e.size==="small",r=e.visible??!0;return l`<calcite-loader class=${v({spinner:!0,small:i,visible:r})} .inline=${i} label></calcite-loader>`}_renderClearButton(){let e=this._messages.clearProfile??"";return l`<calcite-action icon=trash @click=${this._onClearButtonClick} .text=${e} title=${e??g}></calcite-action>`}_renderLegend(){return l`<arcgis-elevation-profile-legend .effectiveDisplayUnits=${this.viewModel.effectiveDisplayUnits} .featureSelected=${this.viewModel.featureIsSelected} .messages=${this._messages} .profiles=${this.profiles} .results=${this.viewModel.results}></arcgis-elevation-profile-legend>`}_renderSettingsButton(){return l`<arcgis-elevation-profile-settings .hasCustomStartContent=${this._hasSettingsStartContent} .hasCustomEndContent=${this._hasSettingsEndContent} .viewModel=${this.viewModel} .hideUniformChartScalingToggle=${this.hideUniformChartScalingToggle} .hideDistanceDisplayUnitSelect=${this.hideDistanceDisplayUnitSelect} .hideElevationDisplayUnitSelect=${this.hideElevationDisplayUnitSelect} .messages=${this._messages} .uniformChartScaling=${this.viewModel.uniformChartScaling} .unitOptionsDistance=${this.viewModel.distanceUnitOptions} .unitOptionsElevation=${this.viewModel.elevationUnitOptions} @arcgisElevationProfileSettingsUniformChartScalingChange=${e=>{this.viewModel.uniformChartScaling=e.detail}}><slot name=settings-start slot=settings-start @slotchange=${e=>{this._hasSettingsStartContent=f(e)}}></slot><slot name=settings-end slot=settings-end @slotchange=${e=>{this._hasSettingsEndContent=f(e)}}></slot></arcgis-elevation-profile-settings>`}_renderActions({actions:e}){let i=this._messages,r=e.map(n=>{switch(n.type){case"sketch":return h({hidden:this.hideStartButton,children:this._renderAction({action:n,label:i.sketchButtonLabel,primary:!0,onClick:()=>{this.start()}})});case"sketch-cancel":return h({hidden:this.hideStartButton,children:this._renderAction({action:n,label:i.cancelButtonLabel,primary:!1,onClick:this._onCancelButtonClick})});case"sketch-done":return h({hidden:this.hideStartButton,children:this._renderAction({action:n,label:i.doneButtonLabel,primary:!0,onClick:this._onDoneButtonClick})});case"select":return h({hidden:!this._selectButtonVisible,children:this._renderAction({action:n,label:i.selectButtonLabel,primary:!1,onClick:()=>{this.select()}})});case"select-cancel":return h({hidden:!this._selectButtonVisible,children:this._renderAction({action:n,label:i.cancelButtonLabel,primary:!1,onClick:this._onCancelButtonClick})});default:return}}).filter(Boolean);return r.length?l`<footer class="actions">${r}</footer>`:void 0}_renderAction({action:e,label:i,onClick:r,primary:n}){return l`<calcite-button .appearance=${n?"solid":"outline-fill"} class="action-button" .disabled=${e.disabled||void 0} @click=${r}>${i}</calcite-button>`}};function h(t){return t.hidden?void 0:t.children}var p=[{type:"select"},{type:"sketch"}],X={none:void 0,"no-valid-input":"noProfile","no-available-profiles":"noProfile","too-complex":"tooComplex",unknown:"unknown"};U("arcgis-elevation-profile",b);return b},"applications/Components/analysisUtils","applications/Components/reactiveUtils","core/promiseUtils","core/reactiveUtils","analysis/ElevationProfileAnalysis","core/accessorSupport/decorators",a,b,c,d,e,h)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import a from"./BJQE4ISL.js";import{O as r,U as c,a as o,b as i}from"./6MQTAMXU.js";import"./3TTFCHAA.js";export default $arcgis.t(([{a:n}])=>{var u=o`.export-button-container{display:flex;flex-direction:column;align-items:center;gap:.5rem}`,s=class extends r{static{this.properties={viewModel:0,messages:0,fileName:1,selectExportsTab:0}}static{this.styles=u}loaded(){this.manager.onLifecycle(()=>[])}async _handlePrintMap(){this.viewModel.export(this.fileName||this.messages.untitled),this.selectExportsTab()}render(){let{messages:t}=this,{layout:a,layoutItem:e,format:p}=this.viewModel.templateOptions,d=this.viewModel.state!=="ready"||!(a||e),m=n.test(this.viewModel.portal?.url),l=`5 ${t.credits}`,h=!!e?.id;return i`<div class="export-button-container">${m&&h?i`<calcite-chip icon=credits kind=neutral .label=${l} scale=s>${l}</calcite-chip>`:null}<calcite-button .ariaLabel=${t.exportDescription} .disabled=${d||!(a||e?.id)&&!p} @click=${this._handlePrintMap} scale=l width=full>${t.export}</calcite-button></div>`}};c("arcgis-print-export-button",s);return s},a)
2
+ import a from"./BJQE4ISL.js";import{O as r,U as c,a as o,b as i}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{a:n}])=>{var u=o`.export-button-container{display:flex;flex-direction:column;align-items:center;gap:.5rem}`,s=class extends r{static{this.properties={viewModel:0,messages:0,fileName:1,selectExportsTab:0}}static{this.styles=u}loaded(){this.manager.onLifecycle(()=>[])}async _handlePrintMap(){this.viewModel.export(this.fileName||this.messages.untitled),this.selectExportsTab()}render(){let{messages:t}=this,{layout:a,layoutItem:e,format:p}=this.viewModel.templateOptions,d=this.viewModel.state!=="ready"||!(a||e),m=n.test(this.viewModel.portal?.url),l=`5 ${t.credits}`,h=!!e?.id;return i`<div class="export-button-container">${m&&h?i`<calcite-chip icon=credits kind=neutral .label=${l} scale=s>${l}</calcite-chip>`:null}<calcite-button .ariaLabel=${t.exportDescription} .disabled=${d||!(a||e?.id)&&!p} @click=${this._handlePrintMap} scale=l width=full>${t.export}</calcite-button></div>`}};c("arcgis-print-export-button",s);return s},a)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import a from"./KYU6MBFA.js";import{O as P,P as k,Q as g,U as A,a as N,b as v}from"./6MQTAMXU.js";import"./3TTFCHAA.js";export default $arcgis.t(([{e:C,g:I,h:R}])=>{var B=N`.size-ramp-container{display:flex;align-items:center;justify-content:center}.size-ramp-vertical-container{display:flex;flex-direction:column;align-items:center;justify-content:center}.size-ramp-label{margin:0 .5em;white-space:nowrap}.size-ramp-vertical-ramp{display:flex;flex-direction:column;align-items:center}.size-ramp-ramp{display:flex;flex-direction:row-reverse;align-items:center}.size-ramp-preview{display:flex}`,O="#ddd";function X(e){if(!e)return;if(e.type.includes("3d")){if(!("symbolLayers"in e)||!e.symbolLayers?.length)return;let s=e.symbolLayers.at(-1),i=s&&"resource"in s?s.resource?.primitive:void 0;return i==="circle"||i==="cross"||i==="kite"||i==="sphere"||i==="cube"||i==="diamond"}let n="style"in e?e.style:void 0;return n==="circle"||n==="diamond"||n==="cross"}function Y(e){if(e){if(e.type.includes("3d")){if(!("symbolLayers"in e)||!e.symbolLayers?.length)return;let n=e.symbolLayers.at(-1),s=n&&"resource"in n?n.resource?.primitive:void 0;return s==="triangle"||s==="cone"||s==="tetrahedron"}return"style"in e&&e.style==="triangle"}}var j=class extends P{constructor(){super(...arguments),this.hasIndicators=!1,this.legendElement=null,this.opacity=1}static{this.properties={hasIndicators:5,legendElement:0,opacity:9,messages:0}}static{this.styles=B}render(){if(this.legendElement.theme==="spike")return v`<div style=${g({display:"flex",flex:"1",justifyContent:"center"})}><arcgis-legend-spike-ramp .legendElement=${this.legendElement} .messages=${this.messages}></arcgis-legend-spike-ramp></div>`;let{legendElement:n,hasIndicators:s,opacity:i}=this,o=n.infos,d=o.at(0),m=o.at(-1);if(!d||!m)return null;let{label:y,...z}=d,{label:f,...x}=m,r=z.preview,t=x.preview;if(!r||!t)return null;r=r.cloneNode(!0),r.style.display="flex",R(r,I(this.messages,y)),t=t.cloneNode(!0),t.style.display="flex",R(t,I(this.messages,f));let l={opacity:`${i??""}`};return v`<div class=${k(s?"size-ramp-vertical-container":"size-ramp-container")}><div class="size-ramp-label">${s?y:f}</div><div class=${k(s?"size-ramp-vertical-ramp":"size-ramp-ramp")}><div class="size-ramp-preview" style=${g(l)}>${r}</div>${this._renderSizeRampLines(n)}<div class="size-ramp-preview" style=${g(l)}>${t}</div></div><div class="size-ramp-label">${s?f:y}</div></div>`}_renderSizeRampLines(n){let s=n.infos,i=s.at(0),o=s.at(-1);if(!i||!o)return null;let d=i.symbol,m=this.hasIndicators,y=i.size&&typeof i.size=="number"?i.size:0,z=o.size&&typeof o.size=="number"?o.size:0,f=i.outlineSize||0,x=o.outlineSize||0,r=C(y+f),t=C(z+x),l=m?r:r+50,p=m?r/2+50:r,u=Y(d),h=X(d),c=document.createElement("canvas");c.width=l,c.height=p,c.style.width=`${c.width}px`,c.style.height=`${c.height}px`;let a=c.getContext("2d");if(m){a.beginPath();let $=0,b=0,w=l/2-t/2,M=p;a.moveTo($,b),a.lineTo(w,M);let L=l,T=0,E=l/2+t/2,S=p;a.moveTo(L,T),a.lineTo(E,S)}else{a.beginPath();let $=0,b=p/2-t/2,w=l;a.moveTo($,b),a.lineTo(w,0);let L=0,T=p/2+t/2,E=l,S=p;a.moveTo(L,T),a.lineTo(E,S)}return a.strokeStyle=O,a.stroke(),v`<div style=${g(m?{display:"flex",marginTop:`-${u?0:h?r/2:0}px`,marginBottom:`-${u?t:h?t/2:0}px`}:{display:"flex",marginRight:`-${u?0:h?r/2:0}px`,marginLeft:`-${u?0:h?t/2:0}px`})}>${c}</div>`}};A("arcgis-legend-card-size-ramp",j);return j},a)
2
+ import a from"./KYU6MBFA.js";import{O as P,P as k,Q as g,U as A,a as N,b as v}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{e:C,g:I,h:R}])=>{var B=N`.size-ramp-container{display:flex;align-items:center;justify-content:center}.size-ramp-vertical-container{display:flex;flex-direction:column;align-items:center;justify-content:center}.size-ramp-label{margin:0 .5em;white-space:nowrap}.size-ramp-vertical-ramp{display:flex;flex-direction:column;align-items:center}.size-ramp-ramp{display:flex;flex-direction:row-reverse;align-items:center}.size-ramp-preview{display:flex}`,O="#ddd";function X(e){if(!e)return;if(e.type.includes("3d")){if(!("symbolLayers"in e)||!e.symbolLayers?.length)return;let s=e.symbolLayers.at(-1),i=s&&"resource"in s?s.resource?.primitive:void 0;return i==="circle"||i==="cross"||i==="kite"||i==="sphere"||i==="cube"||i==="diamond"}let n="style"in e?e.style:void 0;return n==="circle"||n==="diamond"||n==="cross"}function Y(e){if(e){if(e.type.includes("3d")){if(!("symbolLayers"in e)||!e.symbolLayers?.length)return;let n=e.symbolLayers.at(-1),s=n&&"resource"in n?n.resource?.primitive:void 0;return s==="triangle"||s==="cone"||s==="tetrahedron"}return"style"in e&&e.style==="triangle"}}var j=class extends P{constructor(){super(...arguments),this.hasIndicators=!1,this.legendElement=null,this.opacity=1}static{this.properties={hasIndicators:5,legendElement:0,opacity:9,messages:0}}static{this.styles=B}render(){if(this.legendElement.theme==="spike")return v`<div style=${g({display:"flex",flex:"1",justifyContent:"center"})}><arcgis-legend-spike-ramp .legendElement=${this.legendElement} .messages=${this.messages}></arcgis-legend-spike-ramp></div>`;let{legendElement:n,hasIndicators:s,opacity:i}=this,o=n.infos,d=o.at(0),m=o.at(-1);if(!d||!m)return null;let{label:y,...z}=d,{label:f,...x}=m,r=z.preview,t=x.preview;if(!r||!t)return null;r=r.cloneNode(!0),r.style.display="flex",R(r,I(this.messages,y)),t=t.cloneNode(!0),t.style.display="flex",R(t,I(this.messages,f));let l={opacity:`${i??""}`};return v`<div class=${k(s?"size-ramp-vertical-container":"size-ramp-container")}><div class="size-ramp-label">${s?y:f}</div><div class=${k(s?"size-ramp-vertical-ramp":"size-ramp-ramp")}><div class="size-ramp-preview" style=${g(l)}>${r}</div>${this._renderSizeRampLines(n)}<div class="size-ramp-preview" style=${g(l)}>${t}</div></div><div class="size-ramp-label">${s?f:y}</div></div>`}_renderSizeRampLines(n){let s=n.infos,i=s.at(0),o=s.at(-1);if(!i||!o)return null;let d=i.symbol,m=this.hasIndicators,y=i.size&&typeof i.size=="number"?i.size:0,z=o.size&&typeof o.size=="number"?o.size:0,f=i.outlineSize||0,x=o.outlineSize||0,r=C(y+f),t=C(z+x),l=m?r:r+50,p=m?r/2+50:r,u=Y(d),h=X(d),c=document.createElement("canvas");c.width=l,c.height=p,c.style.width=`${c.width}px`,c.style.height=`${c.height}px`;let a=c.getContext("2d");if(m){a.beginPath();let $=0,b=0,w=l/2-t/2,M=p;a.moveTo($,b),a.lineTo(w,M);let L=l,T=0,E=l/2+t/2,S=p;a.moveTo(L,T),a.lineTo(E,S)}else{a.beginPath();let $=0,b=p/2-t/2,w=l;a.moveTo($,b),a.lineTo(w,0);let L=0,T=p/2+t/2,E=l,S=p;a.moveTo(L,T),a.lineTo(E,S)}return a.strokeStyle=O,a.stroke(),v`<div style=${g(m?{display:"flex",marginTop:`-${u?0:h?r/2:0}px`,marginBottom:`-${u?t:h?t/2:0}px`}:{display:"flex",marginRight:`-${u?0:h?r/2:0}px`,marginLeft:`-${u?0:h?t/2:0}px`})}>${c}</div>`}};A("arcgis-legend-card-size-ramp",j);return j},a)
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
+ import{a as Y}from"./TYBW347N.js";import{e as q,f as k,g as S,h as F,i as le,j as g}from"./NTESPOTX.js";import{a as U}from"./GFQGSSBN.js";import{a as G}from"./UOVNWT76.js";import{a as D}from"./IGSZABNU.js";import c from"./EZ67DXSF.js";import"./PC4PAQXQ.js";import"./KV3OYCZ7.js";import{a as ae}from"./NJE3P4JX.js";import"./54VXNFQ4.js";import b from"./U5KGWKHD.js";import"./Z6JYZ2A2.js";import"./YYCNECYH.js";import a from"./7P4SZTMT.js";import"./6OM3S3VY.js";import{M as j,N as R,O as ie,Q as B,R as O,U as te,a as ee,b as m,x as I}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{watch:De,when:Se,whenOnce:Te},_e,ke,$e,{createTrackingTarget:Ce,runTracked:ce,signal:Pe},,{a:oe},{f:re,g:se,h:ne}])=>{function fe(r,e){return(r%e+e)%e}var J=class{#e;#t;#r=Ce(()=>{this.#i()});constructor(e){this.#t=e;let i;ce(this.#r,()=>{i=e()}),this.#e=Pe(i)}#i(){let e=this.#e.value;ce(this.#r,()=>{this.#e.value=this.#t(e)})}mutate(e){this.#e.value=e}get value(){return this.#e.value}};function Z(r){return new J(r)}var A=Math.PI,u=Math.sin,$=Math.cos,ze=Math.asin,Oe=Math.acos,w=A/180,be=1e3*60*60*24,ve=2440588,we=2451545;function Ue(r){return r.valueOf()/be-.5+ve}function M(r){return new Date((r+.5-ve)*be)}function Me(r){return Ue(r)-we}var de=w*23.4397;function Ee(r,e){return ze(u(e)*$(de)+$(e)*u(de)*u(r))}function Le(r){return w*(357.5291+.98560028*r)}function Ae(r){return w*(1.9148*u(r)+.02*u(2*r)+3e-4*u(3*r))}function Ne(r,e){var i=w*102.9372;return r+e+i+A}var T={};T.PolarException={NORMAL:0,MIDNIGHT_SUN:1,POLAR_NIGHT:2};var V=[[-.83,"sunrise","sunset"]],xe=9e-4;function He(r,e){return Math.round(r-xe-e/(2*A))}function he(r,e,i){return xe+(r+e)/(2*A)+i}function ge(r,e,i){return we+r+.0053*u(e)-.0069*u(2*i)}function Ie(r,e,i){return Oe((u(r)-u(e)*u(i))/($(e)*$(i)))}T.getTimes=function(r,e,i){var t=w*-i,s=w*e,n=Me(r),a=He(n,t),c=he(0,t,a),o=Le(c),d=Ae(o),l=Ne(o,d),h=Ee(l,0),p=ge(c,o,l);function x(H){var z=Ie(H,s,h),ye=he(z,t,a);return ge(ye,o,l)}function y(H){var z=(u(H)-u(s)*u(h))/($(s)*$(h));return z<-1?T.PolarException.MIDNIGHT_SUN:z>1?T.PolarException.POLAR_NIGHT:T.PolarException.NORMAL}var f={solarNoon:M(p),nadir:M(p-.5),polarException:T.PolarException.NORMAL},v,_,P,N,Q;for(v=0,_=V.length;v<_;v+=1)P=V[v],N=x(P[0]*w),Q=p-(N-p),f[P[1]]=M(Q),f[P[2]]=M(N);return f.polarException=y(V[0][0]*w),f};var je={spring:{dayOfMonth:20,month:2},summer:{dayOfMonth:21,month:5},fall:{dayOfMonth:23,month:8},winter:{dayOfMonth:21,month:11}},K=["spring","summer","fall","winter"];function C(r,e,i){let t=X(e,i),{dayOfMonth:s,month:n}=je[t],a=new Date(r.getTime());return a.setMonth(n,s),a}function Re(r,e){let i=Be(r);return X(i,e)}function Be(r){let e=r.getTime(),i=C(r,"spring","northern").getTime(),t=C(r,"summer","northern").getTime(),s=C(r,"fall","northern").getTime(),n=C(r,"winter","northern").getTime();return e>=i&&e<t?"spring":e>=t&&e<s?"summer":e>=s&&e<n?"fall":"winter"}function X(r,e){return e==="northern"?r:Ge(r)}function ue(r){return r>=0?"northern":"southern"}function Ge(r){let e=K.indexOf(r);return K[(e+2)%4]}var Ye=1440,qe=864e5;function Fe(r,e,i,t){let s=T.getTimes(r,e,i),n=s.sunrise,a=s.sunset,c=k(r,t),o=k(n,t),d=k(a,t);if(c.getUTCDate()!==o.getUTCDate()||c.getUTCDate()!==d.getUTCDate()){let l=c.getTime()-o.getTime()>0?1:-1;n.setUTCDate(n.getUTCDate()+l),a.setUTCDate(a.getUTCDate()+l)}return{sunrise:n,sunset:a}}var Ze=100,Ve=1e3,b=12e5,E=72e5;function pe(r,e){return fe(r+e,24)}function Je({mode:r,lighting:e,getPlaySpeed:i,onProgress:t,beforeProgress:s}){let n=-1;function a(c=Date.now()){let o=e.date,d=Date.now()-(c??0);if(r==="day"){c=Date.now();let l=i()/Ze*d;if(l>0){let h=new Date(o.getTime()+l),p=e.displayUTCOffset??0,x=pe(h.getUTCHours(),p),y=pe(o.getUTCHours(),p);x<y&&(h=new Date(o.getTime()+l-qe));let f=e.clone();s?.(),e.date=h,t?.(f,e)}}else if(d>Ve){c=Date.now();let l=(o.getUTCMonth()+1)%12,h=new Date(o.getTime());h.setUTCMonth(l);let p=e.clone();s?.(),e.date=h,t?.(p,e)}n=requestAnimationFrame(()=>a(c))}return a(),U(()=>cancelAnimationFrame(n))}var L=b/4;function Ke(r,e,i,t){let{day:s,night:n=s,twilight:a=s}=t,c=s*L,o=n*L,d=a*L;if(r==null||e==null||Number.isNaN(r.getTime())&&Number.isNaN(e.getTime()))return c;let l=i.getTime(),h=r.getTime(),p=e.getTime(),x=h-E/2,y=h+E/2,f=p-E/3*2,v=p+E/3,_=c;return l>=x&&l<=y?l-x<=b?_=o-(l-x)/b*(o-d):y-l<=b/2?_=c-(y-l)/b*2*(c-d):_=d:l>=f&&l<=v?l-f<=b/2?_=c-(l-f)/b*2*(c-d):v-l<=b?_=o-(v-l)/b*(o-d):_=d:(l<h||l>p)&&(_=o),_}var We=ee`.esri-widget__heading{color:var(--calcite-color-text-2);margin:0 0 .5rem;font-weight:var(--calcite-font-weight-semibold)}h1.esri-widget__heading{font-size:var(--calcite-font-size-xl)}h2.esri-widget__heading{font-size:var(--calcite-font-size-md)}h3.esri-widget__heading,h4.esri-widget__heading,h5.esri-widget__heading,h6.esri-widget__heading{font-size:var(--calcite-font-size)}.esri-widget{box-sizing:border-box;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);font-size:var(--calcite-font-size);line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget *,.esri-widget :before,.esri-widget :after{box-sizing:inherit}.esri-widget.esri-widget--disabled>*{opacity:.4;pointer-events:none}.esri-widget.esri-widget--compact{--esri-widget-padding-y: 0;--esri-widget-padding-x: 0}.esri-widget__anchor{color:var(--calcite-color-text-2)}.esri-widget__anchor:hover{color:var(--calcite-color-text-3)}.esri-widget__anchor:hover,.esri-widget__anchor:focus{text-decoration:underline}.esri-widget__anchor--disabled{opacity:.4;pointer-events:none}.esri-widget__header{background-color:var(--calcite-color-foreground-1);flex:1 0 100%;justify-content:space-between;align-items:center;width:100%;min-height:48px;padding:12px 0 12px 15px;display:flex}.esri-widget__heading{word-break:break-word}.esri-widget__header .esri-widget__heading{width:calc(100% - 48px);text-align:initial;color:var(--calcite-color-text-1);align-items:center;margin:0;padding:0;display:flex}.esri-widget__header-button{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background-color:var(--calcite-color-foreground-1);border:none;flex:0 0 48px;justify-content:center;align-self:stretch;align-items:center;width:48px;padding:0;display:flex}.esri-widget__footer{background-color:var(--calcite-color-foreground-1);justify-content:center;align-items:center;width:100%;min-height:48px;display:flex}.esri-widget__footer-pagination{color:var(--calcite-color-text-2);justify-content:space-between;align-items:center;display:flex}.esri-widget__footer-pagination-previous-button,.esri-widget__footer-pagination-next-button{cursor:pointer;background-color:var(--calcite-color-foreground-1);border:0;margin:0 7px;padding:12px 15px;transition:background-color .125s ease-in-out}.esri-widget__footer-pagination-previous-button:hover,.esri-widget__footer-pagination-previous-button:focus,.esri-widget__footer-pagination-next-button:hover,.esri-widget__footer-pagination-next-button:focus{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1)}.esri-menu{visibility:hidden;z-index:1;background-clip:padding;background-color:var(--calcite-color-foreground-1);background-clip:padding-box;width:100%;max-height:0;margin:2px 0 0;padding:0;font-size:var(--calcite-font-size);line-height:var(--calcite-spacing-xl);position:absolute;top:100%;left:0;overflow:hidden;box-shadow:0 1px 2px #0000004d}.esri-menu .esri-menu__header{color:var(--calcite-color-text-inverse);background-color:var(--calcite-color-inverse);padding:6px 12px}.esri-menu__list{margin:0;padding:0;list-style:none}.esri-menu__list-item{cursor:pointer;border-top:1px solid #adadad4d;border-left:3px solid #0000;padding:.8em 1em}.esri-menu__list-item [class^=esri-icon-],.esri-menu__list-item [class*=" esri-icon-"]{padding-right:2.8px}.esri-menu__list-item:first-child{border-top:none}.esri-menu__list-item--focus,.esri-menu__list-item:hover,.esri-menu__list-item:focus{background-color:var(--calcite-color-foreground-1)}.esri-menu__list-item:active{background-color:var(--calcite-color-foreground-current)}.esri-menu__list-item--active,.esri-menu__list-item--active:hover,.esri-menu__list-item--active:focus{background-color:var(--calcite-color-foreground-1);border-left-color:var(--calcite-color-brand)}.esri-widget__table{border-collapse:collapse;color:var(--calcite-color-text-1);border:none;width:100%;line-height:var(--calcite-font-line-height-relative-tight)}.esri-widget__table tr:nth-child(odd){background-color:var(--calcite-color-transparent)}.esri-widget__table tr:nth-child(2n){background-color:var(--calcite-color-transparent-press)}.esri-widget__table tr a{color:var(--calcite-color-text-2)}.esri-widget__table tr a:hover,.esri-widget__table tr a:focus{color:var(--calcite-color-text-1)}.esri-widget__table tr td,.esri-widget__table tr th{vertical-align:top;word-break:break-word;padding:.5em .7em;font-size:var(--calcite-font-size-sm);font-weight:var(--calcite-font-weight-regular)}.esri-widget__table tr th{text-align:left;border-right:3px solid #0000000d;width:50%}.esri-widget__table tr td{width:50%}.esri-input{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-1);border:1px solid #959595;font-size:var(--calcite-font-size)}.esri-input::-ms-clear{display:none}.esri-input::placeholder{opacity:1;color:var(--calcite-color-text-2)}.esri-input:placeholder-shown{text-overflow:ellipsis}.esri-input[type=text],.esri-input[type=password],.esri-input[type=number]{height:32px;padding:0 .5em}calcite-combobox.esri-input{border:none}.esri-widget__content--empty{text-align:center;color:var(--calcite-color-border-input);flex-flow:column wrap;align-items:center;padding:18px 22px;display:flex}.esri-widget__content--empty h1.esri-widget__heading,.esri-widget__content--empty h2.esri-widget__heading,.esri-widget__content--empty h3.esri-widget__heading,.esri-widget__content--empty h4.esri-widget__heading,.esri-widget__content--empty h5.esri-widget__heading{font-weight:var(--calcite-font-weight-regular)}.esri-widget__content-illustration--empty{width:128px;padding:1rem 0}.esri-widget__content-icon--empty{width:32px;padding:.5rem 0}.esri-select{appearance:none;cursor:pointer;color:var(--calcite-color-text-2);background:var(--calcite-color-foreground-1) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 32 32' width='32' height='32'%3E%3Cpath d='M8 11.207l-4-4V5.793l4 4 4-4v1.414z' fill='%23adadad' fillrule='nonzero'/%3E%3C/svg%3E") 100% no-repeat;border:1px solid #959595;border-radius:0;width:100%;height:32px;margin:0;padding:0 .5em;font-family:inherit;font-size:.85em;display:block}.esri-select[disabled]{cursor:auto}.esri-select::-ms-expand{display:none}.esri-disabled a,.esri-disabled [role=menu],.esri-disabled [role=checkbox],.esri-disabled [class^=esri-icon-],.esri-disabled [class*=" esri-icon-"]{color:var(--calcite-color-text-3)}.keynav-mode .esri-widget:focus,.keynav-mode .esri-widget :focus{z-index:1;outline-offset:2px;outline:2px solid #adadad}.esri-widget__loader-animation{border:.15em solid #adadad4d;border-top-color:var(--calcite-color-border-input);border-radius:100%;width:1em;height:1em;font-size:var(--calcite-font-size-md);animation:1.25s linear infinite esri-rotate;display:block;transform:translateZ(0)}:dir(rtl) .esri-widget__table th{text-align:right;border-left:3px solid #0000000d;border-right:none}:dir(rtl) .esri-select{background-position:0}:dir(rtl) .esri-menu__list-item{border-left:none;border-right:3px solid #0000}:dir(rtl) .esri-menu__list-item [class^=esri-icon-],:dir(rtl) .esri-menu__list-item [class*=" esri-icon-"]{padding-left:2px;padding-right:0}:dir(rtl) .esri-menu__list-item--active{border-right-color:var(--calcite-color-brand)}.esri-icon-font-fallback-text{clip:rect(0 0 0 0);width:1px;height:1px;position:absolute;overflow:hidden}.esri-rotating{animation:1.25s linear infinite esri-rotate;transform:translateZ(0)}.esri-clearfix:before,.esri-clearfix:after{content:" ";display:table}.esri-clearfix:after{clear:both}.esri-interactive{cursor:pointer}.esri-hidden{display:none!important}.esri-invisible{visibility:hidden!important}.esri-offscreen{position:absolute;top:-999em;left:-999em}.esri-match-height{flex-direction:column;flex:auto;display:flex;overflow:hidden}@supports (-ms-ime-align: auto){.esri-slider__anchor:focus{outline:1px dotted var(--calcite-color-foreground-current)}}.esri-slider{-webkit-user-select:none;user-select:none;direction:ltr;width:100%;height:100%;display:flex}.esri-disabled{pointer-events:none}.esri-disabled .esri-slider__content,.esri-disabled .esri-slider__min,.esri-disabled .esri-slider__max{opacity:var(--calcite-opacity-light)}.esri-slider--reversed.esri-slider--horizontal{flex-direction:row-reverse}.esri-slider--reversed.esri-slider--vertical{flex-direction:column}.esri-slider--horizontal{flex-direction:row}.esri-slider--horizontal .esri-slider__content{height:auto}.esri-slider--horizontal .esri-slider__track{width:100%;height:2px}.esri-slider--horizontal .esri-slider__segment--interactive:hover{cursor:ew-resize}.esri-slider--horizontal .esri-slider__anchor{width:1px;height:100%}.esri-slider--horizontal .esri-slider__label{text-align:center;margin:0 11px;top:-30px;left:-50px}.esri-slider--horizontal .esri-slider__label-input{text-align:center}.esri-slider--horizontal .esri-slider__max,.esri-slider--horizontal .esri-slider__min{flex:none;width:50px;height:auto;margin:auto}.esri-slider--horizontal .esri-slider__ticks{width:100%;margin:9px 0 0;top:100%;left:0}.esri-slider--horizontal .esri-slider__tick{width:1px;height:5px}.esri-slider--horizontal .esri-slider__tick-label{margin-top:18px}.esri-slider--vertical{flex-direction:column-reverse}.esri-slider--vertical .esri-slider__content{flex-direction:column;width:auto}.esri-slider--vertical .esri-slider__track{flex-direction:column;flex:1 0 0;width:2px;height:100%}.esri-slider--vertical .esri-slider__segment--interactive:hover{cursor:ns-resize}.esri-slider--vertical .esri-slider__anchor{width:100%;height:1px}.esri-slider--vertical .esri-slider__label{text-align:left;top:-10px;left:20px}.esri-slider--vertical .esri-slider__max,.esri-slider--vertical .esri-slider__min{flex:0 0 22px;width:100%;margin:auto}.esri-slider--vertical .esri-slider__ticks{margin:0 0 0 11px;top:0;left:100%}.esri-slider--vertical .esri-slider__tick{width:5px;height:1px}.esri-slider--vertical .esri-slider__tick-label{margin-left:30px}.esri-slider__content{z-index:0;flex:1 0 auto;justify-content:center;align-items:center;margin:auto;line-height:0;display:flex;position:relative}.esri-slider__track{touch-action:none;background-color:var(--calcite-color-border-ghost);display:inline-block;position:relative}.esri-slider__segment{transform-origin:0 0;will-change:transform;touch-action:none;width:100%;height:100%;position:absolute;top:0;left:0}.esri-slider__segment:hover{cursor:pointer}.esri-slider__anchor{touch-action:none;-webkit-user-select:none;user-select:none;background-color:var(--calcite-color-brand);position:absolute}.esri-slider__anchor:focus .esri-slider__thumb,.esri-slider__anchor:focus .esri-slider__label{outline:inherit}.esri-slider__anchor--moving:focus .esri-slider__thumb{cursor:grabbing;border:3px solid var(--calcite-color-brand-press)}.esri-slider__anchor--moving .esri-slider__label:hover,.esri-slider__anchor--moving .esri-slider__label--interactive:hover{cursor:grabbing}.esri-slider__thumb{box-sizing:border-box;z-index:1;touch-action:none;background-color:var(--calcite-color-foreground-2);border:2px solid var(--calcite-color-brand);border-radius:16px;width:16px;height:16px;transition:all .125s ease-in-out;position:absolute;top:-7px;left:-7px}.esri-slider__thumb:hover{cursor:grab;border-width:3px;border-color:var(--calcite-color-brand-press);width:19.2px;height:19.2px;top:-8.6px;left:-8.6px}.esri-slider__label{min-width:80px;line-height:var(--calcite-font-line-height-fixed-xl);position:absolute}.esri-slider__label:hover{cursor:grab}.esri-slider__label--interactive:hover,.esri-slider__max--interactive:hover,.esri-slider__min--interactive:hover{cursor:pointer;text-decoration:underline}.esri-slider__label-input{z-index:1;width:100%;position:relative}.esri-slider__extra-content{display:inline-block}.esri-slider__max,.esri-slider__min{text-align:center;justify-content:center;align-items:center;height:22px;line-height:var(--calcite-font-line-height-fixed-xl);display:flex}.esri-slider__max--interactive:hover,.esri-slider__min--interactive:hover{background-color:var(--calcite-color-foreground-2)}.esri-slider__range-input{text-align:center;width:100%;padding:1px 0}.esri-slider__ticks{z-index:0;height:100%;display:inline-block;position:absolute}.esri-slider__tick{background:var(--calcite-color-foreground-1);position:absolute}.esri-slider__tick-label{width:max-content;position:absolute}:dir(rtl) .esri-slider__label,:dir(rtl) .esri-slider__max,:dir(rtl) .esri-slider__min,:dir(rtl) .esri-slider__tick-label{direction:rtl;unicode-bidi:plaintext}:dir(rtl) .esri-slider__range-input,:dir(rtl) .esri-slider__label-input{unicode-bidi:plaintext}:host{width:350px}.root{display:flex;flex-direction:column;overflow:visible;gap:var(--calcite-spacing-md);justify-content:space-between;padding:var(--arcgis-internal-padding);position:relative;calcite-label{--calcite-label-margin-bottom: 0}&.loading>*:not(calcite-scrim){opacity:0}}.unsupported{padding:0 var(--calcite-spacing-lg);animation:esri-fade-in .25s ease-in-out}.slider{margin-block-start:0rem}.time-configuration{--date-play-button-offset: 11px;--slider-play-button-offset: var(--calcite-spacing-md);display:grid;gap:var(--calcite-spacing-md);grid-template-columns:1fr min-content;.slider-container{grid-column:1;+calcite-button{grid-column:2;transform:translateY(var(--slider-play-button-offset))}}.timezone-input-container{grid-column:1;min-width:0;+span{grid-column:2}}.date-picker-container{grid-column:1;+calcite-button{grid-column:2;transform:translateY(var(--date-play-button-offset))}}calcite-button{place-self:center}}`,Xe={day:1,night:6,twilight:2/3},W=class extends ie{constructor(){super(...arguments),this.messages=ae({blocking:!0}),this.#t="none",this.#r=null,this.#l=j(),this.#g=j(),this.#u=200,this.#p=200,this.#c=!1,this.#a={},this._offset=Z(e=>{let i=this._lighting,t=g(i)?i.displayUTCOffset:void 0;return this.#i?e:t??e}),this._timesliderPosition=Z(e=>{let i=this._lighting;if(!g(i))return e;let t=i.displayUTCOffset??this.utcOffset??0,s=i.date;if(this.#i)return e;if(q(s)){let{minutesSinceMidnight:n}=S(s,t);return n}return e}),this._localDate=Z(e=>{let i=le(this._view,this.utcOffset);return this.#i?e:i??e}),this.view=oe(this),this.autoDestroyDisabled=!1,this.dateOrSeason="date",this.headingLevel=2,this.hideDatePicker=!1,this.hideHeader=!1,this.hidePlayButtons=!1,this.hideShadowsToggle=!1,this.hideSunLightingToggle=!1,this.hideTimezone=!1,this.icon="brightness",this.playSpeedMultiplier=1,this.timeSliderSteps=5,this.arcgisReady=I(),this.arcgisUserDateTimeChange=I(),this.#o=!1}static{this.properties={localDateAsString:32,view:0,_playingState:16,_sunlightingDisabled:16,autoDestroyDisabled:5,currentSeason:1,dateOrSeason:3,dayPlaying:5,_directShadowsDisabled:16,headingLevel:9,hideDatePicker:5,hideHeader:5,hidePlayButtons:5,hideShadowsToggle:5,hideSunLightingToggle:5,hideTimezone:5,icon:3,label:1,playSpeedMultiplier:9,referenceElement:1,timeSliderSteps:9,utcOffset:9,timeSliderPosition:9,localDate:1,yearPlaying:5}}static{this.styles=We}get _view(){return this.view?.type==="3d"?this.view:void 0}#e;#t;#r;#i;#l;#g;#u;#p;#c;#s(e,i){return this.#o||this.#c?!1:(this.#a[e]=i,!0)}#m(){let{utcOffset:e,timeSliderPosition:i,localDate:t,directShadowsDisabled:s,sunlightingDisabled:n}=this.#a;if(this.#c=!0,e!=null)if(i==null&&t==null){let a=this._lighting;g(a)?(a.displayUTCOffset=e,this.#h(e,a)):this._offset.mutate(e)}else this.utcOffset=e;i!=null&&(this.timeSliderPosition=i),t&&(this.localDate=t),s!=null&&(this._directShadowsDisabled=s),n!=null&&(this._sunlightingDisabled=n),this.#a={},this.#c=!1}#d(){if(this.requestUpdate(),this.#i)return;let e=se(()=>{if(g(this._lighting)){let i=this.utcOffset??0,t=this.timeSliderPosition??0,s=this.localDate;this._lighting.date=F(s,t,i),this._lighting.displayUTCOffset=i}this.#i?.remove()},{timeout:this.#u});this.#i=U(()=>{ne(e),this.#i=void 0})}#_(e){let i=this.utcOffset??e.displayUTCOffset??0,{minutesSinceMidnight:t,localDate:s}=S(e.date,i),n=this.timeSliderPosition??t,a=this.localDateAsString??s;this.#i?.remove(),e.date=F(a,n,i),e.displayUTCOffset=i}#f({scale:e,disabled:i}){let{messages:t}=this;return m`<calcite-label .scale=${e} class="date-picker-container">${t.date}${Qe({disabled:i,scale:e,date:this.localDateAsString,onDateChange:s=>{let n=s.currentTarget.value,a=Array.isArray(n)?n[0]:n;this._stopPlaying(),this.localDate=a,this._emitUserDateTimeChangeEvent()}})}</calcite-label>${D({hidden:this.hidePlayButtons,children:me({playing:this.yearPlaying,disabled:i,label:t.playYear,onClick:()=>{this._playingState==="year"?this._playingState="none":this._playingState="year"},scale:e})})}`}#b({scale:e,disabled:i}){let{messages:t}=this;return m`<calcite-label .scale=${e} class="date-picker-container">${t.season}${ei({scale:e,selectedSeason:this.currentSeason,disabled:i,messages:t,onSeasonChange:s=>{this._stopPlaying(),this.currentSeason=s.currentTarget.value}})}</calcite-label>`}#a;get#v(){return this.#g?.value?.startTime}get localDateAsString(){return this._localDate.value??void 0}get _playingState(){return this.#t}set _playingState(e){this.#t=e,this.#n?.remove(),e==="none"?this.#e?.remove():(this._play(e),this._emitUserDateTimeChangeEvent())}get _lighting(){return this._view?.environment?.lighting}get _sunlightingDisabled(){return!g(this._lighting)}set _sunlightingDisabled(e){this.#s("sunlightingDisabled",e);let i=this._view?.environment;if(i==null)return;let t=i.lighting,s=this.#r;this.#r=t;let n={directShadowsEnabled:t.directShadowsEnabled,glow:t.glow};g(t)&&(n.cameraTrackingEnabled=t.cameraTrackingEnabled);let a=e?"virtual":"sun",c;s?.type===a?c=s:c=e?new $e:new ke({date:k(k(this.localDate,this.timeSliderPosition??0,"minutes"),this.utcOffset??0),displayUTCOffset:this.utcOffset}),c.set(n),i.lighting=c,e||(this._stopPlaying(),this.#l.value&&(this.#l.value.open=!1))}get currentSeason(){let e=this._view?.camera?.position?.latitude??0,i=ue(e);return Re(this.localDate,i)}set currentSeason(e){this._stopPlaying();let i=this._view?.camera?.position?.latitude??0,t=ue(i),s=X(e,t);this.localDate=C(this.localDate,s,"northern"),this._emitUserDateTimeChangeEvent()}get dayPlaying(){return this._playingState==="day"}set dayPlaying(e){this._playingState=e?"day":"none"}get _directShadowsDisabled(){return!this._lighting?.directShadowsEnabled}set _directShadowsDisabled(e){this.#s("directShadowsDisabled",e),this._lighting&&(this._lighting.directShadowsEnabled=!e)}get utcOffset(){return this._offset.value}set utcOffset(e){this._offset.mutate(e),!this.#s("utcOffset",e)&&this.#d()}get timeSliderPosition(){return this._timesliderPosition.value}set timeSliderPosition(e){this._timesliderPosition.mutate(fe(e??0,Ye)),!this.#s("timeSliderPosition",e)&&this.#d()}get localDate(){return this._localDate.value!=null?new Date(this._localDate.value):new Date}set localDate(e){if(typeof e=="string"&&/^\d{4}-\d{2}-\d{2}$/u.test(e)){if(this._localDate.mutate(e),this.#s("localDate",e))return;this.#d();return}let i=new Date(e);if(q(i)){i.setUTCFullYear(i.getFullYear(),i.getMonth(),i.getDate());let t=i.toISOString().slice(0,10);if(this._localDate.mutate(t),this.#s("localDate",t))return;this.#d()}}get yearPlaying(){return this._playingState==="year"}set yearPlaying(e){this._playingState=e?"year":"none"}async destroy(){await this.manager.destroy()}async load(){this.manager.onLifecycle(()=>[De(()=>{let e=this._view?.camera?.position;return e?Y(e):void 0},(e,i)=>{this.#w(e,i)},{sync:!0,initial:!0}),Se(()=>!g(this._lighting),()=>{this._stopPlaying()}),_e.onLocaleChange(()=>{this.requestUpdate()})]),this.manager.onDisconnected(()=>{this.#e?.remove(),this.#i?.remove(),this.#n?.remove()})}willUpdate(e){if(super.willUpdate(e),!!this.#o&&g(this._lighting)&&e.has("utcOffset")&&!e.has("localDate")&&!e.has("timeSliderPosition")){let i=this.utcOffset??0,{minutesSinceMidnight:t,localDate:s}=S(this._lighting.date,i);this._timesliderPosition.mutate(t),this._localDate.mutate(s)}}#o;async loaded(){let e=new AbortController;this.manager.onDisconnected(()=>({remove:()=>{e.abort()}})),await re(Te(()=>this._view?.ready,{signal:e.signal}).then(()=>{let i=this._lighting,t=this._view?.camera?.position;if(this.#a.utcOffset==null&&g(i)&&i.displayUTCOffset==null&&t){let n=Y(t);this.#h(n,i)}this.#o=!0,this.#m();let s=this._playingState;s!=="none"&&this.#e==null&&this._play(s)}))}#w(e,i){let t=this._lighting;if(!(!this.#o||!g(t)||!t.cameraTrackingEnabled||e==null)){if(i==null&&t.displayUTCOffset==null){this.#h(e,t);return}t.displayUTCOffset!=null&&(t.displayUTCOffset=e),this.#h(e,t)}}#h(e,i){i.displayUTCOffset=e,this._offset.mutate(e);let{minutesSinceMidnight:t,localDate:s}=S(i.date,e);this._timesliderPosition.mutate(t),this._localDate.mutate(s),this.requestUpdate()}_emitUserDateTimeChangeEvent(){this.isConnected&&this.arcgisUserDateTimeChange.emit()}_stopPlaying(){this._playingState="none"}#n;#x(e){if(this.#n)return;let i=setTimeout(()=>{let t=e.displayUTCOffset??0,s=e.date,{minutesSinceMidnight:n}=S(s,t);this._timesliderPosition.mutate(n),this.#n?.remove()},this.#p);this.#n=U(()=>{clearTimeout(i),this.#n=void 0;let t=this._lighting;if(g(t)){let s=t.displayUTCOffset??0,n=t.date,{minutesSinceMidnight:a}=S(n,s);this._timesliderPosition.mutate(a)}})}_play(e){this.#e?.remove();let i=this._view;if(i==null||this._sunlightingDisabled)return;let t=i.environment.lighting;if(!g(t))return;this.#_(t);let s=0;this.#e=Je({mode:e,lighting:t,beforeProgress:()=>{s=this.#v??0},onProgress:(n,a)=>{this._timesliderPosition.mutate(s),this.#x(a)},getPlaySpeed:()=>{let n=this._view,a=this._view?.environment.lighting;if(n!=null&&g(a)){let c=n.camera.position.latitude??0,o=n.camera.position.longitude??0,{sunrise:d,sunset:l}=Fe(a.date,c,o,a.displayUTCOffset??0);return Ke(d,l,a.date,Xe)*this.playSpeedMultiplier}else return L*this.playSpeedMultiplier}})}render(){let{messages:e,dateOrSeason:i}=this,t=this._sunlightingDisabled,s="m";if(this._view?.type!=="3d")return G({class:"root",label:e.componentLabel,title:e.title,hideHeader:this.hideHeader,headingLevel:this.headingLevel,children:m`<div class="unsupported"><p>${e.unsupported}</p></div>`});let n=(this.utcOffset??0)*60,a=this.view?.ready===!0,c=Array.isArray(this.timeSliderSteps)?this.timeSliderSteps.at(0):this.timeSliderSteps;return G({class:{root:!0,loading:!a},label:e.componentLabel,title:e.title,hideHeader:this.hideHeader,headingLevel:this.headingLevel,children:m`${a?void 0:m`<calcite-scrim loading></calcite-scrim>`}<div class="time-configuration" style=${B({columnGap:this.hidePlayButtons?"0":void 0})}><calcite-label class="slider-container" .scale=${s}>${e.timeSliderLabel}<arcgis-time-of-day-slider class="slider" .disabled=${this._sunlightingDisabled} mode=single .startTime=${this.timeSliderPosition??0} .steps=${c} style=${B({gridArea:"slider"})} @arcgisTimeChange=${({currentTarget:o})=>{this._stopPlaying(),this._emitUserDateTimeChangeEvent(),this.timeSliderPosition=o.startTime}} ${R(this.#g)}></arcgis-time-of-day-slider></calcite-label>${D({hidden:this.hidePlayButtons,children:me({disabled:this._sunlightingDisabled,playing:this.dayPlaying,label:e.playDay,onClick:()=>{this._playingState==="day"?this._stopPlaying():this._playingState="day"},scale:s})})}${D({hidden:this.hideTimezone,children:m`<calcite-label .scale=${s} class="timezone-input-container">${e.timezone}<calcite-input-time-zone mode=offset overlay-positioning=fixed .scale=${s} .disabled=${this._sunlightingDisabled} .value=${`${n}`} .referenceDate=${this.localDateAsString} @calciteInputTimeZoneChange=${o=>{let d=+o.target.value;this.utcOffset=d/60,this._stopPlaying()}} ${R(this.#l)}></calcite-input-time-zone></calcite-label><span></span>`})}${D({hidden:this.hideDatePicker,children:i==="date"?this.#f({scale:s,disabled:t}):this.#b({scale:s,disabled:t})})}</div>${D({hidden:this.hideSunLightingToggle,children:ii({scale:s,messages:e.sunLightingToggle,sunlightingEnabled:!this._sunlightingDisabled,onSunLightingToggle:o=>{this._sunlightingDisabled=!o}})})}${D({hidden:this.hideShadowsToggle,children:ti({scale:s,messages:e.shadowsToggle,onShadowCheckboxChange:o=>{this._directShadowsDisabled=!o},shadowEnabled:!this._directShadowsDisabled})})}`})}};function me({disabled:r,playing:e,onClick:i,label:t,scale:s="m"}){return m`<calcite-button appearance=solid .scale=${s} .disabled=${r} .iconStart=${e?"pause-f":"play-f"} .label=${t} @click=${i} round title=${t??O} type=button></calcite-button>`}function Qe({disabled:r,date:e,onDateChange:i,scale:t}){return m`<calcite-input-date-picker data-testid=daylight-date-picker .disabled=${r} overlay-positioning=fixed placement=bottom .value=${e} .scale=${t} @calciteInputDatePickerChange=${i}></calcite-input-date-picker>`}function ei({messages:r,disabled:e,scale:i,selectedSeason:t,onSeasonChange:s}){return m`<calcite-select .disabled=${e} .label=${r.season} .scale=${i} .value=${t} @calciteSelectChange=${n=>{s(n)}}>${K.map(n=>m`<calcite-option .selected=${t===n} .value=${n}>${r[n]}</calcite-option>`)}</calcite-select>`}function ii({messages:r,sunlightingEnabled:e,onSunLightingToggle:i,scale:t}){return m`<calcite-label layout=inline .scale=${t} title=${r?.tooltip??O}><calcite-checkbox .scale=${t} .checked=${e} @calciteCheckboxChange=${s=>i(s.target.checked)}></calcite-checkbox>${r?.label}</calcite-label>`}function ti({messages:r,shadowEnabled:e,onShadowCheckboxChange:i,scale:t}){return m`<calcite-label layout=inline .scale=${t} title=${r?.tooltip??O}><calcite-checkbox .checked=${e} @calciteCheckboxChange=${s=>i(s.target.checked)}></calcite-checkbox>${r.label}</calcite-label>`}te("arcgis-daylight",W);return W},"core/reactiveUtils","intl","views/3d/environment/SunLighting","views/3d/environment/VirtualLighting","applications/Components/reactiveUtils",a,b,c)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{O as o,U as d,a as s,b as t}from"./6MQTAMXU.js";import"./3TTFCHAA.js";export default $arcgis.t(([{watch:c}])=>{var n=s`.table{display:flex;flex-direction:column;border-top:1px solid var(--calcite-color-border-1)}.row{display:flex;flex-direction:row;border-bottom:1px solid var(--calcite-color-border-1);border-right:1px solid var(--calcite-color-border-1)}.data{flex:1;border-left:1px solid var(--calcite-color-border-1);padding:5px}.empty-state{width:100%;max-inline-size:unset;transition-duration:0ms;margin-top:var(--calcite-spacing-md)}`,e=class extends o{constructor(){super(...arguments),this._disabled=!1,this._hasMetadata=!1,this._missionInfo={},this._platformInfo={},this._frameInfo={}}static{this.properties={_disabled:16,_hasMetadata:16,_missionInfo:16,_platformInfo:16,_frameInfo:16,viewModel:0,messages:0}}static{this.styles=n}loaded(){this.manager.onLifecycle(()=>[c(()=>this.viewModel.state,a=>{this._disabled=a==="not-ready"||a==="waiting"},{initial:!0}),c(()=>[this.viewModel.metadata?.missionInfo,this.viewModel.metadata?.platformInfo,this.viewModel.metadata?.frameInfo],()=>{let{metadata:a}=this.viewModel;if(this._hasMetadata=!!a,!this._hasMetadata)return;let{missionInfo:i,platformInfo:r,frameInfo:l}=a;this._missionInfo=i,this._platformInfo=r,this._frameInfo=l},{initial:!0})])}render(){let{messages:a}=this;return this._disabled||!this._hasMetadata?t`<calcite-tile class="empty-state" .description=${a.metadataDescription} .heading=${a.metadataNotLoaded}></calcite-tile>`:t`<calcite-block .heading=${a.metadata} expanded><calcite-accordion appearance=solid selection-mode=single><calcite-accordion-item .heading=${a.missionInfo}><div class="table">${Object.keys(this._missionInfo).map(i=>t`<div class="row"><div class="data">${i}</div><div class="data">${this._missionInfo[i]}</div></div>`)}</div></calcite-accordion-item><calcite-accordion-item .heading=${a.platformInfo}><div class="table">${Object.keys(this._platformInfo).map(i=>t`<div class="row"><div class="data">${i}</div><div class="data">${this._platformInfo[i]}</div></div>`)}</div></calcite-accordion-item><calcite-accordion-item .heading=${a.frameInfo}><div class="table">${Object.keys(this._frameInfo).map(i=>t`<div class="row"><div class="data">${i}</div><div class="data">${this._frameInfo[i]}</div></div>`)}</div></calcite-accordion-item></calcite-accordion></calcite-block>`}};d("arcgis-video-player-metadata",e);return e},"core/reactiveUtils")
2
+ import{O as o,U as d,a as s,b as t}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{watch:c}])=>{var n=s`.table{display:flex;flex-direction:column;border-top:1px solid var(--calcite-color-border-1)}.row{display:flex;flex-direction:row;border-bottom:1px solid var(--calcite-color-border-1);border-right:1px solid var(--calcite-color-border-1)}.data{flex:1;border-left:1px solid var(--calcite-color-border-1);padding:5px}.empty-state{width:100%;max-inline-size:unset;transition-duration:0ms;margin-top:var(--calcite-spacing-md)}`,e=class extends o{constructor(){super(...arguments),this._disabled=!1,this._hasMetadata=!1,this._missionInfo={},this._platformInfo={},this._frameInfo={}}static{this.properties={_disabled:16,_hasMetadata:16,_missionInfo:16,_platformInfo:16,_frameInfo:16,viewModel:0,messages:0}}static{this.styles=n}loaded(){this.manager.onLifecycle(()=>[c(()=>this.viewModel.state,a=>{this._disabled=a==="not-ready"||a==="waiting"},{initial:!0}),c(()=>[this.viewModel.metadata?.missionInfo,this.viewModel.metadata?.platformInfo,this.viewModel.metadata?.frameInfo],()=>{let{metadata:a}=this.viewModel;if(this._hasMetadata=!!a,!this._hasMetadata)return;let{missionInfo:i,platformInfo:r,frameInfo:l}=a;this._missionInfo=i,this._platformInfo=r,this._frameInfo=l},{initial:!0})])}render(){let{messages:a}=this;return this._disabled||!this._hasMetadata?t`<calcite-tile class="empty-state" .description=${a.metadataDescription} .heading=${a.metadataNotLoaded}></calcite-tile>`:t`<calcite-block .heading=${a.metadata} expanded><calcite-accordion appearance=solid selection-mode=single><calcite-accordion-item .heading=${a.missionInfo}><div class="table">${Object.keys(this._missionInfo).map(i=>t`<div class="row"><div class="data">${i}</div><div class="data">${this._missionInfo[i]}</div></div>`)}</div></calcite-accordion-item><calcite-accordion-item .heading=${a.platformInfo}><div class="table">${Object.keys(this._platformInfo).map(i=>t`<div class="row"><div class="data">${i}</div><div class="data">${this._platformInfo[i]}</div></div>`)}</div></calcite-accordion-item><calcite-accordion-item .heading=${a.frameInfo}><div class="table">${Object.keys(this._frameInfo).map(i=>t`<div class="row"><div class="data">${i}</div><div class="data">${this._frameInfo[i]}</div></div>`)}</div></calcite-accordion-item></calcite-accordion></calcite-block>`}};d("arcgis-video-player-metadata",e);return e},"core/reactiveUtils")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as C}from"./MP6Z45SA.js";import{a as I}from"./KLSSO2IB.js";import a from"./R3NYK6BO.js";import{O as $,S as F,U as L,a as q,b as p}from"./6MQTAMXU.js";import"./3TTFCHAA.js";export default $arcgis.t(([{createReactiveMap:k,findUtilityNetwork:U,getOrCreateMapValue:x},{stripHTML:E},f,{ignoreAbortErrors:S},{watch:v},V,P,Q,B,G,{b:N,f:A}])=>{var R=q`.list-container{min-height:var(--calcite-spacing-xxxl)}.loading-container{display:flex;justify-content:center;padding:var(--calcite-spacing-md) 0;width:100%}.sticky-loading-container{display:flex;position:sticky;bottom:var(--calcite-spacing-sm);align-items:center;justify-content:center;z-index:2;margin:0;padding:0;height:var(--calcite-spacing-xxxl);pointer-events:none;height:500px}`,M=100,D={assetGroup:"assetgroup",assetType:"assettype"},j="{00000000-0000-0000-0000-000000000000}",T=class extends ${constructor(){super(...arguments),this._addFlowItem=t=>{t&&this.flowItems?.push(t)},this._attachmentAssociations=new f,this._attachmentFeatureCount=0,this._cancelQuery=()=>{let{_queryAbortController:t}=this;t&&t.abort(),this._queryAbortController=null},this._cancelQueryFeatureCount=()=>{let{_queryFeatureCountAbortController:t}=this;t&&t.abort(),this._queryFeatureCountAbortController=null},this._connectivityAssociations=new f,this._connectivityFeatureCount=0,this._containerAssociations=new f,this._containerFeatureCount=0,this._contentAssociations=new f,this._contentFeatureCount=0,this._networkSourceIdsInUse=new Set,this._query=async t=>{if(!t)return;await this._loadUtiltyNetworks();let{_queryAbortController:e}=this;this._destroyAssociatedFeatureViewModels(),this._clearFeatures(),this._featureCount&&await this._queryAssociatedFeatures(t,{signal:e?.signal})},this._queryController=async t=>{this._cancelQuery();let e=new AbortController;this._queryAbortController=e,await S(this._query(t)),this._queryAbortController===e&&(this._queryAbortController=null)},this._queryFeatureCountController=async()=>{this._loaded=!1,this._cancelQueryFeatureCount();let t=new AbortController;this._queryFeatureCountAbortController=t,await S(this._queryFeatureCount()),this._queryFeatureCountAbortController===t&&(this._queryFeatureCountAbortController=null),this._loaded=!0},this._queryDebounced=C(this._queryController,M),this._queryFeatureCountDebounced=C(this._queryFeatureCountController,M),this._structureAssociations=new f,this._structureFeatureCount=0,this._queryAssociationType=async()=>{this._activeAssociationType&&this._queryDebounced(this._activeAssociationType)},this._associationFeatures=k(),this._associationViewModels=k(),this._featureCount=0,this._loaded=!1,this._queryAbortController=null,this._queryFeatureCountAbortController=null,this._queryPageAbortController=null,this.associationTypes=null,this.autoDestroyDisabled=!1,this.useFeatureNextFlowItem=!1,this.flowType="feature-utility-network-associations",this.headingLevel=2,this.source="popup"}static{this.properties={_activeAssociationType:16,_associationFeatures:16,_associationViewModels:16,_canLoad:16,_canQuery:16,_featureCount:16,_loaded:16,_queryAbortController:16,_queryFeatureCountAbortController:16,_queryPageAbortController:16,_state:16,associationTypes:0,autoDestroyDisabled:5,description:1,flowItems:0,useFeatureNextFlowItem:5,flowType:1,graphic:0,heading:1,headingLevel:9,layer:0,map:0,messages:0,parentFeatureViewModel:0,referenceElement:1,source:1,spatialReference:0,timeZone:1,view:0}}static{this.styles=R}get _globalId(){return(this._globalIdField&&this.graphic?.attributes?.[this._globalIdField])??null}get _globalIdField(){return this.layer?.globalIdField}get _objectId(){return(this._objectIdField&&this.graphic?.attributes?.[this._objectIdField])??null}get _objectIdField(){return this.layer?.objectIdField}get _supportsCacheHint(){return!!this.layer?.capabilities?.queryRelated?.supportsCacheHint}get _utilityNetwork(){let{layer:t,map:e}=this;if(!t?.loaded||!e)return null;let s=A(t)?t.parent:t;return U(e,s)}get _canLoad(){return!!this.map}get _canQuery(){return!!this.layer?.capabilities?.query?.supportsPagination}get _state(){let{_canLoad:t,_canQuery:e,_featureCount:s,_loaded:a,_queryAbortController:i,_queryFeatureCountAbortController:o,_queryPageAbortController:r,associationTypes:l}=this;return o||t&&!a?"loading":i||r?"querying":!this._globalId||!l||!e||!s?"disabled":"ready"}get heading(){return this._heading}set heading(t){this._heading=t}async destroy(){await this.manager.destroy()}loaded(){this.manager.onLifecycle(()=>[v(()=>[this.graphic,this.layer,this.map,this.associationTypes,this._canQuery,this._objectId,this._globalId],()=>{this._queryFeatureCountDebounced(),this._queryAssociationType()},{initial:!0}),v(()=>this._activeAssociationType,t=>{this._queryDebounced(t)}),v(()=>this._associationFeatures.values(),()=>{this._setUpUtilityNetworkAssociationsViewModels()})]),this.manager.onDestroy(()=>{this._cancelQuery(),this._cancelQueryFeatureCount()})}_addAssociationTypeFlowItem(t){let e=this.useFeatureNextFlowItem?F(p`<arcgis-feature-utility-network-association-list .autoDestroyDisabled=${this.autoDestroyDisabled} .associationViewModels=${this._associationViewModels} .description=${this._getParentFeatureDescription()} .flowItems=${this.flowItems} .flowType=${this.flowType} .heading=${this._getAssociationTypeTitle(t)} .messages=${this.messages} .map=${this.map} .parentFeatureViewModel=${this.parentFeatureViewModel} .referenceElement=${this.referenceElement} .state=${this._state} .spatialReference=${this.spatialReference} .timeZone=${this.timeZone} use-feature-next-flow-item .view=${this.view}></arcgis-feature-utility-network-association-list>`):F(p`<arcgis-feature-utility-network-association-list .autoDestroyDisabled=${this.autoDestroyDisabled} .associationViewModels=${this._associationViewModels} .description=${this._getParentFeatureDescription()} .flowItems=${this.flowItems} .flowType=${this.flowType} .heading=${this._getAssociationTypeTitle(t)} .messages=${this.messages} .map=${this.map} .parentFeatureViewModel=${this.parentFeatureViewModel} .referenceElement=${this.referenceElement} .state=${this._state} .spatialReference=${this.spatialReference} .timeZone=${this.timeZone} .view=${this.view}></arcgis-feature-utility-network-association-list>`);this._addFlowItem(e)}_clearAssociations(){this._attachmentAssociations.removeAll(),this._connectivityAssociations.removeAll(),this._containerAssociations.removeAll(),this._contentAssociations.removeAll(),this._structureAssociations.removeAll()}_clearFeatures(){this._associationFeatures.forEach(t=>t.removeAll()),this._associationFeatures.clear()}_compareByFeatureTitle(t,e){return t.title.localeCompare(e.title,void 0,{numeric:!0})}async _countAssociatedFeatureCount(t,e,s,a,i){let o=this._getFeatureQueryWhereClause(t,e,s,a);return await t.queryFeatureCount({where:o,outFields:["*"],returnGeometry:!1},{signal:i?.signal})}async _countAssociatedFeatures(t,e,s,a,i){if(!e.length)return 0;let o=await this._findLayersBySourceId(t);await this._loadLayers(o);let r=o.map(l=>this._countAssociatedFeatureCount(l,e,s,a,i));return(await Promise.all(r)).reduce((l,c)=>l+c,0)}async _createAssociationFeatureObjects(t,e,s,a,i){if(!t.length)return[];let o=new Map,r=Array.from(e.entries()).map(async([c,d])=>{let u=await this._findLayersBySourceId(c);await this._loadLayers(u);let h=u.map(m=>this._queryLayer(m,d,s,a,i));(await Promise.all(h)).forEach(m=>{m.forEach(n=>{if(this.source==="popup"?n.sourceLayer&&n.getEffectivePopupTemplate():n.sourceLayer){let _=n.layer.globalIdField??"",y=n.getAttribute(_),w=o.get(y)??[];w.push(n),o.set(y,w)}})})});await Promise.all(r);let l=[];return await Promise.all(t.toArray().map(async c=>{let{fromNetworkElement:d,toNetworkElement:u}=c,h=d.globalId===this._globalId?u:d,m=o.get(h.globalId)??[];await Promise.all(m.map(async n=>{let _=this._utilityNetwork?.getTerminalById(h?.terminalId??void 0)?.name,y=await n.sourceLayer.getFeatureTitle(n)||this._getFeatureTitle(n);l.push({title:y,feature:n,association:c,terminalName:_})}))})),l}_destroyAssociatedFeatureViewModels(){this._associationViewModels.forEach(t=>t.destroyAll())}_equals(t,e){if(t.globalId===j&&e.globalId===j){let s=function(d,u){return d.networkSourceId===u.networkSourceId&&d.globalId===u.globalId&&d.terminalId===u.terminalId&&d.firstUnit===u.firstUnit&&d.numUnits===u.numUnits},a=t.fromNetworkElement,i=t.toNetworkElement,o=e.fromNetworkElement,r=e.toNetworkElement,l=s(a,o),c=s(i,r);return l&&c&&t.associationType===e.associationType}return t.globalId!=null&&e.globalId!=null&&t.globalId===e.globalId}async _findLayersBySourceId(t){let{_utilityNetwork:e,map:s}=this;e?.loaded||await e?.load();let a=e.getLayerIdBySourceId(t),i=s.allLayers.filter(r=>!!e?.isUtilityLayer(r)&&r.layerId===a),o=s.allTables.filter(r=>!!e?.isUtilityLayer(r)&&r.layerId===a);return i.concat(o).toArray()}_getAssociationsByType(t){switch(t){case"attachment":return this._attachmentAssociations;case"structure":return this._structureAssociations;case"connectivity":return this._connectivityAssociations;case"container":return this._containerAssociations;case"content":return this._contentAssociations}}_getAssociationTypeTitle(t){let{messages:e}=this;if(t.title)return t.title;switch(t.type){case"attachment":return e?.associationsAttachments??this.messages?.noTitle??"";case"connectivity":return e?.associationsConnectivity??this.messages?.noTitle??"";case"structure":return e?.associationsStructure??this.messages?.noTitle??"";case"content":return e?.associationsContents??this.messages?.noTitle??"";case"container":return e?.associationsContainer??this.messages?.noTitle??""}}_getFeatureCountForAssociationType(t){switch(t){case"attachment":return this._attachmentFeatureCount;case"structure":return this._structureFeatureCount;case"content":return this._contentFeatureCount;case"container":return this._containerFeatureCount;case"connectivity":return this._connectivityFeatureCount}}_getFeatureQueryWhereClause(t,e,s,a){let i=t.globalIdField,o=t.fieldsIndex.get(D.assetGroup),r=t.fieldsIndex.get(D.assetType),l=s!=null,c=a!=null,d=i?V.sqlIn(i,e):null,u=l?`(${o?.name} = ${s})`:null,h=l&&c?`(${r?.name} = ${a})`:null;return[d,u,h].filter(Boolean).join(" AND ")}_getFeatureTitle(t){let e=t.attributes,s=t.sourceLayer;if(!e||!s)return"";let a="displayField"in s?s.displayField:null,i=a!=null?e[a.toString()]:null,o=i!=null?i.toString():null,r=t.getObjectId()?.toString();return o||r||""}_getParentFeatureDescription(){let{parentFeatureViewModel:t}=this;if(t){if("heading"in t)return t.heading;if("title"in t)return t.title}}async _loadUtiltyNetworks(){let t=this.map;if(!t)return;t.utilityNetworks&&await Promise.allSettled(t.utilityNetworks.map(s=>s.load()));let e=this._utilityNetwork;if(e){let s=a=>{if("layerId"in a&&e.isUtilityLayer(a)){let i=a.layerId!=null?e.getSourceIdByLayerId(a.layerId):null;i!=null&&this._networkSourceIdsInUse.add(i)}};this._networkSourceIdsInUse=new Set,t.allLayers.forEach(s),t.allTables.forEach(s)}}async _loadLayers(t){let e=t.filter(s=>!s.loaded).map(s=>s.load());e.length&&await Promise.allSettled(e)}_matchesGlobalFeature(t,e){return this._equals(t.association,e.association)}async _queryAssociatedFeatures(t,e){let{layer:s,_globalId:a,associationTypes:i,_utilityNetwork:o,_canQuery:r,_associationFeatures:l}=this;if(await Promise.allSettled([s?.load(),o?.load()]),!r||!s||!i||!o)return;let c=this._getAssociationsByType(t.type),{associatedAssetGroup:d,associatedAssetType:u}=t,h=new Map;c.forEach(n=>{let{fromNetworkElement:_,toNetworkElement:y}=n,{networkSourceId:w,elementGlobalId:b}=_.globalId===a?{networkSourceId:y.networkSourceId,elementGlobalId:y.globalId}:{networkSourceId:_.networkSourceId,elementGlobalId:_.globalId},g=h.get(w)||[];g.push(b),h.set(w,g)});let m=await this._createAssociationFeatureObjects(c,h,d,u,e);this._parseFeatureObjects(m,l)}async _queryAssociations(t){let{layer:e,_globalId:s,associationTypes:a,_utilityNetwork:i,_canQuery:o}=this;if(await Promise.allSettled([e?.load(),i?.load()]),this._clearAssociations(),!o||!e||!a||!i||!s)return;let r=A(e)?e.parent:e,l=new P({globalId:s,networkSourceId:i.getSourceIdByLayerId(r.layerId)}),c=new Set;a.forEach(n=>{switch(n.type){case"attachment":case"structure":c.add("attachment");break;case"container":case"content":c.add("containment");break;case"connectivity":c.add("connectivity"),c.add("junction-junction-connectivity"),c.add("junction-edge-from-connectivity"),c.add("junction-edge-midspan-connectivity"),c.add("junction-edge-to-connectivity");break}});let d=await i?.queryAssociations(new Q({elements:[l],types:Array.from(c)}),{signal:t?.signal}),u=new Map,h=new Map;a.forEach(n=>{h.set(n.type,n),u.set(n.type,[])}),d.forEach(n=>{let{toNetworkElement:_,fromNetworkElement:y}=n;switch(n.associationType){case"attachment":if(y?.globalId===s){if(this._shouldDiscardNetworkElement(_,"attachment",h))break;u.get("attachment")?.push(_.globalId),this._attachmentAssociations.add(n)}else{if(this._shouldDiscardNetworkElement(y,"structure",h))break;u.get("structure")?.push(y.globalId),this._structureAssociations.add(n)}break;case"connectivity":case"junction-edge-from-connectivity":case"junction-edge-midspan-connectivity":case"junction-edge-to-connectivity":case"junction-junction-connectivity":if(y?.globalId===s){if(this._shouldDiscardNetworkElement(_,"connectivity",h))break;u.get("connectivity")?.push(_.globalId)}else{if(this._shouldDiscardNetworkElement(y,"connectivity",h))break;u.get("connectivity")?.push(y.globalId)}this._connectivityAssociations.add(n);break;case"containment":if(y?.globalId===s){if(this._shouldDiscardNetworkElement(_,"content",h))break;u.get("content")?.push(_.globalId),this._contentAssociations.add(n)}else{if(this._shouldDiscardNetworkElement(y,"container",h))break;u.get("container")?.push(y.globalId),this._containerAssociations.add(n)}break}});let m=a.map(async n=>{let{associatedNetworkSourceId:_,associatedAssetGroup:y,associatedAssetType:w}=n,b=u.get(n.type),g=y!=null?await this._countAssociatedFeatures(_,b,y,w,t):b.length;switch(n.type){case"attachment":this._attachmentFeatureCount=g;break;case"connectivity":this._connectivityFeatureCount=g;break;case"container":this._containerFeatureCount=g;break;case"content":this._contentFeatureCount=g;break;case"structure":this._structureFeatureCount=g;break}});await Promise.allSettled(m)}async _queryFeatureCount(){await this._loadUtiltyNetworks();let{_queryFeatureCountAbortController:t,_canQuery:e}=this;if(!e){this._featureCount=0;return}await this._queryAssociations(t),this._featureCount=this._attachmentFeatureCount+this._connectivityFeatureCount+this._containerFeatureCount+this._contentFeatureCount+this._structureFeatureCount}async _queryLayer(t,e,s,a,i){let o=this._getFeatureQueryWhereClause(t,e,s,a),r=new B({where:o,outFields:["*"],cacheHint:this._supportsCacheHint}),{features:l}=await N(t,r,i);return l}_parseFeatureObjects(t,e){let s=k();t.forEach(a=>{let i=(a?.feature).sourceLayer;x(s,i,()=>new f).add(a)});for(let[a,i]of s)this._sortFeatureObjectsByTitle(i),e.set(a,i)}_selectAssociationType(t){let{flowItems:e}=this;e&&(this._activeAssociationType=t,this._setUpUtilityNetworkAssociationsViewModels(),this._addAssociationTypeFlowItem(t))}_setUpUtilityNetworkAssociationsViewModels(){this._associationViewModels.forEach((i,o)=>{let r=this._associationFeatures.get(o);r?i.forEach(l=>{r.find(c=>this._matchesGlobalFeature(l,c))||(i.remove(l),i.length||this._associationViewModels.delete(o))}):(i.removeAll(),this._associationViewModels.delete(o))});let{map:t,view:e,spatialReference:s,timeZone:a}=this;this._associationFeatures.forEach((i,o)=>{let r=this._associationViewModels.get(o)||new f;i?.filter(Boolean).forEach((l,c)=>{if(!r.some(d=>this._matchesGlobalFeature(d,l))){let{association:d,feature:u,terminalName:h,title:m}=l;r.add({title:m,association:d,featureViewModel:new G({abilities:{utilityNetworkAssociationsContent:!1},map:t,view:e,spatialReference:s,timeZone:a,graphic:u}),terminalName:h},c)}}),this._associationViewModels.set(o,r)})}_shouldDiscardNetworkElement(t,e,s){if(!t)return!1;let{networkSourceId:a}=t,i=s.get(e)?.associatedNetworkSourceId,o=this._networkSourceIdsInUse.has(a);return i!=null&&i!==a||!o}_sortFeatureObjectsByTitle(t){t.sort(this._compareByFeatureTitle)}render(){let{_state:t}=this;return p`<div class="root"><arcgis-feature-element-info .heading=${this.heading} .headingLevel=${this.headingLevel} .description=${this.description}></arcgis-feature-element-info>${t==="loading"?this._renderLoading():t==="disabled"?this._renderAssociationNotFound():this._renderContent()}</div>`}_renderAssociationNotFound(){return p`<calcite-notice icon=information kind=info open scale=s width=full><div slot=message>${this.messages?.noAssociations}</div></calcite-notice>`}_renderAssociationTypeList(t){return this._getFeatureCountForAssociationType(t.type)>0?this._renderAssociationTypeListItem(t):null}_renderAssociationTypeListItem(t){let e=this._getAssociationTypeTitle(t);return I(`association-type-${t.type}`,p`<calcite-list-item .description=${E(t.description)} .label=${E(e)} .value=${t.type} @calciteListItemSelect=${()=>this._selectAssociationType(t)}><calcite-icon flip-rtl icon=chevron-right scale=s slot=content-end></calcite-icon></calcite-list-item>`)}_renderContent(){let{_state:t,associationTypes:e,messages:s}=this,a=s?.associationsList??s?.noTitle??"";return I("list-container",p`<div class="list-container">${t==="ready"?p`<div><calcite-list display-mode=flat .label=${a}>${e.map(i=>this._renderAssociationTypeList(i))}</calcite-list></div>`:null}${this._renderStickyLoading()}</div>`)}_renderLoading(){return p`<div class="loading-container">${this._renderLoadingIcon()}${this._renderStickyLoading()}</div>`}_renderLoadingIcon(){return p`<calcite-loader inline label></calcite-loader>`}_renderStickyLoading(){return this._state==="querying"?p`<div class="sticky-loading-container">${this._renderLoadingIcon()}</div>`:null}};L("arcgis-feature-utility-network-associations",T);return T},"applications/Components/featureUtils","applications/Components/stringUtils","core/Collection","core/promiseUtils","core/reactiveUtils","core/sql","rest/networks/support/NetworkElement","rest/networks/support/QueryAssociationsParameters","rest/support/Query","popup/Feature",a)
2
+ import{a as C}from"./MP6Z45SA.js";import{a as I}from"./HS2QCKGL.js";import a from"./R3NYK6BO.js";import{O as $,S as F,U as L,a as q,b as p}from"./KQLKJSEY.js";import"./3TTFCHAA.js";export default $arcgis.t(([{createReactiveMap:k,findUtilityNetwork:U,getOrCreateMapValue:x},{stripHTML:E},f,{ignoreAbortErrors:S},{watch:v},V,P,Q,B,G,{b:N,f:A}])=>{var R=q`.list-container{min-height:var(--calcite-spacing-xxxl)}.loading-container{display:flex;justify-content:center;padding:var(--calcite-spacing-md) 0;width:100%}.sticky-loading-container{display:flex;position:sticky;bottom:var(--calcite-spacing-sm);align-items:center;justify-content:center;z-index:2;margin:0;padding:0;height:var(--calcite-spacing-xxxl);pointer-events:none;height:500px}`,M=100,D={assetGroup:"assetgroup",assetType:"assettype"},j="{00000000-0000-0000-0000-000000000000}",T=class extends ${constructor(){super(...arguments),this._addFlowItem=t=>{t&&this.flowItems?.push(t)},this._attachmentAssociations=new f,this._attachmentFeatureCount=0,this._cancelQuery=()=>{let{_queryAbortController:t}=this;t&&t.abort(),this._queryAbortController=null},this._cancelQueryFeatureCount=()=>{let{_queryFeatureCountAbortController:t}=this;t&&t.abort(),this._queryFeatureCountAbortController=null},this._connectivityAssociations=new f,this._connectivityFeatureCount=0,this._containerAssociations=new f,this._containerFeatureCount=0,this._contentAssociations=new f,this._contentFeatureCount=0,this._networkSourceIdsInUse=new Set,this._query=async t=>{if(!t)return;await this._loadUtiltyNetworks();let{_queryAbortController:e}=this;this._destroyAssociatedFeatureViewModels(),this._clearFeatures(),this._featureCount&&await this._queryAssociatedFeatures(t,{signal:e?.signal})},this._queryController=async t=>{this._cancelQuery();let e=new AbortController;this._queryAbortController=e,await S(this._query(t)),this._queryAbortController===e&&(this._queryAbortController=null)},this._queryFeatureCountController=async()=>{this._loaded=!1,this._cancelQueryFeatureCount();let t=new AbortController;this._queryFeatureCountAbortController=t,await S(this._queryFeatureCount()),this._queryFeatureCountAbortController===t&&(this._queryFeatureCountAbortController=null),this._loaded=!0},this._queryDebounced=C(this._queryController,M),this._queryFeatureCountDebounced=C(this._queryFeatureCountController,M),this._structureAssociations=new f,this._structureFeatureCount=0,this._queryAssociationType=async()=>{this._activeAssociationType&&this._queryDebounced(this._activeAssociationType)},this._associationFeatures=k(),this._associationViewModels=k(),this._featureCount=0,this._loaded=!1,this._queryAbortController=null,this._queryFeatureCountAbortController=null,this._queryPageAbortController=null,this.associationTypes=null,this.autoDestroyDisabled=!1,this.useFeatureNextFlowItem=!1,this.flowType="feature-utility-network-associations",this.headingLevel=2,this.source="popup"}static{this.properties={_activeAssociationType:16,_associationFeatures:16,_associationViewModels:16,_canLoad:16,_canQuery:16,_featureCount:16,_loaded:16,_queryAbortController:16,_queryFeatureCountAbortController:16,_queryPageAbortController:16,_state:16,associationTypes:0,autoDestroyDisabled:5,description:1,flowItems:0,useFeatureNextFlowItem:5,flowType:1,graphic:0,heading:1,headingLevel:9,layer:0,map:0,messages:0,parentFeatureViewModel:0,referenceElement:1,source:1,spatialReference:0,timeZone:1,view:0}}static{this.styles=R}get _globalId(){return(this._globalIdField&&this.graphic?.attributes?.[this._globalIdField])??null}get _globalIdField(){return this.layer?.globalIdField}get _objectId(){return(this._objectIdField&&this.graphic?.attributes?.[this._objectIdField])??null}get _objectIdField(){return this.layer?.objectIdField}get _supportsCacheHint(){return!!this.layer?.capabilities?.queryRelated?.supportsCacheHint}get _utilityNetwork(){let{layer:t,map:e}=this;if(!t?.loaded||!e)return null;let s=A(t)?t.parent:t;return U(e,s)}get _canLoad(){return!!this.map}get _canQuery(){return!!this.layer?.capabilities?.query?.supportsPagination}get _state(){let{_canLoad:t,_canQuery:e,_featureCount:s,_loaded:a,_queryAbortController:i,_queryFeatureCountAbortController:o,_queryPageAbortController:r,associationTypes:l}=this;return o||t&&!a?"loading":i||r?"querying":!this._globalId||!l||!e||!s?"disabled":"ready"}get heading(){return this._heading}set heading(t){this._heading=t}async destroy(){await this.manager.destroy()}loaded(){this.manager.onLifecycle(()=>[v(()=>[this.graphic,this.layer,this.map,this.associationTypes,this._canQuery,this._objectId,this._globalId],()=>{this._queryFeatureCountDebounced(),this._queryAssociationType()},{initial:!0}),v(()=>this._activeAssociationType,t=>{this._queryDebounced(t)}),v(()=>this._associationFeatures.values(),()=>{this._setUpUtilityNetworkAssociationsViewModels()})]),this.manager.onDestroy(()=>{this._cancelQuery(),this._cancelQueryFeatureCount()})}_addAssociationTypeFlowItem(t){let e=this.useFeatureNextFlowItem?F(p`<arcgis-feature-utility-network-association-list .autoDestroyDisabled=${this.autoDestroyDisabled} .associationViewModels=${this._associationViewModels} .description=${this._getParentFeatureDescription()} .flowItems=${this.flowItems} .flowType=${this.flowType} .heading=${this._getAssociationTypeTitle(t)} .messages=${this.messages} .map=${this.map} .parentFeatureViewModel=${this.parentFeatureViewModel} .referenceElement=${this.referenceElement} .state=${this._state} .spatialReference=${this.spatialReference} .timeZone=${this.timeZone} use-feature-next-flow-item .view=${this.view}></arcgis-feature-utility-network-association-list>`):F(p`<arcgis-feature-utility-network-association-list .autoDestroyDisabled=${this.autoDestroyDisabled} .associationViewModels=${this._associationViewModels} .description=${this._getParentFeatureDescription()} .flowItems=${this.flowItems} .flowType=${this.flowType} .heading=${this._getAssociationTypeTitle(t)} .messages=${this.messages} .map=${this.map} .parentFeatureViewModel=${this.parentFeatureViewModel} .referenceElement=${this.referenceElement} .state=${this._state} .spatialReference=${this.spatialReference} .timeZone=${this.timeZone} .view=${this.view}></arcgis-feature-utility-network-association-list>`);this._addFlowItem(e)}_clearAssociations(){this._attachmentAssociations.removeAll(),this._connectivityAssociations.removeAll(),this._containerAssociations.removeAll(),this._contentAssociations.removeAll(),this._structureAssociations.removeAll()}_clearFeatures(){this._associationFeatures.forEach(t=>t.removeAll()),this._associationFeatures.clear()}_compareByFeatureTitle(t,e){return t.title.localeCompare(e.title,void 0,{numeric:!0})}async _countAssociatedFeatureCount(t,e,s,a,i){let o=this._getFeatureQueryWhereClause(t,e,s,a);return await t.queryFeatureCount({where:o,outFields:["*"],returnGeometry:!1},{signal:i?.signal})}async _countAssociatedFeatures(t,e,s,a,i){if(!e.length)return 0;let o=await this._findLayersBySourceId(t);await this._loadLayers(o);let r=o.map(l=>this._countAssociatedFeatureCount(l,e,s,a,i));return(await Promise.all(r)).reduce((l,c)=>l+c,0)}async _createAssociationFeatureObjects(t,e,s,a,i){if(!t.length)return[];let o=new Map,r=Array.from(e.entries()).map(async([c,d])=>{let u=await this._findLayersBySourceId(c);await this._loadLayers(u);let h=u.map(m=>this._queryLayer(m,d,s,a,i));(await Promise.all(h)).forEach(m=>{m.forEach(n=>{if(this.source==="popup"?n.sourceLayer&&n.getEffectivePopupTemplate():n.sourceLayer){let _=n.layer.globalIdField??"",y=n.getAttribute(_),w=o.get(y)??[];w.push(n),o.set(y,w)}})})});await Promise.all(r);let l=[];return await Promise.all(t.toArray().map(async c=>{let{fromNetworkElement:d,toNetworkElement:u}=c,h=d.globalId===this._globalId?u:d,m=o.get(h.globalId)??[];await Promise.all(m.map(async n=>{let _=this._utilityNetwork?.getTerminalById(h?.terminalId??void 0)?.name,y=await n.sourceLayer.getFeatureTitle(n)||this._getFeatureTitle(n);l.push({title:y,feature:n,association:c,terminalName:_})}))})),l}_destroyAssociatedFeatureViewModels(){this._associationViewModels.forEach(t=>t.destroyAll())}_equals(t,e){if(t.globalId===j&&e.globalId===j){let s=function(d,u){return d.networkSourceId===u.networkSourceId&&d.globalId===u.globalId&&d.terminalId===u.terminalId&&d.firstUnit===u.firstUnit&&d.numUnits===u.numUnits},a=t.fromNetworkElement,i=t.toNetworkElement,o=e.fromNetworkElement,r=e.toNetworkElement,l=s(a,o),c=s(i,r);return l&&c&&t.associationType===e.associationType}return t.globalId!=null&&e.globalId!=null&&t.globalId===e.globalId}async _findLayersBySourceId(t){let{_utilityNetwork:e,map:s}=this;e?.loaded||await e?.load();let a=e.getLayerIdBySourceId(t),i=s.allLayers.filter(r=>!!e?.isUtilityLayer(r)&&r.layerId===a),o=s.allTables.filter(r=>!!e?.isUtilityLayer(r)&&r.layerId===a);return i.concat(o).toArray()}_getAssociationsByType(t){switch(t){case"attachment":return this._attachmentAssociations;case"structure":return this._structureAssociations;case"connectivity":return this._connectivityAssociations;case"container":return this._containerAssociations;case"content":return this._contentAssociations}}_getAssociationTypeTitle(t){let{messages:e}=this;if(t.title)return t.title;switch(t.type){case"attachment":return e?.associationsAttachments??this.messages?.noTitle??"";case"connectivity":return e?.associationsConnectivity??this.messages?.noTitle??"";case"structure":return e?.associationsStructure??this.messages?.noTitle??"";case"content":return e?.associationsContents??this.messages?.noTitle??"";case"container":return e?.associationsContainer??this.messages?.noTitle??""}}_getFeatureCountForAssociationType(t){switch(t){case"attachment":return this._attachmentFeatureCount;case"structure":return this._structureFeatureCount;case"content":return this._contentFeatureCount;case"container":return this._containerFeatureCount;case"connectivity":return this._connectivityFeatureCount}}_getFeatureQueryWhereClause(t,e,s,a){let i=t.globalIdField,o=t.fieldsIndex.get(D.assetGroup),r=t.fieldsIndex.get(D.assetType),l=s!=null,c=a!=null,d=i?V.sqlIn(i,e):null,u=l?`(${o?.name} = ${s})`:null,h=l&&c?`(${r?.name} = ${a})`:null;return[d,u,h].filter(Boolean).join(" AND ")}_getFeatureTitle(t){let e=t.attributes,s=t.sourceLayer;if(!e||!s)return"";let a="displayField"in s?s.displayField:null,i=a!=null?e[a.toString()]:null,o=i!=null?i.toString():null,r=t.getObjectId()?.toString();return o||r||""}_getParentFeatureDescription(){let{parentFeatureViewModel:t}=this;if(t){if("heading"in t)return t.heading;if("title"in t)return t.title}}async _loadUtiltyNetworks(){let t=this.map;if(!t)return;t.utilityNetworks&&await Promise.allSettled(t.utilityNetworks.map(s=>s.load()));let e=this._utilityNetwork;if(e){let s=a=>{if("layerId"in a&&e.isUtilityLayer(a)){let i=a.layerId!=null?e.getSourceIdByLayerId(a.layerId):null;i!=null&&this._networkSourceIdsInUse.add(i)}};this._networkSourceIdsInUse=new Set,t.allLayers.forEach(s),t.allTables.forEach(s)}}async _loadLayers(t){let e=t.filter(s=>!s.loaded).map(s=>s.load());e.length&&await Promise.allSettled(e)}_matchesGlobalFeature(t,e){return this._equals(t.association,e.association)}async _queryAssociatedFeatures(t,e){let{layer:s,_globalId:a,associationTypes:i,_utilityNetwork:o,_canQuery:r,_associationFeatures:l}=this;if(await Promise.allSettled([s?.load(),o?.load()]),!r||!s||!i||!o)return;let c=this._getAssociationsByType(t.type),{associatedAssetGroup:d,associatedAssetType:u}=t,h=new Map;c.forEach(n=>{let{fromNetworkElement:_,toNetworkElement:y}=n,{networkSourceId:w,elementGlobalId:b}=_.globalId===a?{networkSourceId:y.networkSourceId,elementGlobalId:y.globalId}:{networkSourceId:_.networkSourceId,elementGlobalId:_.globalId},g=h.get(w)||[];g.push(b),h.set(w,g)});let m=await this._createAssociationFeatureObjects(c,h,d,u,e);this._parseFeatureObjects(m,l)}async _queryAssociations(t){let{layer:e,_globalId:s,associationTypes:a,_utilityNetwork:i,_canQuery:o}=this;if(await Promise.allSettled([e?.load(),i?.load()]),this._clearAssociations(),!o||!e||!a||!i||!s)return;let r=A(e)?e.parent:e,l=new P({globalId:s,networkSourceId:i.getSourceIdByLayerId(r.layerId)}),c=new Set;a.forEach(n=>{switch(n.type){case"attachment":case"structure":c.add("attachment");break;case"container":case"content":c.add("containment");break;case"connectivity":c.add("connectivity"),c.add("junction-junction-connectivity"),c.add("junction-edge-from-connectivity"),c.add("junction-edge-midspan-connectivity"),c.add("junction-edge-to-connectivity");break}});let d=await i?.queryAssociations(new Q({elements:[l],types:Array.from(c)}),{signal:t?.signal}),u=new Map,h=new Map;a.forEach(n=>{h.set(n.type,n),u.set(n.type,[])}),d.forEach(n=>{let{toNetworkElement:_,fromNetworkElement:y}=n;switch(n.associationType){case"attachment":if(y?.globalId===s){if(this._shouldDiscardNetworkElement(_,"attachment",h))break;u.get("attachment")?.push(_.globalId),this._attachmentAssociations.add(n)}else{if(this._shouldDiscardNetworkElement(y,"structure",h))break;u.get("structure")?.push(y.globalId),this._structureAssociations.add(n)}break;case"connectivity":case"junction-edge-from-connectivity":case"junction-edge-midspan-connectivity":case"junction-edge-to-connectivity":case"junction-junction-connectivity":if(y?.globalId===s){if(this._shouldDiscardNetworkElement(_,"connectivity",h))break;u.get("connectivity")?.push(_.globalId)}else{if(this._shouldDiscardNetworkElement(y,"connectivity",h))break;u.get("connectivity")?.push(y.globalId)}this._connectivityAssociations.add(n);break;case"containment":if(y?.globalId===s){if(this._shouldDiscardNetworkElement(_,"content",h))break;u.get("content")?.push(_.globalId),this._contentAssociations.add(n)}else{if(this._shouldDiscardNetworkElement(y,"container",h))break;u.get("container")?.push(y.globalId),this._containerAssociations.add(n)}break}});let m=a.map(async n=>{let{associatedNetworkSourceId:_,associatedAssetGroup:y,associatedAssetType:w}=n,b=u.get(n.type),g=y!=null?await this._countAssociatedFeatures(_,b,y,w,t):b.length;switch(n.type){case"attachment":this._attachmentFeatureCount=g;break;case"connectivity":this._connectivityFeatureCount=g;break;case"container":this._containerFeatureCount=g;break;case"content":this._contentFeatureCount=g;break;case"structure":this._structureFeatureCount=g;break}});await Promise.allSettled(m)}async _queryFeatureCount(){await this._loadUtiltyNetworks();let{_queryFeatureCountAbortController:t,_canQuery:e}=this;if(!e){this._featureCount=0;return}await this._queryAssociations(t),this._featureCount=this._attachmentFeatureCount+this._connectivityFeatureCount+this._containerFeatureCount+this._contentFeatureCount+this._structureFeatureCount}async _queryLayer(t,e,s,a,i){let o=this._getFeatureQueryWhereClause(t,e,s,a),r=new B({where:o,outFields:["*"],cacheHint:this._supportsCacheHint}),{features:l}=await N(t,r,i);return l}_parseFeatureObjects(t,e){let s=k();t.forEach(a=>{let i=(a?.feature).sourceLayer;x(s,i,()=>new f).add(a)});for(let[a,i]of s)this._sortFeatureObjectsByTitle(i),e.set(a,i)}_selectAssociationType(t){let{flowItems:e}=this;e&&(this._activeAssociationType=t,this._setUpUtilityNetworkAssociationsViewModels(),this._addAssociationTypeFlowItem(t))}_setUpUtilityNetworkAssociationsViewModels(){this._associationViewModels.forEach((i,o)=>{let r=this._associationFeatures.get(o);r?i.forEach(l=>{r.find(c=>this._matchesGlobalFeature(l,c))||(i.remove(l),i.length||this._associationViewModels.delete(o))}):(i.removeAll(),this._associationViewModels.delete(o))});let{map:t,view:e,spatialReference:s,timeZone:a}=this;this._associationFeatures.forEach((i,o)=>{let r=this._associationViewModels.get(o)||new f;i?.filter(Boolean).forEach((l,c)=>{if(!r.some(d=>this._matchesGlobalFeature(d,l))){let{association:d,feature:u,terminalName:h,title:m}=l;r.add({title:m,association:d,featureViewModel:new G({abilities:{utilityNetworkAssociationsContent:!1},map:t,view:e,spatialReference:s,timeZone:a,graphic:u}),terminalName:h},c)}}),this._associationViewModels.set(o,r)})}_shouldDiscardNetworkElement(t,e,s){if(!t)return!1;let{networkSourceId:a}=t,i=s.get(e)?.associatedNetworkSourceId,o=this._networkSourceIdsInUse.has(a);return i!=null&&i!==a||!o}_sortFeatureObjectsByTitle(t){t.sort(this._compareByFeatureTitle)}render(){let{_state:t}=this;return p`<div class="root"><arcgis-feature-element-info .heading=${this.heading} .headingLevel=${this.headingLevel} .description=${this.description}></arcgis-feature-element-info>${t==="loading"?this._renderLoading():t==="disabled"?this._renderAssociationNotFound():this._renderContent()}</div>`}_renderAssociationNotFound(){return p`<calcite-notice icon=information kind=info open scale=s width=full><div slot=message>${this.messages?.noAssociations}</div></calcite-notice>`}_renderAssociationTypeList(t){return this._getFeatureCountForAssociationType(t.type)>0?this._renderAssociationTypeListItem(t):null}_renderAssociationTypeListItem(t){let e=this._getAssociationTypeTitle(t);return I(`association-type-${t.type}`,p`<calcite-list-item .description=${E(t.description)} .label=${E(e)} .value=${t.type} @calciteListItemSelect=${()=>this._selectAssociationType(t)}><calcite-icon flip-rtl icon=chevron-right scale=s slot=content-end></calcite-icon></calcite-list-item>`)}_renderContent(){let{_state:t,associationTypes:e,messages:s}=this,a=s?.associationsList??s?.noTitle??"";return I("list-container",p`<div class="list-container">${t==="ready"?p`<div><calcite-list display-mode=flat .label=${a}>${e.map(i=>this._renderAssociationTypeList(i))}</calcite-list></div>`:null}${this._renderStickyLoading()}</div>`)}_renderLoading(){return p`<div class="loading-container">${this._renderLoadingIcon()}${this._renderStickyLoading()}</div>`}_renderLoadingIcon(){return p`<calcite-loader inline label></calcite-loader>`}_renderStickyLoading(){return this._state==="querying"?p`<div class="sticky-loading-container">${this._renderLoadingIcon()}</div>`:null}};L("arcgis-feature-utility-network-associations",T);return T},"applications/Components/featureUtils","applications/Components/stringUtils","core/Collection","core/promiseUtils","core/reactiveUtils","core/sql","rest/networks/support/NetworkElement","rest/networks/support/QueryAssociationsParameters","rest/support/Query","popup/Feature",a)