@esri/solutions-components 0.10.34 → 0.10.36
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/basemap-gallery_7.cjs.entry.js +7 -6
- package/dist/cjs/buffer-tools_3.cjs.entry.js +1 -1
- package/dist/cjs/calcite-alert_5.cjs.entry.js +10 -8
- package/dist/cjs/calcite-combobox_3.cjs.entry.js +1 -1
- package/dist/cjs/calcite-flow_4.cjs.entry.js +18 -16
- package/dist/cjs/{calcite-modal_3.cjs.entry.js → calcite-modal.cjs.entry.js} +27 -368
- package/dist/cjs/calcite-shell-panel_14.cjs.entry.js +7 -7
- package/dist/cjs/calcite-shell_3.cjs.entry.js +440 -0
- package/dist/cjs/card-manager_3.cjs.entry.js +22 -11
- package/dist/cjs/crowdsource-manager.cjs.entry.js +28 -31
- package/dist/cjs/crowdsource-reporter.cjs.entry.js +24 -21
- package/dist/cjs/{downloadUtils-20637f89.js → downloadUtils-76bc7e30.js} +6 -5
- package/dist/cjs/feature-comments.cjs.entry.js +1 -1
- package/dist/cjs/feature-form-flow-item.cjs.entry.js +1 -1
- package/dist/cjs/feature-list.cjs.entry.js +7 -7
- package/dist/cjs/features-flow-item.cjs.entry.js +1 -1
- package/dist/cjs/{index.es-a242cb45.js → index.es-8336efed.js} +2 -2
- package/dist/cjs/layout-manager.cjs.entry.js +1 -1
- package/dist/cjs/list-flow-item.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/location-flow-item.cjs.entry.js +1 -1
- package/dist/cjs/map-select-tools_3.cjs.entry.js +5 -5
- package/dist/cjs/pci-calculator.cjs.entry.js +1 -1
- package/dist/cjs/{popupUtils-d477705b.js → popupUtils-bc762034.js} +1 -1
- package/dist/cjs/public-notification.cjs.entry.js +3 -3
- package/dist/cjs/refine-results-flow-item.cjs.entry.js +1 -1
- package/dist/cjs/share-item.cjs.entry.js +1 -1
- package/dist/cjs/solution-configuration.cjs.entry.js +3 -3
- package/dist/cjs/solution-contents_3.cjs.entry.js +3 -3
- package/dist/cjs/solution-item-accordion.cjs.entry.js +1 -1
- package/dist/cjs/solution-item-icon.cjs.entry.js +1 -1
- package/dist/cjs/solutions-components.cjs.js +1 -1
- package/dist/cjs/spatial-ref.cjs.entry.js +1 -1
- package/dist/collection/assets/t9n/delete-dialog/resources.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_ar.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_bg.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_bs.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_ca.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_cs.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_da.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_de.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_el.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_en.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_es.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_et.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_fi.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_fr.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_he.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_hr.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_hu.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_id.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_it.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_ja.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_ko.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_lt.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_lv.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_nb.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_nl.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_pl.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_pt-BR.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_pt-PT.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_ro.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_ru.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_sk.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_sl.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_sr.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_sv.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_th.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_tr.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_uk.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_vi.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_zh-CN.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_zh-HK.json +8 -0
- package/dist/collection/assets/t9n/delete-dialog/resources_zh-TW.json +8 -0
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/create-feature/create-feature.css +2 -1
- package/dist/collection/components/create-feature/create-feature.js +3 -1
- package/dist/collection/components/crowdsource-manager/crowdsource-manager.css +4 -0
- package/dist/collection/components/crowdsource-manager/crowdsource-manager.js +29 -30
- package/dist/collection/components/crowdsource-reporter/crowdsource-reporter.js +24 -21
- package/dist/collection/components/delete-button/delete-button.js +20 -27
- package/dist/collection/components/delete-dialog/delete-dialog.css +23 -0
- package/dist/collection/components/delete-dialog/delete-dialog.js +239 -0
- package/dist/collection/components/edit-card/edit-card.js +1 -1
- package/dist/collection/components/feature-comments/feature-comments.js +1 -1
- package/dist/collection/components/feature-details/feature-details.js +13 -11
- package/dist/collection/components/feature-form-flow-item/feature-form-flow-item.js +1 -1
- package/dist/collection/components/feature-list/feature-list.js +4 -4
- package/dist/collection/components/features-flow-item/features-flow-item.js +1 -1
- package/dist/collection/components/floor-filter/floor-filter.js +1 -1
- package/dist/collection/components/info-card/info-card.js +2 -2
- package/dist/collection/components/json-editor/json-editor.js +1 -1
- package/dist/collection/components/layer-list/layer-list.js +5 -5
- package/dist/collection/components/layer-table/layer-table.css +6 -0
- package/dist/collection/components/layer-table/layer-table.js +19 -7
- package/dist/collection/components/layout-manager/layout-manager.js +1 -1
- package/dist/collection/components/list-flow-item/list-flow-item.js +1 -1
- package/dist/collection/components/location-flow-item/location-flow-item.js +1 -1
- package/dist/collection/components/map-card/map-card.js +1 -1
- package/dist/collection/components/map-draw-tools/map-draw-tools.js +1 -1
- package/dist/collection/components/map-fullscreen/map-fullscreen.js +1 -1
- package/dist/collection/components/map-layer-picker/map-layer-picker.js +1 -1
- package/dist/collection/components/map-legend/map-legend.js +2 -1
- package/dist/collection/components/map-picker/map-picker.js +1 -1
- package/dist/collection/components/map-search/map-search.js +1 -1
- package/dist/collection/components/map-select-tools/map-select-tools.js +1 -1
- package/dist/collection/components/map-tools/map-tools.js +1 -1
- package/dist/collection/components/pci-calculator/pci-calculator.js +1 -1
- package/dist/collection/components/pdf-download/pdf-download.js +1 -1
- package/dist/collection/components/public-notification/public-notification.js +1 -1
- package/dist/collection/components/refine-results-flow-item/refine-results-flow-item.js +1 -1
- package/dist/collection/components/refine-selection/refine-selection.js +1 -1
- package/dist/collection/components/share-item/share-item.js +1 -1
- package/dist/collection/components/solution-configuration/solution-configuration.js +3 -3
- package/dist/collection/components/solution-contents/solution-contents.js +1 -1
- package/dist/collection/components/solution-item/solution-item.js +1 -1
- package/dist/collection/components/solution-item-accordion/solution-item-accordion.js +1 -1
- package/dist/collection/components/solution-item-details/solution-item-details.js +1 -1
- package/dist/collection/components/solution-item-icon/solution-item-icon.js +1 -1
- package/dist/collection/components/solution-item-sharing/solution-item-sharing.js +1 -1
- package/dist/collection/components/solution-organization-variables/solution-organization-variables.js +1 -1
- package/dist/collection/components/solution-resource-item/solution-resource-item.js +1 -1
- package/dist/collection/components/solution-spatial-ref/solution-spatial-ref.js +1 -1
- package/dist/collection/components/solution-template-data/solution-template-data.js +1 -1
- package/dist/collection/components/solution-variables/solution-variables.js +1 -1
- package/dist/collection/components/spatial-ref/spatial-ref.js +1 -1
- package/dist/collection/utils/downloadUtils.js +5 -3
- package/dist/collection/utils/downloadUtils.ts +6 -3
- package/dist/collection/utils/test/downloadUtils.spec.tsx +10 -12
- package/dist/components/card-manager2.js +40 -34
- package/dist/components/create-feature2.js +4 -2
- package/dist/components/crowdsource-manager.js +127 -123
- package/dist/components/crowdsource-reporter.js +110 -101
- package/dist/components/delete-button2.js +24 -41
- package/dist/components/delete-dialog.d.ts +11 -0
- package/dist/components/delete-dialog.js +11 -0
- package/dist/components/delete-dialog2.js +165 -0
- package/dist/components/downloadUtils.js +5 -4
- package/dist/components/edit-card2.js +1 -1
- package/dist/components/feature-comments.js +1 -1
- package/dist/components/feature-details2.js +67 -59
- package/dist/components/feature-form-flow-item.js +1 -1
- package/dist/components/feature-list2.js +4 -4
- package/dist/components/features-flow-item.js +1 -1
- package/dist/components/floor-filter2.js +1 -1
- package/dist/components/info-card2.js +38 -32
- package/dist/components/json-editor2.js +1 -1
- package/dist/components/layer-list2.js +5 -5
- package/dist/components/layer-table2.js +100 -82
- package/dist/components/layout-manager.js +1 -1
- package/dist/components/list-flow-item.js +1 -1
- package/dist/components/location-flow-item.js +1 -1
- package/dist/components/map-card2.js +1 -1
- package/dist/components/map-draw-tools2.js +1 -1
- package/dist/components/map-fullscreen2.js +1 -1
- package/dist/components/map-layer-picker2.js +1 -1
- package/dist/components/map-legend2.js +2 -1
- package/dist/components/map-picker2.js +1 -1
- package/dist/components/map-search2.js +1 -1
- package/dist/components/map-select-tools2.js +1 -1
- package/dist/components/map-tools2.js +1 -1
- package/dist/components/pci-calculator.js +1 -1
- package/dist/components/pdf-download2.js +1 -1
- package/dist/components/public-notification.js +1 -1
- package/dist/components/refine-results-flow-item.js +1 -1
- package/dist/components/refine-selection2.js +1 -1
- package/dist/components/share-item.js +1 -1
- package/dist/components/solution-configuration.js +3 -3
- package/dist/components/solution-contents2.js +1 -1
- package/dist/components/solution-item-accordion.js +1 -1
- package/dist/components/solution-item-details2.js +1 -1
- package/dist/components/solution-item-icon2.js +1 -1
- package/dist/components/solution-item-sharing2.js +1 -1
- package/dist/components/solution-item2.js +1 -1
- package/dist/components/solution-organization-variables2.js +1 -1
- package/dist/components/solution-resource-item2.js +1 -1
- package/dist/components/solution-spatial-ref2.js +1 -1
- package/dist/components/solution-template-data2.js +1 -1
- package/dist/components/solution-variables2.js +1 -1
- package/dist/components/spatial-ref.js +1 -1
- package/dist/esm/basemap-gallery_7.entry.js +7 -6
- package/dist/esm/buffer-tools_3.entry.js +1 -1
- package/dist/esm/calcite-alert_5.entry.js +10 -8
- package/dist/esm/calcite-combobox_3.entry.js +1 -1
- package/dist/esm/calcite-flow_4.entry.js +18 -16
- package/dist/esm/{calcite-modal_3.entry.js → calcite-modal.entry.js} +30 -369
- package/dist/esm/calcite-shell-panel_14.entry.js +7 -7
- package/dist/esm/calcite-shell_3.entry.js +434 -0
- package/dist/esm/card-manager_3.entry.js +22 -11
- package/dist/esm/crowdsource-manager.entry.js +28 -31
- package/dist/esm/crowdsource-reporter.entry.js +24 -21
- package/dist/esm/{downloadUtils-e266e98d.js → downloadUtils-bc7a4ba1.js} +6 -5
- package/dist/esm/feature-comments.entry.js +1 -1
- package/dist/esm/feature-form-flow-item.entry.js +1 -1
- package/dist/esm/feature-list.entry.js +7 -7
- package/dist/esm/features-flow-item.entry.js +1 -1
- package/dist/esm/{index.es-c5f258e2.js → index.es-0d189a34.js} +2 -2
- package/dist/esm/layout-manager.entry.js +1 -1
- package/dist/esm/list-flow-item.entry.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/location-flow-item.entry.js +1 -1
- package/dist/esm/map-select-tools_3.entry.js +5 -5
- package/dist/esm/pci-calculator.entry.js +1 -1
- package/dist/esm/{popupUtils-4570096e.js → popupUtils-03dc398a.js} +1 -1
- package/dist/esm/public-notification.entry.js +3 -3
- package/dist/esm/refine-results-flow-item.entry.js +1 -1
- package/dist/esm/share-item.entry.js +1 -1
- package/dist/esm/solution-configuration.entry.js +3 -3
- package/dist/esm/solution-contents_3.entry.js +3 -3
- package/dist/esm/solution-item-accordion.entry.js +1 -1
- package/dist/esm/solution-item-icon.entry.js +1 -1
- package/dist/esm/solutions-components.js +1 -1
- package/dist/esm/spatial-ref.entry.js +1 -1
- package/dist/solutions-components/assets/t9n/delete-dialog/resources.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_ar.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_bg.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_bs.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_ca.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_cs.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_da.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_de.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_el.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_en.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_es.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_et.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_fi.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_fr.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_he.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_hr.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_hu.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_id.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_it.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_ja.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_ko.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_lt.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_lv.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_nb.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_nl.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_pl.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_pt-BR.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_pt-PT.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_ro.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_ru.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_sk.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_sl.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_sr.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_sv.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_th.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_tr.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_uk.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_vi.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_zh-CN.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_zh-HK.json +8 -0
- package/dist/solutions-components/assets/t9n/delete-dialog/resources_zh-TW.json +8 -0
- package/dist/solutions-components/{p-ffa9a117.entry.js → p-04ab956c.entry.js} +1 -1
- package/dist/solutions-components/{p-6c3261d7.entry.js → p-06364211.entry.js} +1 -1
- package/dist/solutions-components/{p-d119872d.entry.js → p-18089a0b.entry.js} +1 -1
- package/dist/solutions-components/p-1f07e21a.entry.js +6 -0
- package/dist/solutions-components/p-2a6ecaa9.entry.js +11 -0
- package/dist/solutions-components/p-46416e11.entry.js +6 -0
- package/dist/solutions-components/{p-5fc0e134.entry.js → p-59ccd27c.entry.js} +1 -1
- package/dist/solutions-components/{p-42f75c8f.entry.js → p-6502d0f8.entry.js} +1 -1
- package/dist/solutions-components/{p-a568af9f.js → p-6f606cdb.js} +1 -1
- package/dist/solutions-components/p-70c0050c.entry.js +6 -0
- package/dist/solutions-components/p-720de4db.entry.js +6 -0
- package/dist/solutions-components/p-74bcef23.entry.js +11 -0
- package/dist/solutions-components/{p-4cb12506.entry.js → p-76154700.entry.js} +1 -1
- package/dist/solutions-components/p-82ddf716.entry.js +6 -0
- package/dist/solutions-components/{p-d08ece15.entry.js → p-841816a1.entry.js} +1 -1
- package/dist/solutions-components/p-938bc915.entry.js +6 -0
- package/dist/solutions-components/p-97fe6ec5.entry.js +6 -0
- package/dist/solutions-components/{p-dd0bd439.entry.js → p-9c4fef09.entry.js} +3 -3
- package/dist/solutions-components/{p-fa7672c7.entry.js → p-9d56f4b5.entry.js} +1 -1
- package/dist/solutions-components/p-9da8a590.entry.js +6 -0
- package/dist/solutions-components/{p-5fdb8f83.entry.js → p-a5d79c86.entry.js} +1 -1
- package/dist/solutions-components/{p-4f5913f3.entry.js → p-aac0c89c.entry.js} +1 -1
- package/dist/solutions-components/{p-ddc1218d.entry.js → p-be4c7ffd.entry.js} +1 -1
- package/dist/solutions-components/p-cd482a33.js +21 -0
- package/dist/solutions-components/p-d2612c30.entry.js +6 -0
- package/dist/solutions-components/{p-a07322cc.entry.js → p-df7de4b7.entry.js} +1 -1
- package/dist/solutions-components/{p-a8525233.entry.js → p-e345f9c4.entry.js} +1 -1
- package/dist/solutions-components/{p-1f072e2c.entry.js → p-eadff42b.entry.js} +1 -1
- package/dist/solutions-components/{p-06db1bfd.entry.js → p-efb4cb43.entry.js} +1 -1
- package/dist/solutions-components/{p-e4a42efa.entry.js → p-fa1c368c.entry.js} +1 -1
- package/dist/solutions-components/{p-46c8015c.js → p-ff9e28d1.js} +30 -30
- package/dist/solutions-components/solutions-components.esm.js +1 -1
- package/dist/solutions-components/utils/downloadUtils.ts +6 -3
- package/dist/solutions-components/utils/test/downloadUtils.spec.tsx +10 -12
- package/dist/types/components/crowdsource-manager/crowdsource-manager.d.ts +4 -7
- package/dist/types/components/crowdsource-reporter/crowdsource-reporter.d.ts +6 -1
- package/dist/types/components/delete-button/delete-button.d.ts +4 -12
- package/dist/types/components/delete-dialog/delete-dialog.d.ts +75 -0
- package/dist/types/components/layer-table/layer-table.d.ts +12 -0
- package/dist/types/components.d.ts +69 -0
- package/dist/types/preact.d.ts +5 -0
- package/package.json +2 -1
- package/dist/solutions-components/p-2360802a.js +0 -21
- package/dist/solutions-components/p-51e2500f.entry.js +0 -6
- package/dist/solutions-components/p-52280e10.entry.js +0 -17
- package/dist/solutions-components/p-67ca4a64.entry.js +0 -6
- package/dist/solutions-components/p-7e6a8c06.entry.js +0 -6
- package/dist/solutions-components/p-8a411917.entry.js +0 -6
- package/dist/solutions-components/p-8d2d66d0.entry.js +0 -6
- package/dist/solutions-components/p-8e6081e0.entry.js +0 -6
- package/dist/solutions-components/p-b9b77b87.entry.js +0 -6
- package/dist/solutions-components/p-cf878a34.entry.js +0 -6
- package/dist/solutions-components/p-edd88d2d.entry.js +0 -6
@@ -21101,7 +21101,7 @@ const SpatialRef = class {
|
|
21101
21101
|
* Renders the component.
|
21102
21102
|
*/
|
21103
21103
|
render() {
|
21104
|
-
return (h(Host, { key: '
|
21104
|
+
return (h(Host, { key: '1da00c18c49d769c98e236f73e648dd880df6e2a' }, h("div", { key: '61da287f6865c90a1b4b523cb13d689247255573' }, h("calcite-input", { key: 'e129b4a009fa12f9aff37384debe673dbed31774', disabled: this.disabled, id: "calcite-sr-search", onKeyUp: (evt) => this._searchInputKeyDown(evt), placeholder: this._translations.spatialReferencePlaceholder }), h("calcite-tree", { key: '125c006a62fda7fd1204c81374c119b562424e26', id: "calcite-sr-tree", slot: "children" }, this._getTreeContent()))));
|
21105
21105
|
}
|
21106
21106
|
_lastHighlightedSref;
|
21107
21107
|
//--------------------------------------------------------------------------
|
@@ -0,0 +1,8 @@
|
|
1
|
+
{
|
2
|
+
"cancel": "Cancel·la",
|
3
|
+
"confirmMultiple": "Aquestes entitats s'eliminaran permanentment.",
|
4
|
+
"confirmSingle": "Aquesta entitat s'eliminarà permanentment.",
|
5
|
+
"delete": "Suprimeix",
|
6
|
+
"deleteCount": "Suprimeix ({{n}})",
|
7
|
+
"deleteFeature": "Suprimeix l'entitat"
|
8
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
{
|
2
|
+
"cancel": "Cancelar",
|
3
|
+
"confirmMultiple": "Estas entidades se eliminarán de forma permanente.",
|
4
|
+
"confirmSingle": "Esta entidad se eliminará de forma permanente.",
|
5
|
+
"delete": "Eliminar",
|
6
|
+
"deleteCount": "Eliminar ({{n}})",
|
7
|
+
"deleteFeature": "Eliminar entidad"
|
8
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
{
|
2
|
+
"cancel": "Annuler",
|
3
|
+
"confirmMultiple": "Ces entités seront définitivement supprimées.",
|
4
|
+
"confirmSingle": "Cette entité sera définitivement supprimée.",
|
5
|
+
"delete": "Supprimer",
|
6
|
+
"deleteCount": "Supprimer ({{n}})",
|
7
|
+
"deleteFeature": "Supprimer l’entité"
|
8
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
{
|
2
|
+
"cancel": "Mégse",
|
3
|
+
"confirmMultiple": "Ezek a vektoros elemek végleg el lesznek távolítva.",
|
4
|
+
"confirmSingle": "A vektoros elem véglegesen el lesz távolítva.",
|
5
|
+
"delete": "Törlés",
|
6
|
+
"deleteCount": "Törlés ({{n}})",
|
7
|
+
"deleteFeature": "Vektoros elem törlése"
|
8
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
{
|
2
|
+
"cancel": "Cancelar",
|
3
|
+
"confirmMultiple": "Estes elementos serão permanentemente removidos.",
|
4
|
+
"confirmSingle": "Este elemento será permanentemente removido.",
|
5
|
+
"delete": "Eliminar",
|
6
|
+
"deleteCount": "Eliminar ({{n}})",
|
7
|
+
"deleteFeature": "Eliminar elemento"
|
8
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
{
|
2
|
+
"cancel": "Anulare",
|
3
|
+
"confirmMultiple": "Aceste obiecte spațiale vor fi eliminate definitiv.",
|
4
|
+
"confirmSingle": "Acest obiect spațial va fi eliminat definitiv.",
|
5
|
+
"delete": "Ștergere",
|
6
|
+
"deleteCount": "Ștergere ({{n}})",
|
7
|
+
"deleteFeature": "Ştergere obiect spaţial"
|
8
|
+
}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as i,c as t,g as e,h as s,H as a}from"./p-4e6eb06e.js";import{a as h,l,g as n}from"./p-f4aadb3b.js";import{e as o,h as r,k as c,l as d,c as p,m as b,n as g,o as f}from"./p-d572627c.js";import{a as y,e as m,f as u}from"./p-80cb7c73.js";import{s as w}from"./p-51c6e6fe.js";import{d as v,a as _}from"./p-46c8015c.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-dc9d4be3.js";import"./p-d0d020a5.js";import"./p-7530a02f.js";import"./p-9bb44f57.js";const S=class{constructor(e){i(this,e),this.selectionSetChange=t(this,"selectionSetChange",7),this.bufferColor=[227,139,79,.8],this.bufferOutlineColor=[255,255,255],this.customLabelEnabled=void 0,this.enabledLayerIds=[],this.enableLayerFeatures=!0,this.enableLayerFeaturesOnLoad=!1,this.enableSearchDistance=!0,this.enableSearchDistanceOnLoad=!1,this.enableSketchTools=!0,this.defaultBufferDistance=void 0,this.defaultBufferUnit=void 0,this.geometries=[],this.isUpdate=!1,this.layerViews=[],this.locale=void 0,this.mapView=void 0,this.noResultText=void 0,this.searchConfiguration=void 0,this.selectionSet=void 0,this.selectionLayerIds=[],this.selectLayerView=void 0,this.sketchLineSymbol=void 0,this.sketchPointSymbol=void 0,this.sketchPolygonSymbol=void 0,this._numSelected=0,this._searchDistanceEnabled=!1,this._searchTerm=void 0,this._selectionLoading=!1,this._translations=void 0,this._useLayerFeaturesEnabled=!1}get el(){return e(this)}_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(i,t){if(i!==t){const t=0===i.length;if(await this._clearResults(t,t),i.length>0)return this._highlightWithOIDsOrGeoms()}}async mapViewWatchHandler(i,t){i&&i!==t&&await this._init()}async watchSearchConfigurationHandler(i,t){JSON.stringify(i)!==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(i){this.searchConfiguration=i.detail}async distanceChanged(i){await this._distanceChanged(i.detail)}async unitChanged(i){i.detail.newValue!==i.detail.oldValue&&(this._unit=i.detail.newValue,await this._updateLabel())}async componentWillLoad(){await this._getTranslations(),await this._initModules()}async componentDidLoad(){await this._init()}render(){const i=this.enableSketchTools?"":"display-none",t=this.enableSketchTools?"padding-top-1":"";return s(a,{key:"6753158d00a33dd5dfbb1f22cc27388baf4c0b5e"},this._getMapLayerPicker(),s("div",{key:"082c6be48d3dfbe2e39be2c462959c7772a91d40",class:"border-bottom"}),s("div",{key:"0e8133a809b05bef34c2f19adeff43c1e57cc002",class:"padding-top-sides-1"},s("div",{key:"4434b5b4d073f3ba9a7e44b82078b9b81733025b",class:"search-widget",ref:i=>{this._searchElement=i}}),s("div",{key:"6f01e27e06ea365de6ff98df3f9edd973d87117c",class:t},s("map-draw-tools",{key:"24ffe562d080955f2aacfd080c0baa1997f8eaab",active:!0,class:i,editGraphicsEnabled:!this._useLayerFeaturesEnabled,graphics:this._graphics,mapView:this.mapView,onSketchGraphicsChange:i=>{this._sketchGraphicsChanged(i)},pointSymbol:this.sketchPointSymbol,polygonSymbol:this.sketchPolygonSymbol,polylineSymbol:this.sketchLineSymbol,ref:i=>{this._drawTools=i}})),this.enableSearchDistance?this._getBufferOptions():void 0,this.enableLayerFeatures?this._getUseLayerFeaturesOptions():void 0,this._getNumSelected()),s("div",{key:"4c7cf401b5bcc7e4adef34e140d22676fce8ebbc",class:"border-bottom"}),this._getNameInput())}_getBufferOptions(){this.enableSearchDistanceOnLoad&&(this._searchDistanceEnabled=!0,this.enableSearchDistanceOnLoad=!1);const i=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:i},s("buffer-tools",{disabled:!this._searchDistanceEnabled,distance:t,geometries:this.geometries,onBufferComplete:i=>{this._bufferComplete(i)},ref:i=>this._bufferTools=i,unit:this.selectionSet?.unit||this.defaultBufferUnit})))}_getUseLayerFeaturesOptions(){this.enableLayerFeaturesOnLoad&&(this._useLayerFeaturesEnabled=!0,this.enableLayerFeaturesOnLoad=!1);const i=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:i+" padding-top-1"},s("map-layer-picker",{enabledLayerIds:this.selectionLayerIds,mapView:this.mapView,onLayerSelectionChange:i=>{this._layerSelectionChange(i)},selectedIds:this.layerViews.map((i=>i.layer.id)),showTables:!1})))}_getNumSelected(){const i=h(this.el),t=i&&"en"===i?`${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:i=>{this._labelName=i},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,mapView:this.mapView,onLayerSelectionChange:i=>{this._inputLayerSelectionChange(i)},selectedIds:this.selectLayerView?[this.selectLayerView.layer.id]:this.selectionSet?[this.selectionSet.layerView.layer.id]:[],showTables:!1})))}async _initModules(){const[i,t,e,s,a,h]=await l(["esri/request","esri/layers/GraphicsLayer","esri/Graphic","esri/widgets/Search","esri/geometry/geometryEngine","esri/layers/FeatureLayer"]);this._esriRequest=i,this.GraphicsLayer=t,this.Graphic=e,this.Search=s,this._geometryEngine=a,this.FeatureLayer=h}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((i=>new this.Graphic({geometry:i,symbol:"point"===i.type?this.sketchPointSymbol:"polyline"===i.type?this.sketchLineSymbol:this.sketchPolygonSymbol}))),this._selectionLabel=this.selectionSet?.label,this._useLayerFeaturesEnabled||await(this._drawTools?.updateGraphics()),await o(this.selectionSet.selectedIds,this.selectionSet.layerView,this.mapView,!1))}async _initSearchWidget(){if(this.mapView&&this._searchElement){const i=this._getSearchConfig(this.searchConfiguration,this.mapView),t={view:this.mapView,container:this._searchElement,searchTerm:this._searchTerm,...i};this._searchWidget=new this.Search(t),this._searchWidget.popupEnabled=!1,this._searchWidget.resultGraphicEnabled=!1,this._searchWidget.on("search-clear",(()=>{const i=this._searchClearLabel();this._clearResults(!1,i)})),this._searchWidget.on("select-result",(i=>{this._selectResult(i.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(i){if(i){this._searchResult=i;const t=i.feature,e=t?.layer,s=this.selectLayerView.layer,a=t?.getObjectId();let h,l;e.sourceJSON?.isView&&(h=await this._getViewSourceUrl(e.url)),s.sourceJSON?.isView&&(l=await this._getViewSourceUrl(s.url));const n=e?.url?.toLowerCase(),o=h?.toLowerCase(),r=s?.url?.toLowerCase(),c=l?.toLowerCase(),d=n&&r&&(n===r||n===c||o===r||o===c)&&!isNaN(a),p=d?[a]:void 0;this._workflowType=y.SEARCH,this._updateLabel();const b=[i.feature];this._updateSelection(b,d,p),this._drawTools.graphics=b,this._searchWidget.resultGraphic.visible=!1}else{const i=this._searchClearLabel();this._clearResults(!1,i)}}async _getViewSourceUrl(i){let t="";const e=`${i}/sources?f=json`;try{const i=await this._esriRequest(e,{query:{f:"json"}});1===i?.data?.services?.length&&(t=i.data.services[0].url)}catch(i){console.log(i)}return t}_searchClearLabel(){return this._searchResult?.name&&this._labelName.value.indexOf(this._searchResult.name)>-1}_getSearchConfig(i,t){const e=i?.sources;return e?.length>0?(i={...i,includeDefaultSources:!1},e.forEach((i=>{if(i.hasOwnProperty("layer")){const e=i,s=e.layer?.id,a=s?t.map.findLayerById(s):null,h=e?.layer?.url;a?e.layer=a:h&&(e.layer=new this.FeatureLayer(h))}})),e?.forEach((i=>{if(i.hasOwnProperty("locator")){const t=i;"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}}))):i={...i,includeDefaultSources:!0},i}_initGraphicsLayer(){const i=this._translations.bufferLayer;if(this.mapView){const t=this.mapView.map.layers.findIndex((t=>t.title===i));if(t>-1)this._bufferGraphicsLayer=this.mapView.map.layers.getItemAt(t);else{this._bufferGraphicsLayer=new this.GraphicsLayer({title:i,listMode:"hide"}),w.managedLayers[i]="buffer";const t=this.mapView.map.layers.findIndex((i=>i.title===this._translations.sketchLayer));t>-1?this.mapView.map.layers.add(this._bufferGraphicsLayer,t):this.mapView.map.layers.add(this._bufferGraphicsLayer)}}}async _sketchGraphicsChanged(i,t=!1){const e=i.detail.graphics;if(e.length>0&&e[0])if(t||(this._sketchGraphic=e[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 i=Array.isArray(e)?e.map((i=>i.geometry)):this.geometries;await this._selectLayerFeatures(i[0])}else{const t=e.reduce(((i,t)=>(t?.layer?.objectIdField?i.push(t.attributes[t.layer.objectIdField]):t.getObjectId&&i.push(t.getObjectId()),i)),[]),s=i.detail.useOIDs&&t.length>0;this._updateSelection(e,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(i){w.removeHandles(),i.length>0&&w.highlightHandles.push(await r(i,this.selectLayerView,this.mapView)),this._numSelected=i.length,this.selectionSetChange.emit(i.length)}async _selectFeatures(i){this._selectionLoading=!0,this._selectedIds=await c(i,this.selectLayerView.layer),this._selectionLoading=!1,this._drawTools.graphics=this._graphics,await this._highlightFeatures(this._selectedIds)}async _bufferComplete(i){this._bufferGeometry=Array.isArray(i.detail)?i.detail[0]:i.detail;let t=this._bufferTools.distance,e=0;if(this._bufferGeometry){const i=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(i),await this._selectFeatures([this._bufferGeometry]),await this.mapView.goTo(i.geometry.extent),e=t,t=0}else this._bufferGraphicsLayer&&this._bufferGraphicsLayer.removeAll(),await this._highlightWithOIDsOrGeoms();await this._distanceChanged({oldValue:t,newValue:e})}_geomQuery(i){const t=d(i,this._geometryEngine);return this._selectFeatures(t)}async _clearResults(i=!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(),i&&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(i,t,e){this._selectedIds=t&&e?e:this._selectedIds,this._skipGeomOIDs=t?e:void 0,this.geometries=Array.isArray(i)?i.map((i=>i.geometry)):this.geometries,this._graphics=i}async _updateLabel(){if(this.enableSearchDistance){const i=this._selectionLabel.indexOf(this._translations.sketch)>-1,t=this._selectionLabel.indexOf(this._translations.select)>-1,e=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,h=await this._bufferTools.getTranslatedUnit(a),l=isNaN(this._distance)?this._bufferTools.distance:this._distance;this._selectionLabel=i||t||e||!this._selectionLabel?`${s} ${l} ${h}`:this._selectionLabel,this._labelName.value=this._selectionLabel}}async _layerSelectionChange(i){if(Array.isArray(i.detail)&&i.detail.length>0){const t=i.detail.map((i=>p(this.mapView,i)));return Promise.all(t).then((i=>{this.layerViews=i,this._featuresCollection={},this._sketchGraphic&&this._sketchGraphicsChanged({detail:{graphics:[this._sketchGraphic],useOIDs:!1}})}))}}async _inputLayerSelectionChange(i){const t=i?.detail?.length>0?i.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(i){i.newValue!==i.oldValue&&(this._distance=i.newValue,await this._updateLabel())}async _selectLayerFeatures(i){this._selectionLoading=!0;const t=this.layerViews.map((t=>(this._featuresCollection[t.layer.id]=[],b(0,t.layer,i,this._featuresCollection))));return Promise.all(t).then((async i=>{this._selectionLoading=!1;let t=[];i.forEach((i=>{Object.keys(i).forEach((e=>{t=t.concat(i[e])}))}));let e=!1;t.forEach((i=>{const t=i.geometry;i.symbol="point"===t.type?this.sketchPointSymbol:"polyline"===t.type?this.sketchLineSymbol:"polygon"===t.type?this.sketchPolygonSymbol:void 0,e=i?.layer?.hasOwnProperty("objectIdField")||i.hasOwnProperty("getObjectId")}));const s=this.layerViews[0].layer,a=this.selectLayerView.layer,h=e&&s.url===a.url&&a.layerId===s.layerId;await this._sketchGraphicsChanged({detail:{graphics:t,useOIDs:h}},!0)}))}_useLayerFeaturesEnabledChanged(){this._useLayerFeaturesEnabled=!this._useLayerFeaturesEnabled,this._sketchGraphic&&this._sketchGraphicsChanged({detail:{graphics:[this._sketchGraphic],useOIDs:!1}})}async _getTranslations(){const i=await n(this.el);this._translations=i[0]}static get watchers(){return{geometries:["watchGeometriesHandler"],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){i(this,t),this.defaultNumLabelsPerPage=void 0,this.disabled=!1,this._translations=void 0}get el(){return e(this)}_labelInfoElement;_intl;async downloadCSV(i,t,e,s=!0){return v(i,t,!0,e,s)}async downloadPDF(i,t,e=!1,s="",a=""){return _(i,t,this._labelInfoElement.selectedOption?.value,e,s,a)}async componentWillLoad(){await this._getTranslations(),await this._initModules()}render(){return s(a,{key:"ff0ad2a97a113ccfaa10d5219d93f5b07319fb33"},s("calcite-select",{key:"4675536d2732329715198c54b5c03c8748d7732a",disabled:this.disabled,label:"",ref:i=>{this._labelInfoElement=i}}))}componentDidLoad(){this._renderOptions()}async _initModules(){const[i]=await l(["esri/intl"]);this._intl=i}_getLabelSizeText(i){const t="‎"+i.descriptionPDF.labelWidthDisplay+" x "+i.descriptionPDF.labelHeightDisplay+"‏";return this._translations.pdfLabel.replace("{{n}}",i.descriptionPDF.labelsPerPageDisplay).replace("{{labelSize}}",t)}async _getTranslations(){const i=await n(this.el);this._translations=i[0]}_renderOptions(){(L.default||L).sort(((i,t)=>{const e=parseInt(i.descriptionPDF.labelsPerPageDisplay,10),s=parseInt(t.descriptionPDF.labelsPerPageDisplay,10);return e<s?-1:e>s?1:0})).forEach(((i,t)=>{const e=document.createElement("calcite-option");e.value=i,e.innerHTML=this._getLabelSizeText(i),this._labelInfoElement.appendChild(e),(this.defaultNumLabelsPerPage?parseInt(i.descriptionPDF.labelsPerPageDisplay,10)===this.defaultNumLabelsPerPage:0===t)&&(e.selected=!0,this._labelInfoElement.selectedOption=e)}))}};k.style=":host{display:block}";const P=class{constructor(e){i(this,e),this.selectionLoadingChange=t(this,"selectionLoadingChange",7),this.selectionSetsChanged=t(this,"selectionSetsChanged",7),this.addresseeLayer=void 0,this.enabledLayerIds=[],this.locale=void 0,this.mapView=void 0,this.selectionSets=[],this.sketchLineSymbol=void 0,this.sketchPointSymbol=void 0,this.sketchPolygonSymbol=void 0,this._translations=void 0,this._selectionMode=m.ADD,this._refineLayer=void 0}get el(){return e(this)}_addEnabled=!0;_drawTools;_refineSets=[];_enabledLayerIds=[];_layerPicker;_featuresCollection={};_refineSelectionSet;selectionLoadingChange;selectionSetsChanged;async componentWillLoad(){await this._getTranslations(),this._enabledLayerIds=this._getEnabledLayerIds(),await this._setRefineSet(this._enabledLayerIds[0])}render(){return s(a,{key:"b3693694a5d007dd6add79848d1254a1ee52b8e3"},s("div",{key:"c464770d28fb981e9fba4d5cb3709684e41cbdc3",class:(this._enabledLayerIds.length>1?"display-block":"display-none")+" padding-top-sides-1"},s("div",{key:"2972637e3194c86d097a491678eb8b508bbf2fd2",class:"display-flex"},s("calcite-label",{key:"242295f4d8f2f17554b99748795a5bc1e1f05dcb",class:"font-bold width-full label-margin-0"},s("div",{key:"f2643bf44301aaa0a1d67595dac537c6bad21928",class:"display-flex"},this._translations.inputLayer,s("calcite-icon",{key:"1d068bd809b36b4aba7e3836d2fc8b33d6de5d3e",class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"refine-input-layer",scale:"s"})),s("map-layer-picker",{key:"e97947859dfa0a718595bfb54c843b6358ece94e",enabledLayerIds:this._enabledLayerIds,mapView:this.mapView,onLayerSelectionChange:i=>{this._layerSelectionChange(i)},ref:i=>{this._layerPicker=i},selectedIds:[this._refineLayer.layer.id],showTables:!1})),s("calcite-popover",{key:"e78a114a50aec427b6f6f0e4f8096447e464ba7e",closable:!0,label:"",referenceElement:"refine-input-layer"},s("span",{key:"b7abd37b2907c0ef98059fd280dd30cfa4eea2d2",class:"tooltip-message"},this._translations.inputLayerTip)))),s("div",{key:"3d5869d473e7c8068969e07619fc891268422f2b",class:"padding-1"},s("div",{key:"b89ed77287dc4ae5a6f7a7589faccbbc4da3b524",class:"padding-bottom-1"},s("calcite-segmented-control",{key:"1f0d85ab4ed9af445ff8b9bc5c7d4be80733f573",class:"w-100",width:"full"},s("calcite-segmented-control-item",{key:"229473e79f8ddc6c95ad0a09fdd3fef08c176b1e",checked:this._addEnabled,class:"w-50 word-wrap-anywhere",onClick:()=>this._setSelectionMode(m.ADD),value:m.ADD},s("span",{key:"27f7e1f70da8ae44cab4d2643d58b0bfe8e3ad6c",class:"font-weight-500"},this._translations.add)),s("calcite-segmented-control-item",{key:"b6c4199b48d7cedec36510572de7f63ee105b605",checked:!this._addEnabled,class:"w-50 word-wrap-anywhere",onClick:()=>this._setSelectionMode(m.REMOVE),value:m.REMOVE},s("span",{key:"c3047bd7b4564b171ed8cb7c7842b64e7a4677f8",class:"font-weight-500"},this._translations.remove)))),s("div",{key:"14408ec1abdbb64e4c4ccc473b3615d7036399f7"},s("map-draw-tools",{key:"fe946dc9ae433dabe45f5da695cde3daaa9e057d",active:!0,drawMode:u.REFINE,mapView:this.mapView,onDrawRedo:()=>this._redo(),onDrawUndo:()=>this._undo(),onSketchGraphicsChange:i=>this._sketchGraphicsChanged(i),pointSymbol:this.sketchPointSymbol,polygonSymbol:this.sketchPolygonSymbol,polylineSymbol:this.sketchLineSymbol,redoEnabled:this._refineSelectionSet?.redoStack.length>0,ref:i=>{this._drawTools=i},undoEnabled:this._refineSelectionSet?.undoStack.length>0})),s("br",{key:"a532f7b86708d6839449397841a68f2258645410"}),s("calcite-list",{key:"ef51c27c396c52c8fcb1c512957b3b2e276306e4",class:"list-border"},this._getRefineSelectionSetList())))}_layerSelectionChange(i){this._setRefineSet(i.detail[0])}_setSelectionMode(i){this._selectionMode=i}_sketchGraphicsChanged(i){const t=i.detail?.graphics[0].geometry;this._selectFeatures(t)}_getEnabledLayerIds(){return this.selectionSets.reduce(((i,t)=>{const e=t?.layerView?.layer.id;return e&&i.indexOf(e)<0?i.push(e):t.workflowType===y.REFINE&&Object.keys(t.refineInfos).forEach((t=>{i.indexOf(t)<0&&i.push(t)})),i}),[])}async _setRefineSet(i){this.selectionSets.some((t=>{if(t.workflowType===y.REFINE)return this._refineSelectionSet=t,Object.keys(t.refineInfos).indexOf(i)>-1}))||await this._initRefineSet(i,this._refineSelectionSet),this._refineLayer=this._refineSelectionSet.refineInfos[i].layerView}async _initRefineSet(i,t){const e={};e[i]={addIds:[],removeIds:[],layerView:await p(this.mapView,i)},t?t.refineInfos={...t.refineInfos,...e}:(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:e,redoStack:[],undoStack:[],sketchGraphic:void 0},this.selectionSets.push(this._refineSelectionSet))}_undo(){const i=this._refineSelectionSet.undoStack.pop();this._updateIds(i.ids,i.mode===m.ADD?m.REMOVE:m.ADD,this._refineSelectionSet.redoStack,i.layerView)}_redo(){const i=this._refineSelectionSet.redoStack.pop();this._updateIds(i.ids,i.mode===m.ADD?m.REMOVE:m.ADD,this._refineSelectionSet.undoStack,i.layerView)}_getRefineSelectionSetList(){const i=this._getTotal(this.selectionSets);let t;this.selectionSets.some((i=>{if(i.workflowType===y.REFINE)return t=i,!0}));let e=0,a=0;return Object.keys(t.refineInfos).forEach((i=>{e+=t.refineInfos[i].addIds.length,a+=t.refineInfos[i].removeIds.length})),[s("calcite-list-item",{label:this._translations.featuresAdded.replace("{{n}}",e.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}}",i.toString()),"non-interactive":!0})]}_getTotal(i){const t=g(i);return Object.keys(t).reduce(((i,e)=>i+t[e].ids.length),0)}async _getTranslations(){const i=await n(this.el);this._translations=i[0]}async _selectFeatures(i){this.selectionLoadingChange.emit(!0),this._featuresCollection[this._refineLayer?.layer.id]=[];const t=await b(0,this._refineLayer?.layer,i,this._featuresCollection);this.selectionLoadingChange.emit(!1);let e=[];Object.keys(t).forEach((i=>{i===this._refineLayer?.layer.id&&(e=e.concat(t[i]))}));const s=Array.isArray(e)?e.map((i=>i.attributes[i?.layer?.objectIdField])):[];await this._updateIds(s,this._selectionMode,this._refineSelectionSet.undoStack,this._refineLayer),this._drawTools.clear()}async _highlightFeatures(){this._clearHighlight(),w.highlightHandles=await f(this.selectionSets)}_clearHighlight(){w.removeHandles()}async _updateIds(i,t,e,s){let a=!1;const h=this._refineSelectionSet.refineInfos,l=s.layer.id,n={};n[l]={addIds:[],removeIds:[],layerView:s};const o=Object.keys(h).indexOf(l)>-1?h[l]:n[l];if(t===m.ADD)o.addIds=[...new Set([...i,...o.addIds])],o.addIds.length>0&&e.push({ids:i,mode:t,layerView:s}),o.removeIds.length>0&&(o.removeIds=o.removeIds.filter((t=>i.indexOf(t)<0)));else{const h=this.selectionSets.reduce(((t,e)=>(i.forEach((i=>{e.workflowType!==y.REFINE?e.selectedIds.indexOf(i)>-1&&t.push(i):Object.keys(e.refineInfos).some((a=>{const h=e.refineInfos[a];if(h.layerView.layer.id===s.layer.id&&h.addIds.indexOf(i)>-1)return t.push(i),!0}))})),t)),[]);o.removeIds=[...new Set([...h,...o.removeIds])],o.addIds=o.addIds.filter((i=>h.indexOf(i)<0)),o.removeIds.length>0&&e.push({ids:h,mode:t,layerView:s}),this.selectionSets=this.selectionSets.reduce(((i,t)=>(t.workflowType!==y.REFINE&&t.layerView.layer.id===s.layer.id?(t.selectedIds=t.selectedIds.filter((i=>o.removeIds.indexOf(i)<0)),t.selectedIds.length>0?i.push(t):a=!0):i.push(t),i)),[])}this._refineSelectionSet.refineInfos[l]=o,this.selectionSets=[...this.selectionSets],a&&this.selectionSetsChanged.emit(this.selectionSets),await this._highlightFeatures()}};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}
|
6
|
+
import{r as i,c as t,g as e,h as s,H as a}from"./p-4e6eb06e.js";import{a as h,l,g as n}from"./p-f4aadb3b.js";import{e as c,h as o,k as r,l as d,c as p,m as b,n as g,o as y}from"./p-d572627c.js";import{a as f,e as m,f as u}from"./p-80cb7c73.js";import{s as w}from"./p-51c6e6fe.js";import{d as v,a as _}from"./p-ff9e28d1.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-dc9d4be3.js";import"./p-7530a02f.js";import"./p-d0d020a5.js";import"./p-9bb44f57.js";const S=class{constructor(e){i(this,e),this.selectionSetChange=t(this,"selectionSetChange",7),this.bufferColor=[227,139,79,.8],this.bufferOutlineColor=[255,255,255],this.customLabelEnabled=void 0,this.enabledLayerIds=[],this.enableLayerFeatures=!0,this.enableLayerFeaturesOnLoad=!1,this.enableSearchDistance=!0,this.enableSearchDistanceOnLoad=!1,this.enableSketchTools=!0,this.defaultBufferDistance=void 0,this.defaultBufferUnit=void 0,this.geometries=[],this.isUpdate=!1,this.layerViews=[],this.locale=void 0,this.mapView=void 0,this.noResultText=void 0,this.searchConfiguration=void 0,this.selectionSet=void 0,this.selectionLayerIds=[],this.selectLayerView=void 0,this.sketchLineSymbol=void 0,this.sketchPointSymbol=void 0,this.sketchPolygonSymbol=void 0,this._numSelected=0,this._searchDistanceEnabled=!1,this._searchTerm=void 0,this._selectionLoading=!1,this._translations=void 0,this._useLayerFeaturesEnabled=!1}get el(){return e(this)}_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(i,t){if(i!==t){const t=0===i.length;if(await this._clearResults(t,t),i.length>0)return this._highlightWithOIDsOrGeoms()}}async mapViewWatchHandler(i,t){i&&i!==t&&await this._init()}async watchSearchConfigurationHandler(i,t){JSON.stringify(i)!==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(i){this.searchConfiguration=i.detail}async distanceChanged(i){await this._distanceChanged(i.detail)}async unitChanged(i){i.detail.newValue!==i.detail.oldValue&&(this._unit=i.detail.newValue,await this._updateLabel())}async componentWillLoad(){await this._getTranslations(),await this._initModules()}async componentDidLoad(){await this._init()}render(){const i=this.enableSketchTools?"":"display-none",t=this.enableSketchTools?"padding-top-1":"";return s(a,{key:"62c70f52dbf364c71048b6de11477735fa3eddc4"},this._getMapLayerPicker(),s("div",{key:"f749a152c0821969177ca6bc83b3e75bac232f98",class:"border-bottom"}),s("div",{key:"e5f564bd4c01dd3648891f74581f3826ce59a06c",class:"padding-top-sides-1"},s("div",{key:"0f2a402284088431d0cc956cf17cd9420080a540",class:"search-widget",ref:i=>{this._searchElement=i}}),s("div",{key:"d3f9352d3a6ff51ecbda166ea2dd9ae49bdec443",class:t},s("map-draw-tools",{key:"00fdebdc3d430965aaa9d5f28b5a2f1d50afdeb8",active:!0,class:i,editGraphicsEnabled:!this._useLayerFeaturesEnabled,graphics:this._graphics,mapView:this.mapView,onSketchGraphicsChange:i=>{this._sketchGraphicsChanged(i)},pointSymbol:this.sketchPointSymbol,polygonSymbol:this.sketchPolygonSymbol,polylineSymbol:this.sketchLineSymbol,ref:i=>{this._drawTools=i}})),this.enableSearchDistance?this._getBufferOptions():void 0,this.enableLayerFeatures?this._getUseLayerFeaturesOptions():void 0,this._getNumSelected()),s("div",{key:"67ecd2ef8f3cd8819fc57785e2b84994c8e71547",class:"border-bottom"}),this._getNameInput())}_getBufferOptions(){this.enableSearchDistanceOnLoad&&(this._searchDistanceEnabled=!0,this.enableSearchDistanceOnLoad=!1);const i=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:i},s("buffer-tools",{disabled:!this._searchDistanceEnabled,distance:t,geometries:this.geometries,onBufferComplete:i=>{this._bufferComplete(i)},ref:i=>this._bufferTools=i,unit:this.selectionSet?.unit||this.defaultBufferUnit})))}_getUseLayerFeaturesOptions(){this.enableLayerFeaturesOnLoad&&(this._useLayerFeaturesEnabled=!0,this.enableLayerFeaturesOnLoad=!1);const i=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:i+" padding-top-1"},s("map-layer-picker",{enabledLayerIds:this.selectionLayerIds,mapView:this.mapView,onLayerSelectionChange:i=>{this._layerSelectionChange(i)},selectedIds:this.layerViews.map((i=>i.layer.id)),showTables:!1})))}_getNumSelected(){const i=h(this.el),t=i&&"en"===i?`${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:i=>{this._labelName=i},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,mapView:this.mapView,onLayerSelectionChange:i=>{this._inputLayerSelectionChange(i)},selectedIds:this.selectLayerView?[this.selectLayerView.layer.id]:this.selectionSet?[this.selectionSet.layerView.layer.id]:[],showTables:!1})))}async _initModules(){const[i,t,e,s,a,h]=await l(["esri/request","esri/layers/GraphicsLayer","esri/Graphic","esri/widgets/Search","esri/geometry/geometryEngine","esri/layers/FeatureLayer"]);this._esriRequest=i,this.GraphicsLayer=t,this.Graphic=e,this.Search=s,this._geometryEngine=a,this.FeatureLayer=h}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((i=>new this.Graphic({geometry:i,symbol:"point"===i.type?this.sketchPointSymbol:"polyline"===i.type?this.sketchLineSymbol:this.sketchPolygonSymbol}))),this._selectionLabel=this.selectionSet?.label,this._useLayerFeaturesEnabled||await(this._drawTools?.updateGraphics()),await c(this.selectionSet.selectedIds,this.selectionSet.layerView,this.mapView,!1))}async _initSearchWidget(){if(this.mapView&&this._searchElement){const i=this._getSearchConfig(this.searchConfiguration,this.mapView),t={view:this.mapView,container:this._searchElement,searchTerm:this._searchTerm,...i};this._searchWidget=new this.Search(t),this._searchWidget.popupEnabled=!1,this._searchWidget.resultGraphicEnabled=!1,this._searchWidget.on("search-clear",(()=>{const i=this._searchClearLabel();this._clearResults(!1,i)})),this._searchWidget.on("select-result",(i=>{this._selectResult(i.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(i){if(i){this._searchResult=i;const t=i.feature,e=t?.layer,s=this.selectLayerView.layer,a=t?.getObjectId();let h,l;e.sourceJSON?.isView&&(h=await this._getViewSourceUrl(e.url)),s.sourceJSON?.isView&&(l=await this._getViewSourceUrl(s.url));const n=e?.url?.toLowerCase(),c=h?.toLowerCase(),o=s?.url?.toLowerCase(),r=l?.toLowerCase(),d=n&&o&&(n===o||n===r||c===o||c===r)&&!isNaN(a),p=d?[a]:void 0;this._workflowType=f.SEARCH,this._updateLabel();const b=[i.feature];this._updateSelection(b,d,p),this._drawTools.graphics=b,this._searchWidget.resultGraphic.visible=!1}else{const i=this._searchClearLabel();this._clearResults(!1,i)}}async _getViewSourceUrl(i){let t="";const e=`${i}/sources?f=json`;try{const i=await this._esriRequest(e,{query:{f:"json"}});1===i?.data?.services?.length&&(t=i.data.services[0].url)}catch(i){console.log(i)}return t}_searchClearLabel(){return this._searchResult?.name&&this._labelName.value.indexOf(this._searchResult.name)>-1}_getSearchConfig(i,t){const e=i?.sources;return e?.length>0?(i={...i,includeDefaultSources:!1},e.forEach((i=>{if(i.hasOwnProperty("layer")){const e=i,s=e.layer?.id,a=s?t.map.findLayerById(s):null,h=e?.layer?.url;a?e.layer=a:h&&(e.layer=new this.FeatureLayer(h))}})),e?.forEach((i=>{if(i.hasOwnProperty("locator")){const t=i;"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}}))):i={...i,includeDefaultSources:!0},i}_initGraphicsLayer(){const i=this._translations.bufferLayer;if(this.mapView){const t=this.mapView.map.layers.findIndex((t=>t.title===i));if(t>-1)this._bufferGraphicsLayer=this.mapView.map.layers.getItemAt(t);else{this._bufferGraphicsLayer=new this.GraphicsLayer({title:i,listMode:"hide"}),w.managedLayers[i]="buffer";const t=this.mapView.map.layers.findIndex((i=>i.title===this._translations.sketchLayer));t>-1?this.mapView.map.layers.add(this._bufferGraphicsLayer,t):this.mapView.map.layers.add(this._bufferGraphicsLayer)}}}async _sketchGraphicsChanged(i,t=!1){const e=i.detail.graphics;if(e.length>0&&e[0])if(t||(this._sketchGraphic=e[0]),this._workflowType=this._useLayerFeaturesEnabled?f.SELECT:f.SKETCH,this._workflowType===f.SKETCH&&await this._drawTools.updateGraphics(),await this._updateLabel(),this._clearSearchWidget(),this._useLayerFeaturesEnabled&&!t){const i=Array.isArray(e)?e.map((i=>i.geometry)):this.geometries;await this._selectLayerFeatures(i[0])}else{const t=e.reduce(((i,t)=>(t?.layer?.objectIdField?i.push(t.attributes[t.layer.objectIdField]):t.getObjectId&&i.push(t.getObjectId()),i)),[]),s=i.detail.useOIDs&&t.length>0;this._updateSelection(e,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(i){w.removeHandles(),i.length>0&&w.highlightHandles.push(await o(i,this.selectLayerView,this.mapView)),this._numSelected=i.length,this.selectionSetChange.emit(i.length)}async _selectFeatures(i){this._selectionLoading=!0,this._selectedIds=await r(i,this.selectLayerView.layer),this._selectionLoading=!1,this._drawTools.graphics=this._graphics,await this._highlightFeatures(this._selectedIds)}async _bufferComplete(i){this._bufferGeometry=Array.isArray(i.detail)?i.detail[0]:i.detail;let t=this._bufferTools.distance,e=0;if(this._bufferGeometry){const i=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(i),await this._selectFeatures([this._bufferGeometry]),await this.mapView.goTo(i.geometry.extent),e=t,t=0}else this._bufferGraphicsLayer&&this._bufferGraphicsLayer.removeAll(),await this._highlightWithOIDsOrGeoms();await this._distanceChanged({oldValue:t,newValue:e})}_geomQuery(i){const t=d(i,this._geometryEngine);return this._selectFeatures(t)}async _clearResults(i=!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(),i&&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(i,t,e){this._selectedIds=t&&e?e:this._selectedIds,this._skipGeomOIDs=t?e:void 0,this.geometries=Array.isArray(i)?i.map((i=>i.geometry)):this.geometries,this._graphics=i}async _updateLabel(){if(this.enableSearchDistance){const i=this._selectionLabel.indexOf(this._translations.sketch)>-1,t=this._selectionLabel.indexOf(this._translations.select)>-1,e=this._selectionLabel.indexOf(this._searchResult?.name)>-1,s=this._workflowType===f.SEARCH?this._searchResult?.name:this._workflowType===f.SELECT?this._translations.select:this._translations.sketch,a=this._unit?this._unit:this._bufferTools.unit,h=await this._bufferTools.getTranslatedUnit(a),l=isNaN(this._distance)?this._bufferTools.distance:this._distance;this._selectionLabel=i||t||e||!this._selectionLabel?`${s} ${l} ${h}`:this._selectionLabel,this._labelName.value=this._selectionLabel}}async _layerSelectionChange(i){if(Array.isArray(i.detail)&&i.detail.length>0){const t=i.detail.map((i=>p(this.mapView,i)));return Promise.all(t).then((i=>{this.layerViews=i,this._featuresCollection={},this._sketchGraphic&&this._sketchGraphicsChanged({detail:{graphics:[this._sketchGraphic],useOIDs:!1}})}))}}async _inputLayerSelectionChange(i){const t=i?.detail?.length>0?i.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(i){i.newValue!==i.oldValue&&(this._distance=i.newValue,await this._updateLabel())}async _selectLayerFeatures(i){this._selectionLoading=!0;const t=this.layerViews.map((t=>(this._featuresCollection[t.layer.id]=[],b(0,t.layer,i,this._featuresCollection))));return Promise.all(t).then((async i=>{this._selectionLoading=!1;let t=[];i.forEach((i=>{Object.keys(i).forEach((e=>{t=t.concat(i[e])}))}));let e=!1;t.forEach((i=>{const t=i.geometry;i.symbol="point"===t.type?this.sketchPointSymbol:"polyline"===t.type?this.sketchLineSymbol:"polygon"===t.type?this.sketchPolygonSymbol:void 0,e=i?.layer?.hasOwnProperty("objectIdField")||i.hasOwnProperty("getObjectId")}));const s=this.layerViews[0].layer,a=this.selectLayerView.layer,h=e&&s.url===a.url&&a.layerId===s.layerId;await this._sketchGraphicsChanged({detail:{graphics:t,useOIDs:h}},!0)}))}_useLayerFeaturesEnabledChanged(){this._useLayerFeaturesEnabled=!this._useLayerFeaturesEnabled,this._sketchGraphic&&this._sketchGraphicsChanged({detail:{graphics:[this._sketchGraphic],useOIDs:!1}})}async _getTranslations(){const i=await n(this.el);this._translations=i[0]}static get watchers(){return{geometries:["watchGeometriesHandler"],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){i(this,t),this.defaultNumLabelsPerPage=void 0,this.disabled=!1,this._translations=void 0}get el(){return e(this)}_labelInfoElement;_intl;async downloadCSV(i,t,e,s=!0){return v(i,t,!0,e,s)}async downloadPDF(i,t,e=!1,s="",a=""){return _(i,t,this._labelInfoElement.selectedOption?.value,e,s,a)}async componentWillLoad(){await this._getTranslations(),await this._initModules()}render(){return s(a,{key:"3d3fa11ecc4cf7a49c4b3831a6c4c19abd6c9ed9"},s("calcite-select",{key:"74e76d8854fd582d2ed214c1b8f52c5744be8167",disabled:this.disabled,label:"",ref:i=>{this._labelInfoElement=i}}))}componentDidLoad(){this._renderOptions()}async _initModules(){const[i]=await l(["esri/intl"]);this._intl=i}_getLabelSizeText(i){const t="‎"+i.descriptionPDF.labelWidthDisplay+" x "+i.descriptionPDF.labelHeightDisplay+"‏";return this._translations.pdfLabel.replace("{{n}}",i.descriptionPDF.labelsPerPageDisplay).replace("{{labelSize}}",t)}async _getTranslations(){const i=await n(this.el);this._translations=i[0]}_renderOptions(){(L.default||L).sort(((i,t)=>{const e=parseInt(i.descriptionPDF.labelsPerPageDisplay,10),s=parseInt(t.descriptionPDF.labelsPerPageDisplay,10);return e<s?-1:e>s?1:0})).forEach(((i,t)=>{const e=document.createElement("calcite-option");e.value=i,e.innerHTML=this._getLabelSizeText(i),this._labelInfoElement.appendChild(e),(this.defaultNumLabelsPerPage?parseInt(i.descriptionPDF.labelsPerPageDisplay,10)===this.defaultNumLabelsPerPage:0===t)&&(e.selected=!0,this._labelInfoElement.selectedOption=e)}))}};k.style=":host{display:block}";const P=class{constructor(e){i(this,e),this.selectionLoadingChange=t(this,"selectionLoadingChange",7),this.selectionSetsChanged=t(this,"selectionSetsChanged",7),this.addresseeLayer=void 0,this.enabledLayerIds=[],this.locale=void 0,this.mapView=void 0,this.selectionSets=[],this.sketchLineSymbol=void 0,this.sketchPointSymbol=void 0,this.sketchPolygonSymbol=void 0,this._translations=void 0,this._selectionMode=m.ADD,this._refineLayer=void 0}get el(){return e(this)}_addEnabled=!0;_drawTools;_refineSets=[];_enabledLayerIds=[];_layerPicker;_featuresCollection={};_refineSelectionSet;selectionLoadingChange;selectionSetsChanged;async componentWillLoad(){await this._getTranslations(),this._enabledLayerIds=this._getEnabledLayerIds(),await this._setRefineSet(this._enabledLayerIds[0])}render(){return s(a,{key:"b7322ad26466e7c710b08b1cd10edf3e82d18603"},s("div",{key:"05289c139685611149306ade3b9217c374bf54e7",class:(this._enabledLayerIds.length>1?"display-block":"display-none")+" padding-top-sides-1"},s("div",{key:"a24e1b1ffb921bb493fb4c0e06b455e564077ad2",class:"display-flex"},s("calcite-label",{key:"a6e25d7f0ad1a3aab589bd4731a1fbea87b08b5b",class:"font-bold width-full label-margin-0"},s("div",{key:"d1850cec01ff43a81dfe5d71dc0b88f4fb4de147",class:"display-flex"},this._translations.inputLayer,s("calcite-icon",{key:"ed94bff762eb431bef9207c1db6b9dd5f56d7132",class:"padding-start-1-2 icon",flipRtl:!("he"===this.locale?.toLowerCase()),icon:"question",id:"refine-input-layer",scale:"s"})),s("map-layer-picker",{key:"5da6c655606a2b1ad4f723c13d0b2c5a50464029",enabledLayerIds:this._enabledLayerIds,mapView:this.mapView,onLayerSelectionChange:i=>{this._layerSelectionChange(i)},ref:i=>{this._layerPicker=i},selectedIds:[this._refineLayer.layer.id],showTables:!1})),s("calcite-popover",{key:"3bfe937cd5d2c8cc9a2e1b5628a86bc44b529963",closable:!0,label:"",referenceElement:"refine-input-layer"},s("span",{key:"cc46053c7494631c07521857e90ae83dc3f440cc",class:"tooltip-message"},this._translations.inputLayerTip)))),s("div",{key:"4ceced950b73cc06d28cac4f76d52126249bdbbd",class:"padding-1"},s("div",{key:"5084d664578acd35c550c57d8c7a27cf97f06332",class:"padding-bottom-1"},s("calcite-segmented-control",{key:"965f42a4b3b3c19401681be1f86ab41dcc58a24a",class:"w-100",width:"full"},s("calcite-segmented-control-item",{key:"dad9b9c04c8fcdda7d5cad7c044fb592b6f740bf",checked:this._addEnabled,class:"w-50 word-wrap-anywhere",onClick:()=>this._setSelectionMode(m.ADD),value:m.ADD},s("span",{key:"0cf895d959f14966736b22d4652f406c75af5c0e",class:"font-weight-500"},this._translations.add)),s("calcite-segmented-control-item",{key:"6f0c8158159215d5a0929deb62c97db5058545a3",checked:!this._addEnabled,class:"w-50 word-wrap-anywhere",onClick:()=>this._setSelectionMode(m.REMOVE),value:m.REMOVE},s("span",{key:"77c66ccd25105c2be67178303d0652a90fa97e35",class:"font-weight-500"},this._translations.remove)))),s("div",{key:"0e409d21bda555363c9a0e870cba3e2f9556bcbb"},s("map-draw-tools",{key:"d84888210ce4c31442a523dc5976fee6bd246b9c",active:!0,drawMode:u.REFINE,mapView:this.mapView,onDrawRedo:()=>this._redo(),onDrawUndo:()=>this._undo(),onSketchGraphicsChange:i=>this._sketchGraphicsChanged(i),pointSymbol:this.sketchPointSymbol,polygonSymbol:this.sketchPolygonSymbol,polylineSymbol:this.sketchLineSymbol,redoEnabled:this._refineSelectionSet?.redoStack.length>0,ref:i=>{this._drawTools=i},undoEnabled:this._refineSelectionSet?.undoStack.length>0})),s("br",{key:"b66849ca294e717352e34ac647f69bef36ba9755"}),s("calcite-list",{key:"8e13006094c5b9d5d63d467d5938e95d00e42ded",class:"list-border"},this._getRefineSelectionSetList())))}_layerSelectionChange(i){this._setRefineSet(i.detail[0])}_setSelectionMode(i){this._selectionMode=i}_sketchGraphicsChanged(i){const t=i.detail?.graphics[0].geometry;this._selectFeatures(t)}_getEnabledLayerIds(){return this.selectionSets.reduce(((i,t)=>{const e=t?.layerView?.layer.id;return e&&i.indexOf(e)<0?i.push(e):t.workflowType===f.REFINE&&Object.keys(t.refineInfos).forEach((t=>{i.indexOf(t)<0&&i.push(t)})),i}),[])}async _setRefineSet(i){this.selectionSets.some((t=>{if(t.workflowType===f.REFINE)return this._refineSelectionSet=t,Object.keys(t.refineInfos).indexOf(i)>-1}))||await this._initRefineSet(i,this._refineSelectionSet),this._refineLayer=this._refineSelectionSet.refineInfos[i].layerView}async _initRefineSet(i,t){const e={};e[i]={addIds:[],removeIds:[],layerView:await p(this.mapView,i)},t?t.refineInfos={...t.refineInfos,...e}:(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:f.REFINE,searchDistanceEnabled:!1,useLayerFeaturesEnabled:!1,refineInfos:e,redoStack:[],undoStack:[],sketchGraphic:void 0},this.selectionSets.push(this._refineSelectionSet))}_undo(){const i=this._refineSelectionSet.undoStack.pop();this._updateIds(i.ids,i.mode===m.ADD?m.REMOVE:m.ADD,this._refineSelectionSet.redoStack,i.layerView)}_redo(){const i=this._refineSelectionSet.redoStack.pop();this._updateIds(i.ids,i.mode===m.ADD?m.REMOVE:m.ADD,this._refineSelectionSet.undoStack,i.layerView)}_getRefineSelectionSetList(){const i=this._getTotal(this.selectionSets);let t;this.selectionSets.some((i=>{if(i.workflowType===f.REFINE)return t=i,!0}));let e=0,a=0;return Object.keys(t.refineInfos).forEach((i=>{e+=t.refineInfos[i].addIds.length,a+=t.refineInfos[i].removeIds.length})),[s("calcite-list-item",{label:this._translations.featuresAdded.replace("{{n}}",e.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}}",i.toString()),"non-interactive":!0})]}_getTotal(i){const t=g(i);return Object.keys(t).reduce(((i,e)=>i+t[e].ids.length),0)}async _getTranslations(){const i=await n(this.el);this._translations=i[0]}async _selectFeatures(i){this.selectionLoadingChange.emit(!0),this._featuresCollection[this._refineLayer?.layer.id]=[];const t=await b(0,this._refineLayer?.layer,i,this._featuresCollection);this.selectionLoadingChange.emit(!1);let e=[];Object.keys(t).forEach((i=>{i===this._refineLayer?.layer.id&&(e=e.concat(t[i]))}));const s=Array.isArray(e)?e.map((i=>i.attributes[i?.layer?.objectIdField])):[];await this._updateIds(s,this._selectionMode,this._refineSelectionSet.undoStack,this._refineLayer),this._drawTools.clear()}async _highlightFeatures(){this._clearHighlight(),w.highlightHandles=await y(this.selectionSets)}_clearHighlight(){w.removeHandles()}async _updateIds(i,t,e,s){let a=!1;const h=this._refineSelectionSet.refineInfos,l=s.layer.id,n={};n[l]={addIds:[],removeIds:[],layerView:s};const c=Object.keys(h).indexOf(l)>-1?h[l]:n[l];if(t===m.ADD)c.addIds=[...new Set([...i,...c.addIds])],c.addIds.length>0&&e.push({ids:i,mode:t,layerView:s}),c.removeIds.length>0&&(c.removeIds=c.removeIds.filter((t=>i.indexOf(t)<0)));else{const h=this.selectionSets.reduce(((t,e)=>(i.forEach((i=>{e.workflowType!==f.REFINE?e.selectedIds.indexOf(i)>-1&&t.push(i):Object.keys(e.refineInfos).some((a=>{const h=e.refineInfos[a];if(h.layerView.layer.id===s.layer.id&&h.addIds.indexOf(i)>-1)return t.push(i),!0}))})),t)),[]);c.removeIds=[...new Set([...h,...c.removeIds])],c.addIds=c.addIds.filter((i=>h.indexOf(i)<0)),c.removeIds.length>0&&e.push({ids:h,mode:t,layerView:s}),this.selectionSets=this.selectionSets.reduce(((i,t)=>(t.workflowType!==f.REFINE&&t.layerView.layer.id===s.layer.id?(t.selectedIds=t.selectedIds.filter((i=>c.removeIds.indexOf(i)<0)),t.selectedIds.length>0?i.push(t):a=!0):i.push(t),i)),[])}this._refineSelectionSet.refineInfos[l]=c,this.selectionSets=[...this.selectionSets],a&&this.selectionSetsChanged.emit(this.selectionSets),await this._highlightFeatures()}};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}
|
@@ -3,4 +3,4 @@
|
|
3
3
|
* Licensed under the Apache License, Version 2.0
|
4
4
|
* http://www.apache.org/licenses/LICENSE-2.0
|
5
5
|
*/
|
6
|
-
import{r as a,c as e,g as t,h as i,H as c}from"./p-4e6eb06e.js";import{g as o}from"./p-f4aadb3b.js";import{E as n}from"./p-80cb7c73.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";const r=class{constructor(t){a(this,t),this.layoutChanged=e(this,"layoutChanged",7),this._translations=void 0}get el(){return t(this)}_layoutMode=n.GRID;layoutChanged;async componentWillLoad(){await this._getTranslations()}render(){return i(c,{key:"
|
6
|
+
import{r as a,c as e,g as t,h as i,H as c}from"./p-4e6eb06e.js";import{g as o}from"./p-f4aadb3b.js";import{E as n}from"./p-80cb7c73.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";const r=class{constructor(t){a(this,t),this.layoutChanged=e(this,"layoutChanged",7),this._translations=void 0}get el(){return t(this)}_layoutMode=n.GRID;layoutChanged;async componentWillLoad(){await this._getTranslations()}render(){return i(c,{key:"030b3a829da8eceb1ed2588ec9d0cf56e6c3b801"},i("div",{key:"c883b792dae7fd3118d50ca19529ad215812636a",class:"display-flex"},i("div",{key:"24a8dacb438879ad29ad216d904c0c12229937c8",class:"display-flex action-center"},i("calcite-icon",{key:"d8ab7b953f906c807a5a3b8f6a38736e5da7308e",class:"icon icon-color",icon:"information",id:"app-information-icon",scale:"s"}),i("calcite-popover",{key:"f43e72d3edbb29dadd4d7bf16e0f2028f16fa515",closable:!0,label:"",referenceElement:"app-information-icon"},i("span",{key:"0059d393750540cbcfe0051a9440447c261ec99f",class:"tooltip-message"},this._translations.appInfo))),i("div",{key:"ea6e944271a0538cc6c8558c08c9940f9a84a6bf",class:"header-text"},this._translations.layout),this._getAction("grid-background",n.GRID,this._translations.grid),this._getAction("vertical-background",n.VERTICAL,this._translations.vertical),this._getAction("horizontal-background",n.HORIZONTAL,this._translations.horizontal)))}_getAction(a,e,t){return i("div",null,i("calcite-action",{alignment:"center",appearance:"transparent",compact:!1,id:a,indicator:e===this._layoutMode,onClick:()=>{this._setLayoutMode(e)},text:""},i("div",{class:a+" img-background"})),i("calcite-tooltip",{label:"",placement:"bottom","reference-element":a},i("span",null,t)))}_setLayoutMode(a){this._layoutMode=a,this.layoutChanged.emit(this._layoutMode)}async _getTranslations(){const a=await o(this.el);this._translations=a[0]}};r.style=":host{display:block}.action-center{-webkit-box-align:center;-webkit-align-items:center;-ms-grid-row-align:center;align-items:center;align-content:center;justify-content:center}.display-flex{display:flex}.icon-color{--calcite-color-icon-color:var(--calcite-color-brand)}.icon{cursor:pointer}.tooltip-message{padding:5px 8px;font-weight:var(--calcite-font-weight-normal);color:var(--calcite-color-text-2)}.header-text{font-size:var(--calcite-font-size-0);font-weight:var(--calcite-font-weight-medium);padding-inline:0.75rem;padding-block:0.875rem;line-height:1.25rem}.img-background{background-repeat:no-repeat;background-size:100% 100%;width:38px;height:26px}.grid-background{background-image:url('../../assets/data/images/grid.png')}.horizontal-background{background-image:url('../../assets/data/images/horizontal.png')}.vertical-background{background-image:url('../../assets/data/images/vertical.png')}";export{r as layout_manager}
|