@esri/solutions-components 0.11.17 → 0.11.19

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 (333) hide show
  1. package/dist/cjs/{asyncToGenerator-c7fc3ee4.js → asyncToGenerator-f169429a.js} +1 -1
  2. package/dist/cjs/basemap-gallery_7.cjs.entry.js +50 -259
  3. package/dist/cjs/buffer-tools_2.cjs.entry.js +29 -123
  4. package/dist/cjs/card-manager_3.cjs.entry.js +215 -565
  5. package/dist/cjs/consent-manager.cjs.entry.js +15 -57
  6. package/dist/cjs/create-feature_4.cjs.entry.js +102 -256
  7. package/dist/cjs/create-related-feature_3.cjs.entry.js +38 -172
  8. package/dist/cjs/crowdsource-manager.cjs.entry.js +89 -267
  9. package/dist/cjs/crowdsource-reporter.cjs.entry.js +55 -219
  10. package/dist/cjs/deduct-calculator.cjs.entry.js +1 -1
  11. package/dist/cjs/delete-dialog.cjs.entry.js +9 -38
  12. package/dist/cjs/{downloadUtils-88ec0e88.js → downloadUtils-b269c7a1.js} +5 -5
  13. package/dist/cjs/{effects-3607d1ba.js → effects-2f75069e.js} +1 -1
  14. package/dist/cjs/feature-list.cjs.entry.js +30 -110
  15. package/dist/cjs/{helpers-a65cb83a.js → helpers-69e520bd.js} +3 -3
  16. package/dist/cjs/{index-2c21082d.js → index-af14245a.js} +346 -428
  17. package/dist/cjs/{index-90ef3c01.js → index-ffd12cb0.js} +1 -1
  18. package/dist/cjs/{index.es-3c2404c3.js → index.es-644259ff.js} +2 -2
  19. package/dist/cjs/instant-apps-app-guide.cjs.entry.js +5 -5
  20. package/dist/cjs/instant-apps-ckeditor-wrapper_3.cjs.entry.js +7 -7
  21. package/dist/cjs/instant-apps-control-panel.cjs.entry.js +3 -3
  22. package/dist/cjs/instant-apps-create.cjs.entry.js +5 -5
  23. package/dist/cjs/instant-apps-export-views.cjs.entry.js +5 -5
  24. package/dist/cjs/instant-apps-export.cjs.entry.js +5 -5
  25. package/dist/cjs/instant-apps-filter-list_2.cjs.entry.js +5 -5
  26. package/dist/cjs/instant-apps-header.cjs.entry.js +3 -3
  27. package/dist/cjs/instant-apps-interactive-legend-classic.cjs.entry.js +6 -6
  28. package/dist/cjs/instant-apps-interactive-legend-count_2.cjs.entry.js +6 -6
  29. package/dist/cjs/instant-apps-interactive-legend-group-legend-element-caption.cjs.entry.js +6 -6
  30. package/dist/cjs/instant-apps-interactive-legend-group-legend-element_5.cjs.entry.js +6 -6
  31. package/dist/cjs/instant-apps-interactive-legend.cjs.entry.js +8 -8
  32. package/dist/cjs/instant-apps-keyboard-shortcuts.cjs.entry.js +5 -5
  33. package/dist/cjs/instant-apps-landing-page.cjs.entry.js +1 -1
  34. package/dist/cjs/instant-apps-language-switcher.cjs.entry.js +8 -8
  35. package/dist/cjs/instant-apps-language-translator.cjs.entry.js +8 -8
  36. package/dist/cjs/instant-apps-measurement-tool.cjs.entry.js +3 -3
  37. package/dist/cjs/instant-apps-measurement.cjs.entry.js +5 -5
  38. package/dist/cjs/instant-apps-popover.cjs.entry.js +5 -5
  39. package/dist/cjs/instant-apps-popovers.cjs.entry.js +1 -1
  40. package/dist/cjs/instant-apps-scoreboard.cjs.entry.js +5 -5
  41. package/dist/cjs/instant-apps-sign-in.cjs.entry.js +5 -5
  42. package/dist/cjs/instant-apps-splash.cjs.entry.js +5 -5
  43. package/dist/cjs/instant-apps-time-filter.cjs.entry.js +7 -7
  44. package/dist/cjs/json-editor_7.cjs.entry.js +50 -228
  45. package/dist/cjs/{languageSwitcher-19a22439.js → languageSwitcher-c8e62594.js} +1 -1
  46. package/dist/cjs/{languageUtil-a3e1eafd.js → languageUtil-bd49af69.js} +1 -1
  47. package/dist/cjs/{loadModules-e9d8977c.js → loadModules-3b29fa24.js} +1 -1
  48. package/dist/cjs/loader.cjs.js +2 -2
  49. package/dist/cjs/{locale-c09e93fb.js → locale-905e6063.js} +2 -2
  50. package/dist/cjs/{locale-0a273172.js → locale-c923d7b6.js} +3 -3
  51. package/dist/cjs/map-layer-picker.cjs.entry.js +29 -114
  52. package/dist/cjs/map-select-tools_3.cjs.entry.js +53 -232
  53. package/dist/cjs/{mapViewUtils-319df9ec.js → mapViewUtils-4ea7216c.js} +0 -44
  54. package/dist/cjs/pci-calculator.cjs.entry.js +2 -15
  55. package/dist/cjs/{popupUtils-ca1127aa.js → popupUtils-5378e04a.js} +2 -2
  56. package/dist/cjs/public-notification.cjs.entry.js +47 -197
  57. package/dist/cjs/{publicNotificationStore-ee00411f.js → publicNotificationStore-beb782de.js} +1 -1
  58. package/dist/cjs/solution-configuration.cjs.entry.js +18 -53
  59. package/dist/cjs/solution-contents_3.cjs.entry.js +19 -85
  60. package/dist/cjs/solution-item-accordion.cjs.entry.js +15 -42
  61. package/dist/cjs/solution-item-icon.cjs.entry.js +4 -18
  62. package/dist/cjs/{solution-store-6208ce28.js → solution-store-3cf25b71.js} +1 -1
  63. package/dist/cjs/solutions-components.cjs.js +3 -3
  64. package/dist/cjs/spatial-ref.cjs.entry.js +11 -46
  65. package/dist/cjs/store-manager.cjs.entry.js +6 -21
  66. package/dist/cjs/{utils-30344ce0.js → utils-3739960f.js} +2 -2
  67. package/dist/collection/assets/t9n/crowdsource-manager/resources.json +4 -1
  68. package/dist/collection/assets/t9n/crowdsource-manager/resources_en.json +4 -1
  69. package/dist/collection/assets/t9n/solution-item-accordion/resources.json +1 -1
  70. package/dist/collection/assets/t9n/solution-item-accordion/resources_en.json +1 -1
  71. package/dist/collection/collection-manifest.json +1 -1
  72. package/dist/collection/components/basemap-gallery/basemap-gallery.js +5 -19
  73. package/dist/collection/components/buffer-tools/buffer-tools.js +13 -52
  74. package/dist/collection/components/card-manager/card-manager.js +18 -72
  75. package/dist/collection/components/consent-manager/consent-manager.js +12 -52
  76. package/dist/collection/components/create-feature/create-feature.js +16 -68
  77. package/dist/collection/components/create-related-feature/create-related-feature.js +10 -44
  78. package/dist/collection/components/crowdsource-manager/crowdsource-manager.css +23 -0
  79. package/dist/collection/components/crowdsource-manager/crowdsource-manager.js +88 -263
  80. package/dist/collection/components/crowdsource-reporter/crowdsource-reporter.js +53 -215
  81. package/dist/collection/components/delete-button/delete-button.js +13 -55
  82. package/dist/collection/components/delete-dialog/delete-dialog.js +8 -35
  83. package/dist/collection/components/edit-card/edit-card.js +10 -43
  84. package/dist/collection/components/feature-details/feature-details.js +18 -74
  85. package/dist/collection/components/feature-list/feature-list.js +25 -103
  86. package/dist/collection/components/floor-filter/floor-filter.js +5 -19
  87. package/dist/collection/components/info-card/info-card.js +100 -84
  88. package/dist/collection/components/json-editor/json-editor.js +7 -28
  89. package/dist/collection/components/layer-list/layer-list.js +12 -50
  90. package/dist/collection/components/layer-table/layer-table.js +188 -308
  91. package/dist/collection/components/map-card/map-card.js +43 -182
  92. package/dist/collection/components/map-draw-tools/map-draw-tools.js +15 -66
  93. package/dist/collection/components/map-fullscreen/map-fullscreen.js +4 -18
  94. package/dist/collection/components/map-layer-picker/map-layer-picker.js +25 -108
  95. package/dist/collection/components/map-legend/map-legend.js +4 -15
  96. package/dist/collection/components/map-picker/map-picker.js +8 -35
  97. package/dist/collection/components/map-search/map-search.js +8 -35
  98. package/dist/collection/components/map-select-tools/map-select-tools.js +32 -138
  99. package/dist/collection/components/map-tools/map-tools.js +27 -115
  100. package/dist/collection/components/pci-calculator/pci-calculator.js +3 -14
  101. package/dist/collection/components/pdf-download/pdf-download.js +6 -27
  102. package/dist/collection/components/public-notification/public-notification.js +41 -189
  103. package/dist/collection/components/refine-selection/refine-selection.js +13 -59
  104. package/dist/collection/components/solution-configuration/solution-configuration.js +13 -48
  105. package/dist/collection/components/solution-contents/solution-contents.js +4 -13
  106. package/dist/collection/components/solution-item/solution-item.js +9 -36
  107. package/dist/collection/components/solution-item-accordion/solution-item-accordion.js +19 -40
  108. package/dist/collection/components/solution-item-details/solution-item-details.js +16 -35
  109. package/dist/collection/components/solution-item-icon/solution-item-icon.js +5 -17
  110. package/dist/collection/components/solution-item-sharing/solution-item-sharing.js +6 -27
  111. package/dist/collection/components/solution-organization-variables/solution-organization-variables.js +6 -24
  112. package/dist/collection/components/solution-resource-item/solution-resource-item.js +8 -36
  113. package/dist/collection/components/solution-spatial-ref/solution-spatial-ref.js +7 -31
  114. package/dist/collection/components/solution-template-data/solution-template-data.js +8 -49
  115. package/dist/collection/components/solution-variables/solution-variables.js +6 -24
  116. package/dist/collection/components/spatial-ref/spatial-ref.js +8 -43
  117. package/dist/collection/components/store-manager/store-manager.js +5 -18
  118. package/dist/components/basemap-gallery2.js +3 -19
  119. package/dist/components/buffer-tools2.js +11 -52
  120. package/dist/components/card-manager2.js +16 -72
  121. package/dist/components/consent-manager.js +10 -52
  122. package/dist/components/create-feature2.js +14 -68
  123. package/dist/components/create-related-feature2.js +8 -44
  124. package/dist/components/crowdsource-manager.js +87 -264
  125. package/dist/components/crowdsource-reporter.js +51 -215
  126. package/dist/components/delete-button2.js +11 -55
  127. package/dist/components/delete-dialog2.js +6 -35
  128. package/dist/components/edit-card2.js +8 -43
  129. package/dist/components/feature-details2.js +16 -74
  130. package/dist/components/feature-list2.js +23 -103
  131. package/dist/components/floor-filter2.js +3 -19
  132. package/dist/components/info-card2.js +64 -83
  133. package/dist/components/json-editor2.js +5 -28
  134. package/dist/components/layer-list2.js +10 -50
  135. package/dist/components/layer-table2.js +155 -307
  136. package/dist/components/map-card2.js +41 -182
  137. package/dist/components/map-draw-tools2.js +13 -66
  138. package/dist/components/map-fullscreen2.js +2 -18
  139. package/dist/components/map-layer-picker2.js +23 -108
  140. package/dist/components/map-legend2.js +2 -15
  141. package/dist/components/map-picker2.js +6 -35
  142. package/dist/components/map-search2.js +6 -35
  143. package/dist/components/map-select-tools2.js +31 -139
  144. package/dist/components/map-tools2.js +25 -115
  145. package/dist/components/pci-calculator.js +1 -14
  146. package/dist/components/pdf-download2.js +4 -27
  147. package/dist/components/public-notification.js +39 -189
  148. package/dist/components/queryUtils.js +1 -43
  149. package/dist/components/refine-selection2.js +12 -60
  150. package/dist/components/solution-configuration.js +13 -48
  151. package/dist/components/solution-contents2.js +2 -13
  152. package/dist/components/solution-item-accordion.js +12 -39
  153. package/dist/components/solution-item-details2.js +14 -35
  154. package/dist/components/solution-item-icon2.js +3 -17
  155. package/dist/components/solution-item-sharing2.js +4 -27
  156. package/dist/components/solution-item2.js +7 -36
  157. package/dist/components/solution-organization-variables2.js +4 -24
  158. package/dist/components/solution-resource-item2.js +6 -36
  159. package/dist/components/solution-spatial-ref2.js +5 -31
  160. package/dist/components/solution-template-data2.js +8 -49
  161. package/dist/components/solution-variables2.js +4 -24
  162. package/dist/components/spatial-ref.js +8 -43
  163. package/dist/components/store-manager.js +3 -18
  164. package/dist/esm/{asyncToGenerator-96b2368d.js → asyncToGenerator-e51717ed.js} +1 -1
  165. package/dist/esm/basemap-gallery_7.entry.js +50 -259
  166. package/dist/esm/buffer-tools_2.entry.js +29 -123
  167. package/dist/esm/card-manager_3.entry.js +215 -565
  168. package/dist/esm/consent-manager.entry.js +15 -57
  169. package/dist/esm/create-feature_4.entry.js +102 -256
  170. package/dist/esm/create-related-feature_3.entry.js +38 -172
  171. package/dist/esm/crowdsource-manager.entry.js +89 -267
  172. package/dist/esm/crowdsource-reporter.entry.js +55 -219
  173. package/dist/esm/deduct-calculator.entry.js +1 -1
  174. package/dist/esm/delete-dialog.entry.js +9 -38
  175. package/dist/esm/{downloadUtils-22a8f2d8.js → downloadUtils-d04d4095.js} +5 -5
  176. package/dist/esm/{effects-38bc1195.js → effects-602e7b51.js} +1 -1
  177. package/dist/esm/feature-list.entry.js +30 -110
  178. package/dist/esm/{helpers-77bdd30e.js → helpers-520f100c.js} +3 -3
  179. package/dist/esm/{index-6de7c296.js → index-c247b62b.js} +1 -1
  180. package/dist/esm/{index-3702583a.js → index-df5db8e9.js} +346 -428
  181. package/dist/esm/{index.es-87662946.js → index.es-ca80d0c5.js} +2 -2
  182. package/dist/esm/instant-apps-app-guide.entry.js +5 -5
  183. package/dist/esm/instant-apps-ckeditor-wrapper_3.entry.js +7 -7
  184. package/dist/esm/instant-apps-control-panel.entry.js +3 -3
  185. package/dist/esm/instant-apps-create.entry.js +5 -5
  186. package/dist/esm/instant-apps-export-views.entry.js +5 -5
  187. package/dist/esm/instant-apps-export.entry.js +5 -5
  188. package/dist/esm/instant-apps-filter-list_2.entry.js +5 -5
  189. package/dist/esm/instant-apps-header.entry.js +3 -3
  190. package/dist/esm/instant-apps-interactive-legend-classic.entry.js +6 -6
  191. package/dist/esm/instant-apps-interactive-legend-count_2.entry.js +6 -6
  192. package/dist/esm/instant-apps-interactive-legend-group-legend-element-caption.entry.js +6 -6
  193. package/dist/esm/instant-apps-interactive-legend-group-legend-element_5.entry.js +6 -6
  194. package/dist/esm/instant-apps-interactive-legend.entry.js +8 -8
  195. package/dist/esm/instant-apps-keyboard-shortcuts.entry.js +5 -5
  196. package/dist/esm/instant-apps-landing-page.entry.js +1 -1
  197. package/dist/esm/instant-apps-language-switcher.entry.js +8 -8
  198. package/dist/esm/instant-apps-language-translator.entry.js +8 -8
  199. package/dist/esm/instant-apps-measurement-tool.entry.js +3 -3
  200. package/dist/esm/instant-apps-measurement.entry.js +5 -5
  201. package/dist/esm/instant-apps-popover.entry.js +5 -5
  202. package/dist/esm/instant-apps-popovers.entry.js +1 -1
  203. package/dist/esm/instant-apps-scoreboard.entry.js +5 -5
  204. package/dist/esm/instant-apps-sign-in.entry.js +5 -5
  205. package/dist/esm/instant-apps-splash.entry.js +5 -5
  206. package/dist/esm/instant-apps-time-filter.entry.js +7 -7
  207. package/dist/esm/json-editor_7.entry.js +50 -228
  208. package/dist/esm/{languageSwitcher-49bad3f4.js → languageSwitcher-ccdf79d4.js} +1 -1
  209. package/dist/esm/{languageUtil-2b6e191a.js → languageUtil-2bac3910.js} +1 -1
  210. package/dist/esm/{loadModules-947ccfd4.js → loadModules-1b0b108c.js} +1 -1
  211. package/dist/esm/loader.js +3 -3
  212. package/dist/esm/{locale-aa656a2c.js → locale-15e42305.js} +2 -2
  213. package/dist/esm/{locale-b0016f8e.js → locale-29d08ded.js} +3 -3
  214. package/dist/esm/map-layer-picker.entry.js +29 -114
  215. package/dist/esm/map-select-tools_3.entry.js +53 -232
  216. package/dist/esm/{mapViewUtils-a854e298.js → mapViewUtils-9da9be1c.js} +1 -43
  217. package/dist/esm/pci-calculator.entry.js +2 -15
  218. package/dist/esm/{popupUtils-1314cb13.js → popupUtils-b71abb01.js} +2 -2
  219. package/dist/esm/public-notification.entry.js +47 -197
  220. package/dist/esm/{publicNotificationStore-70219049.js → publicNotificationStore-9ec5e22a.js} +1 -1
  221. package/dist/esm/solution-configuration.entry.js +18 -53
  222. package/dist/esm/solution-contents_3.entry.js +19 -85
  223. package/dist/esm/solution-item-accordion.entry.js +15 -42
  224. package/dist/esm/solution-item-icon.entry.js +4 -18
  225. package/dist/esm/{solution-store-2493275a.js → solution-store-4c39c654.js} +1 -1
  226. package/dist/esm/solutions-components.js +4 -4
  227. package/dist/esm/spatial-ref.entry.js +11 -46
  228. package/dist/esm/store-manager.entry.js +6 -21
  229. package/dist/esm/{utils-68015f9d.js → utils-89be1743.js} +2 -2
  230. package/dist/solutions-components/assets/t9n/crowdsource-manager/resources.json +4 -1
  231. package/dist/solutions-components/assets/t9n/crowdsource-manager/resources_en.json +4 -1
  232. package/dist/solutions-components/assets/t9n/solution-item-accordion/resources.json +1 -1
  233. package/dist/solutions-components/assets/t9n/solution-item-accordion/resources_en.json +1 -1
  234. package/dist/solutions-components/{p-68d49e1a.entry.js → p-0132213f.entry.js} +2 -2
  235. package/dist/solutions-components/{p-dc188d13.js → p-039ab075.js} +1 -1
  236. package/dist/solutions-components/p-04277d48.entry.js +6 -0
  237. package/dist/solutions-components/p-04546ef6.js +6 -0
  238. package/dist/solutions-components/{p-174fa218.js → p-0607044f.js} +1 -1
  239. package/dist/solutions-components/p-099379e6.entry.js +6 -0
  240. package/dist/solutions-components/{p-300ff31e.entry.js → p-0b1c830a.entry.js} +1 -1
  241. package/dist/solutions-components/{p-ff5db601.entry.js → p-0ea99464.entry.js} +1 -1
  242. package/dist/solutions-components/p-1054e10a.entry.js +6 -0
  243. package/dist/solutions-components/p-1adc6874.entry.js +6 -0
  244. package/dist/solutions-components/{p-3c3aecdd.js → p-258aa58e.js} +1 -1
  245. package/dist/solutions-components/p-29baf8a2.entry.js +6 -0
  246. package/dist/solutions-components/{p-eb97b5ad.entry.js → p-2a1ed83a.entry.js} +1 -1
  247. package/dist/solutions-components/{p-8107be38.entry.js → p-2a7f23fc.entry.js} +1 -1
  248. package/dist/solutions-components/{p-6da8fe2d.entry.js → p-2cb8c175.entry.js} +1 -1
  249. package/dist/solutions-components/p-2d3b8412.entry.js +6 -0
  250. package/dist/solutions-components/p-2d8300ba.entry.js +6 -0
  251. package/dist/solutions-components/{p-ac122d9e.js → p-3423b5ef.js} +1 -1
  252. package/dist/solutions-components/{p-fa09caf3.entry.js → p-34338938.entry.js} +1 -1
  253. package/dist/solutions-components/{p-4f514c6d.js → p-36e3b39c.js} +2 -2
  254. package/dist/solutions-components/{p-ea64b72e.entry.js → p-37cc79c6.entry.js} +1 -1
  255. package/dist/solutions-components/p-38814554.entry.js +6 -0
  256. package/dist/solutions-components/{p-ee863ffb.entry.js → p-3f8b1062.entry.js} +1 -1
  257. package/dist/solutions-components/p-436b869c.entry.js +6 -0
  258. package/dist/solutions-components/{p-08ad0b7a.js → p-438fdc33.js} +1 -1
  259. package/dist/solutions-components/{p-335a630e.entry.js → p-4454af38.entry.js} +1 -1
  260. package/dist/solutions-components/p-532ed572.entry.js +6 -0
  261. package/dist/solutions-components/{p-959cb673.entry.js → p-552fb1c0.entry.js} +1 -1
  262. package/dist/solutions-components/{p-b560498c.entry.js → p-59a1c5a9.entry.js} +1 -1
  263. package/dist/solutions-components/p-5e4e0f84.entry.js +6 -0
  264. package/dist/solutions-components/{p-2b556610.entry.js → p-64a6162f.entry.js} +1 -1
  265. package/dist/solutions-components/{p-e85da876.entry.js → p-6ac03d17.entry.js} +1 -1
  266. package/dist/solutions-components/p-6e879de9.entry.js +6 -0
  267. package/dist/solutions-components/{p-8f7957a2.js → p-7bf7d67b.js} +1 -1
  268. package/dist/solutions-components/{p-81ae30bd.entry.js → p-86b6f918.entry.js} +1 -1
  269. package/dist/solutions-components/{p-e23b4193.js → p-8717729a.js} +1 -1
  270. package/dist/solutions-components/{p-e81e2d83.entry.js → p-8db12ee9.entry.js} +2 -2
  271. package/dist/solutions-components/{p-173d5fce.js → p-8f973b3d.js} +1 -1
  272. package/dist/solutions-components/{p-1ddd7128.entry.js → p-97abbf8f.entry.js} +1 -1
  273. package/dist/solutions-components/{p-ee2cbba0.js → p-a397e773.js} +1 -1
  274. package/dist/solutions-components/p-b636a8b4.entry.js +6 -0
  275. package/dist/solutions-components/{p-1890b884.entry.js → p-b6a6fdcf.entry.js} +2 -2
  276. package/dist/solutions-components/p-b8f29a99.entry.js +6 -0
  277. package/dist/solutions-components/p-ba472e45.entry.js +6 -0
  278. package/dist/solutions-components/{p-1dffcc22.entry.js → p-c3aac15b.entry.js} +1 -1
  279. package/dist/solutions-components/{p-3d20e307.js → p-cd38fc53.js} +1 -1
  280. package/dist/solutions-components/p-d45b0400.entry.js +6 -0
  281. package/dist/solutions-components/p-d885880a.entry.js +6 -0
  282. package/dist/solutions-components/{p-8b218ba7.js → p-da1e098c.js} +1 -1
  283. package/dist/solutions-components/{p-b40b5be5.entry.js → p-da1e4ff1.entry.js} +1 -1
  284. package/dist/solutions-components/p-dbf2c455.entry.js +6 -0
  285. package/dist/solutions-components/{p-952da957.js → p-dcd2f00b.js} +2 -2
  286. package/dist/solutions-components/{p-2c8360b4.entry.js → p-dda0aa41.entry.js} +1 -1
  287. package/dist/solutions-components/{p-70e8be5c.entry.js → p-e3e35c14.entry.js} +1 -1
  288. package/dist/solutions-components/{p-48942eb8.js → p-e6859850.js} +2 -2
  289. package/dist/solutions-components/{p-699a9557.entry.js → p-e79b69e6.entry.js} +1 -1
  290. package/dist/solutions-components/p-e996c38f.js +7 -0
  291. package/dist/solutions-components/{p-f07a02e2.entry.js → p-edfcce2c.entry.js} +1 -1
  292. package/dist/solutions-components/{p-2dcf8f00.entry.js → p-f292f56e.entry.js} +1 -1
  293. package/dist/solutions-components/{p-4bdd4009.entry.js → p-f36b4778.entry.js} +1 -1
  294. package/dist/solutions-components/{p-579628d9.entry.js → p-f457e8be.entry.js} +1 -1
  295. package/dist/solutions-components/{p-d65f8b73.js → p-f93a9d92.js} +1 -1
  296. package/dist/solutions-components/p-f99a78f1.entry.js +6 -0
  297. package/dist/solutions-components/{p-7f6cbe61.entry.js → p-fdf0d66f.entry.js} +1 -1
  298. package/dist/solutions-components/solutions-components.esm.js +1 -1
  299. package/dist/solutions-components_commit.txt +7 -7
  300. package/dist/types/components/crowdsource-manager/crowdsource-manager.d.ts +11 -7
  301. package/dist/types/components/info-card/info-card.d.ts +16 -0
  302. package/dist/types/components/layer-table/layer-table.d.ts +32 -21
  303. package/dist/types/components/solution-item-accordion/solution-item-accordion.d.ts +1 -1
  304. package/dist/types/components.d.ts +19 -2
  305. package/dist/types/preact.d.ts +2 -1
  306. package/package.json +2 -2
  307. package/dist/solutions-components/p-032d4411.entry.js +0 -6
  308. package/dist/solutions-components/p-1b0588d2.js +0 -7
  309. package/dist/solutions-components/p-1fe3577a.entry.js +0 -6
  310. package/dist/solutions-components/p-265f5dc4.entry.js +0 -6
  311. package/dist/solutions-components/p-43d9bb7d.entry.js +0 -6
  312. package/dist/solutions-components/p-4426901e.entry.js +0 -6
  313. package/dist/solutions-components/p-4ebc471b.entry.js +0 -6
  314. package/dist/solutions-components/p-5ea1e18b.entry.js +0 -6
  315. package/dist/solutions-components/p-6d62a4fa.entry.js +0 -6
  316. package/dist/solutions-components/p-70036eb6.entry.js +0 -6
  317. package/dist/solutions-components/p-87919d6d.entry.js +0 -6
  318. package/dist/solutions-components/p-89fbc318.js +0 -6
  319. package/dist/solutions-components/p-8ea0a36a.entry.js +0 -6
  320. package/dist/solutions-components/p-9d953313.entry.js +0 -6
  321. package/dist/solutions-components/p-a003600b.entry.js +0 -6
  322. package/dist/solutions-components/p-acd2699e.entry.js +0 -6
  323. package/dist/solutions-components/p-afc3ac6d.entry.js +0 -6
  324. package/dist/solutions-components/p-b37be371.entry.js +0 -6
  325. package/dist/solutions-components/p-bc2548ba.entry.js +0 -6
  326. package/dist/solutions-components/p-bf2598f8.entry.js +0 -6
  327. package/dist/solutions-components/p-ce8377c6.entry.js +0 -6
  328. /package/dist/cjs/{esri-loader-08dc41bd.js → esri-loader-1e8cc247.js} +0 -0
  329. /package/dist/cjs/{typeof-2a7e2dec.js → typeof-eba0a941.js} +0 -0
  330. /package/dist/esm/{esri-loader-c6842c6b.js → esri-loader-d10d860d.js} +0 -0
  331. /package/dist/esm/{typeof-ef2a007d.js → typeof-a3e780e1.js} +0 -0
  332. /package/dist/solutions-components/{p-4fe489cf.js → p-19bce2cc.js} +0 -0
  333. /package/dist/solutions-components/{p-0a24ad5f.js → p-3b3f77bc.js} +0 -0
