@esri/solutions-components 5.0.0 → 5.0.1

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 (110) hide show
  1. package/dist/cdn/{J6Z7OGPT.js → 224I72SO.js} +1 -1
  2. package/dist/cdn/{JV3YKSCY.js → 2333JKXT.js} +1 -1
  3. package/dist/cdn/{3QLYSIKK.js → 243LX5NA.js} +1 -1
  4. package/dist/cdn/{G3RPEESM.js → 2SD4IYX3.js} +1 -1
  5. package/dist/cdn/{Z5H7S4UV.js → 2XLDIKUR.js} +1 -1
  6. package/dist/cdn/{PTPT75U6.js → 3RZAPX3S.js} +1 -1
  7. package/dist/cdn/{6OSOUHQD.js → 4JMP7ZE6.js} +1 -1
  8. package/dist/cdn/{S6XTVW2E.js → 4YJT24E5.js} +1 -1
  9. package/dist/cdn/{IW3HH57K.js → 5MTMSAKC.js} +1 -1
  10. package/dist/cdn/{LYMOZHWK.js → 5SHA3PGC.js} +1 -1
  11. package/dist/cdn/{SXOJTCOY.js → 6NMWB5NC.js} +1 -1
  12. package/dist/cdn/{C4M2JGW3.js → 6UJALA2L.js} +1 -1
  13. package/dist/cdn/{JRDWWNST.js → 6VKEW33C.js} +1 -1
  14. package/dist/cdn/{ONIWIJZN.js → 76M3UWJF.js} +1 -1
  15. package/dist/cdn/{R6DDGHRE.js → 7GQ24AKO.js} +1 -1
  16. package/dist/cdn/7PY2VM2S.js +2 -0
  17. package/dist/cdn/{ULPRAGHR.js → 7PZQ2MP7.js} +1 -1
  18. package/dist/cdn/{ASS5QC73.js → ARXWEJFK.js} +1 -1
  19. package/dist/cdn/{7JX6B3W3.js → AV3KXTWF.js} +1 -1
  20. package/dist/cdn/{QNT2CGG3.js → BXXYI7NG.js} +1 -1
  21. package/dist/cdn/{DJRQRVE7.js → BZVRRVNB.js} +1 -1
  22. package/dist/cdn/{KUYFIQG5.js → C5LZGCHH.js} +1 -1
  23. package/dist/cdn/CI66IACC.js +2 -0
  24. package/dist/cdn/DD3JC2L3.js +4 -0
  25. package/dist/cdn/{RGCDDZZ7.js → E7UFN5JY.js} +1 -1
  26. package/dist/cdn/{AS3OMVJG.js → EMSOP52X.js} +1 -1
  27. package/dist/cdn/{L4UMQNXD.js → ESOI3UW5.js} +1 -1
  28. package/dist/cdn/FMFUEICN.js +2 -0
  29. package/dist/cdn/{V3SPTOG3.js → FNGWQOMU.js} +1 -1
  30. package/dist/cdn/{QNSZUCGN.js → G2T6OYTB.js} +1 -1
  31. package/dist/cdn/{E4LHQX7P.js → GU77W2GF.js} +1 -1
  32. package/dist/cdn/HHKKBJCY.js +2 -0
  33. package/dist/cdn/{K3TXWVO2.js → HK7YZNM4.js} +1 -1
  34. package/dist/cdn/{QNTMCZAS.js → HTLJCLHR.js} +1 -1
  35. package/dist/cdn/{MGOL3BOX.js → HVE26GKL.js} +1 -1
  36. package/dist/cdn/{PRSBDD25.js → IQQXCY6C.js} +1 -1
  37. package/dist/cdn/{EVYF4Q4A.js → IZU7KP25.js} +1 -1
  38. package/dist/cdn/{PKLCCM5C.js → JAOKRCFG.js} +1 -1
  39. package/dist/cdn/{AELONRA2.js → JBJJMSR3.js} +1 -1
  40. package/dist/cdn/{7XSKL7BM.js → JUINWMBC.js} +1 -1
  41. package/dist/cdn/{4GUAHP55.js → K5Z5A2RY.js} +1 -1
  42. package/dist/cdn/{Q36LSOV4.js → M5MCA232.js} +1 -1
  43. package/dist/cdn/{HUTJQTEN.js → MBVWXJW7.js} +1 -1
  44. package/dist/cdn/{EUQ4JO3K.js → NCTVUAXT.js} +1 -1
  45. package/dist/cdn/{GPHDOTEY.js → NHKAOTFM.js} +1 -1
  46. package/dist/cdn/{DBPLH4RV.js → NNOOCMHD.js} +1 -1
  47. package/dist/cdn/{74XBLQLQ.js → NU2NW3YW.js} +1 -1
  48. package/dist/cdn/{56MHO3UY.js → O7AZMIQX.js} +1 -1
  49. package/dist/cdn/{Z5GWY442.js → OIFBNDN7.js} +1 -1
  50. package/dist/cdn/{V7JWKNPI.js → OLLLVTHU.js} +1 -1
  51. package/dist/cdn/{GRJZORJP.js → P6NSLBDS.js} +1 -1
  52. package/dist/cdn/{RLTX5S5V.js → P77GI3QL.js} +1 -1
  53. package/dist/cdn/{NVYKJK26.js → PAKIDHHK.js} +1 -1
  54. package/dist/cdn/{ENW2DF2D.js → PCG2HRKC.js} +1 -1
  55. package/dist/cdn/{M2KUCUL3.js → PQ7PCKL4.js} +1 -1
  56. package/dist/cdn/PSXEKRGH.js +2 -0
  57. package/dist/cdn/{EJJFSS5C.js → QRUCDIZO.js} +1 -1
  58. package/dist/cdn/QXSUDN7A.js +21 -0
  59. package/dist/cdn/{C7UAPXZR.js → RA35CIMF.js} +1 -1
  60. package/dist/cdn/{NPPIBUUP.js → RUU2LTYJ.js} +1 -1
  61. package/dist/cdn/{ZJZBIHZ5.js → S4WGAHIV.js} +1 -1
  62. package/dist/cdn/{2CMRI2B3.js → S7XOHDIW.js} +1 -1
  63. package/dist/cdn/{V7FXM6DJ.js → SLXAZV5B.js} +1 -1
  64. package/dist/cdn/{EYFR4JQP.js → SNN6XXHG.js} +1 -1
  65. package/dist/cdn/SPBICIV2.js +2 -0
  66. package/dist/cdn/SS7F2SZ4.js +2 -0
  67. package/dist/cdn/{5S7OJL7F.js → SSL3U5CO.js} +1 -1
  68. package/dist/cdn/{GVGTMXTG.js → SU77ODY2.js} +1 -1
  69. package/dist/cdn/TAHIBODN.js +2 -0
  70. package/dist/cdn/TE7VJ4KH.js +2 -0
  71. package/dist/cdn/{YHW6JKYZ.js → TOLNZKKL.js} +1 -1
  72. package/dist/cdn/{5KV6KCRT.js → UAUP4JQ4.js} +1 -1
  73. package/dist/cdn/{PDNBP4EL.js → VCZPVG3A.js} +1 -1
  74. package/dist/cdn/{QEZPZGBW.js → VGC3RHQQ.js} +1 -1
  75. package/dist/cdn/VLIHU4DD.js +2 -0
  76. package/dist/cdn/{6A5SBI3R.js → VWDJZ7HA.js} +1 -1
  77. package/dist/cdn/{RSLHX62X.js → WCGF6MFJ.js} +1 -1
  78. package/dist/cdn/WGKOKVQY.js +2 -0
  79. package/dist/cdn/WNOPX4X3.js +2 -0
  80. package/dist/cdn/WPV4X3NK.js +2 -0
  81. package/dist/cdn/{QMRCHKSO.js → XY5MX7TV.js} +1 -1
  82. package/dist/cdn/{HA5W44KL.js → Y3XY5BXI.js} +1 -1
  83. package/dist/cdn/{C5YQOXHX.js → YCLEJLXQ.js} +1 -1
  84. package/dist/cdn/{T6AL47LF.js → ZIPMI556.js} +1 -1
  85. package/dist/cdn/index.js +1 -1
  86. package/dist/chunks/runtime.js +1 -1
  87. package/dist/components/public-notification/customElement.js +3 -3
  88. package/dist/components/solutions-all-panel/customElement.js +8 -8
  89. package/dist/components/solutions-all-shell/customElement.js +9 -9
  90. package/dist/components/solutions-deployed-shell/customElement.js +2 -2
  91. package/dist/docs/api.json +1 -1
  92. package/dist/docs/docs.json +1 -1
  93. package/dist/docs/web-types.json +1 -1
  94. package/dist/solutions-components_commit.txt +4 -4
  95. package/package.json +3 -3
  96. package/dist/cdn/4SZGXI37.js +0 -2
  97. package/dist/cdn/52QNBNIL.js +0 -2
  98. package/dist/cdn/AHXBPG3X.js +0 -2
  99. package/dist/cdn/BF6WA5U4.js +0 -2
  100. package/dist/cdn/CBVAXYAC.js +0 -2
  101. package/dist/cdn/D6VGQMIK.js +0 -2
  102. package/dist/cdn/ETEJ4PIB.js +0 -2
  103. package/dist/cdn/GSRMKEUC.js +0 -2
  104. package/dist/cdn/H74UJR3L.js +0 -2
  105. package/dist/cdn/HATDZAP6.js +0 -2
  106. package/dist/cdn/JJUJVV7A.js +0 -2
  107. package/dist/cdn/LHCWS2RN.js +0 -4
  108. package/dist/cdn/PLHWBWIG.js +0 -2
  109. package/dist/cdn/U4QFXUX2.js +0 -33
  110. package/dist/cdn/WNQD3BKN.js +0 -2
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as u}from"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as f}from"./2CMRI2B3.js";import{F as l,G as n,H as m,J as d,K as b,h as c,i as a,r as p}from"./46DQNAMV.js";import"./OR4HXHSY.js";var _=c`:host{display:block;--solutions-theme-foreground-color: var(--calcite-color-foreground-1);width:100%}.width-full{width:100%}.height-full{height:100%}.display-flex{display:flex}.border-bottom-1{border-bottom-width:1px!important;border-width:0px}.border-bottom-2{border-bottom-width:2px!important;border-width:0px}.border-solid{border-style:solid;border-color:var(--calcite-color-border-3)}.border-left-right{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.action-bar-size{height:51px;width:100%}.map-list{display:flex;flex-direction:column;animation:calcite-scrim-fade-in var(--calcite-internal-animation-timing-medium) ease-in-out;background-color:var(--calcite-color-background);z-index:1000}.display-none{display:none}.adjusted-height{max-height:calc(100% - 68px);overflow-y:auto}.position-absolute{position:absolute}.position-relative{position:relative}.popover-map-list{overflow:auto;width:250px}.max-width-200{max-width:200px}.min-width-150{min-width:150px}calcite-action-bar{--calcite-internal-action-bar-gap: 0px;--calcite-internal-action-bar-padding: 0px}`,h=class extends m{constructor(){super(),this.mapInfos=[],this.isMapLayout=!1,this.showMapListInPopover=!1,this.referenceElement="",this.selectedWebMapId="",this._mapListExpanded=!1,this._isValidWebMap=!0,this._translations=u({name:"map-picker",blocking:!0}),this._list=l(),this._loadedId="",this._skipEditCheck=!1,this._popover=l(),this._mapPickerButton=l(),this.beforeMapInfoChange=p(),this.mapInfoChange=p(),this.listenOn(window,"mapChanged",this.mapChanged)}static{this.properties={mapInfos:0,isMapLayout:5,height:9,showMapListInPopover:5,referenceElement:1,selectedWebMapId:1,_mapListExpanded:16,_isValidWebMap:16,_translations:16}}static{this.styles=_}willUpdate(t){t.has("mapInfos")&&this.hasUpdated&&this.mapInfosWatchHandler(this.mapInfos,t.get("mapInfos")),t.has("selectedWebMapId")&&this.hasUpdated&&this.selectedWebMapIdWatchHandler(this.selectedWebMapId)}_webMapInfoWatchHandler(t,e){t&&JSON.stringify(t)!==JSON.stringify(e)&&(this._loadedId=t?.id,this.mapInfoChange.emit(t))}async mapInfosWatchHandler(t,e){if(t&&JSON.stringify(t)!==JSON.stringify(e)){let i=this._getWebMapInfo();this._webMapSelected(i)}}async selectedWebMapIdWatchHandler(t){this._loadedId=t}async setMapByID(t,e=!1){this._skipEditCheck=e;let i=this.mapInfos?.filter(s=>s.id===t);t&&i?.length>0&&this._webMapSelected(i[0]),this._skipEditCheck=!1}async close(){this._mapListExpanded&&(this._mapListExpanded=!1)}async toggle(t){this._mapListExpanded=t}async mapChanged(t){let e=t.detail.isValid;this._isValidWebMap=e}render(){return a`${!this.showMapListInPopover&&this._getToolbar()||""}${this.showMapListInPopover?this._getMapListPopover():this._getMapNameList(this._mapListExpanded)}`}loaded(){let t=this._getWebMapInfo();t&&this._webMapSelected(t)}_getMapPicker(){let t="map-picker-expand-toggle",e=this._mapListExpanded?"chevron-up":"chevron-down",i=this.isMapLayout?"":"position-absolute",s=this.isMapLayout?"max-width-200":"width-full",r=this._isValidWebMap?"map":"exclamation-mark-triangle";return a`<div class=${d(s)}><calcite-button alignment=icon-end-space-between appearance=transparent class=${`width-full height-full ${i}`} .iconEnd=${e} .iconStart=${r} id=${t} kind=neutral @click=${()=>this._chooseMap()} width=full ${n(this._mapPickerButton)}>${this._getWebMapInfo().name}</calcite-button><calcite-tooltip placement=bottom .referenceElement=${t}><span>${this._translations.switchMap}</span></calcite-tooltip></div>`}_getToolbar(){let t=this.isMapLayout?"border-bottom-1":"border-bottom-2",e=this.isMapLayout?"":"position-relative";return a`<div class=${`display-flex border-left-right ${e}`}><calcite-action-bar class=${`border-solid action-bar-size overflow-hidden ${t}`} expand-disabled layout=horizontal slot=header>${this._getMapPicker()}${this._updateMapPickerIconColor()}</calcite-action-bar></div>`}_updateMapPickerIconColor(){this._mapPickerButton.value?.componentOnReady().then(()=>{let t=this._mapPickerButton.value?.shadowRoot?.lastChild,e=null;if(t&&t instanceof HTMLElement){let i=t.getElementsByClassName("icon icon--start");i.length>0&&(e=i[0])}e&&(this._isValidWebMap?e.style.setProperty("color","var(--calcite-color-text-1)"):e.style.setProperty("color","var(--calcite-color-status-danger)"))})}_getMapNameList(t){let e=this.showMapListInPopover?"position-relative":"position-absolute",i=this.isMapLayout?"max-width-200 min-width-150":"width-full",s=this.isMapLayout?"border-bottom-1":"border-bottom-2",r=t?`map-list border-solid ${s} adjusted-height ${i} ${e}`:"display-none";return a`<div class=${d(r)}><calcite-list id=mapList label selection-appearance=border selection-mode=single-persist ${n(this._list)}>${this.mapInfos.map(o=>a`<calcite-list-item .label=${o.name} @click=${()=>this._webMapSelected(o)} .selected=${o.id===this._loadedId} .value=${o.id}></calcite-list-item>`)}</calcite-list></div>`}_getMapListPopover(){let t=this.height&&this.height>0&&this.showMapListInPopover?{"max-height":`${this.height.toString()}px`}:{};return a`<calcite-popover auto-close focus-trap-disabled .label=${this.referenceElement} placement=left .referenceElement=${this.referenceElement} ${n(this._popover)}><div style=${b(t)} class=popover-map-list>${this._getMapNameList(!0)}</div></calcite-popover>`}_getWebMapInfo(){let t=this.mapInfos.find(e=>this.selectedWebMapId===e.id);if(!t&&this.mapInfos.length>0&&(t=this.mapInfos[0]),!t)throw new Error("No valid web map info available");return t}_webMapSelected(t){let e=this._loadedId;this._loadedId=t.id;let i=!1;this._skipEditCheck?i=!0:this.beforeMapInfoChange.emit({currentId:e,mapInfo:t,ref:this.el}).defaultPrevented||(i=!0),i&&(this._webMapInfoWatchHandler(t,this._webMapInfo),this._webMapInfo=t),this._popover.value&&(this._popover.value.open=!1),this._mapListExpanded=!1}_chooseMap(){this._mapListExpanded=!this._mapListExpanded}};f("map-picker",h);export{h as MapPicker};
2
+ import{a as u}from"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as f}from"./S7XOHDIW.js";import{F as l,G as n,H as m,J as d,K as b,h as c,i as a,r as p}from"./46DQNAMV.js";import"./OR4HXHSY.js";var _=c`:host{display:block;--solutions-theme-foreground-color: var(--calcite-color-foreground-1);width:100%}.width-full{width:100%}.height-full{height:100%}.display-flex{display:flex}.border-bottom-1{border-bottom-width:1px!important;border-width:0px}.border-bottom-2{border-bottom-width:2px!important;border-width:0px}.border-solid{border-style:solid;border-color:var(--calcite-color-border-3)}.border-left-right{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.action-bar-size{height:51px;width:100%}.map-list{display:flex;flex-direction:column;animation:calcite-scrim-fade-in var(--calcite-internal-animation-timing-medium) ease-in-out;background-color:var(--calcite-color-background);z-index:1000}.display-none{display:none}.adjusted-height{max-height:calc(100% - 68px);overflow-y:auto}.position-absolute{position:absolute}.position-relative{position:relative}.popover-map-list{overflow:auto;width:250px}.max-width-200{max-width:200px}.min-width-150{min-width:150px}calcite-action-bar{--calcite-internal-action-bar-gap: 0px;--calcite-internal-action-bar-padding: 0px}`,h=class extends m{constructor(){super(),this.mapInfos=[],this.isMapLayout=!1,this.showMapListInPopover=!1,this.referenceElement="",this.selectedWebMapId="",this._mapListExpanded=!1,this._isValidWebMap=!0,this._translations=u({name:"map-picker",blocking:!0}),this._list=l(),this._loadedId="",this._skipEditCheck=!1,this._popover=l(),this._mapPickerButton=l(),this.beforeMapInfoChange=p(),this.mapInfoChange=p(),this.listenOn(window,"mapChanged",this.mapChanged)}static{this.properties={mapInfos:0,isMapLayout:5,height:9,showMapListInPopover:5,referenceElement:1,selectedWebMapId:1,_mapListExpanded:16,_isValidWebMap:16,_translations:16}}static{this.styles=_}willUpdate(t){t.has("mapInfos")&&this.hasUpdated&&this.mapInfosWatchHandler(this.mapInfos,t.get("mapInfos")),t.has("selectedWebMapId")&&this.hasUpdated&&this.selectedWebMapIdWatchHandler(this.selectedWebMapId)}_webMapInfoWatchHandler(t,e){t&&JSON.stringify(t)!==JSON.stringify(e)&&(this._loadedId=t?.id,this.mapInfoChange.emit(t))}async mapInfosWatchHandler(t,e){if(t&&JSON.stringify(t)!==JSON.stringify(e)){let i=this._getWebMapInfo();this._webMapSelected(i)}}async selectedWebMapIdWatchHandler(t){this._loadedId=t}async setMapByID(t,e=!1){this._skipEditCheck=e;let i=this.mapInfos?.filter(s=>s.id===t);t&&i?.length>0&&this._webMapSelected(i[0]),this._skipEditCheck=!1}async close(){this._mapListExpanded&&(this._mapListExpanded=!1)}async toggle(t){this._mapListExpanded=t}async mapChanged(t){let e=t.detail.isValid;this._isValidWebMap=e}render(){return a`${!this.showMapListInPopover&&this._getToolbar()||""}${this.showMapListInPopover?this._getMapListPopover():this._getMapNameList(this._mapListExpanded)}`}loaded(){let t=this._getWebMapInfo();t&&this._webMapSelected(t)}_getMapPicker(){let t="map-picker-expand-toggle",e=this._mapListExpanded?"chevron-up":"chevron-down",i=this.isMapLayout?"":"position-absolute",s=this.isMapLayout?"max-width-200":"width-full",r=this._isValidWebMap?"map":"exclamation-mark-triangle";return a`<div class=${d(s)}><calcite-button alignment=icon-end-space-between appearance=transparent class=${`width-full height-full ${i}`} .iconEnd=${e} .iconStart=${r} id=${t} kind=neutral @click=${()=>this._chooseMap()} width=full ${n(this._mapPickerButton)}>${this._getWebMapInfo().name}</calcite-button><calcite-tooltip placement=bottom .referenceElement=${t}><span>${this._translations.switchMap}</span></calcite-tooltip></div>`}_getToolbar(){let t=this.isMapLayout?"border-bottom-1":"border-bottom-2",e=this.isMapLayout?"":"position-relative";return a`<div class=${`display-flex border-left-right ${e}`}><calcite-action-bar class=${`border-solid action-bar-size overflow-hidden ${t}`} expand-disabled layout=horizontal slot=header>${this._getMapPicker()}${this._updateMapPickerIconColor()}</calcite-action-bar></div>`}_updateMapPickerIconColor(){this._mapPickerButton.value?.componentOnReady().then(()=>{let t=this._mapPickerButton.value?.shadowRoot?.lastChild,e=null;if(t&&t instanceof HTMLElement){let i=t.getElementsByClassName("icon icon--start");i.length>0&&(e=i[0])}e&&(this._isValidWebMap?e.style.setProperty("color","var(--calcite-color-text-1)"):e.style.setProperty("color","var(--calcite-color-status-danger)"))})}_getMapNameList(t){let e=this.showMapListInPopover?"position-relative":"position-absolute",i=this.isMapLayout?"max-width-200 min-width-150":"width-full",s=this.isMapLayout?"border-bottom-1":"border-bottom-2",r=t?`map-list border-solid ${s} adjusted-height ${i} ${e}`:"display-none";return a`<div class=${d(r)}><calcite-list id=mapList label selection-appearance=border selection-mode=single-persist ${n(this._list)}>${this.mapInfos.map(o=>a`<calcite-list-item .label=${o.name} @click=${()=>this._webMapSelected(o)} .selected=${o.id===this._loadedId} .value=${o.id}></calcite-list-item>`)}</calcite-list></div>`}_getMapListPopover(){let t=this.height&&this.height>0&&this.showMapListInPopover?{"max-height":`${this.height.toString()}px`}:{};return a`<calcite-popover auto-close focus-trap-disabled .label=${this.referenceElement} placement=left .referenceElement=${this.referenceElement} ${n(this._popover)}><div style=${b(t)} class=popover-map-list>${this._getMapNameList(!0)}</div></calcite-popover>`}_getWebMapInfo(){let t=this.mapInfos.find(e=>this.selectedWebMapId===e.id);if(!t&&this.mapInfos.length>0&&(t=this.mapInfos[0]),!t)throw new Error("No valid web map info available");return t}_webMapSelected(t){let e=this._loadedId;this._loadedId=t.id;let i=!1;this._skipEditCheck?i=!0:this.beforeMapInfoChange.emit({currentId:e,mapInfo:t,ref:this.el}).defaultPrevented||(i=!0),i&&(this._webMapInfoWatchHandler(t,this._webMapInfo),this._webMapInfo=t),this._popover.value&&(this._popover.value.open=!1),this._mapListExpanded=!1}_chooseMap(){this._mapListExpanded=!this._mapListExpanded}};f("map-picker",h);export{h as MapPicker};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import c from"./4SZGXI37.js";import b from"./QNSZUCGN.js";import"./6MZ227J7.js";import a from"./JJUJVV7A.js";import"./PZ4L77M5.js";import"./LHCWS2RN.js";import"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./2CMRI2B3.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,,a])=>{return a},a,b,c)
2
+ import c from"./WPV4X3NK.js";import b from"./G2T6OYTB.js";import"./6MZ227J7.js";import a from"./HHKKBJCY.js";import"./PZ4L77M5.js";import"./DD3JC2L3.js";import"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./S7XOHDIW.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,,a])=>{return a},a,b,c)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import a from"./JJUJVV7A.js";import{b as m}from"./PZ4L77M5.js";import{a as g}from"./HA5W44KL.js";import{b as p}from"./2CMRI2B3.js";import{F as l,G as d,H as h,L as s,h as c,i}from"./46DQNAMV.js";export default $arcgis.t(([,,,{b:u,t:f,z:r}])=>{var b=c`*[tabindex]:focus-visible{outline:solid 2px var(--calcite-color-brand);outline-offset:2px}.display-flex{display:flex}.align-items-center{align-items:center}.justify-content-center{justify-content:center}.screenshot-container{width:100%;overflow:hidden}.footer{width:100%}.footer-override{--calcite-dialog-footer-space: 0px}.footer-card{width:200px;height:100px;cursor:pointer;padding-bottom:2px}.padding-1{padding:1rem}.padding-bottom-1{padding-bottom:1rem}.padding-end-1{padding-inline-end:1rem}.padding-start-1{padding-inline-start:1rem}.padding-top-1{padding-top:1rem}.padding-top-1-2{padding-top:.5rem}.background-black{background-color:var(--calcite-color-foreground-3)}calcite-card:hover img{-webkit-filter:brightness(30%);filter:brightness(30%);-webkit-transition:all .1s ease;-moz-transition:all .1s ease;-o-transition:all .1s ease;-ms-transition:all .1s ease;transition:all .1s ease}calcite-card:hover{outline:2px solid var(--calcite-color-brand);box-sizing:border-box;cursor:pointer}.calcite-card-selected{outline:2px solid var(--calcite-color-brand);box-sizing:border-box;cursor:pointer}calcite-card:hover .hover-text{opacity:1;color:#fff}.hover-text{transition:.1s ease;opacity:0;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);-ms-transform:translate(-50%,-50%);text-align:center;display:flex;flex-direction:row;align-items:center;height:100%;font-size:var(--calcite-spacing-lg)}.card-image-wrap{width:100%;position:relative;margin-bottom:0;-webkit-box-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto}.card-image{width:100%;display:block}video,img{max-width:100%;height:auto}img{overflow-clip-margin:content-box;overflow:clip;display:block;object-fit:contain}`,n=class extends h{constructor(){super(...arguments),this.open=!1,this._screenshots=[],this._translations=g({name:"solution-snapshot-gallery",blocking:!0}),this._configContextConsumer=m({context:u,subscribe:!0}),this._displayText="",this._paginationControl=l(),this._screenshotNames=[]}static{this.properties={card:0,screenshot:0,itemProperties:0,open:5,_screenshots:16,_translations:16}}static{this.styles=b}willUpdate(t){t.has("screenshot")&&this.screenshot&&(this._displayText=this.screenshot.description||this.screenshot.alt),t.has("itemProperties")&&this.itemProperties&&(this._screenshots=this.itemProperties.preview.filter(e=>e.format==="image"),this._screenshotNames=this._screenshots.map(e=>e.name))}render(){return i`<calcite-dialog class="footer-override" .heading=${this.card?.title} modal @calciteDialogClose=${()=>this.open=!1} .open=${this.open} outside-close-disabled width=l>${this._getScreenshotView()}${this._getFooter()}</calcite-dialog>`}_getScreenshotView(){return this.screenshot?i`<div class="display-flex justify-content-center screenshot-container">${this._getImage(this.screenshot)}</div>`:""}_getFooter(){let t=this._screenshotNames.indexOf(this.screenshot?.name||""),e=document.body.classList.contains("calcite-mode-dark")?"calcite-mode-dark":"";return i`<div class="footer" slot=footer><div class=${`display-flex align-items-center padding-start-1 padding-top-1-2 background-black ${e}`}><calcite-label layout=inline><calcite-pagination class="padding-end-1" @calcitePaginationChange=${this._changeScreenshot} page-size=1 start-item=${t+1} total-items=${this._screenshots.length??s} ${d(this._paginationControl)}></calcite-pagination><span tabindex=0>${this._displayText}</span></calcite-label></div>${this._getCards()}</div>`}_changeScreenshot(){this.screenshot=this._screenshots[this._paginationControl.value.startItem-1]}_getCards(){return i`<calcite-card-group class="card-group padding-1" .label=${this._translations.seeSolutionScreenshots} selection-mode=single>${this._screenshots.map(t=>{let e=t.name===this.screenshot?.name;return i`<calcite-card class=${`footer-card ${e?"calcite-card-selected":""}`} .label=${t.alt} @click=${()=>this._showScreenshot(t)} @keydown=${o=>f(o,()=>this._showScreenshot(t))} .selected=${e}><div class="card-image-wrap" slot=thumbnail>${this._getImage(t,"thumbnail")}<div class="hover-text">${this._translations.viewScreenshot}</div></div></calcite-card>`})}</calcite-card-group>`}_getImage(t,e){return i`<img alt=${t.alt??s} slot=${e??s} src=${this._getSource(this._configContextConsumer.value.authentication,this.card?.id||"",t.name)??s}>`}_showScreenshot(t){this.screenshot=t}_getSource(t,e,o){let a=this._configContextConsumer.value;return a.agoBasedEnterpriseSolutionsGroupId&&a.isEnterprise?r(e||"",o,void 0,a.agolPortalUrl):t?r(e||"",o,t):""}};p("solution-snapshot-gallery",n);return n},"identity/IdentityManager","identity/OAuthInfo","portal/Portal",a)
2
+ import a from"./HHKKBJCY.js";import{b as m}from"./PZ4L77M5.js";import{a as g}from"./Y3XY5BXI.js";import{b as p}from"./S7XOHDIW.js";import{F as l,G as d,H as h,L as s,h as c,i}from"./46DQNAMV.js";export default $arcgis.t(([,,,{b:u,t:f,z:r}])=>{var b=c`*[tabindex]:focus-visible{outline:solid 2px var(--calcite-color-brand);outline-offset:2px}.display-flex{display:flex}.align-items-center{align-items:center}.justify-content-center{justify-content:center}.screenshot-container{width:100%;overflow:hidden}.footer{width:100%}.footer-override{--calcite-dialog-footer-space: 0px}.footer-card{width:200px;height:100px;cursor:pointer;padding-bottom:2px}.padding-1{padding:1rem}.padding-bottom-1{padding-bottom:1rem}.padding-end-1{padding-inline-end:1rem}.padding-start-1{padding-inline-start:1rem}.padding-top-1{padding-top:1rem}.padding-top-1-2{padding-top:.5rem}.background-black{background-color:var(--calcite-color-foreground-3)}calcite-card:hover img{-webkit-filter:brightness(30%);filter:brightness(30%);-webkit-transition:all .1s ease;-moz-transition:all .1s ease;-o-transition:all .1s ease;-ms-transition:all .1s ease;transition:all .1s ease}calcite-card:hover{outline:2px solid var(--calcite-color-brand);box-sizing:border-box;cursor:pointer}.calcite-card-selected{outline:2px solid var(--calcite-color-brand);box-sizing:border-box;cursor:pointer}calcite-card:hover .hover-text{opacity:1;color:#fff}.hover-text{transition:.1s ease;opacity:0;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);-ms-transform:translate(-50%,-50%);text-align:center;display:flex;flex-direction:row;align-items:center;height:100%;font-size:var(--calcite-spacing-lg)}.card-image-wrap{width:100%;position:relative;margin-bottom:0;-webkit-box-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto}.card-image{width:100%;display:block}video,img{max-width:100%;height:auto}img{overflow-clip-margin:content-box;overflow:clip;display:block;object-fit:contain}`,n=class extends h{constructor(){super(...arguments),this.open=!1,this._screenshots=[],this._translations=g({name:"solution-snapshot-gallery",blocking:!0}),this._configContextConsumer=m({context:u,subscribe:!0}),this._displayText="",this._paginationControl=l(),this._screenshotNames=[]}static{this.properties={card:0,screenshot:0,itemProperties:0,open:5,_screenshots:16,_translations:16}}static{this.styles=b}willUpdate(t){t.has("screenshot")&&this.screenshot&&(this._displayText=this.screenshot.description||this.screenshot.alt),t.has("itemProperties")&&this.itemProperties&&(this._screenshots=this.itemProperties.preview.filter(e=>e.format==="image"),this._screenshotNames=this._screenshots.map(e=>e.name))}render(){return i`<calcite-dialog class="footer-override" .heading=${this.card?.title} modal @calciteDialogClose=${()=>this.open=!1} .open=${this.open} outside-close-disabled width=l>${this._getScreenshotView()}${this._getFooter()}</calcite-dialog>`}_getScreenshotView(){return this.screenshot?i`<div class="display-flex justify-content-center screenshot-container">${this._getImage(this.screenshot)}</div>`:""}_getFooter(){let t=this._screenshotNames.indexOf(this.screenshot?.name||""),e=document.body.classList.contains("calcite-mode-dark")?"calcite-mode-dark":"";return i`<div class="footer" slot=footer><div class=${`display-flex align-items-center padding-start-1 padding-top-1-2 background-black ${e}`}><calcite-label layout=inline><calcite-pagination class="padding-end-1" @calcitePaginationChange=${this._changeScreenshot} page-size=1 start-item=${t+1} total-items=${this._screenshots.length??s} ${d(this._paginationControl)}></calcite-pagination><span tabindex=0>${this._displayText}</span></calcite-label></div>${this._getCards()}</div>`}_changeScreenshot(){this.screenshot=this._screenshots[this._paginationControl.value.startItem-1]}_getCards(){return i`<calcite-card-group class="card-group padding-1" .label=${this._translations.seeSolutionScreenshots} selection-mode=single>${this._screenshots.map(t=>{let e=t.name===this.screenshot?.name;return i`<calcite-card class=${`footer-card ${e?"calcite-card-selected":""}`} .label=${t.alt} @click=${()=>this._showScreenshot(t)} @keydown=${o=>f(o,()=>this._showScreenshot(t))} .selected=${e}><div class="card-image-wrap" slot=thumbnail>${this._getImage(t,"thumbnail")}<div class="hover-text">${this._translations.viewScreenshot}</div></div></calcite-card>`})}</calcite-card-group>`}_getImage(t,e){return i`<img alt=${t.alt??s} slot=${e??s} src=${this._getSource(this._configContextConsumer.value.authentication,this.card?.id||"",t.name)??s}>`}_showScreenshot(t){this.screenshot=t}_getSource(t,e,o){let a=this._configContextConsumer.value;return a.agoBasedEnterpriseSolutionsGroupId&&a.isEnterprise?r(e||"",o,void 0,a.agolPortalUrl):t?r(e||"",o,t):""}};p("solution-snapshot-gallery",n);return n},"identity/IdentityManager","identity/OAuthInfo","portal/Portal",a)
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
+ import b from"./TAHIBODN.js";import a from"./HHKKBJCY.js";import{b as C}from"./PZ4L77M5.js";import{rb as v,sa as S,sb as T,tb as $}from"./DD3JC2L3.js";import{a as D}from"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import{b as I}from"./S7XOHDIW.js";import{F as m,G as f,H as y,J as u,h as g,i as r,r as c}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([{J:V,K:w,b:b,f:_},{a:P}])=>{var N=g`*[tabindex]:focus-visible{outline-style:solid!important;outline-width:2px!important;outline-color:var(--calcite-color-brand)!important;outline-offset:2px!important}.display-flex{display:flex}.display-none{display:none}.flex-direction-column{flex-direction:column}.flex-direction-row{flex-direction:row}.font-weight-medium{font-weight:var(--calcite-font-weight-medium)}.font-style-1{font-size:1rem;color:var(--calcite-color-text-2)}.margin-top-0{margin-top:0}.padding-top-20{padding-top:20px}.padding-bottom-2{padding-bottom:2rem}.padding-left-2{padding-left:2rem}.padding-right-2{padding-right:2rem}.padding-end-1{padding-inline-end:1rem}.padding-end-1-2{padding-inline-end:.5rem}.width-full{width:100%}.justify-content-space{justify-content:space-between}`,x=class extends y{constructor(){super(...arguments),this.open=!1,this.source="Card Dropdown",this.solutionData={},this.templateInfos=[],this._saveDisabled=!1,this._displayTemplateInfos=[],this._hasNameLengthError=!1,this._nonSolutionDependencyItems=[],this._solutionItemsTitlesUpdating=!1,this._translations=D({name:"solution-configure-titles",blocking:!0}),this._configContextConsumer=C({context:b,subscribe:!0}),this._defaultPrefix="",this._defaultSuffix="",this._loadingDefaultPrefix=!1,this._loadingDefaultSuffix=!1,this._prefixRef=m(),this._prefixValue="",this._suffixRef=m(),this._suffixValue="",this._templateInfos=[],this._originalTitles=[],this.solutionConfigureTitlesBeforeClose=c(),this.solutionItemsTitlesChanged=c()}static{this.properties={card:0,open:5,source:1,solutionData:1,templateInfos:0,_saveDisabled:16,_displayTemplateInfos:16,_hasNameLengthError:16,_nonSolutionDependencyItems:16,_solutionItemsTitlesUpdating:16,_translations:16}}static{this.styles=N}async willUpdate(i){if(i.has("templateInfos")&&(this._templateInfos=JSON.parse(JSON.stringify(this.templateInfos)),this._updateTemplates()),i.has("open")){let t=i.get("open");if(this.open&&!t){await this._updatePrefixSuffix(),this._templateInfos=JSON.parse(JSON.stringify(this.templateInfos)),this._originalTitles=this._templateInfos.map(s=>({id:s.id,title:s.title})),this._updateTemplates();let e=await P(this._configContextConsumer.value.userSession,this.card);this._nonSolutionDependencyItems=e._nonSolutionDependencyItems,await this._accordionRef?.expandFirstItem()}}}get _telemetry(){return this._configContextConsumer.value?.telemetrySession}async load(){this._updateTemplates(),await this._updatePrefixSuffix()}async _updatePrefixSuffix(){this.solutionData=await S(this.card.id,this._configContextConsumer.value.userSession),this.solutionData.titles?.prefix&&(this._loadingDefaultPrefix=!0,this._defaultPrefix=this.solutionData.titles.prefix,this._prefixValue=this.solutionData.titles.prefix),this.solutionData.titles?.suffix&&(this._loadingDefaultSuffix=!0,this._defaultSuffix=this.solutionData.titles.suffix,this._suffixValue=this.solutionData.titles.suffix)}render(){return r`<calcite-dialog .heading=${this.card.title} modal @calciteDialogBeforeClose=${()=>{this.solutionConfigureTitlesBeforeClose.emit()}} .open=${this.open} outside-close-disabled width=l>${this._getPrefixSuffixControls()}${this._getAccordion()}${this._getDialogButtons()}</calcite-dialog>`}_getPrefixSuffixControls(){let i=_(this._prefixValue,"item"),t=this._hasNameLengthError&&this._prefixValue.length>0,e=!i,s=!t,n=e?"display-none":"",h=s?"display-none":"",a=e&&s?"valid":"invalid",l=_(this._suffixValue,"item"),o=this._hasNameLengthError&&this._suffixValue.length>0,d=!l,p=!o,E=d?"display-none":"",W=p?"display-none":"",k=d&&p?"valid":"invalid";return this._saveDisabled=!e||!s||!d||!p||!this._hasChanges(),r`<div class="display-flex flex-direction-column padding-left-2 padding-right-2 padding-top-20"><calcite-label scale=l class="font-weight-medium"><span tabindex=0>${this._translations.configureTitlesDialogHeader}</span></calcite-label><p class="font-style-1 margin-top-0" tabindex=0>${this._translations.addPrefixOrSuffixToItems}</p><div class="display-flex flex-direction-row justify-content-space"><calcite-label class="width-full padding-end-1" scale=l>${this._translations.prefixToAddToItems}<calcite-input clearable @blur=${this._prefixInput} @input=${this._prefixInput} .placeholder=${this._translations.enterPrefixPlaceholder} .status=${a} .value=${this._prefixValue} ${f(this._prefixRef)}></calcite-input><calcite-input-message class=${u(n)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixCharsError}</calcite-input-message><calcite-input-message class=${u(h)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixLengthError}</calcite-input-message></calcite-label><calcite-label class="width-full" scale=l>${this._translations.suffixToAddToItems}<calcite-input clearable @blur=${this._suffixInput} @input=${this._suffixInput} .placeholder=${this._translations.enterSuffixPlaceholder} .status=${k} .value=${this._suffixValue} ${f(this._suffixRef)}></calcite-input><calcite-input-message class=${u(E)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixCharsError}</calcite-input-message><calcite-input-message class=${u(W)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixLengthError}</calcite-input-message></calcite-label></div></div>`}_getAccordion(){let i=[...new Set(this._nonSolutionDependencyItems.map(t=>t.controlItemId))];return r`<div class="display-flex flex-direction-column padding-left-2 padding-right-2 padding-bottom-2"><p class="font-style-1 margin-top-0">${this._translations.previewTheChanges}</p><solution-item-accordion .itemRelationshipDependencies=${i} list-selection-mode=multiple .reuseWarning=${this._translations.itemDependencyReuseWarning} .templateInfos=${this._displayTemplateInfos} .typeKeywords=${this.card?.typeKeywords} ${f(async t=>{t&&(this._accordionRef=t)})}></solution-item-accordion></div>`}_getDialogButtons(){return r`<div slot=footer-end><calcite-button appearance=outline class="padding-end-1-2" kind=brand @click=${this._closeDialog}>${this._translations.cancelTheDialog}</calcite-button><calcite-button .disabled=${this._saveDisabled} kind=brand .loading=${this._solutionItemsTitlesUpdating} @click=${this._commitNameChanges}>${this._translations.applyChangesAndCloseTheDialog}</calcite-button></div>`}_prefixInput(){clearTimeout(this._textInputTimeout),this._textInputTimeout=setTimeout(()=>{this._prefixValue=this._prefixRef.value?.value||"",this._updateTemplates()},500)}_suffixInput(){clearTimeout(this._textInputTimeout),this._textInputTimeout=setTimeout(()=>{this._suffixValue=this._suffixRef.value?.value||"",this._updateTemplates()},500)}_updateTemplates(){this._templateInfos=this._templateInfos.map(t=>(this._loadingDefaultPrefix&&t.title.startsWith(this._prefixValue)&&(t.title=this._replaceStart(t.title,this._prefixValue,"")),this._loadingDefaultSuffix&&t.title.endsWith(this._suffixValue)&&(t.title=this._replaceAtEnd(t.title,this._suffixValue,"")),t));let i=JSON.parse(JSON.stringify(this._templateInfos));this._hasNameLengthError=!1,this._displayTemplateInfos=i.map(t=>{let e=this._prefixValue!=="",s=this._suffixValue!=="",n=this._defaultPrefix!=="",h=this._defaultSuffix!=="",a=t.title;e&&(n?this._originalTitles.find(o=>o.id===t.id)?.title.startsWith(this._defaultPrefix)?a=this._applyPrefixWithDuplicateCheck(t.title,this._prefixValue):this._prefixValue!==this._defaultPrefix&&(a=this._applyPrefixWithDuplicateCheck(t.title,this._prefixValue)):a=this._applyPrefixWithDuplicateCheck(t.title,this._prefixValue));let l=a;return s&&(h?this._originalTitles.find(o=>o.id===t.id)?.title.endsWith(this._defaultSuffix)?l=this._applySuffixWithDuplicateCheck(a,this._suffixValue):this._suffixValue!==this._defaultSuffix&&(l=this._applySuffixWithDuplicateCheck(a,this._suffixValue)):l=this._applySuffixWithDuplicateCheck(a,this._suffixValue)),t.title=l,this._hasNameLengthError||(this._hasNameLengthError=t.title.length>V),t}),this._loadingDefaultPrefix=!1,this._loadingDefaultSuffix=!1}_replaceStart(i,t,e){return i.startsWith(t)?`${e}${i.slice(t.length)}`:i}_replaceAtEnd(i,t,e){return i.endsWith(t)?`${i.substring(0,i.length-t.length)}${e}`:i}_applyPrefixWithDuplicateCheck(i,t){return!t||i.startsWith(t)?i:t+i}_applySuffixWithDuplicateCheck(i,t){return!t||i.endsWith(t)?i:i+t}_hasChanges(){let i=this._defaultPrefix!==this._prefixValue,t=this._defaultSuffix!==this._suffixValue;return this._displayTemplateInfos.some(e=>{let s=this._originalTitles.find(n=>n.id===e.id);return s&&s.title!==e.title})||i||t}_closeDialog(){this.open=!1}async _commitNameChanges(){if(this._hasChanges()){this._telemetry?.logEvent({category:w.DEPLOYMENTS,action:"Rename Items",dimensions:[this.card?.title||"",this.card?.deployCommonId||"",this.card?.deployVersion||"",this.source]}),this._solutionItemsTitlesUpdating=!0;let i=this._displayTemplateInfos.reduce((t,e)=>{let s={id:e.id,title:e.title};return t.push(e.type==="Group"?T(s,this._configContextConsumer.value.userSession):v(s,this._configContextConsumer.value.userSession,void 0,{solutionOwner:this.card?.owner})),t},[]);if(this.solutionData?.templates){let t={id:this.card.id},e={...this.solutionData,titles:{prefix:this._prefixValue,suffix:this._suffixValue}};i.push($(t,e,this._configContextConsumer.value.userSession,void 0,void 0,null,this.card?.owner))}await Promise.all(i),this._solutionItemsTitlesUpdating=!1,this.solutionItemsTitlesChanged.emit()}this._closeDialog()}};I("solution-configure-titles",x);return x},a,b)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as W}from"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as T}from"./2CMRI2B3.js";import{F as h,G as n,H as b,J as a,h as u,i as r,l as _,r as y}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([x,V])=>{var C=u`:host{display:block}.display-none{display:none}.display-flex{display:flex}.margin-top-1-2{margin-top:.5rem}.margin-left-1-2{margin-left:.5rem}.margin-right-1-2{margin-right:.5rem}.square-32{width:32px;height:32px}.square-40{width:40px;height:40px}.square-48{width:48px;height:48px}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.box-shadow{box-shadow:0 1px 2px #0000004d}.margin-bottom-1-2{margin-bottom:.5rem}.danger-icon-color{--calcite-icon-color: var(--calcite-color-status-danger)}`,m=class extends b{constructor(){super(),this.enabledLayerIds=[],this.enableLegend=!1,this.enableLayerList=!1,this.enableFloorFilter=!1,this.enableFullscreen=!1,this.enableSearch=!1,this.enableBasemap=!1,this.enableHome=!1,this.enableSingleExpand=!1,this.zoomToolsSize="m",this.layout="vertical",this.mapWidgetsSize="m",this.enableMapPicker=!1,this.enableMapLayerPicker=!1,this.position="top-leading",this.stackTools=!0,this.enableSelectionTool=!1,this.toolOrder=["home","legend","search","fullscreen","floorfilter","layers-list","selectiontool","map-picker","map-layer-picker"],this.selectionTools=["rectangle-select","lasso-select","clear-selection"],this.mapInfos=[],this.defaultLayerId="",this.isMobile=!1,this.selectedFeaturesIds=[],this.selectedWebMapId="",this.showOnlyUpdatableLayers=!1,this.visibilityIcon="eyeball",this._hasFloorInfo=!1,this._translations=W({name:"map-tools",blocking:!0}),this._showTools=!0,this._showBasemapWidget=!1,this._showFloorFilter=!1,this._showFullscreen=!1,this._showLegendWidget=!1,this._showSearchWidget=!1,this._showLayersListWidget=!1,this._rectangleSelectionToolActive=!1,this._lassoSelectionToolActive=!1,this._showEllipsisTools=!0,this._ellipsisTools=[],this._isValidWebMap=!0,this._showSelectionTools=!1,this._basemapElement=h(),this._floorFilterElement=h(),this._fullscreenElement=h(),this._layerListWidgetElement=h(),this._legendElement=h(),this._searchElement=h(),this._widgets=[],this._selectionToolElement=h(),this._mapTools=[],this._mapTool=h(),this.clearSelection=y(),this.listenOn(window,"mapChanged",this.mapChanged),this.listenOn(window,"layerSelectionChange",this._layerSelectionChange)}static{this.properties={basemapConfig:0,enabledLayerIds:0,enableLegend:5,enableLayerList:5,enableFloorFilter:5,enableFullscreen:5,enableSearch:5,enableBasemap:5,enableHome:5,enableSingleExpand:5,zoomToolsSize:1,layout:1,mapView:0,mapWidgetsSize:1,enableMapPicker:5,enableMapLayerPicker:5,position:1,searchConfiguration:0,stackTools:5,enableSelectionTool:5,toolOrder:0,selectionTools:0,selectedLayer:0,mapInfos:0,defaultLayerId:1,isMobile:5,parentComponentHeight:9,parentComponentWidth:9,selectedFeaturesIds:0,selectedWebMapId:1,showOnlyUpdatableLayers:5,mapInfo:0,visibilityIcon:1,_hasFloorInfo:16,_translations:16,_showTools:16,_showBasemapWidget:16,_showFloorFilter:16,_showFullscreen:16,_showLegendWidget:16,_showSearchWidget:16,_showLayersListWidget:16,_rectangleSelectionToolActive:16,_lassoSelectionToolActive:16,_showEllipsisTools:16,_ellipsisTools:16,_isValidWebMap:16,_showSelectionTools:16}}static{this.styles=C}willUpdate(t){t.has("mapView")&&this.mapViewWatchHandler(),t.has("parentComponentWidth")&&this.parentComponentWidth&&this.parentComponentWidthWatchHandler(this.parentComponentWidth),t.has("_showBasemapWidget")&&(this.hasUpdated||this._showBasemapWidget!==!1)&&this._showBasemapWidgetWatchHandler(this._showBasemapWidget),t.has("_showLayersListWidget")&&(this.hasUpdated||this._showLayersListWidget!==!1)&&this._showLayersListWidgetWatchHandler(this._showLayersListWidget),t.has("_showFloorFilter")&&(this.hasUpdated||this._showFloorFilter!==!1)&&this._showFloorFilterWatchHandler(this._showFloorFilter),t.has("_showFullscreen")&&(this.hasUpdated||this._showFullscreen!==!1)&&this._showFullscreenWatchHandler(this._showFullscreen),t.has("_showLegendWidget")&&(this.hasUpdated||this._showLegendWidget!==!1)&&this._showLegendWidgetWatchHandler(this._showLegendWidget),t.has("_showSearchWidget")&&(this.hasUpdated||this._showSearchWidget!==!1)&&this._showSearchWidgetWatchHandler(this._showSearchWidget)}async mapViewWatchHandler(){await this.mapView?.when(()=>{this.enableHome&&this._initHome(),this.parentComponentWidth&&this._updateTools(this.parentComponentWidth)})}async parentComponentWidthWatchHandler(t){this._updateTools(t)}async _showBasemapWidgetWatchHandler(t){let e=this._basemapElement.value?this._basemapElement.value.basemapWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showLayersListWidgetWatchHandler(t){let e=this._layerListWidgetElement.value?this._layerListWidgetElement.value.layerListWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showFloorFilterWatchHandler(t){let e=this._floorFilterElement.value?this._floorFilterElement.value.floorFilterWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showFullscreenWatchHandler(t){let e=this._fullscreenElement.value?this._fullscreenElement.value.fullscreenWidget:void 0;e&&(t?e.viewModel.state==="ready"&&e.viewModel.enter():e.viewModel.state==="active"&&e.viewModel.exit())}async _showLegendWidgetWatchHandler(t){let e=this._legendElement.value?this._legendElement.value.legendWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showSearchWidgetWatchHandler(t){let e=this._searchElement.value?this._searchElement.value.searchWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async mapChanged(t){let e=t.detail.isValid;this._isValidWebMap=e,this._showTools||this._toggleTools()}async _layerSelectionChange(t){this._showTools||this._toggleTools()}async load(){this._mapTools=[...this.toolOrder]}render(){this._setZoomToolsSize();let t=this.layout==="horizontal"?"display-flex":"",e=this._getToggleIcon(),s=!this._showTools&&!this._showSelectionTools?"display-none":t,o=this._showEllipsisTools?"":"display-none",l=this._showSearchWidget?"":"display-none",i=this._showBasemapWidget?"":"display-none",c=this._showLegendWidget?"":"display-none",d=this._showFloorFilter?"":"display-none",p=this._showFullscreen?"":"display-none",v=this._showLayersListWidget?"":"display-none",f=this._showTools?this._translations.collapse:this._translations.expand,L=!this.enableBasemap&&!this.enableFullscreen&&!this.enableLegend&&!this.enableLayerList&&!this.enableSearch&&!this.enableMapPicker&&!this.enableMapLayerPicker?"display-none":"",S=document.dir==="rtl"?"margin-right-1-2":"margin-left-1-2",F=this.enableSingleExpand?this.layout==="horizontal"?S:"margin-top-1-2":"",$=this._ellipsisTools.length>0&&this._showTools?"":"display-none",w=this.stackTools&&this._ellipsisTools.length===0?"box-shadow":"",E=this._showSelectionTools?this.selectionTools:this._mapTools;return r`<div class=${`${L} ${t}`}>${this.enableSingleExpand?r`<div class=${a(w)}>${this._getActionGroup(e,!1,f||"",()=>this._toggleTools())}</div>`:void 0}<div class=${`${F} ${w} ${s}`}>${this._getMapWidgets(E)}</div><div><div class=${a($)}>${this._getActionGroup("ellipsis",!1,"",()=>this._toggleEllipsisTools())}<div class=${a(o)}>${this._getMapWidgets(this._ellipsisTools)}</div></div></div></div><map-basemap-gallery .basemapConfig=${this.basemapConfig} class=${a(i)} .mapView=${this.mapView} ${n(this._basemapElement)}></map-basemap-gallery><map-search class=${a(l)} .mapView=${this.mapView} result-graphic-enabled .searchConfiguration=${this.searchConfiguration} ${n(this._searchElement)}></map-search><map-legend class=${a(c)} .mapView=${this.mapView} ${n(this._legendElement)}></map-legend><map-fullscreen class=${a(p)} .mapView=${this.mapView} @fullscreenStateChange=${g=>this._fullscreenStateChange(g.detail)} ${n(this._fullscreenElement)}></map-fullscreen><layer-list-widget class=${a(v)} .mapView=${this.mapView} @fullscreenStateChange=${g=>this._fullscreenStateChange(g.detail)} .visibilityIcon=${this.visibilityIcon} ${n(this._layerListWidgetElement)}></layer-list-widget><map-floor-filter class=${a(d)} .enabled=${this.enableFloorFilter} .mapView=${this.mapView} ${n(this._floorFilterElement)}></map-floor-filter><selection-tool .mapView=${this.mapView} @drawingComplete=${()=>{this._rectangleSelectionToolActive=!1,this._lassoSelectionToolActive=!1}} .selectedLayerId=${this.selectedLayer?.id} ${n(this._selectionToolElement)}></selection-tool>${this.enableMapPicker&&r`<map-picker class=mapPickerClass .height=${(this.parentComponentHeight??0)-25} id=map-picker .mapInfos=${this.mapInfos} reference-element=map .selectedWebMapId=${this.selectedWebMapId} show-map-list-in-popover></map-picker>`||""}${this.enableMapLayerPicker&&this.selectedLayer&&r`<map-layer-picker appearance=transparent .defaultLayerId=${this.defaultLayerId} .enabledLayerIds=${this.enabledLayerIds} .height=${(this.parentComponentHeight??0)-25} .isMobile=${this.isMobile} .mapView=${this.mapView} .showOnlyUpdatableLayers=${this.showOnlyUpdatableLayers} reference-element=layers scale=s .selectedIds=${this.selectedLayer?[this.selectedLayer.id]:[]} show-layers-list-in-popover show-tables type=dropdown></map-layer-picker>`||""}`}_initHome(){this.enableHome&&(this._homeWidget=new V({view:this.mapView}))}_setZoomToolsSize(){let t=document.getElementsByClassName("esri-zoom")[0]?.children[0],e=document.getElementsByClassName("esri-zoom")[0]?.children[1];if(t&&e){let s=this.zoomToolsSize==="s"?"32px":this.zoomToolsSize==="m"?"40px":"48px";t.style.width=s,t.style.height=s,e.style.width=s,e.style.height=s}if(this.layout==="horizontal"){let s=document.dir||"ltr",o=s==="ltr"?"esri-ui-top-left":"esri-ui-top-right",l=s==="ltr"?0:this.parentComponentWidth-62,i=s==="ltr"?this._showTools?"ltr":"rtl":this._showTools?"rtl":"ltr";document.getElementsByClassName(o)[0]?.firstElementChild?.tagName==="MAP-TOOLS"&&!this._showTools&&(i=s),document.getElementsByClassName("esri-zoom")[0]?.setAttribute("style",`position: absolute; top: 50px; left: ${l}px`),this._showSelectionTools||document.getElementsByClassName(o)[0]?.setAttribute("style",`flex-direction: row; gap: 5px; align-items: flex-start; direction: ${i} !important; z-index: 1;`)}}_getToggleIcon(){let t=document.dir||"ltr";return this.layout==="horizontal"?t==="ltr"?this._showTools?"chevrons-left":"chevrons-right":this._showTools?"chevrons-right":"chevrons-left":this._showTools?"chevrons-up":"chevrons-down"}_updateTools(t){let e=this._showSelectionTools?JSON.parse(JSON.stringify(this.selectionTools)):JSON.parse(JSON.stringify(this.toolOrder));this._hasFloorInfo=this.mapView?.map?.floorInfo;let s=e.indexOf("floorfilter");s>-1&&!this._hasFloorInfo&&e.splice(s,1);let o=40,l=110;this.isMobile&&(this.enableMapPicker||this.enableMapLayerPicker)&&(l=160);let i=Math.ceil((t-l)/o)-1;i&&i!==e.length-1?(this._mapTools=e.slice(0,i),this._ellipsisTools=e.slice(i,e.length)):(this._mapTools=e,this._ellipsisTools=[])}_getMapWidgets(t){let e=this._showFullscreen?"full-screen-exit":"full-screen",s=this._showFullscreen?this._translations.exitFullscreen:this._translations.enterFullscreen,o=this._isValidWebMap?"map":"exclamation-mark-triangle",l=this.selectedLayer===void 0?"exclamation-mark-triangle":"layers";return t.map(i=>{switch(i){case"legend":return this.enableLegend&&this.enableSingleExpand?this._getActionGroup("legend",!1,this._translations.legend,()=>this._showLegend()):this.enableLegend?this._getWidget(i,this._legendElement.value?.legendWidget,!0):void 0;case"search":return this.enableSearch&&this.enableSingleExpand?this._getActionGroup("magnifying-glass",!1,this._translations.search,()=>this._search()):this.enableSearch?this._getWidget(i,this._searchElement.value?.searchWidget,!0):void 0;case"fullscreen":return this.enableFullscreen&&this.enableSingleExpand?this._getActionGroup(e,!1,s||"",()=>this._expand()):this.enableFullscreen?this._getWidget(i,this._fullscreenElement.value?.fullscreenWidget,!1):void 0;case"basemap":return this.enableBasemap&&this.enableSingleExpand?this._getActionGroup("basemap",!1,this._translations.basemap,()=>this._toggleBasemapPicker()):this.enableBasemap?this._getWidget(i,this._basemapElement.value?.basemapWidget,!0):void 0;case"layers-list":return this.enableLayerList&&this.enableSingleExpand?this._getActionGroup("layers",!1,this._translations.layers||"",()=>this._toggleLayerListWidget()):this.enableLayerList?this._getWidget(i,this._layerListWidgetElement.value?.layerListWidget,!0):void 0;case"floorfilter":return this.enableFloorFilter&&this._hasFloorInfo&&this.enableSingleExpand?this._getActionGroup("urban-model",!1,this._translations.floorFilter,()=>this._toggleFloorFilter()):this.enableFloorFilter&&this._hasFloorInfo?this._getWidget(i,this._floorFilterElement.value?.floorFilterWidget,!0):void 0;case"selectiontool":return this.enableSelectionTool&&this.selectedLayer?this._getActionGroup("cursor-selection",!1,this._translations.selectionTools,this._onSelectionToolClick,!1):void 0;case"rectangle-select":return this.enableSelectionTool&&this.selectedLayer?this._getActionGroup("cursor-marquee",!1,this._translations.selectByRectangle,()=>this._toggleSelectionTool("rectangle"),!1,this._rectangleSelectionToolActive):void 0;case"lasso-select":return this.enableSelectionTool&&this.selectedLayer?this._getActionGroup("lasso-select",!1,this._translations.selectByLasso,()=>this._toggleSelectionTool("freehandPolygon"),!1,this._lassoSelectionToolActive):void 0;case"clear-selection":return this.selectedLayer&&this.selectedFeaturesIds.length>0?this._getActionGroup("erase",!1,this._translations.clearSelection,()=>this.clearSelection.emit()):void 0;case"home":return this.enableHome?this._getActionGroup("home",!1,this._translations.defaultMapView,()=>this._homeWidget?.go()):void 0;case"map-picker":return this.enableMapPicker?this._getActionGroup(o,!1,"",()=>{},!this._isValidWebMap):void 0;case"map-layer-picker":return this.enableMapLayerPicker&&this._isValidWebMap?this._getActionGroup(l,!1,"",()=>{},this.selectedLayer===void 0):void 0;default:return""}})}_fullscreenStateChange(t){t==="ready"&&this._showFullscreen?this._showFullscreen=!1:t==="active"&&!this._showFullscreen&&(this._showFullscreen=!0)}_getActionGroup(t,e,s,o,l,i){let c=this.mapWidgetsSize==="s"?"square-32":this.mapWidgetsSize==="m"?"square-40":"square-48",d=this.stackTools?"":"margin-bottom-1-2",p=this.stackTools?"":"box-shadow";return r`<div><calcite-action alignment=center appearance=solid .indicator=${i} class=${`map-actions ${c} ${d} border-bottom ${p} ${l?"danger-icon-color":""}`} .disabled=${e} .icon=${t} id=${t??_} @click=${o} scale=s text ${n(this._mapTool)}><calcite-icon icon=chevron-up scale=s slot=icon></calcite-icon></calcite-action>${!this.isMobile&&s&&r`<calcite-tooltip .placement=${this.layout==="vertical"?"auto":"bottom"} reference-element=${t??_}><span>${s}</span></calcite-tooltip>`||""}</div>`}_getWidget(t,e,s){if(this._widgets.indexOf(t)<0&&this.mapView&&e){let o=this.toolOrder.indexOf(t),l=new x({view:this.mapView,content:e}),i=this.enableHome?2:1;this.mapView.ui.add(s?l:e,{position:this.position,index:o>-1?o+i:1}),this._widgets.push(t)}}_showLegend(){this._showLegendWidget=!this._showLegendWidget,this._showTools=!1,this._toggleEllipsisTools()}_search(){this._showSearchWidget=!this._showSearchWidget,this._showTools=!1,this._toggleEllipsisTools()}_toggleBasemapPicker(){this._showBasemapWidget=!this._showBasemapWidget,this._showTools=!1,this._toggleEllipsisTools()}_toggleLayerListWidget(){this._showLayersListWidget=!this._showLayersListWidget,this._showTools=!1,this._toggleEllipsisTools()}_toggleFloorFilter(){this._showFloorFilter=!this._showFloorFilter,this._showTools=!1,this._toggleEllipsisTools()}_onSelectionToolClick(){this._showSelectionTools=!this._showSelectionTools,this._showTools=!1,this._toggleEllipsisTools()}_toggleSelectionTool(t){t==="rectangle"?(this._lassoSelectionToolActive=!1,this._rectangleSelectionToolActive=!this._rectangleSelectionToolActive):t==="freehandPolygon"&&(this._rectangleSelectionToolActive=!1,this._lassoSelectionToolActive=!this._lassoSelectionToolActive),this._selectionToolElement.value?.toggleSelectionTool(t,this._rectangleSelectionToolActive||this._lassoSelectionToolActive)}_expand(){this._showFullscreen=!this._showFullscreen}_toggleTools(){this._showTools||(this._showSelectionTools=!1,this._showBasemapWidget=!1,this._showLayersListWidget=!1,this._showSearchWidget=!1,this._showLegendWidget=!1,this._showFloorFilter=!1),this._rectangleSelectionToolActive?this._toggleSelectionTool("rectangle"):this._lassoSelectionToolActive&&this._toggleSelectionTool("freehandPolygon"),this._showTools=!this._showTools,this._toggleEllipsisTools(),this._updateTools(this.parentComponentWidth)}_toggleEllipsisTools(){this._showEllipsisTools=!this._showEllipsisTools}};T("map-tools",m);return m},"widgets/Expand","widgets/Home")
2
+ import{a as W}from"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as T}from"./S7XOHDIW.js";import{F as h,G as n,H as b,J as a,h as u,i as r,l as _,r as y}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([x,V])=>{var C=u`:host{display:block}.display-none{display:none}.display-flex{display:flex}.margin-top-1-2{margin-top:.5rem}.margin-left-1-2{margin-left:.5rem}.margin-right-1-2{margin-right:.5rem}.square-32{width:32px;height:32px}.square-40{width:40px;height:40px}.square-48{width:48px;height:48px}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.box-shadow{box-shadow:0 1px 2px #0000004d}.margin-bottom-1-2{margin-bottom:.5rem}.danger-icon-color{--calcite-icon-color: var(--calcite-color-status-danger)}`,m=class extends b{constructor(){super(),this.enabledLayerIds=[],this.enableLegend=!1,this.enableLayerList=!1,this.enableFloorFilter=!1,this.enableFullscreen=!1,this.enableSearch=!1,this.enableBasemap=!1,this.enableHome=!1,this.enableSingleExpand=!1,this.zoomToolsSize="m",this.layout="vertical",this.mapWidgetsSize="m",this.enableMapPicker=!1,this.enableMapLayerPicker=!1,this.position="top-leading",this.stackTools=!0,this.enableSelectionTool=!1,this.toolOrder=["home","legend","search","fullscreen","floorfilter","layers-list","selectiontool","map-picker","map-layer-picker"],this.selectionTools=["rectangle-select","lasso-select","clear-selection"],this.mapInfos=[],this.defaultLayerId="",this.isMobile=!1,this.selectedFeaturesIds=[],this.selectedWebMapId="",this.showOnlyUpdatableLayers=!1,this.visibilityIcon="eyeball",this._hasFloorInfo=!1,this._translations=W({name:"map-tools",blocking:!0}),this._showTools=!0,this._showBasemapWidget=!1,this._showFloorFilter=!1,this._showFullscreen=!1,this._showLegendWidget=!1,this._showSearchWidget=!1,this._showLayersListWidget=!1,this._rectangleSelectionToolActive=!1,this._lassoSelectionToolActive=!1,this._showEllipsisTools=!0,this._ellipsisTools=[],this._isValidWebMap=!0,this._showSelectionTools=!1,this._basemapElement=h(),this._floorFilterElement=h(),this._fullscreenElement=h(),this._layerListWidgetElement=h(),this._legendElement=h(),this._searchElement=h(),this._widgets=[],this._selectionToolElement=h(),this._mapTools=[],this._mapTool=h(),this.clearSelection=y(),this.listenOn(window,"mapChanged",this.mapChanged),this.listenOn(window,"layerSelectionChange",this._layerSelectionChange)}static{this.properties={basemapConfig:0,enabledLayerIds:0,enableLegend:5,enableLayerList:5,enableFloorFilter:5,enableFullscreen:5,enableSearch:5,enableBasemap:5,enableHome:5,enableSingleExpand:5,zoomToolsSize:1,layout:1,mapView:0,mapWidgetsSize:1,enableMapPicker:5,enableMapLayerPicker:5,position:1,searchConfiguration:0,stackTools:5,enableSelectionTool:5,toolOrder:0,selectionTools:0,selectedLayer:0,mapInfos:0,defaultLayerId:1,isMobile:5,parentComponentHeight:9,parentComponentWidth:9,selectedFeaturesIds:0,selectedWebMapId:1,showOnlyUpdatableLayers:5,mapInfo:0,visibilityIcon:1,_hasFloorInfo:16,_translations:16,_showTools:16,_showBasemapWidget:16,_showFloorFilter:16,_showFullscreen:16,_showLegendWidget:16,_showSearchWidget:16,_showLayersListWidget:16,_rectangleSelectionToolActive:16,_lassoSelectionToolActive:16,_showEllipsisTools:16,_ellipsisTools:16,_isValidWebMap:16,_showSelectionTools:16}}static{this.styles=C}willUpdate(t){t.has("mapView")&&this.mapViewWatchHandler(),t.has("parentComponentWidth")&&this.parentComponentWidth&&this.parentComponentWidthWatchHandler(this.parentComponentWidth),t.has("_showBasemapWidget")&&(this.hasUpdated||this._showBasemapWidget!==!1)&&this._showBasemapWidgetWatchHandler(this._showBasemapWidget),t.has("_showLayersListWidget")&&(this.hasUpdated||this._showLayersListWidget!==!1)&&this._showLayersListWidgetWatchHandler(this._showLayersListWidget),t.has("_showFloorFilter")&&(this.hasUpdated||this._showFloorFilter!==!1)&&this._showFloorFilterWatchHandler(this._showFloorFilter),t.has("_showFullscreen")&&(this.hasUpdated||this._showFullscreen!==!1)&&this._showFullscreenWatchHandler(this._showFullscreen),t.has("_showLegendWidget")&&(this.hasUpdated||this._showLegendWidget!==!1)&&this._showLegendWidgetWatchHandler(this._showLegendWidget),t.has("_showSearchWidget")&&(this.hasUpdated||this._showSearchWidget!==!1)&&this._showSearchWidgetWatchHandler(this._showSearchWidget)}async mapViewWatchHandler(){await this.mapView?.when(()=>{this.enableHome&&this._initHome(),this.parentComponentWidth&&this._updateTools(this.parentComponentWidth)})}async parentComponentWidthWatchHandler(t){this._updateTools(t)}async _showBasemapWidgetWatchHandler(t){let e=this._basemapElement.value?this._basemapElement.value.basemapWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showLayersListWidgetWatchHandler(t){let e=this._layerListWidgetElement.value?this._layerListWidgetElement.value.layerListWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showFloorFilterWatchHandler(t){let e=this._floorFilterElement.value?this._floorFilterElement.value.floorFilterWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showFullscreenWatchHandler(t){let e=this._fullscreenElement.value?this._fullscreenElement.value.fullscreenWidget:void 0;e&&(t?e.viewModel.state==="ready"&&e.viewModel.enter():e.viewModel.state==="active"&&e.viewModel.exit())}async _showLegendWidgetWatchHandler(t){let e=this._legendElement.value?this._legendElement.value.legendWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async _showSearchWidgetWatchHandler(t){let e=this._searchElement.value?this._searchElement.value.searchWidget:void 0,s=document.dir==="rtl"?"rtl":"ltr";e&&(t?(this.mapView?.ui.add(e,{position:this.position,index:1}),e.container?.style.setProperty("direction",s)):this.mapView?.ui.remove(e))}async mapChanged(t){let e=t.detail.isValid;this._isValidWebMap=e,this._showTools||this._toggleTools()}async _layerSelectionChange(t){this._showTools||this._toggleTools()}async load(){this._mapTools=[...this.toolOrder]}render(){this._setZoomToolsSize();let t=this.layout==="horizontal"?"display-flex":"",e=this._getToggleIcon(),s=!this._showTools&&!this._showSelectionTools?"display-none":t,o=this._showEllipsisTools?"":"display-none",l=this._showSearchWidget?"":"display-none",i=this._showBasemapWidget?"":"display-none",c=this._showLegendWidget?"":"display-none",d=this._showFloorFilter?"":"display-none",p=this._showFullscreen?"":"display-none",v=this._showLayersListWidget?"":"display-none",f=this._showTools?this._translations.collapse:this._translations.expand,L=!this.enableBasemap&&!this.enableFullscreen&&!this.enableLegend&&!this.enableLayerList&&!this.enableSearch&&!this.enableMapPicker&&!this.enableMapLayerPicker?"display-none":"",S=document.dir==="rtl"?"margin-right-1-2":"margin-left-1-2",F=this.enableSingleExpand?this.layout==="horizontal"?S:"margin-top-1-2":"",$=this._ellipsisTools.length>0&&this._showTools?"":"display-none",w=this.stackTools&&this._ellipsisTools.length===0?"box-shadow":"",E=this._showSelectionTools?this.selectionTools:this._mapTools;return r`<div class=${`${L} ${t}`}>${this.enableSingleExpand?r`<div class=${a(w)}>${this._getActionGroup(e,!1,f||"",()=>this._toggleTools())}</div>`:void 0}<div class=${`${F} ${w} ${s}`}>${this._getMapWidgets(E)}</div><div><div class=${a($)}>${this._getActionGroup("ellipsis",!1,"",()=>this._toggleEllipsisTools())}<div class=${a(o)}>${this._getMapWidgets(this._ellipsisTools)}</div></div></div></div><map-basemap-gallery .basemapConfig=${this.basemapConfig} class=${a(i)} .mapView=${this.mapView} ${n(this._basemapElement)}></map-basemap-gallery><map-search class=${a(l)} .mapView=${this.mapView} result-graphic-enabled .searchConfiguration=${this.searchConfiguration} ${n(this._searchElement)}></map-search><map-legend class=${a(c)} .mapView=${this.mapView} ${n(this._legendElement)}></map-legend><map-fullscreen class=${a(p)} .mapView=${this.mapView} @fullscreenStateChange=${g=>this._fullscreenStateChange(g.detail)} ${n(this._fullscreenElement)}></map-fullscreen><layer-list-widget class=${a(v)} .mapView=${this.mapView} @fullscreenStateChange=${g=>this._fullscreenStateChange(g.detail)} .visibilityIcon=${this.visibilityIcon} ${n(this._layerListWidgetElement)}></layer-list-widget><map-floor-filter class=${a(d)} .enabled=${this.enableFloorFilter} .mapView=${this.mapView} ${n(this._floorFilterElement)}></map-floor-filter><selection-tool .mapView=${this.mapView} @drawingComplete=${()=>{this._rectangleSelectionToolActive=!1,this._lassoSelectionToolActive=!1}} .selectedLayerId=${this.selectedLayer?.id} ${n(this._selectionToolElement)}></selection-tool>${this.enableMapPicker&&r`<map-picker class=mapPickerClass .height=${(this.parentComponentHeight??0)-25} id=map-picker .mapInfos=${this.mapInfos} reference-element=map .selectedWebMapId=${this.selectedWebMapId} show-map-list-in-popover></map-picker>`||""}${this.enableMapLayerPicker&&this.selectedLayer&&r`<map-layer-picker appearance=transparent .defaultLayerId=${this.defaultLayerId} .enabledLayerIds=${this.enabledLayerIds} .height=${(this.parentComponentHeight??0)-25} .isMobile=${this.isMobile} .mapView=${this.mapView} .showOnlyUpdatableLayers=${this.showOnlyUpdatableLayers} reference-element=layers scale=s .selectedIds=${this.selectedLayer?[this.selectedLayer.id]:[]} show-layers-list-in-popover show-tables type=dropdown></map-layer-picker>`||""}`}_initHome(){this.enableHome&&(this._homeWidget=new V({view:this.mapView}))}_setZoomToolsSize(){let t=document.getElementsByClassName("esri-zoom")[0]?.children[0],e=document.getElementsByClassName("esri-zoom")[0]?.children[1];if(t&&e){let s=this.zoomToolsSize==="s"?"32px":this.zoomToolsSize==="m"?"40px":"48px";t.style.width=s,t.style.height=s,e.style.width=s,e.style.height=s}if(this.layout==="horizontal"){let s=document.dir||"ltr",o=s==="ltr"?"esri-ui-top-left":"esri-ui-top-right",l=s==="ltr"?0:this.parentComponentWidth-62,i=s==="ltr"?this._showTools?"ltr":"rtl":this._showTools?"rtl":"ltr";document.getElementsByClassName(o)[0]?.firstElementChild?.tagName==="MAP-TOOLS"&&!this._showTools&&(i=s),document.getElementsByClassName("esri-zoom")[0]?.setAttribute("style",`position: absolute; top: 50px; left: ${l}px`),this._showSelectionTools||document.getElementsByClassName(o)[0]?.setAttribute("style",`flex-direction: row; gap: 5px; align-items: flex-start; direction: ${i} !important; z-index: 1;`)}}_getToggleIcon(){let t=document.dir||"ltr";return this.layout==="horizontal"?t==="ltr"?this._showTools?"chevrons-left":"chevrons-right":this._showTools?"chevrons-right":"chevrons-left":this._showTools?"chevrons-up":"chevrons-down"}_updateTools(t){let e=this._showSelectionTools?JSON.parse(JSON.stringify(this.selectionTools)):JSON.parse(JSON.stringify(this.toolOrder));this._hasFloorInfo=this.mapView?.map?.floorInfo;let s=e.indexOf("floorfilter");s>-1&&!this._hasFloorInfo&&e.splice(s,1);let o=40,l=110;this.isMobile&&(this.enableMapPicker||this.enableMapLayerPicker)&&(l=160);let i=Math.ceil((t-l)/o)-1;i&&i!==e.length-1?(this._mapTools=e.slice(0,i),this._ellipsisTools=e.slice(i,e.length)):(this._mapTools=e,this._ellipsisTools=[])}_getMapWidgets(t){let e=this._showFullscreen?"full-screen-exit":"full-screen",s=this._showFullscreen?this._translations.exitFullscreen:this._translations.enterFullscreen,o=this._isValidWebMap?"map":"exclamation-mark-triangle",l=this.selectedLayer===void 0?"exclamation-mark-triangle":"layers";return t.map(i=>{switch(i){case"legend":return this.enableLegend&&this.enableSingleExpand?this._getActionGroup("legend",!1,this._translations.legend,()=>this._showLegend()):this.enableLegend?this._getWidget(i,this._legendElement.value?.legendWidget,!0):void 0;case"search":return this.enableSearch&&this.enableSingleExpand?this._getActionGroup("magnifying-glass",!1,this._translations.search,()=>this._search()):this.enableSearch?this._getWidget(i,this._searchElement.value?.searchWidget,!0):void 0;case"fullscreen":return this.enableFullscreen&&this.enableSingleExpand?this._getActionGroup(e,!1,s||"",()=>this._expand()):this.enableFullscreen?this._getWidget(i,this._fullscreenElement.value?.fullscreenWidget,!1):void 0;case"basemap":return this.enableBasemap&&this.enableSingleExpand?this._getActionGroup("basemap",!1,this._translations.basemap,()=>this._toggleBasemapPicker()):this.enableBasemap?this._getWidget(i,this._basemapElement.value?.basemapWidget,!0):void 0;case"layers-list":return this.enableLayerList&&this.enableSingleExpand?this._getActionGroup("layers",!1,this._translations.layers||"",()=>this._toggleLayerListWidget()):this.enableLayerList?this._getWidget(i,this._layerListWidgetElement.value?.layerListWidget,!0):void 0;case"floorfilter":return this.enableFloorFilter&&this._hasFloorInfo&&this.enableSingleExpand?this._getActionGroup("urban-model",!1,this._translations.floorFilter,()=>this._toggleFloorFilter()):this.enableFloorFilter&&this._hasFloorInfo?this._getWidget(i,this._floorFilterElement.value?.floorFilterWidget,!0):void 0;case"selectiontool":return this.enableSelectionTool&&this.selectedLayer?this._getActionGroup("cursor-selection",!1,this._translations.selectionTools,this._onSelectionToolClick,!1):void 0;case"rectangle-select":return this.enableSelectionTool&&this.selectedLayer?this._getActionGroup("cursor-marquee",!1,this._translations.selectByRectangle,()=>this._toggleSelectionTool("rectangle"),!1,this._rectangleSelectionToolActive):void 0;case"lasso-select":return this.enableSelectionTool&&this.selectedLayer?this._getActionGroup("lasso-select",!1,this._translations.selectByLasso,()=>this._toggleSelectionTool("freehandPolygon"),!1,this._lassoSelectionToolActive):void 0;case"clear-selection":return this.selectedLayer&&this.selectedFeaturesIds.length>0?this._getActionGroup("erase",!1,this._translations.clearSelection,()=>this.clearSelection.emit()):void 0;case"home":return this.enableHome?this._getActionGroup("home",!1,this._translations.defaultMapView,()=>this._homeWidget?.go()):void 0;case"map-picker":return this.enableMapPicker?this._getActionGroup(o,!1,"",()=>{},!this._isValidWebMap):void 0;case"map-layer-picker":return this.enableMapLayerPicker&&this._isValidWebMap?this._getActionGroup(l,!1,"",()=>{},this.selectedLayer===void 0):void 0;default:return""}})}_fullscreenStateChange(t){t==="ready"&&this._showFullscreen?this._showFullscreen=!1:t==="active"&&!this._showFullscreen&&(this._showFullscreen=!0)}_getActionGroup(t,e,s,o,l,i){let c=this.mapWidgetsSize==="s"?"square-32":this.mapWidgetsSize==="m"?"square-40":"square-48",d=this.stackTools?"":"margin-bottom-1-2",p=this.stackTools?"":"box-shadow";return r`<div><calcite-action alignment=center appearance=solid .indicator=${i} class=${`map-actions ${c} ${d} border-bottom ${p} ${l?"danger-icon-color":""}`} .disabled=${e} .icon=${t} id=${t??_} @click=${o} scale=s text ${n(this._mapTool)}><calcite-icon icon=chevron-up scale=s slot=icon></calcite-icon></calcite-action>${!this.isMobile&&s&&r`<calcite-tooltip .placement=${this.layout==="vertical"?"auto":"bottom"} reference-element=${t??_}><span>${s}</span></calcite-tooltip>`||""}</div>`}_getWidget(t,e,s){if(this._widgets.indexOf(t)<0&&this.mapView&&e){let o=this.toolOrder.indexOf(t),l=new x({view:this.mapView,content:e}),i=this.enableHome?2:1;this.mapView.ui.add(s?l:e,{position:this.position,index:o>-1?o+i:1}),this._widgets.push(t)}}_showLegend(){this._showLegendWidget=!this._showLegendWidget,this._showTools=!1,this._toggleEllipsisTools()}_search(){this._showSearchWidget=!this._showSearchWidget,this._showTools=!1,this._toggleEllipsisTools()}_toggleBasemapPicker(){this._showBasemapWidget=!this._showBasemapWidget,this._showTools=!1,this._toggleEllipsisTools()}_toggleLayerListWidget(){this._showLayersListWidget=!this._showLayersListWidget,this._showTools=!1,this._toggleEllipsisTools()}_toggleFloorFilter(){this._showFloorFilter=!this._showFloorFilter,this._showTools=!1,this._toggleEllipsisTools()}_onSelectionToolClick(){this._showSelectionTools=!this._showSelectionTools,this._showTools=!1,this._toggleEllipsisTools()}_toggleSelectionTool(t){t==="rectangle"?(this._lassoSelectionToolActive=!1,this._rectangleSelectionToolActive=!this._rectangleSelectionToolActive):t==="freehandPolygon"&&(this._rectangleSelectionToolActive=!1,this._lassoSelectionToolActive=!this._lassoSelectionToolActive),this._selectionToolElement.value?.toggleSelectionTool(t,this._rectangleSelectionToolActive||this._lassoSelectionToolActive)}_expand(){this._showFullscreen=!this._showFullscreen}_toggleTools(){this._showTools||(this._showSelectionTools=!1,this._showBasemapWidget=!1,this._showLayersListWidget=!1,this._showSearchWidget=!1,this._showLegendWidget=!1,this._showFloorFilter=!1),this._rectangleSelectionToolActive?this._toggleSelectionTool("rectangle"):this._lassoSelectionToolActive&&this._toggleSelectionTool("freehandPolygon"),this._showTools=!this._showTools,this._toggleEllipsisTools(),this._updateTools(this.parentComponentWidth)}_toggleEllipsisTools(){this._showEllipsisTools=!this._showEllipsisTools}};T("map-tools",m);return m},"widgets/Expand","widgets/Home")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as y}from"./6MZ227J7.js";import a from"./JJUJVV7A.js";import{b as g}from"./PZ4L77M5.js";import{a as I}from"./HA5W44KL.js";import{b as N}from"./2CMRI2B3.js";import{H as A,J as b,h as S,i as c,r as u}from"./46DQNAMV.js";export default $arcgis.t(([{D:F,K:v,a:C,b:R,t:_}])=>{var T=S`.width-full{width:100%}calcite-panel{--calcite-panel-background-color: var(--calcite-color-foreground-1);--calcite-panel-footer-space: var(--calcite-spacing-sm)}.border-color{--calcite-block-border-color: transparent}calcite-block{margin:0;--calcite-block-content-space: 0}.tree-padding{padding:0 .2rem}.display-none{display:none}`,f={PUBLICSAFETY:["EMERGENCYMANAGEMENT","FIRESERVICE","LAWENFORCEMENT"],STATEANDLOCALGOVERNMENT:["AGRICULTURE","AIRPORT","ASSESSMENTANDTAXATION","ELECTIONS","EMERGENCYMANAGEMENT","FIRESERVICE","FISHANDWILDLIFE","HEALTHANDHUMANSERVICES","LAWENFORCEMENT","NATURALRESOURCES","PARKS","PLANNINGANDDEVELOPMENT","PUBLICWORKS","TRANSPORTATION"],UTILITIES:["DISTRICTENERGY","ELECTRIC","GAS","SEWER","STORMWATER","WATER"]},O=Object.keys(F).reduce((p,t)=>{let e=t;return p[e]=f[e]??[],p},{}),E=class extends A{constructor(){super(),this.hideIndustryFilter=!1,this.isAIDialogOpen=!1,this.showReset=!1,this._activeFilterSettings={categories:[]},this._isMobile=!1,this._translations=I({name:"solutions-filter-panel",blocking:!0}),this._userFirstName="",this._configContextConsumer=g({context:R,subscribe:!0,callback:t=>{t?.userSession&&!this._userFirstName&&this._loadUserFirstName()}}),this._isMobileContextConsumer=g({context:C,subscribe:!0,callback:t=>this._isMobile=t}),this.applyFilter=u(),this.toggleFilter=u(),this.updateUrlParams=u(),this._handleFilterRemoved=t=>{let e=t.detail;Array.isArray(e)&&(this._activeFilterSettings={...this._activeFilterSettings,categories:[...e]})},this._industryMatchName=t=>{let e=Object.keys(this._translations.industries).find(r=>r.toUpperCase()===t.replaceAll(" ","").toUpperCase());return e&&e in this._translations.industries?this._translations.industries[e]:t},this.listenOn(window,"filterRemoved",this._handleFilterRemoved),this.listenOn(window,"closeAssistant",()=>{this.isAIDialogOpen=!1}),this.listenOn(window,"openAssistant",()=>{this.isAIDialogOpen=!0}),this.listenOn(window,"tabChanged",t=>{t.detail==="all-solutions"?this.updateUrlParams.emit(this._activeFilterSettings):this.updateUrlParams.emit(null)})}static{this.properties={hideIndustryFilter:5,isAIDialogOpen:5,showReset:5,_activeFilterSettings:16,_isMobile:16,_translations:16,_userFirstName:16}}static{this.styles=T}get _telemetry(){return this._configContextConsumer.value?.telemetrySession}changeIndustryFilter(t,e,r,h){if(t!==""||e!==""){let n=[];if(e!==""){let i=F[t];n=[{displayValue:this._industryMatchName(i),type:"industry",value:t,industry:t,domain:""},{displayValue:r,type:"domain",value:e,industry:t,domain:e}]}else n=[{displayValue:r,type:e!==""?"domain":"industry",value:e!==""?e:t,industry:t,domain:e}];this._activeFilterSettings={...this._activeFilterSettings,categories:[...n]},h&&this.applyFilter.emit(n)}else{let n={displayValue:r,type:"industry",value:t,industry:t,domain:e};this._activeFilterSettings={...this._activeFilterSettings,categories:[n]},h&&this.applyFilter.emit(n)}}clearFilters(){this.changeIndustryFilter("","",""),this.applyFilter.emit(null)}async load(){await this._loadUserFirstName(),this._isMobileContextConsumer.value&&(this._isMobile=this._isMobileContextConsumer.value)}render(){return c`<calcite-panel description heading>${this.showReset&&c`<calcite-action appearance=solid icon=reset @click=${()=>{this.clearFilters()}} slot=header-actions-end .text=${this._translations.resetFilters} text-enabled></calcite-action>`||""}<calcite-block-group .label=${this._translations.filters} scale=l>${!this.hideIndustryFilter&&this.renderIndustryBlock()||""}</calcite-block-group><calcite-button id=solutions-assistant-button icon-start=speech-bubbles label="Solutions Assistant" @click=${()=>{this._telemetry?.logEvent({category:v.ASSISTANT,action:"Open"}),this.isAIDialogOpen=!0}} round scale=l slot=footer-start></calcite-button><calcite-tooltip reference-element=solutions-assistant-button placement=right slot=footer-start offset-distance=10 open><span>${this._translations.assistant.welcomeTip}</span></calcite-tooltip><arcgis-solutions-assistant .open=${this.isAIDialogOpen} .userFirstName=${this._userFirstName}></arcgis-solutions-assistant></calcite-panel>`}renderIndustryBlock(){let t=(i,a)=>!this._activeFilterSettings||!this._activeFilterSettings.categories?!1:this._activeFilterSettings.categories.some(s=>s.industry===i&&(s.domain??"")===a),e=i=>!this._activeFilterSettings||!this._activeFilterSettings.categories?!1:this._activeFilterSettings.categories.some(a=>a.industry===i&&(a.domain??"")===""),r=(i,a)=>a.length>0&&(e(i)||this._activeFilterSettings.categories?.some(s=>s.industry===i&&!!s.domain&&a.includes(s.domain))===!0),h=(i,a)=>y(a,s=>s,s=>{let o=Object.keys(this._translations.industriesDomain).find(l=>l.toUpperCase()===s.toUpperCase()),d=o&&o in this._translations.industriesDomain?this._translations.industriesDomain[o]:s,m=t(i,s);return c`<calcite-tree-item .label=${d} @click=${l=>{l.detail!==0&&this.changeIndustryFilter(i,s,d,!0)}} @keydown=${l=>{_(l,()=>{this.changeIndustryFilter(i,s,d,!0)})}} .selected=${m||void 0}>${d}</calcite-tree-item>`}),n=y(Object.entries(O),([i,a])=>i,([i,a])=>{let s=this._industryMatchName(i),o=a,d=e(i),m=r(i,o);return c`<calcite-tree-item .label=${s} @click=${l=>{l.detail!==0&&this.changeIndustryFilter(i,"",s,!0)}} @keydown=${l=>{_(l,()=>{this.changeIndustryFilter(i,"",s,!0)})}} .selected=${d||void 0} .expanded=${m?!0:void 0}>${s}${o.length>0&&c`<calcite-tree slot=children selection-mode=multiple>${h(i,o)}</calcite-tree>`||""}</calcite-tree-item>`});return c`<calcite-block description expanded class="border-color" .heading=${this._translations.industriesHeader} .label=${this._translations.industriesHeader}><calcite-action class=${b(this._isMobile?"":"display-none")} icon=x @click=${this._toggleFilter} slot=content-end text></calcite-action><calcite-tree selection-mode=single-persist class="tree-padding">${n}</calcite-tree></calcite-block>`}_toggleFilter(){this.toggleFilter.emit()}async _loadUserFirstName(){try{let t=await this._configContextConsumer.value?.userSession?.getUser();if(t?.fullName){let e=t.fullName.split(" ")[0];this._userFirstName=e}}catch{}}};N("solutions-filter-panel",E);return E},a)
2
+ import{a as y}from"./6MZ227J7.js";import a from"./HHKKBJCY.js";import{b as g}from"./PZ4L77M5.js";import{a as I}from"./Y3XY5BXI.js";import{b as N}from"./S7XOHDIW.js";import{H as A,J as b,h as S,i as c,r as u}from"./46DQNAMV.js";export default $arcgis.t(([{D:F,K:v,a:C,b:R,t:_}])=>{var T=S`.width-full{width:100%}calcite-panel{--calcite-panel-background-color: var(--calcite-color-foreground-1);--calcite-panel-footer-space: var(--calcite-spacing-sm)}.border-color{--calcite-block-border-color: transparent}calcite-block{margin:0;--calcite-block-content-space: 0}.tree-padding{padding:0 .2rem}.display-none{display:none}`,f={PUBLICSAFETY:["EMERGENCYMANAGEMENT","FIRESERVICE","LAWENFORCEMENT"],STATEANDLOCALGOVERNMENT:["AGRICULTURE","AIRPORT","ASSESSMENTANDTAXATION","ELECTIONS","EMERGENCYMANAGEMENT","FIRESERVICE","FISHANDWILDLIFE","HEALTHANDHUMANSERVICES","LAWENFORCEMENT","NATURALRESOURCES","PARKS","PLANNINGANDDEVELOPMENT","PUBLICWORKS","TRANSPORTATION"],UTILITIES:["DISTRICTENERGY","ELECTRIC","GAS","SEWER","STORMWATER","WATER"]},O=Object.keys(F).reduce((p,t)=>{let e=t;return p[e]=f[e]??[],p},{}),E=class extends A{constructor(){super(),this.hideIndustryFilter=!1,this.isAIDialogOpen=!1,this.showReset=!1,this._activeFilterSettings={categories:[]},this._isMobile=!1,this._translations=I({name:"solutions-filter-panel",blocking:!0}),this._userFirstName="",this._configContextConsumer=g({context:R,subscribe:!0,callback:t=>{t?.userSession&&!this._userFirstName&&this._loadUserFirstName()}}),this._isMobileContextConsumer=g({context:C,subscribe:!0,callback:t=>this._isMobile=t}),this.applyFilter=u(),this.toggleFilter=u(),this.updateUrlParams=u(),this._handleFilterRemoved=t=>{let e=t.detail;Array.isArray(e)&&(this._activeFilterSettings={...this._activeFilterSettings,categories:[...e]})},this._industryMatchName=t=>{let e=Object.keys(this._translations.industries).find(r=>r.toUpperCase()===t.replaceAll(" ","").toUpperCase());return e&&e in this._translations.industries?this._translations.industries[e]:t},this.listenOn(window,"filterRemoved",this._handleFilterRemoved),this.listenOn(window,"closeAssistant",()=>{this.isAIDialogOpen=!1}),this.listenOn(window,"openAssistant",()=>{this.isAIDialogOpen=!0}),this.listenOn(window,"tabChanged",t=>{t.detail==="all-solutions"?this.updateUrlParams.emit(this._activeFilterSettings):this.updateUrlParams.emit(null)})}static{this.properties={hideIndustryFilter:5,isAIDialogOpen:5,showReset:5,_activeFilterSettings:16,_isMobile:16,_translations:16,_userFirstName:16}}static{this.styles=T}get _telemetry(){return this._configContextConsumer.value?.telemetrySession}changeIndustryFilter(t,e,r,h){if(t!==""||e!==""){let n=[];if(e!==""){let i=F[t];n=[{displayValue:this._industryMatchName(i),type:"industry",value:t,industry:t,domain:""},{displayValue:r,type:"domain",value:e,industry:t,domain:e}]}else n=[{displayValue:r,type:e!==""?"domain":"industry",value:e!==""?e:t,industry:t,domain:e}];this._activeFilterSettings={...this._activeFilterSettings,categories:[...n]},h&&this.applyFilter.emit(n)}else{let n={displayValue:r,type:"industry",value:t,industry:t,domain:e};this._activeFilterSettings={...this._activeFilterSettings,categories:[n]},h&&this.applyFilter.emit(n)}}clearFilters(){this.changeIndustryFilter("","",""),this.applyFilter.emit(null)}async load(){await this._loadUserFirstName(),this._isMobileContextConsumer.value&&(this._isMobile=this._isMobileContextConsumer.value)}render(){return c`<calcite-panel description heading>${this.showReset&&c`<calcite-action appearance=solid icon=reset @click=${()=>{this.clearFilters()}} slot=header-actions-end .text=${this._translations.resetFilters} text-enabled></calcite-action>`||""}<calcite-block-group .label=${this._translations.filters} scale=l>${!this.hideIndustryFilter&&this.renderIndustryBlock()||""}</calcite-block-group><calcite-button id=solutions-assistant-button icon-start=speech-bubbles label="Solutions Assistant" @click=${()=>{this._telemetry?.logEvent({category:v.ASSISTANT,action:"Open"}),this.isAIDialogOpen=!0}} round scale=l slot=footer-start></calcite-button><calcite-tooltip reference-element=solutions-assistant-button placement=right slot=footer-start offset-distance=10 open><span>${this._translations.assistant.welcomeTip}</span></calcite-tooltip><arcgis-solutions-assistant .open=${this.isAIDialogOpen} .userFirstName=${this._userFirstName}></arcgis-solutions-assistant></calcite-panel>`}renderIndustryBlock(){let t=(i,a)=>!this._activeFilterSettings||!this._activeFilterSettings.categories?!1:this._activeFilterSettings.categories.some(s=>s.industry===i&&(s.domain??"")===a),e=i=>!this._activeFilterSettings||!this._activeFilterSettings.categories?!1:this._activeFilterSettings.categories.some(a=>a.industry===i&&(a.domain??"")===""),r=(i,a)=>a.length>0&&(e(i)||this._activeFilterSettings.categories?.some(s=>s.industry===i&&!!s.domain&&a.includes(s.domain))===!0),h=(i,a)=>y(a,s=>s,s=>{let o=Object.keys(this._translations.industriesDomain).find(l=>l.toUpperCase()===s.toUpperCase()),d=o&&o in this._translations.industriesDomain?this._translations.industriesDomain[o]:s,m=t(i,s);return c`<calcite-tree-item .label=${d} @click=${l=>{l.detail!==0&&this.changeIndustryFilter(i,s,d,!0)}} @keydown=${l=>{_(l,()=>{this.changeIndustryFilter(i,s,d,!0)})}} .selected=${m||void 0}>${d}</calcite-tree-item>`}),n=y(Object.entries(O),([i,a])=>i,([i,a])=>{let s=this._industryMatchName(i),o=a,d=e(i),m=r(i,o);return c`<calcite-tree-item .label=${s} @click=${l=>{l.detail!==0&&this.changeIndustryFilter(i,"",s,!0)}} @keydown=${l=>{_(l,()=>{this.changeIndustryFilter(i,"",s,!0)})}} .selected=${d||void 0} .expanded=${m?!0:void 0}>${s}${o.length>0&&c`<calcite-tree slot=children selection-mode=multiple>${h(i,o)}</calcite-tree>`||""}</calcite-tree-item>`});return c`<calcite-block description expanded class="border-color" .heading=${this._translations.industriesHeader} .label=${this._translations.industriesHeader}><calcite-action class=${b(this._isMobile?"":"display-none")} icon=x @click=${this._toggleFilter} slot=content-end text></calcite-action><calcite-tree selection-mode=single-persist class="tree-padding">${n}</calcite-tree></calcite-block>`}_toggleFilter(){this.toggleFilter.emit()}async _loadUserFirstName(){try{let t=await this._configContextConsumer.value?.userSession?.getUser();if(t?.fullName){let e=t.fullName.split(" ")[0];this._userFirstName=e}}catch{}}};N("solutions-filter-panel",E);return E},a)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as D}from"./LLYTIOG4.js";import{b as E}from"./PZ4L77M5.js";import c from"./KDIUYXBA.js";import a from"./UUYUTETH.js";import{a as L}from"./HA5W44KL.js";import{b as k}from"./2CMRI2B3.js";import{F as S,G as u,H as v,J as I,h as b,i as h,r as _,u as g}from"./46DQNAMV.js";export default $arcgis.t(([V,A,{d:x},{c:m,h:G,i:$}])=>{var O=b`@layer{:host{display:block}.div-not-visible{display:none!important}.border{outline:1px solid var(--calcite-color-border-input)}.esri-sketch{display:flex;flex-flow:column wrap}.esri-widget{box-sizing:border-box;color:#323232;font-size:14px;font-family:Avenir Next,Helvetica Neue,Helvetica,Arial,sans-serif;line-height:1.3em;background-color:var(--calcite-color-foreground-1)}.esri-sketch__panel{align-items:center;display:flex;flex-flow:row nowrap;padding:0}.esri-sketch__tool-section{border-right:1px solid rgba(110,110,110,.3)}.esri-sketch__section{align-items:center;display:flex;flex-flow:row nowrap;padding:0 7px;margin:6px 0;border-right:1px solid rgba(110,110,110,.3)}.display-flex{display:flex}.font-bold{font-weight:700}.width-full{width:100%}.label-margin-0{--calcite-label-margin-bottom: 0}.padding-start-1-2{padding-inline-start:.5rem}.font-weight-500{font-weight:500}.word-wrap-anywhere{word-wrap:anywhere}.tooltip-message{padding:5px 8px;font-weight:var(--calcite-font-weight-normal);color:var(--calcite-color-text-2);max-width:400px}}`,y=class extends v{constructor(){super(),this.enabledLayerIds=[],this.enableSearchDistance=!0,this.enableSearchDistanceOnLoad=!1,this.searchDistanceEnabled=!1,this.selectionSets=[],this.bufferColor=[227,139,79,.8],this.bufferOutlineColor=[255,255,255],this.geometries=[],this.drawnGraphicsArr=[],this._translations=L({name:"refine-selection",blocking:!0}),this._selectionMode="ADD",this._addEnabled=!0,this._drawTools=S(),this._enabledLayerIds=[],this._layerPicker=S(),this._featuresCollection={},this._pnContextConsumer=E({context:D,subscribe:!0}),this._bufferTools=S(),this._undoGraphicsArr=[],this.selectionLoadingChange=_(),this.selectionSetsChanged=_(),this.listenOn(window,"distanceChanged",this.distanceChanged),this.listenOn(window,"unitChanged",this.unitChanged)}static{this.properties={addresseeLayer:0,enabledLayerIds:0,enableSearchDistance:5,enableSearchDistanceOnLoad:5,mapView:0,searchDistanceEnabled:5,selectionSets:0,sketchLineSymbol:0,sketchPointSymbol:0,sketchPolygonSymbol:0,defaultBufferUnit:1,bufferColor:1,bufferOutlineColor:1,defaultBufferDistance:9,geometries:0,drawnGraphicsArr:0,_translations:16,_selectionMode:16,_refineLayer:16}}static{this.styles=O}static{this.shadowRootOptions=g}willUpdate(e){e.has("defaultBufferUnit")&&this.hasUpdated&&this._refineSelectionSet&&(this._refineSelectionSet.unit=this.defaultBufferUnit),e.has("defaultBufferDistance")&&this.hasUpdated&&this._refineSelectionSet&&(this._refineSelectionSet.distance=this.defaultBufferDistance)}async distanceChanged(e){e.detail.newValue!==e.detail.oldValue&&this._refineSelectionSet&&(this._refineSelectionSet.distance=e.detail.newValue)}async unitChanged(e){e.detail.newValue!==e.detail.oldValue&&this._refineSelectionSet&&(this._refineSelectionSet.unit=e.detail.newValue)}async load(){this._enabledLayerIds=this._getEnabledLayerIds(),await this._setRefineSet(this._enabledLayerIds[0]),this._undoGraphicsArr=this._refineSelectionSet?.undoGraphicsArr}async loaded(){await this._init()}render(){let e=this._enabledLayerIds.length>1?"display-block":"display-none";return h`<div class=${`${e} padding-top-sides-1`}><div class="display-flex"><calcite-label class="font-bold width-full label-margin-0"><div class="display-flex">${this._translations.inputLayer}<calcite-icon class="padding-start-1-2 icon" .flipRtl=${this._translations._lang?.toLowerCase()!=="he"} icon=question id=refine-input-layer scale=s></calcite-icon></div><map-layer-picker .enabledLayerIds=${this._enabledLayerIds} .mapView=${this.mapView} @layerSelectionChange=${t=>{this._layerSelectionChange(t)}} .selectedIds=${this._refineLayer?[this._refineLayer.layer.id]:[]} ${u(this._layerPicker)}></map-layer-picker></calcite-label><calcite-popover closable label overlay-positioning=fixed reference-element=refine-input-layer><span class="tooltip-message">${this._translations.inputLayerTip}</span></calcite-popover></div></div><div class="padding-1"><div class="padding-bottom-1"><calcite-segmented-control class="w-100" width=full><calcite-segmented-control-item .checked=${this._addEnabled} class="w-50 word-wrap-anywhere" @click=${()=>this._setSelectionMode("ADD")} value=ADD><span class="font-weight-500">${this._translations.add}</span></calcite-segmented-control-item><calcite-segmented-control-item .checked=${!this._addEnabled} class="w-50 word-wrap-anywhere" @click=${()=>this._setSelectionMode("REMOVE")} value=REMOVE><span class="font-weight-500">${this._translations.remove}</span></calcite-segmented-control-item></calcite-segmented-control></div><div><map-draw-tools active draw-mode=REFINE .mapView=${this.mapView} @drawRedo=${()=>this._redo()} @drawUndo=${()=>this._undo()} @sketchGraphicsChange=${this._sketchGraphicsChanged} .pointSymbol=${this.sketchPointSymbol} .polygonSymbol=${this.sketchPolygonSymbol} .polylineSymbol=${this.sketchLineSymbol} .redoEnabled=${this._refineSelectionSet?.redoStack&&this._refineSelectionSet.redoStack.length>0} .undoEnabled=${this._refineSelectionSet?.undoStack&&this._refineSelectionSet.undoStack.length>0} ${u(this._drawTools)}></map-draw-tools></div>${this.enableSearchDistance?this._getBufferOptions():void 0}<br>${h`<calcite-list class="list-border" label>${this._getRefineSelectionSetList()}</calcite-list>`}</div>`}async _init(){this._initGraphicsLayer()}_initGraphicsLayer(){let e=this._translations.bufferLayer;if(this.mapView){let t=this.mapView.map.layers.findIndex(i=>i.title===e);if(t>-1)this._bufferGraphicsLayer=this.mapView.map.layers.getItemAt(t);else if(this._bufferGraphicsLayer=new A({title:e,listMode:"hide"}),this._bufferGraphicsLayer){let i=this.mapView.map.layers.findIndex(s=>s.title===this._translations.sketchLayer);i>-1?this.mapView.map.layers.add(this._bufferGraphicsLayer,i):this.mapView.map.layers.add(this._bufferGraphicsLayer)}}}_layerSelectionChange(e){let t=e.detail[0];this._setRefineSet(t)}_setSelectionMode(e){this._selectionMode=e}async _sketchGraphicsChanged(e){let t=e.detail?.graphics[0],i=t.geometry;this.geometries=[i];let s=await this._selectFeatures(i);if(this._sketchGraphic=t,this._refineSelectionSet?.distance===0&&s.length>0){let a={drawnGraphic:t,bufferGraphic:void 0};this.drawnGraphicsArr.push(a)}}_getEnabledLayerIds(){return this.selectionSets.reduce((e,t)=>{let i=t?.layerView?.layer.id;return i&&e.indexOf(i)<0?e.push(i):t.workflowType==="REFINE"&&Object.keys(t.refineInfos).forEach(s=>{e.indexOf(s)<0&&e.push(s)}),e},[])}async _setRefineSet(e){this.selectionSets.some(t=>t.workflowType==="REFINE"?(this._refineSelectionSet=t,Object.keys(t.refineInfos).indexOf(e)>-1):!1)||await this._initRefineSet(e,this._refineSelectionSet),this._refineSelectionSet&&(this._refineLayer=this._refineSelectionSet.refineInfos[e].layerView)}async _initRefineSet(e,t){let i={};i[e]={addIds:[],removeIds:[],layerView:this.mapView&&await m(this.mapView,e)},t?t.refineInfos={...t.refineInfos,...i}:(this._refineSelectionSet={id:Date.now(),searchResult:void 0,buffer:void 0,distance:this.defaultBufferDistance||0,download:!0,unit:this.defaultBufferUnit||"feet",label:"Refine",selectedIds:[],layerView:this.mapView&&await m(this.mapView,e),geometries:[],graphics:[],selectLayers:[],workflowType:"REFINE",searchDistanceEnabled:!1,useLayerFeaturesEnabled:!1,refineInfos:i,redoStack:[],undoStack:[],sketchGraphic:void 0,undoGraphicsArr:[]},this.selectionSets.push(this._refineSelectionSet))}_undo(){if(this._refineSelectionSet){let e=this._refineSelectionSet.undoStack&&this._refineSelectionSet.undoStack.pop();if(e){if(this.drawnGraphicsArr.length>0){let t=this.drawnGraphicsArr.pop();t&&this._refineSelectionSet.undoGraphicsArr?.push(t),this._undoGraphicsArr.push(t)}this._refineSelectionSet.redoStack&&this._updateIds(e.ids,e.mode==="ADD"?"REMOVE":"ADD",this._refineSelectionSet.redoStack,e.layerView)}}}_redo(){if(this._refineSelectionSet){let e=this._refineSelectionSet.redoStack&&this._refineSelectionSet.redoStack.pop();if(e){if(this._undoGraphicsArr.length>0){let t=this._undoGraphicsArr.pop();this._refineSelectionSet.undoGraphicsArr?.pop(),t&&this.drawnGraphicsArr.push(t)}this._refineSelectionSet.undoStack&&this._updateIds(e.ids,e.mode==="ADD"?"REMOVE":"ADD",this._refineSelectionSet.undoStack,e.layerView)}}}_getBufferOptions(){this.enableSearchDistanceOnLoad&&this._refineSelectionSet&&(this._refineSelectionSet.searchDistanceEnabled=!0,this.searchDistanceEnabled=!0,this.enableSearchDistanceOnLoad=!1);let e=this._refineSelectionSet?.searchDistanceEnabled?"search-distance":"div-not-visible";return h`<div><div class="padding-top-1 display-flex"><calcite-label class="label-margin-0 w-100" layout=inline-space-between><div class="tooltip-container">${this._translations.searchDistance}<calcite-icon class="padding-start-1-2 icon" .flipRtl=${this._translations._lang?.toLowerCase()!=="he"} icon=question id=search-distance-icon scale=s></calcite-icon></div></calcite-label><calcite-popover closable label overlay-positioning=fixed reference-element=search-distance-icon><span class="tooltip-message">${this._translations.useSearchDistanceTootip}</span></calcite-popover><calcite-switch .checked=${this._refineSelectionSet?.searchDistanceEnabled} @calciteSwitchChange=${()=>{this.searchDistanceEnabled=!this.searchDistanceEnabled,this._refineSelectionSet&&(this._refineSelectionSet.searchDistanceEnabled=this.searchDistanceEnabled)}}></calcite-switch></div><div class=${I(e)}><buffer-tools .disabled=${!this.searchDistanceEnabled} .distance=${this._refineSelectionSet?.distance} .geometries=${this.geometries} @bufferComplete=${t=>{this._bufferComplete(t)}} .unit=${this._refineSelectionSet?.unit} ${u(this._bufferTools)}></buffer-tools></div></div>`}async _bufferComplete(e){if(this._bufferGeometry=Array.isArray(e.detail)?e.detail[0]:e.detail,this._bufferGeometry){let t={type:"simple-fill",color:this.bufferColor,outline:{color:this.bufferOutlineColor,width:1}},i=new V({geometry:this._bufferGeometry,symbol:t});if(this._bufferGraphicsLayer&&i&&this.mapView&&(this._bufferGraphicsLayer.removeAll(),this._bufferGraphicsLayer.add(i),(await this._selectFeatures(this._bufferGeometry)).length>0)){let s={drawnGraphic:this._sketchGraphic,bufferGraphic:i};this.drawnGraphicsArr.push(s)}}else this._bufferGraphicsLayer&&this._bufferGraphicsLayer.removeAll()}_getRefineSelectionSetList(){let e=this._getTotal(this.selectionSets),t;this.selectionSets.some(o=>o.workflowType==="REFINE"?(t=o,!0):!1);let i=0,s=0;t?.refineInfos&&Object.keys(t.refineInfos).forEach(o=>{i+=t.refineInfos[o].addIds.length,s+=t.refineInfos[o].removeIds.length});let a=this._translations.featuresAdded,f=this._translations.featuresRemoved,c=this._translations.totalSelected;return[h`<calcite-list-item .label=${a.replace("{{n}}",i.toString())}></calcite-list-item>`,h`<calcite-list-item .label=${f.replace("{{n}}",s.toString())}></calcite-list-item>`,h`<calcite-list-item .label=${c.replace("{{n}}",e.toString())}></calcite-list-item>`]}_getTotal(e){let t=$(e);return Object.keys(t).reduce((i,s)=>{let a=t[s];return i+=a.ids.length,i},0)}async _selectFeatures(e){this.selectionLoadingChange.emit(!0);let t=[];if(this._refineLayer){this._featuresCollection[this._refineLayer?.layer.id]=[];let i=await x(0,this._refineLayer?.layer,e,this._featuresCollection);this.selectionLoadingChange.emit(!1);let s=[];Object.keys(i).forEach(a=>{a===this._refineLayer?.layer.id&&(s=s.concat(i[a]))}),t=Array.isArray(s)?s.map(a=>a.attributes[a?.layer?.objectIdField]):[],this._refineSelectionSet?.undoStack&&await this._updateIds(t,this._selectionMode,this._refineSelectionSet.undoStack,this._refineLayer),this._bufferGraphicsLayer&&this._refineSelectionSet&&this._refineSelectionSet.distance>0&&(await new Promise(a=>setTimeout(a,1e3)),this._bufferGraphicsLayer.removeAll()),this.geometries=[],this._drawTools.value&&this._drawTools.value.clear()}return t}async _highlightFeatures(){let e=this._pnContextConsumer.value;e.removeHandles(),e.highlightHandles=await G(this.selectionSets)}async _updateIds(e,t,i,s){let a=!1,f=this._refineSelectionSet?.refineInfos,c=s.layer.id,o={};o[c]={addIds:[],removeIds:[],layerView:s};let n=f&&Object.keys(f).indexOf(c)>-1?f[c]:o[c];if(t==="ADD")n.addIds=[...new Set([...e,...n.addIds])],n.addIds.length>0&&i.push({ids:e,mode:t,layerView:s}),n.removeIds.length>0&&(n.removeIds=n.removeIds.filter(p=>e.indexOf(p)<0));else{let p=this.selectionSets.reduce((l,r)=>(e.forEach(d=>{r.workflowType!=="REFINE"?r.selectedIds.indexOf(d)>-1&&l.push(d):Object.keys(r.refineInfos).some(C=>{let w=r.refineInfos[C];return w.layerView.layer.id===s.layer.id&&w.addIds.indexOf(d)>-1?(l.push(d),!0):!1})}),l),[]);n.removeIds=[...new Set([...p,...n.removeIds])],n.addIds=n.addIds.filter(l=>p.indexOf(l)<0),n.removeIds.length>0&&i.push({ids:p,mode:t,layerView:s}),this.selectionSets=this.selectionSets.reduce((l,r)=>(r.workflowType!=="REFINE"&&r.layerView.layer.id===s.layer.id?(r.selectedIds=r.selectedIds.filter(d=>n.removeIds.indexOf(d)<0),r.selectedIds.length>0?l.push(r):a=!0):l.push(r),l),[])}this._refineSelectionSet&&(this._refineSelectionSet.refineInfos[c]=n),this.selectionSets=[...this.selectionSets],a&&this.selectionSetsChanged.emit(this.selectionSets),await this._highlightFeatures()}};k("refine-selection",y);return y},"Graphic","layers/GraphicsLayer",a,c)
2
+ import{a as D}from"./LLYTIOG4.js";import{b as E}from"./PZ4L77M5.js";import c from"./KDIUYXBA.js";import a from"./UUYUTETH.js";import{a as L}from"./Y3XY5BXI.js";import{b as k}from"./S7XOHDIW.js";import{F as S,G as u,H as v,J as I,h as b,i as h,r as _,u as g}from"./46DQNAMV.js";export default $arcgis.t(([V,A,{d:x},{c:m,h:G,i:$}])=>{var O=b`@layer{:host{display:block}.div-not-visible{display:none!important}.border{outline:1px solid var(--calcite-color-border-input)}.esri-sketch{display:flex;flex-flow:column wrap}.esri-widget{box-sizing:border-box;color:#323232;font-size:14px;font-family:Avenir Next,Helvetica Neue,Helvetica,Arial,sans-serif;line-height:1.3em;background-color:var(--calcite-color-foreground-1)}.esri-sketch__panel{align-items:center;display:flex;flex-flow:row nowrap;padding:0}.esri-sketch__tool-section{border-right:1px solid rgba(110,110,110,.3)}.esri-sketch__section{align-items:center;display:flex;flex-flow:row nowrap;padding:0 7px;margin:6px 0;border-right:1px solid rgba(110,110,110,.3)}.display-flex{display:flex}.font-bold{font-weight:700}.width-full{width:100%}.label-margin-0{--calcite-label-margin-bottom: 0}.padding-start-1-2{padding-inline-start:.5rem}.font-weight-500{font-weight:500}.word-wrap-anywhere{word-wrap:anywhere}.tooltip-message{padding:5px 8px;font-weight:var(--calcite-font-weight-normal);color:var(--calcite-color-text-2);max-width:400px}}`,y=class extends v{constructor(){super(),this.enabledLayerIds=[],this.enableSearchDistance=!0,this.enableSearchDistanceOnLoad=!1,this.searchDistanceEnabled=!1,this.selectionSets=[],this.bufferColor=[227,139,79,.8],this.bufferOutlineColor=[255,255,255],this.geometries=[],this.drawnGraphicsArr=[],this._translations=L({name:"refine-selection",blocking:!0}),this._selectionMode="ADD",this._addEnabled=!0,this._drawTools=S(),this._enabledLayerIds=[],this._layerPicker=S(),this._featuresCollection={},this._pnContextConsumer=E({context:D,subscribe:!0}),this._bufferTools=S(),this._undoGraphicsArr=[],this.selectionLoadingChange=_(),this.selectionSetsChanged=_(),this.listenOn(window,"distanceChanged",this.distanceChanged),this.listenOn(window,"unitChanged",this.unitChanged)}static{this.properties={addresseeLayer:0,enabledLayerIds:0,enableSearchDistance:5,enableSearchDistanceOnLoad:5,mapView:0,searchDistanceEnabled:5,selectionSets:0,sketchLineSymbol:0,sketchPointSymbol:0,sketchPolygonSymbol:0,defaultBufferUnit:1,bufferColor:1,bufferOutlineColor:1,defaultBufferDistance:9,geometries:0,drawnGraphicsArr:0,_translations:16,_selectionMode:16,_refineLayer:16}}static{this.styles=O}static{this.shadowRootOptions=g}willUpdate(e){e.has("defaultBufferUnit")&&this.hasUpdated&&this._refineSelectionSet&&(this._refineSelectionSet.unit=this.defaultBufferUnit),e.has("defaultBufferDistance")&&this.hasUpdated&&this._refineSelectionSet&&(this._refineSelectionSet.distance=this.defaultBufferDistance)}async distanceChanged(e){e.detail.newValue!==e.detail.oldValue&&this._refineSelectionSet&&(this._refineSelectionSet.distance=e.detail.newValue)}async unitChanged(e){e.detail.newValue!==e.detail.oldValue&&this._refineSelectionSet&&(this._refineSelectionSet.unit=e.detail.newValue)}async load(){this._enabledLayerIds=this._getEnabledLayerIds(),await this._setRefineSet(this._enabledLayerIds[0]),this._undoGraphicsArr=this._refineSelectionSet?.undoGraphicsArr}async loaded(){await this._init()}render(){let e=this._enabledLayerIds.length>1?"display-block":"display-none";return h`<div class=${`${e} padding-top-sides-1`}><div class="display-flex"><calcite-label class="font-bold width-full label-margin-0"><div class="display-flex">${this._translations.inputLayer}<calcite-icon class="padding-start-1-2 icon" .flipRtl=${this._translations._lang?.toLowerCase()!=="he"} icon=question id=refine-input-layer scale=s></calcite-icon></div><map-layer-picker .enabledLayerIds=${this._enabledLayerIds} .mapView=${this.mapView} @layerSelectionChange=${t=>{this._layerSelectionChange(t)}} .selectedIds=${this._refineLayer?[this._refineLayer.layer.id]:[]} ${u(this._layerPicker)}></map-layer-picker></calcite-label><calcite-popover closable label overlay-positioning=fixed reference-element=refine-input-layer><span class="tooltip-message">${this._translations.inputLayerTip}</span></calcite-popover></div></div><div class="padding-1"><div class="padding-bottom-1"><calcite-segmented-control class="w-100" width=full><calcite-segmented-control-item .checked=${this._addEnabled} class="w-50 word-wrap-anywhere" @click=${()=>this._setSelectionMode("ADD")} value=ADD><span class="font-weight-500">${this._translations.add}</span></calcite-segmented-control-item><calcite-segmented-control-item .checked=${!this._addEnabled} class="w-50 word-wrap-anywhere" @click=${()=>this._setSelectionMode("REMOVE")} value=REMOVE><span class="font-weight-500">${this._translations.remove}</span></calcite-segmented-control-item></calcite-segmented-control></div><div><map-draw-tools active draw-mode=REFINE .mapView=${this.mapView} @drawRedo=${()=>this._redo()} @drawUndo=${()=>this._undo()} @sketchGraphicsChange=${this._sketchGraphicsChanged} .pointSymbol=${this.sketchPointSymbol} .polygonSymbol=${this.sketchPolygonSymbol} .polylineSymbol=${this.sketchLineSymbol} .redoEnabled=${this._refineSelectionSet?.redoStack&&this._refineSelectionSet.redoStack.length>0} .undoEnabled=${this._refineSelectionSet?.undoStack&&this._refineSelectionSet.undoStack.length>0} ${u(this._drawTools)}></map-draw-tools></div>${this.enableSearchDistance?this._getBufferOptions():void 0}<br>${h`<calcite-list class="list-border" label>${this._getRefineSelectionSetList()}</calcite-list>`}</div>`}async _init(){this._initGraphicsLayer()}_initGraphicsLayer(){let e=this._translations.bufferLayer;if(this.mapView){let t=this.mapView.map.layers.findIndex(i=>i.title===e);if(t>-1)this._bufferGraphicsLayer=this.mapView.map.layers.getItemAt(t);else if(this._bufferGraphicsLayer=new A({title:e,listMode:"hide"}),this._bufferGraphicsLayer){let i=this.mapView.map.layers.findIndex(s=>s.title===this._translations.sketchLayer);i>-1?this.mapView.map.layers.add(this._bufferGraphicsLayer,i):this.mapView.map.layers.add(this._bufferGraphicsLayer)}}}_layerSelectionChange(e){let t=e.detail[0];this._setRefineSet(t)}_setSelectionMode(e){this._selectionMode=e}async _sketchGraphicsChanged(e){let t=e.detail?.graphics[0],i=t.geometry;this.geometries=[i];let s=await this._selectFeatures(i);if(this._sketchGraphic=t,this._refineSelectionSet?.distance===0&&s.length>0){let a={drawnGraphic:t,bufferGraphic:void 0};this.drawnGraphicsArr.push(a)}}_getEnabledLayerIds(){return this.selectionSets.reduce((e,t)=>{let i=t?.layerView?.layer.id;return i&&e.indexOf(i)<0?e.push(i):t.workflowType==="REFINE"&&Object.keys(t.refineInfos).forEach(s=>{e.indexOf(s)<0&&e.push(s)}),e},[])}async _setRefineSet(e){this.selectionSets.some(t=>t.workflowType==="REFINE"?(this._refineSelectionSet=t,Object.keys(t.refineInfos).indexOf(e)>-1):!1)||await this._initRefineSet(e,this._refineSelectionSet),this._refineSelectionSet&&(this._refineLayer=this._refineSelectionSet.refineInfos[e].layerView)}async _initRefineSet(e,t){let i={};i[e]={addIds:[],removeIds:[],layerView:this.mapView&&await m(this.mapView,e)},t?t.refineInfos={...t.refineInfos,...i}:(this._refineSelectionSet={id:Date.now(),searchResult:void 0,buffer:void 0,distance:this.defaultBufferDistance||0,download:!0,unit:this.defaultBufferUnit||"feet",label:"Refine",selectedIds:[],layerView:this.mapView&&await m(this.mapView,e),geometries:[],graphics:[],selectLayers:[],workflowType:"REFINE",searchDistanceEnabled:!1,useLayerFeaturesEnabled:!1,refineInfos:i,redoStack:[],undoStack:[],sketchGraphic:void 0,undoGraphicsArr:[]},this.selectionSets.push(this._refineSelectionSet))}_undo(){if(this._refineSelectionSet){let e=this._refineSelectionSet.undoStack&&this._refineSelectionSet.undoStack.pop();if(e){if(this.drawnGraphicsArr.length>0){let t=this.drawnGraphicsArr.pop();t&&this._refineSelectionSet.undoGraphicsArr?.push(t),this._undoGraphicsArr.push(t)}this._refineSelectionSet.redoStack&&this._updateIds(e.ids,e.mode==="ADD"?"REMOVE":"ADD",this._refineSelectionSet.redoStack,e.layerView)}}}_redo(){if(this._refineSelectionSet){let e=this._refineSelectionSet.redoStack&&this._refineSelectionSet.redoStack.pop();if(e){if(this._undoGraphicsArr.length>0){let t=this._undoGraphicsArr.pop();this._refineSelectionSet.undoGraphicsArr?.pop(),t&&this.drawnGraphicsArr.push(t)}this._refineSelectionSet.undoStack&&this._updateIds(e.ids,e.mode==="ADD"?"REMOVE":"ADD",this._refineSelectionSet.undoStack,e.layerView)}}}_getBufferOptions(){this.enableSearchDistanceOnLoad&&this._refineSelectionSet&&(this._refineSelectionSet.searchDistanceEnabled=!0,this.searchDistanceEnabled=!0,this.enableSearchDistanceOnLoad=!1);let e=this._refineSelectionSet?.searchDistanceEnabled?"search-distance":"div-not-visible";return h`<div><div class="padding-top-1 display-flex"><calcite-label class="label-margin-0 w-100" layout=inline-space-between><div class="tooltip-container">${this._translations.searchDistance}<calcite-icon class="padding-start-1-2 icon" .flipRtl=${this._translations._lang?.toLowerCase()!=="he"} icon=question id=search-distance-icon scale=s></calcite-icon></div></calcite-label><calcite-popover closable label overlay-positioning=fixed reference-element=search-distance-icon><span class="tooltip-message">${this._translations.useSearchDistanceTootip}</span></calcite-popover><calcite-switch .checked=${this._refineSelectionSet?.searchDistanceEnabled} @calciteSwitchChange=${()=>{this.searchDistanceEnabled=!this.searchDistanceEnabled,this._refineSelectionSet&&(this._refineSelectionSet.searchDistanceEnabled=this.searchDistanceEnabled)}}></calcite-switch></div><div class=${I(e)}><buffer-tools .disabled=${!this.searchDistanceEnabled} .distance=${this._refineSelectionSet?.distance} .geometries=${this.geometries} @bufferComplete=${t=>{this._bufferComplete(t)}} .unit=${this._refineSelectionSet?.unit} ${u(this._bufferTools)}></buffer-tools></div></div>`}async _bufferComplete(e){if(this._bufferGeometry=Array.isArray(e.detail)?e.detail[0]:e.detail,this._bufferGeometry){let t={type:"simple-fill",color:this.bufferColor,outline:{color:this.bufferOutlineColor,width:1}},i=new V({geometry:this._bufferGeometry,symbol:t});if(this._bufferGraphicsLayer&&i&&this.mapView&&(this._bufferGraphicsLayer.removeAll(),this._bufferGraphicsLayer.add(i),(await this._selectFeatures(this._bufferGeometry)).length>0)){let s={drawnGraphic:this._sketchGraphic,bufferGraphic:i};this.drawnGraphicsArr.push(s)}}else this._bufferGraphicsLayer&&this._bufferGraphicsLayer.removeAll()}_getRefineSelectionSetList(){let e=this._getTotal(this.selectionSets),t;this.selectionSets.some(o=>o.workflowType==="REFINE"?(t=o,!0):!1);let i=0,s=0;t?.refineInfos&&Object.keys(t.refineInfos).forEach(o=>{i+=t.refineInfos[o].addIds.length,s+=t.refineInfos[o].removeIds.length});let a=this._translations.featuresAdded,f=this._translations.featuresRemoved,c=this._translations.totalSelected;return[h`<calcite-list-item .label=${a.replace("{{n}}",i.toString())}></calcite-list-item>`,h`<calcite-list-item .label=${f.replace("{{n}}",s.toString())}></calcite-list-item>`,h`<calcite-list-item .label=${c.replace("{{n}}",e.toString())}></calcite-list-item>`]}_getTotal(e){let t=$(e);return Object.keys(t).reduce((i,s)=>{let a=t[s];return i+=a.ids.length,i},0)}async _selectFeatures(e){this.selectionLoadingChange.emit(!0);let t=[];if(this._refineLayer){this._featuresCollection[this._refineLayer?.layer.id]=[];let i=await x(0,this._refineLayer?.layer,e,this._featuresCollection);this.selectionLoadingChange.emit(!1);let s=[];Object.keys(i).forEach(a=>{a===this._refineLayer?.layer.id&&(s=s.concat(i[a]))}),t=Array.isArray(s)?s.map(a=>a.attributes[a?.layer?.objectIdField]):[],this._refineSelectionSet?.undoStack&&await this._updateIds(t,this._selectionMode,this._refineSelectionSet.undoStack,this._refineLayer),this._bufferGraphicsLayer&&this._refineSelectionSet&&this._refineSelectionSet.distance>0&&(await new Promise(a=>setTimeout(a,1e3)),this._bufferGraphicsLayer.removeAll()),this.geometries=[],this._drawTools.value&&this._drawTools.value.clear()}return t}async _highlightFeatures(){let e=this._pnContextConsumer.value;e.removeHandles(),e.highlightHandles=await G(this.selectionSets)}async _updateIds(e,t,i,s){let a=!1,f=this._refineSelectionSet?.refineInfos,c=s.layer.id,o={};o[c]={addIds:[],removeIds:[],layerView:s};let n=f&&Object.keys(f).indexOf(c)>-1?f[c]:o[c];if(t==="ADD")n.addIds=[...new Set([...e,...n.addIds])],n.addIds.length>0&&i.push({ids:e,mode:t,layerView:s}),n.removeIds.length>0&&(n.removeIds=n.removeIds.filter(p=>e.indexOf(p)<0));else{let p=this.selectionSets.reduce((l,r)=>(e.forEach(d=>{r.workflowType!=="REFINE"?r.selectedIds.indexOf(d)>-1&&l.push(d):Object.keys(r.refineInfos).some(C=>{let w=r.refineInfos[C];return w.layerView.layer.id===s.layer.id&&w.addIds.indexOf(d)>-1?(l.push(d),!0):!1})}),l),[]);n.removeIds=[...new Set([...p,...n.removeIds])],n.addIds=n.addIds.filter(l=>p.indexOf(l)<0),n.removeIds.length>0&&i.push({ids:p,mode:t,layerView:s}),this.selectionSets=this.selectionSets.reduce((l,r)=>(r.workflowType!=="REFINE"&&r.layerView.layer.id===s.layer.id?(r.selectedIds=r.selectedIds.filter(d=>n.removeIds.indexOf(d)<0),r.selectedIds.length>0?l.push(r):a=!0):l.push(r),l),[])}this._refineSelectionSet&&(this._refineSelectionSet.refineInfos[c]=n),this.selectionSets=[...this.selectionSets],a&&this.selectionSetsChanged.emit(this.selectionSets),await this._highlightFeatures()}};k("refine-selection",y);return y},"Graphic","layers/GraphicsLayer",a,c)
@@ -0,0 +1,2 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
+ import{b as y}from"./PZ4L77M5.js";import{ka as C,nb as R,nc as M,oa as x,qa as N,sa as $}from"./DD3JC2L3.js";import{a as I}from"./Y3XY5BXI.js";import{u as k}from"./2IHQU2FX.js";import{b as O}from"./S7XOHDIW.js";import{F as b,G as w,H as S,J as A,L as h,h as T,i as r,j as _,r as D}from"./46DQNAMV.js";export default $arcgis.t(([])=>{var V="isMobile";var K="config",H=T`calcite-card{height:100%;padding-bottom:var(--calcite-spacing-base)}@media(max-width:400px){calcite-card{width:100%}}calcite-card:hover img{-webkit-filter:brightness(30%);filter:brightness(30%);-webkit-transition:all .1s ease;-moz-transition:all .1s ease;-o-transition:all .1s ease;-ms-transition:all .1s ease;transition:all .1s ease}calcite-card:hover .hover-text{opacity:1;color:#fff}calcite-card:hover{outline:var(--calcite-spacing-base) solid var(--calcite-color-brand);box-sizing:content-box;cursor:pointer}.hover-text{transition:.1s ease;opacity:0;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);-ms-transform:translate(-50%,-50%);text-align:center;display:flex;flex-direction:row;align-items:center;height:100%;font-size:var(--calcite-spacing-xl)}.card-image-wrap{flex:0 0 auto}.card-image-wrap{width:100%;position:relative;margin-bottom:0;-webkit-box-flex:0 0 auto;-ms-flex:0 0 auto;flex:0 0 auto}.card-image{width:100%;display:block}video,img{max-width:100%;height:auto}img{overflow-clip-margin:content-box;overflow:clip}.width-full{width:100%}.deployed-label-override{--calcite-label-text-color: var(--calcite-color-text-3);--calcite-label-margin-bottom: var(--calcite-spacing-none)}.svg-color{fill:var(--calcite-color-text-3)}.padding-end-1-2{padding-inline-end:var(--calcite-spacing-sm)}.padding-bottom-1-2{padding-bottom:var(--calcite-spacing-sm)}.display-flex{display:flex}.display-none{display:none}.flex-direction-column{flex-direction:column}.align-items-center{align-items:center}.font-weight-400,.font-weight-normal{font-weight:400}.font-color-text-2{--calcite-label-text-color: var(--calcite-color-text-2)}.font-line-height{line-height:1.4}.font-size-size--1{font-size:var(--calcite-font-size--1)}.icon-brand-color{--calcite-icon-color: var(--calcite-color-brand)}.header-line-height{--calcite-label-margin-bottom: 0;margin-top:var(--calcite-spacing-sm);margin-bottom:.7rem}.dialog-y-size{--calcite-dialog-size-y: 90% }.dialog-x-size{--calcite-dialog-size-x: 90% }.justify-content-space-between{justify-content:space-between}.panel-bg-color{--calcite-panel-header-background-color: var(--calcite-color-foreground-1);--calcite-panel-background-color: var(--calcite-color-foreground-1)}.cursor-default{cursor:default}`;function z(e){let t="",i="?";return e.forEach(a=>{a.k&&a.v&&(t+=i+a.k+"="+a.v,i="&")}),t}function $e(e){return e?M(e,{}).then(t=>Promise.resolve(!!t)):Promise.resolve(!1)}async function Y(e,t){let i=t,a=await i.getUsername(),s={q:new k().match(e).in("title").and().match(a).in("owner"),filter:"type:Solution",authentication:i},n=(await R(s)).results.map(p=>p.title),{folders:o}=await C(i),d=o.map(p=>p.title),u=[...n,...d].map(p=>p.trim().toLowerCase()),c=e.toLowerCase(),f=u.filter(p=>p===c),F=u.filter(p=>p.startsWith(c));return{conflictingNames:f,similiarNames:F}}async function Re(e,t){return q(e)?{status:!1,type:"empty"}:j(e)?{status:!1,type:"exceed length"}:J(e,"folder")?{status:!1,type:"special character"}:(await Y(e.trim(),t)).conflictingNames.length>0?{status:!1,type:"not unique"}:{status:!0,type:""}}function q(e){return e.length<=0}function j(e){return e.length>ye}function J(e,t){return(t==="item"?/[><~`$^+=|]/u:/[/<>]/u).test(e)}function Me(e){if(e){let t=e.trim();return t?"<div>"+t+"</div>":""}else return""}function Q(e){let t="",i="?";return e.forEach(a=>{a.k&&a.v&&(t+=i+a.k+"="+a.v,i="&")}),t}function Pe(e,t,i,a){let s="";return t?s=a+"/sharing/rest/content/items/"+e+"/info/"+t+Q([{k:"w",v:"400"}]):s=i,s}function Le(e){let t=e?e.replace("https://","").replace("www.",""):"";return t.endsWith("devext.arcgis.com")||t.endsWith("mapsqa.arcgis.com")||t.endsWith("qaext.arcgis.com")?e??"https://www.arcgis.com":"https://www.arcgis.com"}function Ue(e,t,i){return t.some(a=>a.wkid===e?(i=a.defaultExtent,!0):!1),i}function Ge(e,t){return X(t||e)}function Be(e,t="en"){return new Intl.DateTimeFormat(t,{year:"numeric",month:"long",day:"numeric"}).format(e)}function We(e,t){let i="";return e.some(a=>a.startsWith(t)?(i=a.substring(t.length),!0):!1),i}function X(e){let t=e.replace("www.","");return t.endsWith("devext.arcgis.com")?"dev":t.endsWith("mapsqa.arcgis.com")||t.endsWith("qaext.arcgis.com")?"qa":t==="arcgis.com"||t.endsWith(".arcgis.com")?"prod":"dev"}function Fe(e,t){let i=e?.reduce((a,s)=>(a.indexOf(s.id)<0&&a.push(s.id),a),[])||[];return t?i.sort((a,s)=>t.indexOf(a)-t.indexOf(s)):i}function Ve(e){return e.charAt(0).toUpperCase()+e.slice(1)}function Ke(e){return{relevance:"Relevance",title:"Title",new:"New",created:"Date deployed",updated:"Updated",suggested:"Suggested for you"}[e]||e}function He(e){if(!e)return"Unknown error";if(e.message)return e.message;try{let t=JSON.stringify(e);return t&&t!=="{}"?t:e.toString()}catch{return e.toString()}}function ze(e){return e?parseFloat(((Date.now()-e)/1e3).toFixed(2)):0}function m(e,t){(e.key==="Enter"||e.code==="NumpadEnter"||e.key===" ")&&(e.preventDefault(),e.stopPropagation(),t())}async function Z(e,t){let i=await $(e,t);if(!i)throw new Error(`Solution ${e} was not found`);let a=t?.portal.replace("/sharing/rest","")??"https://www.arcgis.com",s=[];if(i.templates[0].item)s=i.templates.map(n=>({id:n.itemId,title:n.item.title,type:n.item.type,typeKeywords:n.item.typeKeywords,dependencies:n.dependencies,snippet:n.item.snippet}));else{let n=i.templates.map(o=>o.type==="Group"?x(o.itemId,t):N(o.itemId,t));s=(await Promise.allSettled(n)).filter(o=>o.status==="fulfilled").map(o=>o.value).map((o,d)=>{let u=typeof o.type>"u"?"group":"item";return{id:o.id,title:o.title,type:o.type??"Group",typeKeywords:o.typeKeywords,dependencies:i.templates[d].dependencies,snippet:o.snippet,url:`${a}/home/${u}.html?id=${o.id}`}})}return s}function Ye(e,t,i){let a=e.templates.map(c=>c.type),s=[];s.push(re),a.indexOf("Group")>=0&&(s.push(P),s.push(U)),a.indexOf("Feature Service")>=0&&s.push(L);let n=a.indexOf("Feed")>-1;n&&s.push(ce);let o=a.indexOf("Big Data Analytic")>-1;o&&s.push(le);let d=a.indexOf("Real Time Analytic")>-1;d&&s.push(ue),(n||o||d)&&s.push(be),a.indexOf("Workflow")>-1&&(s.push(P),s.push(L),s.push(U),s.push(we)),a.indexOf("Geoprocessing Service")>-1&&(s.push(de),i.IsEnterprisePortal&&s.push(he));let u=e.templates.reduce((c,f)=>c.concat(f.item.typeKeywords||[]),[]);return te(s,u,i),ie(s,t),ee(s,e),s}function ee(e,t){t.templates.some(i=>i.type==="Group"&&i.item?.membershipAccess==="collaboration")&&e.push(ne)}function te(e,t,i){let a=G(i),s=ae(i);["Location Tracking View"].some(n=>t.indexOf(n)>-1)&&(!a&&!s?e.push(me):a&&!s?e.push(ge):!a&&s&&e.push(fe))}function ie(e,t){["HubPremium"].some(i=>t.indexOf(i)>-1)&&e.push(pe)}function G(e){return e.PortalUserSubset?.role==="org_admin"&&!e.PortalUserSubset?.roleId}function ae(e){return e.PortalSubset?.locationTrackingEnabled||!1}function qe(e,t){let i={leadingMessages:[],bulletedMessages:[],trailingMessages:[]},a=[l.NOTEBOOK,l.VELOCITY,l.HUBPREMIUM,l.WORKFLOW,l.TRACKINGBASE],s=g(e,t,l.VELOCITY);s&&i.leadingMessages.push(s);let n=g(e,t,l.NOTEBOOK);n&&i.leadingMessages.push(n);let o=g(e,t,l.HUBPREMIUM);o&&i.leadingMessages.push(o);let d=g(e,t,l.WORKFLOW);d&&i.leadingMessages.push(d),t=t.filter(c=>a.indexOf(c)<0),t.forEach(c=>{i.bulletedMessages.push(B(e,c))});let u=g(e,t,l.TRACKINGBASE);return u&&i.trailingMessages.push(u),(i.leadingMessages.length>0||i.trailingMessages.length>0||i.bulletedMessages.length>0)&&i.trailingMessages.push(e.missingPrivilegesPopup.suggestedProblemRemedyMessage),i}function g(e,t,i){return t.filter(a=>a.includes(i)).length>0?B(e,i):""}function B(e,t){let i=e.missingPrivilegesPopup.requiredPrivilegesList,a="";switch(t){case"portal:user:createItem":a=i.createItem;break;case"portal:publisher:publishFeatures":a=i.publishFeatures;break;case"portal:user:createGroup":a=i.createGroup;break;case"portal:user:shareToGroup":a=i.shareToGroup;break;case"portal:user:addExternalMembersToGroup":a=i.addMembers;break;case"portal:publisher:publishFeeds":a=i.publishFeeds;break;case"portal:publisher:publishBigDataAnalytics":a=i.publishBigDataAnalytics;break;case"portal:publisher:publishRealTimeAnalytics":a=i.publishRealTimeAnalytics;break;case"solutions:locationtracking:admin:tracking":a=i.requiresLocationTrackingAndAdmin;break;case"solutions:locationtracking:tracking":a=i.requiresLocationTracking;break;case"solutions:locationtracking:admin":a=i.requiresAdmin;break;case"solutions:hubPremium":a=i.hubPremium;break;case"solutions:workflowManager":a=i.workflowManager;break;case"solutions:velocity":a=i.velocity;break;case"solutions:notebook":a=i.requiresNotebookServer;break;case"portal:publisher:publishServerGPServices":a=i.publishGPServices;break;case"writable:Enterprise":a=i.writableEnterprise;break;case"writable:Online":a=i.writableOnline.replace("{{url}}","https://status.arcgis.com");break}return a}function je(e,t){let i=W(t),a=z([{k:"id",v:e}])||"";return i?`${i}/home/item.html${a}`:""}function Je(e,t,i,a){let s=a||W(i);return s?`${s}/sharing/rest/content/items/${e}/resources/${t}`:""}function W(e){return e?.PortalSubset?.orgUrl||e?.PortalUrl||""}function se(e,t){let i=new URL(e);return i.searchParams.set("token",t),i.toString()}var v=class extends S{constructor(){super(),this.deployedDate="",this.description="",this.diagramKey="",this.heading="",this.itemId="",this.owner="",this.thumbnail="",this.updateAvailable=!1,this.templateInfos=[],this._isDeleteOpen=!1,this._isDiagramOpen=!1,this.isMobile=!1,this.templateInfoGraph=[],this._configureTitlesOpen=!1,this._thumbnailUrl="",this._translations=I({name:"solution-deployed-card",blocking:!0}),this._configContextConsumer=y({context:K,subscribe:!0,callback:async t=>{t&&(this._isOrgAdmin=G(t.authentication),this._thumbnailUrl=`${this.thumbnail}&token=${t.userSession?.token}`)}}),this._deleteDialogRef=b(),this._diagramDialogRef=b(),this._isOrgAdmin=!1,this._isMobileContextConsumer=y({context:V,subscribe:!0,callback:t=>this.isMobile=t}),this.deployedCardSelected=D(),this.listenOn(window,"sessionRefreshed",t=>{this._updateThumbnailToken(t.detail)})}static{this.properties={card:0,deployedDate:1,description:1,diagramKey:1,heading:1,itemId:1,owner:1,thumbnail:1,updateAvailable:5,templateInfos:0,_isDeleteOpen:16,_isDiagramOpen:16,isMobile:16,templateInfoGraph:16,_configureTitlesOpen:16,_thumbnailUrl:16,_translations:16}}static{this.styles=H}get _telemetry(){return this._configContextConsumer.value?.telemetrySession}async renderDeleteDialog(){return this._isDeleteOpen=!0,this._renderDeleteDialog(),this._deleteDialogRef.value}async renderDiagramDialog(t){return await this._viewDiagram(t),await this._renderDiagramDialog(),this._diagramDialogRef.value}async getTemplates(){return this._processTemplates(this.card)}async load(){this._isMobileContextConsumer.value&&(this.isMobile=this._isMobileContextConsumer.value)}render(){return r`<calcite-card .label=${this.description} @click=${this._cardSelected} @keydown=${t=>m(t,()=>this._cardSelected())}>${this._getImage()}${this._getHeader()}<p class="font-color-text-2 font-line-height font-size-size--1" slot=description>${this.description}</p><div class="width-full display-flex flex-direction-column" slot=footer-start><div class="padding-bottom-1-2">${this.owner!==""&&this._getOwnerLabel()||""}${this._getDeployedDate()}</div>${this._getConfigureButton()}</div></calcite-card>${this._renderDeleteDialog()}${this._renderDiagramDialog()}${this._renderConfigureTitlesDialog()}`}_getImage(){return r`<div class="card-image-wrap" slot=thumbnail><img alt=${this.heading??h} class="thumbnail card-image" src=${this._thumbnailUrl??h}><div class="hover-text">${this._translations.openSolution}</div></div>`}_getHeader(){return r`<div class="display-flex justify-content-space-between header-line-height" slot=heading><calcite-label layout=inline-space-between scale=l>${this.heading}</calcite-label></div>`}_getOwnerLabel(){return r`<calcite-label class="font-weight-400 padding-end-1-2" layout=inline scale=s>${`${this._translations.owner}:`}<calcite-link class="font-weight-normal" @click=${this._openUserProfile} @keydown=${t=>m(t,()=>this._openUserProfile(t))}>${this.owner}</calcite-link></calcite-label>`}_getDeployedDate(){return r`<div class="display-flex align-items-center"><div class="padding-end-1-2"><svg height=16px viewBox="0 0 32 32" width=16px xmlns=http://www.w3.org/2000/svg>${_`<path class="svg-color" d="M29.963 7.672a1.586 1.586 0 0 0-1.584-1.585h-5.274a.187.187 0 0 1-.188-.187V3.977A2 2 0 0 0 20.825 2h-9.672A2.095 2.095 0 0 0 9.06 4.093V5.9a.187.187 0 0 1-.187.187H3.598a1.586 1.586 0 0 0-1.584 1.585v4.016a.281.281 0 0 0 .281.28H4.9l.014-.013V9.153a.177.177 0 0 1 .177-.177h21.46a.456.456 0 0 1 .449.45v13.742A1.832 1.832 0 0 1 25.168 25h-8.892a.568.568 0 0 1-.534-.373 3.98 3.98 0 0 0-7.6.373H5.657a.757.757 0 0 1-.757-.757v-3.055A.188.188 0 0 0 4.714 21H2.028l-.014.014v4.58a2.35 2.35 0 0 0 2.347 2.346h4.161a3.963 3.963 0 0 0 6.8.256.569.569 0 0 1 .475-.256h12.065a2.102 2.102 0 0 0 2.101-2.101zM21 5.625a.375.375 0 0 1-.375.375h-9.25A.375.375 0 0 1 11 5.625V4.45a.456.456 0 0 1 .45-.45h9.1a.456.456 0 0 1 .45.45zM12 28a2 2 0 1 1 2-2 2 2 0 0 1-2 2z" /><path class="svg-color" d="M13.273 17.994a.57.57 0 0 1 .479.262A3.73 3.73 0 0 0 17 20a3.74 3.74 0 0 0 3.403-2.006h3.41a.188.188 0 0 0 .187-.188v-2.589a.187.187 0 0 0-.188-.188H20.8A3.8 3.8 0 0 0 17 12a4.058 4.058 0 0 0-3.69 2.647.568.568 0 0 1-.537.383H1.093a.094.094 0 0 0-.093.093V17.9a.094.094 0 0 0 .094.094zM17 13.9a2.1 2.1 0 1 1-2.1 2.1 2.1 2.1 0 0 1 2.1-2.1z" />`}</svg></div><calcite-label class="deployed-label-override" scale=s>${this._translations.deployedDate.replace("{{date}}",this.deployedDate)}</calcite-label></div>`}_getConfigureButton(){let t=this._configContextConsumer.value?.userSession?.username,i=this._configContextConsumer.value?.authentication?.CanUpdateSolution,a=this.card?.owner===t||this._isOrgAdmin||i,s=this.card?.owner===t||this._isOrgAdmin,n=a?"display-none":"";return r`<calcite-split-button appearance=outline aria-label=${this._translations.openSolution??h} dropdown-label=${this._translations.moreActions??h} kind=neutral @calciteSplitButtonPrimaryClick=${this._cardSelected} @click=${o=>o.stopPropagation()} @keydown=${o=>o.stopPropagation()} overlay-positioning=fixed primary-text=${this._translations.openSolution??h} width=full><calcite-dropdown-group selection-mode=none>${!this.isMobile&&r`<calcite-dropdown-item icon-start=model @click=${this._viewDiagram} @keydown=${o=>m(o,()=>this._viewDiagram(o))}>${this._translations.viewDiagram}</calcite-dropdown-item>`||""}<calcite-dropdown-item icon-start=file-text @click=${this._viewDocumentation} @keydown=${o=>m(o,()=>this._viewDocumentation(o))}>${this._translations.documentation}</calcite-dropdown-item><calcite-dropdown-item icon-start=information @click=${this._viewItemDetails} @keydown=${o=>m(o,()=>this._viewItemDetails(o))}>${this._translations.viewItemDetails}</calcite-dropdown-item>${!this.isMobile&&a&&r`<calcite-dropdown-item icon-start=edit-attributes id=solution-configure-titles-dropdown @click=${async()=>{this.templateInfos=await this._processTemplates(this.card),this._configureTitlesOpen=!0}} @keydown=${o=>m(o,async()=>{this.templateInfos=await this._processTemplates(this.card),this._configureTitlesOpen=!0})}>${this._translations.renameItems}</calcite-dropdown-item>`||""}${!this.isMobile&&s&&r`<calcite-dropdown-item icon-start=trash @click=${this._deleteSolution} @keydown=${o=>m(o,()=>this._deleteSolution(o))}>${this._translations.deleteSolution}</calcite-dropdown-item>`||""}</calcite-dropdown-group><calcite-tooltip class=${A(n)} overlay-positioning=fixed reference-element=solution-configure-titles-dropdown><span>${this._translations.mustOwnSolution}</span></calcite-tooltip></calcite-split-button>`}_renderDeleteDialog(){return this._isDeleteOpen?r`<solution-delete-dialog .card=${this.card} @solutionDeleteDialogOpen=${t=>{this._isDeleteOpen=t.detail}} .open=${this._isDeleteOpen} source="Card Dropdown" ${w(this._deleteDialogRef)}></solution-delete-dialog>`:""}_renderDiagramDialog(){return this._isDiagramOpen?r`<calcite-dialog class="dialog-y-size dialog-x-size panel-bg-color" .heading=${this._translations.diagramTitle.replace("{{solution}}",this.card?.title??"")} id=${this._translations.diagramTitle.replace("{{solution}}",this.card?.title??"")??h} modal .open=${this._isDiagramOpen} @calciteDialogClose=${()=>{this._isDiagramOpen=!1}} outside-close-disabled scale=m width=l ${w(this._diagramDialogRef)}><solution-item-diagram .diagramKey=${this.diagramKey} .templateInfoGraph=${this.templateInfoGraph} .typeKeywords=${this.card?.typeKeywords}></solution-item-diagram></calcite-dialog>`:""}_renderConfigureTitlesDialog(){return this._configureTitlesOpen?r`<solution-configure-titles .card=${this.card} @solutionConfigureTitlesBeforeClose=${async()=>{this._processTemplates(this.card).then(t=>{this.templateInfos=t}),this._configureTitlesOpen=!1}} @solutionItemsTitlesChanged=${async()=>{this._processTemplates(this.card).then(t=>{this.templateInfos=t})}} .open=${this._configureTitlesOpen} source="Card Dropdown" .templateInfos=${this.templateInfos}></solution-configure-titles>`:""}_cardSelected(){this.deployedCardSelected.emit({card:this.card,cardRef:this.el})}async _viewDiagram(t){t.stopPropagation(),this.card&&(this._telemetry?.logEvent({category:E.DEPLOYMENTS,action:"View Diagram",dimensions:[this.card.title||"",this.card.deployCommonId||"",this.card.deployVersion||"","Card Dropdown"]}),this.templateInfoGraph=await this._processTemplates(this.card),this._isDiagramOpen=!0)}_viewDocumentation(t){t.stopPropagation(),this._telemetry?.logEvent({category:E.DEPLOYMENTS,action:"Open Help",dimensions:[this.card?.title||"",this.card?.deployCommonId||"",this.card?.deployVersion||"","Card Dropdown"]}),window.open(this.card.learnMoreUrl,"_blank")}_viewItemDetails(t){t.stopPropagation(),this._telemetry?.logEvent({category:E.DEPLOYMENTS,action:"Open Item Details",dimensions:[this.card?.title||"",this.card?.deployCommonId||"",this.card?.deployVersion||"","Card Dropdown"]}),window.open(this.card.itemUrl,"_blank")}_deleteSolution(t){t.stopPropagation(),this._isDeleteOpen=!0}_openUserProfile(t){t.stopPropagation();let i=this._configContextConsumer.value?.authentication?.PortalSubset?.orgUrl;i&&window.open(`${i}/home/user.html?user=${this.owner}`,"_blank")}async _processTemplates(t){return await Z(t.id,this._configContextConsumer.value.userSession)}_updateThumbnailToken(t){this._thumbnailUrl!==""&&(this._thumbnailUrl=se(this._thumbnailUrl,t))}};O("solution-deployed-card",v);var Qe=500,Xe={AEC:"Architecture, Engineering, and Construction (AEC)",AIRPORTPORTRAIL:"Airports, Ports, and Rails",BUSINESS:"Business",CONSERVATION:"Conservation",DEFENSE:"Defense",FACILITIES:"Facilities",HEALTHANDHUMANSERVICES:"Health and Human Services",PIPELINE:"Pipeline",PUBLICSAFETY:"Public Safety",RENEWABLES:"Renewables",STATEANDLOCALGOVERNMENT:"State and Local Government",TELECOMMUNICATIONS:"Telecommunications",UTILITIES:"Utilities"},Ze={AIRPORT:"Airports",AGRICULTURE:"Agriculture",ASSESSMENTANDTAXATION:"Assessment and Taxation",DISTRICTENERGY:"District Energy",ELECTIONS:"Elections",ELECTRIC:"Electric",EMERGENCYMANAGEMENT:"Emergency Management",ENVIRONMENTANDNATURALRESOURCES:"Environment and Natural Resources",FIRESERVICE:"Fire Service",FISHANDWILDLIFE:"Fish and Wildlife",GAS:"Gas",HEALTHANDHUMANSERVICES:"Health and Human Services",LAWENFORCEMENT:"Law Enforcement",NATURALRESOURCES:"Natural Resources",PARKS:"Parks",PLANNINGANDDEVELOPMENT:"Planning and Development",PROTECTEDAREAS:"Protected Areas",PUBLICWORKS:"Public Works",SEWER:"Sewer",STORMWATER:"Stormwater",TELECOMMUNICATIONS:"Telecommunications",TRANSPORTATION:"Transportation",WATER:"Water Distribution"},l=(e=>(e.HUBPREMIUM="solutions:hubPremium",e.NOTEBOOK="solutions:notebook",e.TRACKINGBASE="solutions:locationtracking",e.TRACKING="solutions:locationtracking:tracking",e.TRACKINGADMIN="solutions:locationtracking:admin",e.TRACKINGADMINANDTRACKING="solutions:locationtracking:admin:tracking",e.VELOCITY="solutions:velocity",e.WORKFLOW="solutions:workflowManager",e))(l||{}),oe=(e=>(e.VELOCITYBIGDATA="portal:publisher:publishBigDataAnalytics",e.VELOCITYFEEDS="portal:publisher:publishFeeds",e.VELOCITYREALTIME="portal:publisher:publishRealTimeAnalytics",e))(oe||{}),et='((typekeywords:Solution,Deployed,"ArcGIS Solution") OR ((typekeywords:Solution,Deployed) AND (created:[1577862000000 TO 1622576880000])))',tt="(typekeywords:Solution,Template)",ne="portal:user:addExternalMembersToGroup",re="portal:user:createItem",P="portal:user:createGroup",le="portal:publisher:publishBigDataAnalytics",L="portal:publisher:publishFeatures",ce="portal:publisher:publishFeeds",de="portal:publisher:publishServerGPServices",ue="portal:publisher:publishRealTimeAnalytics",U="portal:user:shareToGroup",pe="solutions:hubPremium",he="solutions:notebook",me="solutions:locationtracking:admin:tracking",ge="solutions:locationtracking:tracking",fe="solutions:locationtracking:admin",be="solutions:velocity",we="solutions:workflowManager",ye=250,E={SOLUTION_DETAILS:"Solution Details",GLOBAL_NAVIGATION:"Global Nav",ALL_SOLUTIONS:"Solutions",DEPLOYMENTS:"Deployments",ASSISTANT:"Assistant",RESOURCES:"Resources"},it={MINE:"My deployments",ORG:"Organization"};return{a:V,b:K,c:$e,d:Y,e:Re,f:J,g:Me,h:Q,i:Pe,j:Le,k:Ue,l:Ge,m:Be,n:We,o:Fe,p:Ve,q:Ke,r:He,s:ze,t:m,u:Z,v:Ye,w:G,x:qe,y:je,z:Je,A:se,B:v,C:Qe,D:Xe,E:Ze,F:l,G:oe,H:et,I:tt,J:ye,K:E,L:it}},"identity/IdentityManager","identity/OAuthInfo","portal/Portal","intl")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import b from"./QNSZUCGN.js";import"./6MZ227J7.js";import a from"./JJUJVV7A.js";import"./PZ4L77M5.js";import"./LHCWS2RN.js";import"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./2CMRI2B3.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,a])=>{return a},a,b)
2
+ import b from"./G2T6OYTB.js";import"./6MZ227J7.js";import a from"./HHKKBJCY.js";import"./PZ4L77M5.js";import"./DD3JC2L3.js";import"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./S7XOHDIW.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,a])=>{return a},a,b)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import"./56MHO3UY.js";import b from"./GRJZORJP.js";import a from"./JJUJVV7A.js";import"./PZ4L77M5.js";import"./LHCWS2RN.js";import{a as p}from"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import{b as g}from"./2CMRI2B3.js";import{F as c,G as l,H as h,h as r,i as s,r as d}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([])=>{var u={heading:"Get Started",card1:{heading:"What's new in the app"},card2:{heading:"Deploy a solution"},card3:{heading:"Manage a deployment"},card4:{heading:"AI Assistant"}},m={heading:"Documentation",card1:{heading:"Help"},card2:{heading:"What's new"},card3:{heading:"FAQ"},card4:{heading:"ArcGIS Blog"}},b={heading:"Support",card1:{heading:"Esri Community"},card2:{heading:"ArcGIS Ideas"},card3:{heading:"Esri Video"},card4:{heading:"Technical support"}},i={getStarted:u,documentation:m,support:b},v=r`*[tabindex]:focus-visible{outline:2px solid var(--calcite-color-brand);outline-offset:2px}.position-relative{position:relative}.background-override{--calcite-shell-panel-background-color: var(--calcite-color-foreground-2);--calcite-panel-background-color: var(--calcite-color-foreground-2)}.width-350{--calcite-shell-panel-width: 350px}.height-full{height:100%}.padding-end-1-2{padding-inline-end:var(--calcite-spacing-sm)}calcite-panel{--calcite-panel-background-color: var(--calcite-color-foreground-1)}calcite-shell{background-color:unset}.padding-end-1{padding-inline-end:var(--calcite-spacing-lg)}.padding-start-1{padding-inline-start:var(--calcite-spacing-lg)}.margin-end-md{margin-inline-end:var(--calcite-spacing-md)}.resources-container{width:100%;box-sizing:border-box}.hero-banner{background-color:var(--calcite-color-foreground-2);padding:4.25rem var(--calcite-spacing-md);text-align:center;width:100%;box-sizing:border-box;margin-bottom:3rem}.hero-heading{font-size:var(--calcite-font-size-5);font-weight:var(--calcite-font-weight-medium);margin:0 0 var(--calcite-spacing-xxl) 0;color:var(--calcite-color-text-1)}.hero-subheading{font-size:var(--calcite-font-size-0);color:var(--calcite-color-text-2);max-width:600px;margin:0 auto}`,o=class extends h{constructor(){super(),this._translations=p({name:"solutions-resources-shell",blocking:!0}),this._mainPanelRef=c(),this._panelFixed=!1,this.sortTypeChanged=d(),this.listenOn(window,"deployAppTabSelected",this._handleDeployAppTabSelected)}static{this.properties={_translations:16}}static{this.styles=v}updated(){this._fixPanelContentWrapperFocus()}_fixPanelContentWrapperFocus(){if(!this._panelFixed&&this._mainPanelRef.value){let e=this._mainPanelRef.value;e.componentOnReady?.().then(()=>{if(e.shadowRoot){let n=e.shadowRoot.querySelector(".content-wrapper");n&&(n.tabIndex=-1,this._panelFixed=!0,this._setupPanelObserver())}}).catch(()=>{this._panelFixed=!0})}}_setupPanelObserver(){if(this._panelObserver)return;this._panelObserver=new MutationObserver(n=>{n.forEach(a=>{if(a.type==="attributes"&&a.attributeName==="tabindex"){let t=a.target;t.classList.contains("content-wrapper")&&t.tabIndex===0&&(t.tabIndex=-1)}})});let e=this._mainPanelRef.value;if(e?.shadowRoot){let n=e.shadowRoot.querySelector(".content-wrapper");n&&this._panelObserver.observe(n,{attributes:!0,attributeFilter:["tabindex"]})}}disconnectedCallback(){super.disconnectedCallback(),this._panelObserver?.disconnect()}render(){let e=this._translations;return s`<calcite-shell><calcite-panel ${l(this._mainPanelRef)}><div class="resources-container"><div class="hero-banner"><h1 class="hero-heading" tabindex=0>${e.hero.heading}</h1><p class="hero-subheading" tabindex=0>${e.hero.subheading}</p></div><solutions-resources-section .heading=${e.getStarted.heading} .subheading=${e.getStarted.subheading} .cards=${[{meridianIcon:"value",heading:e.getStarted.card1.heading,description:e.getStarted.card1.description,url:"https://links.esri.com/solutions/whats-new-in-the-app",headingEn:i.getStarted.card1.heading,sectionHeadingEn:i.getStarted.heading},{meridianIcon:"install",heading:e.getStarted.card2.heading,description:e.getStarted.card2.description,url:"https://links.esri.com/solutions/deploy-a-solution",headingEn:i.getStarted.card2.heading,sectionHeadingEn:i.getStarted.heading},{meridianIcon:"keys",heading:e.getStarted.card3.heading,description:e.getStarted.card3.description,url:"https://links.esri.com/solutions/manage-a-deployment",headingEn:i.getStarted.card3.heading,sectionHeadingEn:i.getStarted.heading},{meridianIcon:"speech-bubbles",heading:e.getStarted.card4.heading,description:e.getStarted.card4.description,url:"https://links.esri.com/solutions/ai-assistant",headingEn:i.getStarted.card4.heading,sectionHeadingEn:i.getStarted.heading}]}></solutions-resources-section><solutions-resources-section .heading=${e.documentation.heading} .subheading=${e.documentation.subheading} .cards=${[{meridianIcon:"search-files",heading:e.documentation.card1.heading,description:e.documentation.card1.description,url:"https://links.esri.com/solutions/help",headingEn:i.documentation.card1.heading,sectionHeadingEn:i.documentation.heading},{meridianIcon:"value",heading:e.documentation.card2.heading,description:e.documentation.card2.description,url:"https://links.esri.com/solutions/whats-new",headingEn:i.documentation.card2.heading,sectionHeadingEn:i.documentation.heading},{meridianIcon:"faq",heading:e.documentation.card3.heading,description:e.documentation.card3.description,url:"https://links.esri.com/solutions/faq",headingEn:i.documentation.card3.heading,sectionHeadingEn:i.documentation.heading},{meridianIcon:"arcmap-blog",heading:e.documentation.card4.heading,description:e.documentation.card4.description,url:"https://links.esri.com/solutions/arcgis-blogs",headingEn:i.documentation.card4.heading,sectionHeadingEn:i.documentation.heading}]}></solutions-resources-section><solutions-resources-section .heading=${e.support.heading} .subheading=${e.support.subheading} .cards=${[{meridianIcon:"esri-community",heading:e.support.card1.heading,description:e.support.card1.description,url:"https://links.esri.com/solutions/esri-community",headingEn:i.support.card1.heading,sectionHeadingEn:i.support.heading},{meridianIcon:"idea",heading:e.support.card2.heading,description:e.support.card2.description,url:"https://links.esri.com/solutions/arcgis-ideas",headingEn:i.support.card2.heading,sectionHeadingEn:i.support.heading},{meridianIcon:"video",heading:e.support.card3.heading,description:e.support.card3.description,url:"https://links.esri.com/solutions/esri-video",headingEn:i.support.card3.heading,sectionHeadingEn:i.support.heading},{meridianIcon:"support",heading:e.support.card4.heading,description:e.support.card4.description,url:"https://links.esri.com/solutions/technical-support",headingEn:i.support.card4.heading,sectionHeadingEn:i.support.heading}]}></solutions-resources-section></div></calcite-panel></calcite-shell>`}_handleDeployAppTabSelected(e){e.detail==="resources"&&this.sortTypeChanged.emit("")}};g("solutions-resources-shell",o);return o},a,b)
2
+ import"./O7AZMIQX.js";import b from"./P6NSLBDS.js";import a from"./HHKKBJCY.js";import"./PZ4L77M5.js";import"./DD3JC2L3.js";import{a as p}from"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import{b as g}from"./S7XOHDIW.js";import{F as c,G as l,H as h,h as r,i as s,r as d}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([])=>{var u={heading:"Get Started",card1:{heading:"What's new in the app"},card2:{heading:"Deploy a solution"},card3:{heading:"Manage a deployment"},card4:{heading:"AI Assistant"}},m={heading:"Documentation",card1:{heading:"Help"},card2:{heading:"What's new"},card3:{heading:"FAQ"},card4:{heading:"ArcGIS Blog"}},b={heading:"Support",card1:{heading:"Esri Community"},card2:{heading:"ArcGIS Ideas"},card3:{heading:"Esri Video"},card4:{heading:"Technical support"}},i={getStarted:u,documentation:m,support:b},v=r`*[tabindex]:focus-visible{outline:2px solid var(--calcite-color-brand);outline-offset:2px}.position-relative{position:relative}.background-override{--calcite-shell-panel-background-color: var(--calcite-color-foreground-2);--calcite-panel-background-color: var(--calcite-color-foreground-2)}.width-350{--calcite-shell-panel-width: 350px}.height-full{height:100%}.padding-end-1-2{padding-inline-end:var(--calcite-spacing-sm)}calcite-panel{--calcite-panel-background-color: var(--calcite-color-foreground-1)}calcite-shell{background-color:unset}.padding-end-1{padding-inline-end:var(--calcite-spacing-lg)}.padding-start-1{padding-inline-start:var(--calcite-spacing-lg)}.margin-end-md{margin-inline-end:var(--calcite-spacing-md)}.resources-container{width:100%;box-sizing:border-box}.hero-banner{background-color:var(--calcite-color-foreground-2);padding:4.25rem var(--calcite-spacing-md);text-align:center;width:100%;box-sizing:border-box;margin-bottom:3rem}.hero-heading{font-size:var(--calcite-font-size-5);font-weight:var(--calcite-font-weight-medium);margin:0 0 var(--calcite-spacing-xxl) 0;color:var(--calcite-color-text-1)}.hero-subheading{font-size:var(--calcite-font-size-0);color:var(--calcite-color-text-2);max-width:600px;margin:0 auto}`,o=class extends h{constructor(){super(),this._translations=p({name:"solutions-resources-shell",blocking:!0}),this._mainPanelRef=c(),this._panelFixed=!1,this.sortTypeChanged=d(),this.listenOn(window,"deployAppTabSelected",this._handleDeployAppTabSelected)}static{this.properties={_translations:16}}static{this.styles=v}updated(){this._fixPanelContentWrapperFocus()}_fixPanelContentWrapperFocus(){if(!this._panelFixed&&this._mainPanelRef.value){let e=this._mainPanelRef.value;e.componentOnReady?.().then(()=>{if(e.shadowRoot){let n=e.shadowRoot.querySelector(".content-wrapper");n&&(n.tabIndex=-1,this._panelFixed=!0,this._setupPanelObserver())}}).catch(()=>{this._panelFixed=!0})}}_setupPanelObserver(){if(this._panelObserver)return;this._panelObserver=new MutationObserver(n=>{n.forEach(a=>{if(a.type==="attributes"&&a.attributeName==="tabindex"){let t=a.target;t.classList.contains("content-wrapper")&&t.tabIndex===0&&(t.tabIndex=-1)}})});let e=this._mainPanelRef.value;if(e?.shadowRoot){let n=e.shadowRoot.querySelector(".content-wrapper");n&&this._panelObserver.observe(n,{attributes:!0,attributeFilter:["tabindex"]})}}disconnectedCallback(){super.disconnectedCallback(),this._panelObserver?.disconnect()}render(){let e=this._translations;return s`<calcite-shell><calcite-panel ${l(this._mainPanelRef)}><div class="resources-container"><div class="hero-banner"><h1 class="hero-heading" tabindex=0>${e.hero.heading}</h1><p class="hero-subheading" tabindex=0>${e.hero.subheading}</p></div><solutions-resources-section .heading=${e.getStarted.heading} .subheading=${e.getStarted.subheading} .cards=${[{meridianIcon:"value",heading:e.getStarted.card1.heading,description:e.getStarted.card1.description,url:"https://links.esri.com/solutions/whats-new-in-the-app",headingEn:i.getStarted.card1.heading,sectionHeadingEn:i.getStarted.heading},{meridianIcon:"install",heading:e.getStarted.card2.heading,description:e.getStarted.card2.description,url:"https://links.esri.com/solutions/deploy-a-solution",headingEn:i.getStarted.card2.heading,sectionHeadingEn:i.getStarted.heading},{meridianIcon:"keys",heading:e.getStarted.card3.heading,description:e.getStarted.card3.description,url:"https://links.esri.com/solutions/manage-a-deployment",headingEn:i.getStarted.card3.heading,sectionHeadingEn:i.getStarted.heading},{meridianIcon:"speech-bubbles",heading:e.getStarted.card4.heading,description:e.getStarted.card4.description,url:"https://links.esri.com/solutions/ai-assistant",headingEn:i.getStarted.card4.heading,sectionHeadingEn:i.getStarted.heading}]}></solutions-resources-section><solutions-resources-section .heading=${e.documentation.heading} .subheading=${e.documentation.subheading} .cards=${[{meridianIcon:"search-files",heading:e.documentation.card1.heading,description:e.documentation.card1.description,url:"https://links.esri.com/solutions/help",headingEn:i.documentation.card1.heading,sectionHeadingEn:i.documentation.heading},{meridianIcon:"value",heading:e.documentation.card2.heading,description:e.documentation.card2.description,url:"https://links.esri.com/solutions/whats-new",headingEn:i.documentation.card2.heading,sectionHeadingEn:i.documentation.heading},{meridianIcon:"faq",heading:e.documentation.card3.heading,description:e.documentation.card3.description,url:"https://links.esri.com/solutions/faq",headingEn:i.documentation.card3.heading,sectionHeadingEn:i.documentation.heading},{meridianIcon:"arcmap-blog",heading:e.documentation.card4.heading,description:e.documentation.card4.description,url:"https://links.esri.com/solutions/arcgis-blogs",headingEn:i.documentation.card4.heading,sectionHeadingEn:i.documentation.heading}]}></solutions-resources-section><solutions-resources-section .heading=${e.support.heading} .subheading=${e.support.subheading} .cards=${[{meridianIcon:"esri-community",heading:e.support.card1.heading,description:e.support.card1.description,url:"https://links.esri.com/solutions/esri-community",headingEn:i.support.card1.heading,sectionHeadingEn:i.support.heading},{meridianIcon:"idea",heading:e.support.card2.heading,description:e.support.card2.description,url:"https://links.esri.com/solutions/arcgis-ideas",headingEn:i.support.card2.heading,sectionHeadingEn:i.support.heading},{meridianIcon:"video",heading:e.support.card3.heading,description:e.support.card3.description,url:"https://links.esri.com/solutions/esri-video",headingEn:i.support.card3.heading,sectionHeadingEn:i.support.heading},{meridianIcon:"support",heading:e.support.card4.heading,description:e.support.card4.description,url:"https://links.esri.com/solutions/technical-support",headingEn:i.support.card4.heading,sectionHeadingEn:i.support.heading}]}></solutions-resources-section></div></calcite-panel></calcite-shell>`}_handleDeployAppTabSelected(e){e.detail==="resources"&&this.sortTypeChanged.emit("")}};g("solutions-resources-shell",o);return o},a,b)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import d from"./ONIWIJZN.js";import c from"./NVYKJK26.js";import b from"./PLHWBWIG.js";import a from"./JJUJVV7A.js";import"./PZ4L77M5.js";import"./LHCWS2RN.js";import"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./2CMRI2B3.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,,,a])=>{return a},a,b,c,d)
2
+ import d from"./76M3UWJF.js";import c from"./PAKIDHHK.js";import b from"./TAHIBODN.js";import a from"./HHKKBJCY.js";import"./PZ4L77M5.js";import"./DD3JC2L3.js";import"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./S7XOHDIW.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,,,a])=>{return a},a,b,c,d)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{b as m}from"./2CMRI2B3.js";import{F as h,G as n,H as d,h as s,i as o,r as i}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([f,l])=>{var c=s`:host{display:block}`,r=class extends d{constructor(){super(...arguments),this.enabled=!1,this._floorFilterElement=h(),this.facilityChanged=i(),this.levelChanged=i(),this.siteChanged=i()}static{this.properties={enabled:5,floorFilterWidget:0,mapView:0}}static{this.styles=c}willUpdate(t){t.has("mapView")&&this.mapViewWatchHandler(),t.has("enabled")&&this.enabledWatchHandler()}async mapViewWatchHandler(){this.mapView&&await this._initFloorFilter(this.mapView)}async enabledWatchHandler(){this.enabled?this.mapView&&await this._initFloorFilter(this.mapView):this.enabled||this._destroyWidget()}render(){return o`<div ${n(this._floorFilterElement)}></div>`}async loaded(){this.mapView&&!this.floorFilterWidget&&await this._initFloorFilter(this.mapView)}_destroyWidget(){this.floorFilterWidget&&(this.floorFilterWidget.destroy(),this.floorFilterWidget=void 0),this._floorFilterElement.value&&this._floorFilterElement.value.remove()}_initContainer(){this._destroyWidget(),this._floorFilterElement&&(this._floorFilterElement.value=document.createElement("div"))}async _initFloorFilter(t){let a=t?.map;a&&await a.when(()=>{t&&this.enabled&&a?.floorInfo&&(this._initContainer(),this.floorFilterWidget=new f({container:this._floorFilterElement.value,view:t}),this._facilityHandle?.remove(),this._facilityHandle=l?.watch(()=>this.floorFilterWidget?.facility,e=>{e&&this.facilityChanged.emit(e)}),this._levelHandle?.remove(),this._levelHandle=l.watch(()=>this.floorFilterWidget?.level,e=>{e&&this.levelChanged.emit(e)}),this._siteHandle?.remove(),this._siteHandle=l.watch(()=>this.floorFilterWidget?.site,e=>{e&&this.siteChanged.emit(e)}))})}};m("map-floor-filter",r);return r},"widgets/FloorFilter","core/reactiveUtils")
2
+ import{b as m}from"./S7XOHDIW.js";import{F as h,G as n,H as d,h as s,i as o,r as i}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([f,l])=>{var c=s`:host{display:block}`,r=class extends d{constructor(){super(...arguments),this.enabled=!1,this._floorFilterElement=h(),this.facilityChanged=i(),this.levelChanged=i(),this.siteChanged=i()}static{this.properties={enabled:5,floorFilterWidget:0,mapView:0}}static{this.styles=c}willUpdate(t){t.has("mapView")&&this.mapViewWatchHandler(),t.has("enabled")&&this.enabledWatchHandler()}async mapViewWatchHandler(){this.mapView&&await this._initFloorFilter(this.mapView)}async enabledWatchHandler(){this.enabled?this.mapView&&await this._initFloorFilter(this.mapView):this.enabled||this._destroyWidget()}render(){return o`<div ${n(this._floorFilterElement)}></div>`}async loaded(){this.mapView&&!this.floorFilterWidget&&await this._initFloorFilter(this.mapView)}_destroyWidget(){this.floorFilterWidget&&(this.floorFilterWidget.destroy(),this.floorFilterWidget=void 0),this._floorFilterElement.value&&this._floorFilterElement.value.remove()}_initContainer(){this._destroyWidget(),this._floorFilterElement&&(this._floorFilterElement.value=document.createElement("div"))}async _initFloorFilter(t){let a=t?.map;a&&await a.when(()=>{t&&this.enabled&&a?.floorInfo&&(this._initContainer(),this.floorFilterWidget=new f({container:this._floorFilterElement.value,view:t}),this._facilityHandle?.remove(),this._facilityHandle=l?.watch(()=>this.floorFilterWidget?.facility,e=>{e&&this.facilityChanged.emit(e)}),this._levelHandle?.remove(),this._levelHandle=l.watch(()=>this.floorFilterWidget?.level,e=>{e&&this.levelChanged.emit(e)}),this._siteHandle?.remove(),this._siteHandle=l.watch(()=>this.floorFilterWidget?.site,e=>{e&&this.siteChanged.emit(e)}))})}};m("map-floor-filter",r);return r},"widgets/FloorFilter","core/reactiveUtils")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as h}from"./4T7P5RXF.js";import{a as d}from"./HA5W44KL.js";import{b as r}from"./2CMRI2B3.js";import{F as i,G as l,H as c,h as n,i as s,r as a}from"./46DQNAMV.js";var g=n`*[tabindex]:focus-visible{outline:2px solid var(--calcite-color-brand);outline-offset:2px}.panel-bg-white{--calcite-panel-background-color: var(--calcite-color-foreground-1)}calcite-loader{--calcite-loader-spacing: var(--calcite-spacing-md)}.loader-text{margin-top:var(--calcite-spacing-sm);margin-bottom:var(--calcite-spacing-xxxl);text-align:center;font-size:var(--calcite-font-size-relative-base);color:var(--calcite-color-text-1)}.carousel-style{height:120px;display:flex;align-items:center}`,o=class extends c{constructor(){super(),this.deploymentProgress=0,this.open=!1,this.isWaitingForCard=!1,this._isInCancelConfirmation=!1,this._showCancelConfirmation=!1,this._showIsCancelling=!1,this._translations=d({name:"solution-deploying-dialog",blocking:!0}),this._carouselKey=0,this._deployingDialogRef=i(),this._carouselRef=i(),this._carouselMessages=[],this._confirmUnload=!1,this.deployingDialogOpened=a(),this.deploymentProcessCancelled=a(),this.listenOn(window,"beforeunload",e=>{(this._confirmUnload||this._showIsCancelling)&&(e.preventDefault(),e.returnValue=!0)})}static{this.properties={abortController:0,card:0,deploymentProgress:9,open:5,isWaitingForCard:5,_isInCancelConfirmation:16,_showCancelConfirmation:16,_showIsCancelling:16,_translations:16,_carouselKey:16}}static{this.styles=g}close(){this._showCancelConfirmation=!1,this._showIsCancelling=!1,this.isWaitingForCard=!1;let e=this._deployingDialogRef.value;e&&(e.open=!1),this.open=!1}confirmCancel(){let e=this._deployingDialogRef.value;e&&(e.open=!0,e.closeDisabled=!0,this._isInCancelConfirmation=!0,this._showIsCancelling=!1),this._showCancelConfirmation=!0}cancelDeployment(){this._isInCancelConfirmation&&this.abortController&&(this.deploymentProcessCancelled.emit(),this.abortController.abort(),this._showIsCancelling=!0,this._showCancelConfirmation=!1)}async load(){}render(){return s`<calcite-dialog close-disabled .heading=${this._translations.title.replace("{{solution}}",this.card?.title??"")} escape-disabled modal width=m .open=${this.open} @calciteDialogBeforeClose=${e=>{e.preventDefault(),this._confirmUnload=!1}} @calciteDialogOpen=${()=>this._onDialogOpen()} outside-close-disabled ${l(this._deployingDialogRef)}>${this._showCancelConfirmation?this.renderCancelModal():this._showIsCancelling?this.renderCancellingModal():s`<calcite-panel class="panel-bg-white">${this.isWaitingForCard?s`<calcite-loader .label=${this._translations.deploymentInProgress} scale=l type=indeterminate></calcite-loader><div class="loader-text" tabindex=0>${this._translations.deploymentInProgress}</div>`:s`<calcite-loader .label=${this._translations.deploymentInProgress} scale=l type=determinate-value .value=${this.deploymentProgress}></calcite-loader><div class="loader-text" tabindex=0>${this._translations.deploymentInProgress}</div>`}<div class="carousel-style">${h(this._carouselKey,s`<calcite-carousel .label=${this._translations.newsAndFeatures} arrow-type=inline ${l(this._carouselRef)}>${this.renderCarouselItems()}</calcite-carousel>`)}</div></calcite-panel>`}${!this._showCancelConfirmation&&!this._showIsCancelling&&s`<calcite-button appearance=outline @click=${this.confirmCancel} slot=footer-end>${this._translations.cancel}</calcite-button>`||""}${this._showCancelConfirmation&&s`<calcite-button kind=brand @click=${()=>{this._isInCancelConfirmation=!1,this._showCancelConfirmation=!1}} slot=footer-end>${this._translations.continueDeployment}</calcite-button><calcite-button appearance=outline @click=${this.cancelDeployment} slot=footer-end>${this._translations.cancelDeploymentButton}</calcite-button>`||""}</calcite-dialog>`}renderCarouselItems(){let e=[];return this._carouselMessages.forEach((t,p)=>{e.push(s`<calcite-carousel-item .label=${`carousel-item-${p}`}><calcite-label layout=inline scale=m>${t.icon&&s`<calcite-icon .icon=${t.icon} class="padding-end-0-5"></calcite-icon>`||""}<span .innerHTML=${this._processCarouselMessage(t)??""} tabindex=0></span></calcite-label></calcite-carousel-item>`)}),e}_getCarouselMessages(){let e=this._translations.carousel,t=[{message:e.stockMessage1,icon:"question"},{message:e.stockMessage2,icon:"model"},{message:e.stockMessage3,icon:"lightbulb"},{message:e.stockMessage4,icon:"information"},{message:e.stockMessage5,icon:"speech-bubbles"},{message:e.stockMessage6,icon:"information"}];return t.sort(()=>Math.random()-.5),t}_processCarouselMessage(e){let t=e.message||"";return t.includes("{{url}}")&&e.url&&(t=t.replace("{{url}}",e.url)),t}renderCancelModal(){return s`<calcite-panel class="panel-bg-white"><div tabindex=0>${this._translations.deploymentCancelMessage}</div></calcite-panel>`}renderCancellingModal(){return s`<calcite-panel class="panel-bg-white"><calcite-loader .label=${this._translations.cancelCurrentDeployment}></calcite-loader><div class="loader-text" tabindex=0>${this._translations.cancelCurrentDeployment}</div></calcite-panel>`}_onDialogOpen(){this._confirmUnload=!0,this._carouselKey++,this._translations.carousel&&(this._carouselMessages=this._getCarouselMessages()),this.deployingDialogOpened.emit(),setTimeout(()=>{let e=this._carouselRef.value;e&&e.play()},100)}};r("solution-deploying-dialog",o);export{o as a};
2
+ import{a as h}from"./4T7P5RXF.js";import{a as d}from"./Y3XY5BXI.js";import{b as r}from"./S7XOHDIW.js";import{F as i,G as l,H as c,h as n,i as s,r as a}from"./46DQNAMV.js";var g=n`*[tabindex]:focus-visible{outline:2px solid var(--calcite-color-brand);outline-offset:2px}.panel-bg-white{--calcite-panel-background-color: var(--calcite-color-foreground-1)}calcite-loader{--calcite-loader-spacing: var(--calcite-spacing-md)}.loader-text{margin-top:var(--calcite-spacing-sm);margin-bottom:var(--calcite-spacing-xxxl);text-align:center;font-size:var(--calcite-font-size-relative-base);color:var(--calcite-color-text-1)}.carousel-style{height:120px;display:flex;align-items:center}`,o=class extends c{constructor(){super(),this.deploymentProgress=0,this.open=!1,this.isWaitingForCard=!1,this._isInCancelConfirmation=!1,this._showCancelConfirmation=!1,this._showIsCancelling=!1,this._translations=d({name:"solution-deploying-dialog",blocking:!0}),this._carouselKey=0,this._deployingDialogRef=i(),this._carouselRef=i(),this._carouselMessages=[],this._confirmUnload=!1,this.deployingDialogOpened=a(),this.deploymentProcessCancelled=a(),this.listenOn(window,"beforeunload",e=>{(this._confirmUnload||this._showIsCancelling)&&(e.preventDefault(),e.returnValue=!0)})}static{this.properties={abortController:0,card:0,deploymentProgress:9,open:5,isWaitingForCard:5,_isInCancelConfirmation:16,_showCancelConfirmation:16,_showIsCancelling:16,_translations:16,_carouselKey:16}}static{this.styles=g}close(){this._showCancelConfirmation=!1,this._showIsCancelling=!1,this.isWaitingForCard=!1;let e=this._deployingDialogRef.value;e&&(e.open=!1),this.open=!1}confirmCancel(){let e=this._deployingDialogRef.value;e&&(e.open=!0,e.closeDisabled=!0,this._isInCancelConfirmation=!0,this._showIsCancelling=!1),this._showCancelConfirmation=!0}cancelDeployment(){this._isInCancelConfirmation&&this.abortController&&(this.deploymentProcessCancelled.emit(),this.abortController.abort(),this._showIsCancelling=!0,this._showCancelConfirmation=!1)}async load(){}render(){return s`<calcite-dialog close-disabled .heading=${this._translations.title.replace("{{solution}}",this.card?.title??"")} escape-disabled modal width=m .open=${this.open} @calciteDialogBeforeClose=${e=>{e.preventDefault(),this._confirmUnload=!1}} @calciteDialogOpen=${()=>this._onDialogOpen()} outside-close-disabled ${l(this._deployingDialogRef)}>${this._showCancelConfirmation?this.renderCancelModal():this._showIsCancelling?this.renderCancellingModal():s`<calcite-panel class="panel-bg-white">${this.isWaitingForCard?s`<calcite-loader .label=${this._translations.deploymentInProgress} scale=l type=indeterminate></calcite-loader><div class="loader-text" tabindex=0>${this._translations.deploymentInProgress}</div>`:s`<calcite-loader .label=${this._translations.deploymentInProgress} scale=l type=determinate-value .value=${this.deploymentProgress}></calcite-loader><div class="loader-text" tabindex=0>${this._translations.deploymentInProgress}</div>`}<div class="carousel-style">${h(this._carouselKey,s`<calcite-carousel .label=${this._translations.newsAndFeatures} arrow-type=inline ${l(this._carouselRef)}>${this.renderCarouselItems()}</calcite-carousel>`)}</div></calcite-panel>`}${!this._showCancelConfirmation&&!this._showIsCancelling&&s`<calcite-button appearance=outline @click=${this.confirmCancel} slot=footer-end>${this._translations.cancel}</calcite-button>`||""}${this._showCancelConfirmation&&s`<calcite-button kind=brand @click=${()=>{this._isInCancelConfirmation=!1,this._showCancelConfirmation=!1}} slot=footer-end>${this._translations.continueDeployment}</calcite-button><calcite-button appearance=outline @click=${this.cancelDeployment} slot=footer-end>${this._translations.cancelDeploymentButton}</calcite-button>`||""}</calcite-dialog>`}renderCarouselItems(){let e=[];return this._carouselMessages.forEach((t,p)=>{e.push(s`<calcite-carousel-item .label=${`carousel-item-${p}`}><calcite-label layout=inline scale=m>${t.icon&&s`<calcite-icon .icon=${t.icon} class="padding-end-0-5"></calcite-icon>`||""}<span .innerHTML=${this._processCarouselMessage(t)??""} tabindex=0></span></calcite-label></calcite-carousel-item>`)}),e}_getCarouselMessages(){let e=this._translations.carousel,t=[{message:e.stockMessage1,icon:"question"},{message:e.stockMessage2,icon:"model"},{message:e.stockMessage3,icon:"lightbulb"},{message:e.stockMessage4,icon:"information"},{message:e.stockMessage5,icon:"speech-bubbles"},{message:e.stockMessage6,icon:"information"}];return t.sort(()=>Math.random()-.5),t}_processCarouselMessage(e){let t=e.message||"";return t.includes("{{url}}")&&e.url&&(t=t.replace("{{url}}",e.url)),t}renderCancelModal(){return s`<calcite-panel class="panel-bg-white"><div tabindex=0>${this._translations.deploymentCancelMessage}</div></calcite-panel>`}renderCancellingModal(){return s`<calcite-panel class="panel-bg-white"><calcite-loader .label=${this._translations.cancelCurrentDeployment}></calcite-loader><div class="loader-text" tabindex=0>${this._translations.cancelCurrentDeployment}</div></calcite-panel>`}_onDialogOpen(){this._confirmUnload=!0,this._carouselKey++,this._translations.carousel&&(this._carouselMessages=this._getCarouselMessages()),this.deployingDialogOpened.emit(),setTimeout(()=>{let e=this._carouselRef.value;e&&e.play()},100)}};r("solution-deploying-dialog",o);export{o as a};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import a from"./JJUJVV7A.js";import{b as r}from"./PZ4L77M5.js";import{c as u}from"./LHCWS2RN.js";import"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import{b as l}from"./2CMRI2B3.js";import{H as o,h as s,i as n}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([{A:m,b:c}])=>{var h=s`*[tabindex]:focus-visible{outline:2px solid var(--calcite-color-brand);outline-offset:2px}.avatar-container{align-items:center;display:flex;flex-direction:row;padding-top:var(--calcite-spacing-lg)}.full-name{margin-inline-start:0px;font-size:var(--calcite-font-size--1);font-weight:var(--calcite-font-weight-medium);color:var(--calcite-navigation-user-full-name-text-color, var(--calcite-color-text-1))}.text-container{margin-block-start:.125rem;display:flex;flex-direction:column;padding-inline:1rem;text-align:start}.username{font-size:var(--calcite-font-size--1);color:var(--calcite-navigation-user-name-text-color, var(--calcite-color-text-2))}`,a=class extends o{constructor(){super(),this.lookupProfile=!1,this.username="",this._configContextConsumer=r({context:c,subscribe:!0}),this.listenOn(window,"sessionRefreshed",t=>{this._updateThumbnailToken(t.detail)})}static{this.properties={fullname:1,lookupProfile:5,thumbnailUrl:1,username:1}}static{this.styles=h}loaded(){this.lookupProfile&&this._lookupOwnerProfile(this.username)}willUpdate(t){t.has("username")&&this.lookupProfile&&this._lookupOwnerProfile(this.username)}render(){return n`<div class="avatar-container"><calcite-avatar scale=m .username=${this.username} .thumbnail=${this.thumbnailUrl??void 0} .fullName=${this.fullname??void 0}></calcite-avatar><div class="text-container"><span class="full-name" tabindex=0>${this.fullname??""}</span><span class="username" tabindex=0>${this.username}</span></div></div>`}async _lookupOwnerProfile(t){if(this.fullname=void 0,this.thumbnailUrl="",this.lookupProfile&&this._configContextConsumer.value){let{userSession:i}=this._configContextConsumer.value;if(i)try{let e=await u({authentication:i,username:t});e&&(e.fullName&&(this.fullname=e.fullName),e.thumbnail&&(this.thumbnailUrl=i.portal+"/community/users/"+e.id+"/info/"+e.thumbnail+"?token="+i.token))}catch{console.log("user not found")}}}_updateThumbnailToken(t){this.thumbnailUrl&&this.thumbnailUrl!==""&&(this.thumbnailUrl=m(this.thumbnailUrl,t))}};l("solution-user-avatar",a);return a},a)
2
+ import a from"./HHKKBJCY.js";import{b as r}from"./PZ4L77M5.js";import{d as u}from"./DD3JC2L3.js";import"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import{b as l}from"./S7XOHDIW.js";import{H as o,h as s,i as n}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([{A:m,b:c}])=>{var h=s`*[tabindex]:focus-visible{outline:2px solid var(--calcite-color-brand);outline-offset:2px}.avatar-container{align-items:center;display:flex;flex-direction:row;padding-top:var(--calcite-spacing-lg)}.full-name{margin-inline-start:0px;font-size:var(--calcite-font-size--1);font-weight:var(--calcite-font-weight-medium);color:var(--calcite-navigation-user-full-name-text-color, var(--calcite-color-text-1))}.text-container{margin-block-start:.125rem;display:flex;flex-direction:column;padding-inline:1rem;text-align:start}.username{font-size:var(--calcite-font-size--1);color:var(--calcite-navigation-user-name-text-color, var(--calcite-color-text-2))}`,a=class extends o{constructor(){super(),this.lookupProfile=!1,this.username="",this._configContextConsumer=r({context:c,subscribe:!0}),this.listenOn(window,"sessionRefreshed",t=>{this._updateThumbnailToken(t.detail)})}static{this.properties={fullname:1,lookupProfile:5,thumbnailUrl:1,username:1}}static{this.styles=h}loaded(){this.lookupProfile&&this._lookupOwnerProfile(this.username)}willUpdate(t){t.has("username")&&this.lookupProfile&&this._lookupOwnerProfile(this.username)}render(){return n`<div class="avatar-container"><calcite-avatar scale=m .username=${this.username} .thumbnail=${this.thumbnailUrl??void 0} .fullName=${this.fullname??void 0}></calcite-avatar><div class="text-container"><span class="full-name" tabindex=0>${this.fullname??""}</span><span class="username" tabindex=0>${this.username}</span></div></div>`}async _lookupOwnerProfile(t){if(this.fullname=void 0,this.thumbnailUrl="",this.lookupProfile&&this._configContextConsumer.value){let{userSession:i}=this._configContextConsumer.value;if(i)try{let e=await u({authentication:i,username:t});e&&(e.fullName&&(this.fullname=e.fullName),e.thumbnail&&(this.thumbnailUrl=i.portal+"/community/users/"+e.id+"/info/"+e.thumbnail+"?token="+i.token))}catch{console.log("user not found")}}}_updateThumbnailToken(t){this.thumbnailUrl&&this.thumbnailUrl!==""&&(this.thumbnailUrl=m(this.thumbnailUrl,t))}};l("solution-user-avatar",a);return a},a)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{b as n}from"./2CMRI2B3.js";import{F as m,G as r,H as o,h as t,i as p}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([l,h])=>{var d=t`.display-block{display:block}`,s=class extends o{constructor(){super(...arguments),this._basemapElement=m()}static{this.properties={mapView:0,basemapConfig:0,basemapWidget:0}}static{this.styles=d}willUpdate(a){a.has("basemapConfig")&&this.basemapConfigWatchHandler(),a.has("mapView")&&this.mapViewWatchHandler()}async basemapConfigWatchHandler(){if(this.basemapWidget?.source){let a=this.basemapWidget?.source;a.query=this.basemapConfig?.basemapGroupId?`id:${this.basemapConfig.basemapGroupId}`:null,await a.refresh()}}async mapViewWatchHandler(){this.mapView!==void 0&&await this.mapView.when(()=>{this._initBaseMapGallery(this.mapView)})}render(){return p`<div class="display-block" ${r(this._basemapElement)}></div>`}loaded(){this.mapView&&this.mapViewWatchHandler()}async _initBaseMapGallery(a){if(a){let e=new h({query:this.basemapConfig?.basemapGroupId?`id:${this.basemapConfig.basemapGroupId}`:null,filterFunction:this.basemapConfig?i=>i?.portalItem?.id&&this.basemapConfig?!this.basemapConfig.basemapIdsToFilter.includes(i?.portalItem?.id):!0:()=>!0});await e.refresh(),this.basemapWidget?(this.basemapWidget.view=a,this.basemapWidget.source=e):this.basemapWidget=new l({container:this._basemapElement.value,view:a,source:e})}}};n("map-basemap-gallery",s);return s},"widgets/BasemapGallery","widgets/BasemapGallery/support/PortalBasemapsSource")
2
+ import{b as n}from"./S7XOHDIW.js";import{F as m,G as r,H as o,h as t,i as p}from"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([l,h])=>{var d=t`.display-block{display:block}`,s=class extends o{constructor(){super(...arguments),this._basemapElement=m()}static{this.properties={mapView:0,basemapConfig:0,basemapWidget:0}}static{this.styles=d}willUpdate(a){a.has("basemapConfig")&&this.basemapConfigWatchHandler(),a.has("mapView")&&this.mapViewWatchHandler()}async basemapConfigWatchHandler(){if(this.basemapWidget?.source){let a=this.basemapWidget?.source;a.query=this.basemapConfig?.basemapGroupId?`id:${this.basemapConfig.basemapGroupId}`:null,await a.refresh()}}async mapViewWatchHandler(){this.mapView!==void 0&&await this.mapView.when(()=>{this._initBaseMapGallery(this.mapView)})}render(){return p`<div class="display-block" ${r(this._basemapElement)}></div>`}loaded(){this.mapView&&this.mapViewWatchHandler()}async _initBaseMapGallery(a){if(a){let e=new h({query:this.basemapConfig?.basemapGroupId?`id:${this.basemapConfig.basemapGroupId}`:null,filterFunction:this.basemapConfig?i=>i?.portalItem?.id&&this.basemapConfig?!this.basemapConfig.basemapIdsToFilter.includes(i?.portalItem?.id):!0:()=>!0});await e.refresh(),this.basemapWidget?(this.basemapWidget.view=a,this.basemapWidget.source=e):this.basemapWidget=new l({container:this._basemapElement.value,view:a,source:e})}}};n("map-basemap-gallery",s);return s},"widgets/BasemapGallery","widgets/BasemapGallery/support/PortalBasemapsSource")
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as r}from"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as n}from"./2CMRI2B3.js";import{H as o,h as l,i as a,r as i}from"./46DQNAMV.js";import"./OR4HXHSY.js";var c=l`:host{display:block}`,s=class extends o{constructor(){super(...arguments),this.ids=[],this.open=!1,this._isDeleting=!1,this._translations=r({name:"delete-dialog",blocking:!0}),this.editsComplete=i(),this.deleteDialogClose=i()}static{this.properties={ids:0,layer:0,open:5,_isDeleting:16,_translations:16}}static{this.styles=c}render(){let e=this.layer?.title||"",t=this.ids.length===1?(this._translations.confirmSingle||"").replace("{{layer-name}}",e):(this._translations.confirmMultiple||"").replace("{{layer-name}}",e);return a`<calcite-dialog .heading=${this._translations.deleteFeature} kind=danger modal @calciteDialogClose=${()=>this._close()} .open=${this.open} width=s><div>${t}</div><calcite-button appearance=outline kind=danger @click=${()=>this._close()} slot=footer-end width=full>${this._translations.cancel}</calcite-button><calcite-button kind=danger .loading=${this._isDeleting} @click=${()=>{this._deleteFeatures()}} slot=footer-end width=full>${this._translations.delete}</calcite-button></calcite-dialog>`}async _deleteFeatures(){if(this.layer){this._isDeleting=!0;let e=this.ids.map(t=>({objectId:Number(t)}));await this.layer.applyEdits({deleteFeatures:e}),this._isDeleting=!1,this._close(),this.editsComplete.emit("delete")}}_close(){this.open=!1,this.deleteDialogClose.emit()}};n("delete-dialog",s);export{s as DeleteDialog};
2
+ import{a as r}from"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as n}from"./S7XOHDIW.js";import{H as o,h as l,i as a,r as i}from"./46DQNAMV.js";import"./OR4HXHSY.js";var c=l`:host{display:block}`,s=class extends o{constructor(){super(...arguments),this.ids=[],this.open=!1,this._isDeleting=!1,this._translations=r({name:"delete-dialog",blocking:!0}),this.editsComplete=i(),this.deleteDialogClose=i()}static{this.properties={ids:0,layer:0,open:5,_isDeleting:16,_translations:16}}static{this.styles=c}render(){let e=this.layer?.title||"",t=this.ids.length===1?(this._translations.confirmSingle||"").replace("{{layer-name}}",e):(this._translations.confirmMultiple||"").replace("{{layer-name}}",e);return a`<calcite-dialog .heading=${this._translations.deleteFeature} kind=danger modal @calciteDialogClose=${()=>this._close()} .open=${this.open} width=s><div>${t}</div><calcite-button appearance=outline kind=danger @click=${()=>this._close()} slot=footer-end width=full>${this._translations.cancel}</calcite-button><calcite-button kind=danger .loading=${this._isDeleting} @click=${()=>{this._deleteFeatures()}} slot=footer-end width=full>${this._translations.delete}</calcite-button></calcite-dialog>`}async _deleteFeatures(){if(this.layer){this._isDeleting=!0;let e=this.ids.map(t=>({objectId:Number(t)}));await this.layer.applyEdits({deleteFeatures:e}),this._isDeleting=!1,this._close(),this.editsComplete.emit("delete")}}_close(){this.open=!1,this.deleteDialogClose.emit()}};n("delete-dialog",s);export{s as DeleteDialog};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import b from"./L4UMQNXD.js";import a from"./JJUJVV7A.js";import"./PZ4L77M5.js";import"./LHCWS2RN.js";import"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./2CMRI2B3.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,a])=>{return a},a,b)
2
+ import b from"./P6NSLBDS.js";import a from"./HHKKBJCY.js";import"./PZ4L77M5.js";import"./DD3JC2L3.js";import"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import"./AOBFPJ2R.js";import"./JK6XUSIM.js";import"./UPHYUDLT.js";import"./QJJXVRMV.js";import"./7FMLZNDR.js";import"./LL5C4DHP.js";import"./WPAMUSBR.js";import"./XJPOVJV7.js";import"./LDNQ56OK.js";import"./3HUY3T5F.js";import"./Z6G5PBUQ.js";import"./J3QMHA2M.js";import"./TKZAMPEI.js";import"./2IHQU2FX.js";import"./CGLFPVBM.js";import"./OEJAW72H.js";import"./5JJMGPOW.js";import"./TYX345MZ.js";import"./5UWT66A7.js";import"./S7XOHDIW.js";import"./46DQNAMV.js";import"./OR4HXHSY.js";export default $arcgis.t(([,a])=>{return a},a,b)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
2
- import{a as o}from"./HA5W44KL.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as d}from"./2CMRI2B3.js";import{H as n,h as l,i as e,l as a,r as t}from"./46DQNAMV.js";import"./OR4HXHSY.js";var h=l`:host{display:block}`,s=class extends n{constructor(){super(...arguments),this.buttonType="button",this.disabled=!1,this.ids=[],this.showDeleteCount=!0,this._confirmDelete=!1,this._deleteEndabled=!1,this._supportsDelete=!1,this._translations=o({name:"delete-button",blocking:!0}),this.editsComplete=t(),this.deleteClicked=t()}static{this.properties={deleteDialog:1,buttonType:1,disabled:5,icon:1,ids:0,layer:0,showDeleteCount:5,_confirmDelete:16,_deleteEndabled:16,_supportsDelete:16,_translations:16}}static{this.styles=h}willUpdate(i){i.has("ids")&&(this.hasUpdated||this.ids?.length>0)&&this.idsWatchHandler(),i.has("layer")&&this.layerWatchHandler()}async idsWatchHandler(){this._setDeleteEnabled()}async layerWatchHandler(){this._setDeleteEnabled()}render(){return e`${this.buttonType==="button"?e`<calcite-button appearance=outline .disabled=${!this._deleteEndabled} id=solutions-delete kind=danger @click=${()=>this._delete()} width=full>${this.showDeleteCount?this._translations.deleteCount?.replace("{{n}}",this.ids?.length.toString()):this._translations.delete}</calcite-button>`:e`<calcite-action appearance=solid .disabled=${!this._deleteEndabled} id=${this.icon??a} @click=${()=>this._delete()} scale=s .text=${this._translations.delete}><calcite-button appearance=transparent .iconStart=${this.icon} kind=danger>${this._translations.delete}</calcite-button></calcite-action>`}${this._deleteMessage()}<calcite-tooltip placement=bottom .referenceElement=${this.buttonType==="button"?"solutions-delete":this.icon}><span>${this._translations.delete}</span></calcite-tooltip>`}loaded(){this._setDeleteEnabled()}_setDeleteEnabled(){this._supportsDelete=!!(this.layer?.editingEnabled&&this.layer?.capabilities?.operations?.supportsDelete),this._deleteEndabled=!this.disabled||this._supportsDelete&&this.ids?.length>0}_delete(){this.deleteClicked.emit(),this._confirmDelete=!0}_deleteMessage(){return this.deleteDialog?this.deleteDialog:e`<delete-dialog id=solution-delete-dialog .ids=${this.ids} .layer=${this.layer} @deleteDialogClose=${()=>this._confirmDelete=!1} .open=${this._confirmDelete}></delete-dialog>`}};d("delete-button",s);export{s as DeleteButton};
2
+ import{a as o}from"./Y3XY5BXI.js";import"./36I27Q5R.js";import"./GDPFKW75.js";import{b as d}from"./S7XOHDIW.js";import{H as n,h as l,i as e,l as a,r as t}from"./46DQNAMV.js";import"./OR4HXHSY.js";var h=l`:host{display:block}`,s=class extends n{constructor(){super(...arguments),this.buttonType="button",this.disabled=!1,this.ids=[],this.showDeleteCount=!0,this._confirmDelete=!1,this._deleteEndabled=!1,this._supportsDelete=!1,this._translations=o({name:"delete-button",blocking:!0}),this.editsComplete=t(),this.deleteClicked=t()}static{this.properties={deleteDialog:1,buttonType:1,disabled:5,icon:1,ids:0,layer:0,showDeleteCount:5,_confirmDelete:16,_deleteEndabled:16,_supportsDelete:16,_translations:16}}static{this.styles=h}willUpdate(i){i.has("ids")&&(this.hasUpdated||this.ids?.length>0)&&this.idsWatchHandler(),i.has("layer")&&this.layerWatchHandler()}async idsWatchHandler(){this._setDeleteEnabled()}async layerWatchHandler(){this._setDeleteEnabled()}render(){return e`${this.buttonType==="button"?e`<calcite-button appearance=outline .disabled=${!this._deleteEndabled} id=solutions-delete kind=danger @click=${()=>this._delete()} width=full>${this.showDeleteCount?this._translations.deleteCount?.replace("{{n}}",this.ids?.length.toString()):this._translations.delete}</calcite-button>`:e`<calcite-action appearance=solid .disabled=${!this._deleteEndabled} id=${this.icon??a} @click=${()=>this._delete()} scale=s .text=${this._translations.delete}><calcite-button appearance=transparent .iconStart=${this.icon} kind=danger>${this._translations.delete}</calcite-button></calcite-action>`}${this._deleteMessage()}<calcite-tooltip placement=bottom .referenceElement=${this.buttonType==="button"?"solutions-delete":this.icon}><span>${this._translations.delete}</span></calcite-tooltip>`}loaded(){this._setDeleteEnabled()}_setDeleteEnabled(){this._supportsDelete=!!(this.layer?.editingEnabled&&this.layer?.capabilities?.operations?.supportsDelete),this._deleteEndabled=!this.disabled||this._supportsDelete&&this.ids?.length>0}_delete(){this.deleteClicked.emit(),this._confirmDelete=!0}_deleteMessage(){return this.deleteDialog?this.deleteDialog:e`<delete-dialog id=solution-delete-dialog .ids=${this.ids} .layer=${this.layer} @deleteDialogClose=${()=>this._confirmDelete=!1} .open=${this._confirmDelete}></delete-dialog>`}};d("delete-button",s);export{s as DeleteButton};