@esri/solutions-components 5.1.0-next.4 → 5.1.0-next.6

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 (162) hide show
  1. package/dist/cdn/{CUTRQOEO.js → 2P34QGRO.js} +1 -1
  2. package/dist/cdn/2RBKFT3Q.js +2 -0
  3. package/dist/cdn/{PH36F6ZU.js → 32VP7W5E.js} +1 -1
  4. package/dist/cdn/{X3LGQLCM.js → 3NR3CDWD.js} +1 -1
  5. package/dist/cdn/{ZJ3KQ7WO.js → 3VJ4LKR5.js} +1 -1
  6. package/dist/cdn/{IHP7FAGO.js → 3YP4IHTR.js} +1 -1
  7. package/dist/cdn/{TG3TGRIK.js → 42KJMFQR.js} +1 -1
  8. package/dist/cdn/{JBAXZW3Z.js → 4ABITSEM.js} +1 -1
  9. package/dist/cdn/{HHTLWYIL.js → 4ZEHQ3GR.js} +1 -1
  10. package/dist/cdn/5326HZ74.js +2 -0
  11. package/dist/cdn/5QCBD6ZZ.js +2 -0
  12. package/dist/cdn/5S3WZLB5.js +2 -0
  13. package/dist/cdn/{IBNSJ46F.js → 5WJS5U7G.js} +1 -1
  14. package/dist/cdn/{NXTK6OD5.js → 6M3LFKC2.js} +1 -1
  15. package/dist/cdn/{QUVVORHW.js → 7MXJCE2J.js} +1 -1
  16. package/dist/cdn/ABTC2V7J.js +2 -0
  17. package/dist/cdn/AVNCYWKK.js +2 -0
  18. package/dist/cdn/{MI7UDIFR.js → B4AIK4OP.js} +1 -1
  19. package/dist/cdn/{DGMH4RW7.js → B4UETHGF.js} +1 -1
  20. package/dist/cdn/{SG6YSE6W.js → B5RWUGHH.js} +1 -1
  21. package/dist/cdn/{6UJUVPK6.js → BDDH5UZP.js} +1 -1
  22. package/dist/cdn/BJMKDP4O.js +2 -0
  23. package/dist/cdn/BMJN3MIR.js +2 -0
  24. package/dist/cdn/{FUEG35TG.js → C4SG4U2R.js} +1 -1
  25. package/dist/cdn/{ZSZUJ3FI.js → C63QDNA2.js} +1 -1
  26. package/dist/cdn/{UCUGZIOM.js → CCENFN7F.js} +1 -1
  27. package/dist/cdn/{2QE2HTYW.js → CTVJXR44.js} +1 -1
  28. package/dist/cdn/{5DGVZVGU.js → CVC5BYCF.js} +1 -1
  29. package/dist/cdn/DWUKLLEC.js +2 -0
  30. package/dist/cdn/{AWE3IT6O.js → DXZ6JQQ3.js} +1 -1
  31. package/dist/cdn/E7HQ4JJ2.js +2 -0
  32. package/dist/cdn/{EOZUCQOO.js → F24FJKDG.js} +1 -1
  33. package/dist/cdn/{TVNF2O66.js → GGPVFOLN.js} +1 -1
  34. package/dist/cdn/HBJZGW4L.js +2 -0
  35. package/dist/cdn/{RJPRLDFE.js → HL7P3CHI.js} +1 -1
  36. package/dist/cdn/HMB3LHBC.js +2 -0
  37. package/dist/cdn/{J3YWJVZZ.js → HPFJPSEL.js} +1 -1
  38. package/dist/cdn/HPQPI754.js +2 -0
  39. package/dist/cdn/I4PUORX4.js +2 -0
  40. package/dist/cdn/JTUQKBFR.js +2 -0
  41. package/dist/cdn/JUXXPW6I.js +2 -0
  42. package/dist/cdn/KD46EE7M.js +2 -0
  43. package/dist/cdn/KJMVCXRW.js +2 -0
  44. package/dist/cdn/KPBEUIQV.js +2 -0
  45. package/dist/cdn/KSXW3QKP.js +2 -0
  46. package/dist/cdn/{HVD4BQPK.js → KXAY6N2R.js} +1 -1
  47. package/dist/cdn/LWUSGNUB.js +2 -0
  48. package/dist/cdn/{7EZXA5FN.js → M3ESEITD.js} +1 -1
  49. package/dist/cdn/{KGALGAAM.js → M3KJFMBN.js} +1 -1
  50. package/dist/cdn/M7YK4K5M.js +2 -0
  51. package/dist/cdn/{RA43PFSB.js → MB5ER7VL.js} +1 -1
  52. package/dist/cdn/{R6SBVSPJ.js → MCFH5JBU.js} +1 -1
  53. package/dist/cdn/MXWRV4QM.js +2 -0
  54. package/dist/cdn/MZ3QZD4K.js +2 -0
  55. package/dist/cdn/MZLEP53S.js +2 -0
  56. package/dist/cdn/N7HJKCUK.js +2 -0
  57. package/dist/cdn/NSITJP7B.js +2 -0
  58. package/dist/cdn/{6734MJXK.js → NYCJKKYN.js} +1 -1
  59. package/dist/cdn/{OKJZS44H.js → OAS6T2VR.js} +1 -1
  60. package/dist/cdn/{7GNQSKAB.js → OEFCWMHM.js} +1 -1
  61. package/dist/cdn/OQFRVQQZ.js +2 -0
  62. package/dist/cdn/{OKDHN6B7.js → P2BP2CM5.js} +1 -1
  63. package/dist/cdn/{XXBU3JMK.js → P4GNCZ6F.js} +1 -1
  64. package/dist/cdn/{Q63OZOAM.js → P642ZIKQ.js} +1 -1
  65. package/dist/cdn/P6IYN2TS.js +2 -0
  66. package/dist/cdn/{QYIFZ7XJ.js → PHWLCAZ4.js} +1 -1
  67. package/dist/cdn/PJ4ERPMV.js +2 -0
  68. package/dist/cdn/PZOAAAVI.js +2 -0
  69. package/dist/cdn/{SB3QR3SO.js → Q2FDKRDQ.js} +1 -1
  70. package/dist/cdn/{ABEE7A5Y.js → QLXOOL5D.js} +1 -1
  71. package/dist/cdn/QWRM254M.js +2 -0
  72. package/dist/cdn/{USRH3VII.js → R4P3ACBL.js} +1 -1
  73. package/dist/cdn/RDXJFHLV.js +2 -0
  74. package/dist/cdn/REOO5ZGK.js +2 -0
  75. package/dist/cdn/{727EUXF6.js → RGH3Z5QC.js} +1 -1
  76. package/dist/cdn/{IUG77ONZ.js → RSZTDUO6.js} +1 -1
  77. package/dist/cdn/{SRDPZ2TN.js → RYD5JSIK.js} +1 -1
  78. package/dist/cdn/{AJJFHJJU.js → SI3DJJCC.js} +1 -1
  79. package/dist/cdn/{SOHNIGAO.js → SLC22JQP.js} +1 -1
  80. package/dist/cdn/{24ADXKSX.js → SOFOUNGU.js} +1 -1
  81. package/dist/cdn/SSO3AN4U.js +2 -0
  82. package/dist/cdn/{CN7QQ3JZ.js → SSWZX5KE.js} +1 -1
  83. package/dist/cdn/{VIOCT3NG.js → T7REUAY2.js} +1 -1
  84. package/dist/cdn/{J3PKNUNP.js → TG5Z36QU.js} +1 -1
  85. package/dist/cdn/TH52564W.js +2 -0
  86. package/dist/cdn/THKPPH7G.js +2 -0
  87. package/dist/cdn/TU5GZK4M.js +2 -0
  88. package/dist/cdn/UFJWRZWQ.js +2 -0
  89. package/dist/cdn/{PALYMJLD.js → UIVSGAJR.js} +1 -1
  90. package/dist/cdn/UUNDSSCA.js +2 -0
  91. package/dist/cdn/{QW3T2SOQ.js → V74VHTFF.js} +1 -1
  92. package/dist/cdn/VPTZV5YV.js +2 -0
  93. package/dist/cdn/{F7OHPN7H.js → VTXVM7WH.js} +1 -1
  94. package/dist/cdn/WCPWYPN2.js +2 -0
  95. package/dist/cdn/{CSQ77SHH.js → XB2BJKRI.js} +1 -1
  96. package/dist/cdn/{AQ3TQ7PO.js → XFB4UFWT.js} +1 -1
  97. package/dist/cdn/XK6Q5TUT.js +2 -0
  98. package/dist/cdn/{VKG5PJNA.js → XQISEL3T.js} +1 -1
  99. package/dist/cdn/{TJ2MW6I4.js → YDNB3Z7B.js} +1 -1
  100. package/dist/cdn/YTK4IGLJ.js +2 -0
  101. package/dist/cdn/ZKQHD6X2.js +2 -0
  102. package/dist/cdn/{73MLGNDP.js → ZPFYLUCJ.js} +1 -1
  103. package/dist/cdn/ZSHMK5VX.js +2 -0
  104. package/dist/cdn/index.js +1 -1
  105. package/dist/chunks/solutions-deploy-app-nav.js +1 -1
  106. package/dist/components/public-notification/customElement.js +3 -3
  107. package/dist/components/solution-details-panel/customElement.js +12 -12
  108. package/dist/components/solution-snapshot-gallery/customElement.js +1 -1
  109. package/dist/components/solutions-all-panel/customElement.js +8 -8
  110. package/dist/components/solutions-all-shell/customElement.js +9 -9
  111. package/dist/components/solutions-deployed-shell/customElement.js +2 -2
  112. package/dist/docs/api.json +1 -1
  113. package/dist/docs/docs.json +1 -1
  114. package/dist/docs/web-types.json +1 -1
  115. package/dist/solutions-components_commit.txt +5 -5
  116. package/package.json +22 -22
  117. package/dist/cdn/25MTK2JD.js +0 -2
  118. package/dist/cdn/2MVCIEAD.js +0 -2
  119. package/dist/cdn/43HJUBM4.js +0 -2
  120. package/dist/cdn/4LVJK3V2.js +0 -2
  121. package/dist/cdn/4X53QTF7.js +0 -2
  122. package/dist/cdn/5YSNBFO6.js +0 -2
  123. package/dist/cdn/6CHHUU33.js +0 -2
  124. package/dist/cdn/7EF56IQP.js +0 -2
  125. package/dist/cdn/ABL7HXUY.js +0 -2
  126. package/dist/cdn/B7XPPNVY.js +0 -2
  127. package/dist/cdn/BB3L2KIS.js +0 -2
  128. package/dist/cdn/BG55H324.js +0 -2
  129. package/dist/cdn/BUR53ZIF.js +0 -2
  130. package/dist/cdn/CHWUORRX.js +0 -2
  131. package/dist/cdn/DHE3GFUJ.js +0 -2
  132. package/dist/cdn/DQNQ7DLH.js +0 -2
  133. package/dist/cdn/DSHJPE6S.js +0 -2
  134. package/dist/cdn/EDWOTP4V.js +0 -2
  135. package/dist/cdn/EYJ255MM.js +0 -2
  136. package/dist/cdn/F7R4EYDS.js +0 -2
  137. package/dist/cdn/FA44RLAZ.js +0 -2
  138. package/dist/cdn/FIWSWJTZ.js +0 -2
  139. package/dist/cdn/GXICL6EL.js +0 -2
  140. package/dist/cdn/HAWNWJLR.js +0 -2
  141. package/dist/cdn/HKAZRCQE.js +0 -2
  142. package/dist/cdn/HYJ7UXOV.js +0 -2
  143. package/dist/cdn/IXSZQTPL.js +0 -2
  144. package/dist/cdn/J74DGHF3.js +0 -2
  145. package/dist/cdn/JY62CMT7.js +0 -2
  146. package/dist/cdn/KWNAM7AD.js +0 -2
  147. package/dist/cdn/LNZEGAPP.js +0 -2
  148. package/dist/cdn/LW4KR4D5.js +0 -2
  149. package/dist/cdn/M7ERGA4I.js +0 -2
  150. package/dist/cdn/MTDE4K26.js +0 -2
  151. package/dist/cdn/NDSUZD6T.js +0 -2
  152. package/dist/cdn/NF3TLIP3.js +0 -2
  153. package/dist/cdn/O44OLIT5.js +0 -2
  154. package/dist/cdn/R4OPQN6O.js +0 -2
  155. package/dist/cdn/R5PY2TMY.js +0 -2
  156. package/dist/cdn/RXLJOKCX.js +0 -2
  157. package/dist/cdn/S27I4OM5.js +0 -2
  158. package/dist/cdn/SJQW6ZDF.js +0 -2
  159. package/dist/cdn/VOM7CM3O.js +0 -2
  160. package/dist/cdn/VUQ25YDH.js +0 -2
  161. package/dist/cdn/WYV4MD77.js +0 -2
  162. package/dist/cdn/X4Y4DHJ5.js +0 -2
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as v}from"./SOHNIGAO.js";import{b as u}from"./7EF56IQP.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{F as m,G as d,H as h,J as o,h as l,i as n,r,u as p}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";var T=l`@layer{.instant-apps-measurement-panel{width:300px}.instant-apps-measurement-panel calcite-action-bar{--calcite-action-bar-items-space: 1.5em}.instant-apps-measurement-panel .esri-coordinate-conversion__conversions-view,.instant-apps-measurement-panel .esri-coordinate-conversion{max-width:300px}}`,$={content:"instant-apps-measurement__content"},c=class extends h{constructor(){super(...arguments),this._messages=v({name:"instant-apps-measurement",blocking:!0}),this.measureTool=m(),this.showHeading=!0,this.closable=!1,this.measureActive=r()}static{this.properties={view:0,areaUnit:1,linearUnit:1,coordinateFormat:1,showHeading:5,activeToolType:1,closable:5}}static{this.styles=T}static{this.shadowRootOptions=p}_handleToolClick(e){if(!this?.measureTool)return;let a=e?.target;if(!(a instanceof HTMLElement))return;let t=a?.dataset.value;if(t!=="distance"&&t!=="area"&&t!=="point"&&t!=="clear")return;t&&this.measureTool.value&&(this.measureTool.value.activeTool=t);let s=document.getElementsByClassName("active-tool");for(let i=0;i<s?.length;i++)s[i]?.classList?.remove("active-tool");a?.classList.add("active-tool"),this.measureActive.emit(!(t===void 0||t==="clear"))}render(){return n`<calcite-panel class="instant-apps-measurement-panel" .heading=${this.showHeading?this._messages.label:void 0} .closable=${this.closable}>${this.renderActionBar()}${this.renderMeasureToolPanel()}</calcite-panel>`}renderMeasureToolPanel(){let{view:e,coordinateFormat:a,areaUnit:t,linearUnit:s,activeToolType:i}=this;return n`<calcite-panel class=${o($.content)}><instant-apps-measurement-tool .view=${e} .measureConfiguration=${{coordinateFormat:a,areaUnit:t,linearUnit:s,activeToolType:i}} .activeTool=${this.activeToolType} ${d(this.measureTool)}></instant-apps-measurement-tool></calcite-panel>`}renderActionBar(){let{_messages:e,activeToolType:a}=this;return n`<calcite-action-bar expand-disabled selection-appearance=highlight slot=action-bar><calcite-action class=${o(a==="distance"?"active-tool":"")} .text=${e.line} scale=m icon=measure data-value=distance @click=${this._handleToolClick} id=distanceTool><calcite-tooltip reference-element=distanceTool overlay-positioning=fixed close-on-click placement=top>${e.line}</calcite-tooltip></calcite-action><calcite-action class=${o(a==="area"?"active-tool":"")} .text=${e.area} icon=measure-area scale=m data-value=area @click=${this._handleToolClick} id=areaTool><calcite-tooltip reference-element=areaTool overlay-positioning=fixed close-on-click placement=top>${e.area}</calcite-tooltip></calcite-action><calcite-action class=${o(a==="point"?"active-tool":"")} .text=${e.point} scale=m icon=pin-plus data-value=point @click=${this._handleToolClick} id=pointTool><calcite-tooltip reference-element=pointTool overlay-positioning=fixed close-on-click placement=top>${e.point}</calcite-tooltip></calcite-action><calcite-action .text=${e.clear} scale=m icon=trash data-value=clear @click=${this._handleToolClick} id=trashTool><calcite-tooltip reference-element=trashTool overlay-positioning=fixed close-on-click placement=top>${e.clear}</calcite-tooltip></calcite-action></calcite-action-bar>`}};u("instant-apps-measurement",c);export{c as InstantAppsMeasurement};
2
+ import{a as v}from"./SLC22JQP.js";import{b as u}from"./JTUQKBFR.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{F as m,G as d,H as h,J as o,h as l,i as n,r,u as p}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";var T=l`@layer{.instant-apps-measurement-panel{width:300px}.instant-apps-measurement-panel calcite-action-bar{--calcite-action-bar-items-space: 1.5em}.instant-apps-measurement-panel .esri-coordinate-conversion__conversions-view,.instant-apps-measurement-panel .esri-coordinate-conversion{max-width:300px}}`,$={content:"instant-apps-measurement__content"},c=class extends h{constructor(){super(...arguments),this._messages=v({name:"instant-apps-measurement",blocking:!0}),this.measureTool=m(),this.showHeading=!0,this.closable=!1,this.measureActive=r()}static{this.properties={view:0,areaUnit:1,linearUnit:1,coordinateFormat:1,showHeading:5,activeToolType:1,closable:5}}static{this.styles=T}static{this.shadowRootOptions=p}_handleToolClick(e){if(!this?.measureTool)return;let a=e?.target;if(!(a instanceof HTMLElement))return;let t=a?.dataset.value;if(t!=="distance"&&t!=="area"&&t!=="point"&&t!=="clear")return;t&&this.measureTool.value&&(this.measureTool.value.activeTool=t);let s=document.getElementsByClassName("active-tool");for(let i=0;i<s?.length;i++)s[i]?.classList?.remove("active-tool");a?.classList.add("active-tool"),this.measureActive.emit(!(t===void 0||t==="clear"))}render(){return n`<calcite-panel class="instant-apps-measurement-panel" .heading=${this.showHeading?this._messages.label:void 0} .closable=${this.closable}>${this.renderActionBar()}${this.renderMeasureToolPanel()}</calcite-panel>`}renderMeasureToolPanel(){let{view:e,coordinateFormat:a,areaUnit:t,linearUnit:s,activeToolType:i}=this;return n`<calcite-panel class=${o($.content)}><instant-apps-measurement-tool .view=${e} .measureConfiguration=${{coordinateFormat:a,areaUnit:t,linearUnit:s,activeToolType:i}} .activeTool=${this.activeToolType} ${d(this.measureTool)}></instant-apps-measurement-tool></calcite-panel>`}renderActionBar(){let{_messages:e,activeToolType:a}=this;return n`<calcite-action-bar expand-disabled selection-appearance=highlight slot=action-bar><calcite-action class=${o(a==="distance"?"active-tool":"")} .text=${e.line} scale=m icon=measure data-value=distance @click=${this._handleToolClick} id=distanceTool><calcite-tooltip reference-element=distanceTool overlay-positioning=fixed close-on-click placement=top>${e.line}</calcite-tooltip></calcite-action><calcite-action class=${o(a==="area"?"active-tool":"")} .text=${e.area} icon=measure-area scale=m data-value=area @click=${this._handleToolClick} id=areaTool><calcite-tooltip reference-element=areaTool overlay-positioning=fixed close-on-click placement=top>${e.area}</calcite-tooltip></calcite-action><calcite-action class=${o(a==="point"?"active-tool":"")} .text=${e.point} scale=m icon=pin-plus data-value=point @click=${this._handleToolClick} id=pointTool><calcite-tooltip reference-element=pointTool overlay-positioning=fixed close-on-click placement=top>${e.point}</calcite-tooltip></calcite-action><calcite-action .text=${e.clear} scale=m icon=trash data-value=clear @click=${this._handleToolClick} id=trashTool><calcite-tooltip reference-element=trashTool overlay-positioning=fixed close-on-click placement=top>${e.clear}</calcite-tooltip></calcite-action></calcite-action-bar>`}};u("instant-apps-measurement",c);export{c as InstantAppsMeasurement};
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
+ import"./QPIMTXPL.js";var e="Teil pole selle toimingu tegemiseks piisavalt krediiti. Abi saamiseks p\xF6\xF6rduge ArcGIS-i s\xFCsteemiadministraatori poole.",a="See t\xF6\xF6riist avaldati m\xE4rkmikust. Juurdep\xE4\xE4s ArcGIS m\xE4rkmikele on teie organisatsiooni jaoks blokeeritud. Seadete kohandamiseks v\xF5tke \xFChendust oma administraatoriga.",i="Muutujal ${ dataPath } ei tohi olla: ${ additionalProperty }.",t="${ dataPath } peab vastama \xFChele nendest skeemidest: ${ schemaOptions }.",s="Proovige kaarti uuesti salvestada.",r="Krediidi hindamine nurjus. Liikuge kerides alla, parandage vead ja hinnake krediiti uuesti.",o="Anal\xFC\xFCsi k\xE4itamisel ilmnes t\xF5rge.",l="${ dataPath } peab v\xF5rduma \xFChega allpool nimetatud v\xE4\xE4rtustest: ${ allowedValues }.",u="Anal\xFC\xFCsiajaloo salvestamine nurjus",n="Ajaloo talletusruum on t\xE4is. Eemaldage anal\xFC\xFCsiajaloost m\xF5ned sisu\xFCksused ja proovige uuesti salvestada.",d="Teenuse nimi sisaldab v\xE4hemalt \xFChte sobimatut t\xE4hem\xE4rki.",m="Ajutise kihi salvestamine majutatud objektikihina ei j\xF5udnud l\xF5pule.",k="Selle t\xF6\xF6riista kasutamiseks on vaja j\xE4rgmisi \xF5igusi: ${ privileges }. <calcite-link href='${docLink}' target='_blank'>Lisateave</calcite-link>",h="V\xF5tmeatribuutide toomine nurjus.",c="Kihi laadimine nurjus",v="Kiht pole saadaval.",p="Muutujal ${ dataPath } ei tohi olla rohkem kui ${ limit } \xFCksust.",g="Mudeli salvestamisel ilmnes t\xF5rge. Proovige uuesti salvestada.",j="Muutujal ${ dataPath } ei tohi olla v\xE4hem kui ${ limit } \xFCksust.",E="${ dataPath } ei tohi olla l\xFChem kui ${ limit } m\xE4rki.",P="Mudeli \xFCksuse laadimine nurjus. Veenduge, et mudel oleks olemas ja juurdep\xE4\xE4suluba oleks antud.",b="Taotluse t\xE4itmine nurjus.",S="Teil puudub selle t\xF6\xF6riista kasutamise \xF5igus. <calcite-link target='_blank' href='${ docLink }'>Lisateave</calcite-link>",y="Portaali sisselogimine nurjus.",f="Sisendandmete lugemine nurjus.",$="Omadusel ${ dataPath } puudub omadus nimega ${ missingProperty }.",T="Selle nimega tulemkiht on juba olemas. Tulemkihtide nimed peavad kogu organisatsioonis olema kordumatud. Kasutage m\xF5nda muud nime.",L="V\xE4ljundi nimes on \xFCks v\xF5i mitu lubamatut m\xE4rki. <calcite-link href='${docLink}' target='_blank'>Lisateave</calcite-link>",F="Ajutise kihi avaldamine majutatud kihina nurjus v\xE4hemalt \xFChe sobimatu v\xE4lja t\xF5ttu. K\xE4ivitage t\xF6\xF6riist uuesti, et luua sobivate v\xE4ljadega kiht.",I="T\xF6\xF6 edastamine nurjus. Liikuge kerides alla, parandage vead ja k\xE4ivitage anal\xFC\xFCs uuesti.",A="${ dataPath } peab sisaldama v\xE4hemalt \xFChte m\xE4rki, mis pole t\xFChim\xE4rk.",V={InsufficientCreditsError:e,accessBlocked:a,additionalProperty:i,anyOfValues:t,cannotWriteToItemResource:s,creditEstimationError:r,defaultError:o,enumValues:l,failedToSaveHistory:u,fullSessionStorage:n,hostedFeatureServiceInvalidTitle:d,hostedFeatureServicePublishDidNotComplete:m,insufficientPermissions:k,keyPropertiesError:h,layerLoadFailure:c,layerUnavailable:v,maxItems:p,mbFailedToSave:g,minItems:j,minLength:E,modelNotFound:P,networkError:b,noPermissionToAccessTool:S,portalLoadError:y,queryFeaturesError:f,requiredProperty:$,serviceNameExistsError:T,specialCharactersInServiceNameError:L,temporaryLayerFieldsError:F,toolValidationError:I,whiteSpacePattern:A};export{e as InsufficientCreditsError,a as accessBlocked,i as additionalProperty,t as anyOfValues,s as cannotWriteToItemResource,r as creditEstimationError,V as default,o as defaultError,l as enumValues,u as failedToSaveHistory,n as fullSessionStorage,d as hostedFeatureServiceInvalidTitle,m as hostedFeatureServicePublishDidNotComplete,k as insufficientPermissions,h as keyPropertiesError,c as layerLoadFailure,v as layerUnavailable,p as maxItems,g as mbFailedToSave,j as minItems,E as minLength,P as modelNotFound,b as networkError,S as noPermissionToAccessTool,y as portalLoadError,f as queryFeaturesError,$ as requiredProperty,T as serviceNameExistsError,L as specialCharactersInServiceNameError,F as temporaryLayerFieldsError,I as toolValidationError,A as whiteSpacePattern};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as _}from"./SOHNIGAO.js";import{b as m}from"./7EF56IQP.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{F as h,G as u,H as g,J as r,h as d,i as s}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";var c=class{constructor(){this.pages=[],this.headerText="",this.pages=[]}setPages(e){this.pages=e,this.setDefaultHeaderText()}setDefaultHeaderText(){this.headerText=this.pages.length?this.pages[0].title:""}},f=d`:host{--instant-apps-app-guide-width: 300px;--instant-apps-app-guide-height: 400px;--instant-apps-app-guide-list-item-bubble-size: 22px;width:var(--instant-apps-app-guide-width);height:var(--instant-apps-app-guide-height);display:block}:host calcite-panel{max-width:var(--instant-apps-app-guide-width);max-height:var(--instant-apps-app-guide-height);display:flex}:host calcite-carousel{flex:1;height:fit-content;background-color:var(--calcite-color-foreground-1);overflow:auto}:host [slot=header-content]{display:flex;gap:var(--calcite-spacing-sm);padding-inline-start:.25rem;font-weight:var(--calcite-font-weight-bold)}:host calcite-carousel-item{flex-grow:1;display:flex;flex-direction:column}:host .instant-apps-app-guide__content-wrapper{padding-block-start:.5rem;padding-inline:.5rem;flex-shrink:1;flex-grow:0}:host calcite-icon{--calcite-icon-color: var(--calcite-color-brand)}:host .instant-apps-app-guide__content-list{counter-set:item-counter;margin-inline:0;padding-inline-start:var(--calcite-spacing-xxxl);padding-inline-end:var(--calcite-spacing-lg);position:relative}:host .instant-apps-app-guide__content-list .instant-apps-app-guide__content-list--item{counter-increment:item-counter;margin-block-start:var(--calcite-spacing-lg);display:flex;align-items:flex-start}:host .instant-apps-app-guide__content-list .instant-apps-app-guide__content-list--item:before{content:counter(item-counter);background-color:var(--calcite-color-text-2);color:var(--calcite-color-text-inverse);line-height:var(--calcite-font-line-height-fixed-xl);width:var(--instant-apps-app-guide-list-item-bubble-size);left:0;border-radius:var(--calcite-corner-radius-pill);display:flex;justify-content:center;font-size:var(--calcite-font-size-sm);position:absolute;max-height:var(--instant-apps-app-guide-list-item-bubble-size)}:host .instant-apps-app-guide__content-list .instant-apps-app-guide__content-list--item::marker{color:var(--calcite-color-transparent)}`,l={contentList:"instant-apps-app-guide__content-list",contentListItem:"instant-apps-app-guide__content-list--item",contentWrapper:"instant-apps-app-guide__content-wrapper"},o=class extends g{constructor(){super(...arguments),this._messages=_({name:"instant-apps-app-guide"}),this._viewModel=new c,this._carouselRef=h(),this.header=!0}static{this.properties={headerText:16,header:5,data:0}}static{this.styles=f}load(){this._setContent(this.data)}willUpdate(e){e.has("data")&&this._setContent(this.data),e.has("headerText")&&(this._viewModel.headerText=this.headerText)}_setContent(e){this._viewModel.setPages(e),this.headerText=this._viewModel.headerText}_updateHeaderText(){let{_viewModel:e,_carouselRef:{value:t},_messages:a}=this;if(!(e&&t))return;let i=Array.from(t.children).indexOf(t.selectedItem),n=e?.pages,p=n?.[i]??n[0];this.headerText=p?.title||a.headerText}_getArrowType(){return this._viewModel.pages.length>2?"inline":"none"}render(){let e=this._renderAppGuidePages(this._viewModel.pages),t=this._renderAppGuideHeader();return s`<calcite-panel scale=s>${t}<calcite-carousel label="App Guide" @calciteCarouselChange=${()=>this._updateHeaderText()} .arrowType=${this._getArrowType()} ${u(this._carouselRef)}>${e}</calcite-carousel></calcite-panel>`}_renderAppGuideHeader(){let{_messages:e,header:t,headerText:a}=this,i=!!t&&e.headerText,n=a||e.headerText;return i?s`<span slot=header-content>${n} <calcite-icon icon=lightbulb scale=s></calcite-icon></span>`:null}_renderAppGuidePages(e){return e.map((t,a)=>{let{content:i,type:n,title:p}=t;return s`<calcite-carousel-item .label=${p}><div class=${r(l.contentWrapper)}>${this._renderContentItems(i,n)}</div></calcite-carousel-item>`})}_renderContentItems(e,t){switch(t){case"list":return s`<ol class=${r(l.contentList)}>${e.map((a,i)=>s`<li class=${r(l.contentListItem)}>${a}</li>`)}</ol>`;case"paragraphs":default:return e.map((a,i)=>s`<p>${a}</p>`)}}};m("instant-apps-app-guide",o);export{o as InstantAppsAppGuide};
2
+ import{a as _}from"./SLC22JQP.js";import{b as m}from"./JTUQKBFR.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{F as h,G as u,H as g,J as r,h as d,i as s}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";var c=class{constructor(){this.pages=[],this.headerText="",this.pages=[]}setPages(e){this.pages=e,this.setDefaultHeaderText()}setDefaultHeaderText(){this.headerText=this.pages.length?this.pages[0].title:""}},f=d`:host{--instant-apps-app-guide-width: 300px;--instant-apps-app-guide-height: 400px;--instant-apps-app-guide-list-item-bubble-size: 22px;width:var(--instant-apps-app-guide-width);height:var(--instant-apps-app-guide-height);display:block}:host calcite-panel{max-width:var(--instant-apps-app-guide-width);max-height:var(--instant-apps-app-guide-height);display:flex}:host calcite-carousel{flex:1;height:fit-content;background-color:var(--calcite-color-foreground-1);overflow:auto}:host [slot=header-content]{display:flex;gap:var(--calcite-spacing-sm);padding-inline-start:.25rem;font-weight:var(--calcite-font-weight-bold)}:host calcite-carousel-item{flex-grow:1;display:flex;flex-direction:column}:host .instant-apps-app-guide__content-wrapper{padding-block-start:.5rem;padding-inline:.5rem;flex-shrink:1;flex-grow:0}:host calcite-icon{--calcite-icon-color: var(--calcite-color-brand)}:host .instant-apps-app-guide__content-list{counter-set:item-counter;margin-inline:0;padding-inline-start:var(--calcite-spacing-xxxl);padding-inline-end:var(--calcite-spacing-lg);position:relative}:host .instant-apps-app-guide__content-list .instant-apps-app-guide__content-list--item{counter-increment:item-counter;margin-block-start:var(--calcite-spacing-lg);display:flex;align-items:flex-start}:host .instant-apps-app-guide__content-list .instant-apps-app-guide__content-list--item:before{content:counter(item-counter);background-color:var(--calcite-color-text-2);color:var(--calcite-color-text-inverse);line-height:var(--calcite-font-line-height-fixed-xl);width:var(--instant-apps-app-guide-list-item-bubble-size);left:0;border-radius:var(--calcite-corner-radius-pill);display:flex;justify-content:center;font-size:var(--calcite-font-size-sm);position:absolute;max-height:var(--instant-apps-app-guide-list-item-bubble-size)}:host .instant-apps-app-guide__content-list .instant-apps-app-guide__content-list--item::marker{color:var(--calcite-color-transparent)}`,l={contentList:"instant-apps-app-guide__content-list",contentListItem:"instant-apps-app-guide__content-list--item",contentWrapper:"instant-apps-app-guide__content-wrapper"},o=class extends g{constructor(){super(...arguments),this._messages=_({name:"instant-apps-app-guide"}),this._viewModel=new c,this._carouselRef=h(),this.header=!0}static{this.properties={headerText:16,header:5,data:0}}static{this.styles=f}load(){this._setContent(this.data)}willUpdate(e){e.has("data")&&this._setContent(this.data),e.has("headerText")&&(this._viewModel.headerText=this.headerText)}_setContent(e){this._viewModel.setPages(e),this.headerText=this._viewModel.headerText}_updateHeaderText(){let{_viewModel:e,_carouselRef:{value:t},_messages:a}=this;if(!(e&&t))return;let i=Array.from(t.children).indexOf(t.selectedItem),n=e?.pages,p=n?.[i]??n[0];this.headerText=p?.title||a.headerText}_getArrowType(){return this._viewModel.pages.length>2?"inline":"none"}render(){let e=this._renderAppGuidePages(this._viewModel.pages),t=this._renderAppGuideHeader();return s`<calcite-panel scale=s>${t}<calcite-carousel label="App Guide" @calciteCarouselChange=${()=>this._updateHeaderText()} .arrowType=${this._getArrowType()} ${u(this._carouselRef)}>${e}</calcite-carousel></calcite-panel>`}_renderAppGuideHeader(){let{_messages:e,header:t,headerText:a}=this,i=!!t&&e.headerText,n=a||e.headerText;return i?s`<span slot=header-content>${n} <calcite-icon icon=lightbulb scale=s></calcite-icon></span>`:null}_renderAppGuidePages(e){return e.map((t,a)=>{let{content:i,type:n,title:p}=t;return s`<calcite-carousel-item .label=${p}><div class=${r(l.contentWrapper)}>${this._renderContentItems(i,n)}</div></calcite-carousel-item>`})}_renderContentItems(e,t){switch(t){case"list":return s`<ol class=${r(l.contentList)}>${e.map((a,i)=>s`<li class=${r(l.contentListItem)}>${a}</li>`)}</ol>`;case"paragraphs":default:return e.map((a,i)=>s`<p>${a}</p>`)}}};m("instant-apps-app-guide",o);export{o as InstantAppsAppGuide};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{b as r}from"./7EF56IQP.js";import{H as i,h as a,i as p}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";export default $arcgis.t(([l])=>{var d=a`:host{display:block}`,m="floating",h="instant-apps-control-panel",x="border-bottom: 1px solid var(--calcite-color-border-3)",s=class extends i{constructor(){super(...arguments),this.components=[]}static{this.properties={components:0,view:0}}static{this.styles=d}async load(){await this._handleComponents()}async _handleComponents(){let t=this._getComponentsNode();t&&(this._resetUI(t),this._attachComponents(t))}_attachComponents(t){this.components.forEach(this._attachmentComponent(t))}_attachmentComponent(t){return(o,e)=>{let n=o.content;o.isExpand&&(n=this._getExpand(o),o.expandIcon&&(n.expandIcon=o.expandIcon),o.collapseTooltip&&(n.collapseTooltip=o.collapseTooltip),o.expandTooltip&&(n.expandTooltip=o.expandTooltip)),n.container||(n.container=document.createElement("div")),t?.appendChild(n.container),e!==this.components.length-1&&(n.container.style=x)}}_getExpand(t){let{view:o}=this,{content:e,focusTrapDisabled:n}=t,c=t?.expanded??!1;return new l({content:e,view:o,expanded:c,mode:m,group:h,focusTrapDisabled:!!n})}_getComponentsNode(){return this.el.querySelector('[slot="components"]')}_resetUI(t){if(t.children.length>0)for(;t.firstChild;)t.removeChild(t.firstChild)}render(){return p`<slot name=components></slot>`}};r("instant-apps-control-panel",s);return s},"widgets/Expand")
2
+ import{b as r}from"./JTUQKBFR.js";import{H as i,h as a,i as p}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";export default $arcgis.t(([l])=>{var d=a`:host{display:block}`,m="floating",h="instant-apps-control-panel",x="border-bottom: 1px solid var(--calcite-color-border-3)",s=class extends i{constructor(){super(...arguments),this.components=[]}static{this.properties={components:0,view:0}}static{this.styles=d}async load(){await this._handleComponents()}async _handleComponents(){let t=this._getComponentsNode();t&&(this._resetUI(t),this._attachComponents(t))}_attachComponents(t){this.components.forEach(this._attachmentComponent(t))}_attachmentComponent(t){return(o,e)=>{let n=o.content;o.isExpand&&(n=this._getExpand(o),o.expandIcon&&(n.expandIcon=o.expandIcon),o.collapseTooltip&&(n.collapseTooltip=o.collapseTooltip),o.expandTooltip&&(n.expandTooltip=o.expandTooltip)),n.container||(n.container=document.createElement("div")),t?.appendChild(n.container),e!==this.components.length-1&&(n.container.style=x)}}_getExpand(t){let{view:o}=this,{content:e,focusTrapDisabled:n}=t,c=t?.expanded??!1;return new l({content:e,view:o,expanded:c,mode:m,group:h,focusTrapDisabled:!!n})}_getComponentsNode(){return this.el.querySelector('[slot="components"]')}_resetUI(t){if(t.children.length>0)for(;t.firstChild;)t.removeChild(t.firstChild)}render(){return p`<slot name=components></slot>`}};r("instant-apps-control-panel",s);return s},"widgets/Expand")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{b as i}from"./7EF56IQP.js";import{H as s,h as l,i as t}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";var u=l`:host{display:block}`,a=class extends s{constructor(){super(...arguments),this.disabled=!1}static{this.properties={selectedValue:3,disabled:7,labels:0}}static{this.styles=u}get _radioButtonData(){return[{label:this.labels.selectFeature,value:"select-feature"},{label:this.labels.drawGraphic,value:"draw-graphic"},{label:this.labels.searchLocation,value:"search-location"}]}render(){let r=this.labels.title,o=this.labels.groupName;return t`<calcite-label>${r}</calcite-label><calcite-radio-button-group .name=${o} .disabled=${this.disabled} layout=vertical>${this._radioButtonData.map(({label:c,value:e})=>t`<calcite-radio-button .value=${e} .labelText=${c} .checked=${this.selectedValue===e}></calcite-radio-button>`)}</calcite-radio-button-group>`}};i("instant-apps-buffer-input-radiogroup",a);export{a as InstantAppsBufferInputRadiogroup};
2
+ import{b as i}from"./JTUQKBFR.js";import{H as s,h as l,i as t}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";var u=l`:host{display:block}`,a=class extends s{constructor(){super(...arguments),this.disabled=!1}static{this.properties={selectedValue:3,disabled:7,labels:0}}static{this.styles=u}get _radioButtonData(){return[{label:this.labels.selectFeature,value:"select-feature"},{label:this.labels.drawGraphic,value:"draw-graphic"},{label:this.labels.searchLocation,value:"search-location"}]}render(){let r=this.labels.title,o=this.labels.groupName;return t`<calcite-label>${r}</calcite-label><calcite-radio-button-group .name=${o} .disabled=${this.disabled} layout=vertical>${this._radioButtonData.map(({label:c,value:e})=>t`<calcite-radio-button .value=${e} .labelText=${c} .checked=${this.selectedValue===e}></calcite-radio-button>`)}</calcite-radio-button-group>`}};i("instant-apps-buffer-input-radiogroup",a);export{a as InstantAppsBufferInputRadiogroup};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import e from"./HIMUNCZ6.js";import{a as H}from"./VKG5PJNA.js";import d from"./3R5VOUDP.js";import c from"./CEP54NLT.js";import a from"./YVNP437O.js";import{a as S}from"./3AQ7U2PF.js";import{b as E}from"./NDUAEC62.js";import{F as f,G as g,H as x,J as b,h as v,i as o,l as _,r as p,u as T}from"./P4KZ6OZF.js";export default $arcgis.t(([L,c,M,w,{c:O},{c:C,d:A,j:y},{C:m,o:F},{b:$}])=>{var R=v`@layer{:host{display:block}.height-full{height:100%}.height-full-adjusted{height:calc(100% - 20px)}.width-full{width:100%}.display-flex{display:flex}.display-none{display:none}.table-border{border:1px solid var(--calcite-color-border-2)}.border-end{border-inline-end:1px solid var(--calcite-color-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51-px{height:51px}.height-50-px{height:50px}.bottom-left{position:absolute;left:0;bottom:0;padding-left:5px}html[dir=rtl] .bottom-left{position:absolute;right:0;bottom:0;padding-right:5px}.height-19{height:19px}.background{background-color:var(--calcite-color-background)}.text-color{color:var(--calcite-color-text-1)}.align-center{align-items:center}.danger-color{color:var(--calcite-color-status-danger)}.esri-feature-table vaadin-grid{border:none!important}vaadin-grid-cell-content{font-size:14px!important;color:var(--calcite-color-text-3)!important}.absolute-right{position:absolute;right:0;left:unset}html[dir=rtl] .absolute-right{left:0;right:unset}.disabled{cursor:default!important;user-select:none;opacity:var(--calcite-opacity-disabled);pointer-events:none}.actions-end{height:50px!important;display:inline-flex}.border-top{border-top:1px solid var(--calcite-color-border-2)}.modal{--calcite-dialog-content-space: 0}.esri-feature-table__table-container{height:100%}.search-container{background-color:var(--calcite-color-foreground-1)!important}.search{--calcite-color-border-input: var(--calcite-color-border-3);width:60%;padding:10px}.delete-red{--calcite-icon-color: var(--calcite-color-status-danger);--calcite-color-text-1: var(--calcite-color-status-danger);--calcite-color-text-3: var(--calcite-color-status-danger)}.label-override{white-space:nowrap}.padding-start-1-4{padding-inline-start:.5rem}.panel-header-override{--calcite-panel-header-content-space: 0px}.danger-label-color{color:var(--calcite-color-status-danger)}.danger-icon-color{--calcite-icon-color: var(--calcite-color-status-danger)}.width-51{width:51px}.height-51{height:51px}calcite-action-bar{--calcite-internal-action-bar-gap: 0px;--calcite-internal-action-bar-padding: 0px}}`,I=class extends x{constructor(){super(),this.defaultGlobalId=[],this.defaultLayerId="",this.defaultOid=[],this.enableAutoRefresh=!1,this.enableColumnReorder=!0,this.enableCSV=!1,this.enableInlineEdit=!1,this.enableShare=!1,this.enableTableAutosave=!0,this.featureSelectionMode="multiple",this.selectedRelatedIds=[],this.honorMapFieldSettings=!1,this.isMobile=!1,this.mapHidden=!1,this.showOnlyUpdatableLayers=!1,this.selectedIds=[],this.shareIncludeEmbed=!1,this.shareIncludeSocial=!1,this.showNewestFirst=!1,this.zoomAndScrollToSelected=!1,this._allIds=[],this._configLayerOrderDefined=!1,this._csvExporting=!1,this._fetchingData=!1,this._hideTable=!1,this._filterActive=!1,this._selectAllActive=!1,this._showHideOpen=!1,this._showOnlySelected=!1,this._toolInfos=[],this._translations=S({name:"layer-table",blocking:!0}),this._fullTextSearchInfo=[],this._searchPlaceHolder="",this._size=0,this._queryingData=!1,this._editEnabled=!1,this._enabledLayerIds=[],this._defaultGlobalIdHonored=!1,this._defaultOidHonored=!1,this._deleteEnabled=!1,this._floorExpression="",this._floorField="",this._floorLevel="",this._loaded=!1,this._shareNode=f(),this._toolbar=f(),this._searchExpression="",this._skipEditCheck=!1,this._tempSelectedIds=[],this._outOFExtentOids=[],this._shouldUpdateTableOnExtentChange=!0,this._creatingFeature=!1,this._searchNode=f(),this.columnReorder=p(),this.featureSelectionChange=p(),this.toggleFilter=p(),this.showDelete=p(),this.relatedRecordToggled=p(),this.editMultipleFeatures=p(),this.listenOn(window,"beforeMapInfoChange",this.beforeMapInfoChange,{capture:!0}),this.listenOn(window,"editorInitialized",this.editorInitialized),this.listenOn(window,"closeEdit",this.closeEdit),this.listenOn(window,"selectionChanged",this.selectionChanged),this.listenOn(window,"beforeLayerSelectionChange",this.beforeLayerSelectionChange),this.listenOn(window,"layerSelectionChange",this.layerSelectionChange),this.listenOn(window,"editsComplete",this.editsComplete),this.listenOn(window,"facilityChanged",this.facilityChanged),this.listenOn(window,"levelChanged",this.levelChanged),this.listenOn(window,"siteChanged",this.siteChanged),this.listenOn(window,"noLayersFound",this.noLayersFound),this.listenOn(window,"clearSelection",this.clearSelection),this.listenOn(window,"mapChanged",this.mapChanged),this.listenOn(window,"featuresSelected",this.featuresSelected),this.listenOn(window,"createWorkFlowStarted",this.createWorkFlowStarted),this.listenOn(window,"backFromCreateWorkFlow",this.backFromCreateWorkFlow),H(window)}static{this.properties={appLayout:1,defaultGlobalId:0,defaultLayerId:1,defaultOid:0,enableAutoRefresh:5,enableColumnReorder:5,enableCSV:5,enableInlineEdit:5,enableShare:5,enableTableAutosave:5,featureSelectionMode:1,selectedRelatedIds:0,honorMapFieldSettings:5,isMobile:5,mapHidden:5,mapInfo:0,mapView:0,showOnlyUpdatableLayers:5,selectedIds:0,shareIncludeEmbed:5,shareIncludeSocial:5,showNewestFirst:5,zoomAndScrollToSelected:5,zoomToScale:9,_allIds:16,_configLayerOrderDefined:16,_csvExporting:16,_fetchingData:16,_hideTable:16,_filterActive:16,_layer:16,_selectAllActive:16,_showHideOpen:16,_showOnlySelected:16,_toolInfos:16,_translations:16,_fullTextSearchInfo:16,_searchPlaceHolder:16,_size:16,_queryingData:16}}static{this.styles=R}static{this.shadowRootOptions=T}willUpdate(e){if(e.has("appLayout")&&this.appLayoutWatchHandler(),e.has("defaultOid")&&this.defaultOidWatchHandler(),e.has("defaultGlobalId")&&this.defaultGlobalIdWatchHandler(),e.has("enableCSV")&&this.enableCSVWatchHandler(),e.has("enableInlineEdit")&&this.enableInlineEditWatchHandler(),e.has("mapHidden")&&this.mapHiddenWatchHandler(),e.has("isMobile")&&this.isMobileWatchHandler(),e.has("mapInfo")&&this.mapInfoWatchHandler(),e.has("mapView")&&this.mapViewWatchHandler(),e.has("_layer")&&this._layerWatchHandler(),e.has("selectedIds")&&(this.hasUpdated||JSON.stringify(e.get("selectedIds"))!==JSON.stringify(this.selectedIds))&&this.selectedIdsWatchHandler(),e.has("selectedRelatedIds")&&(this.hasUpdated||JSON.stringify(e.get("selectedRelatedIds"))!==JSON.stringify(this.selectedRelatedIds))&&this.selectedRelatedIdsWatchHandler(),e.has("enableTableAutosave")&&this.hasUpdated&&this._table&&(this._table.autoSaveEnabled=this.enableTableAutosave),e.has("_translations")){let t=this._translations._lang,i=e.get("_translations")?._lang;t&&i&&t!==i&&this._initToolInfos()}}async appLayoutWatchHandler(){await this._initToolInfos(),this._updateShareUrl()}async defaultOidWatchHandler(){await this._handleDefaults()}async defaultGlobalIdWatchHandler(){await this._handleDefaults()}async enableCSVWatchHandler(){this._toolInfos?.length>0&&await this._initToolInfos()}enableInlineEditWatchHandler(){this._table&&(this._table.editingEnabled=this._editEnabled&&this.enableInlineEdit)}async mapHiddenWatchHandler(){this._toolInfos?.length>0&&await this._initToolInfos()}async isMobileWatchHandler(){!this._toolInfos&&!this.isMobile&&await this._initToolInfos()}async mapInfoWatchHandler(){this._configLayerOrderDefined="configLayerOrder"in(this.mapInfo?.layerOptions||{}),this._enabledLayerIds=F(this.mapInfo?.layerOptions?.layers||[],this.mapInfo?.layerOptions?.configLayerOrder),this._table&&(this._resetColumnTemplates(),this._sortTable())}async mapViewWatchHandler(){this._mapClickHandle&&this._mapClickHandle.remove(),this.mapView&&(this._floorExpression="",this._searchExpression="undefined",this.mapView.highlights=[{name:"default",color:"#00FFFF"},{name:"current-selection",color:"#ff00ff"},{name:"temporary",color:"#FFFF00"}],this._updateShareUrl(),this._mapClickHandle=c.on(()=>this.mapView,"click",e=>{this._creatingFeature||this._mapClicked(e)}))}async _layerWatchHandler(){if(this._hideTable=!1,this._fetchingData=!0,!this._layer){this._fetchingData=!1,this._hideTable=!0;return}try{await this._layer.when(),this._floorField=this._layer.floorInfo?.floorField||"",this._updateFloorDefinitionExpression(),await this._resetTable(),this._updateShareUrl()}catch(e){console.error(e),this._hideTable=!0}finally{this._fetchingData=!1}}async selectedIdsWatchHandler(){this._updateShareUrl(),this._validateEnabledActions(),this._selectAllActive&&this.selectedIds.length!==this._allIds.length&&(this._selectAllActive=!1),this.selectedIds.length>0&&(this._table.rowHighlightIds.removeAll(),this._table.rowHighlightIds.add(this.selectedIds[0])),this.selectedIds.length===0&&setTimeout(()=>{this.featureSelectionChange.emit(this.selectedIds)},700)}async selectedRelatedIdsWatchHandler(){this._validateEnabledActions(),this.selectedRelatedIds.length>0&&(this._relatedFeatureTable?.rowHighlightIds.removeAll(),this._relatedFeatureTable?.rowHighlightIds.add(this.selectedRelatedIds[0]))}async closeFilter(){await this._closeFilter()}async filterReset(){this._filterByExtentHandle&&(this._table&&(this._table.filterGeometry=void 0),this._filterByExtentHandle.remove(),this._filterByExtentHandle=void 0),await this._handleFilterListReset()}async filterUpdate(e,t){await this._handleFilterUpdate(e),t?(this._shouldUpdateTableOnExtentChange=!0,this._handleTableOnMapExtent()):t===!1&&(this._table&&(this._table.filterGeometry=void 0),this._filterByExtentHandle?.remove(),this._filterByExtentHandle=void 0,await this._updateAllIds())}async validateTableUpdate(e){this._shouldUpdateTableOnExtentChange=e}async validateActiveEdits(){return this._validateActiveEdits([],this.selectedIds)}async refresh(){this._table&&await this._refresh()}async setColumnOrder(e){this._setColumnTemplates(e)}async beforeMapInfoChange(e){let t=e.detail.ref,i=e.detail.mapInfo;if(this._hasPendingEdits()){e.preventDefault();let s=await this._validateActiveEdits([],this.selectedIds);await t.setMapByID(s?i.id:e.detail.currentId,!s)}}async editorInitialized(e){this._shouldUpdateTableOnExtentChange=!1,this._editor=e.detail}async closeEdit(){this._shouldUpdateTableOnExtentChange=!0,this._filterByExtentHandle&&this._handleTableOnMapExtent()}async selectionChanged(e){let t=e.detail.selectedFeature[0],i=Number(t.getObjectId()),s=this._table;if(s.rowHighlightIds.length&&s.rowHighlightIds.removeAll(),s.rowHighlightIds.add(i),this._highlightFeatures(i),this.zoomAndScrollToSelected&&s&&this.mapView){let a=s.viewModel.getObjectIdIndex(i);s.scrollToIndex(a);let l=t.layer,h=this.mapView.allLayerViews.toArray(),n;h.some(async r=>r.layer.title===l?.title&&r.layer.type==="feature"?(n=r,this.mapView&&await y([i],n,this.mapView,!0,void 0,this.zoomToScale),!0):!1)}}async beforeLayerSelectionChange(e){if(this._hasPendingEdits()){e.preventDefault();let t=e.detail.ref,i=await this._validateActiveEdits([],this.selectedIds);return e.detail.selectedIds?await t.setLayerByIds(i?e.detail.newIds:e.detail.currentIds,!0):await t.setLayerById(i?e.detail.newId:e.detail.currentId,!0)}}async layerSelectionChange(e){await this._layerSelectionChanged(e)}async editsComplete(e){let t=e.detail;(t==="delete"||t==="add")&&(this._allIds=await this.queryAllIds()),await this._refresh()}async facilityChanged(e){this._updateFloorDefinitionExpression()}async levelChanged(e){this._floorLevel=e.detail,this._updateFloorDefinitionExpression()}async siteChanged(e){this._updateFloorDefinitionExpression()}async noLayersFound(){this._layer=void 0,this._allIds=[],this._size=0,this._clearSelection()}async clearSelection(){await this._validateActiveEdits([],this.selectedIds)&&this._clearSelection()}async mapChanged(){this._queryingData=!1,this._creatingFeature=!1,this._clearSelection()}async featuresSelected(e){e.detail.forEach(t=>{let i=this._table?.highlightIds.indexOf(t);i&&i<0&&this._table?.highlightIds.add(t)})}createWorkFlowStarted(){this._creatingFeature=!0}backFromCreateWorkFlow(){this._creatingFeature=!1}async load(){await this._initToolInfos()}render(){let e=this._fetchingData||this._hideTable?"display-none":"",t=this._fetchingData?"":"display-none",i=this._queryingData?"":"display-none",s=this._size.toString(),a=this.selectedIds.length.toString(),l=this.isMobile?"height-full":"height-full-adjusted",h=this._canShowFullTextSearch();return this._validateActiveActions(),o`<div><calcite-scrim class=${b(i)} .loading=${this._queryingData}></calcite-scrim><calcite-shell><div class=${`width-full ${l}`}><calcite-panel class="height-full width-full panel-header-override">${this._getMapLayerPicker("header-actions-start")}${!this.isMobile&&o`${this._getTableControlRow("header-content")}${this._getActionsEnd("header-actions-end")}`||""}${h&&o`<div class="search-container border-bottom"><calcite-input class=search clearable icon=search @calciteInputChange=${n=>{this._searchTextChanged(n)}} .placeholder=${this._searchPlaceHolder} title=${this._searchPlaceHolder??_} type=search ${g(this._searchNode)}></calcite-input></div>`||""}<calcite-loader class=${b(t)} .label=${this._translations.fetchingData} scale=l></calcite-loader><div class=${b(e)} ${g(this.onTableNodeCreate)}></div></calcite-panel></div>${this.isMobile?void 0:o`<div class="bottom-left text-color height-19" id=solutions-selected-count-div>${(this._translations.recordsTotal?.replace("{{total-number-of-records}}",s)+" | "+this._translations.recordsSelected.replace("{{selected-number-of-records}}",a)).replace("{{total}}",s).replace("{{selected}}",a)}</div>`}</calcite-shell></div>`}updated(){this._table&&this.updateRelatedAttachmentColumns()}async _searchTextChanged(e){this._fullTextSearchInfo.forEach(t=>{t.searchTerm=e.target.value}),this._searchFullText()}async _searchFullText(){let e=[],t=!1;if(this._showOnlySelected)e=this._tempSelectedIds,t=!0;else if(await this._validateActiveEdits([],this.selectedIds))this._clearSelection(),this._tempSelectedIds=[];else return;this._searchExpression&&this._clearSearchDefinitionExpression();let i=[];if(this._fullTextSearchInfo?.length&&this._fullTextSearchInfo[0].searchTerm){let s=this._layer?.createQuery();s.fullText=this._fullTextSearchInfo,i=this._layer?await this._layer.queryObjectIds(s):[],t&&e?.length&&(i=i.filter(a=>e.includes(a))),await this._updateSearchDefinitionExpression(i?.length?i:[-1])}t&&i?.length&&(this._showOnlySelected=!0,this._table?.highlightIds.addMany(i.reverse())),await new Promise(s=>setTimeout(s,800)),await this._updateAllIds()}_clearSearchDefinitionExpression(){let e=this._layer?.definitionExpression;this._searchExpression&&e&&e?.indexOf(this._searchExpression)>-1&&this._layer&&(e?.indexOf(" AND ("+this._searchExpression)>-1?this._layer.definitionExpression=e.replace(` AND (${this._searchExpression})`,""):this._layer.definitionExpression=e.replace(this._searchExpression,"")),this._searchExpression=""}async _updateSearchDefinitionExpression(e){let t=this._layer?.definitionExpression;if(this._layer)if(e?.length){let i=`objectId in(${e})`;this._layer.definitionExpression=this._searchExpression&&t&&t.includes(this._searchExpression)?t.replace(this._searchExpression,i):t?`${t} AND (${i})`:i,this._searchExpression=i}else this._clearSearchDefinitionExpression()}_canShowFullTextSearch(){return this._layer?.capabilities?.query?.supportsFullTextSearch&&this._layer.indexes.items.filter(e=>e.indexType=="FullText").length>0}_getFullTextSearchInfo(){if(this._fullTextSearchInfo=[],this._layer?.capabilities?.query?.supportsFullTextSearch){let e=this._layer.indexes?.filter(t=>t.indexType=="FullText");if(e?.length){let t=[];e.forEach(s=>{t.push(...s.fields.split(","))});let i=[];t.forEach(s=>{let a=this._layer?.getField(s.trim());a?.alias&&i.push(a.alias)}),this._searchPlaceHolder=this._translations.searchPlaceholder.replace("{{field_names}}",i.join(", ")),this._fullTextSearchInfo.push({onFields:["*"],searchTerm:"",searchType:"prefix"})}}}_getMapLayerPicker(e){let t=this.isMobile?"display-none":"";return o`<div class=${`border-end ${t}`} id=solutions-map-layer-picker-container slot=${e??_}><map-layer-picker appearance=transparent .configLayerOrderDefined=${this._configLayerOrderDefined} .defaultLayerId=${this.defaultLayerId} display=inline-flex .enabledLayerIds=${this._enabledLayerIds} height=50 .isMobile=${this.isMobile} .mapView=${this.mapView} .showOnlyUpdatableLayers=${this.showOnlyUpdatableLayers} placeholder-icon=layers scale=l .selectedIds=${this._layer?[this._layer?.id]:[]} show-single-layer-as-label show-tables type=dropdown></map-layer-picker></div>`}_getLayerOption(e){let t;return this.mapInfo?.layerOptions?.layers.some(i=>i.id===e?(t=i,!0):!1),t}_getActionsEnd(e){let t=this._relatedFeatureTable?this._relatedFeatureTable.layer:this._layer,i=this._relatedFeatureTable||this._table,s=this._getLayerOption(t?.id||"");return o`<div class="display-flex" slot=${e??_}><field-selection .configExtraFields=${s?.extraFields} .layer=${t} .mapView=${this.mapView} .table=${i} .tableRef=${this.el}></field-selection>${this.enableShare&&!this.isMobile?this._getShare("share"):void 0}</div>`}_getTableControlRow(e){return o`<div class=${"height-51-px width-full display-flex"} slot=${e??_} ${g(this._toolbar)}>${this._getActionBar()}</div>`}_getActionBar(){return o`<calcite-action-bar class=width-full expand-disabled id=${this._getId("bar")??_} layout=horizontal><calcite-action-group>${this.isMobile?void 0:this._getActions()}</calcite-action-group></calcite-action-bar>`}_getActions(){return this._toolInfos?.reduce((e,t)=>(t&&e.push(t.isDanger?this._getDangerAction(t.icon,t.label,t.func,t.disabled):this._getAction(t.active,t.icon,t.indicator,t.label,t.func,t.disabled,!!t.loading,t.toolTip)),e),[])}_validateEnabledActions(){let e=this._getIds().length,t=["zoom-to-object","pencil","trash","erase","selected-items-filter"];this._toolInfos?.forEach(i=>{i&&t.indexOf(i.icon)>-1&&(i.disabled=i.icon==="pencil"?e<2||e>m:e<1,i.toolTip=i.icon==="pencil"?e>m?this._translations.featureEditLimitNotice:this._translations.editMultiple:i.toolTip)})}_validateActiveActions(){let e=["filter","list-check-all","selected-items-filter"];this._toolInfos?.forEach(t=>{t&&e.indexOf(t.icon)>-1&&(t.icon==="filter"&&(t.indicator=this._filterActive),t.icon==="list-check-all"&&(t.active=this._selectAllActive),t.icon==="selected-items-filter"&&(t.active=this._showOnlySelected,t.label=this._showOnlySelected?this._translations.showAll:this._translations.showSelected))})}async _initToolInfos(){let e=this._getIds().length>0,t=this._relatedFeatureTable?this._relatedFeatureTable.layer.isTable:this._layer?.isTable,i=this.featureSelectionMode==="multiple"&&this._layer?.capabilities?.operations.supportsUpdate,s=this._getSelectedIds().length<2||this._getSelectedIds().length>m,a=!this.mapHidden&&!t,l=!this._relatedFeatureTable&&(!this._layer?.isTable||this._hasFilterExpressions()),h=this._featuresEmpty(),n=this.featureSelectionMode==="single",r=this.enableCSV;if(this._relatedFeatureTable){let u=await this._queryRelatedFeatures();r=u&&Object.keys(u).length>0}let d=[];l&&d.push({active:!1,icon:"filter",indicator:!1,label:this._translations.filters,func:()=>this.toggleFilter.emit(),disabled:!1,toolTip:this._translations.filters}),a&&d.push({active:!1,icon:"zoom-to-object",indicator:!1,label:this._translations.zoom,func:()=>this._zoom(),disabled:!e,toolTip:this._translations.zoom}),i&&d.push({active:!1,icon:"pencil",indicator:!1,label:this._translations.editMultiple,func:()=>this.editMultipleFeatures.emit(this._getSelectedIds()),disabled:s,toolTip:this._translations.editMultiple}),this._deleteEnabled&&d.push({active:!1,icon:"trash",indicator:!1,label:this._translations.delete,func:()=>this._showDelete(),disabled:!e,isDanger:!0,toolTip:this._translations.delete}),d.push({active:!1,icon:"erase",indicator:!1,label:this._translations.clearSelection,func:()=>{this.clearSelection()},disabled:!e,toolTip:this._translations.clearSelection}),this._relatedFeatureTable||d.push({active:!1,icon:"selected-items-filter",indicator:!1,label:this._showOnlySelected?this._translations.showAll:this._translations.showSelected,func:()=>this._toggleShowSelected(),disabled:!e,toolTip:this._showOnlySelected?this._translations.showAll:this._translations.showSelected}),!n&&!this._relatedFeatureTable&&d.push({active:!1,icon:"list-check-all",indicator:!1,func:async()=>await this._selectAll(),label:this._translations.selectAll,disabled:h,toolTip:this._translations.selectAll}),!n&&!this._relatedFeatureTable&&d.push({active:!1,icon:"compare",indicator:!1,func:async()=>await this._switchSelected(),label:this._translations.switchSelected,disabled:h,toolTip:this._translations.switchSelected}),d.push({active:!1,icon:"refresh",indicator:!1,func:()=>{this._refresh()},label:this._translations.refresh,disabled:!1,toolTip:this._translations.refresh}),r&&d.push({active:!1,icon:"export",indicator:!1,func:()=>{this._exportToCSV()},label:this._translations.exportCSV,loading:this._csvExporting,disabled:h,toolTip:this._translations.exportCSV}),this._toolInfos=[...d]}_updateFloorDefinitionExpression(){if(this._floorField&&this._floorLevel){let e=`${this._floorField} = '${this._floorLevel}'`,t=this._layer?.definitionExpression;this._layer&&(this._layer.definitionExpression=t&&this._floorExpression&&t?.indexOf(this._floorExpression)>-1?t.replace(this._floorExpression,e):t?`${t} AND (${e})`:e),this._floorExpression=e}}_featuresEmpty(){return this._allIds?.length===0}_hasFilterExpressions(){let e=[],t=this._layer?.id;return this.mapInfo?.filterConfig?.layerExpressions&&t!==void 0&&(e=this.mapInfo.filterConfig.layerExpressions.filter(i=>i.id===t)),e.length>0}_getAction(e,t,i,s,a,l,h,n){let r=this._layer===void 0?!0:l;return o`<calcite-action .active=${e} appearance=solid .disabled=${r} .icon=${t} .id=${`layer-table-${t}`} .indicator=${i} .label=${s} .loading=${h} @click=${a} text text-enabled><div class="display-flex"><span class="label-override padding-start-1-4">${s}</span></div></calcite-action>${this._getToolTip("auto",`layer-table-${t}`,n)}`}_showDelete(){this.showDelete.emit({ids:this._getIds()})}_getShare(e){return o`<div id=${this._getId(e)??_}><instant-apps-social-share class="height-51 width-51 display-flex" .embed=${this.shareIncludeEmbed} flip-rtl popover-button-icon-scale=s scale=m share-button-color=neutral share-button-type=action .socialMedia=${this.shareIncludeSocial} .view=${this.mapView} ${g(this._shareNode)}></instant-apps-social-share>${this._getToolTip("bottom",e,this._translations.share)}</div>`}_updateShareUrl(){let e=this._shareNode.value?.shareUrl;if(!e)return;let t=new URL(e);this.mapInfo?.id?t.searchParams.set("webmap",this.mapInfo.id):t.searchParams.delete("webmap"),this._layer?.id?t.searchParams.set("layer",this._layer.id):t.searchParams.delete("layer"),this.selectedIds?.length>0?t.searchParams.set("oid",this.selectedIds.reverse().join(",")):t.searchParams.delete("oid"),this.appLayout&&t.searchParams.set("applayout",this.appLayout),this.selectedRelatedIds?.length>0&&this._relatedFeatureTable?.layer?.id&&(t.searchParams.set("oid",this.selectedRelatedIds.join(",")),t.searchParams.set("layer",this._relatedFeatureTable?.layer?.id.toString())),this._shareNode.value&&(this._shareNode.value.autoUpdateShareUrl=!1,this._shareNode.value.shareUrl=t.href)}_getToolTip(e,t,i){return o`<calcite-tooltip .placement=${e} .referenceElement=${t}><span>${i}</span></calcite-tooltip>`}_getId(e){return`solutions-action-${e}`}_getDangerAction(e,t,i,s){let a=this._layer===void 0?!0:s;return o`<div class="display-flex" id=${this._getId(e)??_}>${o`<calcite-action appearance=solid .disabled=${a} .id=${`layer-table-${e}`} @click=${i} text><calcite-icon class="danger-icon-color" .icon=${e} scale=s></calcite-icon><span class="label-override padding-start-1-4 danger-label-color">${t}</span></calcite-action>`}${this._getToolTip("bottom",`layer-table-${e}`,t)}</div>`}_getIds(){let e=this._relatedFeatureTable??this._table;return this._relatedFeatureTable&&this._table&&this._table.highlightIds.getItemAt(0)!==this.selectedIds[0]&&(e=this._table),e?.highlightIds.map(t=>Number.parseInt(t.toString(),10)).toArray()??[]}onTableNodeCreate(e){this._tableNode=e}async _getTable(e,t){this._layer&&(await this._layer.when(()=>{this._table=new L({autoRefreshEnabled:this.enableAutoRefresh,autoSaveEnabled:this.enableTableAutosave,layer:this._layer,view:this.mapView,columnReorderingEnabled:this.enableColumnReorder,editingEnabled:this._editEnabled&&this.enableInlineEdit,relatedRecordsEnabled:!0,attachmentsEnabled:!0,highlightEnabled:!1,multiSortEnabled:!1,visibleElements:{columnDescriptions:!1,header:!1,menu:!1,progress:!1},tableTemplate:{columnTemplates:t},container:e})}),await this._table?.when(()=>{this._table?.viewModel.addHandles(this._table.highlightIds.on("change",i=>{this._handleOnChange(i)})),this._table?.viewModel.addHandles(this._table.on("cell-pointerover",this.tempHighlightOnHover.bind(this))),this._table?.viewModel.addHandles(this._table.on("cell-pointerout",this._removeTempHighlight.bind(this))),this._table?.viewModel.addHandles(this._table.on("column-reorder",this._handleColumnReorder.bind(this))),this.listenOn(this._tableNode,"mouseleave",this._removeTempHighlight),this._table?.viewModel.addHandles(c.watch(()=>this._table.size,i=>{this._size=i})),c?.watch(()=>this._table?.relatedTable,async i=>{if(i){if(i.rowHighlightIds.length){let a={added:[i.rowHighlightIds.getItemAt(0)],removed:[]};this._handleOnChange(a)}let s=i.layer;if(this._layerEditHandle=s.on("edits",async()=>{await new Promise(a=>setTimeout(a,50)),await this._refresh(!0)}),this._checkEditEnabled(s),i.editingEnabled=this._editEnabled&&this.enableInlineEdit,i.autoSaveEnabled=this.enableTableAutosave,this._relatedFeatureTable=i,typeof i.layer?.id=="string"&&i.layer?.fields){let a=i.layer.popupTemplate?.fieldInfos,l=this._getColumnTemplates(i.layer.id,i.layer.fields,a);this._relatedFeatureTable.tableTemplate=new w({columnTemplates:l})}i.highlightIds.on("change",a=>{this._handleRelatedRecordsChange(a)})}else{this.selectedRelatedIds=[],this._relatedFeatureTable=void 0,this._layerEditHandle&&this._layerEditHandle.remove();let s=this._layer;this._refresh(),s&&this.relatedRecordToggled.emit(s),this._finishOnChange()}await this._initToolInfos()})}))}async _handleRelatedRecordsChange(e){await this._handleOnChange(e),this._updateShareUrl()}hasAttachmentsEnabled(e){if(!e?.capabilities)return!1;let{capabilities:{data:{supportsAttachment:t},operations:{supportsQueryAttachments:i}}}=e;return t&&i}async _handleOnChange(e){if(!await this._validateActiveEdits([...e.added],[...e.removed]))return;let t=[...this._getIds()],i=this._getSelectedLayer(t);this._relatedFeatureTable&&this._table?.highlightIds.getItemAt(0)!==this.selectedIds[0]&&(i=this._layer,await this._initToolInfos()),i&&this.relatedRecordToggled.emit(i),this.featureSelectionMode==="single"&&(this._relatedFeatureTable&&t.length>1?(this._relatedFeatureTable.highlightIds.remove(t[0]),t.shift()):t.length>1&&!this._selectAllActive&&(this._table?.highlightIds.remove(t[0]),t.shift())),!this._relatedFeatureTable||this._relatedFeatureTable&&this._table?.highlightIds.getItemAt(0)!==this.selectedIds[0]?(this.selectedRelatedIds=[],this.selectedIds=t.reverse(),this._tempSelectedIds=[...this.selectedIds],this._highlightFeatures(this.selectedIds[0])):this.selectedRelatedIds=t.reverse(),this._finishOnChange()}async _validateActiveEdits(e,t){let i=!0;if(this._editor&&!this._skipEditCheck){if(this._hasPendingEdits()){let s=!1;try{this._editor.viewModel.activeWorkflow&&await this._editor.viewModel.activeWorkflow.cancel({force:!1})}catch(a){s=a?.name==="workflow:cancel-denied"}if(s){let a=this._relatedFeatureTable&&this._relatedFeatureTable.highlightIds.length>0?this._relatedFeatureTable:this._table;i=!1,this._skipEditCheck=!0,e.length>0?a?.highlightIds.removeMany(e):t.length>0&&a?.highlightIds.addMany(t)}}}else i=!this._skipEditCheck,this._skipEditCheck=!1;return this._shouldUpdateTableOnExtentChange=i,i}_hasPendingEdits(){let e=this._editor?.viewModel?.hasPendingEdits,t=this._editor?.activeWorkflow?.activeWorkflow?.hasPendingEdits;return e||t}_finishOnChange(){this._showOnlySelected&&!this._relatedFeatureTable&&(this._table&&this._getSelectedIds().length>0?this._table.filterBySelectionEnabled=!0:this._toggleShowSelected());let e=this._getSelectedIds();setTimeout(()=>{this.featureSelectionChange.emit(e)},50)}_handleColumnReorder(){this.columnReorder.emit()}tempHighlightOnHover(e){if(this._removeTempHighlight(),this._selectedLayerView){let t=e.feature;this._temporaryFeatureHandle=this._selectedLayerView?.highlight([t],{name:"temporary"})}}_removeTempHighlight(){this._temporaryFeatureHandle&&this._temporaryFeatureHandle.remove()}_highlightFeatures(e){if(this._clearHighlights(),this.selectedIds.length>0&&this._selectedLayerView&&(this._currentFeatureHighlightHandle=this._selectedLayerView?.highlight([e],{name:"current-selection"}),this.selectedIds.length>1)){let t=this.selectedIds.filter(i=>i!==e);this._defaultFeaturesHandle=this._selectedLayerView?.highlight(t,{name:"default"})}}_clearHighlights(){this._removeTempHighlight(),this._currentFeatureHighlightHandle&&this._currentFeatureHighlightHandle.remove(),this._defaultFeaturesHandle&&this._defaultFeaturesHandle.remove()}_resetColumnTemplates(){if(this._layer){let e=this._layer.popupTemplate?.fieldInfos,t=this._getColumnTemplates(this._layer.id,this._layer.fields,e);t?.length===0?this._tableNode?.classList.add("display-none"):this._tableNode?.classList.remove("display-none");let i=this._table?.tableTemplate?.columnTemplates,s=i&&t&&i.length!==t.length||t?.some((a,l)=>i&&i[l]?JSON.stringify(i[l])!==JSON.stringify(a):!1);if(this._table&&t&&(s||!this._columnsInfo)){this._table.tableTemplate=new w({columnTemplates:t});let a=t.map(l=>l.fieldName);this._initColumnsInfo(a)}}}_setColumnTemplates(e){this._table&&e&&(this._table.tableTemplate=new w({columnTemplates:e}))}async _resetTable(){if(this._loaded=!1,this._clearSelection(),this._allIds=await this.queryAllIds(),!this._table&&this._layer){let e=this._layer.popupTemplate?.fieldInfos,t=this._getColumnTemplates(this._layer.id,this._layer.fields,e);this._tableNode&&await this._getTable(this._tableNode,t)}else this._table&&(this._table.view=this.mapView,this._table.layer=this._layer);await this._initLayerRefresh(),this._checkEditEnabled(this._layer),this._table&&(this._table.editingEnabled=this._editEnabled&&this.enableInlineEdit,this._table.autoSaveEnabled=this.enableTableAutosave,await this._table.when(),setTimeout(()=>{this._loaded||this.finishLoading()},1e3),await c.once(()=>this._table?.state==="loaded").then(async()=>{await this.finishLoading()}))}async finishLoading(){try{this._loaded=!0,this._table?.highlightIds.removeAll(),this._table.objectIds.removeAll(),this._resetColumnTemplates(),this._showOnlySelected=!1,await this._handleDefaults(),await this._sortTable(),await this._initToolInfos(),["esri-feature-table","esri-widget"].forEach(e=>{this._tableNode&&!this._tableNode.classList.contains(e)&&this._tableNode.classList.add(e)})}catch(e){console.log(e)}}async _initLayerRefresh(){this._refreshHandle&&this._refreshHandle.remove(),this._layer&&(this._refreshHandle=this._layer.on("refresh",e=>{e.dataChanged&&this._updateAllIds()}))}async _updateAllIds(){let e=await this.queryAllIds(),t=this.selectedIds.filter(i=>this._allIds.indexOf(i)>-1);(JSON.stringify(e)!==JSON.stringify(this._allIds)||JSON.stringify(this.selectedIds)!==JSON.stringify(t))&&(this._allIds=e,this.selectedIds=t,await this._refresh())}async _handleDefaults(){if(!this._defaultOidHonored&&this.defaultOid?.length>0&&this.defaultOid[0]>-1&&this._table&&(await this._selectDefaultFeature(this.defaultOid),this._defaultOidHonored=!0,this.defaultOid=[],this._showOnlySelected=!1,this._toggleShowSelected()),!this._defaultGlobalIdHonored&&this.defaultGlobalId&&this.defaultGlobalId?.length>0&&this._table&&this._layer){let e=await O(this.defaultGlobalId,this._layer),t=e?.length>0?e.map(i=>Number(i.getObjectId())):void 0;t&&await this._selectDefaultFeature(t),this._defaultGlobalIdHonored=!0,this.defaultGlobalId=[],this._showOnlySelected=!1,this._toggleShowSelected()}}_initColumnsInfo(e){let t=this._table?.columns.reduce((s,a)=>((!e||e?.indexOf(a.name)>-1)&&(s[a.name]=!a.hidden),s),{}),i=this._table?.columns.map(s=>s.name);(e&&i?e.filter(s=>i.indexOf(s)<0):[]).forEach(s=>{t[s]=!0}),this._columnsInfo=e?e.reduce((s,a)=>(s[a]=t[a],s),{}):t}async _selectDefaultFeature(e){e.length>0&&this._table?.highlightIds.addMany(e)}_checkEditEnabled(e){this._editEnabled=!!(e?.editingEnabled&&e?.capabilities?.operations.supportsUpdate),this._deleteEnabled=!!(e?.editingEnabled&&e?.capabilities?.operations.supportsDelete)}async _sortTable(){let e=this._layer?.objectIdField,t="desc",i,s=this.mapInfo?.layerOptions?.layers,a=this._layer?.id;s&&s.length>0&&a!==void 0&&(i=s.filter(l=>l.id===a),i&&i.length>0&&(i=i[0],i.sortField&&i.fields?.includes(i.sortField)&&(e=i.sortField),t=i?.sortOrder?i.sortOrder:"desc")),this._table&&this._layer&&(await this._table.when(),await this._layer.when(()=>{e&&this._table?.sortColumn(e,t)}))}async _handleFilterListReset(){this._filterActive=!1,this._updateShareUrl(),await this._searchFullText()}async _handleFilterUpdate(e){if(this._floorExpression&&this._layer){let t=this._layer.definitionExpression,i=new RegExp(`${this._floorField} = ['].+[']`,"gm");this._layer.definitionExpression=t&&this._floorField&&t.indexOf(`${this._floorField} = '`)>-1?t.replace(i,this._floorExpression):t?`${t} AND (${this._floorExpression})`:this._floorExpression}this._filterActive=e,this._updateShareUrl(),await this._searchFullText()}_handleTableOnMapExtent(){this._table&&(this._filterByExtentHandle=c.when(()=>this.mapView?.stationary,async()=>{if(this._shouldUpdateTableOnExtentChange&&this.appLayout==="splitView"){if(await new Promise(e=>setTimeout(e,800)),this._table&&this.mapView){this._table.filterGeometry=this.mapView.extent;let e={geometry:this.mapView.extent},t=this._layer&&await this._layer.queryObjectIds(e),i=this.selectedIds.filter(a=>!t?.includes(a)),s=this._outOFExtentOids.filter(a=>t?.includes(a));i.length>0&&(this._table&&this._table?.viewModel?.attachmentsViewOptions?.objectId&&this._table.viewModel.hideAttachmentsView(),this._table.highlightIds.removeMany(i),this._outOFExtentOids=[...this._outOFExtentOids,...i]),s.length>0&&(this.selectedIds=[...new Set([...this.selectedIds,...s])],this._table.highlightIds.removeAll(),this._table.highlightIds.addMany(this.selectedIds.reverse()),this._outOFExtentOids=this._outOFExtentOids.filter(a=>!s.includes(a)))}this._allIds=await this.queryAllIds()}},{initial:!0}))}async _closeFilter(){this._allIds=await this.queryAllIds()}async queryAllIds(){if(this._layer){let e=this._layer.createQuery();return e.geometry=this._filterByExtentHandle&&this.mapView?this.mapView.extent:null,e.where=this._layer.definitionExpression||"1=1",await this._layer.queryObjectIds(e)}else return[]}async _mapClicked(e){let t={include:this._layer},i=await this.mapView?.hitTest(e.screenPoint,t);if(i&&i.results.length>0){let s=i.results;if(this.featureSelectionMode==="single"){this._table?.highlightIds.removeAll();let a=s[0].graphic.getObjectId();if(a){let l=this._table?.highlightIds.indexOf(a);l!==void 0&&l<0&&this._table?.highlightIds.add(a)}}else s.forEach(a=>{let l=Number(a.graphic.getObjectId()),h=this._table?.highlightIds.indexOf(l);h&&h<0&&l&&this._table?.highlightIds.add(l)});this._showOnlySelected&&this._table&&(this._table.filterBySelectionEnabled=!0)}else await this.clearSelection()}async _selectAll(){let e=this._allIds,t=e.filter(i=>this.selectedIds.indexOf(i)<0);await this._validateActiveEdits(t,this.selectedIds)&&this._table?(this._table.highlightIds.removeAll(),this._table.highlightIds.addMany(e),this.selectedIds=e,this._finishOnChange(),this._selectAllActive=!0):this._skipEditCheck=!1}_toggleShowSelected(){this._showOnlySelected=!this._showOnlySelected,this._table&&(this._table.filterBySelectionEnabled=this._showOnlySelected)}_clearSelection(){this._relatedFeatureTable||(this.selectedIds=[],this._outOFExtentOids=[],this._table&&this._table?.viewModel?.attachmentsViewOptions?.objectId&&this._table.viewModel.hideAttachmentsView(),this._table?.highlightIds.removeAll(),this._clearHighlights(),this._table?.rowHighlightIds.removeAll()),this._relatedFeatureTable&&(this._relatedFeatureTable?.highlightIds.removeAll(),this.selectedRelatedIds=[]),this._finishOnChange()}async _switchSelected(){let e=[...this.selectedIds],t=this._allIds.reduce((i,s)=>(e.indexOf(s)<0&&i.push(s),i),[]).sort((i,s)=>i-s);await this._validateActiveEdits(t,e)&&this._table?(this._table.highlightIds.removeAll(),this._table.highlightIds.addMany(t),this.selectedIds=t,this._finishOnChange()):this._skipEditCheck=!1}async _exportToCSV(){let e=this._relatedFeatureTable?this._relatedFeatureTable.layer:this._layer;if(!e)return;let t={},i=this._getIds();if(this._relatedFeatureTable?.tableParent&&this._relatedFeatureTable.highlightIds.length===0){let l=this._relatedFeatureTable.tableParent.highlightIds?.getItemAt(0);if(l!==void 0){let h=await this._queryRelatedFeatures(),n=[];h&&h[l]?.features&&(h[l].features.forEach(r=>{r.attributes&&n.push(r.attributes[e.objectIdField])}),i=n.length>0?n:[])}}t[e.id]={selectionSetNames:[e.title||""],ids:i,layer:e};let s=this._relatedFeatureTable??this._table;if(!s)return;let a=s&&s.columns.toArray().reduce((l,h)=>{if(!h.hidden){let n=h?.name||h?.fieldName;n&&l.push(n.toLocaleLowerCase())}return l},[]);this._updateToolInfoLoading("export",!0),this._csvExporting=!0,this.mapView?.map&&await $(this.mapView.map,t,!1,!1,!0,a,!0,!0),this._updateToolInfoLoading("export",!1),this._csvExporting=!1}async _queryRelatedFeatures(){let e=this._relatedFeatureTable?this._relatedFeatureTable?this._relatedFeatureTable.layer:this._relatedFeatureTable.tableParent?.layer:this._layer,t=this._relatedFeatureTable?.tableParent?.highlightIds?.items[0],i=this._relatedFeatureTable?.tableParent?.layer,s=e?.relationships?.find(l=>i.relationships?.some(h=>h.id===l.id)),a=new M({objectIds:[t],outFields:["*"],relationshipId:s?.id});return t&&a&&await i.queryRelatedFeatures(a).catch(async l=>{console.error(l)})}_updateToolInfoLoading(e,t){this._toolInfos.some(i=>i?.icon===e?(i.loading=t,!0):!1)}async _refresh(e){if(await this._validateActiveEdits([],this.selectedIds)){this._table&&await this._table.refresh(),this._relatedFeatureTable&&await this._relatedFeatureTable.refresh(),this._allIds=await this.queryAllIds();let t=this._getSelectedLayer(this.selectedRelatedIds);if(t&&this.relatedRecordToggled.emit(t),!e){let i=this._getSelectedIds();this.featureSelectionChange.emit(i)}}}_getSelectedIds(){let e;return this._relatedFeatureTable?this.selectedRelatedIds.length>0?e=this.selectedRelatedIds:e=this._relatedFeatureTable.tableParent?.highlightIds.toArray()??[]:e=this.selectedIds,e}_getSelectedLayer(e){let t;return this._relatedFeatureTable?e.length>0?t=this._relatedFeatureTable.layer:t=this._relatedFeatureTable.tableParent?.layer:t=this._layer,t}async _clearSearchText(){if(this._searchNode.value){this._searchNode.value.value="";let e={target:{value:""}};await this._searchTextChanged(e)}}async _zoom(){this._layer&&this.mapView&&await y(this.selectedIds,this._selectedLayerView,this.mapView,!0,void 0,this.zoomToScale)}async _layerSelectionChanged(e){let t=e.detail[0];if(t!==this._layer?.id||this._featuresEmpty()){this._fetchingData=!0,await this._clearSearchText();let i=this.mapView&&await A(this.mapView,t);i&&await i.when(async()=>{this._selectedLayerView=!i.isTable&&this.mapView?await C(this.mapView,i.id):null,this._table&&this._table?.viewModel?.attachmentsViewOptions?.objectId&&this._table.viewModel.hideAttachmentsView(),this._shouldUpdateTableOnExtentChange=!0,this._layer=i,await this._initToolInfos(),this._getFullTextSearchInfo()})}this._creatingFeature=!1,this._fetchingData=!1}_getColumnTemplates(e,t,i){let s=this._getLayerOption(e),a=this._layer?.attributeTableTemplate?.elements,l=[];a?.length>0&&this.honorMapFieldSettings&&(l=a.map(r=>r.fieldName));let h=s?.fields&&s?.fieldOrder?s.fieldOrder.filter(r=>s?.fields&&s.fields.indexOf(r)>-1):l.length>0?l:void 0,n;return t&&(n=t.reduce((r,d)=>{let u={type:"field",fieldName:d.name,label:this.getFieldLabel(d,i),menuConfig:this._getMenuConfig(d.name)};return s&&s.fields&&s?.fields?.length>0?s.fields.indexOf(d.name)>-1&&r.push(u):l.length>0?l.indexOf(d.name)>-1&&r.push(u):r.push(u),r},[])),n?h?n?.sort(this._sortFields.bind(this,h)):n:[]}updateRelatedAttachmentColumns(){let e=this._getLayerOption(this._layer?.id||""),t=this.hasAttachmentsEnabled(this._layer),i=!0,s="attachments",a=(e?.extraFields||[]).reduce((h,n)=>(n.startsWith("related:")?h.related.push(n.split("related:")[1]):h.extra.push(n),h),{related:[],extra:[]}),l=a.extra.some(h=>h.toLowerCase()===s);a&&(t=l&&t,i=a.related.length>0,this._table?.columns.forEach(h=>{h.fieldName.startsWith("EsriFeatureTableRelationshipColumn")&&(h.hidden=!a.related.includes(h.effectiveLabel)),h.fieldName.startsWith("EsriFeatureTableAttachmentsColumn")&&(h.hidden=!a.extra.some(n=>n.toLowerCase()===h.effectiveLabel.toLowerCase()))})),this._table.relatedRecordsEnabled=i,this._table.attachmentsEnabled=t}getFieldLabel(e,t){let i=e.alias?e.alias:e.name;return t?.some(s=>s.fieldName===e.name?(i=s.label,!0):!1),i||e.name}_sortFields(e,t,i){return e?.indexOf(t.fieldName)-e.indexOf(i.fieldName)}_getMenuConfig(e){return{items:[{label:this._translations.hideField,icon:"view-hide",autoCloseMenu:!0,clickFunction:()=>{this._handleHideClick(e)}}]}}_handleHideClick(e){this._columnsInfo&&this._table&&(this._columnsInfo[e]=!1,this._table.hideColumn(e),this._table.tableTemplate&&this._table.tableTemplate.columnTemplates.forEach(t=>{t.fieldName===e&&(t.visible=!1)}))}};E("layer-table",I);return I},"widgets/FeatureTable","core/reactiveUtils","rest/support/RelationshipQuery","widgets/FeatureTable/support/TableTemplate",a,c,d,e)
2
+ import e from"./HIMUNCZ6.js";import{a as H}from"./XQISEL3T.js";import d from"./3R5VOUDP.js";import c from"./CEP54NLT.js";import a from"./YVNP437O.js";import{a as S}from"./3AQ7U2PF.js";import{b as E}from"./NDUAEC62.js";import{F as f,G as g,H as x,J as b,h as v,i as o,l as _,r as p,u as T}from"./P4KZ6OZF.js";export default $arcgis.t(([L,c,M,w,{c:O},{c:C,d:A,j:y},{C:m,o:F},{b:$}])=>{var R=v`@layer{:host{display:block}.height-full{height:100%}.height-full-adjusted{height:calc(100% - 20px)}.width-full{width:100%}.display-flex{display:flex}.display-none{display:none}.table-border{border:1px solid var(--calcite-color-border-2)}.border-end{border-inline-end:1px solid var(--calcite-color-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51-px{height:51px}.height-50-px{height:50px}.bottom-left{position:absolute;left:0;bottom:0;padding-left:5px}html[dir=rtl] .bottom-left{position:absolute;right:0;bottom:0;padding-right:5px}.height-19{height:19px}.background{background-color:var(--calcite-color-background)}.text-color{color:var(--calcite-color-text-1)}.align-center{align-items:center}.danger-color{color:var(--calcite-color-status-danger)}.esri-feature-table vaadin-grid{border:none!important}vaadin-grid-cell-content{font-size:14px!important;color:var(--calcite-color-text-3)!important}.absolute-right{position:absolute;right:0;left:unset}html[dir=rtl] .absolute-right{left:0;right:unset}.disabled{cursor:default!important;user-select:none;opacity:var(--calcite-opacity-disabled);pointer-events:none}.actions-end{height:50px!important;display:inline-flex}.border-top{border-top:1px solid var(--calcite-color-border-2)}.modal{--calcite-dialog-content-space: 0}.esri-feature-table__table-container{height:100%}.search-container{background-color:var(--calcite-color-foreground-1)!important}.search{--calcite-color-border-input: var(--calcite-color-border-3);width:60%;padding:10px}.delete-red{--calcite-icon-color: var(--calcite-color-status-danger);--calcite-color-text-1: var(--calcite-color-status-danger);--calcite-color-text-3: var(--calcite-color-status-danger)}.label-override{white-space:nowrap}.padding-start-1-4{padding-inline-start:.5rem}.panel-header-override{--calcite-panel-header-content-space: 0px}.danger-label-color{color:var(--calcite-color-status-danger)}.danger-icon-color{--calcite-icon-color: var(--calcite-color-status-danger)}.width-51{width:51px}.height-51{height:51px}calcite-action-bar{--calcite-internal-action-bar-gap: 0px;--calcite-internal-action-bar-padding: 0px}}`,I=class extends x{constructor(){super(),this.defaultGlobalId=[],this.defaultLayerId="",this.defaultOid=[],this.enableAutoRefresh=!1,this.enableColumnReorder=!0,this.enableCSV=!1,this.enableInlineEdit=!1,this.enableShare=!1,this.enableTableAutosave=!0,this.featureSelectionMode="multiple",this.selectedRelatedIds=[],this.honorMapFieldSettings=!1,this.isMobile=!1,this.mapHidden=!1,this.showOnlyUpdatableLayers=!1,this.selectedIds=[],this.shareIncludeEmbed=!1,this.shareIncludeSocial=!1,this.showNewestFirst=!1,this.zoomAndScrollToSelected=!1,this._allIds=[],this._configLayerOrderDefined=!1,this._csvExporting=!1,this._fetchingData=!1,this._hideTable=!1,this._filterActive=!1,this._selectAllActive=!1,this._showHideOpen=!1,this._showOnlySelected=!1,this._toolInfos=[],this._translations=S({name:"layer-table",blocking:!0}),this._fullTextSearchInfo=[],this._searchPlaceHolder="",this._size=0,this._queryingData=!1,this._editEnabled=!1,this._enabledLayerIds=[],this._defaultGlobalIdHonored=!1,this._defaultOidHonored=!1,this._deleteEnabled=!1,this._floorExpression="",this._floorField="",this._floorLevel="",this._loaded=!1,this._shareNode=f(),this._toolbar=f(),this._searchExpression="",this._skipEditCheck=!1,this._tempSelectedIds=[],this._outOFExtentOids=[],this._shouldUpdateTableOnExtentChange=!0,this._creatingFeature=!1,this._searchNode=f(),this.columnReorder=p(),this.featureSelectionChange=p(),this.toggleFilter=p(),this.showDelete=p(),this.relatedRecordToggled=p(),this.editMultipleFeatures=p(),this.listenOn(window,"beforeMapInfoChange",this.beforeMapInfoChange,{capture:!0}),this.listenOn(window,"editorInitialized",this.editorInitialized),this.listenOn(window,"closeEdit",this.closeEdit),this.listenOn(window,"selectionChanged",this.selectionChanged),this.listenOn(window,"beforeLayerSelectionChange",this.beforeLayerSelectionChange),this.listenOn(window,"layerSelectionChange",this.layerSelectionChange),this.listenOn(window,"editsComplete",this.editsComplete),this.listenOn(window,"facilityChanged",this.facilityChanged),this.listenOn(window,"levelChanged",this.levelChanged),this.listenOn(window,"siteChanged",this.siteChanged),this.listenOn(window,"noLayersFound",this.noLayersFound),this.listenOn(window,"clearSelection",this.clearSelection),this.listenOn(window,"mapChanged",this.mapChanged),this.listenOn(window,"featuresSelected",this.featuresSelected),this.listenOn(window,"createWorkFlowStarted",this.createWorkFlowStarted),this.listenOn(window,"backFromCreateWorkFlow",this.backFromCreateWorkFlow),H(window)}static{this.properties={appLayout:1,defaultGlobalId:0,defaultLayerId:1,defaultOid:0,enableAutoRefresh:5,enableColumnReorder:5,enableCSV:5,enableInlineEdit:5,enableShare:5,enableTableAutosave:5,featureSelectionMode:1,selectedRelatedIds:0,honorMapFieldSettings:5,isMobile:5,mapHidden:5,mapInfo:0,mapView:0,showOnlyUpdatableLayers:5,selectedIds:0,shareIncludeEmbed:5,shareIncludeSocial:5,showNewestFirst:5,zoomAndScrollToSelected:5,zoomToScale:9,_allIds:16,_configLayerOrderDefined:16,_csvExporting:16,_fetchingData:16,_hideTable:16,_filterActive:16,_layer:16,_selectAllActive:16,_showHideOpen:16,_showOnlySelected:16,_toolInfos:16,_translations:16,_fullTextSearchInfo:16,_searchPlaceHolder:16,_size:16,_queryingData:16}}static{this.styles=R}static{this.shadowRootOptions=T}willUpdate(e){if(e.has("appLayout")&&this.appLayoutWatchHandler(),e.has("defaultOid")&&this.defaultOidWatchHandler(),e.has("defaultGlobalId")&&this.defaultGlobalIdWatchHandler(),e.has("enableCSV")&&this.enableCSVWatchHandler(),e.has("enableInlineEdit")&&this.enableInlineEditWatchHandler(),e.has("mapHidden")&&this.mapHiddenWatchHandler(),e.has("isMobile")&&this.isMobileWatchHandler(),e.has("mapInfo")&&this.mapInfoWatchHandler(),e.has("mapView")&&this.mapViewWatchHandler(),e.has("_layer")&&this._layerWatchHandler(),e.has("selectedIds")&&(this.hasUpdated||JSON.stringify(e.get("selectedIds"))!==JSON.stringify(this.selectedIds))&&this.selectedIdsWatchHandler(),e.has("selectedRelatedIds")&&(this.hasUpdated||JSON.stringify(e.get("selectedRelatedIds"))!==JSON.stringify(this.selectedRelatedIds))&&this.selectedRelatedIdsWatchHandler(),e.has("enableTableAutosave")&&this.hasUpdated&&this._table&&(this._table.autoSaveEnabled=this.enableTableAutosave),e.has("_translations")){let t=this._translations._lang,i=e.get("_translations")?._lang;t&&i&&t!==i&&this._initToolInfos()}}async appLayoutWatchHandler(){await this._initToolInfos(),this._updateShareUrl()}async defaultOidWatchHandler(){await this._handleDefaults()}async defaultGlobalIdWatchHandler(){await this._handleDefaults()}async enableCSVWatchHandler(){this._toolInfos?.length>0&&await this._initToolInfos()}enableInlineEditWatchHandler(){this._table&&(this._table.editingEnabled=this._editEnabled&&this.enableInlineEdit)}async mapHiddenWatchHandler(){this._toolInfos?.length>0&&await this._initToolInfos()}async isMobileWatchHandler(){!this._toolInfos&&!this.isMobile&&await this._initToolInfos()}async mapInfoWatchHandler(){this._configLayerOrderDefined="configLayerOrder"in(this.mapInfo?.layerOptions||{}),this._enabledLayerIds=F(this.mapInfo?.layerOptions?.layers||[],this.mapInfo?.layerOptions?.configLayerOrder),this._table&&(this._resetColumnTemplates(),this._sortTable())}async mapViewWatchHandler(){this._mapClickHandle&&this._mapClickHandle.remove(),this.mapView&&(this._floorExpression="",this._searchExpression="undefined",this.mapView.highlights=[{name:"default",color:"#00FFFF"},{name:"current-selection",color:"#ff00ff"},{name:"temporary",color:"#FFFF00"}],this._updateShareUrl(),this._mapClickHandle=c.on(()=>this.mapView,"click",e=>{this._creatingFeature||this._mapClicked(e)}))}async _layerWatchHandler(){if(this._hideTable=!1,this._fetchingData=!0,!this._layer){this._fetchingData=!1,this._hideTable=!0;return}try{await this._layer.when(),this._floorField=this._layer.floorInfo?.floorField||"",this._updateFloorDefinitionExpression(),await this._resetTable(),this._updateShareUrl()}catch(e){console.error(e),this._hideTable=!0}finally{this._fetchingData=!1}}async selectedIdsWatchHandler(){this._updateShareUrl(),this._validateEnabledActions(),this._selectAllActive&&this.selectedIds.length!==this._allIds.length&&(this._selectAllActive=!1),this.selectedIds.length>0&&(this._table.rowHighlightIds.removeAll(),this._table.rowHighlightIds.add(this.selectedIds[0])),this.selectedIds.length===0&&setTimeout(()=>{this.featureSelectionChange.emit(this.selectedIds)},700)}async selectedRelatedIdsWatchHandler(){this._validateEnabledActions(),this.selectedRelatedIds.length>0&&(this._relatedFeatureTable?.rowHighlightIds.removeAll(),this._relatedFeatureTable?.rowHighlightIds.add(this.selectedRelatedIds[0]))}async closeFilter(){await this._closeFilter()}async filterReset(){this._filterByExtentHandle&&(this._table&&(this._table.filterGeometry=void 0),this._filterByExtentHandle.remove(),this._filterByExtentHandle=void 0),await this._handleFilterListReset()}async filterUpdate(e,t){await this._handleFilterUpdate(e),t?(this._shouldUpdateTableOnExtentChange=!0,this._handleTableOnMapExtent()):t===!1&&(this._table&&(this._table.filterGeometry=void 0),this._filterByExtentHandle?.remove(),this._filterByExtentHandle=void 0,await this._updateAllIds())}async validateTableUpdate(e){this._shouldUpdateTableOnExtentChange=e}async validateActiveEdits(){return this._validateActiveEdits([],this.selectedIds)}async refresh(){this._table&&await this._refresh()}async setColumnOrder(e){this._setColumnTemplates(e)}async beforeMapInfoChange(e){let t=e.detail.ref,i=e.detail.mapInfo;if(this._hasPendingEdits()){e.preventDefault();let s=await this._validateActiveEdits([],this.selectedIds);await t.setMapByID(s?i.id:e.detail.currentId,!s)}}async editorInitialized(e){this._shouldUpdateTableOnExtentChange=!1,this._editor=e.detail}async closeEdit(){this._shouldUpdateTableOnExtentChange=!0,this._filterByExtentHandle&&this._handleTableOnMapExtent()}async selectionChanged(e){let t=e.detail.selectedFeature[0],i=Number(t.getObjectId()),s=this._table;if(s.rowHighlightIds.length&&s.rowHighlightIds.removeAll(),s.rowHighlightIds.add(i),this._highlightFeatures(i),this.zoomAndScrollToSelected&&s&&this.mapView){let a=s.viewModel.getObjectIdIndex(i);s.scrollToIndex(a);let l=t.layer,h=this.mapView.allLayerViews.toArray(),n;h.some(async r=>r.layer.title===l?.title&&r.layer.type==="feature"?(n=r,this.mapView&&await y([i],n,this.mapView,!0,void 0,this.zoomToScale),!0):!1)}}async beforeLayerSelectionChange(e){if(this._hasPendingEdits()){e.preventDefault();let t=e.detail.ref,i=await this._validateActiveEdits([],this.selectedIds);return e.detail.selectedIds?await t.setLayerByIds(i?e.detail.newIds:e.detail.currentIds,!0):await t.setLayerById(i?e.detail.newId:e.detail.currentId,!0)}}async layerSelectionChange(e){await this._layerSelectionChanged(e)}async editsComplete(e){let t=e.detail;(t==="delete"||t==="add")&&(this._allIds=await this.queryAllIds()),await this._refresh()}async facilityChanged(e){this._updateFloorDefinitionExpression()}async levelChanged(e){this._floorLevel=e.detail,this._updateFloorDefinitionExpression()}async siteChanged(e){this._updateFloorDefinitionExpression()}async noLayersFound(){this._layer=void 0,this._allIds=[],this._size=0,this._clearSelection()}async clearSelection(){await this._validateActiveEdits([],this.selectedIds)&&this._clearSelection()}async mapChanged(){this._queryingData=!1,this._creatingFeature=!1,this._clearSelection()}async featuresSelected(e){e.detail.forEach(t=>{let i=this._table?.highlightIds.indexOf(t);i&&i<0&&this._table?.highlightIds.add(t)})}createWorkFlowStarted(){this._creatingFeature=!0}backFromCreateWorkFlow(){this._creatingFeature=!1}async load(){await this._initToolInfos()}render(){let e=this._fetchingData||this._hideTable?"display-none":"",t=this._fetchingData?"":"display-none",i=this._queryingData?"":"display-none",s=this._size.toString(),a=this.selectedIds.length.toString(),l=this.isMobile?"height-full":"height-full-adjusted",h=this._canShowFullTextSearch();return this._validateActiveActions(),o`<div><calcite-scrim class=${b(i)} .loading=${this._queryingData}></calcite-scrim><calcite-shell><div class=${`width-full ${l}`}><calcite-panel class="height-full width-full panel-header-override">${this._getMapLayerPicker("header-actions-start")}${!this.isMobile&&o`${this._getTableControlRow("header-content")}${this._getActionsEnd("header-actions-end")}`||""}${h&&o`<div class="search-container border-bottom"><calcite-input class=search clearable icon=search @calciteInputChange=${n=>{this._searchTextChanged(n)}} .placeholder=${this._searchPlaceHolder} title=${this._searchPlaceHolder??_} type=search ${g(this._searchNode)}></calcite-input></div>`||""}<calcite-loader class=${b(t)} .label=${this._translations.fetchingData} scale=l></calcite-loader><div class=${b(e)} ${g(this.onTableNodeCreate)}></div></calcite-panel></div>${this.isMobile?void 0:o`<div class="bottom-left text-color height-19" id=solutions-selected-count-div>${(this._translations.recordsTotal?.replace("{{total-number-of-records}}",s)+" | "+this._translations.recordsSelected.replace("{{selected-number-of-records}}",a)).replace("{{total}}",s).replace("{{selected}}",a)}</div>`}</calcite-shell></div>`}updated(){this._table&&this.updateRelatedAttachmentColumns()}async _searchTextChanged(e){this._fullTextSearchInfo.forEach(t=>{t.searchTerm=e.target.value}),this._searchFullText()}async _searchFullText(){let e=[],t=!1;if(this._showOnlySelected)e=this._tempSelectedIds,t=!0;else if(await this._validateActiveEdits([],this.selectedIds))this._clearSelection(),this._tempSelectedIds=[];else return;this._searchExpression&&this._clearSearchDefinitionExpression();let i=[];if(this._fullTextSearchInfo?.length&&this._fullTextSearchInfo[0].searchTerm){let s=this._layer?.createQuery();s.fullText=this._fullTextSearchInfo,i=this._layer?await this._layer.queryObjectIds(s):[],t&&e?.length&&(i=i.filter(a=>e.includes(a))),await this._updateSearchDefinitionExpression(i?.length?i:[-1])}t&&i?.length&&(this._showOnlySelected=!0,this._table?.highlightIds.addMany(i.reverse())),await new Promise(s=>setTimeout(s,800)),await this._updateAllIds()}_clearSearchDefinitionExpression(){let e=this._layer?.definitionExpression;this._searchExpression&&e&&e?.indexOf(this._searchExpression)>-1&&this._layer&&(e?.indexOf(" AND ("+this._searchExpression)>-1?this._layer.definitionExpression=e.replace(` AND (${this._searchExpression})`,""):this._layer.definitionExpression=e.replace(this._searchExpression,"")),this._searchExpression=""}async _updateSearchDefinitionExpression(e){let t=this._layer?.definitionExpression;if(this._layer)if(e?.length){let i=`objectId in(${e})`;this._layer.definitionExpression=this._searchExpression&&t&&t.includes(this._searchExpression)?t.replace(this._searchExpression,i):t?`${t} AND (${i})`:i,this._searchExpression=i}else this._clearSearchDefinitionExpression()}_canShowFullTextSearch(){return this._layer?.capabilities?.query?.supportsFullTextSearch&&this._layer.indexes.items.filter(e=>e.indexType=="FullText").length>0}_getFullTextSearchInfo(){if(this._fullTextSearchInfo=[],this._layer?.capabilities?.query?.supportsFullTextSearch){let e=this._layer.indexes?.filter(t=>t.indexType=="FullText");if(e?.length){let t=[];e.forEach(s=>{t.push(...s.fields.split(","))});let i=[];t.forEach(s=>{let a=this._layer?.getField(s.trim());a?.alias&&i.push(a.alias)}),this._searchPlaceHolder=this._translations.searchPlaceholder.replace("{{field_names}}",i.join(", ")),this._fullTextSearchInfo.push({onFields:["*"],searchTerm:"",searchType:"prefix"})}}}_getMapLayerPicker(e){let t=this.isMobile?"display-none":"";return o`<div class=${`border-end ${t}`} id=solutions-map-layer-picker-container slot=${e??_}><map-layer-picker appearance=transparent .configLayerOrderDefined=${this._configLayerOrderDefined} .defaultLayerId=${this.defaultLayerId} display=inline-flex .enabledLayerIds=${this._enabledLayerIds} height=50 .isMobile=${this.isMobile} .mapView=${this.mapView} .showOnlyUpdatableLayers=${this.showOnlyUpdatableLayers} placeholder-icon=layers scale=l .selectedIds=${this._layer?[this._layer?.id]:[]} show-single-layer-as-label show-tables type=dropdown></map-layer-picker></div>`}_getLayerOption(e){let t;return this.mapInfo?.layerOptions?.layers.some(i=>i.id===e?(t=i,!0):!1),t}_getActionsEnd(e){let t=this._relatedFeatureTable?this._relatedFeatureTable.layer:this._layer,i=this._relatedFeatureTable||this._table,s=this._getLayerOption(t?.id||"");return o`<div class="display-flex" slot=${e??_}><field-selection .configExtraFields=${s?.extraFields} .layer=${t} .mapView=${this.mapView} .table=${i} .tableRef=${this.el}></field-selection>${this.enableShare&&!this.isMobile?this._getShare("share"):void 0}</div>`}_getTableControlRow(e){return o`<div class=${"height-51-px width-full display-flex"} slot=${e??_} ${g(this._toolbar)}>${this._getActionBar()}</div>`}_getActionBar(){return o`<calcite-action-bar class=width-full expand-disabled id=${this._getId("bar")??_} layout=horizontal><calcite-action-group>${this.isMobile?void 0:this._getActions()}</calcite-action-group></calcite-action-bar>`}_getActions(){return this._toolInfos?.reduce((e,t)=>(t&&e.push(t.isDanger?this._getDangerAction(t.icon,t.label,t.func,t.disabled):this._getAction(t.active,t.icon,t.indicator,t.label,t.func,t.disabled,!!t.loading,t.toolTip)),e),[])}_validateEnabledActions(){let e=this._getIds().length,t=["zoom-to-object","pencil","trash","erase","selected-items-filter"];this._toolInfos?.forEach(i=>{i&&t.indexOf(i.icon)>-1&&(i.disabled=i.icon==="pencil"?e<2||e>m:e<1,i.toolTip=i.icon==="pencil"?e>m?this._translations.featureEditLimitNotice:this._translations.editMultiple:i.toolTip)})}_validateActiveActions(){let e=["filter","list-check-all","selected-items-filter"];this._toolInfos?.forEach(t=>{t&&e.indexOf(t.icon)>-1&&(t.icon==="filter"&&(t.indicator=this._filterActive),t.icon==="list-check-all"&&(t.active=this._selectAllActive),t.icon==="selected-items-filter"&&(t.active=this._showOnlySelected,t.label=this._showOnlySelected?this._translations.showAll:this._translations.showSelected))})}async _initToolInfos(){let e=this._getIds().length>0,t=this._relatedFeatureTable?this._relatedFeatureTable.layer.isTable:this._layer?.isTable,i=this.featureSelectionMode==="multiple"&&this._layer?.capabilities?.operations.supportsUpdate,s=this._getSelectedIds().length<2||this._getSelectedIds().length>m,a=!this.mapHidden&&!t,l=!this._relatedFeatureTable&&(!this._layer?.isTable||this._hasFilterExpressions()),h=this._featuresEmpty(),n=this.featureSelectionMode==="single",r=this.enableCSV;if(this._relatedFeatureTable){let u=await this._queryRelatedFeatures();r=u&&Object.keys(u).length>0}let d=[];l&&d.push({active:!1,icon:"filter",indicator:!1,label:this._translations.filters,func:()=>this.toggleFilter.emit(),disabled:!1,toolTip:this._translations.filters}),a&&d.push({active:!1,icon:"zoom-to-object",indicator:!1,label:this._translations.zoom,func:()=>this._zoom(),disabled:!e,toolTip:this._translations.zoom}),i&&d.push({active:!1,icon:"pencil",indicator:!1,label:this._translations.editMultiple,func:()=>this.editMultipleFeatures.emit(this._getSelectedIds()),disabled:s,toolTip:this._translations.editMultiple}),this._deleteEnabled&&d.push({active:!1,icon:"trash",indicator:!1,label:this._translations.delete,func:()=>this._showDelete(),disabled:!e,isDanger:!0,toolTip:this._translations.delete}),d.push({active:!1,icon:"erase",indicator:!1,label:this._translations.clearSelection,func:()=>{this.clearSelection()},disabled:!e,toolTip:this._translations.clearSelection}),this._relatedFeatureTable||d.push({active:!1,icon:"selected-items-filter",indicator:!1,label:this._showOnlySelected?this._translations.showAll:this._translations.showSelected,func:()=>this._toggleShowSelected(),disabled:!e,toolTip:this._showOnlySelected?this._translations.showAll:this._translations.showSelected}),!n&&!this._relatedFeatureTable&&d.push({active:!1,icon:"list-check-all",indicator:!1,func:async()=>await this._selectAll(),label:this._translations.selectAll,disabled:h,toolTip:this._translations.selectAll}),!n&&!this._relatedFeatureTable&&d.push({active:!1,icon:"compare",indicator:!1,func:async()=>await this._switchSelected(),label:this._translations.switchSelected,disabled:h,toolTip:this._translations.switchSelected}),d.push({active:!1,icon:"refresh",indicator:!1,func:()=>{this._refresh()},label:this._translations.refresh,disabled:!1,toolTip:this._translations.refresh}),r&&d.push({active:!1,icon:"export",indicator:!1,func:()=>{this._exportToCSV()},label:this._translations.exportCSV,loading:this._csvExporting,disabled:h,toolTip:this._translations.exportCSV}),this._toolInfos=[...d]}_updateFloorDefinitionExpression(){if(this._floorField&&this._floorLevel){let e=`${this._floorField} = '${this._floorLevel}'`,t=this._layer?.definitionExpression;this._layer&&(this._layer.definitionExpression=t&&this._floorExpression&&t?.indexOf(this._floorExpression)>-1?t.replace(this._floorExpression,e):t?`${t} AND (${e})`:e),this._floorExpression=e}}_featuresEmpty(){return this._allIds?.length===0}_hasFilterExpressions(){let e=[],t=this._layer?.id;return this.mapInfo?.filterConfig?.layerExpressions&&t!==void 0&&(e=this.mapInfo.filterConfig.layerExpressions.filter(i=>i.id===t)),e.length>0}_getAction(e,t,i,s,a,l,h,n){let r=this._layer===void 0?!0:l;return o`<calcite-action .active=${e} appearance=solid .disabled=${r} .icon=${t} .id=${`layer-table-${t}`} .indicator=${i} .label=${s} .loading=${h} @click=${a} text text-enabled><div class="display-flex"><span class="label-override padding-start-1-4">${s}</span></div></calcite-action>${this._getToolTip("auto",`layer-table-${t}`,n)}`}_showDelete(){this.showDelete.emit({ids:this._getIds()})}_getShare(e){return o`<div id=${this._getId(e)??_}><instant-apps-social-share class="height-51 width-51 display-flex" .embed=${this.shareIncludeEmbed} flip-rtl popover-button-icon-scale=s scale=m share-button-color=neutral share-button-type=action .socialMedia=${this.shareIncludeSocial} .view=${this.mapView} ${g(this._shareNode)}></instant-apps-social-share>${this._getToolTip("bottom",e,this._translations.share)}</div>`}_updateShareUrl(){let e=this._shareNode.value?.shareUrl;if(!e)return;let t=new URL(e);this.mapInfo?.id?t.searchParams.set("webmap",this.mapInfo.id):t.searchParams.delete("webmap"),this._layer?.id?t.searchParams.set("layer",this._layer.id):t.searchParams.delete("layer"),this.selectedIds?.length>0?t.searchParams.set("oid",this.selectedIds.reverse().join(",")):t.searchParams.delete("oid"),this.appLayout&&t.searchParams.set("applayout",this.appLayout),this.selectedRelatedIds?.length>0&&this._relatedFeatureTable?.layer?.id&&(t.searchParams.set("oid",this.selectedRelatedIds.join(",")),t.searchParams.set("layer",this._relatedFeatureTable?.layer?.id.toString())),this._shareNode.value&&(this._shareNode.value.autoUpdateShareUrl=!1,this._shareNode.value.shareUrl=t.href)}_getToolTip(e,t,i){return o`<calcite-tooltip .placement=${e} .referenceElement=${t}><span>${i}</span></calcite-tooltip>`}_getId(e){return`solutions-action-${e}`}_getDangerAction(e,t,i,s){let a=this._layer===void 0?!0:s;return o`<div class="display-flex" id=${this._getId(e)??_}>${o`<calcite-action appearance=solid .disabled=${a} .id=${`layer-table-${e}`} @click=${i} text><calcite-icon class="danger-icon-color" .icon=${e} scale=s></calcite-icon><span class="label-override padding-start-1-4 danger-label-color">${t}</span></calcite-action>`}${this._getToolTip("bottom",`layer-table-${e}`,t)}</div>`}_getIds(){let e=this._relatedFeatureTable??this._table;return this._relatedFeatureTable&&this._table&&this._table.highlightIds.getItemAt(0)!==this.selectedIds[0]&&(e=this._table),e?.highlightIds.map(t=>Number.parseInt(t.toString(),10)).toArray()??[]}onTableNodeCreate(e){this._tableNode=e}async _getTable(e,t){this._layer&&(await this._layer.when(()=>{this._table=new L({autoRefreshEnabled:this.enableAutoRefresh,autoSaveEnabled:this.enableTableAutosave,layer:this._layer,view:this.mapView,columnReorderingEnabled:this.enableColumnReorder,editingEnabled:this._editEnabled&&this.enableInlineEdit,relatedRecordsEnabled:!0,attachmentsEnabled:!0,highlightEnabled:!1,multiSortEnabled:!1,visibleElements:{columnDescriptions:!1,header:!1,menu:!1,progress:!1},tableTemplate:{columnTemplates:t},container:e})}),await this._table?.when(()=>{this._table?.viewModel.addHandles(this._table.highlightIds.on("change",i=>{this._handleOnChange(i)})),this._table?.viewModel.addHandles(this._table.on("cell-pointerover",this.tempHighlightOnHover.bind(this))),this._table?.viewModel.addHandles(this._table.on("cell-pointerout",this._removeTempHighlight.bind(this))),this._table?.viewModel.addHandles(this._table.on("column-reorder",this._handleColumnReorder.bind(this))),this.listenOn(this._tableNode,"mouseleave",this._removeTempHighlight),this._table?.viewModel.addHandles(c.watch(()=>this._table.size,i=>{this._size=i})),c?.watch(()=>this._table?.relatedTable,async i=>{if(i){if(i.rowHighlightIds.length){let a={added:[i.rowHighlightIds.getItemAt(0)],removed:[]};this._handleOnChange(a)}let s=i.layer;if(this._layerEditHandle=s.on("edits",async()=>{await new Promise(a=>setTimeout(a,50)),await this._refresh(!0)}),this._checkEditEnabled(s),i.editingEnabled=this._editEnabled&&this.enableInlineEdit,i.autoSaveEnabled=this.enableTableAutosave,this._relatedFeatureTable=i,typeof i.layer?.id=="string"&&i.layer?.fields){let a=i.layer.popupTemplate?.fieldInfos,l=this._getColumnTemplates(i.layer.id,i.layer.fields,a);this._relatedFeatureTable.tableTemplate=new w({columnTemplates:l})}i.highlightIds.on("change",a=>{this._handleRelatedRecordsChange(a)})}else{this.selectedRelatedIds=[],this._relatedFeatureTable=void 0,this._layerEditHandle&&this._layerEditHandle.remove();let s=this._layer;this._refresh(),s&&this.relatedRecordToggled.emit(s),this._finishOnChange()}await this._initToolInfos()})}))}async _handleRelatedRecordsChange(e){await this._handleOnChange(e),this._updateShareUrl()}hasAttachmentsEnabled(e){if(!e?.capabilities)return!1;let{capabilities:{data:{supportsAttachment:t},operations:{supportsQueryAttachments:i}}}=e;return t&&i}async _handleOnChange(e){if(!await this._validateActiveEdits([...e.added],[...e.removed]))return;let t=[...this._getIds()],i=this._getSelectedLayer(t);this._relatedFeatureTable&&this._table?.highlightIds.getItemAt(0)!==this.selectedIds[0]&&(i=this._layer,await this._initToolInfos()),i&&this.relatedRecordToggled.emit(i),this.featureSelectionMode==="single"&&(this._relatedFeatureTable&&t.length>1?(this._relatedFeatureTable.highlightIds.remove(t[0]),t.shift()):t.length>1&&!this._selectAllActive&&(this._table?.highlightIds.remove(t[0]),t.shift())),!this._relatedFeatureTable||this._relatedFeatureTable&&this._table?.highlightIds.getItemAt(0)!==this.selectedIds[0]?(this.selectedRelatedIds=[],this.selectedIds=t.reverse(),this._tempSelectedIds=[...this.selectedIds],this._highlightFeatures(this.selectedIds[0])):this.selectedRelatedIds=t.reverse(),this._finishOnChange()}async _validateActiveEdits(e,t){let i=!0;if(this._editor&&!this._skipEditCheck){if(this._hasPendingEdits()){let s=!1;try{this._editor.viewModel.activeWorkflow&&await this._editor.viewModel.activeWorkflow.cancel({force:!1})}catch(a){s=a?.name==="workflow:cancel-denied"}if(s){let a=this._relatedFeatureTable&&this._relatedFeatureTable.highlightIds.length>0?this._relatedFeatureTable:this._table;i=!1,this._skipEditCheck=!0,e.length>0?a?.highlightIds.removeMany(e):t.length>0&&a?.highlightIds.addMany(t)}}}else i=!this._skipEditCheck,this._skipEditCheck=!1;return this._shouldUpdateTableOnExtentChange=i,i}_hasPendingEdits(){let e=this._editor?.viewModel?.hasPendingEdits,t=this._editor?.activeWorkflow?.activeWorkflow?.hasPendingEdits;return e||t}_finishOnChange(){this._showOnlySelected&&!this._relatedFeatureTable&&(this._table&&this._getSelectedIds().length>0?this._table.filterBySelectionEnabled=!0:this._toggleShowSelected());let e=this._getSelectedIds();setTimeout(()=>{this.featureSelectionChange.emit(e)},50)}_handleColumnReorder(){this.columnReorder.emit()}tempHighlightOnHover(e){if(this._removeTempHighlight(),this._selectedLayerView){let t=e.feature;this._temporaryFeatureHandle=this._selectedLayerView?.highlight([t],{name:"temporary"})}}_removeTempHighlight(){this._temporaryFeatureHandle&&this._temporaryFeatureHandle.remove()}_highlightFeatures(e){if(this._clearHighlights(),this.selectedIds.length>0&&this._selectedLayerView&&(this._currentFeatureHighlightHandle=this._selectedLayerView?.highlight([e],{name:"current-selection"}),this.selectedIds.length>1)){let t=this.selectedIds.filter(i=>i!==e);this._defaultFeaturesHandle=this._selectedLayerView?.highlight(t,{name:"default"})}}_clearHighlights(){this._removeTempHighlight(),this._currentFeatureHighlightHandle&&this._currentFeatureHighlightHandle.remove(),this._defaultFeaturesHandle&&this._defaultFeaturesHandle.remove()}_resetColumnTemplates(){if(this._layer){let e=this._layer.popupTemplate?.fieldInfos,t=this._getColumnTemplates(this._layer.id,this._layer.fields,e);t?.length===0?this._tableNode?.classList.add("display-none"):this._tableNode?.classList.remove("display-none");let i=this._table?.tableTemplate?.columnTemplates,s=i&&t&&i.length!==t.length||t?.some((a,l)=>i&&i[l]?JSON.stringify(i[l])!==JSON.stringify(a):!1);if(this._table&&t&&(s||!this._columnsInfo)){this._table.tableTemplate=new w({columnTemplates:t});let a=t.map(l=>l.fieldName);this._initColumnsInfo(a)}}}_setColumnTemplates(e){this._table&&e&&(this._table.tableTemplate=new w({columnTemplates:e}))}async _resetTable(){if(this._loaded=!1,this._clearSelection(),this._allIds=await this.queryAllIds(),!this._table&&this._layer){let e=this._layer.popupTemplate?.fieldInfos,t=this._getColumnTemplates(this._layer.id,this._layer.fields,e);this._tableNode&&await this._getTable(this._tableNode,t)}else this._table&&(this._table.view=this.mapView,this._table.layer=this._layer);await this._initLayerRefresh(),this._checkEditEnabled(this._layer),this._table&&(this._table.editingEnabled=this._editEnabled&&this.enableInlineEdit,this._table.autoSaveEnabled=this.enableTableAutosave,await this._table.when(),setTimeout(()=>{this._loaded||this.finishLoading()},1e3),await c.once(()=>this._table?.state==="loaded").then(async()=>{await this.finishLoading()}))}async finishLoading(){try{this._loaded=!0,this._table?.highlightIds.removeAll(),this._table.objectIds.removeAll(),this._resetColumnTemplates(),this._showOnlySelected=!1,await this._handleDefaults(),await this._sortTable(),await this._initToolInfos(),["esri-feature-table","esri-widget"].forEach(e=>{this._tableNode&&!this._tableNode.classList.contains(e)&&this._tableNode.classList.add(e)})}catch(e){console.log(e)}}async _initLayerRefresh(){this._refreshHandle&&this._refreshHandle.remove(),this._layer&&(this._refreshHandle=this._layer.on("refresh",e=>{e.dataChanged&&this._updateAllIds()}))}async _updateAllIds(){let e=await this.queryAllIds(),t=this.selectedIds.filter(i=>this._allIds.indexOf(i)>-1);(JSON.stringify(e)!==JSON.stringify(this._allIds)||JSON.stringify(this.selectedIds)!==JSON.stringify(t))&&(this._allIds=e,this.selectedIds=t,await this._refresh())}async _handleDefaults(){if(!this._defaultOidHonored&&this.defaultOid?.length>0&&this.defaultOid[0]>-1&&this._table&&(await this._selectDefaultFeature(this.defaultOid),this._defaultOidHonored=!0,this.defaultOid=[],this._showOnlySelected=!1,this._toggleShowSelected()),!this._defaultGlobalIdHonored&&this.defaultGlobalId&&this.defaultGlobalId?.length>0&&this._table&&this._layer){let e=await O(this.defaultGlobalId,this._layer),t=e?.length>0?e.map(i=>Number(i.getObjectId())):void 0;t&&await this._selectDefaultFeature(t),this._defaultGlobalIdHonored=!0,this.defaultGlobalId=[],this._showOnlySelected=!1,this._toggleShowSelected()}}_initColumnsInfo(e){let t=this._table?.columns.reduce((s,a)=>((!e||e?.indexOf(a.name)>-1)&&(s[a.name]=!a.hidden),s),{}),i=this._table?.columns.map(s=>s.name);(e&&i?e.filter(s=>i.indexOf(s)<0):[]).forEach(s=>{t[s]=!0}),this._columnsInfo=e?e.reduce((s,a)=>(s[a]=t[a],s),{}):t}async _selectDefaultFeature(e){e.length>0&&this._table?.highlightIds.addMany(e)}_checkEditEnabled(e){this._editEnabled=!!(e?.editingEnabled&&e?.capabilities?.operations.supportsUpdate),this._deleteEnabled=!!(e?.editingEnabled&&e?.capabilities?.operations.supportsDelete)}async _sortTable(){let e=this._layer?.objectIdField,t="desc",i,s=this.mapInfo?.layerOptions?.layers,a=this._layer?.id;s&&s.length>0&&a!==void 0&&(i=s.filter(l=>l.id===a),i&&i.length>0&&(i=i[0],i.sortField&&i.fields?.includes(i.sortField)&&(e=i.sortField),t=i?.sortOrder?i.sortOrder:"desc")),this._table&&this._layer&&(await this._table.when(),await this._layer.when(()=>{e&&this._table?.sortColumn(e,t)}))}async _handleFilterListReset(){this._filterActive=!1,this._updateShareUrl(),await this._searchFullText()}async _handleFilterUpdate(e){if(this._floorExpression&&this._layer){let t=this._layer.definitionExpression,i=new RegExp(`${this._floorField} = ['].+[']`,"gm");this._layer.definitionExpression=t&&this._floorField&&t.indexOf(`${this._floorField} = '`)>-1?t.replace(i,this._floorExpression):t?`${t} AND (${this._floorExpression})`:this._floorExpression}this._filterActive=e,this._updateShareUrl(),await this._searchFullText()}_handleTableOnMapExtent(){this._table&&(this._filterByExtentHandle=c.when(()=>this.mapView?.stationary,async()=>{if(this._shouldUpdateTableOnExtentChange&&this.appLayout==="splitView"){if(await new Promise(e=>setTimeout(e,800)),this._table&&this.mapView){this._table.filterGeometry=this.mapView.extent;let e={geometry:this.mapView.extent},t=this._layer&&await this._layer.queryObjectIds(e),i=this.selectedIds.filter(a=>!t?.includes(a)),s=this._outOFExtentOids.filter(a=>t?.includes(a));i.length>0&&(this._table&&this._table?.viewModel?.attachmentsViewOptions?.objectId&&this._table.viewModel.hideAttachmentsView(),this._table.highlightIds.removeMany(i),this._outOFExtentOids=[...this._outOFExtentOids,...i]),s.length>0&&(this.selectedIds=[...new Set([...this.selectedIds,...s])],this._table.highlightIds.removeAll(),this._table.highlightIds.addMany(this.selectedIds.reverse()),this._outOFExtentOids=this._outOFExtentOids.filter(a=>!s.includes(a)))}this._allIds=await this.queryAllIds()}},{initial:!0}))}async _closeFilter(){this._allIds=await this.queryAllIds()}async queryAllIds(){if(this._layer){let e=this._layer.createQuery();return e.geometry=this._filterByExtentHandle&&this.mapView?this.mapView.extent:null,e.where=this._layer.definitionExpression||"1=1",await this._layer.queryObjectIds(e)}else return[]}async _mapClicked(e){let t={include:this._layer},i=await this.mapView?.hitTest(e.screenPoint,t);if(i&&i.results.length>0){let s=i.results;if(this.featureSelectionMode==="single"){this._table?.highlightIds.removeAll();let a=s[0].graphic.getObjectId();if(a){let l=this._table?.highlightIds.indexOf(a);l!==void 0&&l<0&&this._table?.highlightIds.add(a)}}else s.forEach(a=>{let l=Number(a.graphic.getObjectId()),h=this._table?.highlightIds.indexOf(l);h&&h<0&&l&&this._table?.highlightIds.add(l)});this._showOnlySelected&&this._table&&(this._table.filterBySelectionEnabled=!0)}else await this.clearSelection()}async _selectAll(){let e=this._allIds,t=e.filter(i=>this.selectedIds.indexOf(i)<0);await this._validateActiveEdits(t,this.selectedIds)&&this._table?(this._table.highlightIds.removeAll(),this._table.highlightIds.addMany(e),this.selectedIds=e,this._finishOnChange(),this._selectAllActive=!0):this._skipEditCheck=!1}_toggleShowSelected(){this._showOnlySelected=!this._showOnlySelected,this._table&&(this._table.filterBySelectionEnabled=this._showOnlySelected)}_clearSelection(){this._relatedFeatureTable||(this.selectedIds=[],this._outOFExtentOids=[],this._table&&this._table?.viewModel?.attachmentsViewOptions?.objectId&&this._table.viewModel.hideAttachmentsView(),this._table?.highlightIds.removeAll(),this._clearHighlights(),this._table?.rowHighlightIds.removeAll()),this._relatedFeatureTable&&(this._relatedFeatureTable?.highlightIds.removeAll(),this.selectedRelatedIds=[]),this._finishOnChange()}async _switchSelected(){let e=[...this.selectedIds],t=this._allIds.reduce((i,s)=>(e.indexOf(s)<0&&i.push(s),i),[]).sort((i,s)=>i-s);await this._validateActiveEdits(t,e)&&this._table?(this._table.highlightIds.removeAll(),this._table.highlightIds.addMany(t),this.selectedIds=t,this._finishOnChange()):this._skipEditCheck=!1}async _exportToCSV(){let e=this._relatedFeatureTable?this._relatedFeatureTable.layer:this._layer;if(!e)return;let t={},i=this._getIds();if(this._relatedFeatureTable?.tableParent&&this._relatedFeatureTable.highlightIds.length===0){let l=this._relatedFeatureTable.tableParent.highlightIds?.getItemAt(0);if(l!==void 0){let h=await this._queryRelatedFeatures(),n=[];h&&h[l]?.features&&(h[l].features.forEach(r=>{r.attributes&&n.push(r.attributes[e.objectIdField])}),i=n.length>0?n:[])}}t[e.id]={selectionSetNames:[e.title||""],ids:i,layer:e};let s=this._relatedFeatureTable??this._table;if(!s)return;let a=s&&s.columns.toArray().reduce((l,h)=>{if(!h.hidden){let n=h?.name||h?.fieldName;n&&l.push(n.toLocaleLowerCase())}return l},[]);this._updateToolInfoLoading("export",!0),this._csvExporting=!0,this.mapView?.map&&await $(this.mapView.map,t,!1,!1,!0,a,!0,!0),this._updateToolInfoLoading("export",!1),this._csvExporting=!1}async _queryRelatedFeatures(){let e=this._relatedFeatureTable?this._relatedFeatureTable?this._relatedFeatureTable.layer:this._relatedFeatureTable.tableParent?.layer:this._layer,t=this._relatedFeatureTable?.tableParent?.highlightIds?.items[0],i=this._relatedFeatureTable?.tableParent?.layer,s=e?.relationships?.find(l=>i.relationships?.some(h=>h.id===l.id)),a=new M({objectIds:[t],outFields:["*"],relationshipId:s?.id});return t&&a&&await i.queryRelatedFeatures(a).catch(async l=>{console.error(l)})}_updateToolInfoLoading(e,t){this._toolInfos.some(i=>i?.icon===e?(i.loading=t,!0):!1)}async _refresh(e){if(await this._validateActiveEdits([],this.selectedIds)){this._table&&await this._table.refresh(),this._relatedFeatureTable&&await this._relatedFeatureTable.refresh(),this._allIds=await this.queryAllIds();let t=this._getSelectedLayer(this.selectedRelatedIds);if(t&&this.relatedRecordToggled.emit(t),!e){let i=this._getSelectedIds();this.featureSelectionChange.emit(i)}}}_getSelectedIds(){let e;return this._relatedFeatureTable?this.selectedRelatedIds.length>0?e=this.selectedRelatedIds:e=this._relatedFeatureTable.tableParent?.highlightIds.toArray()??[]:e=this.selectedIds,e}_getSelectedLayer(e){let t;return this._relatedFeatureTable?e.length>0?t=this._relatedFeatureTable.layer:t=this._relatedFeatureTable.tableParent?.layer:t=this._layer,t}async _clearSearchText(){if(this._searchNode.value){this._searchNode.value.value="";let e={target:{value:""}};await this._searchTextChanged(e)}}async _zoom(){this._layer&&this.mapView&&await y(this.selectedIds,this._selectedLayerView,this.mapView,!0,void 0,this.zoomToScale)}async _layerSelectionChanged(e){let t=e.detail[0];if(t!==this._layer?.id||this._featuresEmpty()){this._fetchingData=!0,await this._clearSearchText();let i=this.mapView&&await A(this.mapView,t);i&&await i.when(async()=>{this._selectedLayerView=!i.isTable&&this.mapView?await C(this.mapView,i.id):null,this._table&&this._table?.viewModel?.attachmentsViewOptions?.objectId&&this._table.viewModel.hideAttachmentsView(),this._shouldUpdateTableOnExtentChange=!0,this._layer=i,await this._initToolInfos(),this._getFullTextSearchInfo()})}this._creatingFeature=!1,this._fetchingData=!1}_getColumnTemplates(e,t,i){let s=this._getLayerOption(e),a=this._layer?.attributeTableTemplate?.elements,l=[];a?.length>0&&this.honorMapFieldSettings&&(l=a.map(r=>r.fieldName));let h=s?.fields&&s?.fieldOrder?s.fieldOrder.filter(r=>s?.fields&&s.fields.indexOf(r)>-1):l.length>0?l:void 0,n;return t&&(n=t.reduce((r,d)=>{let u={type:"field",fieldName:d.name,label:this.getFieldLabel(d,i),menuConfig:this._getMenuConfig(d.name)};return s&&s.fields&&s?.fields?.length>0?s.fields.indexOf(d.name)>-1&&r.push(u):l.length>0?l.indexOf(d.name)>-1&&r.push(u):r.push(u),r},[])),n?h?n?.sort(this._sortFields.bind(this,h)):n:[]}updateRelatedAttachmentColumns(){let e=this._getLayerOption(this._layer?.id||""),t=this.hasAttachmentsEnabled(this._layer),i=!0,s="attachments",a=(e?.extraFields||[]).reduce((h,n)=>(n.startsWith("related:")?h.related.push(n.split("related:")[1]):h.extra.push(n),h),{related:[],extra:[]}),l=a.extra.some(h=>h.toLowerCase()===s);a&&(t=l&&t,i=a.related.length>0,this._table?.columns.forEach(h=>{h.fieldName.startsWith("EsriFeatureTableRelationshipColumn")&&(h.hidden=!a.related.includes(h.effectiveLabel)),h.fieldName.startsWith("EsriFeatureTableAttachmentsColumn")&&(h.hidden=!a.extra.some(n=>n.toLowerCase()===h.effectiveLabel.toLowerCase()))})),this._table.relatedRecordsEnabled=i,this._table.attachmentsEnabled=t}getFieldLabel(e,t){let i=e.alias?e.alias:e.name;return t?.some(s=>s.fieldName===e.name?(i=s.label,!0):!1),i||e.name}_sortFields(e,t,i){return e?.indexOf(t.fieldName)-e.indexOf(i.fieldName)}_getMenuConfig(e){return{items:[{label:this._translations.hideField,icon:"view-hide",autoCloseMenu:!0,clickFunction:()=>{this._handleHideClick(e)}}]}}_handleHideClick(e){this._columnsInfo&&this._table&&(this._columnsInfo[e]=!1,this._table.hideColumn(e),this._table.tableTemplate&&this._table.tableTemplate.columnTemplates.forEach(t=>{t.fieldName===e&&(t.visible=!1)}))}};E("layer-table",I);return I},"widgets/FeatureTable","core/reactiveUtils","rest/support/RelationshipQuery","widgets/FeatureTable/support/TableTemplate",a,c,d,e)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as O}from"./SOHNIGAO.js";import{b as B}from"./7EF56IQP.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{E as L,F as m,G as h,H as U,J as i,K as d,L as E,h as I,i as n,j as w}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";export default $arcgis.t(([M,Q,P,Y,H])=>{var ee=I`:host{display:block;--instant-apps-social-share-action-width: initial;--instant-apps-social-share-width--s: 200px;--instant-apps-social-share-width--m: 280px;--instant-apps-social-share-width--l: 320px;--instant-apps-social-share-width-horizontal--s: 300px;--instant-apps-social-share-width-horizontal--m: 380px;--instant-apps-social-share-width-horizontal--l: 420px;--instant-apps-social-share-background-color: var( --calcite-color-foreground-1 );--instant-apps-social-share-popover-button-background-color: transparent;--instant-apps-social-share-popover-button-icon-color: var( --calcite-icon-color );--instant-apps-social-share-embed-border: 1px solid $border;--instant-apps-social-share-embed-text-area-text: #468540}:host .instant-apps-social-share__popover-button{background-color:var(--instant-apps-social-share-popover-button-background-color)}:host .instant-apps-social-share__popover-button calcite-icon{color:var(--instant-apps-social-share-popover-button-icon-color)}:host .instant-apps-social-share__dialog,:host .instant-apps-social-share__dialog-embed{background-color:var(--instant-apps-social-share-background-color);border:var(--instant-apps-social-share-embed-border)}:host .instant-apps-social-share__dialog{box-sizing:border-box;height:auto;padding:10px 0;border-radius:5px;color:var(--calcite-color-text-1)}:host .instant-apps-social-share__options{margin:0;padding:1% 0 0;list-style-type:none}:host .instant-apps-social-share__options li{box-sizing:border-box;display:flex;align-items:center;width:100%;padding:5%;transition:background-color .15s ease-out 0s}:host .instant-apps-social-share__options li .instant-apps-social-share__icon,:host .instant-apps-social-share__options li .instant-apps-social-share__option-text{display:inline-block}:host .instant-apps-social-share__options li .instant-apps-social-share__icon{display:flex;align-items:center}:host .instant-apps-social-share__options li .instant-apps-social-share__option-text{width:85%;margin-left:10px;word-break:break-word}:host .instant-apps-social-share__options li .instant-apps-social-share__option-text--rtl{margin-left:0;margin-right:10px}:host .instant-apps-social-share__options li:hover{cursor:pointer;background-color:var(--calcite-color-foreground-2)}:host .instant-apps-social-share__options__x-logo--light path{fill:#000}:host .instant-apps-social-share__options__x-logo--dark path{fill:#fff}:host .instant-apps-social-share__tip{box-sizing:border-box;padding:0 5% 1%}:host .instant-apps-social-share__tip-header{display:flex;align-items:center;color:#007ac2;margin:8px 0 5px}:host .instant-apps-social-share__tip-header calcite-icon{margin-right:5px}:host .instant-apps-social-share__tip-content{line-height:17px;margin:0;padding-top:2%}:host .instant-apps-social-share__success{display:flex;flex-direction:column;padding:15px}:host .instant-apps-social-share__success-header{display:flex;align-items:center;font-weight:700;margin-bottom:10px}:host .instant-apps-social-share__success-icon{display:flex;align-items:center;margin-right:5px}:host .instant-apps-social-share__success-icon calcite-icon{color:var(--calcite-color-status-success)}:host .instant-apps-social-share__success-message{line-height:16px}:host .instant-apps-social-share__embed{box-sizing:border-box;width:100%;padding:5%;margin-bottom:10px;border-top:1px solid #d3d3d3}:host .instant-apps-social-share__embed-header{display:flex;align-items:center;margin-bottom:5px}:host .instant-apps-social-share__embed-header calcite-icon{margin-right:5px}:host .instant-apps-social-share__embed-code-text-area{border:1px solid #d3d3d3}:host .instant-apps-social-share__embed-code-text-area textarea{box-sizing:border-box;padding:4%;border:none;resize:none;background:transparent;width:100%;font-family:var(--calcite-sans-family);color:var(--calcite-color-text-1)}:host .instant-apps-social-share__embed-code-text-area button{display:flex;align-items:center;text-align:start;width:100%;border:none;border-top:1px solid #d3d3d3;background-color:transparent;line-height:16px;font-weight:400;padding:3%;color:var(--calcite-color-text-1)}:host .instant-apps-social-share__embed-code-text-area button calcite-icon{color:#007ac2;margin-right:3px}:host .instant-apps-social-share__embed-code-text-area button:hover{cursor:pointer;background-color:var(--calcite-color-foreground-2);transition:background-color .15s ease-out 0s}:host .instant-apps-social-share__embed-text-area-text{display:inline-block;padding-block-start:var(--calcite-spacing-md);font-weight:600;color:var(--instant-apps-social-share-embed-text-area-text)}:host .instant-apps-social-share__embed .instant-apps-social-share__text-area--rtl{text-align:left;direction:ltr}:host .instant-apps-social-share__embed-dimensions{display:flex;justify-content:space-between;margin-top:10px}:host .instant-apps-social-share__embed-dimensions-input{width:47%;box-sizing:border-box}:host .instant-apps-social-share__embed-dimensions-input input{border:1px solid #d3d3d3;width:100%;height:25px;font-family:var(--calcite-sans-family)}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options{display:flex;justify-content:space-around;margin-bottom:8%}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options li{flex-direction:column;padding:0}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options li .instant-apps-social-share__option-text{word-break:break-word;margin-left:0;margin-top:10px;text-align:center}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options li:hover{background-color:unset}:host .instant-apps-social-share__icon-container{display:flex;align-items:center}:host calcite-action{width:var(--instant-apps-social-share-action-width)}:host([scale=s]) .instant-apps-social-share__dialog{width:var(--instant-apps-social-share-width--s)}:host([scale=s]) .instant-apps-social-share__icon{width:16px;height:16px}:host([scale=s]) .instant-apps-social-share__option-text{font-size:var(--calcite-font-size--1)}:host([scale=s]) .instant-apps-social-share__dialog.instant-apps-social-share__layout--horizontal{width:var(--instant-apps-social-share-width-horizontal--s)}:host([scale=s]) .instant-apps-social-share__tip-header,:host([scale=s]) .instant-apps-social-share__tip-content,:host([scale=s]) .instant-apps-social-share__embed-header,:host([scale=s]) .instant-apps-social-share__embed-dimensions-input{font-size:var(--calcite-font-size--2)}:host([scale=m]) .instant-apps-social-share__dialog{width:var(--instant-apps-social-share-width--m)}:host([scale=m]) .instant-apps-social-share__icon{width:24px;height:24px}:host([scale=m]) .instant-apps-social-share__option-text{font-size:var(--calcite-font-size-0)}:host([scale=m]) .instant-apps-social-share__dialog.instant-apps-social-share__layout--horizontal{width:var(--instant-apps-social-share-width-horizontal--m)}:host([scale=m]) .instant-apps-social-share__tip-header,:host([scale=m]) .instant-apps-social-share__tip-content,:host([scale=m]) .instant-apps-social-share__embed-header,:host([scale=m]) .instant-apps-social-share__embed-dimensions-input{font-size:var(--calcite-font-size--1)}:host([scale=l]) .instant-apps-social-share__dialog{width:var(--instant-apps-social-share-width--l)}:host([scale=l]) .instant-apps-social-share__icon{width:32px;height:32px}:host([scale=l]) .instant-apps-social-share__option-text{font-size:var(--calcite-font-size-1)}:host([scale=l]) .instant-apps-social-share__dialog.instant-apps-social-share__layout--horizontal{width:var(--instant-apps-social-share-width-horizontal--l)}:host([scale=l]) .instant-apps-social-share__tip-header,:host([scale=l]) .instant-apps-social-share__tip-content,:host([scale=l]) .instant-apps-social-share__embed-header,:host([scale=l]) .instant-apps-social-share__embed-dimensions-input{font-size:var(--calcite-font-size-0)}`,a="instant-apps-social-share",k=".calcite-mode-dark",t={dialog:`${a}__dialog`,dialogContent:`${a}__dialog-content`,options:`${a}__options`,tipContainer:`${a}__tip`,tipHeader:`${a}__tip-header`,tipContent:`${a}__tip-content`,icon:`${a}__icon`,iconContainer:`${a}__icon-container`,optionText:`${a}__option-text`,popoverButton:`${a}__popover-button`,layout:{vertical:`${a}__layout--vertical`,horizontal:`${a}__layout--horizontal`},xLogo:{light:`${a}__x-logo--light`,dark:`${a}__x-logo--dark`},success:{container:`${a}__success`,header:`${a}__success-header`,message:`${a}__success-message`,icon:`${a}__success-icon`},embed:{container:`${a}__embed`,header:`${a}__embed-header`,embedCode:{container:`${a}__embed-code`,textArea:`${a}__embed-code-text-area`,copyButton:`${a}__embed-code-copy-button`},textAreaText:`${a}__embed-text-area-text`,dimensions:{container:`${a}__embed-dimensions`,input:`${a}__embed-dimensions-input`}},rtl:{optionText:`${a}__option-text--rtl`,textArea:`${a}__text-area--rtl`}},te={facebook:"https://www.facebook.com/sharer/sharer.php?u={url}",x:"https://x.com/intent/post?url={url}",linkedIn:"https://www.linkedin.com/sharing/share-offsite/?text={url}",bluesky:"https://bsky.app/intent/compose?text={url}"},T=1,z=class extends U{constructor(){super(...arguments),this._messages=O({name:"instant-apps-social-share"}),this.popoverRef=m(),this.embedWidthRef=m(),this.embedHeightRef=m(),this.embedCodeRef=m(),this.copyLinkPopoverRef=m(),this.copyEmbedPopoverRef=m(),this.dialogContentRef=m(),this.shareListRef=m(),this.popoverButtonRef=m(),this.handlePopoverRefKeyDown=async e=>{if(!this.isNativeShareEnabled)if(e.code==="Tab"){if(!this.shareListRef.value)return;let s=e.target,o=this.shareListRef.value.children[0],r=this.shareListRef.value.children[this.shareListRef.value.children.length-1];e.shiftKey&&s===o?(e.preventDefault(),r.focus()):!e.shiftKey&&s===r&&(e.preventDefault(),o.focus())}else e.code==="Escape"&&(this.closePopover(),await this.popoverButtonRef.value?.setFocus())},this.stopEventPropagation=e=>{e.stopPropagation()},this.autoCloseCallback=()=>{this.mode==="popover"&&this.popoverRef.value?(this.isPopoverOpen=!1,this.popoverRef.value.open=this.isPopoverOpen):(this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!1),this.inlineCopyLinkOpened=!1,this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!1),this.inlineCopyEmbedOpened=!1)},this.resetPopoverCopyState=async()=>{await this.popoverButtonRef.value?.setFocus(),setTimeout(()=>{this.isLinkCopiedToClipboard=!1,this.isEmbedCopiedToClipboard=!1},200)},this.isPopoverOpen=!1,this.isLinkCopiedToClipboard=!1,this.isEmbedCopiedToClipboard=!1,this.inlineCopyLinkOpened=!1,this.inlineCopyEmbedOpened=!1,this.embedWidth=400,this.embedHeight=600,this.mode="popover",this.shareUrl=window.location.href,this.autoUpdateShareUrl=!0,this.shareText="",this.embed=!1,this.shareButtonColor="neutral",this.shareButtonType="button",this.shareButtonScale="m",this.iframeInnerText="",this.popoverButtonIconScale="m",this.displayTipText=!0,this.shortenShareUrl=!0,this.socialMedia=!0,this.shareIconsLayout="vertical",this.scale="m",this.successMessage="",this.flipRtl=!1,this.defaultUrlParams=null,this.inlineSuccessPopoverPlacement="trailing",this.popoverPositioning="absolute",this.removePopoverOffset=!1,this.useNativeShare=!1,this.isNativeShareEnabled=!1}static{this.properties={isPopoverOpen:16,isLinkCopiedToClipboard:16,isEmbedCopiedToClipboard:16,inlineCopyLinkOpened:16,inlineCopyEmbedOpened:16,embedWidth:16,embedHeight:16,mode:3,shareUrl:1,autoUpdateShareUrl:5,shareText:3,embed:7,shareButtonColor:3,shareButtonType:3,shareButtonScale:3,iframeInnerText:3,popoverButtonIconScale:3,view:0,displayTipText:7,shortenShareUrl:7,socialMedia:7,shareIconsLayout:3,scale:3,successMessage:3,flipRtl:7,defaultUrlParams:0,inlineSuccessPopoverPlacement:3,popoverPositioning:3,removePopoverOffset:7,useNativeShare:7,isNativeShareEnabled:7}}static{this.styles=ee}load(){document.documentElement.addEventListener("click",this.autoCloseCallback),this.isNativeShareEnabled=this.useNativeShare&&this.isMobileDevice}disconnectedCallback(){super.disconnectedCallback(),document.documentElement.removeEventListener("click",this.autoCloseCallback)}makeOptionKeyDownHandler(e){return async s=>{let o=s.code;(o==="Space"||o==="Enter")&&await this.handleShareItem(e)}}makeEmbedResizeHandler(e){let s=e==="width"?this.embedWidthRef.value:this.embedHeightRef.value;return()=>{if(!(!this.embed||this.isNativeShareEnabled)&&s){let o=Math.max(s.valueAsNumber??0,T);this[e==="width"?"embedWidth":"embedHeight"]=o}}}togglePopoverVisibility(e){e.stopPropagation(),this.isPopoverOpen=!this.isPopoverOpen,this.popoverRef.value&&(this.popoverRef.value.open=this.isPopoverOpen)}closePopover(){this.isPopoverOpen=!1,this.popoverRef.value&&(this.popoverRef.value.open=this.isPopoverOpen)}async handleShareItem(e){this.shareUrl=await this.generateShareUrl();let s=null,o=navigator?.userAgent?.includes("Chrome")??!1,r=(navigator?.userAgent?.includes("Safari")??!1)&&!o;!r&&this.shortenShareUrl&&(s=await this.shortenUrl(this.shareUrl));let p=s||this.shareUrl;switch(e){case"link":await navigator.clipboard.writeText(p),this.embed&&this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!1,this.inlineCopyEmbedOpened=!1),this.mode==="inline"&&this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!0,setTimeout(()=>{this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!1)},3e3)),this.inlineCopyLinkOpened=!0,this.isLinkCopiedToClipboard=!0,this.mode==="popover"&&setTimeout(()=>this.closePopover(),2e3);return;case"facebook":case"bluesky":case"x":case"linkedIn":{let l;r&&(l=window.open("","_blank"),this.shortenShareUrl&&(p=await this.shortenUrl(this.shareUrl)||p));let f={url:encodeURI(p)},g=e==="x"?{...f,text:this.shareText}:f,R=M.substitute(te[e],g);this.mode==="popover"&&this.closePopover(),r&&l?(l.location=R,l.focus()):window.open(encodeURI(R),"_blank")}break;case"native-share":let b={title:this._messages.share?.label||"Share",text:this.shareText,url:encodeURI(p)};navigator?.canShare?.(b)?navigator.share(b).catch(l=>{console.error("Error using native share:",l)}):console.warn("Native share is not supported or the provided data is not shareable.");return}}async shortenUrl(e){let s=(await Q("https://arcg.is/prod/shorten",{query:{longUrl:e,f:"json"}}))?.data?.data?.url;if(s)return s.replace("http://","https://")}getEmbedCode(){return`<iframe src="${this.shareUrl}" width="${this.embedWidth}" height="${this.embedHeight}" frameborder="0" style="border:0" allowfullscreen>${this.iframeInnerText}</iframe>`}async copyEmbedCode(){if(await navigator.clipboard.writeText(this.getEmbedCode()),this.isEmbedCopiedToClipboard=!0,this.mode==="popover"){setTimeout(()=>this.closePopover(),2e3);return}this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!1),this.inlineCopyLinkOpened=!1,this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!0,setTimeout(()=>{this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!1)},3e3)),this.inlineCopyEmbedOpened=!0}async generateShareUrl(){if(this.autoUpdateShareUrl&&(this.shareUrl=window.location.href),!this.view?.ready)return this.shareUrl;let{x:e,y:s}=this.view.center,{spatialReference:o}=this.view,r=new H({...o.toJSON()}),p=new Y({x:e,y:s,spatialReference:r}),b=await this.processPoint(p),{isWGS84:l,isWebMercator:f}=b.spatialReference,g=l||f;return this.generateShareUrlParams(b,g)}async processPoint(e){let{isWGS84:s,isWebMercator:o}=e.spatialReference;if(s||o)return e;let r=new H({wkid:4326}),p=this.view?.spatialReference??r;try{return await P.load(),P.execute(e,p)}catch(b){console.error("Failed to project point to outSpatialReference",b);try{let l=P.execute(e,r);return Promise.resolve(l)}catch(l){return console.error("Failed to project point to fallbackOutSpatialReference",l),await Promise.reject(new Error("Failed to project point to both spatial references"))}}}generateShareUrlParams(e,s){let{longitude:o,latitude:r,x:p,y:b}=e;if(o===void 0||r===void 0||!this.view)return this.shareUrl;let l=this.roundValue(s?o:p),f=this.roundValue(s?r:b),{zoom:g}=this.view,R=this.roundValue(g),C=this.view?.popup?.selectedFeature,F=this.view?.popup?.visible,$,x;if(C&&F&&C?.layer?.type==="feature"){let v=C?.layer;$=v?.id,x=C.attributes[v.objectIdField]}let S=this.view.map?.allLayers.filter(v=>!v.visible).toArray().map(v=>v.id).toString().replaceAll(",",";"),{type:N}=this.view,{defaultUrlParams:_}=this,c=new URL(this.shareUrl),{searchParams:u}=c;if(u.get("center")&&u.delete("center"),u.get("level")&&u.delete("level"),u.get("selectedFeature")&&u.delete("selectedFeature"),u.get("hiddenLayers")&&u.delete("hiddenLayers"),u.get("viewpoint")&&u.delete("viewpoint"),N==="3d"){let{camera:v}=this.view,{heading:D,position:A,tilt:V}=v,{longitude:W,latitude:j,x:K,y:Z,z:G}=A,X=s?W:K,q=s?j:Z,y={longitude:this.roundValue(X,8),latitude:this.roundValue(q,8),z:this.roundValue(G,3),heading:this.roundValue(D,3),tilt:this.roundValue(V,3)},J=`cam:${y.longitude},${y.latitude},${y.z}${!s&&this.view?.spatialReference?.wkid?`,${this.view?.spatialReference?.wkid}`:""};${y.heading},${y.tilt}`;return _?.viewpoint!==!1&&c.searchParams.set("viewpoint",J),$&&x&&_?.selectedFeature!==!1&&c.searchParams.set("selectedFeature",`${$};${x}`),S&&_?.hiddenLayers!==!1&&c.searchParams.set("hiddenLayers",S),c.search=decodeURIComponent(c.search),c.href}return _?.center!==!1&&c.searchParams.set("center",`${l};${f}${!s&&this.view?.spatialReference?.wkid?`;${this.view?.spatialReference?.wkid}`:""}`),_?.level!==!1&&c.searchParams.set("level",`${R}`),$&&x&&_?.selectedFeature!==!1&&c.searchParams.set("selectedFeature",`${$};${x}`),S&&_?.hiddenLayers!==!1&&c.searchParams.set("hiddenLayers",S),c.search=decodeURIComponent(c.search),c.href}roundValue(e,s=4){return Number.parseFloat(e.toFixed(s))}get isMobileDevice(){return/Mobi|Android|iPhone|iPad|iPod/iu.test(navigator.userAgent)}render(){let e=this.mode==="popover"&&(this.isLinkCopiedToClipboard||this.isEmbedCopiedToClipboard)?this.isEmbedCopiedToClipboard?this.renderEmbedSuccess():this.renderSuccess():n`<div class=${i(t.dialogContent)}>${this.renderMenuOptions()}${this.displayTipText?this.renderTip():null}${this.embed?this.renderEmbed():null}</div>`,s=this.shareIconsLayout==="vertical"?` ${t.layout.vertical}`:` ${t.layout.horizontal}`,o=` calcite-mode-${this.el.closest(k)?"dark":"light"}`,r=n`<div class=${`${t.dialog}${s}${o}`} @click=${this.stopEventPropagation} ${h(this.dialogContentRef)}>${e}</div>`,p=this.removePopoverOffset?0:6;return this.isNativeShareEnabled?this.renderShareButton():this.mode==="popover"?[n`<calcite-popover .open=${this.isPopoverOpen} .label=${this._messages.share?.label??""} reference-element=shareButton placement=bottom-start .scale=${this.scale} .overlayPositioning=${this.popoverPositioning} .offsetDistance=${p} .pointerDisabled=${this.removePopoverOffset} @calcitePopoverOpen=${()=>{!this.shareListRef.value||this.isNativeShareEnabled||this.shareListRef.value.children[0].focus()}} @calcitePopoverBeforeClose=${this.resetPopoverCopyState} @click=${this.stopEventPropagation} @keydown=${this.handlePopoverRefKeyDown} ${h(this.popoverRef)}>${r}</calcite-popover>`,this.renderShareButton()]:[r,n`<calcite-popover .label=${this._messages.share?.label??""} reference-element=copyToClipboard .placement=${this.inlineSuccessPopoverPlacement} .scale=${this.scale} overlay-positioning=fixed ${h(this.copyLinkPopoverRef)}>${this.renderSuccess()}</calcite-popover>`,this.embed?n`<calcite-popover .label=${this._messages.share?.label??""} reference-element=copyEmbedToClipboard .placement=${this.inlineSuccessPopoverPlacement} .scale=${this.scale} overlay-positioning=fixed ${h(this.copyEmbedPopoverRef)}>${this.renderEmbedSuccess()}</calcite-popover>`:null]}renderShareButton(){let e=this.shareButtonScale??this.scale,s=async r=>{this.isNativeShareEnabled?(r.stopPropagation(),await this.handleShareItem("native-share")):this.togglePopoverVisibility(r)},o=n`<div class=${i(t.iconContainer)}><calcite-icon icon=share .scale=${this.popoverButtonIconScale}></calcite-icon></div>`;return this.shareButtonType==="button"?n`<calcite-button id=shareButton class=${i(t.popoverButton)} .label=${this._messages.share?.label} title=${this._messages.share?.label??E} .scale=${e} @click=${s} .kind=${this.shareButtonColor} appearance=transparent ${h(this.isNativeShareEnabled?void 0:this.popoverButtonRef)}>${o}</calcite-button>`:n`<calcite-action id=shareButton class=${i(t.popoverButton)} .label=${this._messages.share?.label} title=${this._messages.share?.label??E} .scale=${e} @click=${s} appearance=transparent text alignment=center ${h(this.isNativeShareEnabled?void 0:this.popoverButtonRef)}>${o}</calcite-action>`}renderSuccess(){let e=this._messages.success;return n`<div class=${i(t.success.container)}><span class=${i(t.success.header)}><span class=${i(t.success.icon)}><calcite-icon icon=check-circle-f .scale=${this.scale}></calcite-icon></span>${e?.label}</span><span class=${i(t.success.message)}>${this.successMessage||e?.url}</span></div>`}renderEmbedSuccess(){let e=this._messages.success;return n`<div class=${i(t.success.container)}><span class=${i(t.success.header)}><span class=${i(t.success.icon)}><calcite-icon icon=check-circle-f .scale=${this.scale}></calcite-icon></span>${e?.label}</span><span class=${i(t.success.message)}>${e?.embed}</span></div>`}renderMenuOptions(){let e=this._messages.options,s=document.dir==="rtl"?` ${t.rtl.optionText}`:"";return n`<ul class=${i(t.options)} role=menu ${h(this.shareListRef)}><li id=copyToClipboard @click=${this.handleShareItem.bind(this,"link")} @keydown=${this.makeOptionKeyDownHandler("link")} role=menuitem tabindex=0><span class=${i(t.icon)}><calcite-icon icon=link .scale=${this.scale}></calcite-icon></span><span class=${`${t.optionText}${s}`}>${e?.link?.label}</span></li>${this.socialMedia?[n`<li @click=${this.handleShareItem.bind(this,"facebook")} @keydown=${this.makeOptionKeyDownHandler("facebook")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderFacebookIcon()}</span><span class=${`${t.optionText}${s}`}>${e?.facebook?.label}</span></li>`,n`<li @click=${this.handleShareItem.bind(this,"x")} @keydown=${this.makeOptionKeyDownHandler("x")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderXIcon()}</span><span class=${`${t.optionText}${s}`}>X</span></li>`,n`<li @click=${this.handleShareItem.bind(this,"linkedIn")} @keydown=${this.makeOptionKeyDownHandler("linkedIn")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderLinkedInIcon()}</span><span class=${`${t.optionText}${s}`}>${e?.linkedIn?.label}</span></li>`,n`<li @click=${this.handleShareItem.bind(this,"bluesky")} @keydown=${this.makeOptionKeyDownHandler("bluesky")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderBlueSkyIcon()}</span><span class=${`${t.optionText}${s}`}>${e?.blueSky?.label}</span></li>`]:null}</ul>`}renderFacebookIcon(){let e=!!this.el.closest(k);return n`<svg height=100% style=${d({fillRule:"evenodd",clipRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2"})} version=1.1 viewBox="0 0 512 512" width=100% xmlns=http://www.w3.org/2000/svg>${w`<g><path d="M512,256c0,-141.385 -114.615,-256 -256,-256c-141.385,0 -256,114.615 -256,256c0,127.777 93.616,233.685 216,252.89l0,-178.89l-65,0l0,-74l65,0l0,-56.4c0,-64.16 38.219,-99.6 96.695,-99.6c28.009,0 57.305,5 57.305,5l0,63l-32.281,0c-31.801,0 -41.719,19.733 -41.719,39.978l0,48.022l71,0l-11.35,74l-59.65,0l0,178.89c122.385,-19.205 216,-125.113 216,-252.89Z" style=${d({fill:e?"#fff":"#000",fillRule:"nonzero"})} /><path d="M355.65,330l11.35,-74l-71,0l0,-48.022c0,-20.245 9.917,-39.978 41.719,-39.978l32.281,0l0,-63c0,0 -29.297,-5 -57.305,-5c-58.476,0 -96.695,35.44 -96.695,99.6l0,56.4l-65,0l0,74l65,0l0,178.89c13.033,2.045 26.392,3.11 40,3.11c13.608,0 26.966,-1.065 40,-3.11l0,-178.89l59.65,0Z" style=${d({fill:e?"#000":"#fff",fillRule:"nonzero"})} /></g>`}</svg>`}renderXIcon(){let e=!!this.el.closest(k);return n`<svg height=100% class=${i(e?t.xLogo.dark:t.xLogo.light)} viewBox="0 0 1200 1227" fill=none xmlns=http://www.w3.org/2000/svg>${w`<rect height=400 style=${d({fill:"none"})} width=400 x=56 y=56 /><path d="M714.163 519.284L1160.89 0H1055.03L667.137 450.887L357.328 0H0L468.492 681.821L0 1226.37H105.866L515.491 750.218L842.672 1226.37H1200L714.137 519.284H714.163ZM569.165 687.828L521.697 619.934L144.011 79.6944H306.615L611.412 515.685L658.88 583.579L1055.08 1150.3H892.476L569.165 687.854V687.828Z" fill=${e?"white":"black"} />`}</svg>`}renderBlueSkyIcon(){let e=!!this.el.closest(k);return n`<svg height=100% xmlns=http://www.w3.org/2000/svg viewBox="0 0 512 512">${w`<path style=${d({fill:e?"#fff":"#000"})} d="M111.8 62.2C170.2 105.9 233 194.7 256 242.4c23-47.6 85.8-136.4 144.2-180.2c42.1-31.6 110.3-56 110.3 21.8c0 15.5-8.9 130.5-14.1 149.2C478.2 298 412 314.6 353.1 304.5c102.9 17.5 129.1 75.5 72.5 133.5c-107.4 110.2-154.3-27.6-166.3-62.9l0 0c-1.7-4.9-2.6-7.8-3.3-7.8s-1.6 3-3.3 7.8l0 0c-12 35.3-59 173.1-166.3 62.9c-56.5-58-30.4-116 72.5-133.5C100 314.6 33.8 298 15.7 233.1C10.4 214.4 1.5 99.4 1.5 83.9c0-77.8 68.2-53.4 110.3-21.8z" />`}</svg>`}renderLinkedInIcon(){let e=!!this.el.closest(k);return n`<svg height=100% style=${d({fillRule:"evenodd",clipRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2"})} version=1.1 viewBox="0 0 512 512" width=100% xmlns=http://www.w3.org/2000/svg>${w`<g id=g5891><path d="M512,64c0,-35.323 -28.677,-64 -64,-64l-384,0c-35.323,0 -64,28.677 -64,64l0,384c0,35.323 28.677,64 64,64l384,0c35.323,0 64,-28.677 64,-64l0,-384Z" id=background style=${d({fill:e?"#fff":"#000"})} /><g id=shapes><rect height=257.962 id=rect11 style=${d({fill:e?"#000":"#fff"})} width=85.76 x=61.053 y=178.667 /><path d="M104.512,54.28c-29.341,0 -48.512,19.29 -48.512,44.573c0,24.752 18.588,44.574 47.377,44.574l0.554,0c29.903,0 48.516,-19.822 48.516,-44.574c-0.555,-25.283 -18.611,-44.573 -47.935,-44.573Z" id=path13-0 style=${d({fill:e?"#000":"#fff",fillRule:"nonzero"})} /><path d="M357.278,172.601c-45.49,0 -65.866,25.017 -77.276,42.589l0,-36.523l-85.738,0c1.137,24.197 0,257.961 0,257.961l85.737,0l0,-144.064c0,-7.711 0.554,-15.42 2.827,-20.931c6.188,-15.4 20.305,-31.352 43.993,-31.352c31.012,0 43.436,23.664 43.436,58.327l0,138.02l85.741,0l0,-147.93c0,-79.237 -42.305,-116.097 -98.72,-116.097Z" id=path15 style=${d({fill:e?"#000":"#fff",fillRule:"nonzero"})} /></g></g>`}</svg>`}renderTip(){let e=this._messages.info;return n`<div class=${i(t.tipContainer)}><span class=${i(t.tipHeader)}><calcite-icon icon=lightbulb .scale=${this.scale}></calcite-icon><span>${e?.label}</span></span><p class=${i(t.tipContent)}>${e?.tooltip}</p></div>`}renderEmbed(){let e=this._messages.embed,s=document.dir==="rtl"?` ${t.rtl.textArea}`:"";return n`<div class=${i(t.embed.container)}><span class=${i(t.embed.header)}><calcite-icon icon=code .scale=${this.scale}></calcite-icon><span>${this._messages.embed?.label}</span></span><div class=${i(t.embed.embedCode.container)}><div class=${i(t.embed.embedCode.textArea)}><textarea cols=30 rows=5 readonly class=${i(s)} .value=${L(this.getEmbedCode()??"")} ${h(this.embedCodeRef)}></textarea><button id=copyEmbedToClipboard @click=${this.copyEmbedCode} class=${i(t.embed.embedCode.copyButton)}><calcite-icon icon=copy .scale=${this.scale}></calcite-icon><span>${e?.copy}</span></button></div><span class=${i(t.embed.textAreaText)}><slot name=text-area-text></slot></span><div class=${i(t.embed.dimensions.container)}><label class=${i(t.embed.dimensions.input)}><span>${e?.width}</span><input type=number @keydown=${o=>["e","E","+","-"].includes(o.key)&&o.preventDefault()} @change=${this.makeEmbedResizeHandler("width")} .value=${L(this.embedWidth??"")} min=${T} ${h(this.embedWidthRef)}></label><label class=${i(t.embed.dimensions.input)}><span>${e?.height}</span><input type=number @keydown=${o=>["e","E","+","-"].includes(o.key)&&o.preventDefault()} @change=${this.makeEmbedResizeHandler("height")} .value=${L(this.embedHeight??"")} min=${T} ${h(this.embedHeightRef)}></label></div></div></div>`}};B("instant-apps-social-share",z);return z},"intl","request","geometry/operators/projectOperator","geometry/Point","geometry/SpatialReference")
2
+ import{a as O}from"./SLC22JQP.js";import{b as B}from"./JTUQKBFR.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{E as L,F as m,G as h,H as U,J as i,K as d,L as E,h as I,i as n,j as w}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";export default $arcgis.t(([M,Q,P,Y,H])=>{var ee=I`:host{display:block;--instant-apps-social-share-action-width: initial;--instant-apps-social-share-width--s: 200px;--instant-apps-social-share-width--m: 280px;--instant-apps-social-share-width--l: 320px;--instant-apps-social-share-width-horizontal--s: 300px;--instant-apps-social-share-width-horizontal--m: 380px;--instant-apps-social-share-width-horizontal--l: 420px;--instant-apps-social-share-background-color: var( --calcite-color-foreground-1 );--instant-apps-social-share-popover-button-background-color: transparent;--instant-apps-social-share-popover-button-icon-color: var( --calcite-icon-color );--instant-apps-social-share-embed-border: 1px solid $border;--instant-apps-social-share-embed-text-area-text: #468540}:host .instant-apps-social-share__popover-button{background-color:var(--instant-apps-social-share-popover-button-background-color)}:host .instant-apps-social-share__popover-button calcite-icon{color:var(--instant-apps-social-share-popover-button-icon-color)}:host .instant-apps-social-share__dialog,:host .instant-apps-social-share__dialog-embed{background-color:var(--instant-apps-social-share-background-color);border:var(--instant-apps-social-share-embed-border)}:host .instant-apps-social-share__dialog{box-sizing:border-box;height:auto;padding:10px 0;border-radius:5px;color:var(--calcite-color-text-1)}:host .instant-apps-social-share__options{margin:0;padding:1% 0 0;list-style-type:none}:host .instant-apps-social-share__options li{box-sizing:border-box;display:flex;align-items:center;width:100%;padding:5%;transition:background-color .15s ease-out 0s}:host .instant-apps-social-share__options li .instant-apps-social-share__icon,:host .instant-apps-social-share__options li .instant-apps-social-share__option-text{display:inline-block}:host .instant-apps-social-share__options li .instant-apps-social-share__icon{display:flex;align-items:center}:host .instant-apps-social-share__options li .instant-apps-social-share__option-text{width:85%;margin-left:10px;word-break:break-word}:host .instant-apps-social-share__options li .instant-apps-social-share__option-text--rtl{margin-left:0;margin-right:10px}:host .instant-apps-social-share__options li:hover{cursor:pointer;background-color:var(--calcite-color-foreground-2)}:host .instant-apps-social-share__options__x-logo--light path{fill:#000}:host .instant-apps-social-share__options__x-logo--dark path{fill:#fff}:host .instant-apps-social-share__tip{box-sizing:border-box;padding:0 5% 1%}:host .instant-apps-social-share__tip-header{display:flex;align-items:center;color:#007ac2;margin:8px 0 5px}:host .instant-apps-social-share__tip-header calcite-icon{margin-right:5px}:host .instant-apps-social-share__tip-content{line-height:17px;margin:0;padding-top:2%}:host .instant-apps-social-share__success{display:flex;flex-direction:column;padding:15px}:host .instant-apps-social-share__success-header{display:flex;align-items:center;font-weight:700;margin-bottom:10px}:host .instant-apps-social-share__success-icon{display:flex;align-items:center;margin-right:5px}:host .instant-apps-social-share__success-icon calcite-icon{color:var(--calcite-color-status-success)}:host .instant-apps-social-share__success-message{line-height:16px}:host .instant-apps-social-share__embed{box-sizing:border-box;width:100%;padding:5%;margin-bottom:10px;border-top:1px solid #d3d3d3}:host .instant-apps-social-share__embed-header{display:flex;align-items:center;margin-bottom:5px}:host .instant-apps-social-share__embed-header calcite-icon{margin-right:5px}:host .instant-apps-social-share__embed-code-text-area{border:1px solid #d3d3d3}:host .instant-apps-social-share__embed-code-text-area textarea{box-sizing:border-box;padding:4%;border:none;resize:none;background:transparent;width:100%;font-family:var(--calcite-sans-family);color:var(--calcite-color-text-1)}:host .instant-apps-social-share__embed-code-text-area button{display:flex;align-items:center;text-align:start;width:100%;border:none;border-top:1px solid #d3d3d3;background-color:transparent;line-height:16px;font-weight:400;padding:3%;color:var(--calcite-color-text-1)}:host .instant-apps-social-share__embed-code-text-area button calcite-icon{color:#007ac2;margin-right:3px}:host .instant-apps-social-share__embed-code-text-area button:hover{cursor:pointer;background-color:var(--calcite-color-foreground-2);transition:background-color .15s ease-out 0s}:host .instant-apps-social-share__embed-text-area-text{display:inline-block;padding-block-start:var(--calcite-spacing-md);font-weight:600;color:var(--instant-apps-social-share-embed-text-area-text)}:host .instant-apps-social-share__embed .instant-apps-social-share__text-area--rtl{text-align:left;direction:ltr}:host .instant-apps-social-share__embed-dimensions{display:flex;justify-content:space-between;margin-top:10px}:host .instant-apps-social-share__embed-dimensions-input{width:47%;box-sizing:border-box}:host .instant-apps-social-share__embed-dimensions-input input{border:1px solid #d3d3d3;width:100%;height:25px;font-family:var(--calcite-sans-family)}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options{display:flex;justify-content:space-around;margin-bottom:8%}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options li{flex-direction:column;padding:0}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options li .instant-apps-social-share__option-text{word-break:break-word;margin-left:0;margin-top:10px;text-align:center}:host .instant-apps-social-share__layout--horizontal .instant-apps-social-share__options li:hover{background-color:unset}:host .instant-apps-social-share__icon-container{display:flex;align-items:center}:host calcite-action{width:var(--instant-apps-social-share-action-width)}:host([scale=s]) .instant-apps-social-share__dialog{width:var(--instant-apps-social-share-width--s)}:host([scale=s]) .instant-apps-social-share__icon{width:16px;height:16px}:host([scale=s]) .instant-apps-social-share__option-text{font-size:var(--calcite-font-size--1)}:host([scale=s]) .instant-apps-social-share__dialog.instant-apps-social-share__layout--horizontal{width:var(--instant-apps-social-share-width-horizontal--s)}:host([scale=s]) .instant-apps-social-share__tip-header,:host([scale=s]) .instant-apps-social-share__tip-content,:host([scale=s]) .instant-apps-social-share__embed-header,:host([scale=s]) .instant-apps-social-share__embed-dimensions-input{font-size:var(--calcite-font-size--2)}:host([scale=m]) .instant-apps-social-share__dialog{width:var(--instant-apps-social-share-width--m)}:host([scale=m]) .instant-apps-social-share__icon{width:24px;height:24px}:host([scale=m]) .instant-apps-social-share__option-text{font-size:var(--calcite-font-size-0)}:host([scale=m]) .instant-apps-social-share__dialog.instant-apps-social-share__layout--horizontal{width:var(--instant-apps-social-share-width-horizontal--m)}:host([scale=m]) .instant-apps-social-share__tip-header,:host([scale=m]) .instant-apps-social-share__tip-content,:host([scale=m]) .instant-apps-social-share__embed-header,:host([scale=m]) .instant-apps-social-share__embed-dimensions-input{font-size:var(--calcite-font-size--1)}:host([scale=l]) .instant-apps-social-share__dialog{width:var(--instant-apps-social-share-width--l)}:host([scale=l]) .instant-apps-social-share__icon{width:32px;height:32px}:host([scale=l]) .instant-apps-social-share__option-text{font-size:var(--calcite-font-size-1)}:host([scale=l]) .instant-apps-social-share__dialog.instant-apps-social-share__layout--horizontal{width:var(--instant-apps-social-share-width-horizontal--l)}:host([scale=l]) .instant-apps-social-share__tip-header,:host([scale=l]) .instant-apps-social-share__tip-content,:host([scale=l]) .instant-apps-social-share__embed-header,:host([scale=l]) .instant-apps-social-share__embed-dimensions-input{font-size:var(--calcite-font-size-0)}`,a="instant-apps-social-share",k=".calcite-mode-dark",t={dialog:`${a}__dialog`,dialogContent:`${a}__dialog-content`,options:`${a}__options`,tipContainer:`${a}__tip`,tipHeader:`${a}__tip-header`,tipContent:`${a}__tip-content`,icon:`${a}__icon`,iconContainer:`${a}__icon-container`,optionText:`${a}__option-text`,popoverButton:`${a}__popover-button`,layout:{vertical:`${a}__layout--vertical`,horizontal:`${a}__layout--horizontal`},xLogo:{light:`${a}__x-logo--light`,dark:`${a}__x-logo--dark`},success:{container:`${a}__success`,header:`${a}__success-header`,message:`${a}__success-message`,icon:`${a}__success-icon`},embed:{container:`${a}__embed`,header:`${a}__embed-header`,embedCode:{container:`${a}__embed-code`,textArea:`${a}__embed-code-text-area`,copyButton:`${a}__embed-code-copy-button`},textAreaText:`${a}__embed-text-area-text`,dimensions:{container:`${a}__embed-dimensions`,input:`${a}__embed-dimensions-input`}},rtl:{optionText:`${a}__option-text--rtl`,textArea:`${a}__text-area--rtl`}},te={facebook:"https://www.facebook.com/sharer/sharer.php?u={url}",x:"https://x.com/intent/post?url={url}",linkedIn:"https://www.linkedin.com/sharing/share-offsite/?text={url}",bluesky:"https://bsky.app/intent/compose?text={url}"},T=1,z=class extends U{constructor(){super(...arguments),this._messages=O({name:"instant-apps-social-share"}),this.popoverRef=m(),this.embedWidthRef=m(),this.embedHeightRef=m(),this.embedCodeRef=m(),this.copyLinkPopoverRef=m(),this.copyEmbedPopoverRef=m(),this.dialogContentRef=m(),this.shareListRef=m(),this.popoverButtonRef=m(),this.handlePopoverRefKeyDown=async e=>{if(!this.isNativeShareEnabled)if(e.code==="Tab"){if(!this.shareListRef.value)return;let s=e.target,o=this.shareListRef.value.children[0],r=this.shareListRef.value.children[this.shareListRef.value.children.length-1];e.shiftKey&&s===o?(e.preventDefault(),r.focus()):!e.shiftKey&&s===r&&(e.preventDefault(),o.focus())}else e.code==="Escape"&&(this.closePopover(),await this.popoverButtonRef.value?.setFocus())},this.stopEventPropagation=e=>{e.stopPropagation()},this.autoCloseCallback=()=>{this.mode==="popover"&&this.popoverRef.value?(this.isPopoverOpen=!1,this.popoverRef.value.open=this.isPopoverOpen):(this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!1),this.inlineCopyLinkOpened=!1,this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!1),this.inlineCopyEmbedOpened=!1)},this.resetPopoverCopyState=async()=>{await this.popoverButtonRef.value?.setFocus(),setTimeout(()=>{this.isLinkCopiedToClipboard=!1,this.isEmbedCopiedToClipboard=!1},200)},this.isPopoverOpen=!1,this.isLinkCopiedToClipboard=!1,this.isEmbedCopiedToClipboard=!1,this.inlineCopyLinkOpened=!1,this.inlineCopyEmbedOpened=!1,this.embedWidth=400,this.embedHeight=600,this.mode="popover",this.shareUrl=window.location.href,this.autoUpdateShareUrl=!0,this.shareText="",this.embed=!1,this.shareButtonColor="neutral",this.shareButtonType="button",this.shareButtonScale="m",this.iframeInnerText="",this.popoverButtonIconScale="m",this.displayTipText=!0,this.shortenShareUrl=!0,this.socialMedia=!0,this.shareIconsLayout="vertical",this.scale="m",this.successMessage="",this.flipRtl=!1,this.defaultUrlParams=null,this.inlineSuccessPopoverPlacement="trailing",this.popoverPositioning="absolute",this.removePopoverOffset=!1,this.useNativeShare=!1,this.isNativeShareEnabled=!1}static{this.properties={isPopoverOpen:16,isLinkCopiedToClipboard:16,isEmbedCopiedToClipboard:16,inlineCopyLinkOpened:16,inlineCopyEmbedOpened:16,embedWidth:16,embedHeight:16,mode:3,shareUrl:1,autoUpdateShareUrl:5,shareText:3,embed:7,shareButtonColor:3,shareButtonType:3,shareButtonScale:3,iframeInnerText:3,popoverButtonIconScale:3,view:0,displayTipText:7,shortenShareUrl:7,socialMedia:7,shareIconsLayout:3,scale:3,successMessage:3,flipRtl:7,defaultUrlParams:0,inlineSuccessPopoverPlacement:3,popoverPositioning:3,removePopoverOffset:7,useNativeShare:7,isNativeShareEnabled:7}}static{this.styles=ee}load(){document.documentElement.addEventListener("click",this.autoCloseCallback),this.isNativeShareEnabled=this.useNativeShare&&this.isMobileDevice}disconnectedCallback(){super.disconnectedCallback(),document.documentElement.removeEventListener("click",this.autoCloseCallback)}makeOptionKeyDownHandler(e){return async s=>{let o=s.code;(o==="Space"||o==="Enter")&&await this.handleShareItem(e)}}makeEmbedResizeHandler(e){let s=e==="width"?this.embedWidthRef.value:this.embedHeightRef.value;return()=>{if(!(!this.embed||this.isNativeShareEnabled)&&s){let o=Math.max(s.valueAsNumber??0,T);this[e==="width"?"embedWidth":"embedHeight"]=o}}}togglePopoverVisibility(e){e.stopPropagation(),this.isPopoverOpen=!this.isPopoverOpen,this.popoverRef.value&&(this.popoverRef.value.open=this.isPopoverOpen)}closePopover(){this.isPopoverOpen=!1,this.popoverRef.value&&(this.popoverRef.value.open=this.isPopoverOpen)}async handleShareItem(e){this.shareUrl=await this.generateShareUrl();let s=null,o=navigator?.userAgent?.includes("Chrome")??!1,r=(navigator?.userAgent?.includes("Safari")??!1)&&!o;!r&&this.shortenShareUrl&&(s=await this.shortenUrl(this.shareUrl));let p=s||this.shareUrl;switch(e){case"link":await navigator.clipboard.writeText(p),this.embed&&this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!1,this.inlineCopyEmbedOpened=!1),this.mode==="inline"&&this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!0,setTimeout(()=>{this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!1)},3e3)),this.inlineCopyLinkOpened=!0,this.isLinkCopiedToClipboard=!0,this.mode==="popover"&&setTimeout(()=>this.closePopover(),2e3);return;case"facebook":case"bluesky":case"x":case"linkedIn":{let l;r&&(l=window.open("","_blank"),this.shortenShareUrl&&(p=await this.shortenUrl(this.shareUrl)||p));let f={url:encodeURI(p)},g=e==="x"?{...f,text:this.shareText}:f,R=M.substitute(te[e],g);this.mode==="popover"&&this.closePopover(),r&&l?(l.location=R,l.focus()):window.open(encodeURI(R),"_blank")}break;case"native-share":let b={title:this._messages.share?.label||"Share",text:this.shareText,url:encodeURI(p)};navigator?.canShare?.(b)?navigator.share(b).catch(l=>{console.error("Error using native share:",l)}):console.warn("Native share is not supported or the provided data is not shareable.");return}}async shortenUrl(e){let s=(await Q("https://arcg.is/prod/shorten",{query:{longUrl:e,f:"json"}}))?.data?.data?.url;if(s)return s.replace("http://","https://")}getEmbedCode(){return`<iframe src="${this.shareUrl}" width="${this.embedWidth}" height="${this.embedHeight}" frameborder="0" style="border:0" allowfullscreen>${this.iframeInnerText}</iframe>`}async copyEmbedCode(){if(await navigator.clipboard.writeText(this.getEmbedCode()),this.isEmbedCopiedToClipboard=!0,this.mode==="popover"){setTimeout(()=>this.closePopover(),2e3);return}this.copyLinkPopoverRef.value&&(this.copyLinkPopoverRef.value.open=!1),this.inlineCopyLinkOpened=!1,this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!0,setTimeout(()=>{this.copyEmbedPopoverRef.value&&(this.copyEmbedPopoverRef.value.open=!1)},3e3)),this.inlineCopyEmbedOpened=!0}async generateShareUrl(){if(this.autoUpdateShareUrl&&(this.shareUrl=window.location.href),!this.view?.ready)return this.shareUrl;let{x:e,y:s}=this.view.center,{spatialReference:o}=this.view,r=new H({...o.toJSON()}),p=new Y({x:e,y:s,spatialReference:r}),b=await this.processPoint(p),{isWGS84:l,isWebMercator:f}=b.spatialReference,g=l||f;return this.generateShareUrlParams(b,g)}async processPoint(e){let{isWGS84:s,isWebMercator:o}=e.spatialReference;if(s||o)return e;let r=new H({wkid:4326}),p=this.view?.spatialReference??r;try{return await P.load(),P.execute(e,p)}catch(b){console.error("Failed to project point to outSpatialReference",b);try{let l=P.execute(e,r);return Promise.resolve(l)}catch(l){return console.error("Failed to project point to fallbackOutSpatialReference",l),await Promise.reject(new Error("Failed to project point to both spatial references"))}}}generateShareUrlParams(e,s){let{longitude:o,latitude:r,x:p,y:b}=e;if(o===void 0||r===void 0||!this.view)return this.shareUrl;let l=this.roundValue(s?o:p),f=this.roundValue(s?r:b),{zoom:g}=this.view,R=this.roundValue(g),C=this.view?.popup?.selectedFeature,F=this.view?.popup?.visible,$,x;if(C&&F&&C?.layer?.type==="feature"){let v=C?.layer;$=v?.id,x=C.attributes[v.objectIdField]}let S=this.view.map?.allLayers.filter(v=>!v.visible).toArray().map(v=>v.id).toString().replaceAll(",",";"),{type:N}=this.view,{defaultUrlParams:_}=this,c=new URL(this.shareUrl),{searchParams:u}=c;if(u.get("center")&&u.delete("center"),u.get("level")&&u.delete("level"),u.get("selectedFeature")&&u.delete("selectedFeature"),u.get("hiddenLayers")&&u.delete("hiddenLayers"),u.get("viewpoint")&&u.delete("viewpoint"),N==="3d"){let{camera:v}=this.view,{heading:D,position:A,tilt:V}=v,{longitude:W,latitude:j,x:K,y:Z,z:G}=A,X=s?W:K,q=s?j:Z,y={longitude:this.roundValue(X,8),latitude:this.roundValue(q,8),z:this.roundValue(G,3),heading:this.roundValue(D,3),tilt:this.roundValue(V,3)},J=`cam:${y.longitude},${y.latitude},${y.z}${!s&&this.view?.spatialReference?.wkid?`,${this.view?.spatialReference?.wkid}`:""};${y.heading},${y.tilt}`;return _?.viewpoint!==!1&&c.searchParams.set("viewpoint",J),$&&x&&_?.selectedFeature!==!1&&c.searchParams.set("selectedFeature",`${$};${x}`),S&&_?.hiddenLayers!==!1&&c.searchParams.set("hiddenLayers",S),c.search=decodeURIComponent(c.search),c.href}return _?.center!==!1&&c.searchParams.set("center",`${l};${f}${!s&&this.view?.spatialReference?.wkid?`;${this.view?.spatialReference?.wkid}`:""}`),_?.level!==!1&&c.searchParams.set("level",`${R}`),$&&x&&_?.selectedFeature!==!1&&c.searchParams.set("selectedFeature",`${$};${x}`),S&&_?.hiddenLayers!==!1&&c.searchParams.set("hiddenLayers",S),c.search=decodeURIComponent(c.search),c.href}roundValue(e,s=4){return Number.parseFloat(e.toFixed(s))}get isMobileDevice(){return/Mobi|Android|iPhone|iPad|iPod/iu.test(navigator.userAgent)}render(){let e=this.mode==="popover"&&(this.isLinkCopiedToClipboard||this.isEmbedCopiedToClipboard)?this.isEmbedCopiedToClipboard?this.renderEmbedSuccess():this.renderSuccess():n`<div class=${i(t.dialogContent)}>${this.renderMenuOptions()}${this.displayTipText?this.renderTip():null}${this.embed?this.renderEmbed():null}</div>`,s=this.shareIconsLayout==="vertical"?` ${t.layout.vertical}`:` ${t.layout.horizontal}`,o=` calcite-mode-${this.el.closest(k)?"dark":"light"}`,r=n`<div class=${`${t.dialog}${s}${o}`} @click=${this.stopEventPropagation} ${h(this.dialogContentRef)}>${e}</div>`,p=this.removePopoverOffset?0:6;return this.isNativeShareEnabled?this.renderShareButton():this.mode==="popover"?[n`<calcite-popover .open=${this.isPopoverOpen} .label=${this._messages.share?.label??""} reference-element=shareButton placement=bottom-start .scale=${this.scale} .overlayPositioning=${this.popoverPositioning} .offsetDistance=${p} .pointerDisabled=${this.removePopoverOffset} @calcitePopoverOpen=${()=>{!this.shareListRef.value||this.isNativeShareEnabled||this.shareListRef.value.children[0].focus()}} @calcitePopoverBeforeClose=${this.resetPopoverCopyState} @click=${this.stopEventPropagation} @keydown=${this.handlePopoverRefKeyDown} ${h(this.popoverRef)}>${r}</calcite-popover>`,this.renderShareButton()]:[r,n`<calcite-popover .label=${this._messages.share?.label??""} reference-element=copyToClipboard .placement=${this.inlineSuccessPopoverPlacement} .scale=${this.scale} overlay-positioning=fixed ${h(this.copyLinkPopoverRef)}>${this.renderSuccess()}</calcite-popover>`,this.embed?n`<calcite-popover .label=${this._messages.share?.label??""} reference-element=copyEmbedToClipboard .placement=${this.inlineSuccessPopoverPlacement} .scale=${this.scale} overlay-positioning=fixed ${h(this.copyEmbedPopoverRef)}>${this.renderEmbedSuccess()}</calcite-popover>`:null]}renderShareButton(){let e=this.shareButtonScale??this.scale,s=async r=>{this.isNativeShareEnabled?(r.stopPropagation(),await this.handleShareItem("native-share")):this.togglePopoverVisibility(r)},o=n`<div class=${i(t.iconContainer)}><calcite-icon icon=share .scale=${this.popoverButtonIconScale}></calcite-icon></div>`;return this.shareButtonType==="button"?n`<calcite-button id=shareButton class=${i(t.popoverButton)} .label=${this._messages.share?.label} title=${this._messages.share?.label??E} .scale=${e} @click=${s} .kind=${this.shareButtonColor} appearance=transparent ${h(this.isNativeShareEnabled?void 0:this.popoverButtonRef)}>${o}</calcite-button>`:n`<calcite-action id=shareButton class=${i(t.popoverButton)} .label=${this._messages.share?.label} title=${this._messages.share?.label??E} .scale=${e} @click=${s} appearance=transparent text alignment=center ${h(this.isNativeShareEnabled?void 0:this.popoverButtonRef)}>${o}</calcite-action>`}renderSuccess(){let e=this._messages.success;return n`<div class=${i(t.success.container)}><span class=${i(t.success.header)}><span class=${i(t.success.icon)}><calcite-icon icon=check-circle-f .scale=${this.scale}></calcite-icon></span>${e?.label}</span><span class=${i(t.success.message)}>${this.successMessage||e?.url}</span></div>`}renderEmbedSuccess(){let e=this._messages.success;return n`<div class=${i(t.success.container)}><span class=${i(t.success.header)}><span class=${i(t.success.icon)}><calcite-icon icon=check-circle-f .scale=${this.scale}></calcite-icon></span>${e?.label}</span><span class=${i(t.success.message)}>${e?.embed}</span></div>`}renderMenuOptions(){let e=this._messages.options,s=document.dir==="rtl"?` ${t.rtl.optionText}`:"";return n`<ul class=${i(t.options)} role=menu ${h(this.shareListRef)}><li id=copyToClipboard @click=${this.handleShareItem.bind(this,"link")} @keydown=${this.makeOptionKeyDownHandler("link")} role=menuitem tabindex=0><span class=${i(t.icon)}><calcite-icon icon=link .scale=${this.scale}></calcite-icon></span><span class=${`${t.optionText}${s}`}>${e?.link?.label}</span></li>${this.socialMedia?[n`<li @click=${this.handleShareItem.bind(this,"facebook")} @keydown=${this.makeOptionKeyDownHandler("facebook")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderFacebookIcon()}</span><span class=${`${t.optionText}${s}`}>${e?.facebook?.label}</span></li>`,n`<li @click=${this.handleShareItem.bind(this,"x")} @keydown=${this.makeOptionKeyDownHandler("x")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderXIcon()}</span><span class=${`${t.optionText}${s}`}>X</span></li>`,n`<li @click=${this.handleShareItem.bind(this,"linkedIn")} @keydown=${this.makeOptionKeyDownHandler("linkedIn")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderLinkedInIcon()}</span><span class=${`${t.optionText}${s}`}>${e?.linkedIn?.label}</span></li>`,n`<li @click=${this.handleShareItem.bind(this,"bluesky")} @keydown=${this.makeOptionKeyDownHandler("bluesky")} role=menuitem tabindex=0><span class=${i(t.icon)}>${this.renderBlueSkyIcon()}</span><span class=${`${t.optionText}${s}`}>${e?.blueSky?.label}</span></li>`]:null}</ul>`}renderFacebookIcon(){let e=!!this.el.closest(k);return n`<svg height=100% style=${d({fillRule:"evenodd",clipRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2"})} version=1.1 viewBox="0 0 512 512" width=100% xmlns=http://www.w3.org/2000/svg>${w`<g><path d="M512,256c0,-141.385 -114.615,-256 -256,-256c-141.385,0 -256,114.615 -256,256c0,127.777 93.616,233.685 216,252.89l0,-178.89l-65,0l0,-74l65,0l0,-56.4c0,-64.16 38.219,-99.6 96.695,-99.6c28.009,0 57.305,5 57.305,5l0,63l-32.281,0c-31.801,0 -41.719,19.733 -41.719,39.978l0,48.022l71,0l-11.35,74l-59.65,0l0,178.89c122.385,-19.205 216,-125.113 216,-252.89Z" style=${d({fill:e?"#fff":"#000",fillRule:"nonzero"})} /><path d="M355.65,330l11.35,-74l-71,0l0,-48.022c0,-20.245 9.917,-39.978 41.719,-39.978l32.281,0l0,-63c0,0 -29.297,-5 -57.305,-5c-58.476,0 -96.695,35.44 -96.695,99.6l0,56.4l-65,0l0,74l65,0l0,178.89c13.033,2.045 26.392,3.11 40,3.11c13.608,0 26.966,-1.065 40,-3.11l0,-178.89l59.65,0Z" style=${d({fill:e?"#000":"#fff",fillRule:"nonzero"})} /></g>`}</svg>`}renderXIcon(){let e=!!this.el.closest(k);return n`<svg height=100% class=${i(e?t.xLogo.dark:t.xLogo.light)} viewBox="0 0 1200 1227" fill=none xmlns=http://www.w3.org/2000/svg>${w`<rect height=400 style=${d({fill:"none"})} width=400 x=56 y=56 /><path d="M714.163 519.284L1160.89 0H1055.03L667.137 450.887L357.328 0H0L468.492 681.821L0 1226.37H105.866L515.491 750.218L842.672 1226.37H1200L714.137 519.284H714.163ZM569.165 687.828L521.697 619.934L144.011 79.6944H306.615L611.412 515.685L658.88 583.579L1055.08 1150.3H892.476L569.165 687.854V687.828Z" fill=${e?"white":"black"} />`}</svg>`}renderBlueSkyIcon(){let e=!!this.el.closest(k);return n`<svg height=100% xmlns=http://www.w3.org/2000/svg viewBox="0 0 512 512">${w`<path style=${d({fill:e?"#fff":"#000"})} d="M111.8 62.2C170.2 105.9 233 194.7 256 242.4c23-47.6 85.8-136.4 144.2-180.2c42.1-31.6 110.3-56 110.3 21.8c0 15.5-8.9 130.5-14.1 149.2C478.2 298 412 314.6 353.1 304.5c102.9 17.5 129.1 75.5 72.5 133.5c-107.4 110.2-154.3-27.6-166.3-62.9l0 0c-1.7-4.9-2.6-7.8-3.3-7.8s-1.6 3-3.3 7.8l0 0c-12 35.3-59 173.1-166.3 62.9c-56.5-58-30.4-116 72.5-133.5C100 314.6 33.8 298 15.7 233.1C10.4 214.4 1.5 99.4 1.5 83.9c0-77.8 68.2-53.4 110.3-21.8z" />`}</svg>`}renderLinkedInIcon(){let e=!!this.el.closest(k);return n`<svg height=100% style=${d({fillRule:"evenodd",clipRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2"})} version=1.1 viewBox="0 0 512 512" width=100% xmlns=http://www.w3.org/2000/svg>${w`<g id=g5891><path d="M512,64c0,-35.323 -28.677,-64 -64,-64l-384,0c-35.323,0 -64,28.677 -64,64l0,384c0,35.323 28.677,64 64,64l384,0c35.323,0 64,-28.677 64,-64l0,-384Z" id=background style=${d({fill:e?"#fff":"#000"})} /><g id=shapes><rect height=257.962 id=rect11 style=${d({fill:e?"#000":"#fff"})} width=85.76 x=61.053 y=178.667 /><path d="M104.512,54.28c-29.341,0 -48.512,19.29 -48.512,44.573c0,24.752 18.588,44.574 47.377,44.574l0.554,0c29.903,0 48.516,-19.822 48.516,-44.574c-0.555,-25.283 -18.611,-44.573 -47.935,-44.573Z" id=path13-0 style=${d({fill:e?"#000":"#fff",fillRule:"nonzero"})} /><path d="M357.278,172.601c-45.49,0 -65.866,25.017 -77.276,42.589l0,-36.523l-85.738,0c1.137,24.197 0,257.961 0,257.961l85.737,0l0,-144.064c0,-7.711 0.554,-15.42 2.827,-20.931c6.188,-15.4 20.305,-31.352 43.993,-31.352c31.012,0 43.436,23.664 43.436,58.327l0,138.02l85.741,0l0,-147.93c0,-79.237 -42.305,-116.097 -98.72,-116.097Z" id=path15 style=${d({fill:e?"#000":"#fff",fillRule:"nonzero"})} /></g></g>`}</svg>`}renderTip(){let e=this._messages.info;return n`<div class=${i(t.tipContainer)}><span class=${i(t.tipHeader)}><calcite-icon icon=lightbulb .scale=${this.scale}></calcite-icon><span>${e?.label}</span></span><p class=${i(t.tipContent)}>${e?.tooltip}</p></div>`}renderEmbed(){let e=this._messages.embed,s=document.dir==="rtl"?` ${t.rtl.textArea}`:"";return n`<div class=${i(t.embed.container)}><span class=${i(t.embed.header)}><calcite-icon icon=code .scale=${this.scale}></calcite-icon><span>${this._messages.embed?.label}</span></span><div class=${i(t.embed.embedCode.container)}><div class=${i(t.embed.embedCode.textArea)}><textarea cols=30 rows=5 readonly class=${i(s)} .value=${L(this.getEmbedCode()??"")} ${h(this.embedCodeRef)}></textarea><button id=copyEmbedToClipboard @click=${this.copyEmbedCode} class=${i(t.embed.embedCode.copyButton)}><calcite-icon icon=copy .scale=${this.scale}></calcite-icon><span>${e?.copy}</span></button></div><span class=${i(t.embed.textAreaText)}><slot name=text-area-text></slot></span><div class=${i(t.embed.dimensions.container)}><label class=${i(t.embed.dimensions.input)}><span>${e?.width}</span><input type=number @keydown=${o=>["e","E","+","-"].includes(o.key)&&o.preventDefault()} @change=${this.makeEmbedResizeHandler("width")} .value=${L(this.embedWidth??"")} min=${T} ${h(this.embedWidthRef)}></label><label class=${i(t.embed.dimensions.input)}><span>${e?.height}</span><input type=number @keydown=${o=>["e","E","+","-"].includes(o.key)&&o.preventDefault()} @change=${this.makeEmbedResizeHandler("height")} .value=${L(this.embedHeight??"")} min=${T} ${h(this.embedHeightRef)}></label></div></div></div>`}};B("instant-apps-social-share",z);return z},"intl","request","geometry/operators/projectOperator","geometry/Point","geometry/SpatialReference")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as d}from"./SOHNIGAO.js";import{b as c}from"./7EF56IQP.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{H as r,L as o,h as a,i as t}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";export default $arcgis.t(([g,p,{on:m}])=>{var v=a`:host{--default-width: auto;--width: var(--default-width);--padding: 10px;--border-style: 1px solid var(--calcite-color-border-1);--calcite-button-height: 48px;--calcite-icon-color: var(--calcite-color-text-3);display:block;width:var(--width);background:var(--background-color, var(--calcite-color-foreground-1));color:var(--calcite-color-text-1);font-size:var(--calcite-font-size--1);padding:var(--padding);box-sizing:border-box;>*{border:var(--border-style)}}[role=group]{display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:var(--calcite-button-height)}.selection-count{display:flex;align-items:center;justify-content:space-between;padding-inline-start:var(--padding);margin-block-start:var(--padding)}`,s=class extends r{constructor(){super(),this._messages=d({name:"instant-apps-selection-toolbar",blocking:!0}),this._selectionCount=0,this.disabled=!1,this.selectionManager=new g,this.selectionToolbarViewModel=new p({selectionManager:this.selectionManager})}static{this.properties={_selectionCount:16,view:0,selectionManager:0,selectionToolbarViewModel:0,selectedCount:32,sources:0,enabledTool:3,readyToSelect:39,continuousSelectionEnabled:5,disabled:5}}static{this.styles=v}get#e(){return this.disabled||this.selectionToolbarViewModel.state==="disabled"}set view(e){this.selectionManager.view=e,this.selectionToolbarViewModel.view=e}get view(){return this.selectionManager.view}get selectedCount(){return this._selectionCount}set sources(e){this.selectionManager.sources=e,this.selectionToolbarViewModel.sources=e}get sources(){return this.selectionManager.sources}get readyToSelect(){return!this.#e&&!!this.view&&!!this.sources?.length}set continuousSelectionEnabled(e){this.selectionToolbarViewModel.continuousSelectionEnabled=e}get continuousSelectionEnabled(){return this.selectionToolbarViewModel.continuousSelectionEnabled}clearSelection(){this.selectionManager.clear()}async getSelectedFeatures(){return this.selectionManager.getSelectedFeatures(null,{returnGeometry:!0})}load(){this.manager.onLifecycle(()=>m(()=>this.selectionManager,"selection-change",()=>{this._selectionCount=this.selectionManager.count}))}willUpdate(e){e.has("enabledTool")&&this.readyToSelect&&(this.enabledTool?this.selectionToolbarViewModel.activateTool(this.enabledTool):this.selectionToolbarViewModel.cancel())}_getSelectButtonClickEventHandler(e){return()=>{this.enabledTool===e?this.enabledTool=null:this.enabledTool=e}}_renderSelectionButton(e,i,u){let l=this.enabledTool===e,h={pressed:l},b=this._getSelectButtonClickEventHandler(e),n=`${e}-action`;return t`<calcite-action id=${n??o} .aria=${h} .active=${l} alignment=center .text=${i} @click=${b} .disabled=${this.disabled}><calcite-icon .icon=${u}></calcite-icon></calcite-action><calcite-tooltip .referenceElement=${n}><span>${i}</span></calcite-tooltip>`}_renderSelectionCount(){if(this._selectionCount>0){let e=this._selectionCount===1?this._messages.labels.singleFeatureSelected:this._messages.labels.multipleFeaturesSelected.replace("{number}",String(this._selectionCount));return t`<div class="selection-count"><span>${e}</span><calcite-button appearance=transparent .label=${this._messages.labels.deselectFeatures} @click=${this.clearSelection}><calcite-icon icon=x></calcite-icon></calcite-button></div>`}return null}render(){return t`<div role=group aria-label=${this._messages.labels.groupLabel??o}>${this._renderSelectionButton("point",this._messages.labels.selectCursor,"cursor")}${this._renderSelectionButton("rectangle",this._messages.labels.selectMarquee,"cursor-marquee")}${this._renderSelectionButton("lasso",this._messages.labels.selectLasso,"lasso-select")}</div>${this._renderSelectionCount()}`}};c("instant-apps-selection-toolbar",s);return s},"views/SelectionManager","widgets/support/SelectionToolbar/SelectionToolbarViewModel","core/reactiveUtils")
2
+ import{a as d}from"./SLC22JQP.js";import{b as c}from"./JTUQKBFR.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{H as r,L as o,h as a,i as t}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";export default $arcgis.t(([g,p,{on:m}])=>{var v=a`:host{--default-width: auto;--width: var(--default-width);--padding: 10px;--border-style: 1px solid var(--calcite-color-border-1);--calcite-button-height: 48px;--calcite-icon-color: var(--calcite-color-text-3);display:block;width:var(--width);background:var(--background-color, var(--calcite-color-foreground-1));color:var(--calcite-color-text-1);font-size:var(--calcite-font-size--1);padding:var(--padding);box-sizing:border-box;>*{border:var(--border-style)}}[role=group]{display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:var(--calcite-button-height)}.selection-count{display:flex;align-items:center;justify-content:space-between;padding-inline-start:var(--padding);margin-block-start:var(--padding)}`,s=class extends r{constructor(){super(),this._messages=d({name:"instant-apps-selection-toolbar",blocking:!0}),this._selectionCount=0,this.disabled=!1,this.selectionManager=new g,this.selectionToolbarViewModel=new p({selectionManager:this.selectionManager})}static{this.properties={_selectionCount:16,view:0,selectionManager:0,selectionToolbarViewModel:0,selectedCount:32,sources:0,enabledTool:3,readyToSelect:39,continuousSelectionEnabled:5,disabled:5}}static{this.styles=v}get#e(){return this.disabled||this.selectionToolbarViewModel.state==="disabled"}set view(e){this.selectionManager.view=e,this.selectionToolbarViewModel.view=e}get view(){return this.selectionManager.view}get selectedCount(){return this._selectionCount}set sources(e){this.selectionManager.sources=e,this.selectionToolbarViewModel.sources=e}get sources(){return this.selectionManager.sources}get readyToSelect(){return!this.#e&&!!this.view&&!!this.sources?.length}set continuousSelectionEnabled(e){this.selectionToolbarViewModel.continuousSelectionEnabled=e}get continuousSelectionEnabled(){return this.selectionToolbarViewModel.continuousSelectionEnabled}clearSelection(){this.selectionManager.clear()}async getSelectedFeatures(){return this.selectionManager.getSelectedFeatures(null,{returnGeometry:!0})}load(){this.manager.onLifecycle(()=>m(()=>this.selectionManager,"selection-change",()=>{this._selectionCount=this.selectionManager.count}))}willUpdate(e){e.has("enabledTool")&&this.readyToSelect&&(this.enabledTool?this.selectionToolbarViewModel.activateTool(this.enabledTool):this.selectionToolbarViewModel.cancel())}_getSelectButtonClickEventHandler(e){return()=>{this.enabledTool===e?this.enabledTool=null:this.enabledTool=e}}_renderSelectionButton(e,i,u){let l=this.enabledTool===e,h={pressed:l},b=this._getSelectButtonClickEventHandler(e),n=`${e}-action`;return t`<calcite-action id=${n??o} .aria=${h} .active=${l} alignment=center .text=${i} @click=${b} .disabled=${this.disabled}><calcite-icon .icon=${u}></calcite-icon></calcite-action><calcite-tooltip .referenceElement=${n}><span>${i}</span></calcite-tooltip>`}_renderSelectionCount(){if(this._selectionCount>0){let e=this._selectionCount===1?this._messages.labels.singleFeatureSelected:this._messages.labels.multipleFeaturesSelected.replace("{number}",String(this._selectionCount));return t`<div class="selection-count"><span>${e}</span><calcite-button appearance=transparent .label=${this._messages.labels.deselectFeatures} @click=${this.clearSelection}><calcite-icon icon=x></calcite-icon></calcite-button></div>`}return null}render(){return t`<div role=group aria-label=${this._messages.labels.groupLabel??o}>${this._renderSelectionButton("point",this._messages.labels.selectCursor,"cursor")}${this._renderSelectionButton("rectangle",this._messages.labels.selectMarquee,"cursor-marquee")}${this._renderSelectionButton("lasso",this._messages.labels.selectLasso,"lasso-select")}</div>${this._renderSelectionCount()}`}};c("instant-apps-selection-toolbar",s);return s},"views/SelectionManager","widgets/support/SelectionToolbar/SelectionToolbarViewModel","core/reactiveUtils")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as u}from"./VVZAS55G.js";import{a as m}from"./SOHNIGAO.js";import{b as d}from"./7EF56IQP.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{H as p,J as a,g as c,h as r,i as e,r as h}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";function f(){return new u({whiteList:{h1:["style"],h2:["style"],h3:["style"],h4:["style"],h5:["style"],h6:["style"],img:["style","src","width","height"],pre:["style"],p:["id","class","style"],div:["id","class","style","role"],span:["id","class","style","role"],figure:["class","style"]}},!0)}function g(i){window?.localStorage.setItem(i,"false")}function b(i){return!!window?.localStorage?.getItem(i)}function _(i){window?.localStorage?.removeItem(i)}var x=r`:host{--instant-apps-splash-content-max-height: 100%;--instant-apps-splash-back-content-display: flex;display:block}:host .image.image_resized img{width:100%}:host .instant-apps-splash__back-content{display:var(--instant-apps-splash-back-content-display);align-items:center}:host .instant-apps-splash__back-content calcite-label{--calcite-label-margin-bottom: 0}:host .instant-apps-splash__content{max-height:var(--instant-apps-splash-content-max-height)}:host .instant-apps-splash__confirmation-tooltip{display:inline-block;max-width:200px;word-wrap:break-word}:host .instant-apps-splash__required{display:inline-block;margin-inline-start:var(--calcite-spacing-xxs);color:var(--calcite-color-status-danger)}:host .instant-apps-splash__footer{width:100%;display:flex;justify-content:space-between}:host .instant-apps-splash__button-container{display:flex}:host .instant-apps-splash__button-container calcite-button:not(:last-child){margin-inline-end:var(--calcite-spacing-sm)}@media(max-width:816px){:host .instant-apps-splash__footer{justify-content:flex-start;flex-direction:column}:host .instant-apps-splash__back-content{margin-bottom:var(--calcite-spacing-sm)}:host .instant-apps-splash__back-content span{display:flex;align-items:center}:host .instant-apps-splash__button-container{width:100%;gap:var(--calcite-spacing-sm);justify-content:space-between}:host .instant-apps-splash__button-container calcite-button:not(:last-child){margin-inline-end:0}:host .instant-apps-splash__button-container>*{flex:1 1 0;min-width:0}}`,n={back:"instant-apps-splash__back-content",confirmationTooltip:"instant-apps-splash__confirmation-tooltip",requiredText:"instant-apps-splash__required",footer:"instant-apps-splash__footer",buttonContainer:"instant-apps-splash__button-container"},l=class extends p{constructor(){super(...arguments),this._messages=m({name:"instant-apps-splash"}),this._sanitizer=f(),this.titleText="",this.content="",this.primaryButtonText="",this.open=!0,this.closeButtonDisabled=!1,this.outsideCloseDisabled=!1,this.secondaryButton=!1,this.closeBehavior="permanent-dismissal",this.confirmationText="",this.isConfirmed=!1,this.splashClose=h()}static{this.properties={localStorageKey:1,titleText:1,content:1,primaryButtonText:1,open:5,closeButtonDisabled:5,outsideCloseDisabled:5,secondaryButton:5,secondaryButtonText:1,secondaryButtonIcon:1,secondaryButtonCallback:0,closeBehavior:1,confirmationText:1,isConfirmed:32}}static{this.styles=x}load(){let t;if(this.closeBehavior==="confirmation"||this.closeBehavior==="dismissal")t=!0;else{let{localStorageKey:s}=this;s?t=this.open&&!b(s):t=this.open}this.el.open=t,this.content&&this._sanitizer&&this.sanitizeContent()}willUpdate(t){t.has("content")&&this.sanitizeContent()}sanitizeContent(){this.content=this._sanitizer.sanitize(this.content)}close(){this.open=!1,this.splashClose.emit()}getCheckboxText(){return this.closeBehavior==="confirmation"?this.confirmationText?this.confirmationText:`${this._messages.confirmationText}`:this._messages?.dontShowThisAgain}handleDontShowThisAgain(t){if(this.closeBehavior==="confirmation"){let s=t.target,{checked:o}=s;c(()=>{this.isConfirmed=o})}else if(this.closeBehavior==="permanent-dismissal"){let{localStorageKey:s}=this;if(!s)return;let o=t.target,{checked:y}=o;y?g(s):_(s)}}render(){return e`<calcite-dialog .open=${this.open} .focusTrapOptions=${{allowOutsideClick:!0}} modal .heading=${this.titleText} aria-describedby=description @calciteDialogClose=${this.close} top-layer-disabled .closeDisabled=${this.closeBehavior==="confirmation"||this.closeButtonDisabled} .outsideCloseDisabled=${this.closeBehavior==="confirmation"||this.outsideCloseDisabled} .escapeDisabled=${this.closeBehavior==="confirmation"}><div id=description .innerHTML=${this.content??""}></div><slot name=custom-action></slot><div class=${a(n.footer)} slot=footer>${this.localStorageKey&&this.closeBehavior==="permanent-dismissal"||this.closeBehavior==="confirmation"?this.renderCheckbox():null}<div class=${a(n.buttonContainer)}>${this.secondaryButton?this.renderSecondaryButton():null}${this.renderPrimaryButton()}</div>${this.closeBehavior==="confirmation"&&!this.isConfirmed&&e`<calcite-tooltip reference-element=primary-button overlay-positioning=fixed placement=top><span class=${a(n.confirmationTooltip)}>${this._messages?.confirmationTooltip}</span></calcite-tooltip>`||""}</div></calcite-dialog>`}renderCheckbox(){let{localStorageKey:t}=this,s=this.closeBehavior!=="confirmation"&&t&&b(t)?!0:null;return e`<div class=${a(n.back)}><calcite-label layout=inline><calcite-checkbox @calciteCheckboxChange=${this.handleDontShowThisAgain} .checked=${s??void 0}></calcite-checkbox><span>${this.getCheckboxText()}<span class=${a(n.requiredText)}>${this.closeBehavior==="confirmation"&&`(${this._messages?.required})`||""}</span></span></calcite-label></div>`}renderPrimaryButton(){let{primaryButtonText:t}=this;return e`<calcite-button id=primary-button @click=${this.close} slot=footer-end .disabled=${this.closeBehavior==="confirmation"?!this.isConfirmed:!1}>${t||this._messages?.enter}</calcite-button>`}renderSecondaryButton(){return e`<calcite-button @click=${this.secondaryButtonCallback} slot=footer-end .iconStart=${this.secondaryButtonIcon} appearance=outline .disabled=${this.closeBehavior==="confirmation"?!this.isConfirmed:!1}>${this.secondaryButtonText}</calcite-button>`}};d("instant-apps-splash",l);export{l as InstantAppsSplash};
2
+ import{a as u}from"./VVZAS55G.js";import{a as m}from"./SLC22JQP.js";import{b as d}from"./JTUQKBFR.js";import"./DIKAKOU5.js";import"./S423P2GA.js";import{H as p,J as a,g as c,h as r,i as e,r as h}from"./P4KZ6OZF.js";import"./QPIMTXPL.js";function f(){return new u({whiteList:{h1:["style"],h2:["style"],h3:["style"],h4:["style"],h5:["style"],h6:["style"],img:["style","src","width","height"],pre:["style"],p:["id","class","style"],div:["id","class","style","role"],span:["id","class","style","role"],figure:["class","style"]}},!0)}function g(i){window?.localStorage.setItem(i,"false")}function b(i){return!!window?.localStorage?.getItem(i)}function _(i){window?.localStorage?.removeItem(i)}var x=r`:host{--instant-apps-splash-content-max-height: 100%;--instant-apps-splash-back-content-display: flex;display:block}:host .image.image_resized img{width:100%}:host .instant-apps-splash__back-content{display:var(--instant-apps-splash-back-content-display);align-items:center}:host .instant-apps-splash__back-content calcite-label{--calcite-label-margin-bottom: 0}:host .instant-apps-splash__content{max-height:var(--instant-apps-splash-content-max-height)}:host .instant-apps-splash__confirmation-tooltip{display:inline-block;max-width:200px;word-wrap:break-word}:host .instant-apps-splash__required{display:inline-block;margin-inline-start:var(--calcite-spacing-xxs);color:var(--calcite-color-status-danger)}:host .instant-apps-splash__footer{width:100%;display:flex;justify-content:space-between}:host .instant-apps-splash__button-container{display:flex}:host .instant-apps-splash__button-container calcite-button:not(:last-child){margin-inline-end:var(--calcite-spacing-sm)}@media(max-width:816px){:host .instant-apps-splash__footer{justify-content:flex-start;flex-direction:column}:host .instant-apps-splash__back-content{margin-bottom:var(--calcite-spacing-sm)}:host .instant-apps-splash__back-content span{display:flex;align-items:center}:host .instant-apps-splash__button-container{width:100%;gap:var(--calcite-spacing-sm);justify-content:space-between}:host .instant-apps-splash__button-container calcite-button:not(:last-child){margin-inline-end:0}:host .instant-apps-splash__button-container>*{flex:1 1 0;min-width:0}}`,n={back:"instant-apps-splash__back-content",confirmationTooltip:"instant-apps-splash__confirmation-tooltip",requiredText:"instant-apps-splash__required",footer:"instant-apps-splash__footer",buttonContainer:"instant-apps-splash__button-container"},l=class extends p{constructor(){super(...arguments),this._messages=m({name:"instant-apps-splash"}),this._sanitizer=f(),this.titleText="",this.content="",this.primaryButtonText="",this.open=!0,this.closeButtonDisabled=!1,this.outsideCloseDisabled=!1,this.secondaryButton=!1,this.closeBehavior="permanent-dismissal",this.confirmationText="",this.isConfirmed=!1,this.splashClose=h()}static{this.properties={localStorageKey:1,titleText:1,content:1,primaryButtonText:1,open:5,closeButtonDisabled:5,outsideCloseDisabled:5,secondaryButton:5,secondaryButtonText:1,secondaryButtonIcon:1,secondaryButtonCallback:0,closeBehavior:1,confirmationText:1,isConfirmed:32}}static{this.styles=x}load(){let t;if(this.closeBehavior==="confirmation"||this.closeBehavior==="dismissal")t=!0;else{let{localStorageKey:s}=this;s?t=this.open&&!b(s):t=this.open}this.el.open=t,this.content&&this._sanitizer&&this.sanitizeContent()}willUpdate(t){t.has("content")&&this.sanitizeContent()}sanitizeContent(){this.content=this._sanitizer.sanitize(this.content)}close(){this.open=!1,this.splashClose.emit()}getCheckboxText(){return this.closeBehavior==="confirmation"?this.confirmationText?this.confirmationText:`${this._messages.confirmationText}`:this._messages?.dontShowThisAgain}handleDontShowThisAgain(t){if(this.closeBehavior==="confirmation"){let s=t.target,{checked:o}=s;c(()=>{this.isConfirmed=o})}else if(this.closeBehavior==="permanent-dismissal"){let{localStorageKey:s}=this;if(!s)return;let o=t.target,{checked:y}=o;y?g(s):_(s)}}render(){return e`<calcite-dialog .open=${this.open} .focusTrapOptions=${{allowOutsideClick:!0}} modal .heading=${this.titleText} aria-describedby=description @calciteDialogClose=${this.close} top-layer-disabled .closeDisabled=${this.closeBehavior==="confirmation"||this.closeButtonDisabled} .outsideCloseDisabled=${this.closeBehavior==="confirmation"||this.outsideCloseDisabled} .escapeDisabled=${this.closeBehavior==="confirmation"}><div id=description .innerHTML=${this.content??""}></div><slot name=custom-action></slot><div class=${a(n.footer)} slot=footer>${this.localStorageKey&&this.closeBehavior==="permanent-dismissal"||this.closeBehavior==="confirmation"?this.renderCheckbox():null}<div class=${a(n.buttonContainer)}>${this.secondaryButton?this.renderSecondaryButton():null}${this.renderPrimaryButton()}</div>${this.closeBehavior==="confirmation"&&!this.isConfirmed&&e`<calcite-tooltip reference-element=primary-button overlay-positioning=fixed placement=top><span class=${a(n.confirmationTooltip)}>${this._messages?.confirmationTooltip}</span></calcite-tooltip>`||""}</div></calcite-dialog>`}renderCheckbox(){let{localStorageKey:t}=this,s=this.closeBehavior!=="confirmation"&&t&&b(t)?!0:null;return e`<div class=${a(n.back)}><calcite-label layout=inline><calcite-checkbox @calciteCheckboxChange=${this.handleDontShowThisAgain} .checked=${s??void 0}></calcite-checkbox><span>${this.getCheckboxText()}<span class=${a(n.requiredText)}>${this.closeBehavior==="confirmation"&&`(${this._messages?.required})`||""}</span></span></calcite-label></div>`}renderPrimaryButton(){let{primaryButtonText:t}=this;return e`<calcite-button id=primary-button @click=${this.close} slot=footer-end .disabled=${this.closeBehavior==="confirmation"?!this.isConfirmed:!1}>${t||this._messages?.enter}</calcite-button>`}renderSecondaryButton(){return e`<calcite-button @click=${this.secondaryButtonCallback} slot=footer-end .iconStart=${this.secondaryButtonIcon} appearance=outline .disabled=${this.closeBehavior==="confirmation"?!this.isConfirmed:!1}>${this.secondaryButtonText}</calcite-button>`}};d("instant-apps-splash",l);export{l as InstantAppsSplash};
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
+ import"./QPIMTXPL.js";var e="\u0394\u03B5\u03BD \u03AD\u03C7\u03B5\u03C4\u03B5 \u03B1\u03C1\u03BA\u03B5\u03C4\u03AD\u03C2 \u03BC\u03BF\u03BD\u03AC\u03B4\u03B5\u03C2 \u03BA\u03B1\u03C4\u03B1\u03BD\u03AC\u03BB\u03C9\u03C3\u03B7\u03C2 \u03B3\u03B9\u03B1 \u03BD\u03B1 \u03B5\u03BA\u03C4\u03B5\u03BB\u03AD\u03C3\u03B5\u03C4\u03B5 \u03B1\u03C5\u03C4\u03AE\u03BD \u03C4\u03B7 \u03BB\u03B5\u03B9\u03C4\u03BF\u03C5\u03C1\u03B3\u03AF\u03B1. \u0395\u03C0\u03B9\u03BA\u03BF\u03B9\u03BD\u03C9\u03BD\u03AE\u03C3\u03C4\u03B5 \u03BC\u03B5 \u03C4\u03BF\u03BD \u03B4\u03B9\u03B1\u03C7\u03B5\u03B9\u03C1\u03B9\u03C3\u03C4\u03AE \u03C4\u03BF\u03C5 \u03C3\u03C5\u03C3\u03C4\u03AE\u03BC\u03B1\u03C4\u03BF\u03C2 ArcGIS \u03B3\u03B9\u03B1 \u03B2\u03BF\u03AE\u03B8\u03B5\u03B9\u03B1.",a="\u0391\u03C5\u03C4\u03CC \u03C4\u03BF \u03B5\u03C1\u03B3\u03B1\u03BB\u03B5\u03AF\u03BF \u03B4\u03B7\u03BC\u03BF\u03C3\u03B9\u03B5\u03CD\u03C4\u03B7\u03BA\u03B5 \u03B1\u03C0\u03CC \u03AD\u03BD\u03B1 notebook. \u0397 \u03C0\u03C1\u03CC\u03C3\u03B2\u03B1\u03C3\u03B7 \u03C3\u03C4\u03BF ArcGIS Notebooks \u03AD\u03C7\u03B5\u03B9 \u03B1\u03C0\u03B1\u03B3\u03BF\u03C1\u03B5\u03C5\u03C4\u03B5\u03AF \u03B3\u03B9\u03B1 \u03C4\u03BF\u03BD \u03BF\u03C1\u03B3\u03B1\u03BD\u03B9\u03C3\u03BC\u03CC \u03C3\u03B1\u03C2. \u0395\u03C0\u03B9\u03BA\u03BF\u03B9\u03BD\u03C9\u03BD\u03AE\u03C3\u03C4\u03B5 \u03BC\u03B5 \u03C4\u03BF\u03BD \u03B4\u03B9\u03B1\u03C7\u03B5\u03B9\u03C1\u03B9\u03C3\u03C4\u03AE \u03B3\u03B9\u03B1 \u03BD\u03B1 \u03C0\u03C1\u03BF\u03C3\u03B1\u03C1\u03BC\u03BF\u03C3\u03C4\u03B5\u03AF \u03B7 \u03C1\u03CD\u03B8\u03BC\u03B9\u03C3\u03B7.",r="\u03A4\u03BF ${ dataPath } \u03B4\u03B5\u03BD \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 ${ additionalProperty }.",t="\u03A4\u03BF ${ dataPath } \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03C3\u03C5\u03BC\u03C6\u03C9\u03BD\u03B5\u03AF \u03BC\u03B5 \u03C4\u03B7 \u03B4\u03BF\u03BC\u03AE \u03B5\u03BD\u03CC\u03C2 \u03B1\u03C0\u03CC \u03C4\u03B1 \u03B5\u03BE\u03AE\u03C2: ${ schemaOptions }.",o="\u0394\u03BF\u03BA\u03B9\u03BC\u03AC\u03C3\u03C4\u03B5 \u03BD\u03B1 \u03B1\u03C0\u03BF\u03B8\u03B7\u03BA\u03B5\u03CD\u03C3\u03B5\u03C4\u03B5 \u03C4\u03BF\u03BD \u03C7\u03AC\u03C1\u03C4\u03B7 \u03BE\u03B1\u03BD\u03AC.",i="\u0397 \u03B5\u03BA\u03C4\u03AF\u03BC\u03B7\u03C3\u03B7 \u03BC\u03BF\u03BD\u03AC\u03B4\u03B1\u03C2 \u03BA\u03B1\u03C4\u03B1\u03BD\u03AC\u03BB\u03C9\u03C3\u03B7\u03C2 \u03B1\u03C0\u03AD\u03C4\u03C5\u03C7\u03B5. \u039C\u03B5\u03C4\u03B1\u03BA\u03B9\u03BD\u03B7\u03B8\u03B5\u03AF\u03C4\u03B5 \u03C0\u03C1\u03BF\u03C2 \u03BA\u03AC\u03C4\u03C9, \u03B4\u03B9\u03BF\u03C1\u03B8\u03CE\u03C3\u03C4\u03B5 \u03C4\u03B1 \u03C3\u03C6\u03AC\u03BB\u03BC\u03B1\u03C4\u03B1 \u03BA\u03B1\u03B9 \u03C5\u03C0\u03BF\u03BB\u03BF\u03B3\u03AF\u03C3\u03C4\u03B5 \u03BE\u03B1\u03BD\u03AC \u03C4\u03B9\u03C2 \u03BC\u03BF\u03BD\u03AC\u03B4\u03B5\u03C2 \u03BA\u03B1\u03C4\u03B1\u03BD\u03AC\u03BB\u03C9\u03C3\u03B7\u03C2.",s="\u03A0\u03C1\u03BF\u03AD\u03BA\u03C5\u03C8\u03B5 \u03BA\u03AC\u03C0\u03BF\u03B9\u03BF \u03C3\u03C6\u03AC\u03BB\u03BC\u03B1 \u03BA\u03B1\u03C4\u03AC \u03C4\u03B7\u03BD \u03B5\u03BA\u03C4\u03AD\u03BB\u03B5\u03C3\u03B7 \u03C4\u03B7\u03C2 \u03B1\u03BD\u03AC\u03BB\u03C5\u03C3\u03B7\u03C2.",l="\u03A4\u03BF ${ dataPath } \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03B9\u03C3\u03BF\u03CD\u03C4\u03B1\u03B9 \u03BC\u03B5 \u03BC\u03AF\u03B1 \u03B1\u03C0\u03CC \u03C4\u03B9\u03C2 \u03B5\u03BE\u03AE\u03C2 \u03B5\u03C0\u03B9\u03C4\u03C1\u03B5\u03C0\u03CC\u03BC\u03B5\u03BD\u03B5\u03C2 \u03C4\u03B9\u03BC\u03AD\u03C2: ${ allowedValues }.",n="\u0391\u03C0\u03BF\u03C4\u03C5\u03C7\u03AF\u03B1 \u03B1\u03C0\u03BF\u03B8\u03AE\u03BA\u03B5\u03C5\u03C3\u03B7\u03C2 \u03B9\u03C3\u03C4\u03BF\u03C1\u03B9\u03BA\u03BF\u03CD \u03B1\u03BD\u03AC\u03BB\u03C5\u03C3\u03B7\u03C2",d="\u039F \u03C7\u03CE\u03C1\u03BF\u03C2 \u03B1\u03C0\u03BF\u03B8\u03AE\u03BA\u03B5\u03C5\u03C3\u03B7\u03C2 \u03B9\u03C3\u03C4\u03BF\u03C1\u03B9\u03BA\u03BF\u03CD \u03B5\u03AF\u03BD\u03B1\u03B9 \u03B3\u03B5\u03BC\u03AC\u03C4\u03BF\u03C2 \u039A\u03B1\u03C4\u03B1\u03C1\u03B3\u03AE\u03C3\u03C4\u03B5 \u03BC\u03B5\u03C1\u03B9\u03BA\u03AC \u03B1\u03BD\u03C4\u03B9\u03BA\u03B5\u03AF\u03BC\u03B5\u03BD\u03B1 \u03B1\u03C0\u03CC \u03C4\u03BF \u03B9\u03C3\u03C4\u03BF\u03C1\u03B9\u03BA\u03CC \u03B1\u03BD\u03AC\u03BB\u03C5\u03C3\u03B7\u03C2 \u03BA\u03B1\u03B9 \u03C0\u03C1\u03BF\u03C3\u03C0\u03B1\u03B8\u03AE\u03C3\u03C4\u03B5 \u03BD\u03B1 \u03B1\u03C0\u03BF\u03B8\u03B7\u03BA\u03B5\u03CD\u03C3\u03B5\u03C4\u03B5 \u03BE\u03B1\u03BD\u03AC.",c="\u03A4\u03BF \u03CC\u03BD\u03BF\u03BC\u03B1 \u03C4\u03B7\u03C2 \u03C5\u03C0\u03B7\u03C1\u03B5\u03C3\u03AF\u03B1\u03C2 \u03C0\u03B5\u03C1\u03B9\u03AD\u03C7\u03B5\u03B9 \u03AD\u03BD\u03B1\u03BD \u03AE \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03BF\u03C5\u03C2 \u03BC\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03BF\u03C5\u03C2 \u03C7\u03B1\u03C1\u03B1\u03BA\u03C4\u03AE\u03C1\u03B5\u03C2.",m="\u0397 \u03B1\u03C0\u03BF\u03B8\u03AE\u03BA\u03B5\u03C5\u03C3\u03B7 \u03C4\u03BF\u03C5 \u03C0\u03C1\u03BF\u03C3\u03C9\u03C1\u03B9\u03BD\u03BF\u03CD \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03BF\u03CD \u03B5\u03C0\u03B9\u03C0\u03AD\u03B4\u03BF\u03C5 \u03C9\u03C2 hosted feature layer \u03B4\u03B5\u03BD \u03BF\u03BB\u03BF\u03BA\u03BB\u03B7\u03C1\u03CE\u03B8\u03B7\u03BA\u03B5.",u="\u0393\u03B9\u03B1 \u03C4\u03B7\u03BD \u03B5\u03BA\u03C4\u03AD\u03BB\u03B5\u03C3\u03B7 \u03B1\u03C5\u03C4\u03BF\u03CD \u03C4\u03BF\u03C5 \u03B5\u03C1\u03B3\u03B1\u03BB\u03B5\u03AF\u03BF\u03C5 \u03B1\u03C0\u03B1\u03B9\u03C4\u03BF\u03CD\u03BD\u03C4\u03B1\u03B9 \u03C4\u03B1 \u03C0\u03B1\u03C1\u03B1\u03BA\u03AC\u03C4\u03C9 \u03B4\u03B9\u03BA\u03B1\u03B9\u03CE\u03BC\u03B1\u03C4\u03B1: ${ privileges }. <calcite-link href='${docLink}' target='_blank'>\u039C\u03AC\u03B8\u03B5\u03C4\u03B5 \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03B5\u03C2 \u03C0\u03BB\u03B7\u03C1\u03BF\u03C6\u03BF\u03C1\u03AF\u03B5\u03C2.</calcite-link>",h="\u0391\u03C0\u03BF\u03C4\u03C5\u03C7\u03AF\u03B1 \u03BB\u03AE\u03C8\u03B7\u03C2 \u03C4\u03C9\u03BD \u03B9\u03B4\u03B9\u03BF\u03C4\u03AE\u03C4\u03C9\u03BD \u03BA\u03BB\u03B5\u03B9\u03B4\u03B9\u03BF\u03CD.",E="\u0391\u03BD\u03B5\u03C0\u03B9\u03C4\u03C5\u03C7\u03AE\u03C2 \u03C6\u03CC\u03C1\u03C4\u03C9\u03C3\u03B7 \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03BF\u03CD \u03B5\u03C0\u03B9\u03C0\u03AD\u03B4\u03BF\u03C5.",y="\u03A4\u03BF \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03CC \u03B5\u03C0\u03AF\u03C0\u03B5\u03B4\u03BF \u03B4\u03B5\u03BD \u03B5\u03AF\u03BD\u03B1\u03B9 \u03B4\u03B9\u03B1\u03B8\u03AD\u03C3\u03B9\u03BC\u03BF.",P="\u03A4\u03BF ${ dataPath } \u03B4\u03B5\u03BD \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03B1 \u03B1\u03C0\u03CC ${ limit } \u03C3\u03C4\u03BF\u03B9\u03C7\u03B5\u03AF\u03B1.",f="\u03A0\u03B1\u03C1\u03BF\u03C5\u03C3\u03B9\u03AC\u03C3\u03C4\u03B7\u03BA\u03B5 \u03BA\u03AC\u03C0\u03BF\u03B9\u03BF \u03C3\u03C6\u03AC\u03BB\u03BC\u03B1 \u03BA\u03B1\u03C4\u03AC \u03C4\u03B7\u03BD \u03B1\u03C0\u03BF\u03B8\u03AE\u03BA\u03B5\u03C5\u03C3\u03B7 \u03C4\u03BF\u03C5 \u03BC\u03BF\u03BD\u03C4\u03AD\u03BB\u03BF\u03C5. \u0394\u03BF\u03BA\u03B9\u03BC\u03AC\u03C3\u03C4\u03B5 \u03BD\u03B1 \u03C4\u03BF \u03B1\u03C0\u03BF\u03B8\u03B7\u03BA\u03B5\u03CD\u03C3\u03B5\u03C4\u03B5 \u03BE\u03B1\u03BD\u03AC.",p="\u03A4\u03BF ${ dataPath } \u03B4\u03B5\u03BD \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 \u03BB\u03B9\u03B3\u03CC\u03C4\u03B5\u03C1\u03B1 \u03B1\u03C0\u03CC ${ limit } \u03C3\u03C4\u03BF\u03B9\u03C7\u03B5\u03AF\u03B1.",k="\u03A4\u03BF ${ dataPath } \u03B4\u03B5\u03BD \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 \u03BB\u03B9\u03B3\u03CC\u03C4\u03B5\u03C1\u03BF\u03C5\u03C2 \u03B1\u03C0\u03CC ${ limit } \u03C7\u03B1\u03C1\u03B1\u03BA\u03C4\u03AE\u03C1\u03B5\u03C2.",$="\u0391\u03C0\u03AD\u03C4\u03C5\u03C7\u03B5 \u03B7 \u03C6\u03CC\u03C1\u03C4\u03C9\u03C3\u03B7 \u03C4\u03BF\u03C5 \u03C3\u03C4\u03BF\u03B9\u03C7\u03B5\u03AF\u03BF\u03C5 \u03BC\u03BF\u03BD\u03C4\u03AD\u03BB\u03BF\u03C5. \u0392\u03B5\u03B2\u03B1\u03B9\u03C9\u03B8\u03B5\u03AF\u03C4\u03B5 \u03CC\u03C4\u03B9 \u03C4\u03BF \u03BC\u03BF\u03BD\u03C4\u03AD\u03BB\u03BF \u03C5\u03C0\u03AC\u03C1\u03C7\u03B5\u03B9 \u03BA\u03B1\u03B9 \u03CC\u03C4\u03B9 \u03AD\u03C7\u03B5\u03B9 \u03B5\u03BA\u03C7\u03C9\u03C1\u03B7\u03B8\u03B5\u03AF \u03AC\u03B4\u03B5\u03B9\u03B1 \u03C0\u03C1\u03CC\u03C3\u03B2\u03B1\u03C3\u03B7\u03C2 \u03C3\u03B5 \u03B1\u03C5\u03C4\u03CC.",S="\u0391\u03C0\u03BF\u03C4\u03C5\u03C7\u03AF\u03B1 \u03BF\u03BB\u03BF\u03BA\u03BB\u03AE\u03C1\u03C9\u03C3\u03B7\u03C2 \u03B1\u03B9\u03C4\u03AE\u03BC\u03B1\u03C4\u03BF\u03C2",v="\u0394\u03B5\u03BD \u03AD\u03C7\u03B5\u03C4\u03B5 \u03AC\u03B4\u03B5\u03B9\u03B1 \u03B3\u03B9\u03B1 \u03B5\u03BA\u03C4\u03AD\u03BB\u03B5\u03C3\u03B7 \u03B1\u03C5\u03C4\u03BF\u03CD \u03C4\u03BF\u03C5 \u03B5\u03C1\u03B3\u03B1\u03BB\u03B5\u03AF\u03BF\u03C5. <calcite-link target='_blank' href='${ docLink }'>\u039C\u03AC\u03B8\u03B5\u03C4\u03B5 \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03B5\u03C2 \u03C0\u03BB\u03B7\u03C1\u03BF\u03C6\u03BF\u03C1\u03AF\u03B5\u03C2.</calcite-link>",F="\u0391\u03C0\u03BF\u03C4\u03C5\u03C7\u03AF\u03B1 \u03C3\u03CD\u03BD\u03B4\u03B5\u03C3\u03B7\u03C2 \u03C3\u03C4\u03B7\u03BD \u03C0\u03CD\u03BB\u03B7.",I="\u0391\u03C0\u03BF\u03C4\u03C5\u03C7\u03AF\u03B1 \u03B1\u03BD\u03AC\u03B3\u03BD\u03C9\u03C3\u03B7\u03C2 \u03B4\u03B5\u03B4\u03BF\u03BC\u03AD\u03BD\u03C9\u03BD \u03B5\u03B9\u03C3\u03CC\u03B4\u03BF\u03C5.",T="\u0391\u03C0\u03CC \u03C4\u03BF ${ dataPath } \u03BB\u03B5\u03AF\u03C0\u03B5\u03B9 \u03BC\u03B9\u03B1 \u03B9\u03B4\u03B9\u03CC\u03C4\u03B7\u03C4\u03B1 \u03BC\u03B5 \u03C4\u03BF \u03CC\u03BD\u03BF\u03BC\u03B1 ${ missingProperty }.",b="\u03A5\u03C0\u03AC\u03C1\u03C7\u03B5\u03B9 \u03AE\u03B4\u03B7 \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03CC \u03B5\u03C0\u03AF\u03C0\u03B5\u03B4\u03BF \u03B1\u03C0\u03BF\u03C4\u03B5\u03BB\u03AD\u03C3\u03BC\u03B1\u03C4\u03BF\u03C2 \u03BC\u03B5 \u03B1\u03C5\u03C4\u03CC \u03C4\u03BF \u03CC\u03BD\u03BF\u03BC\u03B1. \u03A4\u03B1 \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03AC \u03B5\u03C0\u03AF\u03C0\u03B5\u03B4\u03B1 \u03C0\u03BF\u03C5 \u03C0\u03C1\u03BF\u03BA\u03CD\u03C0\u03C4\u03BF\u03C5\u03BD \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03AD\u03C7\u03BF\u03C5\u03BD \u03BC\u03BF\u03BD\u03B1\u03B4\u03B9\u03BA\u03CC \u03CC\u03BD\u03BF\u03BC\u03B1 \u03C3\u03B5 \u03BF\u03BB\u03CC\u03BA\u03BB\u03B7\u03C1\u03BF \u03C4\u03BF\u03BD \u03BF\u03C1\u03B3\u03B1\u03BD\u03B9\u03C3\u03BC\u03CC. \u03A7\u03C1\u03B7\u03C3\u03B9\u03BC\u03BF\u03C0\u03BF\u03B9\u03AE\u03C3\u03C4\u03B5 \u03B4\u03B9\u03B1\u03C6\u03BF\u03C1\u03B5\u03C4\u03B9\u03BA\u03CC \u03CC\u03BD\u03BF\u03BC\u03B1.",L="\u03A4\u03BF \u03CC\u03BD\u03BF\u03BC\u03B1 \u03B5\u03BE\u03CC\u03B4\u03BF\u03C5 \u03C0\u03B5\u03C1\u03B9\u03AD\u03C7\u03B5\u03B9 \u03AD\u03BD\u03B1\u03BD \u03AE \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03BF\u03C5\u03C2 \u03BC\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03BF\u03C5\u03C2 \u03C7\u03B1\u03C1\u03B1\u03BA\u03C4\u03AE\u03C1\u03B5\u03C2. <calcite-link href='${docLink}' target='_blank'>\u039C\u03AC\u03B8\u03B5\u03C4\u03B5 \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03B5\u03C2 \u03C0\u03BB\u03B7\u03C1\u03BF\u03C6\u03BF\u03C1\u03AF\u03B5\u03C2.</calcite-link>",g="\u0397 \u03B4\u03B7\u03BC\u03BF\u03C3\u03AF\u03B5\u03C5\u03C3\u03B7 \u03C4\u03BF\u03C5 \u03C0\u03C1\u03BF\u03C3\u03C9\u03C1\u03B9\u03BD\u03BF\u03CD \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03BF\u03CD \u03B5\u03C0\u03B9\u03C0\u03AD\u03B4\u03BF\u03C5 \u03C9\u03C2 hosted layer \u03B1\u03C0\u03AD\u03C4\u03C5\u03C7\u03B5 \u03BB\u03CC\u03B3\u03C9 \u03B5\u03BD\u03CC\u03C2 \u03AE \u03C0\u03B5\u03C1\u03B9\u03C3\u03C3\u03CC\u03C4\u03B5\u03C1\u03C9\u03BD \u03BC\u03B7 \u03AD\u03B3\u03BA\u03C5\u03C1\u03C9\u03BD \u03C0\u03B5\u03B4\u03AF\u03C9\u03BD. \u0395\u03C0\u03B1\u03BD\u03B5\u03BA\u03C4\u03AD\u03BB\u03B5\u03C3\u03B7 \u03C4\u03BF\u03C5 \u03B5\u03C1\u03B3\u03B1\u03BB\u03B5\u03AF\u03BF\u03C5 \u03B3\u03B9\u03B1 \u03C4\u03B7 \u03B4\u03B7\u03BC\u03B9\u03BF\u03C5\u03C1\u03B3\u03AF\u03B1 \u03B8\u03B5\u03BC\u03B1\u03C4\u03B9\u03BA\u03BF\u03CD \u03B5\u03C0\u03B9\u03C0\u03AD\u03B4\u03BF\u03C5 \u03BC\u03B5 \u03AD\u03B3\u03BA\u03C5\u03C1\u03B1 \u03C0\u03B5\u03B4\u03AF\u03B1.",N="\u0391\u03C0\u03BF\u03C4\u03C5\u03C7\u03AF\u03B1 \u03C5\u03C0\u03BF\u03B2\u03BF\u03BB\u03AE\u03C2 \u03B5\u03C1\u03B3\u03B1\u03C3\u03AF\u03B1\u03C2. \u039A\u03AC\u03BD\u03C4\u03B5 \u03BA\u03CD\u03BB\u03B9\u03C3\u03B7 \u03C0\u03C1\u03BF\u03C2 \u03C4\u03B1 \u03BA\u03AC\u03C4\u03C9, \u03B4\u03B9\u03BF\u03C1\u03B8\u03CE\u03C3\u03C4\u03B5 \u03C4\u03B1 \u03C3\u03C6\u03AC\u03BB\u03BC\u03B1\u03C4\u03B1 \u03BA\u03B1\u03B9 \u03B5\u03BA\u03C4\u03B5\u03BB\u03AD\u03C3\u03C4\u03B5 \u03BE\u03B1\u03BD\u03AC \u03C4\u03B7\u03BD \u03B1\u03BD\u03AC\u03BB\u03C5\u03C3\u03B7.",V="\u03A4\u03BF ${ dataPath } \u03C0\u03C1\u03AD\u03C0\u03B5\u03B9 \u03BD\u03B1 \u03AD\u03C7\u03B5\u03B9 \u03C4\u03BF\u03C5\u03BB\u03AC\u03C7\u03B9\u03C3\u03C4\u03BF\u03BD \u03AD\u03BD\u03B1\u03BD \u03C7\u03B1\u03C1\u03B1\u03BA\u03C4\u03AE\u03C1\u03B1 \u03C0\u03BF\u03C5 \u03BD\u03B1 \u03BC\u03B7\u03BD \u03B5\u03AF\u03BD\u03B1\u03B9 \u03BA\u03B5\u03BD\u03CC \u03B4\u03B9\u03AC\u03C3\u03C4\u03B7\u03BC\u03B1.",C={InsufficientCreditsError:e,accessBlocked:a,additionalProperty:r,anyOfValues:t,cannotWriteToItemResource:o,creditEstimationError:i,defaultError:s,enumValues:l,failedToSaveHistory:n,fullSessionStorage:d,hostedFeatureServiceInvalidTitle:c,hostedFeatureServicePublishDidNotComplete:m,insufficientPermissions:u,keyPropertiesError:h,layerLoadFailure:E,layerUnavailable:y,maxItems:P,mbFailedToSave:f,minItems:p,minLength:k,modelNotFound:$,networkError:S,noPermissionToAccessTool:v,portalLoadError:F,queryFeaturesError:I,requiredProperty:T,serviceNameExistsError:b,specialCharactersInServiceNameError:L,temporaryLayerFieldsError:g,toolValidationError:N,whiteSpacePattern:V};export{e as InsufficientCreditsError,a as accessBlocked,r as additionalProperty,t as anyOfValues,o as cannotWriteToItemResource,i as creditEstimationError,C as default,s as defaultError,l as enumValues,n as failedToSaveHistory,d as fullSessionStorage,c as hostedFeatureServiceInvalidTitle,m as hostedFeatureServicePublishDidNotComplete,u as insufficientPermissions,h as keyPropertiesError,E as layerLoadFailure,y as layerUnavailable,P as maxItems,f as mbFailedToSave,p as minItems,k as minLength,$ as modelNotFound,S as networkError,v as noPermissionToAccessTool,F as portalLoadError,I as queryFeaturesError,T as requiredProperty,b as serviceNameExistsError,L as specialCharactersInServiceNameError,g as temporaryLayerFieldsError,N as toolValidationError,V as whiteSpacePattern};
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
+ import"./QPIMTXPL.js";var e="Nie masz wystarczaj\u0105cej liczby kredyt\xF3w do wykonania tej operacji. Skontaktuj si\u0119 z administratorem systemu ArcGIS, aby uzyska\u0107 pomoc.",a="To narz\u0119dzie zosta\u0142o opublikowane z poziomu notatnika. Dost\u0119p do aplikacji ArcGIS Notebooks jest zablokowany dla Twojej instytucji. Skontaktuj si\u0119 z administratorem w celu dostosowania ustawienia.",i="Element ${ dataPath } nie mo\u017Ce zawiera\u0107 ${ additionalProperty }.",o="Element ${ dataPath } musi by\u0107 zgodny z jednym z tych schemat\xF3w: ${ schemaOptions }.",r="Spr\xF3buj ponownie zapisa\u0107 map\u0119.",t="Oszacowanie kredyt\xF3w si\u0119 nie powiod\u0142o. Przewi\u0144 w d\xF3\u0142, popraw b\u0142\u0119dy i ponownie oszacuj kredyty.",n="Podczas przeprowadzania analizy wyst\u0105pi\u0142 b\u0142\u0105d.",s="Element ${ dataPath } musi mie\u0107 warto\u015B\u0107 r\xF3wn\u0105 jednej z tych dozwolonych warto\u015Bci: ${ allowedValues }.",w="Nie powiod\u0142o si\u0119 zapisanie historii analiz",d="Pami\u0119\u0107 historii jest pe\u0142na. Usu\u0144 niekt\xF3re elementy z historii analiz i spr\xF3buj zapisa\u0107 ponownie.",l="Nazwa us\u0142ugi zawiera co najmniej jeden nieprawid\u0142owy znak.",c="Zapisanie warstwy tymczasowej jako hostowanej warstwy obiektowej nie powiod\u0142o si\u0119.",m="Nast\u0119puj\u0105ce uprawnienia s\u0105 wymagane do u\u017Cycia tego narz\u0119dzia: ${ privileges }. <calcite-link href='${docLink}' target='_blank'>Dowiedz si\u0119 wi\u0119cej</calcite-link>",y="Nie uda\u0142o si\u0119 pobra\u0107 kluczowych w\u0142a\u015Bciwo\u015Bci.",p="Nie uda\u0142o si\u0119 wczyta\u0107 warstwy.",u="Warstwa jest niedost\u0119pna.",z="Element ${ dataPath } nie mo\u017Ce mie\u0107 wi\u0119cej element\xF3w ni\u017C ${ limit }.",j="Wyst\u0105pi\u0142 b\u0142\u0105d podczas zapisywania modelu. Spr\xF3buj ponownie zapisa\u0107.",k="Element ${ dataPath } nie mo\u017Ce mie\u0107 mniej element\xF3w ni\u017C ${ limit }.",h="Element ${ dataPath } nie mo\u017Ce by\u0107 kr\xF3tszy ni\u017C nast\u0119puj\u0105ca liczba znak\xF3w: ${ limit }.",E="Nie powiod\u0142o si\u0119 wczytywanie elementu modelu. Upewnij si\u0119, \u017Ce model istnieje i \u017Ce przyznano uprawnienia dost\u0119pu.",b="Nie powiod\u0142o si\u0119 wykonanie \u017C\u0105dania.",P="Nie masz uprawnie\u0144 do uruchomienia tego narz\u0119dzia. <calcite-link target='_blank' href='${ docLink }'>Dowiedz si\u0119 wi\u0119cej</calcite-link>",N="Nie mo\u017Cna zalogowa\u0107 si\u0119 w portalu.",S="Nie powi\xF3d\u0142 si\u0119 odczyt danych wej\u015Bciowych.",f="W elemencie ${ dataPath } brak w\u0142a\u015Bciwo\u015Bci o nazwie ${ missingProperty }.",$="Istnieje ju\u017C warstwa wynikowa o tej nazwie. Nazwy warstw wynikowych musz\u0105 by\u0107 niepowtarzalne w ca\u0142ej instytucji. U\u017Cyj innej nazwy.",g="Nazwa danych wynikowych zawiera co najmniej jeden nieprawid\u0142owy znak. <calcite-link href='${docLink}' target='_blank'>Dowiedz si\u0119 wi\u0119cej</calcite-link>",v="Publikowanie warstwy tymczasowej jako warstwy hostowanej nie powiod\u0142o si\u0119 z powodu co najmniej jednego nieprawid\u0142owego pola. Uruchom ponownie narz\u0119dzie, aby utworzy\u0107 warstw\u0119 z prawid\u0142owymi polami.",I="Nie powiod\u0142o si\u0119 wys\u0142anie zadania. Przewi\u0144 widok w d\xF3\u0142, popraw b\u0142\u0119dy i ponownie uruchom analiz\u0119.",F="Element ${ dataPath } musi zawiera\u0107 co najmniej jeden znak inny ni\u017C bia\u0142y znak.",T={InsufficientCreditsError:e,accessBlocked:a,additionalProperty:i,anyOfValues:o,cannotWriteToItemResource:r,creditEstimationError:t,defaultError:n,enumValues:s,failedToSaveHistory:w,fullSessionStorage:d,hostedFeatureServiceInvalidTitle:l,hostedFeatureServicePublishDidNotComplete:c,insufficientPermissions:m,keyPropertiesError:y,layerLoadFailure:p,layerUnavailable:u,maxItems:z,mbFailedToSave:j,minItems:k,minLength:h,modelNotFound:E,networkError:b,noPermissionToAccessTool:P,portalLoadError:N,queryFeaturesError:S,requiredProperty:f,serviceNameExistsError:$,specialCharactersInServiceNameError:g,temporaryLayerFieldsError:v,toolValidationError:I,whiteSpacePattern:F};export{e as InsufficientCreditsError,a as accessBlocked,i as additionalProperty,o as anyOfValues,r as cannotWriteToItemResource,t as creditEstimationError,T as default,n as defaultError,s as enumValues,w as failedToSaveHistory,d as fullSessionStorage,l as hostedFeatureServiceInvalidTitle,c as hostedFeatureServicePublishDidNotComplete,m as insufficientPermissions,y as keyPropertiesError,p as layerLoadFailure,u as layerUnavailable,z as maxItems,j as mbFailedToSave,k as minItems,h as minLength,E as modelNotFound,b as networkError,P as noPermissionToAccessTool,N as portalLoadError,S as queryFeaturesError,f as requiredProperty,$ as serviceNameExistsError,g as specialCharactersInServiceNameError,v as temporaryLayerFieldsError,I as toolValidationError,F as whiteSpacePattern};
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
+ import"./QPIMTXPL.js";var i="Neturite pakankamai kredit\u0173 atlikti \u0161\u012F veiksm\u0105. Kreipkit\u0117s pagalbos \u012F savo ArcGIS sistemos administratori\u0173.",a="\u0160is \u012Frankis publikuotas i\u0161 u\u017Era\u0161in\u0117s. J\u016Bs\u0173 organizacijos prieiga prie ArcGIS Notebooks u\u017Eblokuota. Nor\u0117dami koreguoti nustatym\u0105 susisiekite su savo administratoriumi.",e="${ dataPath } negali sudaryti ${ additionalProperty }.",t="${ dataPath } turi sutapti su viena i\u0161 \u0161i\u0173 schem\u0173: ${ schemaOptions }.",r="Bandykite \u012Fra\u0161yti \u017Eem\u0117lap\u012F i\u0161 naujo.",s="Kredit\u0173 \u012Fvertinimas nepavyko. Slinkite \u017Eemyn, i\u0161taisykite klaidas ir dar kart\u0105 \u012Fvertinkite kreditus.",o="Vykdant analiz\u0119 \u012Fvyko klaida.",n="${ dataPath } turi b\u016Bti lygus vienai i\u0161 \u0161i\u0173 leid\u017Eiam\u0173 reik\u0161mi\u0173: ${ allowedValues }.",l="Nepavyko \u012Fra\u0161yti analiz\u0117s istorijos",u="Istorijos saugykla pilna. Pa\u0161alinkite kelet\u0105 element\u0173 i\u0161 analiz\u0117s istorijos ir bandykite \u012Fra\u0161yti dar kart\u0105.",k="Paslaugos pavadinime yra vienas arba daugiau neleistin\u0173 simboli\u0173.",d="Laikinojo sluoksnio i\u0161saugojimas kaip talpinam\u0173 element\u0173 sluoksnis nebuvo baigtas.",m="Norint paleisti \u0161\u012F \u012Frank\u012F reikalingos \u0161ios teis\u0117s: ${ privileges }. <calcite-link href='${docLink}' target='_blank'>Su\u017Einokite daugiau </calcite-link>",p="Nepavyko gauti pagrindini\u0173 ypatybi\u0173.",y="Sluoksnio \u012Fkelti nepavyko.",c="Sluoksnis nepasiekiamas.",v="${ dataPath } negali tur\u0117ti daugiau negu ${ limit } element\u0173.",g="\u012Era\u0161ant model\u012F \u012Fvyko klaida. Bandykite \u012Fra\u0161yti i\u0161 naujo.",b="${ dataPath } negali tur\u0117ti ma\u017Eiau negu ${ limit } element\u0173.",P="${ dataPath } negali b\u016Bti trumpesnis negu ${ limit } simb.",E="Nepavyko \u012Fkelti modelio elemento. \u012Esitikinkite, kad modelis egzistuoja ir suteikta prieiga.",h="Nepavyko u\u017Ebaigti u\u017Eklausos.",S="Neturite leidimo vykdyti \u0161io \u012Frankio. <calcite-link target='_blank' href='${ docLink }'>Su\u017Einokite daugiau </calcite-link>",N="Nepavyko prisijungti prie portalo.",f="Nepavyko nuskaityti \u012Fvesties duomen\u0173.",$="${ dataPath } tr\u016Bksta savyb\u0117s pavadinimu ${ missingProperty }.",j="Rezultat\u0173 sluoksnis tokiu pavadinimu jau yra. Rezultat\u0173 sluoksni\u0173 pavadinimai turi b\u016Bti unikal\u016Bs visoje organizacijoje. Naudokite kit\u0105 pavadinim\u0105.",I="I\u0161vesties pavadinime yra vienas ar daugiau neleistini\u0173 simboli\u0173. <calcite-link href='${docLink}' target='_blank'>Su\u017Einokite daugiau </calcite-link>",F="Nepavyko publikuoti laikinojo sluoksnio kaip talpinamo sluoksnio d\u0117l vieno ar daugiau netinkam\u0173 lauk\u0173. Paleiskite \u012Frank\u012F i\u0161 naujo, kad sukurtum\u0117te sluoksn\u012F su tinkamais laukais.",L="Nepavyko pateikti u\u017Eduoties. Slinkite \u017Eemyn, i\u0161taisykite klaidas ir dar kart\u0105 paleiskite analiz\u0119.",T="${ dataPath } turi sudaryti bent vienas simbolis, kuris n\u0117ra tarpas.",z={InsufficientCreditsError:i,accessBlocked:a,additionalProperty:e,anyOfValues:t,cannotWriteToItemResource:r,creditEstimationError:s,defaultError:o,enumValues:n,failedToSaveHistory:l,fullSessionStorage:u,hostedFeatureServiceInvalidTitle:k,hostedFeatureServicePublishDidNotComplete:d,insufficientPermissions:m,keyPropertiesError:p,layerLoadFailure:y,layerUnavailable:c,maxItems:v,mbFailedToSave:g,minItems:b,minLength:P,modelNotFound:E,networkError:h,noPermissionToAccessTool:S,portalLoadError:N,queryFeaturesError:f,requiredProperty:$,serviceNameExistsError:j,specialCharactersInServiceNameError:I,temporaryLayerFieldsError:F,toolValidationError:L,whiteSpacePattern:T};export{i as InsufficientCreditsError,a as accessBlocked,e as additionalProperty,t as anyOfValues,r as cannotWriteToItemResource,s as creditEstimationError,z as default,o as defaultError,n as enumValues,l as failedToSaveHistory,u as fullSessionStorage,k as hostedFeatureServiceInvalidTitle,d as hostedFeatureServicePublishDidNotComplete,m as insufficientPermissions,p as keyPropertiesError,y as layerLoadFailure,c as layerUnavailable,v as maxItems,g as mbFailedToSave,b as minItems,P as minLength,E as modelNotFound,h as networkError,S as noPermissionToAccessTool,N as portalLoadError,f as queryFeaturesError,$ as requiredProperty,j as serviceNameExistsError,I as specialCharactersInServiceNameError,F as temporaryLayerFieldsError,L as toolValidationError,T as whiteSpacePattern};