@@ -193,10 +193,6 @@ export declare class LayerTable {
193
193
  * IColumnsInfo: Key/value pair with fieldname/(visible in table)
194
194
  */
195
195
  protected _columnsInfo: IColumnsInfo;
196
- /**
197
- * boolean: When true the ctrl key is currently pressed
198
- */
199
- protected _ctrlIsPressed: boolean;
200
196
  /**
201
197
  * number: The id of the most recently selected row from the table
202
198
  */
@@ -302,18 +298,10 @@ export declare class LayerTable {
302
298
  * HTMLInstantAppsSocialShareElement: Element to support app sharing to social media
303
299
  */
304
300
  protected _shareNode: HTMLInstantAppsSocialShareElement;
305
- /**
306
- * boolean: When true the shift key is currently pressed
307
- */
308
- protected _shiftIsPressed: boolean;
309
301
  /**
310
302
  * HTMLCalciteDropdownElement: Dropdown the will support show/hide of table columns
311
303
  */
312
304
  protected _showHideDropdown: HTMLCalciteDropdownElement;
313
- /**
314
- * boolean: When true any onChange handeling will be skipped
315
- */
316
- protected _skipOnChange: boolean;
317
305
  /**
318
306
  * HTMLCalciteDropdownElement: Dropdown the will support overflow tools that won't fit in the current display
319
307
  */
@@ -346,10 +334,22 @@ export declare class LayerTable {
346
334
  * boolean: When true we will not evaluate if the editor has any pending edits
347
335
  */
348
336
  protected _skipEditCheck: boolean;
337
+ /**
338
+ * __esri.Handle: handle for the filter by extent
339
+ */
340
+ protected _filterByExtentHandle: __esri.Handle;
349
341
  /**
350
342
  * number[]: selected features from table
351
343
  */
352
344
  protected _tempSelectedIds: number[];
345
+ /**
346
+ * number[]: out of extent oids which are selected but now out of extent
347
+ */
348
+ protected _outOFExtentOids: number[];
349
+ /**
350
+ * boolean: When true allow table to update the records
351
+ */
352
+ protected _shouldUpdateTableOnExtentChange: boolean;
353
353
  /**
354
354
  * Update the url params when the appLayout changes
355
355
  */
@@ -417,7 +417,11 @@ export declare class LayerTable {
417
417
  /**
418
418
  * Updates the filter
419
419
  */
420
- filterUpdate(active: boolean): Promise<void>;
420
+ filterUpdate(filterActive: boolean, keepTableUpdatingOnMapExtentChange?: boolean): Promise<void>;
421
+ /**
422
+ * Validate if the table should update
423
+ */
424
+ validateTableUpdate(shouldUpdateTableOnExtentChange: boolean): Promise<void>;
421
425
  /**
422
426
  * Validate if the editor has any pending edits
423
427
  */
@@ -450,6 +454,12 @@ export declare class LayerTable {
450
454
  * @returns a promise when the operation has completed
451
455
  */
452
456
  editorInitialized(evt: CustomEvent): Promise<void>;
457
+ /**
458
+ * Respond to and close the edit record display
459
+ *
460
+ * @returns a promise when the operation has completed
461
+ */
462
+ closeEdit(): Promise<void>;
453
463
  /**
454
464
  * Scroll and zoom to the selected feature from the Features widget.
455
465
  *
@@ -808,14 +818,6 @@ export declare class LayerTable {
808
818
  * @protected
809
819
  */
810
820
  protected _handleDocumentClick(e: MouseEvent): void;
811
- /**
812
- * Keep track of key down for ctrl and shift
813
- */
814
- protected _handleKeyDown(e: KeyboardEvent): void;
815
- /**
816
- * Keep track of key up for ctrl and shift
817
- */
818
- protected _handleKeyUp(e: KeyboardEvent): void;
819
821
  /**
820
822
  * Show filter component in modal
821
823
  *
@@ -833,11 +835,20 @@ export declare class LayerTable {
833
835
  * @protected
834
836
  */
835
837
  protected _handleFilterUpdate(active: boolean): Promise<void>;
838
+ /**
839
+ * Update the table when extent is changed
840
+ */
841
+ protected _handleTableOnMapExtent(): void;
836
842
  /**
837
843
  * Close the filter modal
838
844
  * @protected
839
845
  */
840
846
  protected _closeFilter(): Promise<void>;
847
+ /**
848
+ * Query the layer for applied filter
849
+ * @returns Promise with the featureSet from the layer that match the provided ids
850
+ */
851
+ protected queryAllIds(): Promise<number[]>;
841
852
  /**
842
853
  * Handle map click events to keep table and map click selection in sync
843
854
  *
@@ -53,7 +53,7 @@ export declare class SolutionItemAccordion {
53
53
  localeWatchHandler(): Promise<void>;
54
54
  templateInfosWatchHandler(): Promise<void>;
55
55
  /**
56
- * Deselect all items in the accordion.
56
+ * Deselects all items in the accordion and closes the accordion item containing it.
57
57
  * Only applies when selectionMode is "single" or "single-persist".
58
58
  */
59
59
  deselectAll(): Promise<void>;
@@ -814,6 +814,10 @@ export namespace Components {
814
814
  * @returns Promise when complete
815
815
  */
816
816
  "refresh": () => Promise<any>;
817
+ /**
818
+ * boolean: If true show close button on the feature info
819
+ */
820
+ "showCloseBtn"?: boolean;
817
821
  /**
818
822
  * Toggle the visibility of the features list view
819
823
  */
@@ -948,7 +952,7 @@ export namespace Components {
948
952
  /**
949
953
  * Updates the filter
950
954
  */
951
- "filterUpdate": (active: boolean) => Promise<void>;
955
+ "filterUpdate": (filterActive: boolean, keepTableUpdatingOnMapExtentChange?: boolean) => Promise<void>;
952
956
  /**
953
957
  * boolean: when true we will honor field order and visibility that may have been defined in the map viewer if no field order is defined in the mapInfo. Field order defined in the mapInfo as would be the case for Instant App configurations will always override this map level setting.
954
958
  */
@@ -1001,6 +1005,10 @@ export namespace Components {
1001
1005
  * Validate if the editor has any pending edits
1002
1006
  */
1003
1007
  "validateActiveEdits": () => Promise<boolean>;
1008
+ /**
1009
+ * Validate if the table should update
1010
+ */
1011
+ "validateTableUpdate": (shouldUpdateTableOnExtentChange: boolean) => Promise<void>;
1004
1012
  /**
1005
1013
  * boolean: When true the selected feature will zoomed to in the map and the row will be scrolled to within the table
1006
1014
  */
@@ -1788,7 +1796,7 @@ export namespace Components {
1788
1796
  }
1789
1797
  interface SolutionItemAccordion {
1790
1798
  /**
1791
- * Deselect all items in the accordion. Only applies when selectionMode is "single" or "single-persist".
1799
+ * Deselects all items in the accordion and closes the accordion item containing it. Only applies when selectionMode is "single" or "single-persist".
1792
1800
  */
1793
1801
  "deselectAll": () => Promise<void>;
1794
1802
  /**
@@ -2380,6 +2388,7 @@ declare global {
2380
2388
  };
2381
2389
  interface HTMLInfoCardElementEventMap {
2382
2390
  "popupClosed": void;
2391
+ "clearSelection": void;
2383
2392
  "selectionChanged": { selectedFeature: __esri.Graphic[], selectedFeatureIndex: number };
2384
2393
  }
2385
2394
  interface HTMLInfoCardElement extends Components.InfoCard, HTMLStencilElement {
@@ -3703,6 +3712,10 @@ declare namespace LocalJSX {
3703
3712
  * esri/views/MapView: https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html
3704
3713
  */
3705
3714
  "mapView"?: __esri.MapView;
3715
+ /**
3716
+ * Emitted on demand when close button is clicked
3717
+ */
3718
+ "onClearSelection"?: (event: InfoCardCustomEvent<void>) => void;
3706
3719
  /**
3707
3720
  * Emitted on demand when the popup is closed
3708
3721
  */
@@ -3719,6 +3732,10 @@ declare namespace LocalJSX {
3719
3732
  * string: Set the position of the feature info
3720
3733
  */
3721
3734
  "position"?: string;
3735
+ /**
3736
+ * boolean: If true show close button on the feature info
3737
+ */
3738
+ "showCloseBtn"?: boolean;
3722
3739
  }
3723
3740
  interface JsonEditor {
3724
3741
  /**
@@ -87,8 +87,9 @@ declare module "preact/src/jsx" {
87
87
  "onsiteChanged"?: (event: CustomEvent<any>) => void;
88
88
  }
89
89
 
90
- "info-card": Omit<JSX.SolutionsInfoCard, "onPopupClosed" | "onSelectionChanged"> & JSXInternal.HTMLAttributes<HTMLSolutionsInfoCardElement> & {
90
+ "info-card": Omit<JSX.SolutionsInfoCard, "onPopupClosed" | "onClearSelection" | "onSelectionChanged"> & JSXInternal.HTMLAttributes<HTMLSolutionsInfoCardElement> & {
91
91
  "onpopupClosed"?: (event: CustomEvent<any>) => void;
92
+ "onclearSelection"?: (event: CustomEvent<any>) => void;
92
93
  "onselectionChanged"?: (event: CustomEvent<any>) => void;
93
94
  }
94
95
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@esri/solutions-components",
3
- "version": "0.11.17",
3
+ "version": "0.11.19",
4
4
  "description": "Web Components for Esri's Solutions Applications",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -43,7 +43,7 @@
43
43
  "@esri/telemetry-amazon": "3.0.1",
44
44
  "@esri/telemetry-google-analytics": "2.0.1",
45
45
  "@stencil-community/postcss": "^2.2.0",
46
- "@stencil/core": "^4.25.1",
46
+ "@stencil/core": "4.23.0",
47
47
  "@stencil/sass": "^3.0.12",
48
48
  "@stencil/store": "^2.0.16",
49
49
  "@types/jest": "^29.5.14",
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,c as i,g as e,h as s,H as a}from"./p-1b0588d2.js";import{l as h,g as n}from"./p-ee2cbba0.js";import{f as l}from"./p-80cb7c73.js";import{s as r}from"./p-48942eb8.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-e23b4193.js";const o=class{constructor(e){t(this,e),this.bufferComplete=i(this,"bufferComplete",7),this.distanceChanged=i(this,"distanceChanged",7),this.unitChanged=i(this,"unitChanged",7)}get el(){return e(this)}appearance="text";distance=0;geometries=[];locale;max;min=0;sliderTicks=10;unionResults=!0;unit="meters";disabled=!1;_translations;_geometryEngine;_bufferTimeout;_unitElement;_units;geometriesWatchHandler(){this._buffer()}disabledWatchHandler(){this._buffer()}async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async getTranslatedUnit(t){return this._units||await this._defineTranslations(),this._units[t]}bufferComplete;distanceChanged;unitChanged;async componentWillLoad(){await this._defineTranslations(),await this._initModules()}render(){return s(a,{key:"56719f53eabb0743adb129546e27e7dc99399021"},"text"===this.appearance?this._getTextBoxDisplay():this._getSliderDisplay())}async _defineTranslations(){await this._getTranslations(),this._initTranslatedUnits()}async _initModules(){const[t]=await h(["esri/geometry/geometryEngine"]);this._geometryEngine=t}_initTranslatedUnits(){this._units={feet:this._translations.feet,meters:this._translations.meters,miles:this._translations.miles,kilometers:this._translations.kilometers}}_getUnits(){return Object.keys(this._units).map((t=>s("calcite-option",{label:this._units[t],selected:this.unit===t,value:t})))}_setDistance(t){const i=parseInt(t.target.value,10);this.distance!==i&&i>=this.min&&(this.distanceChanged.emit({oldValue:this.distance,newValue:i}),this.distance=i,this.distance>0?this._buffer():this.bufferComplete.emit(void 0))}_setUnit(t){this.unitChanged.emit({oldValue:this.unit,newValue:t}),this.unit=t,this._buffer()}_buffer(){this.disabled?this.bufferComplete.emit(void 0):(this._bufferTimeout&&clearTimeout(this._bufferTimeout),this._bufferTimeout=setTimeout((()=>{if(this.geometries?.length>0&&this.unit&&this.distance>0){const t=this.geometries[0].spatialReference,i=t.isWGS84||t.isWebMercator?this._geometryEngine.geodesicBuffer(this.geometries,this.distance,this.unit,this.unionResults):this._geometryEngine.buffer(this.geometries,this.distance,this.unit,this.unionResults);this.bufferComplete.emit(i)}}),400))}_getTextBoxDisplay(){return s("div",{class:"c-container"},s("calcite-input",{class:"padding-end-1 w-50",max:this.max&&this.max>0?this.max:void 0,min:this.min,"number-button-type":"vertical",onCalciteInputInput:t=>this._setDistance(t),placeholder:"0",type:"number",value:this.distance?this.distance.toString():void 0}),s("calcite-select",{class:"flex-1 w-50",label:"label",onCalciteSelectChange:()=>this._setUnit(this._unitElement.value),ref:t=>{this._unitElement=t}},this._getUnits()))}_getSliderDisplay(){return s("div",null,s("calcite-slider",{labelHandles:!0,max:this.max&&this.max>0?this.max:void 0,min:this.min,ticks:this.sliderTicks}))}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}_testAccess(t,i){switch(t){case"_setUnit":return this._setUnit(i);case"_setDistance":return this._setDistance(i)}return null}static get watchers(){return{geometries:["geometriesWatchHandler"],disabled:["disabledWatchHandler"],locale:["localeWatchHandler"]}}};o.style=':host{display:block}.c-container{display:inline-flex}.flex-1{flex:"1"}.padding-end-1{padding-inline-end:1rem}.w-50{width:50%}';const c=class{constructor(e){t(this,e),this.selectionLoadingChange=i(this,"selectionLoadingChange",7),this.sketchGraphicsChange=i(this,"sketchGraphicsChange",7),this.drawUndo=i(this,"drawUndo",7),this.drawRedo=i(this,"drawRedo",7)}get el(){return e(this)}active=!1;drawMode=l.SKETCH;editGraphicsEnabled=!0;graphics;locale;mapView;pointSymbol;polylineSymbol;polygonSymbol;redoEnabled=!1;undoEnabled=!1;_translations;_selectionMode;GraphicsLayer;SketchViewModel;Sketch;_sketchGraphicsLayer;_sketchViewModel;_sketchWidget;_sketchElement;graphicsWatchHandler(t,i){t&&t.length>0&&JSON.stringify(t)!==JSON.stringify(i)&&this._sketchGraphicsLayer&&(this._updateGraphicsSymbols(t),this._sketchGraphicsLayer.removeAll(),this._sketchGraphicsLayer.addMany(t))}async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}mapViewWatchHandler(t,i){t&&t!==i&&this._init()}async clear(){this._clearSketch()}async updateGraphics(){this._updateGraphics()}selectionLoadingChange;sketchGraphicsChange;drawUndo;drawRedo;async componentWillLoad(){await this._getTranslations(),await this._initModules()}componentDidLoad(){this._init()}disconnectedCallback(){this._sketchWidget.cancel(),this._clearSketch()}render(){const t=this.drawMode===l.SKETCH?"display-none":"esri-widget esri-sketch__panel border-left esri-sketch__section";return s(a,{key:"da7ef0973544c8b88ced49ef8c5a89b5d5cf48ea"},s("div",{key:"6cf3a4276a2a319c6f1a74d2824b0bb3003c9f9b",class:this.drawMode===l.SKETCH?"border":"border esri-widget esri-sketch__panel"},s("div",{key:"dade38f4d01fa7c28915a4fce879f9383d5892b9",ref:t=>{this._sketchElement=t}}),s("div",{key:"6e2fbb2dcfb2e4e51f35aa615c0003a65fa3bd66",class:t},s("calcite-action",{key:"8156802d2740aaa483e4f312cadadc5744f13486",disabled:!this.undoEnabled,icon:"undo",onClick:()=>this._undo(),scale:"s",text:this._translations.undo}),s("calcite-action",{key:"cd05845f66e187a317215e18d6a18696328960bf",disabled:!this.redoEnabled,icon:"redo",onClick:()=>this._redo(),scale:"s",text:this._translations.redo}))))}async _initModules(){const[t,i,e]=await h(["esri/layers/GraphicsLayer","esri/widgets/Sketch","esri/widgets/Sketch/SketchViewModel"]);this.GraphicsLayer=t,this.Sketch=i,this.SketchViewModel=e}_init(){this.mapView&&this._sketchElement&&(this._initGraphicsLayer(),this._initSketch())}_initGraphicsLayer(){const t=this._translations.sketchLayer,i=this.mapView.map.layers.findIndex((i=>i.title===t));i>-1?this._sketchGraphicsLayer=this.mapView.map.layers.getItemAt(i):(this._sketchGraphicsLayer=new this.GraphicsLayer({title:t,listMode:"hide"}),r.managedLayers[t]="sketch",this.mapView.map.layers.add(this._sketchGraphicsLayer)),this.graphics&&this.graphics.length>0&&this._sketchGraphicsLayer.addMany(this.graphics)}_initSketch(){const t={layer:this._sketchGraphicsLayer,view:this.mapView,defaultCreateOptions:{mode:"hybrid"},defaultUpdateOptions:{preserveAspectRatio:!1,enableScaling:!1,enableRotation:!1,tool:"reshape",toggleToolOnClick:!1}};this._sketchWidget=new this.Sketch({...t,container:this._sketchElement,creationMode:"single",visibleElements:{duplicateButton:!1,selectionTools:{"lasso-selection":!1,"rectangle-selection":!1},createTools:{circle:!1},undoRedoMenu:!1,settingsMenu:this.drawMode===l.SKETCH}}),this._sketchViewModel=new this.SketchViewModel({...t}),this._sketchWidget.viewModel.polylineSymbol=this.polylineSymbol,this._sketchWidget.viewModel.pointSymbol=this.pointSymbol,this._sketchWidget.viewModel.polygonSymbol=this.polygonSymbol;let i=!1;this._sketchWidget.on("create",(t=>{"complete"===t.state&&(this.graphics=[t.graphic],this.sketchGraphicsChange.emit({graphics:this.graphics,useOIDs:!1}),this.drawMode===l.REFINE&&(i=!0,this._sketchWidget.viewModel.create(t.tool))),"cancel"===t.state&&this.drawMode===l.REFINE&&i&&(i=!i,this._sketchWidget.viewModel.create(t.tool))})),this._sketchWidget.on("update",(t=>{if(this.editGraphicsEnabled){const i=t?.toolEventInfo?.type;"reshape-stop"!==i&&"move-stop"!==i||(this.graphics=t.graphics,this.sketchGraphicsChange.emit({graphics:this.graphics,useOIDs:!1}))}else this._sketchWidget.viewModel.cancel(),this._sketchViewModel.cancel()})),this._sketchWidget.on("delete",(()=>{this.graphics=[],this.sketchGraphicsChange.emit({graphics:this.graphics,useOIDs:!1})})),this._sketchWidget.on("undo",(t=>{this.graphics=t.graphics,this.sketchGraphicsChange.emit({graphics:this.graphics,useOIDs:!1})})),this._sketchWidget.on("redo",(t=>{this.graphics=t.graphics,this.sketchGraphicsChange.emit({graphics:this.graphics,useOIDs:!1})}))}_clearSketch(){this._sketchWidget?.viewModel.cancel(),this.graphics=[],this._sketchGraphicsLayer?.removeAll()}_undo(){this.drawUndo.emit()}_redo(){this.drawRedo.emit()}_updateGraphics(){setTimeout((()=>{1===this.graphics.length&&this._sketchWidget.update(this.graphics,{tool:"reshape",enableRotation:!1,enableScaling:!1,preserveAspectRatio:!1,toggleToolOnClick:!1})}),100)}_updateGraphicsSymbols(t){const i=t[0].geometry.type,e="point"===i?this.pointSymbol:"polyline"===i?this.polylineSymbol:"polygon"===i?this.polygonSymbol:void 0;e&&t.forEach((t=>t.symbol=e))}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{graphics:["graphicsWatchHandler"],locale:["localeWatchHandler"],mapView:["mapViewWatchHandler"]}}};c.style=':host{display:block}.border{outline:1px solid var(--calcite-color-border-input)}.div-visible{display:inherit}.div-not-visible{display:none !important}.padding-top-1-2{padding-top:.5rem}.main-label{display:flex;float:left}html[dir="rtl"] .main-label{display:flex;float:right}.margin-top-1{margin-top:1rem}.border-left{border-left:1px solid rgba(110, 110, 110, .3)}.border-left[dir="rtl"]{border-right:1px solid rgba(110, 110, 110, .3)}.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:#fff;--esri-widget-padding-v:12px;--esri-widget-padding-h:15px;--esri-widget-padding:var(--esri-widget-padding-v) var(--esri-widget-padding-h)}.esri-sketch__panel{align-items:center;display:flex;flex-flow:row wrap;padding:0;justify-content:flex-start !important}.esri-sketch__section{align-items:center;display:flex;flex-flow:row wrap;padding:0 7px;margin:6px 0}';export{o as buffer_tools,c as map_draw_tools}
@@ -1,7 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- var t=Object.defineProperty,e=(t,e)=>{var n;Object.entries(null!=(n=e.o.t)?n:{}).map((([n,[o]])=>{if(31&o||32&o){const o=t[n],l=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(t),n);Object.defineProperty(t,n,{get(){return l.get.call(this)},set(t){l.set.call(this,t)},configurable:!0,enumerable:!0}),t[n]=e.l.has(n)?e.l.get(n):o}}))},n=new WeakMap,o=t=>n.get(t),l=(t,o)=>{n.set(o.i=t,o),e(t,o)},s=(t,e)=>e in t,i=(t,e)=>(0,console.error)(t,e),r=new Map,c=new Map,u="slot-fb{display:contents}slot-fb[hidden]{display:none}",f="undefined"!=typeof window?window:{},a=f.document||{head:{}},d={u:0,h:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,o)=>t.addEventListener(e,n,o),rel:(t,e,n,o)=>t.removeEventListener(e,n,o),ce:(t,e)=>new CustomEvent(t,e)},h=t=>Promise.resolve(t),v=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(t){}return!1})(),p=!1,m=[],y=[],b=(t,e)=>n=>{t.push(n),p||(p=!0,e&&4&d.u?g(w):d.raf(w))},$=t=>{for(let e=0;e<t.length;e++)try{t[e](performance.now())}catch(t){i(t)}t.length=0},w=()=>{$(m),$(y),(p=m.length>0)&&d.raf(w)},g=t=>h().then(t),j=b(y,!0),S=t=>{const e=new URL(t,d.h);return e.origin!==f.location.origin?e.href:e.pathname},O=t=>"object"==(t=typeof t)||"function"===t;function k(t){var e,n,o;return null!=(o=null==(n=null==(e=t.head)?void 0:e.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?o:void 0}((e,n)=>{for(var o in n)t(e,o,{get:n[o],enumerable:!0})})({},{err:()=>C,map:()=>M,ok:()=>E,unwrap:()=>R,unwrapErr:()=>x});var E=t=>({isOk:!0,isErr:!1,value:t}),C=t=>({isOk:!1,isErr:!0,value:t});function M(t,e){if(t.isOk){const n=e(t.value);return n instanceof Promise?n.then((t=>E(t))):E(n)}if(t.isErr)return C(t.value);throw"should never get here"}var R=t=>{if(t.isOk)return t.value;throw t.value},x=t=>{if(t.isErr)return t.value;throw t.value},T=t=>{const e=t.__childNodes||t.childNodes;t.tagName&&t.tagName.includes("-")&&t["s-cr"]&&"SLOT-FB"!==t.tagName&&L(e,t.tagName).forEach((t=>{var e;1===t.nodeType&&"SLOT-FB"===t.tagName&&(t.hidden=!!(null==(e=D(t,t["s-sn"],!1))?void 0:e.length))}));for(const t of e)1===t.nodeType&&(t.__childNodes||t.childNodes).length&&T(t)};function L(t,e,n){let o,l=0,s=[];for(;l<t.length;l++){if(o=t[l],o["s-sr"]&&o["s-hn"]===e&&(void 0===n||o["s-sn"]===n)&&(s.push(o),void 0!==n))return s;s=[...s,...L(o.childNodes,e,n)]}return s}var P,F,A,D=(t,e,n=!0)=>{const o=[];for((n&&t["s-sr"]||!t["s-sr"])&&o.push(t);(t=t.nextSibling)&&t["s-sn"]===e;)o.push(t);return o},U=(t,e)=>1===t.nodeType?null===t.getAttribute("slot")&&""===e||t.getAttribute("slot")===e:t["s-sn"]===e||""===e,H=(t,e,...n)=>{let o=null,l=null,s=null,i=!1,r=!1;const c=[],u=e=>{for(let n=0;n<e.length;n++)o=e[n],Array.isArray(o)?u(o):null!=o&&"boolean"!=typeof o&&((i="function"!=typeof t&&!O(o))&&(o+=""),i&&r?c[c.length-1].v+=o:c.push(i?N(null,o):o),r=i)};if(u(n),e){e.key&&(l=e.key),e.name&&(s=e.name);{const t=e.className||e.class;t&&(e.class="object"!=typeof t?t:Object.keys(t).filter((e=>t[e])).join(" "))}}if("function"==typeof t)return t(null===e?{}:e,c,B);const f=N(t,null);return f.p=e,c.length>0&&(f.m=c),f.$=l,f.j=s,f},N=(t,e)=>({u:0,S:t,v:e,O:null,m:null,p:null,$:null,j:null}),W={},B={forEach:(t,e)=>t.map(V).forEach(e),map:(t,e)=>t.map(V).map(e).map(q)},V=t=>({vattrs:t.p,vchildren:t.m,vkey:t.$,vname:t.j,vtag:t.S,vtext:t.v}),q=t=>{if("function"==typeof t.vtag){const e={...t.vattrs};return t.vkey&&(e.key=t.vkey),t.vname&&(e.name=t.vname),H(t.vtag,e,...t.vchildren||[])}const e=N(t.vtag,t.vtext);return e.p=t.vattrs,e.m=t.vchildren,e.$=t.vkey,e.j=t.vname,e},G=(t,e)=>null==t||O(t)?t:4&e?"false"!==t&&(""===t||!!t):2&e?parseFloat(t):1&e?t+"":t,_=t=>o(t).$hostElement$,z=(t,e,n)=>{const o=_(t);return{emit:t=>I(o,e,{bubbles:!!(4&n),composed:!!(2&n),cancelable:!!(1&n),detail:t})}},I=(t,e,n)=>{const o=d.ce(e,n);return t.dispatchEvent(o),o},J=new WeakMap,K=t=>"sc-"+t.k,Q=(t,e,n,o,l,i)=>{if(n!==o){let r=s(t,e),c=e.toLowerCase();if("class"===e){const e=t.classList,l=Y(n);let s=Y(o);e.remove(...l.filter((t=>t&&!s.includes(t)))),e.add(...s.filter((t=>t&&!l.includes(t))))}else if("style"===e){for(const e in n)o&&null!=o[e]||(e.includes("-")?t.style.removeProperty(e):t.style[e]="");for(const e in o)n&&o[e]===n[e]||(e.includes("-")?t.style.setProperty(e,o[e]):t.style[e]=o[e])}else if("key"===e);else if("ref"===e)o&&o(t);else if(r||"o"!==e[0]||"n"!==e[1]){const s=O(o);if((r||s&&null!==o)&&!l)try{if(t.tagName.includes("-"))t[e]!==o&&(t[e]=o);else{const l=null==o?"":o;"list"===e?r=!1:null!=n&&t[e]==l||("function"==typeof t.__lookupSetter__(e)?t[e]=l:t.setAttribute(e,l))}}catch(t){}null==o||!1===o?!1===o&&""!==t.getAttribute(e)||t.removeAttribute(e):(!r||4&i||l)&&!s&&t.setAttribute(e,o=!0===o?"":o)}else if(e="-"===e[2]?e.slice(3):s(f,c)?c.slice(2):c[2]+e.slice(3),n||o){const l=e.endsWith(Z);e=e.replace(tt,""),n&&d.rel(t,e,n,l),o&&d.ael(t,e,o,l)}}},X=/\s/,Y=t=>("object"==typeof t&&t&&"baseVal"in t&&(t=t.baseVal),t&&"string"==typeof t?t.split(X):[]),Z="Capture",tt=RegExp(Z+"$"),et=(t,e,n)=>{const o=11===e.O.nodeType&&e.O.host?e.O.host:e.O,l=t&&t.p||{},s=e.p||{};for(const t of nt(Object.keys(l)))t in s||Q(o,t,l[t],void 0,n,e.u);for(const t of nt(Object.keys(s)))Q(o,t,l[t],s[t],n,e.u)};function nt(t){return t.includes("ref")?[...t.filter((t=>"ref"!==t)),"ref"]:t}var ot=!1,lt=!1,st=!1,it=!1,rt=(t,e,n)=>{var o;const l=e.m[n];let s,i,r,c=0;if(ot||(st=!0,"slot"===l.S&&(l.u|=l.m?2:1)),null!==l.v)s=l.O=a.createTextNode(l.v);else if(1&l.u)s=l.O=a.createTextNode("");else{if(it||(it="svg"===l.S),s=l.O=a.createElementNS(it?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",!ot&&2&l.u?"slot-fb":l.S),it&&"foreignObject"===l.S&&(it=!1),et(null,l,it),null!=P&&void 0!==P&&s["s-si"]!==P&&s.classList.add(s["s-si"]=P),l.m)for(c=0;c<l.m.length;++c)i=rt(t,l,c),i&&s.appendChild(i);"svg"===l.S?it=!1:"foreignObject"===s.tagName&&(it=!0)}return s["s-hn"]=A,3&l.u&&(s["s-sr"]=!0,s["s-cr"]=F,s["s-sn"]=l.j||"",s["s-rf"]=null==(o=l.p)?void 0:o.ref,r=t&&t.m&&t.m[n],r&&r.S===l.S&&t.O&&ct(t.O,!1),bt(F,s,e.O,null==t?void 0:t.O)),s},ct=(t,e)=>{d.u|=1;const n=Array.from(t.__childNodes||t.childNodes);for(let t=n.length-1;t>=0;t--){const o=n[t];o["s-hn"]!==A&&o["s-ol"]&&(yt(dt(o).parentNode,o,dt(o)),o["s-ol"].remove(),o["s-ol"]=void 0,o["s-sh"]=void 0,st=!0),e&&ct(o,e)}d.u&=-2},ut=(t,e,n,o,l,s)=>{let i,r=t["s-cr"]&&t["s-cr"].parentNode||t;for(r.shadowRoot&&r.tagName===A&&(r=r.shadowRoot);l<=s;++l)o[l]&&(i=rt(null,n,l),i&&(o[l].O=i,yt(r,i,dt(e))))},ft=(t,e,n)=>{for(let o=e;o<=n;++o){const e=t[o];if(e){const t=e.O;mt(e),t&&(lt=!0,t["s-ol"]?t["s-ol"].remove():ct(t,!0),t.remove())}}},at=(t,e,n=!1)=>t.S===e.S&&("slot"===t.S?t.j===e.j:n?(n&&!t.$&&e.$&&(t.$=e.$),!0):t.$===e.$),dt=t=>t&&t["s-ol"]||t,ht=(t,e,n=!1)=>{const o=e.O=t.O,l=t.m,s=e.m,i=e.S,r=e.v;let c;null===r?(it="svg"===i||"foreignObject"!==i&&it,("slot"!==i||ot)&&et(t,e,it),null!==l&&null!==s?((t,e,n,o,l=!1)=>{let s,i,r=0,c=0,u=0,f=0,a=e.length-1,d=e[0],h=e[a],v=o.length-1,p=o[0],m=o[v];for(;r<=a&&c<=v;)if(null==d)d=e[++r];else if(null==h)h=e[--a];else if(null==p)p=o[++c];else if(null==m)m=o[--v];else if(at(d,p,l))ht(d,p,l),d=e[++r],p=o[++c];else if(at(h,m,l))ht(h,m,l),h=e[--a],m=o[--v];else if(at(d,m,l))"slot"!==d.S&&"slot"!==m.S||ct(d.O.parentNode,!1),ht(d,m,l),yt(t,d.O,h.O.nextSibling),d=e[++r],m=o[--v];else if(at(h,p,l))"slot"!==d.S&&"slot"!==m.S||ct(h.O.parentNode,!1),ht(h,p,l),yt(t,h.O,d.O),h=e[--a],p=o[++c];else{for(u=-1,f=r;f<=a;++f)if(e[f]&&null!==e[f].$&&e[f].$===p.$){u=f;break}u>=0?(i=e[u],i.S!==p.S?s=rt(e&&e[c],n,u):(ht(i,p,l),e[u]=void 0,s=i.O),p=o[++c]):(s=rt(e&&e[c],n,c),p=o[++c]),s&&yt(dt(d.O).parentNode,s,dt(d.O))}r>a?ut(t,null==o[v+1]?null:o[v+1].O,n,o,c,v):c>v&&ft(e,r,a)})(o,l,e,s,n):null!==s?(null!==t.v&&(o.textContent=""),ut(o,null,e,s,0,s.length-1)):!n&&null!==l&&ft(l,0,l.length-1),it&&"svg"===i&&(it=!1)):(c=o["s-cr"])?c.parentNode.textContent=r:t.v!==r&&(o.data=r)},vt=[],pt=t=>{let e,n,o;const l=t.__childNodes||t.childNodes;for(const t of l){if(t["s-sr"]&&(e=t["s-cr"])&&e.parentNode){n=e.parentNode.__childNodes||e.parentNode.childNodes;const l=t["s-sn"];for(o=n.length-1;o>=0;o--)if(e=n[o],!e["s-cn"]&&!e["s-nr"]&&e["s-hn"]!==t["s-hn"])if(U(e,l)){let n=vt.find((t=>t.C===e));lt=!0,e["s-sn"]=e["s-sn"]||l,n?(n.C["s-sh"]=t["s-hn"],n.M=t):(e["s-sh"]=t["s-hn"],vt.push({M:t,C:e})),e["s-sr"]&&vt.map((t=>{U(t.C,e["s-sn"])&&(n=vt.find((t=>t.C===e)),n&&!t.M&&(t.M=n.M))}))}else vt.some((t=>t.C===e))||vt.push({C:e})}1===t.nodeType&&pt(t)}},mt=t=>{t.p&&t.p.ref&&t.p.ref(null),t.m&&t.m.map(mt)},yt=(t,e,n)=>("string"==typeof e["s-sn"]&&e["s-sr"]&&e["s-cr"]&&bt(e["s-cr"],e,t,e.parentElement),null==t?void 0:t.insertBefore(e,n));function bt(t,e,n,o){var l;let s;if(t&&"string"==typeof e["s-sn"]&&e["s-sr"]&&t.parentNode&&t.parentNode["s-sc"]&&(s=e["s-si"]||t.parentNode["s-sc"])){const t=e["s-sn"],i=e["s-hn"];if(null==(l=n.classList)||l.add(s+"-s"),o&&o.classList.contains(s+"-s")){let e=(o.__childNodes||o.childNodes)[0],n=!1;for(;e;){if(e["s-sn"]!==t&&e["s-hn"]===i&&e["s-sr"]){n=!0;break}e=e.nextSibling}n||o.classList.remove(s+"-s")}}}var $t=(t,e)=>{if(e&&!t.R&&e["s-p"]){const n=e["s-p"].push(new Promise((o=>t.R=()=>{e["s-p"].splice(n-1,1),o()})))}},wt=(t,e)=>{if(t.u|=16,!(4&t.u))return $t(t,t.T),j((()=>gt(t,e)));t.u|=512},gt=(t,e)=>{const n=t.$hostElement$,o=t.i;if(!o)throw Error(`Can't render component <${n.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let l;return e?(t.u|=256,t.L&&(t.L.map((([t,e])=>Tt(o,t,e,n))),t.L=void 0),l=Tt(o,"componentWillLoad",void 0,n)):l=Tt(o,"componentWillUpdate",void 0,n),l=jt(l,(()=>Tt(o,"componentWillRender",void 0,n))),jt(l,(()=>Ot(t,o,e)))},jt=(t,e)=>St(t)?t.then(e).catch((t=>{console.error(t),e()})):e(),St=t=>t instanceof Promise||t&&t.then&&"function"==typeof t.then,Ot=async(t,e,n)=>{var o;const l=t.$hostElement$,s=l["s-rc"];n&&(t=>{const e=t.o,n=t.$hostElement$,o=e.u,l=((t,e)=>{var n;const o=K(e),l=c.get(o);if(t=11===t.nodeType?t:a,l)if("string"==typeof l){let s,i=J.get(t=t.head||t);if(i||J.set(t,i=new Set),!i.has(o)){{s=document.querySelector(`[sty-id="${o}"]`)||a.createElement("style"),s.innerHTML=l;const i=null!=(n=d.P)?n:k(a);if(null!=i&&s.setAttribute("nonce",i),!(1&e.u))if("HEAD"===t.nodeName){const e=t.querySelectorAll("link[rel=preconnect]"),n=e.length>0?e[e.length-1].nextSibling:t.querySelector("style");t.insertBefore(s,(null==n?void 0:n.parentNode)===t?n:null)}else if("host"in t)if(v){const e=new CSSStyleSheet;e.replaceSync(l),t.adoptedStyleSheets=[e,...t.adoptedStyleSheets]}else{const e=t.querySelector("style");e?e.innerHTML=l+e.innerHTML:t.prepend(s)}else t.append(s);1&e.u&&"HEAD"!==t.nodeName&&t.insertBefore(s,null)}4&e.u&&(s.innerHTML+=u),i&&i.add(o)}}else t.adoptedStyleSheets.includes(l)||(t.adoptedStyleSheets=[...t.adoptedStyleSheets,l]);return o})(n.shadowRoot?n.shadowRoot:n.getRootNode(),e);10&o&&2&o&&(n["s-sc"]=l,n.classList.add(l+"-h"))})(t);Et(t,e,l,n),s&&(s.map((t=>t())),l["s-rc"]=void 0);{const e=null!=(o=l["s-p"])?o:[],n=()=>Mt(t);0===e.length?n():(Promise.all(e).then(n),t.u|=4,e.length=0)}},kt=null,Et=(t,e,n,o)=>{try{kt=e,e=e.render(),t.u&=-17,t.u|=2,((t,e,n=!1)=>{var o,l,s,i;const r=t.$hostElement$,c=t.o,u=t.F||N(null,null),f=(t=>t&&t.S===W)(e)?e:H(null,null,e);if(A=r.tagName,c.A&&(f.p=f.p||{},c.A.map((([t,e])=>f.p[e]=r[t]))),n&&f.p)for(const t of Object.keys(f.p))r.hasAttribute(t)&&!["key","ref","style","class"].includes(t)&&(f.p[t]=r[t]);if(f.S=null,f.u|=4,t.F=f,f.O=u.O=r.shadowRoot||r,P=r["s-sc"],ot=!!(1&c.u),F=r["s-cr"],lt=!1,ht(u,f,n),d.u|=1,st){pt(f.O);for(const t of vt){const e=t.C;if(!e["s-ol"]){const t=a.createTextNode("");t["s-nr"]=e,yt(e.parentNode,e["s-ol"]=t,e)}}for(const t of vt){const e=t.C,r=t.M;if(r){const t=r.parentNode;let n=r.nextSibling;{let s=null==(o=e["s-ol"])?void 0:o.previousSibling;for(;s;){let o=null!=(l=s["s-nr"])?l:null;if(o&&o["s-sn"]===e["s-sn"]&&t===(o.__parentNode||o.parentNode)){for(o=o.nextSibling;o===e||(null==o?void 0:o["s-sr"]);)o=null==o?void 0:o.nextSibling;if(!o||!o["s-nr"]){n=o;break}}s=s.previousSibling}}(!n&&t!==(e.__parentNode||e.parentNode)||(e.__nextSibling||e.nextSibling)!==n)&&e!==n&&(!e["s-hn"]&&e["s-ol"]&&(e["s-hn"]=e["s-ol"].parentNode.nodeName),yt(t,e,n),1===e.nodeType&&"SLOT-FB"!==e.tagName&&(e.hidden=null!=(s=e["s-ih"])&&s)),e&&"function"==typeof r["s-rf"]&&r["s-rf"](e)}else 1===e.nodeType&&(n&&(e["s-ih"]=null!=(i=e.hidden)&&i),e.hidden=!0)}}lt&&T(f.O),d.u&=-2,vt.length=0,F=void 0})(t,e,o)}catch(e){i(e,t.$hostElement$)}return kt=null,null},Ct=()=>kt,Mt=t=>{const e=t.$hostElement$,n=t.i,o=t.T;Tt(n,"componentDidRender",void 0,e),64&t.u?Tt(n,"componentDidUpdate",void 0,e):(t.u|=64,Lt(e),Tt(n,"componentDidLoad",void 0,e),t.D(e),o||xt()),t.U(e),t.R&&(t.R(),t.R=void 0),512&t.u&&g((()=>wt(t,!1))),t.u&=-517},Rt=t=>{{const e=o(t),n=e.$hostElement$.isConnected;return n&&2==(18&e.u)&&wt(e,!1),n}},xt=()=>{Lt(a.documentElement),g((()=>I(f,"appload",{detail:{namespace:"solutions-components"}})))},Tt=(t,e,n,o)=>{if(t&&t[e])try{return t[e](n)}catch(t){i(t,o)}},Lt=t=>t.classList.add("hydrated"),Pt=(t,e,n,l)=>{const s=o(t);if(!s)throw Error(`Couldn't find host element for "${l.k}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/ionic-team/stencil/issues/5457).`);const r=s.$hostElement$,c=s.l.get(e),u=s.u,f=s.i;if(n=G(n,l.t[e][0]),(!(8&u)||void 0===c)&&n!==c&&(!Number.isNaN(c)||!Number.isNaN(n))&&(s.l.set(e,n),f)){if(l.H&&128&u){const t=l.H[e];t&&t.map((t=>{try{f[t](n,c,e)}catch(t){i(t,r)}}))}2==(18&u)&&wt(s,!1)}},Ft=(t,e,n)=>{var l,s;const i=t.prototype;if(e.t||e.H||t.watchers){t.watchers&&!e.H&&(e.H=t.watchers);const r=Object.entries(null!=(l=e.t)?l:{});if(r.map((([t,[l]])=>{if(31&l||2&n&&32&l){const{get:s,set:r}=Object.getOwnPropertyDescriptor(i,t)||{};s&&(e.t[t][0]|=2048),r&&(e.t[t][0]|=4096),(1&n||!s)&&Object.defineProperty(i,t,{get(){{if(!(2048&e.t[t][0]))return((t,e)=>o(this).l.get(e))(0,t);const n=o(this),l=n?n.i:i;if(!l)return;return l[t]}},configurable:!0,enumerable:!0}),Object.defineProperty(i,t,{set(s){const i=o(this);if(r){const n=32&l?this[t]:i.$hostElement$[t];return void 0===n&&i.l.get(t)?s=i.l.get(t):!i.l.get(t)&&n&&i.l.set(t,n),r.call(this,G(s,l)),void Pt(this,t,s=32&l?this[t]:i.$hostElement$[t],e)}{if(!(1&n&&4096&e.t[t][0]))return Pt(this,t,s,e),void(1&n&&!i.i&&i.N.then((()=>{4096&e.t[t][0]&&i.i[t]!==i.l.get(t)&&(i.i[t]=s)})));const o=()=>{const n=i.i[t];!i.l.get(t)&&n&&i.l.set(t,n),i.i[t]=G(s,l),Pt(this,t,i.i[t],e)};i.i?o():i.N.then((()=>o()))}}})}else 1&n&&64&l&&Object.defineProperty(i,t,{value(...e){var n;const l=o(this);return null==(n=null==l?void 0:l.W)?void 0:n.then((()=>{var n;return null==(n=l.i)?void 0:n[t](...e)}))}})})),1&n){const n=new Map;i.attributeChangedCallback=function(t,l,s){d.jmp((()=>{var r;const c=n.get(t);if(this.hasOwnProperty(c))s=this[c],delete this[c];else{if(i.hasOwnProperty(c)&&"number"==typeof this[c]&&this[c]==s)return;if(null==c){const n=o(this),i=null==n?void 0:n.u;if(i&&!(8&i)&&128&i&&s!==l){const o=n.i,i=null==(r=e.H)?void 0:r[t];null==i||i.forEach((e=>{null!=o[e]&&o[e].call(o,s,l,t)}))}return}}const u=Object.getOwnPropertyDescriptor(i,c);(s=(null!==s||"boolean"!=typeof this[c])&&s)===this[c]||u.get&&!u.set||(this[c]=s)}))},t.observedAttributes=Array.from(new Set([...Object.keys(null!=(s=e.H)?s:{}),...r.filter((([t,e])=>15&e[0])).map((([t,o])=>{var l;const s=o[1]||t;return n.set(s,t),512&o[0]&&(null==(l=e.A)||l.push([t,s])),s}))]))}}return t},At=(t,e)=>{Tt(t,"connectedCallback",void 0,e)},Dt=(t,e)=>{Tt(t,"disconnectedCallback",void 0,e||t)},Ut=(t,e={})=>{var l;const s=[],h=e.exclude||[],p=f.customElements,m=a.head,y=m.querySelector("meta[charset]"),b=a.createElement("style"),$=[];let w,g=!0;Object.assign(d,e),d.h=new URL(e.resourcesUrl||"./",a.baseURI).href;let j=!1;if(t.map((t=>{t[1].map((e=>{var l;const u={u:e[0],k:e[1],t:e[2],B:e[3]};4&u.u&&(j=!0),u.t=e[2],u.B=e[3],u.A=[],u.H=null!=(l=e[4])?l:{};const f=u.k,m=class extends HTMLElement{constructor(t){if(super(t),this.hasRegisteredEventListeners=!1,((t,e)=>{const o={u:0,$hostElement$:t,o:e,l:new Map};o.W=new Promise((t=>o.U=t)),o.N=new Promise((t=>o.D=t)),t["s-p"]=[],t["s-rc"]=[],n.set(t,o)})(t=this,u),1&u.u)if(t.shadowRoot){if("open"!==t.shadowRoot.mode)throw Error(`Unable to re-use existing shadow root for ${u.k}! Mode is set to ${t.shadowRoot.mode} but Stencil only supports open shadow roots.`)}else t.attachShadow({mode:"open"})}connectedCallback(){const t=o(this);this.hasRegisteredEventListeners||(this.hasRegisteredEventListeners=!0,Nt(this,t,u.B)),w&&(clearTimeout(w),w=null),g?$.push(this):d.jmp((()=>(t=>{if(!(1&d.u)){const e=o(t),n=e.o,l=()=>{};if(1&e.u)Nt(t,e,n.B),(null==e?void 0:e.i)?At(e.i,t):(null==e?void 0:e.N)&&e.N.then((()=>At(e.i,t)));else{e.u|=1,12&n.u&&(t=>{const e=t["s-cr"]=a.createComment("");e["s-cn"]=!0,yt(t,e,t.firstChild)})(t);{let n=t;for(;n=n.parentNode||n.host;)if(n["s-p"]){$t(e,e.T=n);break}}n.t&&Object.entries(n.t).map((([e,[n]])=>{if(31&n&&t.hasOwnProperty(e)){const n=t[e];delete t[e],t[e]=n}})),(async(t,e,n)=>{let o;if(!(32&e.u)){e.u|=32;{const l=((t,e)=>{const n=t.k.replace(/-/g,"_"),o=t.V;if(!o)return;const l=r.get(o);return l?l[n]:import(`./${o}.entry.js`).then((t=>(r.set(o,t),t[n])),(t=>{i(t,e.$hostElement$)}))
7
- /*!__STENCIL_STATIC_IMPORT_SWITCH__*/})(n,e);if(l&&"then"in l){const t=()=>{};o=await l,t()}else o=l;if(!o)throw Error(`Constructor for "${n.k}#${e.q}" was not found`);o.isProxied||(n.H=o.watchers,Ft(o,n,2),o.isProxied=!0);const s=()=>{};e.u|=8;try{new o(e)}catch(e){i(e,t)}e.u&=-9,e.u|=128,s(),At(e.i,t)}if(o&&o.style){let t;"string"==typeof o.style&&(t=o.style);const e=K(n);if(!c.has(e)){const o=()=>{};((t,e,n)=>{let o=c.get(t);v&&n?(o=o||new CSSStyleSheet,"string"==typeof o?o=e:o.replaceSync(e)):o=e,c.set(t,o)})(e,t,!!(1&n.u)),o()}}}const l=e.T,s=()=>wt(e,!0);l&&l["s-rc"]?l["s-rc"].push(s):s()})(t,e,n)}l()}})(this)))}disconnectedCallback(){d.jmp((()=>(async t=>{if(!(1&d.u)){const e=o(t);e.G&&(e.G.map((t=>t())),e.G=void 0),(null==e?void 0:e.i)?Dt(e.i,t):(null==e?void 0:e.N)&&e.N.then((()=>Dt(e.i,t)))}J.has(t)&&J.delete(t),t.shadowRoot&&J.has(t.shadowRoot)&&J.delete(t.shadowRoot)})(this))),d.raf((()=>{var t;const e=o(this);(null==(t=null==e?void 0:e.F)?void 0:t.O)instanceof Node&&!e.F.O.isConnected&&delete e.F.O}))}componentOnReady(){return o(this).N}};u.V=t[0],h.includes(f)||p.get(f)||(s.push(f),p.define(f,Ft(m,u,1)))}))})),s.length>0&&(j&&(b.textContent+=u),b.textContent+=s.sort()+"{visibility:hidden}.hydrated{visibility:inherit}",b.innerHTML.length)){b.setAttribute("data-styles","");const t=null!=(l=d.P)?l:k(a);null!=t&&b.setAttribute("nonce",t),m.insertBefore(b,y?y.nextSibling:m.firstChild)}g=!1,$.length?$.map((t=>t.connectedCallback())):d.jmp((()=>w=setTimeout(xt,30)))},Ht=(t,e)=>e,Nt=(t,e,n)=>{n&&n.map((([n,o,l])=>{const s=Bt(t,n),i=Wt(e,l),r=Vt(n);d.ael(s,o,i,r),(e.G=e.G||[]).push((()=>d.rel(s,o,i,r)))}))},Wt=(t,e)=>n=>{var o;try{256&t.u?null==(o=t.i)||o[e](n):(t.L=t.L||[]).push([e,n])}catch(e){i(e,t.$hostElement$)}},Bt=(t,e)=>8&e?f:t,Vt=t=>({passive:!!(1&t),capture:!!(2&t)}),qt=t=>d.P=t;export{Ht as F,W as H,S as a,Ut as b,z as c,Ct as d,Rt as f,_ as g,H as h,h as p,l as r,qt as s}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as e,c as t,g as i,h as s,H as a}from"./p-1b0588d2.js";import{a as l,l as h,g as n}from"./p-ee2cbba0.js";import{e as r,h as c,k as o,l as d,c as p,m as b,n as f,o as g}from"./p-952da957.js";import{a as y,e as m,f as u}from"./p-80cb7c73.js";import{s as w}from"./p-48942eb8.js";import{d as _,a as v}from"./p-4f514c6d.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-e23b4193.js";import"./p-4fe489cf.js";import"./p-2bc98cb0.js";import"./p-4f236b5d.js";import"./p-570b13d9.js";import"./p-0668e30d.js";const S=class{constructor(i){e(this,i),this.selectionSetChange=t(this,"selectionSetChange",7)}get el(){return i(this)}bufferColor=[227,139,79,.8];bufferOutlineColor=[255,255,255];customLabelEnabled;enabledLayerIds=[];enableLayerFeatures=!0;enableLayerFeaturesOnLoad=!1;enableSearchDistance=!0;enableSearchDistanceOnLoad=!1;enableSketchTools=!0;defaultBufferDistance;defaultBufferUnit;geometries=[];isUpdate=!1;layerViews=[];locale;mapView;noResultText;searchConfiguration;selectionSet;selectionLayerIds=[];selectLayerView;sketchLineSymbol;sketchPointSymbol;sketchPolygonSymbol;searchDistanceEnabled=!1;useLayerFeaturesEnabled=!1;_numSelected=0;_searchTerm;_selectionLoading=!1;_translations;_esriRequest;FeatureLayer;Graphic;GraphicsLayer;Search;_geometryEngine;_bufferGeometry;_bufferGraphicsLayer;_bufferTools;_distance;_drawTools;_labelName;_selectLayers;_searchElement;_searchResult;_searchWidget;_selectedIds=[];_selectionLabel="";_skipGeomOIDs;_sketchGraphic;_graphics=[];_unit;_workflowType;_featuresCollection={};async watchGeometriesHandler(e,t){if(e!==t){const t=0===e.length;if(await this._clearResults(t,t),e.length>0)return this._highlightWithOIDsOrGeoms()}}async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async mapViewWatchHandler(e,t){e&&e!==t&&await this._init()}async watchSearchConfigurationHandler(e,t){JSON.stringify(e)!==JSON.stringify(t)&&await this._initSearchWidget()}async clearSelection(){return this._clearResults(!0,!0)}async getSelection(){return/\S+/gm.test(this._selectionLabel)||await this._updateLabel(),{id:this.isUpdate?this.selectionSet.id:Date.now(),searchResult:this._searchResult,buffer:this._bufferGeometry,distance:this._bufferTools?.distance,download:!0,unit:this._bufferTools?.unit,label:this._selectionLabel,selectedIds:this._selectedIds,layerView:this.selectLayerView,geometries:this.geometries,graphics:this._graphics,selectLayers:this.layerViews,skipGeomOIDs:this._skipGeomOIDs,searchDistanceEnabled:this.searchDistanceEnabled,workflowType:this._workflowType,useLayerFeaturesEnabled:this.useLayerFeaturesEnabled,sketchGraphic:this._sketchGraphic}}selectionSetChange;searchConfigurationChangeChanged(e){this.searchConfiguration=e.detail}async distanceChanged(e){await this._distanceChanged(e.detail)}async unitChanged(e){e.detail.newValue!==e.detail.oldValue&&(this._unit=e.detail.newValue,await this._updateLabel())}async componentWillLoad(){await this._getTranslations(),await this._initModules()}async componentDidLoad(){await this._init()}render(){const e=this.enableSketchTools?"":"display-none",t=this.enableSketchTools?"padding-top-1":"";return s(a,{key:"a5001c196db1464bffa746310638b2853ff5fdf9"},this._getMapLayerPicker(),s("div",{key:"3e023a81f76bdd371c84d9ecb42e97a9160c6f89",class:"border-bottom"}),s("div",{key:"c6be571bee2d2c1fe82407aee9a1cf9f1f27280d",class:"padding-top-sides-1"},s("div",{key:"aaf5992f616728f6be5be034700ac09b9b5b733f",class:"search-widget",ref:e=>{this._searchElement=e}}),s("div",{key:"a86b4e147b7baf4b93272bed7f189a47faf65ab8",class:t},s("map-draw-tools",{key:"9b3c2faaa8f612d055189206e2baeb868d55dceb",active:!0,class:e,editGraphicsEnabled:!this.useLayerFeaturesEnabled,graphics:this._graphics,locale:this.locale,mapView:this.mapView,onSketchGraphicsChange:e=>{this._sketchGraphicsChanged(e)},pointSymbol:this.sketchPointSymbol,polygonSymbol:this.sketchPolygonSymbol,polylineSymbol:this.sketchLineSymbol,ref:e=>{this._drawTools=e}})),this.enableSearchDistance?this._getBufferOptions():void 0,this.enableLayerFeatures?this._getUseLayerFeaturesOptions():void 0,this._getNumSelected()),s("div",{key:"73b3039f0861046a3f955872180b64c15bd5c5d9",class:"border-bottom"}),this._getNameInput())}_getBufferOptions(){this.enableSearchDistanceOnLoad&&(this.searchDistanceEnabled=!0,this.enableSearchDistanceOnLoad=!1);const e=this.searchDistanceEnabled?"search-distance":"div-not-visible",t="number"==typeof this.selectionSet?.distance?this.selectionSet.distance:this.defaultBufferDistance;return s("div",null,s("div",{class:"padding-top-1 display-flex"},s("calcite-label",{class:"label-margin-0 w-100",layout:"inline-space-between"},s("div",{class:"tooltip-container"},this._translations.searchDistance,s("calcite-icon",{class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"search-distance-icon",scale:"s"}))),s("calcite-popover",{closable:!0,label:"",referenceElement:"search-distance-icon"},s("span",{class:"tooltip-message"},this._translations.useSearchDistanceTootip)),s("calcite-switch",{checked:this.searchDistanceEnabled,onCalciteSwitchChange:()=>this.searchDistanceEnabled=!this.searchDistanceEnabled})),s("div",{class:e},s("buffer-tools",{disabled:!this.searchDistanceEnabled,distance:t,geometries:this.geometries,locale:this.locale,onBufferComplete:e=>{this._bufferComplete(e)},ref:e=>this._bufferTools=e,unit:this.selectionSet?.unit||this.defaultBufferUnit})))}_getUseLayerFeaturesOptions(){this.enableLayerFeaturesOnLoad&&(this.useLayerFeaturesEnabled=!0,this.enableLayerFeaturesOnLoad=!1);const e=this.useLayerFeaturesEnabled?"div-visible":"div-not-visible";return s("div",null,s("div",{class:"padding-top-1 display-flex"},s("calcite-label",{class:"label-margin-0 w-100",layout:"inline-space-between"},s("div",{class:"tooltip-container"},this._translations.useLayerFeatures,s("calcite-icon",{class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"use-layer-features-icon",scale:"s"}))),s("calcite-popover",{closable:!0,label:"",referenceElement:"use-layer-features-icon"},s("span",{class:"tooltip-message"},this._translations.useLayerFeaturesTooltip)),s("calcite-switch",{checked:this.useLayerFeaturesEnabled,onCalciteSwitchChange:()=>{this._useLayerFeaturesEnabledChanged()}})),s("div",{class:e+" padding-top-1"},s("map-layer-picker",{enabledLayerIds:this.selectionLayerIds,locale:this.locale,mapView:this.mapView,onLayerSelectionChange:e=>{this._layerSelectionChange(e)},selectedIds:this.layerViews.map((e=>e.layer.id)),showTables:!1})))}_getNumSelected(){const e=l(this.el),t=e&&"en"===e?`${this._translations.selectionLoading}...`:this._translations.selectionLoading;return s("div",{class:"padding-top-1 padding-bottom-1",style:{"align-items":"end",display:"flex"}},this._selectionLoading?s("div",null,s("calcite-loader",{class:"info-blue",inline:!0,label:t,scale:"m",type:"indeterminate"})):s("calcite-icon",{class:"info-blue padding-end-1-2",icon:"feature-layer",scale:"s"}),s("calcite-input-message",{class:"info-blue",scale:"m"},this._selectionLoading?t:this.noResultText&&0===this._numSelected?this.noResultText:this._translations.selectedFeatures.replace("{{n}}",this._numSelected.toString())))}_getNameInput(){return s("div",{class:"padding-sides-1 padding-top-1 "+(this.customLabelEnabled?"":"display-none")},s("calcite-label",{class:"font-bold"},this._translations.listName,s("calcite-input",{onInput:()=>{this._selectionLabel=this._labelName.value},placeholder:this._translations.listNamePlaceholder,ref:e=>{this._labelName=e},value:this._selectionLabel||""})))}_getMapLayerPicker(){return s("div",{class:"display-flex padding-sides-1 padding-bottom-1"},s("calcite-label",{class:"font-bold width-full label-margin-0"},this._translations.inputLayer,s("map-layer-picker",{enabledLayerIds:this.enabledLayerIds,locale:this.locale,mapView:this.mapView,onLayerSelectionChange:e=>{this._inputLayerSelectionChange(e)},selectedIds:this.selectLayerView?[this.selectLayerView.layer.id]:this.selectionSet?[this.selectionSet.layerView.layer.id]:[],showTables:!1})))}async _initModules(){const[e,t,i,s,a,l]=await h(["esri/request","esri/layers/GraphicsLayer","esri/Graphic","esri/widgets/Search","esri/geometry/geometryEngine","esri/layers/FeatureLayer"]);this._esriRequest=e,this.GraphicsLayer=t,this.Graphic=i,this.Search=s,this._geometryEngine=a,this.FeatureLayer=l}async _init(){this._initGraphicsLayer(),await this._initSelectionSet(),await this._initSearchWidget()}async _initSelectionSet(){this.selectionSet&&(this._searchTerm=this.selectionSet.searchResult?.name,this._searchResult=this.selectionSet.searchResult,this._selectLayers=this.selectionSet.selectLayers,this._selectedIds=this.selectionSet.selectedIds,this._skipGeomOIDs=this.selectionSet.skipGeomOIDs,this.searchDistanceEnabled=this.selectionSet.searchDistanceEnabled,this.useLayerFeaturesEnabled=this.selectionSet.useLayerFeaturesEnabled,this._distance=this.selectionSet.searchDistanceEnabled?this.selectionSet.distance:0,this._unit=this.selectionSet.unit,this._workflowType=this.selectionSet.workflowType,this.selectLayerView=this.selectionSet.layerView,this._sketchGraphic=this.selectionSet.sketchGraphic,this.geometries=[...this.selectionSet?.geometries||[]],this._graphics=this.geometries.map((e=>new this.Graphic({geometry:e,symbol:"point"===e.type?this.sketchPointSymbol:"polyline"===e.type?this.sketchLineSymbol:this.sketchPolygonSymbol}))),this._selectionLabel=this.selectionSet?.label,this.useLayerFeaturesEnabled||await(this._drawTools?.updateGraphics()),await r(this.selectionSet.selectedIds,this.selectionSet.layerView,this.mapView,!1))}async _initSearchWidget(){if(this.mapView&&this._searchElement){const e=this._getSearchConfig(this.searchConfiguration,this.mapView),t={view:this.mapView,container:this._searchElement,searchTerm:this._searchTerm,...e};this._searchWidget=new this.Search(t),this._searchWidget.popupEnabled=!1,this._searchWidget.resultGraphicEnabled=!1,this._searchWidget.on("search-clear",(()=>{const e=this._searchClearLabel();this._clearResults(!1,e)})),this._searchWidget.on("select-result",(e=>{this._selectResult(e.result)})),await this._searchWidget.when((()=>{this._searchWidget.allPlaceholder=this.searchConfiguration?.allPlaceholder&&"find address or place"!==this.searchConfiguration.allPlaceholder.toLowerCase()?this.searchConfiguration.allPlaceholder:this._translations.placeholder}))}}async _selectResult(e){if(e){this._searchResult=e;const t=e.feature,i=t?.layer,s=this.selectLayerView.layer,a=t?.getObjectId();let l,h;i?.sourceJSON?.isView&&(l=await this._getViewSourceUrl(i.url)),s?.sourceJSON?.isView&&(h=await this._getViewSourceUrl(s.url));const n=i?.url?.toLowerCase(),r=l?.toLowerCase(),c=s?.url?.toLowerCase(),o=h?.toLowerCase(),d=n&&c&&(n===c||n===o||r===c||r===o)&&!isNaN(a),p=d?[a]:void 0;this._workflowType=y.SEARCH,this._updateLabel();const b=[e.feature];this._updateSelection(b,d,p),this._drawTools.graphics=b,this._searchWidget.resultGraphic.visible=!1}else{const e=this._searchClearLabel();this._clearResults(!1,e)}}async _getViewSourceUrl(e){let t="";const i=`${e}/sources?f=json`;try{const e=await this._esriRequest(i,{query:{f:"json"}});1===e?.data?.services?.length&&(t=e.data.services[0].url)}catch(e){console.log(e)}return t}_searchClearLabel(){return this._searchResult?.name&&this._labelName.value.indexOf(this._searchResult.name)>-1}_getSearchConfig(e,t){const i=e?.sources;return i?.length>0?(e={...e,includeDefaultSources:!1},i.forEach((e=>{if(e.hasOwnProperty("layer")){const i=e,s=i.layer?.id,a=s?t.map.findLayerById(s):null,l=i?.layer?.url;a?i.layer=a:l&&(i.layer=new this.FeatureLayer(l))}})),i?.forEach((e=>{if(e.hasOwnProperty("locator")){const t=e;"ArcGIS World Geocoding Service"===t?.name&&(t.outFields=t.outFields||["Addr_type","Match_addr","StAddr","City"],t.singleLineFieldName="SingleLine"),t.url=t.url,delete t.url}}))):e={...e,includeDefaultSources:!0},e}_initGraphicsLayer(){const e=this._translations.bufferLayer;if(this.mapView){const t=this.mapView.map.layers.findIndex((t=>t.title===e));if(t>-1)this._bufferGraphicsLayer=this.mapView.map.layers.getItemAt(t);else{this._bufferGraphicsLayer=new this.GraphicsLayer({title:e,listMode:"hide"}),w.managedLayers[e]="buffer";const t=this.mapView.map.layers.findIndex((e=>e.title===this._translations.sketchLayer));t>-1?this.mapView.map.layers.add(this._bufferGraphicsLayer,t):this.mapView.map.layers.add(this._bufferGraphicsLayer)}}}async _sketchGraphicsChanged(e,t=!1){const i=e.detail.graphics;if(i.length>0&&i[0])if(t||(this._sketchGraphic=i[0]),this._workflowType=this.useLayerFeaturesEnabled?y.SELECT:y.SKETCH,this._workflowType===y.SKETCH&&await this._drawTools.updateGraphics(),await this._updateLabel(),this._clearSearchWidget(),this.useLayerFeaturesEnabled&&!t){const e=Array.isArray(i)?i.map((e=>e.geometry)):this.geometries;await this._selectLayerFeatures(e[0])}else{const t=i.reduce(((e,t)=>(t?.layer?.objectIdField?e.push(t.attributes[t.layer.objectIdField]):t.getObjectId&&e.push(t.getObjectId()),e)),[]),s=e.detail.useOIDs&&t.length>0;this._updateSelection(i,s,t),s&&await this._highlightFeatures(t)}else await this._clearResults(!0,!0)}async _highlightWithOIDsOrGeoms(){return this._skipGeomOIDs?.length>0?(this._selectedIds=this._skipGeomOIDs,this._highlightFeatures(this._selectedIds)):this._geomQuery(this.geometries)}async _highlightFeatures(e){w.removeHandles(),e.length>0&&w.highlightHandles.push(await c(e,this.selectLayerView,this.mapView)),this._numSelected=e.length,this.selectionSetChange.emit(e.length)}async _selectFeatures(e){this._selectionLoading=!0,this._selectedIds=await o(e,this.selectLayerView.layer),this._selectionLoading=!1,this._drawTools.graphics=this._graphics,await this._highlightFeatures(this._selectedIds)}async _bufferComplete(e){this._bufferGeometry=Array.isArray(e.detail)?e.detail[0]:e.detail;let t=this._bufferTools.distance,i=0;if(this._bufferGeometry){const e=new this.Graphic({geometry:this._bufferGeometry,symbol:{type:"simple-fill",color:this.bufferColor,outline:{color:this.bufferOutlineColor,width:1}}});this._bufferGraphicsLayer.removeAll(),this._bufferGraphicsLayer.add(e),await this._selectFeatures([this._bufferGeometry]),await this.mapView.goTo(e.geometry.extent),i=t,t=0}else this._bufferGraphicsLayer&&this._bufferGraphicsLayer.removeAll(),await this._highlightWithOIDsOrGeoms();await this._distanceChanged({oldValue:t,newValue:i})}_geomQuery(e){const t=d(e,this._geometryEngine);return this._selectFeatures(t)}async _clearResults(e=!0,t=!1){this._selectedIds=[],this._distance=void 0,this._unit=void 0,t&&(this._selectionLabel="",this._labelName&&(this._labelName.value="")),this._bufferGraphicsLayer&&this._bufferGraphicsLayer.removeAll(),e&&this._searchWidget&&this._clearSearchWidget(),w.removeHandles(),this._drawTools?.clear&&(this._graphics=[],await this._drawTools.clear()),this._numSelected=this._selectedIds.length,this.selectionSetChange.emit(this._numSelected)}_clearSearchWidget(){this._searchWidget.clear(),this._searchResult=void 0}_updateSelection(e,t,i){this._selectedIds=t&&i?i:this._selectedIds,this._skipGeomOIDs=t?i:void 0,this.geometries=Array.isArray(e)?e.map((e=>e.geometry)):this.geometries,this._graphics=e}async _updateLabel(){if(this.enableSearchDistance){const e=this._selectionLabel.indexOf(this._translations.sketch)>-1,t=this._selectionLabel.indexOf(this._translations.select)>-1,i=this._selectionLabel.indexOf(this._searchResult?.name)>-1,s=this._workflowType===y.SEARCH?this._searchResult?.name:this._workflowType===y.SELECT?this._translations.select:this._translations.sketch,a=this._unit?this._unit:this._bufferTools.unit,l=await this._bufferTools.getTranslatedUnit(a),h=isNaN(this._distance)?this._bufferTools.distance:this._distance;this._selectionLabel=e||t||i||!this._selectionLabel?`${s} ${h} ${l}`:this._selectionLabel,this._labelName.value=this._selectionLabel}}async _layerSelectionChange(e){if(Array.isArray(e.detail)&&e.detail.length>0){const t=e.detail.map((e=>p(this.mapView,e)));return Promise.all(t).then((e=>{this.layerViews=e,this._featuresCollection={},this._sketchGraphic&&this._sketchGraphicsChanged({detail:{graphics:[this._sketchGraphic],useOIDs:!1}})}))}}async _inputLayerSelectionChange(e){const t=e?.detail?.length>0?e.detail[0]:"";this.selectLayerView&&t===this.selectLayerView.layer.id||(this.selectLayerView=await p(this.mapView,t),await this._updateLabel(),this._bufferGeometry?await this._selectFeatures([this._bufferGeometry]):await this._highlightWithOIDsOrGeoms())}async _distanceChanged(e){e.newValue!==e.oldValue&&(this._distance=e.newValue,await this._updateLabel())}async _selectLayerFeatures(e){this._selectionLoading=!0;const t=this.layerViews.map((t=>(this._featuresCollection[t.layer.id]=[],b(0,t.layer,e,this._featuresCollection))));return Promise.all(t).then((async e=>{this._selectionLoading=!1;let t=[];e.forEach((e=>{Object.keys(e).forEach((i=>{t=t.concat(e[i])}))}));let i=!1;t.forEach((e=>{const t=e.geometry;e.symbol="point"===t.type?this.sketchPointSymbol:"polyline"===t.type?this.sketchLineSymbol:"polygon"===t.type?this.sketchPolygonSymbol:void 0,i=e?.layer?.hasOwnProperty("objectIdField")||e.hasOwnProperty("getObjectId")}));const s=this.layerViews[0].layer,a=this.selectLayerView.layer,l=i&&s.url===a.url&&a.layerId===s.layerId;await this._sketchGraphicsChanged({detail:{graphics:t,useOIDs:l}},!0)}))}_useLayerFeaturesEnabledChanged(){this.useLayerFeaturesEnabled=!this.useLayerFeaturesEnabled,this._sketchGraphic&&this._sketchGraphicsChanged({detail:{graphics:[this._sketchGraphic],useOIDs:!1}})}async _getTranslations(){const e=await n(this.el);this._translations=e[0]}static get watchers(){return{geometries:["watchGeometriesHandler"],locale:["localeWatchHandler"],mapView:["mapViewWatchHandler"],searchConfiguration:["watchSearchConfigurationHandler"]}}};S.style=':host{display:block}.div-visible{display:inherit}.div-visible-search{display:flex;height:44px;align-items:center;padding-bottom:0}.div-not-visible{display:none}.padding-bottom-1{padding-bottom:1rem}.padding-top-1{padding-top:1rem}.search-widget{width:100% !important;border:1px solid var(--calcite-color-border-input)}.w-100{width:100%}.w-50{width:50%}.search-distance-container{padding-top:"1rem" !important}.end-border{border-inline-end:1px solid var(--calcite-color-border-2)}.search-distance{display:flex;padding-top:1rem}.font-bold{font:bold}.border-bottom{border-bottom:1px solid var(--calcite-color-border-2)}.tooltip-container{display:flex}.padding-start-1-2{padding-inline-start:0.5rem}.icon{--calcite-color-icon-color:var(--calcite-color-brand)}.tooltip-message{padding:5px 8px;font-weight:var(--calcite-font-weight-normal);color:var(--calcite-color-text-2)}';const L=Object.freeze({__proto__:null,default:[{descriptionPDF:{labelWidthDisplay:"2-5/8",labelHeightDisplay:"1",labelsPerPageDisplay:"30",averyPartNumber:"*60"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.1875,rightMargin:.1875,topMargin:.5,bottomMargin:.5},numLabelsAcross:3,numLabelsDown:10,labelWidth:2.625,labelHeight:1,horizGapIn:.125,vertGapIn:0,labelPadding:.1,fontSizePx:11,maxNumLabelLines:4}},{descriptionPDF:{labelWidthDisplay:"4",labelHeightDisplay:"1",labelsPerPageDisplay:"20",averyPartNumber:"*61"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.15625,rightMargin:.15625,topMargin:.47637821,bottomMargin:.5},numLabelsAcross:2,numLabelsDown:10,labelWidth:4,labelHeight:1.0025,horizGapIn:.1875,vertGapIn:0,labelPadding:.1,fontSizePx:11,maxNumLabelLines:4}},{descriptionPDF:{labelWidthDisplay:"4",labelHeightDisplay:"1-1/3",labelsPerPageDisplay:"14",averyPartNumber:"*62"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.15625,rightMargin:.15625,topMargin:.81889808,bottomMargin:.83464612},numLabelsAcross:2,numLabelsDown:7,labelWidth:4,labelHeight:1.3352,horizGapIn:.1875,vertGapIn:0,labelPadding:.1,fontSizePx:11,maxNumLabelLines:6}},{descriptionPDF:{labelWidthDisplay:"4",labelHeightDisplay:"2",labelsPerPageDisplay:"10",averyPartNumber:"*63"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.15625,rightMargin:.15625,topMargin:.5,bottomMargin:.5},numLabelsAcross:2,numLabelsDown:5,labelWidth:4,labelHeight:2,horizGapIn:.1875,vertGapIn:0,labelPadding:.1,fontSizePx:12,maxNumLabelLines:10}},{descriptionPDF:{labelWidthDisplay:"4",labelHeightDisplay:"3-1/3",labelsPerPageDisplay:"6",averyPartNumber:"*64"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.15625,rightMargin:.15625,topMargin:.4724412,bottomMargin:.50000027},numLabelsAcross:2,numLabelsDown:3,labelWidth:4,labelHeight:3.342,horizGapIn:.1875,vertGapIn:0,labelPadding:.1,fontSizePx:14,maxNumLabelLines:12}},{descriptionPDF:{labelWidthDisplay:"1-3/4",labelHeightDisplay:"1/2",labelsPerPageDisplay:"80",averyPartNumber:"*67"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.307086375,rightMargin:.307086375,topMargin:.4724412,bottomMargin:.49606326},numLabelsAcross:4,numLabelsDown:20,labelWidth:1.75,labelHeight:.50155,horizGapIn:.29527575,vertGapIn:0,labelPadding:.1,fontSizePx:8,maxNumLabelLines:3}},{descriptionPDF:{labelWidthDisplay:"1-3/4",labelHeightDisplay:"2/3",labelsPerPageDisplay:"60",averyPartNumber:"*95"},labelSpec:{type:"AVERY",pageProperties:{pageType:"ANSI A",leftMargin:.28936983,rightMargin:.28936983,topMargin:.53937037,bottomMargin:.5511814},numLabelsAcross:4,numLabelsDown:15,labelWidth:1.75,labelHeight:.6605,horizGapIn:.30708678,vertGapIn:0,labelPadding:.1,fontSizePx:8,maxNumLabelLines:4}}]}),k=class{constructor(t){e(this,t)}get el(){return i(this)}defaultNumLabelsPerPage;disabled=!1;locale;_translations;_labelInfoElement;_intl;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async downloadCSV(e,t,i,s=!0){return _(e,t,!0,i,s)}async downloadPDF(e,t,i=!1,s="",a=""){return v(e,t,this._labelInfoElement.selectedOption?.value,i,s,a)}async componentWillLoad(){await this._getTranslations(),await this._initModules()}render(){return s(a,{key:"2fd2ec44e8962468e3698b81e98746ddf6b7a3ca"},s("calcite-select",{key:"d24fca5c39aa358116ee8557249f7a4b09727b3f",disabled:this.disabled,label:"",ref:e=>{this._labelInfoElement=e}}))}componentDidLoad(){this._renderOptions()}async _initModules(){const[e]=await h(["esri/intl"]);this._intl=e}_getLabelSizeText(e){const t="&lrm;"+e.descriptionPDF.labelWidthDisplay+" x "+e.descriptionPDF.labelHeightDisplay+"&rlm;";return this._translations.pdfLabel.replace("{{n}}",e.descriptionPDF.labelsPerPageDisplay).replace("{{labelSize}}",t)}async _getTranslations(){const e=await n(this.el);this._translations=e[0]}_renderOptions(){(L.default||L).sort(((e,t)=>{const i=parseInt(e.descriptionPDF.labelsPerPageDisplay,10),s=parseInt(t.descriptionPDF.labelsPerPageDisplay,10);return i<s?-1:i>s?1:0})).forEach(((e,t)=>{const i=document.createElement("calcite-option");i.value=e,i.innerHTML=this._getLabelSizeText(e),this._labelInfoElement.appendChild(i),(this.defaultNumLabelsPerPage?parseInt(e.descriptionPDF.labelsPerPageDisplay,10)===this.defaultNumLabelsPerPage:0===t)&&(i.selected=!0)}))}static get watchers(){return{locale:["localeWatchHandler"]}}};k.style=":host{display:block}";const P=class{constructor(i){e(this,i),this.selectionLoadingChange=t(this,"selectionLoadingChange",7),this.selectionSetsChanged=t(this,"selectionSetsChanged",7)}get el(){return i(this)}addresseeLayer;enabledLayerIds=[];locale;mapView;selectionSets=[];sketchLineSymbol;sketchPointSymbol;sketchPolygonSymbol;_translations;_selectionMode=m.ADD;_refineLayer;_addEnabled=!0;_drawTools;_refineSets=[];_enabledLayerIds=[];_layerPicker;_featuresCollection={};_refineSelectionSet;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}selectionLoadingChange;selectionSetsChanged;async componentWillLoad(){await this._getTranslations(),this._enabledLayerIds=this._getEnabledLayerIds(),await this._setRefineSet(this._enabledLayerIds[0])}render(){return s(a,{key:"8220100e14abd8339947a74df2d8072d06fb2a25"},s("div",{key:"1d7426778d638f347b563bfd29478fae7598e2dd",class:(this._enabledLayerIds.length>1?"display-block":"display-none")+" padding-top-sides-1"},s("div",{key:"cfb649989c24c403bde7d358794933f8f7959bb8",class:"display-flex"},s("calcite-label",{key:"dce85bbfa526941a0fb46c1aeba57f4b028948ef",class:"font-bold width-full label-margin-0"},s("div",{key:"86c19198643381fd99681c53bf0b2b5e66ecf7dc",class:"display-flex"},this._translations.inputLayer,s("calcite-icon",{key:"392022947cd9f53b4b83895992c5b0b32e56fb06",class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"refine-input-layer",scale:"s"})),s("map-layer-picker",{key:"d0946a46e7a79fc613b9eb9aa3e6f896c12bef92",enabledLayerIds:this._enabledLayerIds,locale:this.locale,mapView:this.mapView,onLayerSelectionChange:e=>{this._layerSelectionChange(e)},ref:e=>{this._layerPicker=e},selectedIds:[this._refineLayer.layer.id],showTables:!1})),s("calcite-popover",{key:"3b733fd5e7ceb011446112e65aa1ee1b0c5899c7",closable:!0,label:"",referenceElement:"refine-input-layer"},s("span",{key:"2076104710f4fbdd1de1f31b552b17749ebf9239",class:"tooltip-message"},this._translations.inputLayerTip)))),s("div",{key:"040efdfd6a269244790101cc0712a1cb0bac40d8",class:"padding-1"},s("div",{key:"be963f2cb157fda55980166359e53139a5713405",class:"padding-bottom-1"},s("calcite-segmented-control",{key:"459fa98e8852ea96afd0c9ab5864787f80ff6559",class:"w-100",width:"full"},s("calcite-segmented-control-item",{key:"965fa774838ecd3292c19a430cdbdfc7b44c82b2",checked:this._addEnabled,class:"w-50 word-wrap-anywhere",onClick:()=>this._setSelectionMode(m.ADD),value:m.ADD},s("span",{key:"e0b6fddbded9c78fa98674709ff03f050fd47300",class:"font-weight-500"},this._translations.add)),s("calcite-segmented-control-item",{key:"56e453183fc559ddbce5b041095fad5a8d6262ab",checked:!this._addEnabled,class:"w-50 word-wrap-anywhere",onClick:()=>this._setSelectionMode(m.REMOVE),value:m.REMOVE},s("span",{key:"13593da569557fa57822c98e12a5654cade219a1",class:"font-weight-500"},this._translations.remove)))),s("div",{key:"029fec164d9475274294a1d740a434cab2535cdc"},s("map-draw-tools",{key:"a212c5d21b2b1cdf7ba284a95dacaf83cf0180c9",active:!0,drawMode:u.REFINE,locale:this.locale,mapView:this.mapView,onDrawRedo:()=>this._redo(),onDrawUndo:()=>this._undo(),onSketchGraphicsChange:e=>this._sketchGraphicsChanged(e),pointSymbol:this.sketchPointSymbol,polygonSymbol:this.sketchPolygonSymbol,polylineSymbol:this.sketchLineSymbol,redoEnabled:this._refineSelectionSet?.redoStack.length>0,ref:e=>{this._drawTools=e},undoEnabled:this._refineSelectionSet?.undoStack.length>0})),s("br",{key:"352a0523461cfeeae3bae09ae1cc6f8fa759616b"}),s("calcite-list",{key:"948c7f0aa24d827d29cbc1c2c702deb52134e771",class:"list-border",label:""},this._getRefineSelectionSetList())))}_layerSelectionChange(e){this._setRefineSet(e.detail[0])}_setSelectionMode(e){this._selectionMode=e}_sketchGraphicsChanged(e){const t=e.detail?.graphics[0].geometry;this._selectFeatures(t)}_getEnabledLayerIds(){return this.selectionSets.reduce(((e,t)=>{const i=t?.layerView?.layer.id;return i&&e.indexOf(i)<0?e.push(i):t.workflowType===y.REFINE&&Object.keys(t.refineInfos).forEach((t=>{e.indexOf(t)<0&&e.push(t)})),e}),[])}async _setRefineSet(e){this.selectionSets.some((t=>{if(t.workflowType===y.REFINE)return this._refineSelectionSet=t,Object.keys(t.refineInfos).indexOf(e)>-1}))||await this._initRefineSet(e,this._refineSelectionSet),this._refineLayer=this._refineSelectionSet.refineInfos[e].layerView}async _initRefineSet(e,t){const i={};i[e]={addIds:[],removeIds:[],layerView:await p(this.mapView,e)},t?t.refineInfos={...t.refineInfos,...i}:(this._refineSelectionSet={id:Date.now(),searchResult:void 0,buffer:void 0,distance:0,download:!0,unit:"feet",label:"Refine",selectedIds:[],layerView:void 0,geometries:[],graphics:[],selectLayers:[],workflowType:y.REFINE,searchDistanceEnabled:!1,useLayerFeaturesEnabled:!1,refineInfos:i,redoStack:[],undoStack:[],sketchGraphic:void 0},this.selectionSets.push(this._refineSelectionSet))}_undo(){const e=this._refineSelectionSet.undoStack.pop();this._updateIds(e.ids,e.mode===m.ADD?m.REMOVE:m.ADD,this._refineSelectionSet.redoStack,e.layerView)}_redo(){const e=this._refineSelectionSet.redoStack.pop();this._updateIds(e.ids,e.mode===m.ADD?m.REMOVE:m.ADD,this._refineSelectionSet.undoStack,e.layerView)}_getRefineSelectionSetList(){const e=this._getTotal(this.selectionSets);let t;this.selectionSets.some((e=>{if(e.workflowType===y.REFINE)return t=e,!0}));let i=0,a=0;return Object.keys(t.refineInfos).forEach((e=>{i+=t.refineInfos[e].addIds.length,a+=t.refineInfos[e].removeIds.length})),[s("calcite-list-item",{label:this._translations.featuresAdded.replace("{{n}}",i.toString()),"non-interactive":!0}),s("calcite-list-item",{label:this._translations.featuresRemoved.replace("{{n}}",a.toString()),"non-interactive":!0}),s("calcite-list-item",{label:this._translations.totalSelected.replace("{{n}}",e.toString()),"non-interactive":!0})]}_getTotal(e){const t=f(e);return Object.keys(t).reduce(((e,i)=>e+t[i].ids.length),0)}async _getTranslations(){const e=await n(this.el);this._translations=e[0]}async _selectFeatures(e){this.selectionLoadingChange.emit(!0),this._featuresCollection[this._refineLayer?.layer.id]=[];const t=await b(0,this._refineLayer?.layer,e,this._featuresCollection);this.selectionLoadingChange.emit(!1);let i=[];Object.keys(t).forEach((e=>{e===this._refineLayer?.layer.id&&(i=i.concat(t[e]))}));const s=Array.isArray(i)?i.map((e=>e.attributes[e?.layer?.objectIdField])):[];await this._updateIds(s,this._selectionMode,this._refineSelectionSet.undoStack,this._refineLayer),this._drawTools.clear()}async _highlightFeatures(){this._clearHighlight(),w.highlightHandles=await g(this.selectionSets)}_clearHighlight(){w.removeHandles()}async _updateIds(e,t,i,s){let a=!1;const l=this._refineSelectionSet.refineInfos,h=s.layer.id,n={};n[h]={addIds:[],removeIds:[],layerView:s};const r=Object.keys(l).indexOf(h)>-1?l[h]:n[h];if(t===m.ADD)r.addIds=[...new Set([...e,...r.addIds])],r.addIds.length>0&&i.push({ids:e,mode:t,layerView:s}),r.removeIds.length>0&&(r.removeIds=r.removeIds.filter((t=>e.indexOf(t)<0)));else{const l=this.selectionSets.reduce(((t,i)=>(e.forEach((e=>{i.workflowType!==y.REFINE?i.selectedIds.indexOf(e)>-1&&t.push(e):Object.keys(i.refineInfos).some((a=>{const l=i.refineInfos[a];if(l.layerView.layer.id===s.layer.id&&l.addIds.indexOf(e)>-1)return t.push(e),!0}))})),t)),[]);r.removeIds=[...new Set([...l,...r.removeIds])],r.addIds=r.addIds.filter((e=>l.indexOf(e)<0)),r.removeIds.length>0&&i.push({ids:l,mode:t,layerView:s}),this.selectionSets=this.selectionSets.reduce(((e,t)=>(t.workflowType!==y.REFINE&&t.layerView.layer.id===s.layer.id?(t.selectedIds=t.selectedIds.filter((e=>r.removeIds.indexOf(e)<0)),t.selectedIds.length>0?e.push(t):a=!0):e.push(t),e)),[])}this._refineSelectionSet.refineInfos[h]=r,this.selectionSets=[...this.selectionSets],a&&this.selectionSetsChanged.emit(this.selectionSets),await this._highlightFeatures()}static get watchers(){return{locale:["localeWatchHandler"]}}};P.style=':host{display:block}.div-visible{display:inherit}.div-not-visible{display:none !important}.padding-top-1-2{padding-top:.5rem}.main-label{display:flex;float:left}html[dir="rtl"] .main-label{display:flex;float:right}.border{outline:1px solid var(--calcite-color-border-input)}.margin-top-1{margin-top:1rem}.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:bold}.width-full{width:100%}.label-margin-0{--calcite-label-margin-bottom:0}.padding-start-1-2{padding-inline-start:0.5rem}.font-weight-500{font-weight:500}.word-wrap-anywhere{word-wrap:anywhere}';export{S as map_select_tools,k as pdf_download,P as refine_selection}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,g as e,h as i,H as a,c as s}from"./p-1b0588d2.js";import{g as n}from"./p-ee2cbba0.js";import{s as c}from"./p-8b218ba7.js";import{d as o}from"./p-80cb7c73.js";import{E as l}from"./p-4f236b5d.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-e23b4193.js";import"./p-570b13d9.js";import"./p-0668e30d.js";const d=class{constructor(e){t(this,e)}get el(){return e(this)}hasChanges=!1;hasErrors=!1;instanceid="";locale;value="";async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}componentDidLoad(){const t=document.getElementById(`${this.instanceid}-container`);if(t){this._editor=monaco.editor.create(t,{value:this.value,language:"json",theme:"vs",minimap:{enabled:!1},automaticLayout:!0,scrollBeyondLastLine:!1}),this._currentModel=this._editor.getModel(),this._contentChanged=this._currentModel.onDidChangeContent(this._onEditorChange.bind(this));const e=monaco.editor.setModelMarkers,i=this;monaco.editor.setModelMarkers=function(t,a,s){t.id===i._currentModel.id&&(i._flagEditorHasErrors(s.length>0),i.hasErrors||(i._flagEditorHasChanges(i._currentModel?.canUndo()),i._currentModel?.canUndo()&&i._flagEditorContentChanged()),document.getElementById(`${i.instanceid}-errorFlag`).style.visibility=i.hasErrors?"visible":"hidden"),e.call(monaco.editor,t,a,s)},this._diffEditor=monaco.editor.createDiffEditor(document.getElementById(`${this.instanceid}-diff-container`),{automaticLayout:!0}),this._setDiffModel(),this._loaded=!0,this._toggleUndoRedo()}}async componentWillLoad(){this._initValueObserver(),await this._getTranslations()}render(){return i(a,{key:"e9c806dbfc886daac9be93350e461246339787dd"},i("div",{key:"5f31103bc0392042581d1421530f2ddcdebcc507",id:`${this.instanceid}-editor-container`,class:"editor-container padding-right"},i("div",{key:"560c74b9864cd94f4e689bf65cb8e1fac42b94af",class:"editor-controls"},i("div",{key:"73ca9ac97f3d40fb408e98477641a9d94e1cd32e",class:"editor-buttons"},i("calcite-icon",{key:"2d83934e4493595f66e047c608a87e316279ec1b",id:`${this.instanceid}-errorFlag`,icon:"exclamation-mark-triangle",title:this._translations.errorFlag,scale:"s",class:"edit-error-flag"}),i("calcite-button",{key:"fe95dd90ec0db23c6d6d6766d6d405c32468cec1",id:`${this.instanceid}-undo`,color:"blue",appearance:"solid",title:this._translations.undo,onClick:()=>this._undo(),scale:"s",class:"edit-button"},i("calcite-icon",{key:"d802118d2ac7b8cbf2750f3af11252fd52173dd0",icon:"undo",scale:"s"})),i("calcite-button",{key:"9e9af33be6b712ff83ec70e024776c2429086761",id:`${this.instanceid}-redo`,color:"blue",appearance:"solid",title:this._translations.redo,onClick:()=>this._redo(),scale:"s",class:"edit-button"},i("calcite-icon",{key:"bb5bfd3a99902b03c4ffb704b8fdc963c006e664",icon:"redo",scale:"s"})),i("calcite-button",{key:"a88fcffeb9c82394470717ebc6659b42ad9a1c20",id:`${this.instanceid}-diff`,color:"blue",appearance:"solid",title:this._translations.diff,onClick:()=>this._toggleEditor(),scale:"s",class:"edit-button"},i("calcite-icon",{key:"f902baf72fee24ef3b56da2c4d9337db96ab63b1",icon:"compare",scale:"s"})),i("calcite-button",{key:"841abd705338fb1e43c892c4858bff00591958c3",id:`${this.instanceid}-search`,appearance:"outline",color:"blue",title:this._translations.search,onClick:()=>this._search(),scale:"s",class:"edit-button"},i("calcite-icon",{key:"01c24bdbf30cd22a06064bf26a47b38516508879",icon:"search",scale:"s"})),i("calcite-button",{key:"2d6b9dc60e26e347272c76ff9f8ada529975265b",id:`${this.instanceid}-reset`,color:"blue",appearance:"solid",disabled:!0,title:this._translations.cancelEdits,onClick:()=>this._reset(),scale:"s",class:"edit-button"},i("calcite-icon",{key:"a373dc694d97992dfbd60f49f38536ba34684381",icon:"reset",scale:"s"})))),i("div",{key:"6cdebae478b9d1b61e317155000bf62ad4c5b8a3",class:"edit-parent"},i("div",{key:"e3914618f86335e9538969b5cb7f7797212985c2",id:`${this.instanceid}-container`,class:"json-edit-container"}),i("div",{key:"4a17fd062060ddf2e5dca5c2fb6c9883ed9aadd4",id:`${this.instanceid}-diff-container`,class:"json-edit-container display-none"}))))}_cancelEditsBtnHandler;_contentChanged;_currentModel;_diffEditor;_editor;_loaded=!1;_searchBtnHandler;_translations;_useDiffEditor=!1;_valueObserver;async getEditorContents(){return new Promise(((t,e)=>{try{t(this._currentModel.getValue())}catch(t){e(t)}}))}async prepareForDeletion(){this._searchBtnHandler?.removeEventListener("click",this._search),this._cancelEditsBtnHandler?.removeEventListener("click",this._reset),this._valueObserver?.disconnect(),this._contentChanged?.dispose(),this._editor?.dispose()}async replaceCurrentSelection(t){const e=this._editor.getSelection();this._editor.executeEdits("",[{range:e,text:t}])}async reset(){return new Promise(((t,e)=>{try{this._reset(),t({success:!0})}catch(t){e(t)}}))}_disableButton(t){document.getElementById(t)?.setAttribute("disabled","")}_enableButton(t){document.getElementById(t)?.removeAttribute("disabled")}_flagEditorContentChanged(){window.dispatchEvent(new CustomEvent("solutionEditorContentChanged",{detail:{id:this.instanceid,contents:this._currentModel.getValue()},bubbles:!0,cancelable:!1,composed:!0}))}_flagEditorHasChanges(t){this.hasChanges!==t&&(window.dispatchEvent(new CustomEvent("solutionEditorHasChanges",{detail:t,bubbles:!0,cancelable:!1,composed:!0})),this.hasChanges=t)}_flagEditorHasErrors(t){this.hasErrors!==t&&(window.dispatchEvent(new CustomEvent("solutionEditorHasErrors",{detail:t,bubbles:!0,cancelable:!1,composed:!0})),this.hasErrors=t)}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}_initValueObserver(){this._valueObserver=new MutationObserver((t=>{t.forEach((t=>{"attributes"===t.type&&"value"===t.attributeName&&t.target[t.attributeName]!==t.oldValue&&this._loaded&&this._currentModel.setValue(this.value)}))})),this._valueObserver.observe(this.el,{attributes:!0,attributeOldValue:!0})}_onEditorChange(){this._toggleUndoRedo()}_redo(){this._currentModel?.canRedo()&&(this._currentModel.redo(),this._toggleUndoRedo())}_reset(){this._currentModel.setValue(this.value),this._toggleUndoRedo()}_search(){this._editor.trigger("toggleFind","actions.find")}_setDiffModel(){this._diffEditor&&this._diffEditor.setModel({original:monaco.editor.createModel(this.value,"json"),modified:this._editor.getModel()})}_toggleEditor(){this._useDiffEditor=!this._useDiffEditor;let t=document.getElementById(`${this.instanceid}-diff-container`),e=document.getElementById(`${this.instanceid}-container`);this._useDiffEditor?(this._setDiffModel(),t.classList.remove("display-none"),e.classList.add("display-none")):(t.classList.add("display-none"),e.classList.remove("display-none"))}_toggleUndoRedo(){this._currentModel?.canUndo()?this._enableButton(`${this.instanceid}-undo`):this._disableButton(`${this.instanceid}-undo`),this._currentModel?.canRedo()?this._enableButton(`${this.instanceid}-redo`):this._disableButton(`${this.instanceid}-redo`),this._currentModel?.canUndo()||this._currentModel?.canRedo()?this._enableButton(`${this.instanceid}-reset`):this._disableButton(`${this.instanceid}-reset`)}_undo(){this._currentModel?.canUndo()&&(this._currentModel.undo(),this._toggleUndoRedo())}static get assetsDirs(){return["assets"]}static get watchers(){return{locale:["localeWatchHandler"]}}};d.style=":host{display:block}.editor-container{position:relative;height:100%}.editor-controls{height:2.75rem;padding-right:0.5rem;background-color:#F4F4F4}.editor-buttons{float:right}html[dir=rtl] .editor-buttons{float:left}.edit-error-flag{padding-top:0.5rem;color:red;visibility:hidden}.edit-button{padding-inline-start:0.5rem}.editor-text{width:100%;overflow-y:auto;background-color:#FFFFFF}.edit-width{width:100%}.edit-parent{box-sizing:border-box;width:100%;height:calc(100% - 46px)}.json-edit-container{height:100%;width:100%;border:1px #808080 solid}.padding-right{padding-inline-end:0.125rem}.btn{margin-bottom:1rem;display:flex;align-content:center;height:25px;width:120px}.select-ctrl{margin-bottom:1rem}.all-edits{margin-top:4rem}.floating-title{font-size:2rem;z-index:100;position:absolute;left:0.5rem;pointer-events:none}.floating-title-button{pointer-events:auto}.json-editor-position1{position:absolute;left:0px;top:0px;margin:0px;height:100%;width:100%;overflow:hidden;padding:0px;max-height:100% !important}.json-editor-position2a{position:absolute;left:0px;top:0px;margin:0px;height:100%;width:50%;overflow:hidden;padding:0px;max-height:100% !important}.json-editor-position2b{position:absolute;right:0px;top:0px;margin:0px;height:100%;width:50%;overflow:hidden;padding:0px;max-height:100% !important}";const r=class{constructor(e){t(this,e)}get el(){return e(this)}itemId="";locale;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async componentWillLoad(){return this._getTranslations()}async componentWillRender(){return this.itemEdit=c.getItemInfo(this.itemId),this.itemEdit&&(this.itemDetails=this.itemEdit.item,this.itemType=this.itemDetails.type),Promise.resolve()}render(){return i(a,{key:"8ad2bab229a9ee6cd80efde17d269a484288f5ae"},i("div",{key:"a066afedf3e5ea056579e07cac6c38496fe00d79",class:"parent-container"},i("div",{key:"fe7d207e2d28f0e70507ef048d993bc3ddc62297",class:"inputBottomSeparation"},i("calcite-input",{key:"f0714ef845c9b4aa791e3fc6f5ac28fe6572127d",id:"item-title",value:this.itemDetails.title})),i("div",{key:"40b6f0d4d34ff62134f25fdd42887f395407aa45",class:"inputBottomSeparation"},i("input",{key:"216060434e37ff499a47b4cc24d7682ac6e55ba7",accept:".jpg,.gif,.png,image/jpg,image/gif,image/png",class:"display-none",onChange:t=>this._updateThumbnail(t),ref:t=>this.browseForThumbnail=t,type:"file"}),i("button",{key:"a6b71fac06b9231a91b32a0416cb3a723b6ac6dd",class:"font-size--3 btn-link inline-block trailer-quarter",onClick:()=>this._getThumbnail()},i("svg",{key:"395adfcd43d737fe049f765b3700d7358c06e8a0",class:"icon-inline icon-inline--on-left",height:"16",viewBox:"0 0 16 16",width:"16"},i("path",{key:"5e541a3fcb79fe3a306b720a08e745f0dd69d557",d:"M14.792 2.666l-1.414-1.413a.965.965 0 0 0-1.385-.03l-1.444 1.444-8.763 8.72L.03 15.481a.371.371 0 0 0 .488.488l4.096-1.756 8.763-8.72-.001-.001.002.002 1.443-1.444a.965.965 0 0 0-.03-1.385zM1.569 14.431l.554-1.293.74.739zm2.338-.924l-1.414-1.414 7.963-7.92 1.414 1.415zm8.67-8.626l-1.413-1.414 1.29-1.29a.306.306 0 0 1 .433 0l.981.98a.306.306 0 0 1 0 .433z"})),this._translations.editThumbnail),i("div",{key:"e6dc45b53a0deac24d29a7be29569c55857a7801",class:"flex"},i("div",{key:"8c81b6db29e4b03a5188e729eb8e27b8dcf22e5f",class:"img-container",ref:t=>this.thumbnailContainer=t},i("img",{key:"cfbfad50a4eb55166cb49be45a20f680b7d482d3",class:"scale-down",height:"133",id:"item-thumbnail",ref:t=>this.thumbnail=t,width:"200"})),i("div",{key:"0cf010a87106c0434ff7d54f7889bc2eb08fd733",class:"snippet-count-container"},i("calcite-input",{key:"85eedc1b801db3afdc2dfb606aa93de489bac491",id:"item-snippet",maxLength:250,type:"textarea",value:this.itemDetails.snippet}),i("label",{key:"783be9f5082085add36a16f1a8bc55ecc11dc7e8",class:"font-size--3",id:"item-snippet-count",ref:t=>this.itemSnippetCount=t})))),i("calcite-label",{key:"63bdfb42b95d1e8086e792efd757919676230354"},this._translations.description,i("label",{key:"aa9056a2807d9fd14c7dcd81775d902a30a2df63",id:"item-description-label"},i("calcite-input",{key:"61d584f29afd305913039e0cf4d6be7d54f1aa2f",id:"item-description",type:"textarea",value:this.itemDetails.description}))),i("calcite-label",{key:"4daf0f44b2b14274fe8992bad5607c8ba82d6fa4"},this._translations.tags,i("label",{key:"142f41ae1667c916e2ef32e7b7eb9aacad80e17d",id:"item-tags-label"},i("calcite-input",{key:"2f576b51a68370ce1112b999c35eef0714595e9f",id:"item-tags",value:(this.itemDetails.tags&&Array.isArray(this.itemDetails.tags)?this.itemDetails.tags:[this.itemDetails.tags]).join(",")}))),"Group"!==this.itemType?i("calcite-label",null,this._translations.credits,i("label",{id:"item-credits-label"},i("calcite-input",{id:"item-credits",value:this.itemDetails.accessInformation}))):null,"Group"!==this.itemType?i("calcite-label",null,i("label",{id:"item-terms-label"},this._translations.termsOfUse,i("calcite-input",{id:"item-terms",type:"textarea",value:this.itemDetails.licenseInfo}))):null))}componentDidRender(){this._loadThumb()}browseForThumbnail;itemDetails={accessInformation:"",description:"",licenseInfo:"",snippet:"",tags:[],title:""};itemEdit;itemType;_translations;itemSnippetCount;thumbnail;thumbnailContainer;inputReceivedHandler(t){switch(t.target.id){case"item-title":this.itemDetails.title=t.target.value,this._updateStore();break;case"item-snippet":t.target.value.length>250&&(t.target.value=t.target.value.substring(0,250)),this.itemDetails.snippet=t.target.value,this._updateLengthLabel(this.itemDetails.snippet),this._updateStore();break;case"item-description":this.itemDetails.description=t.target.value,this._updateStore();break;case"item-tags":this.itemDetails.tags=t.target.value,this._updateStore();break;case"item-credits":this.itemDetails.accessInformation=t.target.value,this._updateStore();break;case"item-terms":this.itemDetails.licenseInfo=t.target.value,this._updateStore()}}_getThumbnail(){this.browseForThumbnail.click()}_loadThumb(){this.thumbnail&&this.itemEdit?.thumbnail?(this.thumbnail.src=URL.createObjectURL(this.itemEdit.thumbnail),this.thumbnailContainer.classList.remove("empty-box"),this.thumbnail.classList.remove("display-none")):(this.thumbnailContainer.classList.add("empty-box"),this.thumbnail.classList.add("display-none"))}_updateLengthLabel(t){this.itemSnippetCount.innerText=this._translations.snippetCountPattern.replace("{{n}}",t.length.toString())}_updateStore(){this.itemEdit=c.getItemInfo(this.itemId),this.itemEdit.item=this.itemDetails,c.setItemInfo(this.itemEdit)}_updateThumbnail(t){const e=t.target.files;e&&e[0]&&this.thumbnail&&(this.thumbnail.src=URL.createObjectURL(e[0]),this.itemEdit=c.getItemInfo(this.itemId),this.itemEdit.thumbnail=e[0],c.replaceItemThumbnail(this.itemEdit))}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{locale:["localeWatchHandler"]}}};r.style=".inputBottomSeparation{margin-left:0px;margin-right:0px;margin-top:0px;margin-bottom:1.5rem}.icon-inline--on-left,.icon-inline--on-right{display:inline;vertical-align:middle;margin-inline-end:0.375rem;fill:#0079c1}.scale-down{-o-object-fit:scale-down;object-fit:scale-down}.img-container{display:inline;margin-inline-end:1rem;max-width:363px}.summary-count-container{display:inline;flex-grow:1;margin-inline-start:0.75rem}.snippet-count-container{width:calc(100vw - 363px)}.parent-container{max-width:100%;padding:1rem}label{position:relative;margin-left:0px;margin-right:0px;margin-top:0px;margin-bottom:1.5rem;display:block;min-width:-moz-min-content;min-width:min-content}";const h=class{constructor(e){t(this,e)}get el(){return e(this)}groupId="";locale;itemIdWatchHandler(){const t=c.getItemInfo(this.groupId);this.sharing=t.groupDetails}async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async componentWillLoad(){return this._getTranslations()}render(){return i(a,{key:"1c7dbee68fbf0eabf736fb783f173ade2f408122"},i("div",{key:"3c3d88ab122d4a8bc69363224a2754c4a4b092ba",class:"container-border"},i("calcite-label",{key:"137bb704b258a3cd1e5e5b7a18c53aca331d7f91"},this._translations.groupInfo),this._renderItems(this.sharing)))}_translations;sharing=[];async getShareInfo(){return this.sharing}_renderItems(t){return t&&t.length>0?t.map((t=>i("calcite-label",{layout:"inline"},i("calcite-switch",{checked:t.shareItem,id:t.id,name:"setting",onCalciteSwitchChange:t=>this._updateItem(t),scale:"m",value:"enabled"}),i("solution-item-icon",{type:t.type,typeKeywords:t.typeKeywords}),i("span",{class:"icon-text",title:t.title},t.title)))):null}_updateItem(t){const e=t.target.id;this.sharing=this.sharing.map((i=>{if(i.id===e){i.shareItem=t.target.checked;const a=c.getItemInfo(e);if(i.shareItem)a.groups?a.groups.indexOf(this.groupId)<0&&a.groups.push(this.groupId):a.groups=[this.groupId];else if(a.groups){const t=a.groups.indexOf(this.groupId);t>-1&&a.groups.splice(t,1)}c.setItemInfo(a)}return i}))}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{groupId:["itemIdWatchHandler"],locale:["localeWatchHandler"]}}};h.style=":host{display:block}.container-border{padding:1rem}.icon-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}";const b=class{constructor(e){t(this,e),this.organizationVariableSelected=s(this,"organizationVariableSelected",7)}get el(){return e(this)}locale;value="";async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}valueWatchHandler(){this._organizationVariables=JSON.parse(this.value)}async componentWillLoad(){return this._getTranslations()}render(){return i(a,{key:"3f72a5c1b8fb6bcdab858ee061eadb38cb9965d9"},i("div",{key:"118c7cafc8330c44e72a59a76fd81ca0f39696e1"},i("h4",{key:"86934bdf3cbf162a732a53579e324c5fff8beead",class:"org-var-header"},this._translations.orgVariables)),i("div",{key:"ed5c1df397286a7d1c8e61b5ce04623fa13d74cc",class:"container-border"},i("calcite-tree",{key:"47f4f9bf5a81ded9a37a33a94fac6a230263e917",id:"variable-label"},this._renderHierarchy(this._organizationVariables))))}_organizationVariables=[];_translations;organizationVariableSelected;_renderHierarchy(t){return t.map((t=>i("calcite-tree-item",{onClick:()=>this._treeItemSelected(t.id,t.value)},t.title)))}_treeItemSelected(t,e){this.organizationVariableSelected.emit({itemId:t,value:e})}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{locale:["localeWatchHandler"],value:["valueWatchHandler"]}}};b.style=":host{display:block}.container-border{overflow-y:auto}.org-var-header{margin-left:0px;margin-right:0px;margin-top:0px;margin-bottom:1rem}";const f=class{constructor(e){t(this,e)}get el(){return e(this)}authentication;itemId="";locale;itemIdWatchHandler(){const t=c.getItemInfo(this.itemId);this.resourceFilePaths=t.resourceFilePaths,this.resources=t.resources.map((t=>t.substring(t.lastIndexOf("/")+1)))}async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}componentWillLoad(){return this._getTranslations()}render(){const t=this._hasValidResources();return i(a,{key:"13f2759a882d2eca48bf9dda58e74caade76142b"},i("div",{key:"498ced2e29b8af9138a8aa9d77ec78e07e3c64de",class:"resource-item"},i("div",{key:"d76a967373a990906a67d88ea6466030c41401ff",class:"margin-bottom-1"},i("calcite-button",{key:"96cd2ee08adadef9e1b29db12c38d4748b0689c0",appearance:"solid",class:"resource-button",color:"blue",onClick:()=>this._addNewResource()},this._translations.addResource),i("calcite-button",{key:"49326139cad065995512d3e3568c7d8e7f5cef4f",appearance:"solid",color:"blue",disabled:!t,onClick:()=>this._downloadAll()},this._translations.downloadAll)),i("div",{key:"9c056d9ab7242ea10cbcf57eaabce4bd9777541e",class:"resources-container",style:{display:t?"inherit":"none"}},this._renderResourceList())))}resourceFilePaths=[];resources=[];_translations;_removedResources={};_renderResourceList(){return i("calcite-value-list",{multiple:!0},this.resourceFilePaths.reduce(((t,e)=>(e.type!==l.Thumbnail&&t.push(this._renderResource(e)),t)),[]))}_renderResource(t){const e=t.updateType===o.Remove;return i("calcite-value-list-item",{class:e?"disabled":"",label:t.folder?t.folder+"/"+t.filename:t.filename,nonInteractive:!0,value:t.url},i("calcite-action-group",{"expand-disabled":"true",layout:"horizontal",slot:"actions-end"},i("calcite-action",{disabled:e,icon:"download",label:this._translations.download,onClick:()=>this._download(t.url,t.filename),scale:"m",text:this._translations.download,title:this._translations.download}),i("calcite-action",{disabled:e,icon:"upload-to",label:this._translations.update,onClick:()=>this._upload(t),scale:"m",text:this._translations.update,title:this._translations.update}),i("calcite-action",{disabled:e,icon:"trash",label:this._translations.delete,onClick:()=>this._delete(t),scale:"m",text:this._translations.delete,title:this._translations.delete}),e?i("calcite-action",{icon:"reset",label:this._translations.reset,onClick:()=>this._reset(t.filename),scale:"m",text:this._translations.reset,title:this._translations.reset}):i("div",{class:"display-none"})))}_delete(t){t.updateType=o.Remove,this.resourceFilePaths=[...this.resourceFilePaths],this._updateStore()}_reset(t){this.resourceFilePaths=this.resources.some((e=>e===t))?this.resourceFilePaths.map((e=>(e.filename===t&&(e.updateType=o.None),e))):this.resourceFilePaths.map((e=>(e.filename===t&&(e.updateType=o.Add),e))),this._updateStore()}_downloadAll(){this.resourceFilePaths.forEach((t=>{this._download(t.url,t.filename)}))}_download(t,e){t.startsWith("blob")?this.downloadFile(t,e):this.fetchAndDownload(`${t}?token=${this.authentication.token}`,e)}downloadFile(t,e){const i=document.createElement("a");i.href=t,i.download=e,i.target="_blank",i.click()}_hasValidResources(){return this.resourceFilePaths.some((t=>t.url.indexOf("_info_thumbnail")<0))}async fetchAndDownload(t,e){const i=await fetch(t),a=await i.blob(),s=URL.createObjectURL(a);this.downloadFile(s,e)}_upload(t){const e=document.createElement("input");e.classList.add("display-none"),e.onchange=this._updateResource.bind(this,t),e.type="file",e.click()}_addNewResource(){const t=document.createElement("input");t.classList.add("display-none"),t.onchange=this._add.bind(this),t.type="file",t.click()}_updateResource(t,e){const i=e.target.files;i&&i[0]&&(t.blob=i[0],t.updateType=o.Update,this._updateStore())}_add(t){const e=t.target.files;if(e&&e[0]){const t=URL.createObjectURL(e[0]),i=e[0].name;this.resourceFilePaths.some((e=>e.filename===i&&e.url===t))||(this.resourceFilePaths=[...this.resourceFilePaths,{url:t,type:l.Data,folder:void 0,filename:i,blob:e[0],updateType:o.Add}],this._updateStore())}}_updateStore(){const t=c.getItemInfo(this.itemId);t.resourceFilePaths=this.resourceFilePaths,c.setItemInfo(t)}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{itemId:["itemIdWatchHandler"],locale:["localeWatchHandler"]}}};f.style=":host{display:block}.resource-item{padding:1rem}.resource-button{margin-inline-end:1rem}.resource-progress{padding-top:1rem}.resources-container{border:1px #808080 solid}.margin-bottom-1{margin-bottom:1rem}";const p=class{get el(){return e(this)}instanceid="";itemId="";itemIdWatchHandler(){this._initializing=!0,this.value=JSON.stringify("data"===this.instanceid?c.getItemInfo(this.itemId).data:c.getItemInfo(this.itemId).properties,null,2)}locale;organizationVariables="";solutionVariables="";varsOpen=!0;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}constructor(e){t(this,e),window.addEventListener("solutionEditorContentChanged",(t=>{if(this.itemId){const{id:e,contents:i}=t.detail,[a,s]=e.split("|");if(a==this.itemId&&s===this.instanceid){if(!this._initializing&&i.length>0){const t=c.getItemInfo(a);"data"===s?t.data=JSON.parse(i):t.properties=JSON.parse(i),c.setItemInfo(t)}this._initializing=!1}}}))}componentWillLoad(){return this._getTranslations()}render(){return i(a,{key:"3f853006c19509c8cf484d4420b3f687aaad5161"},i("div",{key:"f524e1ee3c8dc972779be0909372c11c26092dd0",class:"solution-data-container"},i("calcite-shell",{key:"56797702bc53b08051360975dc529c884eb7d294",class:"light var-container",dir:"ltr"},i("calcite-panel",{key:"6208ac7b63ab8b69bc29ad88abdb9bcdeaaa707a",class:"json-editor"},i("div",{key:"66e99550359b5665b4dd04f794d8108e4ee34284",class:"solution-data-child-container calcite-match-height"},i("json-editor",{key:"7a7f5afa5d424fb6099b7167f274ce211e791a56",class:"solution-data-editor-container",instanceid:this.itemId+"|"+this.instanceid,locale:this.locale,value:this.value}))),i("calcite-shell-panel",{key:"7cc8bac91bfc5be96018d005cc87be457278ed6d","height-scale":"l",position:"end",slot:"contextual-panel","width-scale":"xs"},i("div",{key:"4ce0c251d30d5735781394f5c213523867205886",class:this.varsOpen?"solution-data-child-container":"solution-data-child-container-collapsed"},i("calcite-button",{key:"814c8996b854102b022f7ac482498dd6aac36ec8",appearance:"transparent",class:"collapse-btn","icon-start":this.varsOpen?"chevrons-right":"chevrons-left",id:"collapse-vars",onClick:()=>this._toggleVars(),scale:"s",title:this.varsOpen?this._translations.collapse:this._translations.expand}),i("div",{key:"6b872cfc1c60870fb6262808f5d9f61cc35f0f44",class:this.varsOpen?"org-vars":"org-vars display-none",id:"orgVars"},i("solution-organization-variables",{key:"e8e9ee594b6dcb5ddaabd05c322fb33d568ac7b5",locale:this.locale,value:this.organizationVariables})),i("div",{key:"109d17a77a54a13818af6aa2a9beb92526100ea7",class:this.varsOpen?"sol-vars":"sol-vars display-none",id:"solVars"},i("solution-variables",{key:"46902ed69897ed01334def99817fedafbda2e8d5",locale:this.locale,value:this.solutionVariables})))))))}_translations;value="";_initializing=!1;_toggleVars(){this.varsOpen=!this.varsOpen}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{itemId:["itemIdWatchHandler"],locale:["localeWatchHandler"]}}};p.style=":host{display:flexbox}.solution-data-container{position:absolute;height:-moz-available;height:calc(100% - 48px);height:-webkit-fill-available;height:stretch;width:-moz-available;width:100%;width:-webkit-fill-available;width:stretch}.solution-data-child-container{display:flex;height:100%;width:100%;flex-direction:column;overflow-y:auto}.solution-data-editor-container{height:100%}.solution-data-child-container-collapsed{display:flex;height:100%;flex-direction:column;overflow:auto;width:50px}.inputBottomSeparation{margin-left:0px;margin-right:0px;margin-top:0px;margin-bottom:1.5rem}.json-editor{margin:1rem;width:auto;width:-webkit-fill-available -moz-available}.collapse-btn{padding-left:1rem;padding-right:1rem;padding-top:1rem;padding-bottom:0px}.org-vars{padding-left:1rem;padding-right:1rem;padding-top:1rem;padding-bottom:0px}.sol-vars{padding-top:0px;padding-bottom:0px;padding-left:1rem;padding-right:1rem;min-height:45%}.padding-1{padding:1rem}.light{background-color:#F4F4F4}";const u=class{constructor(e){t(this,e),this.solutionVariableSelected=s(this,"solutionVariableSelected",7)}get el(){return e(this)}value="";locale;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}valueWatchHandler(){this._solutionVariables=JSON.parse(this.value)}componentWillLoad(){return this._getTranslations()}render(){return i(a,{key:"a90cdfc9a32279cb07938fc57f9dd7e38d822f6d"},i("div",{key:"6826e3dd84034368f419ff759962a721a275dc9c"},i("h4",{key:"5ebdf456e8c4dc006b036dc182fa75218aac0e01",class:"org-var-header"},this._translations.solVariables)),i("div",{key:"06fc04c1e61dc1897989e3cc11df7b173f1fdb2a",class:"container-border"},i("calcite-tree",{key:"15500194129af7440ec05dc495b060fc18f22324",id:"variable-label"},this._renderHierarchy(this._solutionVariables))))}_solutionVariables=[];_translations;solutionVariableSelected;_renderHierarchy(t){return t.map((t=>t.dependencies&&t.dependencies.length>0?i("calcite-tree-item",{onClick:t=>this._toggleExpand(t)},i("solution-item-icon",{type:t.type}),i("span",{class:"icon-text",title:t.title},t.title),i("calcite-tree",{slot:"children"},this._renderHierarchy(t.dependencies))):i("calcite-tree-item",{onClick:()=>this._treeItemSelected(t.id,t.value)},t.title)))}_treeItemSelected(t,e){this.solutionVariableSelected.emit({itemId:t,value:e})}_toggleExpand(t){const e=t?.target?.closest("calcite-tree-item");e&&(e.expanded=!e.expanded)}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{locale:["localeWatchHandler"],value:["valueWatchHandler"]}}};u.style=":host{display:block}.container-border{overflow-y:hidden}.org-var-header{margin-top:1rem;margin-bottom:1rem;margin-left:0px;margin-right:0px}.icon-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}";export{d as json_editor,r as solution_item_details,h as solution_item_sharing,b as solution_organization_variables,f as solution_resource_item,p as solution_template_data,u as solution_variables}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,c as i,g as e,a as s,h as a,H as l}from"./p-1b0588d2.js";import{b as o,c as n,a as c}from"./p-80cb7c73.js";import{l as h,g as r}from"./p-ee2cbba0.js";import{e as d,h as p}from"./p-952da957.js";import{s as g}from"./p-48942eb8.js";import{c as b,r as m}from"./p-4f514c6d.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-e23b4193.js";import"./p-4fe489cf.js";import"./p-2bc98cb0.js";import"./p-4f236b5d.js";import"./p-570b13d9.js";import"./p-0668e30d.js";const u=class{constructor(e){t(this,e),this.searchConfigurationChange=i(this,"searchConfigurationChange",7)}get el(){return e(this)}addresseeLayerIds=[];bufferColor=[227,139,79,.8];bufferOutlineColor=[255,255,255];customLabelEnabled;defaultBufferDistance;defaultBufferUnit;defaultExportTitle="";defaultNumLabelsPerPage=6;enableLayerFeatures=!0;enableLayerFeaturesOnLoad=!1;enableSearchDistance=!0;enableSearchDistanceOnLoad=!1;enableSketchTools=!0;featureEffect;featureHighlightEnabled;locale;mapView;noResultText;initialNotice="";searchConfiguration;selectionLayerIds=[];showRefineSelection=!1;showSearchSettings=!0;sketchLineSymbol;sketchPointSymbol;sketchPolygonSymbol;_exportGraphics=!1;_addMap=!1;_addResults=!0;_addTitle=!1;_downloadActive=!0;_exportType=o.PDF;_fetchingData=!1;_isMobile;_numDuplicates=0;_pageType=n.LIST;_saveEnabled=!1;_selectionSets=[];_translations;_activeSelection;_downloadTools;_geometryEngine;Graphic;_jsonUtils;_onboardingImageUrl="";_popupsEnabled;_removeDuplicates;_searchConfiguration;_selectTools;_mediaQuery;_titleElement;_titleValue=void 0;_numSelected=0;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async mapViewWatchHandler(t){t?.popup&&(this._popupsEnabled=t?.popupEnabled),this._initSearchConfiguration(this.searchConfiguration)}async watchSearchConfigurationHandler(t,i){const e=JSON.stringify(t);this.mapView&&(e!==JSON.stringify(i)||e&&!this._searchConfiguration)&&(this._searchConfiguration=JSON.parse(e),this.searchConfigurationChange.emit(this._searchConfiguration),this._home())}async sketchLineSymbolWatchHandler(t,i){t&&JSON.stringify(t)!==JSON.stringify(i)&&this._setLineSymbol(t)}async sketchPointSymbolWatchHandler(t,i){t&&JSON.stringify(t)!==JSON.stringify(i)&&this._setPointSymbol(t)}async sketchPolygonSymbolWatchHandler(t,i){t&&JSON.stringify(t)!==JSON.stringify(i)&&this._setPolygonSymbol(t)}async pageTypeWatchHandler(t,i){if(this._checkPopups(),this.mapView?.popup&&(this.mapView.popupEnabled=t===n.LIST&&this._popupsEnabled),t===n.EXPORT&&(this._fetchingData=!0,this._numDuplicates=await this._getNumDuplicates(),this._updateExportGraphics(),this._fetchingData=!1),this._clearHighlight(),i!==n.SELECT&&i!==n.REFINE||await this._clearSelection(),i===n.EXPORT&&this._removeExportGraphics(),t!==n.SELECT)return this._highlightFeatures()}searchConfigurationChange;selectionSetsChanged(t){this._selectionSets=[...t.detail]}connectedCallback(){this._mediaQuery=window.matchMedia("(max-width: 600px)"),this._mediaQuery.addEventListener("change",(t=>this._setIsMobile(t)))}async componentWillLoad(){await this._getTranslations(),await this._initModules(),this._initSymbols(),this._onboardingImageUrl=s("assets/data/images/onboarding.png")}render(){return a(l,{key:"61ed8da1de1c6780188fb7bd4f69c82036ddf705"},a("calcite-shell",{key:"9eb929b7d27d103a207be34681623ca2e0097ef1"},a("calcite-action-bar",{key:"3c7ad5516fdca78819ebdbdc7c41642c816239ec",class:"border-bottom-1 action-bar-size","expand-disabled":!0,layout:"horizontal",slot:this._isMobile?"footer":"header"},this._getActionGroup("list-check",n.LIST,this._translations.myLists),this.showRefineSelection?this._getActionGroup("test-data",n.REFINE,this._translations.refineSelection):null,this._getActionGroup("export",n.EXPORT,this._translations.export)),this._getPage(this._pageType)))}async componentDidLoad(){this._initSearchConfiguration(this.searchConfiguration)}disconnectedCallback(){this._mediaQuery.removeEventListener("change",(t=>this._setIsMobile(t)))}async _initModules(){const[t,i,e]=await h(["esri/geometry/geometryEngine","esri/symbols/support/jsonUtils","esri/Graphic"]);this._geometryEngine=t,this._jsonUtils=i,this.Graphic=e}_initSearchConfiguration(t){this.searchConfiguration&&!this._searchConfiguration&&this.mapView&&(this._searchConfiguration=t,this.searchConfigurationChange.emit(this._searchConfiguration),this._home())}_initSymbols(){this._setLineSymbol(this.sketchLineSymbol),this._setPointSymbol(this.sketchPointSymbol),this._setPolygonSymbol(this.sketchPolygonSymbol)}_setLineSymbol(t){this.sketchLineSymbol="simple-line"===t?.type?t:this._jsonUtils.fromJSON(t||{type:"esriSLS",color:[130,130,130,255],width:2,style:"esriSLSSolid"})}_setPointSymbol(t){this.sketchPointSymbol="simple-marker"===t?.type?t:this._jsonUtils.fromJSON(t||{type:"esriSMS",color:[255,255,255,255],angle:0,xoffset:0,yoffset:0,size:6,style:"esriSMSCircle",outline:{type:"esriSLS",color:[50,50,50,255],width:1,style:"esriSLSSolid"}})}_setPolygonSymbol(t){this.sketchPolygonSymbol="simple-fill"===t?.type?t:this._jsonUtils.fromJSON(t||{type:"esriSFS",color:[150,150,150,51],outline:{type:"esriSLS",color:[50,50,50,255],width:2,style:"esriSLSSolid"},style:"esriSFSSolid"})}_setIsMobile(t){this._isMobile=t.matches}_getActionGroup(t,i,e){return a("calcite-action-group",{class:this.showRefineSelection?"w-1-3":"w-1-2",layout:"horizontal"},a("div",{class:"background-override"},a("calcite-action",{active:this._pageType===i,alignment:"center",class:"width-full height-full",icon:t,id:t,onClick:()=>{this._setPageType(i)},text:""})),a("calcite-tooltip",{label:"",placement:"bottom","reference-element":t},a("span",null,e)))}_setPageType(t){this._pageType=t}_getPage(t){let i;switch(t){case n.LIST:i=this._getListPage();break;case n.SELECT:i=this._getSelectPage();break;case n.EXPORT:i=this._getExportPage();break;case n.REFINE:i=this._getRefinePage()}return i}_getListPage(){const t=this._hasSelections(),i=t?this._translations.listHasSetsTip:""!==this.initialNotice?this.initialNotice:this._translations.selectLayerAndAdd;return a("calcite-panel",null,this._getLabel(this._translations.myLists),this._getNotice(i,"padding-sides-1 padding-bottom-1","word-wrap-anywhere"),t?this._getSelectionSetList():this._getOnboardingImage(),a("div",{class:"display-flex padding-1"},a("calcite-button",{onClick:()=>{this._setPageType(n.SELECT)},width:"full"},a("span",{class:"font-weight-500"},this._translations.add))))}_getOnboardingImage(){return a("div",{class:"display-flex padding-sides-1"},a("img",{class:"img-container",role:"presentation",src:this._onboardingImageUrl}))}_getSelectionSetList(){return a("div",{class:"padding-top-1-2 padding-bottom-1-2"},a("calcite-list",{class:"list-border margin-sides-1",label:""},this._selectionSets.reduce(((t,i,e)=>{const s=this._getSelectionSetIds(i);let l=!0;return i.workflowType===c.REFINE&&(l=Object.keys(i.refineInfos).reduce(((t,e)=>{const s=i.refineInfos[e];return t+(s.addIds.length+s.removeIds.length)}),0)>0),l&&t.push(a("calcite-list-item",{label:i.label,onClick:()=>this._gotoSelection(i,this.mapView)},a("div",{slot:"content"},a("div",{class:"list-label"},i.label),a("div",{class:"list-description"},i?.layerView?.layer.title),a("div",{class:"list-description"},this._translations.selectedFeatures.replace("{{n}}",s.length.toString()))),this._getAction(!0,"pencil","",(t=>this._openSelection(i,t)),!1,"actions-end"),this._getAction(!0,"x","",(t=>this._deleteSelection(e,t)),!1,"actions-end"))),t}),[])))}_getSelectionSetIds(t){return t.workflowType!==c.REFINE?t.selectedIds:Object.keys(t.refineInfos).reduce(((i,e)=>[...i,...t.refineInfos[e].addIds]),[])}_hasSelections(t=!1){let i=[];const e=this._selectionSets.some((t=>{if(t.workflowType===c.REFINE)return i=this._getSelectionSetIds(t),!0}));return t&&e?i.length>0||this._selectionSets.length>1:this._selectionSets.length>0}async _getNumDuplicates(){const t=this._getExportInfos(),i=await b(this.mapView.map,t),e=m(i);return i.length-e.length}_getExportInfos(){return this._selectionSets.reduce(((t,i)=>(i.download&&(i.workflowType!==c.REFINE?this._updateIds(i.layerView.layer.id,i.layerView,i.selectedIds,t):Object.keys(i.refineInfos).forEach((e=>{const s=i.refineInfos[e];s.addIds.length>0&&this._updateIds(e,s.layerView,s.addIds,t)}))),t)),{})}_updateIds(t,i,e,s){return s[t]?s[t].ids=s[t].ids.concat(e):s[t]={layerView:i,ids:e},s}_getSelectPage(){const t=this._translations.selectSearchTip;return a("calcite-panel",null,this._getLabel(this._translations.stepTwoFull,!0),this._getNotice(t,"padding-1","word-wrap-anywhere"),a("div",null,a("map-select-tools",{bufferColor:this.bufferColor,bufferOutlineColor:this.bufferOutlineColor,class:"font-bold",customLabelEnabled:this.customLabelEnabled,defaultBufferDistance:this.defaultBufferDistance,defaultBufferUnit:this.defaultBufferUnit,enableLayerFeatures:this.enableLayerFeatures,enableLayerFeaturesOnLoad:this.enableLayerFeaturesOnLoad,enableSearchDistance:this.enableSearchDistance,enableSearchDistanceOnLoad:this.enableSearchDistanceOnLoad,enableSketchTools:this.enableSketchTools,enabledLayerIds:this.addresseeLayerIds,isUpdate:!!this._activeSelection,locale:this.locale,mapView:this.mapView,noResultText:this.noResultText,onSelectionSetChange:t=>this._updateForSelection(t),ref:t=>{this._selectTools=t},searchConfiguration:this._searchConfiguration,searchDistanceEnabled:this.enableSearchDistanceOnLoad,selectionLayerIds:this.selectionLayerIds,selectionSet:this._activeSelection,sketchLineSymbol:this.sketchLineSymbol,sketchPointSymbol:this.sketchPointSymbol,sketchPolygonSymbol:this.sketchPolygonSymbol,useLayerFeaturesEnabled:this.enableLayerFeaturesOnLoad})),this._getPageNavButtons(this._translations.done,0===this._numSelected,(()=>{this._saveSelection()}),this._translations.cancel,!1,(()=>{this._home()})))}_getExportPage(){const t=this._hasSelections(this.showRefineSelection),i=this._numDuplicates>0?"display-block":"display-none";return a("calcite-panel",null,a("div",null,this._getLabel(this._translations.export,!1),t?a("div",null,this._getNotice(this._translations.exportTip,"padding-sides-1"),this._getLabel(this._translations.exportListsLabel),this._getExportSelectionLists(),a("div",{class:"padding-sides-1 "+i},a("div",{class:"display-flex"},a("calcite-label",{layout:"inline"},a("calcite-checkbox",{ref:t=>{this._removeDuplicates=t}}),a("div",{class:"display-flex"},this._translations.removeDuplicate,a("div",{class:"info-message padding-start-1-2"},a("calcite-input-message",{class:"info-blue margin-top-0",scale:"m"},` ${this._translations.numDuplicates.replace("{{n}}",this._numDuplicates.toString())}`)))),a("calcite-icon",{class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"remove-duplicates-icon",scale:"s"})),a("calcite-popover",{closable:!0,label:"",referenceElement:"remove-duplicates-icon"},a("span",{class:"tooltip-message"},this._translations.duplicatesTip))),a("div",{class:"border-bottom"}),a("div",{class:"padding-top-sides-1"},a("calcite-segmented-control",{class:"w-100",onCalciteSegmentedControlChange:t=>this._exportTypeChange(t),width:"full"},a("calcite-segmented-control-item",{checked:this._exportType===o.PDF,class:"w-50 end-border",value:o.PDF},a("span",{class:"font-weight-500"},this._translations.pdf)),a("calcite-segmented-control-item",{checked:this._exportType===o.CSV,class:"w-50",value:o.CSV},a("span",{class:"font-weight-500"},this._translations.csv)))),a("div",{class:"padding-bottom-1"},this._getExportOptions()),a("div",{class:"padding-1 display-flex"},a("calcite-button",{disabled:!this._downloadActive||this._fetchingData||!this._addMap&&!this._addResults,loading:this._fetchingData,onClick:()=>{this._export()},width:"full"},a("span",{class:"font-weight-500"},this._translations.export)))):this._getNotice(this._translations.downloadNoLists,"padding-sides-1 padding-bottom-1")))}_exportTypeChange(t){this._exportType=t.target.value}_getExportOptions(){const t=this._addTitle?"display-block":"display-none",i=this._addMap?"display-flex":"display-none",e=this._titleValue?this._titleValue:this.defaultExportTitle?this.defaultExportTitle:"",s=this._addResults?"":"display-none";return a("div",{class:this._exportType===o.PDF?"display-block":"display-none"},this._getLabel(this._translations.pdfOptions,!0),a("div",{class:"padding-top-sides-1"},a("calcite-label",{class:"label-margin-0",layout:"inline"},a("calcite-checkbox",{checked:this._addResults,onCalciteCheckboxChange:()=>this._addResults=!this._addResults}),this._translations.addResults)),a("div",{class:`padding-top-sides-1 ${s}`},a("calcite-label",{class:"label-margin-0"},this._translations.selectPDFLabelOption)),a("div",{class:`padding-sides-1 ${s}`},a("pdf-download",{defaultNumLabelsPerPage:parseInt(this.defaultNumLabelsPerPage.toString(),10),disabled:!this._downloadActive,locale:this.locale,ref:t=>{this._downloadTools=t}})),a("div",{class:"padding-top-sides-1"},a("calcite-label",{class:"label-margin-0",layout:"inline"},a("calcite-checkbox",{checked:this._addTitle,onCalciteCheckboxChange:()=>this._addTitle=!this._addTitle}),this._translations.title)),a("div",{class:t},this._getLabel(this._translations.title,!0,""),a("calcite-input-text",{class:"padding-sides-1",onCalciteInputTextInput:()=>this._changeTitle(),placeholder:this._translations.titlePlaceholder,ref:t=>{this._titleElement=t},value:e})),a("div",{class:"padding-top-sides-1"},a("calcite-label",{class:"label-margin-0",layout:"inline"},a("calcite-checkbox",{checked:this._addMap,onCalciteCheckboxChange:()=>this._handleAddMapChange()}),this._translations.includeMap)),a("div",{class:`padding-top-sides-1 ${i}`},a("calcite-label",{class:"label-margin-0",layout:"inline"},a("calcite-checkbox",{checked:this._exportGraphics,onCalciteCheckboxChange:()=>this._handleExportGraphicsChange()}),this._translations.listGraphics),a("calcite-icon",{class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"list-graphics-icon",scale:"s"}),a("calcite-popover",{closable:!0,label:"",referenceElement:"list-graphics-icon"},a("span",{class:"tooltip-message"},this._translations.listGraphicsTip))))}_handleAddMapChange(){this._addMap=!this._addMap,this._updateExportGraphics()}_handleExportGraphicsChange(){this._exportGraphics=!this._exportGraphics,this._updateExportGraphics()}_getManagedLayer(t){let i;return Object.keys(g.managedLayers).some((e=>{const s=this.mapView.map.layers.findIndex((t=>t.title===e));if(g.managedLayers[e]===t)return i=this.mapView.map.layers.getItemAt(s),!0})),i}_updateExportGraphics(t=!1){!t&&this._exportGraphics&&this._addMap||this._removeExportGraphics(),this._exportGraphics&&this._addMap&&this._addExportGraphics()}_removeExportGraphics(){const t=this._getManagedLayer("sketch"),i=this._getManagedLayer("buffer");t&&t.graphics.removeAll(),i&&i.graphics.removeAll()}_addExportGraphics(){const t=this._getManagedLayer("sketch"),i=this._getManagedLayer("buffer");this._selectionSets.forEach((e=>{if(e.download&&(t&&t.graphics.add(e.sketchGraphic),i)){const t=new this.Graphic({geometry:e.buffer,symbol:{type:"simple-fill",color:this.bufferColor,outline:{color:this.bufferOutlineColor,width:1}}});i.graphics.add(t)}}))}_getRefinePage(){const t=this._hasSelections();return a("calcite-panel",null,this._getLabel(this._translations.refineSelection),t?a("div",null,this._getNotice(this._translations.refineTip,"padding-sides-1"),a("refine-selection",{enabledLayerIds:this.selectionLayerIds,locale:this.locale,mapView:this.mapView,selectionSets:this._selectionSets,sketchLineSymbol:this.sketchLineSymbol,sketchPointSymbol:this.sketchPointSymbol,sketchPolygonSymbol:this.sketchPolygonSymbol})):this._getNotice(this._translations.refineTipNoSelections,"padding-sides-1"))}_getPageNavButtons(t,i,e,s,l,o){return a("div",{class:"padding-bottom-1"},a("div",{class:"display-flex padding-top-sides-1"},a("calcite-button",{disabled:i,onClick:e,width:"full"},a("span",{class:"font-weight-500"},t))),a("div",{class:"display-flex padding-top-1-2 padding-sides-1"},a("calcite-button",{appearance:"outline",disabled:l,onClick:o,width:"full"},a("span",{class:"font-weight-500"},s))))}_changeTitle(){this._titleValue=this._titleElement.value}_getNotice(t,i="padding-1",e=""){return a("calcite-notice",{class:i,icon:"lightbulb",kind:"success",open:!0},a("div",{class:e,slot:"message"},t))}_getLabel(t,i=!1,e="font-bold"){return a("div",{class:"padding-top-sides-1"},a("calcite-label",{class:e+=i?" label-margin-0":""},t))}_getExportSelectionLists(){return this._selectionSets.reduce(((t,i)=>{const e=this._getSelectionSetIds(i),s=i.workflowType!==c.REFINE||e.length>0;return!this._downloadActive&&i.download&&s&&(this._downloadActive=!0),s&&t.push(a("div",{class:"display-flex padding-sides-1 padding-bottom-1"},a("calcite-checkbox",{checked:i.download,class:"align-center",onClick:()=>{this._toggleDownload(i.id)}}),a("calcite-list",{class:"list-border margin-start-1-2 width-full",id:"download-list",label:""},a("calcite-list-item",{disabled:!i.download,label:i.label,onClick:()=>{this._toggleDownload(i.id)}},a("div",{slot:"content"},a("div",{class:"list-label"},i.label),a("div",{class:"list-description"},i?.layerView?.layer.title),a("div",{class:"list-description"},this._translations.selectedFeatures.replace("{{n}}",e.length.toString()))))))),t}),[])||a("div",null)}async _toggleDownload(t){let i=!1;this._selectionSets=this._selectionSets.map((e=>(e.download=e.id===t?!e.download:e.download,i=!!e.download||i,e))),this._updateExportGraphics(!0),this._downloadActive=i,this._fetchingData=!0,this._numDuplicates=await this._getNumDuplicates(),this._fetchingData=!1,await this._highlightFeatures()}async _export(){const t=this._addResults?this._getSelectionIdsAndViews(this._selectionSets,!0):{};if(this._exportType===o.PDF){let i="";if(this._addMap&&this.mapView){const t=await this.mapView.takeScreenshot({width:1500,height:2e3});i=t?.dataUrl}this._fetchingData=!0,await this._downloadTools.downloadPDF(this.mapView.map,t,this._removeDuplicates.checked,this._addTitle?this._titleElement.value:"",i),this._fetchingData=!1}this._exportType===o.CSV&&(this._fetchingData=!0,await this._downloadTools.downloadCSV(this.mapView.map,t,this._removeDuplicates.checked),this._fetchingData=!1)}_getSelectionIdsAndViews(t,i=!1){return(i?t.filter((t=>t.download)):t).reduce(((t,i)=>{if(i.workflowType===c.REFINE)Object.keys(i.refineInfos).forEach((e=>{const s=i.refineInfos[e];s.addIds&&(t=this._updateExportInfos(t,s.layerView.layer.id,i.label,s.addIds,s.layerView))}));else{const e=i?.layerView?.layer.id;t=this._updateExportInfos(t,e,i.label,i.selectedIds,i.layerView)}return t}),{})}_updateExportInfos(t,i,e,s,a){return i&&Object.keys(t).indexOf(i)>-1?(t[i].ids=[...new Set([...t[i].ids,...s])],t[i].selectionSetNames.push(e)):i&&(t[i]={ids:s,layerView:a,selectionSetNames:[e]}),t}_getAction(t,i,e,s,l=!1,o=""){return a("calcite-action",{disabled:!t,icon:i,iconFlipRtl:!0,indicator:l,onClick:s,slot:o,text:e})}_updateForSelection(t){this._numSelected=t.detail,this._saveEnabled=this._numSelected>0}async _home(){await this._clearSelection(),this._setPageType(n.LIST)}async _saveSelection(){const t=await(this._selectTools?.getSelection()),i=this._selectTools?.isUpdate;return this._selectionSets=i?this._selectionSets.map((i=>i.id===t.id?t:i)):[...this._selectionSets,t],this._home()}async _clearSelection(){await(this._selectTools?.clearSelection()),this._numSelected=0,this._activeSelection=void 0}_deleteSelection(t,i){return i.stopPropagation(),this._selectionSets=this._selectionSets.filter(((i,e)=>{if(e!==t)return i})),this._highlightFeatures()}_gotoSelection(t,i){d(t.selectedIds,t.layerView,i,this.featureHighlightEnabled,this.featureEffect)}_openSelection(t,i){i.stopPropagation(),this._activeSelection=t,this._pageType=t.workflowType===c.REFINE?n.REFINE:n.SELECT}async _highlightFeatures(){this._clearHighlight();const t=this._getSelectionIdsAndViews(this._selectionSets,this._pageType===n.EXPORT),i=Object.keys(t);if(i.length>0)for(let e=0;e<i.length;e++){const s=t[i[e]];g.highlightHandles.push(await p(s.ids,s.layerView,this.mapView))}}_checkPopups(){"boolean"!=typeof this._popupsEnabled&&(this._popupsEnabled=this.mapView?.popupEnabled)}_clearHighlight(){g&&g.highlightHandles&&g.removeHandles()}async _getTranslations(){const t=await r(this.el);this._translations=t[0]}static get watchers(){return{locale:["localeWatchHandler"],mapView:["mapViewWatchHandler"],searchConfiguration:["watchSearchConfigurationHandler"],sketchLineSymbol:["sketchLineSymbolWatchHandler"],sketchPointSymbol:["sketchPointSymbolWatchHandler"],sketchPolygonSymbol:["sketchPolygonSymbolWatchHandler"],_pageType:["pageTypeWatchHandler"]}}};u.style=':host{display:block;--calcite-input-message-spacing-value:0}.align-center{align-items:center}.border-bottom-1{border-width:0px;border-bottom-width:1px;border-style:solid;border-color:var(--calcite-color-border-3)}.action-bar-size{height:3.5rem;width:100%}.w-1-2{width:50%}.w-1-3{width:33.33%}.width-full{width:100%}.height-full{height:100%}.padding-1{padding:1rem}.padding-top-sides-1{padding-block-start:1rem;padding-inline-start:1rem;padding-inline-end:1rem}.padding-sides-1{padding-inline-start:1rem;padding-inline-end:1rem}.padding-end-1-2{padding-inline-end:.5rem}.padding-top-1-2{padding-block-start:.5rem}.padding-top-1{padding-top:1rem}.padding-bottom-1{padding-bottom:1rem}.padding-bottom-1-2{padding-bottom:.5rem}.info-blue{color:#00A0FF}.info-message{justify-content:center;display:grid}.font-bold{font-weight:bold}.display-flex{display:flex}.display-block{display:block}.display-none{display:none}.border-bottom{border-bottom:1px solid var(--calcite-color-border-2)}.padding-start-1-2{padding-inline-start:0.5rem}.list-border{border:1px solid var(--calcite-color-border-2)}.margin-sides-1{margin-inline-start:1rem;margin-inline-end:1rem}.margin-start-1-2{margin-inline-start:0.5rem}.float-right{float:right}.float-right[dir="rtl"]{float:left}.float-left{float:left}.float-left[dir="rtl"]{float:right}.margin-top-0{margin-block-start:0 !important}.height-1-1-2{height:1.5rem}.main-background{background-color:var(--calcite-color-foreground-2)}.position-right{position:absolute;right:1rem}.position-right[dir="rtl"]{position:absolute;left:1rem}.label-margin-0{--calcite-label-margin-bottom:0}.list-label{color:var(--calcite-color-text-1)}.list-label,.list-description{font-family:var(--calcite-sans-family);font-size:var(--calcite-font-size--2);font-weight:var(--calcite-font-weight-normal);overflow-wrap:break-word;word-break:break-word}.list-description{margin-block-start:0.125rem;color:var(--calcite-color-text-3)}.img-container{width:100%;height:100%}.font-weight-500{font-weight:500}.background-override{height:100%;width:100%;--calcite-color-foreground-3:var(--calcite-color-brand);--calcite-color-foreground-2:var(--calcite-color-brand-hover);--calcite-color-text-1:var(--calcite-color-text-inverse)}.word-wrap-anywhere{word-wrap:anywhere}';export{u as public_notification}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as e,c as t,g as i,h as a,H as s}from"./p-1b0588d2.js";import{s as l}from"./p-8b218ba7.js";import{g as c}from"./p-ee2cbba0.js";import{n}from"./p-8850bd21.js";import{C as r,g as o}from"./p-80cb7c73.js";import"./p-e23b4193.js";import"./p-4f236b5d.js";import"./p-d4056c1c.js";import"./p-570b13d9.js";import"./p-0668e30d.js";import"./p-0a24ad5f.js";const h=class{constructor(i){e(this,i),this.solutionItemSelected=t(this,"solutionItemSelected",7)}get el(){return i(this)}selectedItemId;templateHierarchy=[];valueWatchHandler(e,t){e&&e!==t&&Array.isArray(e)&&e.length>0&&this._treeItemSelected(e[0].id)}componentWillLoad(){this.valueWatchHandler(this.templateHierarchy,[])}render(){return a(s,{key:"cf80f637e998eda76162eb1cf3fe94dfb2aeae3e"},a("calcite-tree",{key:"3bb27819fff1f63b28ed70c360fe8f7a63619d3c"},this.renderHierarchy(this.templateHierarchy)))}renderHierarchy(e){return e.map((e=>{const t=this.selectedItemId&&this.selectedItemId===e.id;return e.dependencies&&e.dependencies.length>0?a("calcite-tree-item",{onClick:t=>this._treeItemSelected(e.id,t),selected:t},a("solution-item-icon",{type:e.type,typeKeywords:e.typeKeywords}),a("span",{class:"icon-text",title:e.title},e.title),a("calcite-tree",{slot:"children"},this.renderHierarchy(e.dependencies))):a("calcite-tree-item",{onClick:t=>this._treeItemSelected(e.id,t),selected:t},a("solution-item-icon",{type:e.type,typeKeywords:e.typeKeywords}),a("span",{class:"icon-text",title:e.title},e.title))}))}solutionItemSelected;_treeItemSelected(e,t){const i=t?.target?.closest("calcite-tree-item");i&&(i.expanded=!i?.expanded),this.selectedItemId=e,this.solutionItemSelected.emit(e)}static get assetsDirs(){return["item-type-icons"]}static get watchers(){return{templateHierarchy:["valueWatchHandler"]}}};h.style=".icon-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}";const d=class{constructor(t){e(this,t)}get el(){return i(this)}authentication;itemId="";itemIdWatchHandler(){const e=l.getItemInfo(this.itemId);this.itemType=e.type}locale;solutionVariables="";organizationVariables="";async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}async componentWillLoad(){return this._getTranslations()}render(){return a(s,{key:"8213c164dbfc2f9d897bcd2dbb732d1029e7bc9a"},a("div",{key:"252091fa803626400a22295d6a9d148d207c84e6",class:"configuration-container"},a("div",{key:"b30bcfd2bec082f8248584749e6d98a2c9331bdf",class:"configuration"},this._showGroupTabs("Group"===this.itemType),this._showItemTabs("Group"!==this.itemType))))}itemType;_translations;_showGroupTabs(e){return a("calcite-tabs",{class:"config-tabs",style:{display:e?"inherit":"none"}},a("calcite-tab-nav",{slot:"tab-nav"},a("calcite-tab-title",null,this._translations.groupDetailsTab),a("calcite-tab-title",null,this._translations.sharingTab)),a("calcite-tab",{class:"config-tab",id:"group-tab",selected:!0},a("solution-item-details",{"item-id":this.itemId,locale:this.locale})),a("calcite-tab",{class:"config-tab",id:"share-tab"},a("solution-item-sharing",{"group-id":this.itemId,locale:this.locale})))}_showItemTabs(e){return a("calcite-tabs",{class:"config-tabs",style:{display:e?"inherit":"none"}},a("calcite-tab-nav",{slot:"tab-nav"},a("calcite-tab-title",null,this._translations.itemDetailsTab),a("calcite-tab-title",null,this._translations.dataTab),a("calcite-tab-title",null,this._translations.propertiesTab),a("calcite-tab-title",null,this._translations.resourcesTab)),a("calcite-tab",{class:"config-tab",selected:!0},a("solution-item-details",{"item-id":this.itemId,locale:this.locale})),a("calcite-tab",{class:"config-tab",id:"data-tab"},a("solution-template-data",{instanceid:"data","item-id":this.itemId,locale:this.locale,"organization-variables":this.organizationVariables,"solution-variables":this.solutionVariables})),a("calcite-tab",{class:"config-tab",id:"props-tab"},a("solution-template-data",{instanceid:"properties","item-id":this.itemId,locale:this.locale,"organization-variables":this.organizationVariables,"solution-variables":this.solutionVariables})),a("calcite-tab",{class:"config-tab",id:"resources-tab"},a("solution-resource-item",{authentication:this.authentication,class:"solutions-resource-container","item-id":this.itemId,locale:this.locale})))}async _getTranslations(){const e=await c(this.el);this._translations=e[0]}static get watchers(){return{itemId:["itemIdWatchHandler"],locale:["localeWatchHandler"]}}};d.style=".configuration-container{position:relative;height:100%;width:100%}.configuration{position:absolute;top:0px;right:0px;bottom:0px;left:0px;display:flex;padding:0.5rem;border:1px #808080 solid}.config-tabs{width:100%}.config-tab{width:100%;overflow-y:auto;height:inherit}";const f="3857",b=class{constructor(i){e(this,i),this.featureServiceSpatialReferenceChange=t(this,"featureServiceSpatialReferenceChange",7),this.enableDefaultSpatialReferenceChange=t(this,"enableDefaultSpatialReferenceChange",7),this.enabledSpatialReferenceChange=t(this,"enabledSpatialReferenceChange",7)}get el(){return i(this)}enabled=!1;enabledChanged(){this._handleSpatialRefParamChange()}enableDefault=!1;enableDefaultChanged(){this._handleDefaultSpatialRefParamChange()}featureServices=[];locale;async localeWatchHandler(){this.el.lang=this.locale,await this._getTranslations()}componentWillLoad(){return this._updateUIFromStore(),this._getTranslations()}render(){return this._updateUIFromStore(),a(s,{key:"7f273e4ac344e1ee0caf40e7d1b7f939ecabda20"},a("label",{key:"06de012379cbfc355a9ace954b1dffffa9ce8c83",class:"switch-label"},a("calcite-switch",{key:"81660a69b2ac46824e2b929e13362f5ab9260c54",checked:this.enabled,class:"spatial-ref-switch",onCalciteSwitchChange:e=>this.enabled=e.target.checked,scale:"m"}),this._translations.enableSpatialReference),a("br",{key:"361d2d822ddad721842b806e4ee1e04ff313a19b"}),a("div",{key:"a211f2f6f55191a9ae9b4e94eae7a998b7bc8e35",class:"spatial-ref-component",id:"spatialRefDefn"},this._renderFeatureServicesList(this.featureServices)),a("label",{key:"9fc52be401af098888688636168b6742e92ce939",class:"switch-label spatial-ref-component"},a("calcite-switch",{key:"138644a57bd5c159e9f7f219f8956f0ed1af5bf1",checked:this.enableDefault,class:"spatial-ref-switch",disabled:!this.enabled,onCalciteSwitchChange:e=>this.enableDefault=e.target.checked,scale:"m"}),this._translations.enableDefaultSpatialReference))}_translations;featureServiceSpatialReferenceChange;enableDefaultSpatialReferenceChange;enabledSpatialReferenceChange;solutionStoreHasChanges(){this.featureServices=l.getStoreInfo("featureServices")}async _testAccess(e,t,i,a){switch(e){case"_parameterizeWkid":return Promise.resolve(this._parameterizeWkid(t));case"_unparameterizeWkid":return Promise.resolve(this._unparameterizeWkid(t))}return Promise.resolve(null)}_clearFeatureServiceDefaults(e){n(this.el.getElementsByClassName("spatial-ref-item-switch")).forEach((e=>e.checked=!1)),e.forEach((e=>this._updateEnabledServices({detail:{switched:!1}},e)))}_handleDefaultSpatialRefParamChange(){this._updateStore(),this.enableDefaultSpatialReferenceChange.emit({defaultWkid:this.enableDefault?f:""})}_handleSpatialRefParamChange(){this.enabled||(this.enableDefault=!1,this._clearFeatureServiceDefaults(this.featureServices)),this._updateStore(),this.enabledSpatialReferenceChange.emit({enabled:this.enabled})}_parameterizeWkid(e){return e?e.toString().startsWith(r)?e:`${r}${e}${o}`:e}_renderFeatureServicesList(e){const t=l.getStoreInfo("spatialReferenceInfo"),i=e.filter((e=>Object.keys(t.services).some((t=>t===e.id))));return i.length>0?a("div",null,a("label",{class:"spatial-ref-item-title"},this._translations.featureServicesHeading),a("ul",{class:"spatial-ref-services-list"},i.map((e=>a("li",{class:"spatial-ref-services-list-item"},a("label",{class:"switch-label"},a("calcite-switch",{checked:t.services[e.id],class:"spatial-ref-item-switch",disabled:!this.enabled,onCalciteSwitchChange:t=>this._updateEnabledServices(t,e),scale:"m"}),e.name)))))):null}_updateEnabledServices(e,t){const i=l.getStoreInfo("spatialReferenceInfo");i.services[t.id]=void 0!==e.detail?.switched?e.detail.switched:void 0===e.target?.checked||e.target.checked,l.setStoreInfo("spatialReferenceInfo",i),this._updateStore(),this.featureServiceSpatialReferenceChange.emit(t)}_unparameterizeWkid(e){return e&&e.toString().startsWith(r)?e.substring(r.length,e.length-o.length):e}_updateFeatureServices(e){e.enabled||Object.keys(e.services).forEach((t=>{e.services[t]=!1})),this.featureServices.forEach((t=>{t.enabled=e.services[t.id],t.wkid=t.enabled?this._parameterizeWkid(t.wkid):this._unparameterizeWkid(t.wkid)})),l.setStoreInfo("featureServices",this.featureServices)}_updateStore(){const e=l.getStoreInfo("spatialReferenceInfo");e.enabled=this.enabled,this.enabled&&this.enableDefault?e.default=f:e.hasOwnProperty("default")&&delete e.default,l.setStoreInfo("spatialReferenceInfo",e),this._updateFeatureServices(e)}_updateUIFromStore(){const e=l.getStoreInfo("spatialReferenceInfo");this.enabled=e.enabled,this.enableDefault=!!e.default,this.featureServices=l.getStoreInfo("featureServices")}async _getTranslations(){const e=await c(this.el);this._translations=e[0]}static get watchers(){return{enabled:["enabledChanged"],enableDefault:["enableDefaultChanged"],locale:["localeWatchHandler"]}}};b.style=".spatial-ref-switch{margin-inline-end:0.5rem}.spatial-ref-component{margin-top:0.625rem;margin-inline-start:2.5rem}#spatialRefDefn .sc-calcite-label-h label.sc-calcite-label{margin:0px;background-color:#CBC3E3}.spatial-ref-item-title{margin-bottom:0.5rem;font-size:0.875rem;line-height:1.25rem}.spatial-ref-item-switch{margin-inline-end:0.5rem}.switch-label{font-size:0.875rem;line-height:1.25rem}.spatial-ref-services-list{margin-block-start:0.5em;margin-block-end:0.5em;list-style-type:none;padding-inline-start:2em}.spatial-ref-services-list-item{margin-top:0.25rem}";export{h as solution_contents,d as solution_item,b as solution_spatial_ref}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as e,g as a,h as i,H as t}from"./p-1b0588d2.js";import{c as l}from"./p-747d4b59.js";const d=class{constructor(a){e(this,a)}get el(){return a(this)}showAddDeduct=!1;_deductValuesElement;render(){const e=this.showAddDeduct?"position-relative":"display-none";return i(t,{key:"6ee5741fe10030324155d5f05a9e4a0eeb337028"},i("div",{key:"14e0c3495ad57d8d1ec4da9b6c5df80323ef1735",class:this.showAddDeduct?"display-none":"display-grid"},i("div",{key:"ef2e48f06b194ee7806e2f6b5c60d77e17ac1e5f",class:"label-display"},i("calcite-label",{key:"60695651cdad1e30570f76f3621740fb8c0b62e9",class:"label-display"},"Enter comma delimited deduct values",this._getDeductValuesInput())),i("div",{key:"19e2db05e7b45fb012892ffa539cb2037da9f449"},this._getCalculateButton())),i("div",{key:"4a2cd1a80a86d2ba7e4b24935dbebbaecd316cd0",class:e},i("div",{key:"f288ef667dd2532c8f409ef12a033d6b4f13ad7e",class:"position-right"},i("calcite-action",{key:"0d62669dd9660098f6ac4eb10334c5a9ea3897aa",appearance:"transparent",class:"float-end",icon:"x",onClick:()=>this._toggleShowAddDeduct(),scale:"s",text:""})),i("deduct-calculator",{key:"dd0a3cb656e7e2c707b1956e40e8a597d8972cfa",class:"display-grid padding-top-1",onDeductValueComplete:e=>this._addDeductValue(e)})))}_getDeductValuesInput(){return i("div",{class:"display-flex"},i("calcite-input",{class:"main-input",ref:e=>{this._deductValuesElement=e}}),i("calcite-action",{appearance:"transparent",icon:"plus-circle",onClick:()=>this._toggleShowAddDeduct(),scale:"s",text:""}))}_getCalculateButton(){return i("calcite-button",{onClick:()=>this._calculatePCI(this._deductValuesElement.value)},"Calculate PCI")}_toggleShowAddDeduct(){this.showAddDeduct=!this.showAddDeduct}_addDeductValue(e){this._toggleShowAddDeduct(),this._deductValuesElement.value+=Math.abs(parseFloat(this._deductValuesElement.value))>0?`,${e.detail}`:e.detail}_calculatePCI(e){const a=l(e,!0),i=a<=10?"Failed":a<=25?"Serious":a<=40?"Very Poor":a<=55?"Poor":a<=70?"Fair":a<=85?"Satisfactory":"Good";console.log(`PCI: ${a}`),console.log(`Rating: ${i}`),alert("See debug console for results")}};d.style=":host{display:block;--calcite-label-margin-bottom:0}.label-display{display:block;padding-bottom:1rem}.display-flex{display:flex}.display-grid{display:grid}.display-table{display:table}.display-inline-table{display:inline-table}.display-none{display:none}.display-inherit{display:inherit}.padding-top-1{padding-top:1rem}.main-input{width:300px;padding-inline-end:1rem}.float-end{float:inline-end}.position-relative{position:relative}.position-right{position:absolute;right:0px}";export{d as pci_calculator}