@esri/solutions-components 0.10.34 → 0.10.35
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 +6 -6
- package/dist/cjs/buffer-tools_3.cjs.entry.js +1 -1
- package/dist/cjs/calcite-alert_5.cjs.entry.js +7 -5
- 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 +20 -9
- package/dist/cjs/crowdsource-manager.cjs.entry.js +3 -2
- package/dist/cjs/crowdsource-reporter.cjs.entry.js +24 -21
- 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 +4 -4
- package/dist/cjs/features-flow-item.cjs.entry.js +1 -1
- 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 +3 -3
- package/dist/cjs/pci-calculator.cjs.entry.js +1 -1
- package/dist/cjs/public-notification.cjs.entry.js +1 -1
- 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 +2 -1
- 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 +1 -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/components/card-manager2.js +40 -34
- package/dist/components/create-feature2.js +4 -2
- package/dist/components/crowdsource-manager.js +101 -94
- 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/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 +1 -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 +6 -6
- package/dist/esm/buffer-tools_3.entry.js +1 -1
- package/dist/esm/calcite-alert_5.entry.js +7 -5
- 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 +20 -9
- package/dist/esm/crowdsource-manager.entry.js +3 -2
- package/dist/esm/crowdsource-reporter.entry.js +24 -21
- 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 +4 -4
- package/dist/esm/features-flow-item.entry.js +1 -1
- 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 +3 -3
- package/dist/esm/pci-calculator.entry.js +1 -1
- package/dist/esm/public-notification.entry.js +1 -1
- 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-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-a8525233.entry.js → p-588adf13.entry.js} +1 -1
- package/dist/solutions-components/{p-5fc0e134.entry.js → p-59ccd27c.entry.js} +1 -1
- package/dist/solutions-components/p-5eb9a413.entry.js +6 -0
- package/dist/solutions-components/{p-42f75c8f.entry.js → p-6502d0f8.entry.js} +1 -1
- package/dist/solutions-components/p-70c0050c.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-4f5913f3.entry.js → p-89046451.entry.js} +1 -1
- package/dist/solutions-components/p-938bc915.entry.js +6 -0
- 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-dd0bd439.entry.js → p-b4c49411.entry.js} +2 -2
- package/dist/solutions-components/p-b86b2664.entry.js +6 -0
- package/dist/solutions-components/{p-ddc1218d.entry.js → p-be4c7ffd.entry.js} +1 -1
- package/dist/solutions-components/{p-ffa9a117.entry.js → p-cb3199f9.entry.js} +1 -1
- package/dist/solutions-components/{p-a07322cc.entry.js → p-df7de4b7.entry.js} +1 -1
- package/dist/solutions-components/{p-1f072e2c.entry.js → p-eadff42b.entry.js} +1 -1
- package/dist/solutions-components/{p-8a411917.entry.js → p-ecf642c2.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/solutions-components.esm.js +1 -1
- 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 +1 -1
- 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-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
@@ -503,7 +503,7 @@ export declare class CrowdsourceReporter {
|
|
503
503
|
* On submit report navigate to the layer list home page and refresh the layer list
|
504
504
|
* @protected
|
505
505
|
*/
|
506
|
-
protected onReportSubmitted(): void
|
506
|
+
protected onReportSubmitted(): Promise<void>;
|
507
507
|
/**
|
508
508
|
* On adding the is failed, show the error message
|
509
509
|
* @param evt Event which has comment failed message
|
@@ -553,6 +553,11 @@ export declare class CrowdsourceReporter {
|
|
553
553
|
* @protected
|
554
554
|
*/
|
555
555
|
protected resetFilter(): Promise<void>;
|
556
|
+
/**
|
557
|
+
* On back from filter panel get the filter's init state
|
558
|
+
* @protected
|
559
|
+
*/
|
560
|
+
protected backFromFilterPanel(): Promise<void>;
|
556
561
|
/**
|
557
562
|
* On back from selected panel navigate to the previous panel
|
558
563
|
* @protected
|
@@ -18,6 +18,10 @@ import DeleteButton_T9n from "../../assets/t9n/delete-button/resources.json";
|
|
18
18
|
import { ButtonType, EditType } from "../../utils/interfaces";
|
19
19
|
export declare class DeleteButton {
|
20
20
|
el: HTMLBufferToolsElement;
|
21
|
+
/**
|
22
|
+
* calcite-modal: Use this prop when using the button within a parent like a dropdown that would constrain the modal and that is not desired
|
23
|
+
*/
|
24
|
+
deleteDialog: any;
|
21
25
|
/**
|
22
26
|
* ButtonType (button | action): Support usage as action or button
|
23
27
|
*/
|
@@ -46,10 +50,6 @@ export declare class DeleteButton {
|
|
46
50
|
* boolean: When true the user can delete the current features
|
47
51
|
*/
|
48
52
|
_deleteEndabled: boolean;
|
49
|
-
/**
|
50
|
-
* boolean: When true a loading indicator will be shown in the delete button
|
51
|
-
*/
|
52
|
-
_isDeleting: boolean;
|
53
53
|
/**
|
54
54
|
* boolean: When true the layer supports delete and a button will be returned
|
55
55
|
*/
|
@@ -101,14 +101,6 @@ export declare class DeleteButton {
|
|
101
101
|
* @returns node to confirm or deny the delete operation
|
102
102
|
*/
|
103
103
|
protected _deleteMessage(): VNode;
|
104
|
-
/**
|
105
|
-
* Delete the currently selected features
|
106
|
-
*/
|
107
|
-
protected _deleteFeatures(): Promise<void>;
|
108
|
-
/**
|
109
|
-
* Set the alertOpen member to false when the alert is closed
|
110
|
-
*/
|
111
|
-
protected _deleteClosed(): void;
|
112
104
|
/**
|
113
105
|
* Fetches the component's translations
|
114
106
|
*
|
@@ -0,0 +1,75 @@
|
|
1
|
+
/** @license
|
2
|
+
* Copyright 2024 Esri
|
3
|
+
*
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
+
* you may not use this file except in compliance with the License.
|
6
|
+
* You may obtain a copy of the License at
|
7
|
+
*
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
*
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
+
* See the License for the specific language governing permissions and
|
14
|
+
* limitations under the License.
|
15
|
+
*/
|
16
|
+
import { EventEmitter } from '../../stencil-public-runtime';
|
17
|
+
import DeleteDialog_T9n from "../../assets/t9n/delete-button/resources.json";
|
18
|
+
import { EditType } from "../../utils/interfaces";
|
19
|
+
export declare class DeleteDialog {
|
20
|
+
el: HTMLDeleteDialogElement;
|
21
|
+
/**
|
22
|
+
* number[]: The ids that would be deleted
|
23
|
+
*/
|
24
|
+
ids: any[];
|
25
|
+
/**
|
26
|
+
* esri/views/layers/FeatureLayer: https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-FeatureLayer.html
|
27
|
+
*/
|
28
|
+
layer: __esri.FeatureLayer;
|
29
|
+
/**
|
30
|
+
* boolean: When true the delete dialog will be displayed
|
31
|
+
*/
|
32
|
+
open: boolean;
|
33
|
+
/**
|
34
|
+
* boolean: When true a loading indicator will be shown in the delete button
|
35
|
+
*/
|
36
|
+
_isDeleting: boolean;
|
37
|
+
/**
|
38
|
+
* Contains the translations for this component.
|
39
|
+
* All UI strings should be defined here.
|
40
|
+
*/
|
41
|
+
_translations: typeof DeleteDialog_T9n;
|
42
|
+
/**
|
43
|
+
* Emitted on demand when features have been deleted
|
44
|
+
*/
|
45
|
+
editsComplete: EventEmitter<EditType>;
|
46
|
+
/**
|
47
|
+
* Emitted on demand when features have been deleted
|
48
|
+
*/
|
49
|
+
deleteDialogClose: EventEmitter<void>;
|
50
|
+
/**
|
51
|
+
* StencilJS: Called once just after the component is first connected to the DOM.
|
52
|
+
*
|
53
|
+
* @returns Promise when complete
|
54
|
+
*/
|
55
|
+
componentWillLoad(): Promise<void>;
|
56
|
+
/**
|
57
|
+
* Renders the component.
|
58
|
+
*/
|
59
|
+
render(): any;
|
60
|
+
/**
|
61
|
+
* Delete the currently selected features
|
62
|
+
*/
|
63
|
+
protected _deleteFeatures(): Promise<void>;
|
64
|
+
/**
|
65
|
+
* Set the alertOpen member to false when the alert is closed
|
66
|
+
*/
|
67
|
+
protected _close(): void;
|
68
|
+
/**
|
69
|
+
* Fetches the component's translations
|
70
|
+
*
|
71
|
+
* @returns Promise when complete
|
72
|
+
* @protected
|
73
|
+
*/
|
74
|
+
protected _getTranslations(): Promise<void>;
|
75
|
+
}
|
@@ -136,6 +136,10 @@ export declare class LayerTable {
|
|
136
136
|
* boolean: When true the select all will be displayed in an active state
|
137
137
|
*/
|
138
138
|
_selectAllActive: boolean;
|
139
|
+
/**
|
140
|
+
* boolean: When true the delete dialog will be shown
|
141
|
+
*/
|
142
|
+
_deleteDialogOpen: boolean;
|
139
143
|
/**
|
140
144
|
* boolean: When true the show/hide fields list is forced open
|
141
145
|
*/
|
@@ -443,6 +447,7 @@ export declare class LayerTable {
|
|
443
447
|
* Renders the component.
|
444
448
|
*/
|
445
449
|
render(): any;
|
450
|
+
protected _deleteDialog: any;
|
446
451
|
/**
|
447
452
|
* Called once after the component is loaded
|
448
453
|
*/
|
@@ -603,6 +608,13 @@ export declare class LayerTable {
|
|
603
608
|
* @returns VNode The node representing the DOM element that will contain the action
|
604
609
|
*/
|
605
610
|
protected _getAction(active: boolean, icon: string, indicator: boolean, label: string, func: any, disabled: boolean, loading: boolean, slot?: string): VNode;
|
611
|
+
/**
|
612
|
+
* Show the delete dialog
|
613
|
+
*
|
614
|
+
* @param
|
615
|
+
*
|
616
|
+
*/
|
617
|
+
protected _showDelete(): void;
|
606
618
|
/**
|
607
619
|
* Get an action and tooltip for share
|
608
620
|
*
|
@@ -499,6 +499,10 @@ export namespace Components {
|
|
499
499
|
* ButtonType (button | action): Support usage as action or button
|
500
500
|
*/
|
501
501
|
"buttonType": ButtonType;
|
502
|
+
/**
|
503
|
+
* calcite-modal: Use this prop when using the button within a parent like a dropdown that would constrain the modal and that is not desired
|
504
|
+
*/
|
505
|
+
"deleteDialog": any;
|
502
506
|
/**
|
503
507
|
* boolean: This overrides internal enable/disable logic that is based on checks if the layer supports delete
|
504
508
|
*/
|
@@ -516,6 +520,20 @@ export namespace Components {
|
|
516
520
|
*/
|
517
521
|
"layer": __esri.FeatureLayer;
|
518
522
|
}
|
523
|
+
interface DeleteDialog {
|
524
|
+
/**
|
525
|
+
* number[]: The ids that would be deleted
|
526
|
+
*/
|
527
|
+
"ids": any[];
|
528
|
+
/**
|
529
|
+
* esri/views/layers/FeatureLayer: https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-FeatureLayer.html
|
530
|
+
*/
|
531
|
+
"layer": __esri.FeatureLayer;
|
532
|
+
/**
|
533
|
+
* boolean: When true the delete dialog will be displayed
|
534
|
+
*/
|
535
|
+
"open": boolean;
|
536
|
+
}
|
519
537
|
interface EditCard {
|
520
538
|
/**
|
521
539
|
* When true the geometry of the current feature will be editable
|
@@ -1813,6 +1831,10 @@ export interface DeleteButtonCustomEvent<T> extends CustomEvent<T> {
|
|
1813
1831
|
detail: T;
|
1814
1832
|
target: HTMLDeleteButtonElement;
|
1815
1833
|
}
|
1834
|
+
export interface DeleteDialogCustomEvent<T> extends CustomEvent<T> {
|
1835
|
+
detail: T;
|
1836
|
+
target: HTMLDeleteDialogElement;
|
1837
|
+
}
|
1816
1838
|
export interface EditCardCustomEvent<T> extends CustomEvent<T> {
|
1817
1839
|
detail: T;
|
1818
1840
|
target: HTMLEditCardElement;
|
@@ -2080,6 +2102,24 @@ declare global {
|
|
2080
2102
|
prototype: HTMLDeleteButtonElement;
|
2081
2103
|
new (): HTMLDeleteButtonElement;
|
2082
2104
|
};
|
2105
|
+
interface HTMLDeleteDialogElementEventMap {
|
2106
|
+
"editsComplete": EditType;
|
2107
|
+
"deleteDialogClose": void;
|
2108
|
+
}
|
2109
|
+
interface HTMLDeleteDialogElement extends Components.DeleteDialog, HTMLStencilElement {
|
2110
|
+
addEventListener<K extends keyof HTMLDeleteDialogElementEventMap>(type: K, listener: (this: HTMLDeleteDialogElement, ev: DeleteDialogCustomEvent<HTMLDeleteDialogElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
2111
|
+
addEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
2112
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
2113
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
2114
|
+
removeEventListener<K extends keyof HTMLDeleteDialogElementEventMap>(type: K, listener: (this: HTMLDeleteDialogElement, ev: DeleteDialogCustomEvent<HTMLDeleteDialogElementEventMap[K]>) => any, options?: boolean | EventListenerOptions): void;
|
2115
|
+
removeEventListener<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
2116
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
2117
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
2118
|
+
}
|
2119
|
+
var HTMLDeleteDialogElement: {
|
2120
|
+
prototype: HTMLDeleteDialogElement;
|
2121
|
+
new (): HTMLDeleteDialogElement;
|
2122
|
+
};
|
2083
2123
|
interface HTMLEditCardElementEventMap {
|
2084
2124
|
"closeEdit": void;
|
2085
2125
|
"editsComplete": void;
|
@@ -2614,6 +2654,7 @@ declare global {
|
|
2614
2654
|
"crowdsource-reporter": HTMLCrowdsourceReporterElement;
|
2615
2655
|
"deduct-calculator": HTMLDeductCalculatorElement;
|
2616
2656
|
"delete-button": HTMLDeleteButtonElement;
|
2657
|
+
"delete-dialog": HTMLDeleteDialogElement;
|
2617
2658
|
"edit-card": HTMLEditCardElement;
|
2618
2659
|
"feature-comments": HTMLFeatureCommentsElement;
|
2619
2660
|
"feature-details": HTMLFeatureDetailsElement;
|
@@ -3206,6 +3247,10 @@ declare namespace LocalJSX {
|
|
3206
3247
|
* ButtonType (button | action): Support usage as action or button
|
3207
3248
|
*/
|
3208
3249
|
"buttonType"?: ButtonType;
|
3250
|
+
/**
|
3251
|
+
* calcite-modal: Use this prop when using the button within a parent like a dropdown that would constrain the modal and that is not desired
|
3252
|
+
*/
|
3253
|
+
"deleteDialog"?: any;
|
3209
3254
|
/**
|
3210
3255
|
* boolean: This overrides internal enable/disable logic that is based on checks if the layer supports delete
|
3211
3256
|
*/
|
@@ -3227,6 +3272,28 @@ declare namespace LocalJSX {
|
|
3227
3272
|
*/
|
3228
3273
|
"onEditsComplete"?: (event: DeleteButtonCustomEvent<EditType>) => void;
|
3229
3274
|
}
|
3275
|
+
interface DeleteDialog {
|
3276
|
+
/**
|
3277
|
+
* number[]: The ids that would be deleted
|
3278
|
+
*/
|
3279
|
+
"ids"?: any[];
|
3280
|
+
/**
|
3281
|
+
* esri/views/layers/FeatureLayer: https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-FeatureLayer.html
|
3282
|
+
*/
|
3283
|
+
"layer"?: __esri.FeatureLayer;
|
3284
|
+
/**
|
3285
|
+
* Emitted on demand when features have been deleted
|
3286
|
+
*/
|
3287
|
+
"onDeleteDialogClose"?: (event: DeleteDialogCustomEvent<void>) => void;
|
3288
|
+
/**
|
3289
|
+
* Emitted on demand when features have been deleted
|
3290
|
+
*/
|
3291
|
+
"onEditsComplete"?: (event: DeleteDialogCustomEvent<EditType>) => void;
|
3292
|
+
/**
|
3293
|
+
* boolean: When true the delete dialog will be displayed
|
3294
|
+
*/
|
3295
|
+
"open"?: boolean;
|
3296
|
+
}
|
3230
3297
|
interface EditCard {
|
3231
3298
|
/**
|
3232
3299
|
* When true the geometry of the current feature will be editable
|
@@ -4463,6 +4530,7 @@ declare namespace LocalJSX {
|
|
4463
4530
|
"crowdsource-reporter": CrowdsourceReporter;
|
4464
4531
|
"deduct-calculator": DeductCalculator;
|
4465
4532
|
"delete-button": DeleteButton;
|
4533
|
+
"delete-dialog": DeleteDialog;
|
4466
4534
|
"edit-card": EditCard;
|
4467
4535
|
"feature-comments": FeatureComments;
|
4468
4536
|
"feature-details": FeatureDetails;
|
@@ -4523,6 +4591,7 @@ declare module "@stencil/core" {
|
|
4523
4591
|
"crowdsource-reporter": LocalJSX.CrowdsourceReporter & JSXBase.HTMLAttributes<HTMLCrowdsourceReporterElement>;
|
4524
4592
|
"deduct-calculator": LocalJSX.DeductCalculator & JSXBase.HTMLAttributes<HTMLDeductCalculatorElement>;
|
4525
4593
|
"delete-button": LocalJSX.DeleteButton & JSXBase.HTMLAttributes<HTMLDeleteButtonElement>;
|
4594
|
+
"delete-dialog": LocalJSX.DeleteDialog & JSXBase.HTMLAttributes<HTMLDeleteDialogElement>;
|
4526
4595
|
"edit-card": LocalJSX.EditCard & JSXBase.HTMLAttributes<HTMLEditCardElement>;
|
4527
4596
|
"feature-comments": LocalJSX.FeatureComments & JSXBase.HTMLAttributes<HTMLFeatureCommentsElement>;
|
4528
4597
|
"feature-details": LocalJSX.FeatureDetails & JSXBase.HTMLAttributes<HTMLFeatureDetailsElement>;
|
package/dist/types/preact.d.ts
CHANGED
@@ -581,6 +581,11 @@ declare module "preact/src/jsx" {
|
|
581
581
|
"oneditsComplete"?: (event: CustomEvent<any>) => void;
|
582
582
|
}
|
583
583
|
|
584
|
+
"delete-dialog": Omit<JSX.SolutionsDeleteDialog, "onEditsComplete" | "onDeleteDialogClose"> & JSXInternal.HTMLAttributes<HTMLSolutionsDeleteDialogElement> & {
|
585
|
+
"oneditsComplete"?: (event: CustomEvent<any>) => void;
|
586
|
+
"ondeleteDialogClose"?: (event: CustomEvent<any>) => void;
|
587
|
+
}
|
588
|
+
|
584
589
|
"edit-card": Omit<JSX.SolutionsEditCard, "onCloseEdit" | "onEditsComplete" | "onRefreshGraphics"> & JSXInternal.HTMLAttributes<HTMLSolutionsEditCardElement> & {
|
585
590
|
"oncloseEdit"?: (event: CustomEvent<any>) => void;
|
586
591
|
"oneditsComplete"?: (event: CustomEvent<any>) => void;
|
package/package.json
CHANGED
@@ -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 s,h as a,H as r}from"./p-4e6eb06e.js";const t=class{constructor(s){e(this,s)}get el(){return s(this)}render(){return a(r,{key:"7b405bc7f7cb4204406da1aa0c05dc292508e6cf"},a("slot",{key:"fcaa34cd163995045268fd539a82ad3b102b1046"}))}};t.style=":host{display:block}";export{t as share_item}
|
@@ -1,17 +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 e,h as i,H as o,g as a,F as n}from"./p-4e6eb06e.js";import{c as s,d as l}from"./p-5e25a0b8.js";import{o as r,s as c,f as d,u as h,e as m}from"./p-621ad249.js";import{d as p,a as b,c as f,u}from"./p-4253e9f1.js";import{s as x,a as g,c as v}from"./p-ad9d1221.js";import{c as w}from"./p-ff336351.js";import{o as k}from"./p-c7f8b7f0.js";import{c as y,d as z}from"./p-895e7b9c.js";import{s as C,c as j,d as S,u as M}from"./p-efaa77a0.js";import{g as $,c as L}from"./p-4a291f79.js";import{l as O}from"./p-fa80bc7e.js";import{g as D}from"./p-f4aadb3b.js";import"./p-7d542581.js";import"./p-91371f97.js";import"./p-a02e2069.js";import"./p-4f82eb55.js";import"./p-233f219c.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";
|
7
|
-
/*!
|
8
|
-
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
9
|
-
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
10
|
-
* v2.13.0
|
11
|
-
*/const T="modal",E="header",F="container",H="container--open",B="container--embedded",A="content",I="content--no-footer",_="modal--opening-idle",P="modal--opening-active",W="modal--closing-idle",R="modal--closing-active",q="content",G="back",V="secondary",J="primary";let K=0,N="";O.deprecated("component",{name:"modal",removalVersion:4,suggested:"dialog"});const Q=class{constructor(i){t(this,i),this.calciteModalBeforeClose=e(this,"calciteModalBeforeClose",6),this.calciteModalClose=e(this,"calciteModalClose",6),this.calciteModalBeforeOpen=e(this,"calciteModalBeforeOpen",6),this.calciteModalOpen=e(this,"calciteModalOpen",6),this.ignoreOpenChange=!1,this.mutationObserver=w("mutation",(()=>this.handleMutationObserver())),this.cssVarObserver=w("mutation",(()=>{this.updateSizeCssVars()})),this.openTransitionProp="opacity",this.setTransitionEl=t=>{this.transitionEl=t},this.openEnd=()=>{this.setFocus(),this.el.removeEventListener("calciteModalOpen",this.openEnd)},this.handleCloseClick=()=>{this.open=!1},this.handleOutsideClose=()=>{this.outsideCloseDisabled||(this.open=!1)},this.closeModal=async()=>{if(this.beforeClose)try{await this.beforeClose(this.el)}catch(t){return void requestAnimationFrame((()=>{this.ignoreOpenChange=!0,this.open=!0,this.ignoreOpenChange=!1}))}K--,this.opened=!1,this.removeOverflowHiddenClass()},this.handleMutationObserver=()=>{this.updateFooterVisibility(),this.updateFocusTrapElements()},this.updateFooterVisibility=()=>{this.hasFooter=!!r(this.el,[G,J,V])},this.updateSizeCssVars=()=>{this.cssWidth=getComputedStyle(this.el).getPropertyValue("--calcite-modal-width"),this.cssHeight=getComputedStyle(this.el).getPropertyValue("--calcite-modal-height")},this.contentTopSlotChangeHandler=t=>{this.hasContentTop=c(t)},this.contentBottomSlotChangeHandler=t=>{this.hasContentBottom=c(t)},this.open=!1,this.opened=!1,this.beforeClose=void 0,this.closeButtonDisabled=!1,this.focusTrapDisabled=!1,this.outsideCloseDisabled=!1,this.docked=void 0,this.embedded=!1,this.escapeDisabled=!1,this.scale="m",this.widthScale="m",this.fullscreen=void 0,this.kind=void 0,this.messages=void 0,this.messageOverrides=void 0,this.cssWidth=void 0,this.cssHeight=void 0,this.hasFooter=!0,this.hasContentTop=!1,this.hasContentBottom=!1,this.effectiveLocale=void 0,this.defaultMessages=void 0}handleFocusTrapDisabled(t){this.open&&(t?p(this):b(this))}onMessagesChange(){}async componentWillLoad(){await C(this),x(this),this.open&&this.openModal()}componentDidLoad(){g(this)}connectedCallback(){this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.cssVarObserver?.observe(this.el,{attributeFilter:["style"]}),this.updateSizeCssVars(),this.updateFooterVisibility(),s(this),y(this),j(this),f(this)}disconnectedCallback(){this.removeOverflowHiddenClass(),this.mutationObserver?.disconnect(),this.cssVarObserver?.disconnect(),l(this),p(this),z(this),S(this),this.embedded=!1}render(){return i(o,{key:"f92cd77f4a5ad4a245ca50fe2b2bfcf9966d4ca8","aria-describedby":this.contentId,"aria-labelledby":this.titleId,"aria-modal":"true",role:"dialog"},i("div",{key:"a9d348a67842162f1bc17ec8422c07963aed412d",class:{[F]:!0,[H]:this.opened,[B]:this.embedded}},i("calcite-scrim",{key:"7dc3bc9220fc375522a6d390b633f9573bfa6c67",class:"scrim",onClick:this.handleOutsideClose}),this.renderStyle(),i("div",{key:"40782ba2b6d3f086c884ace3529110e873009504",class:{[T]:!0},ref:this.setTransitionEl},i("div",{key:"ea3a72ab0a0e5abae6e766d0b7b2cfce54667e86",class:E},this.renderCloseButton(),i("header",{key:"abe5c28d11fc6241cd6ac40adef4d94529eb9d5c",class:"title"},i("slot",{key:"3d1d6ed6c0249472a00fba4128a861e6a6eae4dd",name:E}))),this.renderContentTop(),i("div",{key:"0e65dfbd175e490586518d1a4c34b9eb1dde1f01",class:{[A]:!0,[I]:!this.hasFooter},ref:t=>this.modalContent=t},i("slot",{key:"d5f3b08e61e8e47f64fd13bc6eb7f7ed6a07b7c8",name:q})),this.renderContentBottom(),this.renderFooter())))}renderFooter(){return this.hasFooter?i("div",{class:"footer",key:"footer"},i("span",{class:"back"},i("slot",{name:G})),i("span",{class:"secondary"},i("slot",{name:V})),i("span",{class:"primary"},i("slot",{name:J}))):null}renderContentTop(){return i("div",{class:"content-top",hidden:!this.hasContentTop},i("slot",{name:"content-top",onSlotchange:this.contentTopSlotChangeHandler}))}renderContentBottom(){return i("div",{class:"content-bottom",hidden:!this.hasContentBottom},i("slot",{name:"content-bottom",onSlotchange:this.contentBottomSlotChangeHandler}))}renderCloseButton(){return this.closeButtonDisabled?null:i("button",{"aria-label":this.messages.close,class:"close",key:"button",onClick:this.handleCloseClick,ref:t=>this.closeButtonEl=t,title:this.messages.close},i("calcite-icon",{icon:"x",scale:$(this.scale)}))}renderStyle(){if(!this.fullscreen&&(this.cssWidth||this.cssHeight))return i("style",null,`.${F} {\n ${this.docked&&this.cssWidth?"align-items: center !important;":""}\n }\n .${T} {\n block-size: ${this.cssHeight?this.cssHeight:"auto"} !important;\n ${this.cssWidth?`inline-size: ${this.cssWidth} !important;`:""}\n ${this.cssWidth?`max-inline-size: ${this.cssWidth} !important;`:""}\n ${this.docked?"border-radius: var(--calcite-border-radius) !important;":""}\n }\n @media screen and (max-width: ${this.cssWidth}) {\n .${F} {\n ${this.docked?"align-items: flex-end !important;":""}\n }\n .${T} {\n max-block-size: 100% !important;\n inline-size: 100% !important;\n max-inline-size: 100% !important;\n min-inline-size: 100% !important;\n margin: 0 !important;\n ${this.docked?"":"block-size: 100% !important;"}\n ${this.docked?"":"border-radius: 0 !important;"}\n ${this.docked?"border-radius: var(--calcite-border-radius) var(--calcite-border-radius) 0 0 !important;":""}\n }\n }\n `)}effectiveLocaleChange(){M(this,this.effectiveLocale)}handleEscape(t){!this.open||this.escapeDisabled||"Escape"!==t.key||t.defaultPrevented||(this.open=!1,t.preventDefault())}async setFocus(){await v(this),d(this.el)}async updateFocusTrapElements(){u(this)}async scrollContent(t=0,e=0){this.modalContent&&(this.modalContent.scrollTo?this.modalContent.scrollTo({top:t,left:e,behavior:"smooth"}):(this.modalContent.scrollTop=t,this.modalContent.scrollLeft=e))}onBeforeOpen(){this.transitionEl.classList.add(P),this.calciteModalBeforeOpen.emit()}onOpen(){this.transitionEl.classList.remove(_,P),this.calciteModalOpen.emit(),b(this)}onBeforeClose(){this.transitionEl.classList.add(R),this.calciteModalBeforeClose.emit()}onClose(){this.transitionEl.classList.remove(W,R),this.calciteModalClose.emit(),p(this)}toggleModal(t){this.ignoreOpenChange||(t?this.openModal():this.closeModal())}handleOpenedChange(t){this.transitionEl.classList.add(t?_:W),k(this)}async openModal(){await L(this.el),this.el.addEventListener("calciteModalOpen",this.openEnd),this.opened=!0;const t=r(this.el,"header"),e=r(this.el,q);this.titleId=h(t),this.contentId=h(e),this.embedded||(0===K&&(N=document.documentElement.style.overflow),K++,document.documentElement.style.setProperty("overflow","hidden"))}removeOverflowHiddenClass(){document.documentElement.style.setProperty("overflow",N)}static get assetsDirs(){return["assets"]}get el(){return a(this)}static get watchers(){return{focusTrapDisabled:["handleFocusTrapDisabled"],messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"],open:["toggleModal"],opened:["handleOpenedChange"]}}};Q.style=":host{--calcite-modal-scrim-background:rgba(0, 0, 0, 0.85);position:absolute;inset:0px;z-index:var(--calcite-z-index-overlay);display:flex;opacity:0;visibility:hidden !important;transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow), opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88);--calcite-modal-scrim-background-internal:rgba(0, 0, 0, 0.85)}.content-top[hidden],.content-bottom[hidden]{display:none}.container{position:fixed;inset:0px;z-index:var(--calcite-z-index-overlay);display:flex;align-items:center;justify-content:center;overflow-y:hidden;color:var(--calcite-color-text-2);opacity:0;visibility:hidden !important;transition:visibility 0ms linear var(--calcite-internal-animation-timing-slow), opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88)}:host([scale=s]){--calcite-modal-padding-internal:0.75rem;--calcite-modal-padding-large-internal:1rem;--calcite-modal-title-text-internal:var(--calcite-font-size-1);--calcite-modal-content-text-internal:var(--calcite-font-size--1)}:host([scale=m]){--calcite-modal-padding-internal:1rem;--calcite-modal-padding-large-internal:1.25rem;--calcite-modal-title-text-internal:var(--calcite-font-size-2);--calcite-modal-content-text-internal:var(--calcite-font-size-0)}:host([scale=l]){--calcite-modal-padding-internal:1.25rem;--calcite-modal-padding-large-internal:1.5rem;--calcite-modal-title-text-internal:var(--calcite-font-size-3);--calcite-modal-content-text-internal:var(--calcite-font-size-1)}.scrim{--calcite-scrim-background:var(--calcite-modal-scrim-background, var(--calcite-color-transparent-scrim));position:fixed;inset:0px;display:flex;overflow-y:hidden}.modal{pointer-events:none;z-index:var(--calcite-z-index-modal);float:none;margin:1.5rem;box-sizing:border-box;display:flex;inline-size:100%;flex-direction:column;overflow:hidden;border-radius:0.25rem;background-color:var(--calcite-color-foreground-1);opacity:0;--tw-shadow:0 2px 12px -4px rgba(0, 0, 0, 0.2), 0 2px 4px -2px rgba(0, 0, 0, 0.16);--tw-shadow-colored:0 2px 12px -4px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);-webkit-overflow-scrolling:touch;visibility:hidden;transition:transform var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88), visibility 0ms linear var(--calcite-internal-animation-timing-slow), opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88);--calcite-modal-hidden-position:translate3d(0, 20px, 0);--calcite-modal-shown-position:translate3d(0, 0, 0)}.modal--opening-idle{transform:var(--calcite-modal-hidden-position)}.modal--opening-active{transform:var(--calcite-modal-shown-position)}.modal--closing-idle{transform:var(--calcite-modal-shown-position)}.modal--closing-active{transform:var(--calcite-modal-hidden-position)}:host([opened]){opacity:1;visibility:visible !important;transition-delay:0ms}.container--open{opacity:1;visibility:visible !important;transition-delay:0ms}.container--open .modal{pointer-events:auto;visibility:visible;opacity:1;transition:transform var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88), visibility 0ms linear, opacity var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88), max-inline-size var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88), max-block-size var(--calcite-internal-animation-timing-slow) cubic-bezier(0.215, 0.44, 0.42, 0.88);transition-delay:0ms}.header{z-index:var(--calcite-z-index-header);display:flex;min-inline-size:0px;max-inline-size:100%;border-start-start-radius:0.25rem;border-start-end-radius:0.25rem;border-width:0px;border-block-end-width:1px;border-style:solid;border-color:var(--calcite-color-border-3);background-color:var(--calcite-color-foreground-1);flex:0 0 auto}.close{order:2;margin:0px;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-style:none;background-color:transparent;color:var(--calcite-color-text-3);outline-color:transparent;transition:background-color, block-size, border-color, box-shadow, color, inset-block-end, inset-block-start, inset-inline-end, inset-inline-start inset-size, opacity, outline-color, transform var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;padding-block:var(--calcite-modal-padding-internal);padding-inline:var(--calcite-modal-padding-internal);flex:0 0 auto}.close calcite-icon{pointer-events:none;vertical-align:-2px}.close:focus{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-color-brand));outline-offset:calc(\n -2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-offset-invert-focus),\n 1\n )\n )\n )}.close:hover,.close:focus,.close:active{background-color:var(--calcite-color-foreground-2);color:var(--calcite-color-text-1)}.title{order:1;display:flex;min-inline-size:0px;align-items:center;flex:1 1 auto;padding-block:var(--calcite-modal-padding-internal);padding-inline:var(--calcite-modal-padding-large-internal)}slot[name=header]::slotted(*),*::slotted([slot=header]){margin:0px;font-weight:var(--calcite-font-weight-normal);color:var(--calcite-color-text-1);font-size:var(--calcite-modal-title-text-internal)}.content{position:relative;box-sizing:border-box;display:block;block-size:100%;overflow:auto;padding:0px;background-color:var(--calcite-modal-content-background, var(--calcite-color-foreground-1));max-block-size:100%;padding:var(--calcite-modal-content-padding, var(--calcite-modal-padding-internal))}.content-top,.content-bottom{z-index:var(--calcite-z-index-header);display:flex;border-width:0px;border-style:solid;border-color:var(--calcite-color-border-3);background-color:var(--calcite-color-foreground-1);flex:0 0 auto;padding:var(--calcite-modal-padding-internal)}.content-top{min-inline-size:0px;max-inline-size:100%;border-block-end-width:1px}.content-bottom{margin-block-start:auto;box-sizing:border-box;inline-size:100%;justify-content:space-between;border-block-start-width:1px}.content-top:not(.header~.content-top){border-start-start-radius:0.25rem;border-start-end-radius:0.25rem}.content-bottom:not(.content-bottom~.footer),.content--no-footer{border-end-end-radius:0.25rem;border-end-start-radius:0.25rem}slot[name=content]::slotted(*),*::slotted([slot=content]){font-size:var(--calcite-modal-context-text-internal)}.footer{z-index:var(--calcite-z-index-header);margin-block-start:auto;box-sizing:border-box;display:flex;inline-size:100%;justify-content:space-between;border-end-end-radius:0.25rem;border-end-start-radius:0.25rem;border-width:0px;border-block-start-width:1px;border-style:solid;border-color:var(--calcite-color-border-3);background-color:var(--calcite-color-foreground-1);flex:0 0 auto;padding-block:var(--calcite-modal-padding-internal);padding-inline:var(--calcite-modal-padding-large-internal)}.footer--hide-back .back,.footer--hide-secondary .secondary{display:none}.back{display:block;margin-inline-end:auto}.secondary{margin-inline:0.25rem;display:block}slot[name=primary]{display:block}:host([width=small]) .modal{inline-size:auto}:host([width-scale=s]) .modal{max-block-size:100%;max-inline-size:100%;inline-size:var(--calcite-modal-width, 32rem);block-size:var(--calcite-modal-height, auto)}@media screen and (max-width: 35rem){:host([width-scale=s]) .modal{margin:0px;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%}:host([width-scale=s]) .content{flex:1 1 auto;max-block-size:unset}:host([width-scale=s][docked]) .container{align-items:flex-end}}:host([width-scale=m]) .modal{max-block-size:100%;max-inline-size:100%;inline-size:var(--calcite-modal-width, 48rem);block-size:var(--calcite-modal-height, auto)}@media screen and (max-width: 51rem){:host([width-scale=m]) .modal{margin:0px;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%}:host([width-scale=m]) .content{flex:1 1 auto;max-block-size:unset}:host([width-scale=m][docked]) .container{align-items:flex-end}}:host([width-scale=l]) .modal{max-block-size:100%;max-inline-size:100%;inline-size:var(--calcite-modal-width, 94rem);block-size:var(--calcite-modal-height, auto)}@media screen and (max-width: 97rem){:host([width-scale=l]) .modal{margin:0px;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%}:host([width-scale=l]) .content{flex:1 1 auto;max-block-size:unset}:host([width-scale=l][docked]) .container{align-items:flex-end}}:host([fullscreen]) .modal{margin:0px;block-size:100%;max-block-size:100%;inline-size:100%;max-inline-size:100%;border-radius:0px;--calcite-modal-hidden-position:translate3D(0, 20px, 0) scale(0.95);--calcite-modal-shown-position:translate3D(0, 0, 0) scale(1)}:host([fullscreen]) .content{max-block-size:100%;flex:1 1 auto}:host([opened][fullscreen]) .header,:host([opened][fullscreen]) .footer,:host([opened][fullscreen]) .content-top,:host([opened][fullscreen]) .content-bottom{border-radius:0}:host([docked]) .modal{block-size:var(--calcite-modal-height, auto)}:host([docked]) .content{block-size:auto;flex:1 1 auto}:host([kind=brand]) .modal{border-color:var(--calcite-color-brand)}:host([kind=danger]) .modal{border-color:var(--calcite-color-status-danger)}:host([kind=info]) .modal{border-color:var(--calcite-color-status-info)}:host([kind=success]) .modal{border-color:var(--calcite-color-status-success)}:host([kind=warning]) .modal{border-color:var(--calcite-color-status-warning)}:host([kind=brand]) .modal,:host([kind=danger]) .modal,:host([kind=info]) .modal,:host([kind=success]) .modal,:host([kind=warning]) .modal{border-width:0px;border-block-start-width:4px;border-style:solid}:host([kind=brand]) .header,:host([kind=brand]) .content-top,:host([kind=danger]) .header,:host([kind=danger]) .content-top,:host([kind=info]) .header,:host([kind=info]) .content-top,:host([kind=success]) .header,:host([kind=success]) .content-top,:host([kind=warning]) .header,:host([kind=warning]) .content-top{border-radius:0.25rem;border-end-end-radius:0px;border-end-start-radius:0px}@media screen and (max-width: 860px){* slot[name=header]::slotted(content-top),* content-top::slotted([slot=header]){font-size:var(--calcite-font-size-1)}.footer,.content-bottom{position:sticky;inset-block-end:0px}}@media screen and (max-width: 480px){.footer,.content-bottom{flex-direction:column}.back,.secondary{margin:0px;margin-block-end:0.25rem}}.container--embedded{position:absolute;pointer-events:auto}.container--embedded calcite-scrim{position:absolute}:host([hidden]){display:none}[hidden]{display:none}";
|
12
|
-
/*!
|
13
|
-
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
14
|
-
* See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
|
15
|
-
* v2.13.0
|
16
|
-
*/
|
17
|
-
const U="content",X="content--behind",Y="content-bottom",Z="center-content",tt=class{constructor(e){t(this,e),this.handleHeaderSlotChange=t=>{this.hasHeader=!!c(t)},this.handleFooterSlotChange=t=>{this.hasFooter=!!c(t)},this.handleAlertsSlotChange=t=>{this.hasAlerts=!!c(t),m(t)?.map((t=>{"CALCITE-ALERT"===t.tagName&&(t.embedded=!0)}))},this.handleSheetsSlotChange=t=>{this.hasSheets=!!c(t),m(t)?.map((t=>{"CALCITE-SHEET"===t.tagName&&(t.embedded=!0)}))},this.handleModalsSlotChange=t=>{this.hasModals=!!c(t),m(t)?.map((t=>{"CALCITE-MODAL"===t.tagName&&(t.embedded=!0)}))},this.handlePanelTopChange=t=>{this.hasPanelTop=c(t)},this.handlePanelBottomChange=t=>{this.hasPanelBottom=c(t)},this.handleDialogsSlotChange=t=>{this.hasDialogs=!!c(t),m(t)?.map((t=>{"CALCITE-DIALOG"===t.tagName&&(t.embedded=!0)}))},this.contentBehind=!1,this.hasHeader=!1,this.hasFooter=!1,this.hasAlerts=!1,this.hasModals=!1,this.hasDialogs=!1,this.hasSheets=!1,this.hasPanelTop=!1,this.hasPanelBottom=!1,this.hasOnlyPanelBottom=!1,this.panelIsResizing=!1}handleCalciteInternalShellPanelResizeStart(t){this.panelIsResizing=!0,t.stopPropagation()}handleCalciteInternalShellPanelResizeEnd(t){this.panelIsResizing=!1,t.stopPropagation()}updateHasOnlyPanelBottom(){this.hasOnlyPanelBottom=!this.hasPanelTop&&this.hasPanelBottom}connectedCallback(){s(this)}disconnectedCallback(){l(this)}renderHeader(){return i("div",{hidden:!this.hasHeader},i("slot",{key:"header",name:"header",onSlotchange:this.handleHeaderSlotChange}))}renderFooter(){return i("div",{class:"footer",hidden:!this.hasFooter,key:"footer"},i("slot",{name:"footer",onSlotchange:this.handleFooterSlotChange}))}renderAlerts(){return i("div",{hidden:!this.hasAlerts},i("slot",{key:"alerts",name:"alerts",onSlotchange:this.handleAlertsSlotChange}))}renderSheets(){return i("div",{hidden:!this.hasSheets},i("slot",{key:"sheets",name:"sheets",onSlotchange:this.handleSheetsSlotChange}))}renderModals(){return i("div",{hidden:!this.hasModals},i("slot",{key:"modals",name:"modals",onSlotchange:this.handleModalsSlotChange}))}renderDialogs(){return i("div",{hidden:!this.hasDialogs},i("slot",{key:"dialogs",name:"dialogs",onSlotchange:this.handleDialogsSlotChange}))}renderContent(){const{panelIsResizing:t}=this,e=i("slot",{key:"default-slot"}),o=t?i("div",{class:"content--non-interactive"},e):e,a=i("slot",{key:"center-row-slot",name:"center-row"}),n=i("slot",{key:"panel-bottom-slot",name:"panel-bottom",onSlotchange:this.handlePanelBottomChange}),s=i("slot",{key:"panel-top-slot",name:"panel-top",onSlotchange:this.handlePanelTopChange}),l="content-container";return this.contentBehind?[i("div",{class:{[U]:!0,[X]:!0},key:l},o),i("div",{class:{[Z]:!0,[Y]:this.hasOnlyPanelBottom}},s,n,a)]:[i("div",{class:{[U]:!0,[Y]:this.hasOnlyPanelBottom},key:l},s,o,n,a)]}renderMain(){return i("div",{class:"main"},i("slot",{name:"panel-start"}),this.renderContent(),i("slot",{name:"panel-end"}))}renderPositionedSlots(){return i("div",{class:"positioned-slot-wrapper"},this.renderAlerts(),this.renderModals(),this.renderDialogs(),this.renderSheets())}render(){return i(n,{key:"6864b8b95b6edd871ad622b0d49a3f4a42a0a8a8"},this.renderHeader(),this.renderMain(),this.renderFooter(),this.renderPositionedSlots())}get el(){return a(this)}static get watchers(){return{hasPanelTop:["updateHasOnlyPanelBottom"],hasPanelBottom:["updateHasOnlyPanelBottom"]}}};tt.style=":host{box-sizing:border-box;background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);font-size:var(--calcite-font-size--1)}:host *{box-sizing:border-box}:host{position:absolute;inset:0px;display:flex;block-size:100%;inline-size:100%;flex-direction:column;overflow:hidden;--calcite-shell-tip-spacing:26vw}.main{position:relative;display:flex;block-size:100%;inline-size:100%;flex:1 1 auto;flex-direction:row;justify-content:space-between;overflow:hidden}.content{display:flex;block-size:100%;inline-size:100%;flex-direction:column;flex-wrap:nowrap;overflow:auto;justify-content:space-between}.content ::slotted(calcite-shell-center-row),.content ::slotted(calcite-panel),.content ::slotted(calcite-flow){flex:1 1 auto;align-self:stretch;max-block-size:unset}.content--behind{position:absolute;inset:0px;border-width:0px;z-index:calc(var(--calcite-z-index) - 1);display:initial}.content--non-interactive{pointer-events:none;display:flex;block-size:100%;inline-size:100%;flex-direction:column;flex-wrap:nowrap}::slotted(calcite-shell-center-row){inline-size:unset}::slotted(.header .heading){font-size:var(--calcite-font-size--2);line-height:1.375;font-weight:var(--calcite-font-weight-normal)}slot[name=panel-start]::slotted(calcite-shell-panel),slot[name=panel-end]::slotted(calcite-shell-panel){position:relative;z-index:calc(var(--calcite-z-index) + 1)}slot[name=panel-end]::slotted(calcite-shell-panel){margin-inline-start:auto}::slotted(calcite-panel),::slotted(calcite-flow){border-width:1px;border-inline-start-width:0px;border-inline-end-width:0px;border-style:solid;border-color:var(--calcite-color-border-3)}slot[name=center-row]::slotted(calcite-shell-center-row:not([detached])),slot[name=panel-top]::slotted(calcite-shell-center-row:not([detached])),slot[name=panel-bottom]::slotted(calcite-shell-center-row:not([detached])){border-inline-start-width:1px;border-inline-end-width:1px;border-color:var(--calcite-color-border-3)}.center-content{display:flex;flex-direction:column;justify-content:space-between;block-size:100%;inline-size:100%;min-inline-size:0}.content-bottom{justify-content:flex-end}::slotted(calcite-shell-center-row){flex:none;align-self:stretch}::slotted(calcite-tip-manager){position:absolute;z-index:var(--calcite-z-index-toast);box-sizing:border-box}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}::slotted(calcite-tip-manager){animation:in-up var(--calcite-internal-animation-timing-slow) ease-in-out;border-radius:0.25rem;--tw-shadow:0 6px 20px -4px rgba(0, 0, 0, 0.1), 0 4px 12px -2px rgba(0, 0, 0, 0.08);--tw-shadow-colored:0 6px 20px -4px var(--tw-shadow-color), 0 4px 12px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);inset-block-end:0.5rem;inset-inline:var(--calcite-shell-tip-spacing)}slot[name=center-row]::slotted(calcite-shell-center-row),slot[name=panel-bottom]::slotted(calcite-shell-center-row){margin-block-start:auto}slot[name=panel-top]::slotted(calcite-shell-center-row){margin-block-end:auto}.position-wrapper{position:absolute;pointer-events:none;inset:0}:host([hidden]){display:none}[hidden]{display:none}";const et=class{constructor(i){t(this,i),this.editsComplete=e(this,"editsComplete",7),this.buttonType="button",this.disabled=!1,this.icon=void 0,this.ids=[],this.layer=void 0,this._confirmDelete=!1,this._deleteEndabled=!1,this._isDeleting=!1,this._supportsDelete=void 0,this._translations=void 0}get el(){return a(this)}async idsWatchHandler(){this._setDeleteEnabled()}async layerWatchHandler(){this._setDeleteEnabled()}editsComplete;async componentWillLoad(){await this._getTranslations()}render(){return i(o,{key:"23936d6981c9779f5a21951c6667e3cba86e5d82"},"button"===this.buttonType?i("calcite-button",{appearance:"outline",disabled:!this._deleteEndabled,id:"solutions-delete",kind:"danger",onClick:()=>this._delete(),width:"full"},this._translations.deleteCount.replace("{{n}}",this.ids.length.toString())):i("calcite-action",{appearance:"solid",compact:!0,disabled:!this._deleteEndabled,id:this.icon,onClick:()=>this._delete(),scale:"s",text:this._translations.delete},i("calcite-button",{appearance:"transparent",iconStart:this.icon,kind:"danger"},this._translations.delete)),this._deleteMessage(),i("calcite-tooltip",{key:"0078ca79ef0a2195be88d0b508fefc9838af9693",placement:"bottom","reference-element":"button"===this.buttonType?"solutions-delete":this.icon},i("span",{key:"6a2f3c55237c2cb07f17559c9f14edd4b442e004"},this._translations.delete)))}async componentDidLoad(){this._setDeleteEnabled()}_setDeleteEnabled(){this._supportsDelete=this.layer?.editingEnabled&&this.layer?.capabilities?.operations?.supportsDelete,this._deleteEndabled=!this.disabled||this._supportsDelete&&this.ids.length>0}_delete(){this._confirmDelete=!0}_deleteMessage(){const t=1===this.ids.length?this._translations.confirmSingle:this._translations.confirmMultiple;return i("calcite-modal",{"aria-labelledby":"modal-title",class:"delete-modal",kind:"danger",onCalciteModalClose:()=>this._deleteClosed(),open:this._confirmDelete},i("div",{class:"display-flex align-center",id:"modal-title",slot:"header"},this._translations.deleteFeature),i("div",{slot:"content"},t),i("calcite-button",{appearance:"outline",kind:"danger",onClick:()=>this._deleteClosed(),slot:"secondary",width:"full"},this._translations.cancel),i("calcite-button",{kind:"danger",loading:this._isDeleting,onClick:()=>{this._deleteFeatures()},slot:"primary",width:"full"},this._translations.delete))}async _deleteFeatures(){this._isDeleting=!0;const t=this.ids.map((t=>({objectId:t})));await this.layer.applyEdits({deleteFeatures:t}),this._isDeleting=!1,this._deleteClosed(),this.editsComplete.emit("delete")}_deleteClosed(){this._confirmDelete=!1}async _getTranslations(){const t=await D(this.el);this._translations=t[0]}static get watchers(){return{ids:["idsWatchHandler"],layer:["layerWatchHandler"]}}};et.style=":host{display:block}.delete-modal{position:fixed}";export{Q as calcite_modal,tt as calcite_shell,et as delete_button}
|
@@ -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 r,h as s,H as t}from"./p-4e6eb06e.js";const a=class{constructor(r){e(this,r)}get el(){return r(this)}render(){return s(t,{key:"69a6d88e4a58724a61b964ab9e4cc44df1879be4"},s("slot",{key:"57bb8fc9d5fc942af7a47d4735b358510e406818"}))}};a.style=":host{display:block}";export{a as feature_form_flow_item}
|
@@ -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 s,h as t,H as a}from"./p-4e6eb06e.js";const r=class{constructor(s){e(this,s)}get el(){return s(this)}render(){return t(a,{key:"8154ad4de3a112bcdef4b1495c6fbeab1a13e292"},t("slot",{key:"6c12197599bd5742f4ffacbae64170929e485d99"}))}};r.style=":host{display:block}";export{r as features_flow_item}
|
@@ -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 s,h as e,H as h}from"./p-4e6eb06e.js";import{g as a,l as o}from"./p-f4aadb3b.js";import{g as l,q as n,e as c,f as d,i as r,j as p,c as b}from"./p-d572627c.js";import{d as f}from"./p-46c8015c.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-80cb7c73.js";import"./p-d0d020a5.js";import"./p-7530a02f.js";import"./p-9bb44f57.js";const u=class{constructor(s){t(this,s),this.createWorkFlowStarted=i(this,"createWorkFlowStarted",7),this.backFromCreateWorkFlow=i(this,"backFromCreateWorkFlow",7),this.featureOrRecordSubmitted=i(this,"featureOrRecordSubmitted",7),this.customInfoText=void 0,this.enableEditGeometry=!1,this.isMobile=void 0,this.layer=void 0,this.mapView=void 0,this.zoomAndScrollToSelected=void 0,this.selectedFeaturesIds=void 0,this.enableCreateFeatures=!0,this.selectingFeatureFromMap=void 0,this._cardLoading=!1,this._graphics=void 0,this._showCreateFeatureComponent=!1,this._showSubmitBtn=!1,this._translations=void 0}get el(){return s(this)}_isFeatureCreated=!1;_createFeature;createWorkFlowStarted;backFromCreateWorkFlow;featureOrRecordSubmitted;async featureSelectionChange(t){this._showCreateFeatureComponent&&!this._isFeatureCreated&&this._backFromCreateFeature();const i=t.detail;this._graphics=await this._getFeaturesByIds(i)}async layerSelectionChange(t){this._showCreateFeatureComponent&&this._backFromCreateFeature();const i=t.detail[0];this.layer=await l(this.mapView,i)}async componentWillLoad(){await this._getTranslations(),this.selectedFeaturesIds?.length>0&&(this._graphics=await this._getFeaturesByIds(this.selectedFeaturesIds))}render(){const t=this._graphics?.length>0?"":"display-none",i=0===this._graphics?.length&&this._showCreateFeatureComponent?"":"display-none",s=this._graphics?.length>0||this._showCreateFeatureComponent?"display-none":"",a=this.layer?.isTable,o=a?this._translations.createRecord:this._translations.createFeature,l=this.customInfoText?this.customInfoText:this.selectingFeatureFromMap?this._translations.selectFeaturesFromMapToStart:this._translations.selectFeaturesToStart,n=this.enableCreateFeatures&&this.layer?.capabilities?.operations?.supportsAdd;return e(h,{key:"7360aa9c48dd0c3e4a14fe0833b99c301388f93c"},e("div",{key:"9d610f0c4728c238eceb790e97a4e06b77f1a2d1",class:"overflow-auto height-full"},e("calcite-shell",{key:"4b6a02205a971c7ff61aab567b2f2a3c5d288f8d",class:"position-relative "+t},e("div",{key:"96ee8ce138265dd4b562ac0a33b79a0db4497842",class:"position-static z-index-500"},e("info-card",{key:"7db359bc1016281fd01b737dc5c424fe78995422",enableEditGeometry:this.enableEditGeometry,graphics:this._graphics,isLoading:this._cardLoading,isMobile:this.isMobile,mapView:this.mapView}))),e("calcite-shell",{key:"afc8d06e9aa3213a9ca10c929497ed4618a28e91",class:"position-relative "+s},e("calcite-flow-item",{key:"46db92a6e259eefea3293310e3e2f43d7639db97"},e("calcite-panel",{key:"d2bc23ae7bcf2b7b7b48a35efc0697e0d1f9e23e"},e("div",{key:"8f7fd13f9ec99beec1d7231dda03eba403a70a69",class:"padding-1"},e("calcite-notice",{key:"2fbe94292c1dd91ee1691b8e3d295225ff5b534b",icon:this.selectingFeatureFromMap?"map":"table",iconFlipRtl:!0,open:!0},e("div",{key:"9f91099e4bfa0675c5b098a73b2f132b80ee76b0",slot:"message"},l))),!this.isMobile&&n&&e("calcite-button",{key:"c1b04e776f3750712992d736e09726cc26eae5db",disabled:!this.layer,onClick:()=>this._createFeatureBtnClicked(),slot:"footer",width:"full"},a?this._translations.createRecord:this._translations.createFeature)))),e("calcite-shell",{key:"a71d4b0abd1ec1a4ed14a2cb3dcb10a075f54bf0",class:"position-relative "+i},e("calcite-flow-item",{key:"85047b527f5995a912b527325f287c3596caf630"},e("calcite-panel",{key:"d335be81502e0feb803ee9ad4e501d4c85f184f5",heading:o},e("calcite-action",{key:"b179c3185dbada3bd052d38b98b75cf29240655c",class:"back-button hydrated",icon:"chevron-left",onClick:this._backFromCreateFeature.bind(this),scale:"s",slot:"header-actions-start",text:""}),this.getEditorComponent(),this._showSubmitBtn&&e("calcite-button",{key:"f3b6655e3effdb6b09e64acd651a09d6028a6df9",appearance:"solid",class:"footer-top-button footer-button",onClick:()=>{this._createFeature.submit()},slot:"footer",width:"full"},this._translations.create))))))}getEditorComponent(){return e("div",null,this._showCreateFeatureComponent&&e("create-feature",{customizeSubmit:!0,mapView:this.mapView,onDrawComplete:()=>{this._showSubmitBtn=!0},onEditingAttachment:t=>{this._showSubmitBtn=!t.detail},onProgressStatus:()=>{setTimeout((()=>{this._isFeatureCreated=!1}),2e3)},onSuccess:this._featureCreated.bind(this),ref:t=>this._createFeature=t,selectedLayerId:this.layer?.id,showGuidingMsgWhileDrawing:!1}))}async _getFeaturesByIds(t){return(t.length>0?await n(t,this.layer,[],!0,this.mapView.spatialReference):[]).sort(((i,s)=>t.indexOf(i.getObjectId())-t.indexOf(s.getObjectId())))}_createFeatureBtnClicked(){this._showCreateFeatureComponent=!0,this.createWorkFlowStarted.emit()}async _backFromCreateFeature(){this._createFeature&&(this._showCreateFeatureComponent=!1,this.backFromCreateWorkFlow.emit()),this._showSubmitBtn=!1}_featureCreated(){this._showCreateFeatureComponent=!1,this._showSubmitBtn=!1,this._isFeatureCreated=!0,this.featureOrRecordSubmitted.emit(),setTimeout((()=>{this._showCreateFeatureComponent=!0}),50)}async _getTranslations(){const t=await a(this.el);this._translations=t[0]}};u.style=":host{display:block !important}.display-flex{display:flex}.display-none{display:none}.w-100{width:100%}.padding-bottom-1{padding-bottom:1rem}.padding-1{padding:1rem}.position-relative{position:relative}.focus-margin{margin:1px 1px 0px 1px}.overflow-auto{overflow:auto}.height-full{height:100%}.position-static{position:static !important}.z-index-500{z-index:500 !important}card-manager{display:block}";const m=class{constructor(s){t(this,s),this.featureSelectionChange=i(this,"featureSelectionChange",7),this.toggleFilter=i(this,"toggleFilter",7),this.appLayout=void 0,this.defaultGlobalId=void 0,this.defaultLayerId=void 0,this.defaultOid=void 0,this.enableAutoRefresh=void 0,this.enableColumnReorder=!0,this.enableCSV=void 0,this.enableInlineEdit=void 0,this.enableShare=void 0,this.isMobile=void 0,this.mapHidden=void 0,this.mapInfo=void 0,this.mapView=void 0,this.onlyShowUpdatableLayers=void 0,this.selectedIds=[],this.shareIncludeEmbed=void 0,this.shareIncludeSocial=void 0,this.showNewestFirst=void 0,this.zoomAndScrollToSelected=void 0,this.zoomToScale=void 0,this.createFilterModal=!0,this._allIds=[],this._controlsThatFit=void 0,this._csvExporting=!1,this._fetchingData=!1,this._filterActive=!1,this._filterOpen=!1,this._layer=void 0,this._selectAllActive=!1,this._showHideOpen=!1,this._showOnlySelected=!1,this._toolInfos=void 0,this._translations=void 0,this._fullTextSearchInfo=void 0,this._searchPlaceHolder="",this._size=0}get el(){return s(this)}FeatureTable;TableTemplate;_columnsInfo;_ctrlIsPressed=!1;_currentId;_editEnabled;_defaultFilterHonored=!1;_defaultGlobalIdHonored=!1;_defaultOidHonored=!1;_defaultVisibleToolSizeInfos;_definitionExpression;_deleteEnabled;_filterList;_floorExpression;_floorField;_floorFacility;_floorLevel;_floorSite;_layerExpressions;_loaded=!1;_mapClickHandle;_observerSet=!1;_previousCurrentId;reactiveUtils;_refreshHandle;_resizeObserver;_selectAllElement;_selectionFromMap=!1;_shareNode;_shiftIsPressed=!1;_showHideDropdown;_skipOnChange=!1;_moreDropdown;_table;_tableNode;_timeout;_toolbar;_toolbarSizeInfos;_searchExpression;appLayoutWatchHandler(){this._updateShareUrl()}async defaultOidWatchHandler(){await this._handleDefaults()}async defaultGlobalIdWatchHandler(){await this._handleDefaults()}enableCSVWatchHandler(){this._toolInfos?.length>0&&this._initToolInfos()}enableInlineEditWatchHandler(){this._table&&(this._table.editingEnabled=this._editEnabled&&this.enableInlineEdit)}enableShareWatchHandler(){this._toolbar&&this._updateToolbar()}_controlsThatFitWatchHandler(){const t=this._controlsThatFit?this._controlsThatFit.reduce(((t,i)=>(t.push(i.id),t)),[]):[];this._toolInfos=this._toolInfos?.map((i=>{if(i&&this._controlsThatFit){const s=this._getId(i.icon);return i.isOverflow=t.indexOf(s)<0,i}}))}mapHiddenWatchHandler(){this._toolInfos?.length>0&&this._initToolInfos()}isMobileWatchHandler(){this._toolInfos||this.isMobile||this._initToolInfos()}async mapInfoWatchHandler(){this._resetColumnTemplates(),this.createFilterModal&&this._initLayerExpressions(),this._initToolInfos(),this._updateToolbar(),await this._sortTable()}async mapViewWatchHandler(){this._mapClickHandle&&this._mapClickHandle.remove(),this.mapView&&(this._floorExpression=void 0,this._searchExpression=void 0,this._updateShareUrl(),this._mapClickHandle=this.reactiveUtils.on((()=>this.mapView),"click",(t=>{this._mapClicked(t)})))}async _layerWatchHandler(){this._fetchingData=!0,await(this._layer?.when((async()=>{this._definitionExpression=this._layer.definitionExpression,this._floorField=this._layer.floorInfo?.floorField,this._updateFloorDefinitionExpression(),await this._resetTable(),this.createFilterModal&&this._initLayerExpressions(),this._updateShareUrl(),this._fetchingData=!1})))}async selectedIdsWatchHandler(){this._updateShareUrl(),this._validateEnabledActions(),this._selectAllActive&&this.selectedIds.length!==this._allIds.length&&(this._selectAllActive=!1),this.selectedIds.length>0&&(this._table.rowHighlightIds.removeAll(),this._table.rowHighlightIds.add(this.selectedIds[0]))}async filterReset(){await this._handleFilterListReset()}async filterUpdate(){await this._handleFilterUpdate()}async closeFilter(){await this._closeFilter()}async refresh(){this._table&&await this._refresh()}featureSelectionChange;toggleFilter;async selectionChanged(t){const i=t.detail.selectedFeature[0],s=i.getObjectId(),e=this._table;if(e.rowHighlightIds.length&&e.rowHighlightIds.removeAll(),e.rowHighlightIds.add(s),this.zoomAndScrollToSelected){const t=this._table.viewModel.getObjectIdIndex(s);this._table.scrollToIndex(t);const e=i.layer;let h;this.mapView.allLayerViews.toArray().some((t=>{if(t.layer.title===e.title&&"feature"===t.layer.type)return h=t,!0})),h&&await c([s],h,this.mapView,!0,void 0,this.zoomToScale)}}async layerSelectionChange(t){await this._layerSelectionChanged(t)}async editsComplete(t){const i=t.detail;"delete"!==i&&"add"!==i||(this._allIds=await d(this._layer)),await this._refresh()}async facilityChanged(t){this._floorFacility=t.detail,this._updateFloorDefinitionExpression()}async levelChanged(t){this._floorLevel=t.detail,this._updateFloorDefinitionExpression()}async siteChanged(t){this._floorSite=t.detail,this._updateFloorDefinitionExpression()}noLayersFound(){this._layer=void 0,this._allIds=[],this._clearSelection()}clearSelection(){this._clearSelection()}async componentWillLoad(){await this._getTranslations(),await this._initModules(),this._initToolInfos(),this._resizeObserver||(this._resizeObserver=new ResizeObserver((()=>this._onResize())))}render(){const t=this._fetchingData?"display-none":"",i=this._fetchingData?"":"display-none",s=this._size.toString(),a=this.selectedIds.length.toString(),o=this.isMobile?"height-full":"height-full-adjusted",l=this._canShowFullTextSearch();return this._validateActiveActions(),e(h,{key:"aa79d91e6c569393334a38f937a493de227a0e5b"},e("calcite-shell",{key:"4b7460fc764c5a6027ad5aa8da826bd188e5490e"},this._getTableControlRow("header"),e("div",{key:"66ea361c6c2c3a5d05c4403a5d3dd1dea5a9e70b",class:`width-full ${o}`},e("calcite-panel",{key:"b213a696294c94504f394b54082f0183b46691ce",class:"height-full width-full"},l&&e("div",{key:"866dd2a69bc9e504b459ca8639d13f5babfa65fa",class:"search-container"},e("calcite-input",{key:"26f80276d08106981ef8c769fd4334528a37d881",class:"search",clearable:!0,icon:"search",onCalciteInputChange:t=>{this._searchTextChanged(t)},placeholder:this._searchPlaceHolder,title:this._searchPlaceHolder,type:"search"})),e("calcite-loader",{key:"a3d2e215cee3e370ef5645b6422c95eef32beedf",class:i,label:this._translations.fetchingData,scale:"l"}),e("div",{key:"e48c86ee1ebcc23121eab08903e55cc41270c4c8",class:t,ref:this.onTableNodeCreate}))),this.isMobile?void 0:e("div",{class:"bottom-left text-color height-19"},this._translations.recordsSelected.replace("{{total}}",s).replace("{{selected}}",a))),this.createFilterModal&&this._filterModal())}async componentDidLoad(){this.isMobile||this._observerSet||(this._resizeObserver.observe(this._toolbar),this._observerSet=!0)}componentDidRender(){document.onclick=t=>this._handleDocumentClick(t),document.onkeydown=t=>this._handleKeyDown(t),document.onkeyup=t=>this._handleKeyUp(t),this._updateToolbar()}async _initModules(){const[t,i,s]=await o(["esri/widgets/FeatureTable","esri/core/reactiveUtils","esri/widgets/FeatureTable/support/TableTemplate"]);this.FeatureTable=t,this.reactiveUtils=i,this.TableTemplate=s}async _searchTextChanged(t){this._fullTextSearchInfo.forEach((i=>{i.searchTerm=t.target.value})),this._searchFullText()}async _searchFullText(){if(this._searchExpression&&this._clearSearchDefinitionExpression(),this._fullTextSearchInfo.length&&this._fullTextSearchInfo[0].searchTerm){const t=this._layer.createQuery();t.fullText=this._fullTextSearchInfo;const i=await this._layer.queryObjectIds(t);await this._updateSearchDefinitionExpression(i?.length?i:[-1])}await new Promise((t=>setTimeout(t,800))),await this._updateAllIds()}_clearSearchDefinitionExpression(){const t=this._layer.definitionExpression;this._searchExpression&&t?.indexOf(this._searchExpression)>-1&&(this._layer.definitionExpression=t?.indexOf(" AND ("+this._searchExpression)>-1?t.replace(` AND (${this._searchExpression})`,""):t.replace(this._searchExpression,"")),this._searchExpression=void 0}async _updateSearchDefinitionExpression(t){const i=this._layer.definitionExpression;if(t?.length){const s=`objectId in(${t})`;this._layer.definitionExpression=i?.indexOf(this._searchExpression)>-1?i.replace(this._searchExpression,s):i?`${i} AND (${s})`:s,this._searchExpression=s}else this._clearSearchDefinitionExpression()}_canShowFullTextSearch(){return((this._layer?.capabilities)?.query)?.supportsFullTextSearch&&this._layer.indexes.items.filter((t=>"FullText"==t.indexType)).length>0}_getFullTextSearchInfo(){if(this._fullTextSearchInfo=[],((this._layer?.capabilities)?.query)?.supportsFullTextSearch){const t=this._layer.indexes?.filter((t=>"FullText"==t.indexType));if(t?.length){const i=[];t.forEach((t=>{i.push(...t.fields.split(","))}));const s=[];i.forEach((t=>{const i=this._layer.getField(t.trim());s.push(i.alias)})),this._searchPlaceHolder=this._translations.searchPlaceholder.replace("{{fields}}",s.join(", ")),this._fullTextSearchInfo.push({onFields:["*"],searchTerm:"",searchType:"prefix"})}}}_onResize(){this._updateToolbar()}_getTableControlRow(t){const i=this._canShowFullTextSearch()?"border-bottom":"";return e("div",{class:`display-flex height-51-px ${i}`,ref:t=>this._toolbar=t,slot:t},this._getActionBar(),this.isMobile?void 0:this._getDropdown("more-table-options"),this.enableShare&&!this.isMobile?this._getShare("share"):void 0)}_getActionBar(){const t=this.isMobile?"width-full":"",i=this.isMobile?"border-top":"";return e("calcite-action-bar",{class:t,expandDisabled:!0,expanded:!0,id:this._getId("bar"),layout:"horizontal"},e("div",{class:`border-end ${t} ${i}`,id:"solutions-map-layer-picker-container"},e("map-layer-picker",{appearance:"transparent",defaultLayerId:this.defaultLayerId,display:"inline-flex",height:50,isMobile:this.isMobile,mapView:this.mapView,onlyShowUpdatableLayers:this.onlyShowUpdatableLayers,placeholderIcon:"layers",scale:"l",selectedIds:this._layer?[this._layer?.id]:[],showSingleLayerAsLabel:!0,showTables:!0,type:"dropdown"})),this.isMobile?void 0:this._getActions())}_getActions(){const t=this._getActionItems();return t?.reduce(((t,i)=>(i&&!i.isOverflow&&t.push(i.isDanger?this._getDangerAction(i.icon,i.label,i.func,i.disabled):i.isSublist?e("calcite-dropdown",{closeOnSelectDisabled:!0,id:this._getId(i.icon),onCalciteDropdownBeforeClose:()=>this._forceShowHide(),ref:t=>this._showHideDropdown=t},this._getAction(i.active,this._showHideOpen?"chevron-down":i.icon,i.indicator,i.label,i.func,i.disabled,i.loading,"trigger"),this._showHideOpen?this._getFieldlist():void 0):this._getAction(i.active,i.icon,i.indicator,i.label,i.func,i.disabled,i.loading)),t)),[])}_getFieldlist(){return this._columnsInfo?e("calcite-dropdown-group",{"selection-mode":"multiple"},Object.keys(this._columnsInfo).map((t=>{const i=this._columnsInfo[t];return e("calcite-dropdown-item",{id:`layer-table-${t.toLowerCase().replaceAll(" ","")}`,label:t,onClick:t=>{const i=t.target;this._columnsInfo[i.label]=i.selected,i.selected?this._table.showColumn(i.label):this._table.hideColumn(i.label)},selected:i},t)}))):void 0}_validateEnabledActions(){const t=this._featuresSelected(),i=this.selectedIds.length>1&&this._layer?.capabilities?.operations?.supportsUpdate,s=["zoom-to-object","pencil","trash","erase","selected-items-filter"];this._toolInfos?.forEach((e=>{e&&s.indexOf(e.icon)>-1&&(e.disabled="pencil"===e.icon?!i:!t)}))}_validateActiveActions(){const t=["filter","list-check-all","selected-items-filter"];this._toolInfos?.forEach((i=>{i&&t.indexOf(i.icon)>-1&&("filter"===i.icon&&(i.indicator=this._filterActive),"list-check-all"===i.icon&&(i.active=this._selectAllActive),"selected-items-filter"===i.icon&&(i.active=this._showOnlySelected))}))}_initToolInfos(){const t=this._featuresSelected(),i=this.selectedIds.length>1&&this._layer?.capabilities?.operations?.supportsUpdate&&!1,s=this._featuresEmpty(),e=this._hasFilterExpressions();this._translations&&(this._toolInfos=[this.mapHidden?void 0:{active:!1,icon:"zoom-to-object",indicator:!1,label:this._translations.zoom,func:()=>this._zoom(),disabled:!t,isOverflow:!1},e?{active:!1,icon:"filter",indicator:!1,label:this._translations.filters,func:()=>this.createFilterModal?this._toggleFilter():this.toggleFilter.emit(),disabled:!1,isOverflow:!1}:void 0,i?{active:!1,icon:"pencil",indicator:!1,label:this._translations.editMultiple,func:()=>alert(this._translations.editMultiple),disabled:!i,isOverflow:!1}:void 0,this._deleteEnabled?{active:void 0,icon:"trash",indicator:void 0,label:this._translations.delete,func:()=>{},disabled:!t,isDanger:!0,isOverflow:!1}:void 0,{active:!1,icon:"erase",indicator:!1,label:this._translations.clearSelection,func:()=>this._clearSelection(),disabled:!t,isOverflow:!1},{active:!1,icon:"selected-items-filter",indicator:!1,label:this._showOnlySelected?this._translations.showAll:this._translations.showSelected,func:()=>this._toggleShowSelected(),disabled:!t,isOverflow:!1},{active:!1,icon:"list-check-all",indicator:!1,func:()=>this._selectAll(),label:this._translations.selectAll,disabled:s,isOverflow:!1},{active:!1,icon:"compare",indicator:!1,func:()=>this._switchSelected(),label:this._translations.switchSelected,disabled:s,isOverflow:!1},{active:!1,icon:"refresh",indicator:!1,func:()=>this._refresh(),label:this._translations.refresh,disabled:!1,isOverflow:!1},this.enableCSV?{active:!1,icon:"export",indicator:!1,func:()=>{this._exportToCSV()},label:this._translations.exportCSV,loading:this._csvExporting,disabled:s,isOverflow:!1}:void 0,{active:!1,icon:this._showHideOpen?"chevron-down":"chevron-right",indicator:!1,func:()=>this._toggleShowHide(),label:this._translations.showHideColumns,disabled:!1,isOverflow:!1,isSublist:!0}],this._defaultVisibleToolSizeInfos=void 0)}_updateFloorDefinitionExpression(){if(this._floorField&&this._floorLevel){const t=`${this._floorField} = '${this._floorLevel}'`,i=this._layer.definitionExpression;this._layer.definitionExpression=i?.indexOf(this._floorExpression)>-1?i.replace(this._floorExpression,t):i?`${i} AND (${t})`:t,this._floorExpression=t}}_featuresSelected(){return this.selectedIds.length>0}_featuresEmpty(){return 0===this._allIds.length}_hasFilterExpressions(){let t;return this.mapInfo?.filterConfig?.layerExpressions&&this._layer?.id&&(t=this.mapInfo.filterConfig.layerExpressions.filter((t=>t.id===this._layer.id))),t?.length>0}_updateToolbar(){this._timeout&&clearTimeout(this._timeout),!this.isMobile&&this._toolbar&&this._toolInfos&&(this._timeout=setTimeout((()=>{clearTimeout(this._timeout),this._setToolbarSizeInfos();const t=this._toolbar.offsetWidth;let i=this._toolbarSizeInfos.reduce(((t,i)=>t+i.width),0);const s=["solutions-more","solutions-map-layer-picker-container","solutions-action-share"];if(i>t){if(this._toolbarSizeInfos.length>0){const e=[...this._toolbarSizeInfos].reverse().reduce(((e,h)=>(s.indexOf(h.id)<0&&(i>t?i-=h.width:e.push(h)),e)),[]).reverse();this._setControlsThatFit(e,s)}}else if(this._defaultVisibleToolSizeInfos){const e=this._toolbarSizeInfos.reduce(((t,i)=>(t.push(i.id),t)),[]);let h=!1;const a=[...this._defaultVisibleToolSizeInfos].reduce(((a,o)=>(!h&&s.indexOf(o.id)<0&&(e.indexOf(o.id)>-1||i+o.width<=t)?(e.indexOf(o.id)<0&&(i+=o.width),a.push(o)):s.indexOf(o.id)<0&&i+o.width>t&&(h=!0),a)),[]);this._setControlsThatFit(a,s)}}),250))}_setControlsThatFit(t,i){let s=JSON.stringify(t)!==JSON.stringify(this._controlsThatFit);const e=document.getElementById("solutions-action-bar");e?.childNodes?.forEach((t=>{i.indexOf(t.id)<0&&!s&&(s=this._controlsThatFit.map((t=>t.id)).indexOf(t.id)<0)})),s&&(this._controlsThatFit=[...t])}_setToolbarSizeInfos(){let t=!1;this._toolbarSizeInfos=[],this._toolbar.childNodes.forEach(((i,s)=>{0===s?i.childNodes.forEach((i=>{this._toolbarSizeInfos.push({id:i.id,width:i.offsetWidth}),t||(t=i.offsetWidth>0)})):i.referenceElement||(this._toolbarSizeInfos.push({id:i.id,width:i.offsetWidth}),t||(t=i.offsetWidth>0))})),t&&!this._defaultVisibleToolSizeInfos&&(this._defaultVisibleToolSizeInfos=[...this._toolbarSizeInfos])}_getActionItems(){return this._toolInfos?.filter((t=>t&&!t.isOverflow))}_getDropdown(t){const i=this._getDropdownItems();return i.length>0?e("calcite-dropdown",{closeOnSelectDisabled:!0,disabled:void 0===this._layer,id:"solutions-more",onCalciteDropdownBeforeClose:()=>this._forceShowHide(),ref:t=>this._moreDropdown=t},e("calcite-action",{appearance:"solid",id:t,label:"",onClick:()=>this._closeShowHide(),slot:"trigger",text:""},e("calcite-button",{appearance:"transparent",iconEnd:"chevron-down",kind:"neutral"},this._translations.more)),e("calcite-dropdown-group",{"selection-mode":"none"},i.map((t=>e("calcite-dropdown-group",{class:t.disabled?"disabled":"",selectionMode:"none"},e("calcite-dropdown-item",{disabled:t.loading,iconStart:t.isSublist&&this._showHideOpen?"chevron-down":t.loading?"":t.icon,id:`layer-table-${t.icon}`,onClick:t.func},t.loading?e("div",{class:"display-flex"},e("calcite-loader",{inline:!0,label:t.label,scale:"m"}),t.label):t.label))))),this._showHideOpen?this._getFieldlist():void 0):void 0}_getDropdownItems(){return this._toolInfos?.filter((t=>t&&t.isOverflow))}_getAction(t,i,s,h,a,o,l,n){const c=void 0===this._layer||o;return e("div",{class:"display-flex",id:this._getId(i),slot:n},e("calcite-action",{active:t,appearance:"solid",disabled:c,icon:i,id:`layer-table-${i}`,indicator:s,label:h,loading:l,onClick:a,text:h,textEnabled:!0}),this._getToolTip("bottom",i,h))}_getShare(t){return e("div",{class:"share-action",id:this._getId(t)},e("instant-apps-social-share",{autoUpdateShareUrl:!1,class:"instant-app-share",embed:this.shareIncludeEmbed,popoverButtonIconScale:"s",ref:t=>this._shareNode=t,scale:"m",shareButtonColor:"neutral",shareButtonType:"action",socialMedia:this.shareIncludeSocial,view:this.mapView}),this._getToolTip("bottom",t,this._translations.share))}_updateShareUrl(){const t=this._shareNode?.shareUrl;if(!t)return;const i=new URL(t);this.mapInfo?.id?i.searchParams.set("webmap",this.mapInfo.id):i.searchParams.delete("webmap"),this._layer?.id?i.searchParams.set("layer",this._layer.id):i.searchParams.delete("layer"),this.selectedIds?.length>0?i.searchParams.set("oid",this.selectedIds.join(",")):i.searchParams.delete("oid"),i.searchParams.set("applayout",this.appLayout),this._shareNode.shareUrl=i.href}_getToolTip(t,i,s){return document.getElementById(i)?e("calcite-tooltip",{placement:t,"reference-element":i},e("span",null,s)):void 0}_getId(t){return`solutions-action-${t}`}_getDangerAction(t,i,s,h){const a=void 0===this._layer||h;return e("div",{class:"display-flex",id:this._getId(t)},"trash"===t?e("delete-button",{buttonType:"action",class:"display-flex",disabled:a,icon:t,ids:this._getIds(),layer:this._layer}):e("calcite-action",{appearance:"solid",disabled:a,id:t,onClick:s,text:i},e("calcite-button",{appearance:"transparent",iconStart:t,kind:"danger"},i)),this._getToolTip("bottom",t,i))}_getIds(){return this._table.highlightIds.toArray()}onTableNodeCreate=t=>{this._tableNode=t};async _getTable(t,i){this._layer&&(await this._layer.when((()=>{this._table=new this.FeatureTable({autoRefreshEnabled:this.enableAutoRefresh,layer:this._layer,view:this.mapView,columnReorderingEnabled:this.enableColumnReorder,editingEnabled:this._editEnabled&&this.enableInlineEdit,highlightEnabled:!0,multiSortEnabled:!1,visibleElements:{header:!1,menu:!1},tableTemplate:{columnTemplates:i},container:t})})),await this._table.when((()=>{this._table.highlightIds.on("change",(t=>{this._handleOnChange(t)}));const t=this.reactiveUtils.watch((()=>this._table.size),(t=>{this._size=t}));this._table.viewModel.addHandles(t)})))}async _handleOnChange(t){const i=[...this._table.highlightIds.toArray()];if(this._skipOnChange)this._skipOnChange=!1;else{if(!this._ctrlIsPressed&&!this._shiftIsPressed||this._selectionFromMap&&this._shiftIsPressed)if(this.selectedIds.length>0){this._skipOnChange=!0;const s=this.selectedIds.length>1&&1===t.removed.length?t.removed:i.filter((t=>this.selectedIds.indexOf(t)<0));this._clearSelection(),this.selectedIds=[...s],s.length>0?this._table.highlightIds.add(s[0]):this._skipOnChange=!1}else this.selectedIds=i.reverse();else if(this._ctrlIsPressed)this.selectedIds=i.reverse();else if(this._shiftIsPressed&&i?.length>0)if(this._skipOnChange=!0,this._previousCurrentId=this._currentId,this._currentId=[...i].reverse()[0],1===i.length)this._skipOnChange=!1;else if(this._previousCurrentId!==this._currentId){const t=this._table.activeSortOrders.reduce(((t,i)=>(t.push(`${i.fieldName} ${i.direction}`),t)),[]),s=await r(0,this._layer,[],t);let e=!1;const h=this._table.viewModel.getObjectIdIndex(this._previousCurrentId),a=this._table.viewModel.getObjectIdIndex(this._currentId);this._skipOnChange=(h<a?h:a)+1!==(a>h?a:h);const o=s.reduce(((t,i)=>{const s=i;return s===this._currentId||s===this._previousCurrentId?(e=!e,t.indexOf(s)<0&&t.push(s)):e&&t.indexOf(s)<0&&t.push(s),t}),[]),l=h<a?o.reverse():o;this.selectedIds=[...new Set([...l,...this.selectedIds])],this._table.highlightIds.addMany(this.selectedIds.filter((t=>i.indexOf(t)<0)))}this._finishOnChange()}this._currentId=[...this._table.highlightIds.toArray()].reverse()[0],this._selectionFromMap=!1}_finishOnChange(){this._showOnlySelected&&(this._featuresSelected()?this._table.filterBySelection():this._toggleShowSelected()),this.featureSelectionChange.emit(this.selectedIds)}_resetColumnTemplates(){const t=this._getColumnTemplates(this._layer?.id,this._layer?.fields),i=t?.some(((t,i)=>JSON.stringify(this._table?.tableTemplate.columnTemplates[i])!==JSON.stringify(t)));if(this._table&&t&&(i||!this._columnsInfo)){this._table.tableTemplate=new this.TableTemplate({columnTemplates:t});const i=t.map((t=>t.fieldName));this._initColumnsInfo(i)}}async _resetTable(){if(this._loaded=!1,this._clearSelection(),this._allIds=await d(this._layer),this._table)this._table.view=this.mapView,this._table.layer=this._layer;else{const t=this._getColumnTemplates(this._layer.id,this._layer?.fields);await this._getTable(this._tableNode,t)}await this._initLayerRefresh(),this._checkEditEnabled(),this._table.editingEnabled=this._editEnabled&&this.enableInlineEdit,await this._table.when(),setTimeout((()=>{this._loaded||(console.log(`table.state: ${this._table.state}`),this.finishLoading())}),1e3),await this.reactiveUtils.once((()=>"loaded"===this._table.state)).then((async()=>{await this.finishLoading()}))}async finishLoading(){try{this._loaded=!0,this._table.highlightIds.removeAll(),this._table.clearSelectionFilter(),this._resetColumnTemplates(),this._showOnlySelected=!1,await this._handleDefaults(),await this._sortTable(),this._initToolInfos(),this._updateToolbar()}catch(t){console.log(t)}}async _initLayerRefresh(){this._refreshHandle&&this._refreshHandle.remove(),this._refreshHandle=this._layer.on("refresh",(t=>{t.dataChanged&&(this._skipOnChange=!0,this._updateAllIds())}))}async _updateAllIds(){this._allIds=await d(this._layer),this.selectedIds=this.selectedIds.filter((t=>this._allIds.indexOf(t)>-1)),await this._refresh()}async _handleDefaults(){if(!this._defaultOidHonored&&this.defaultOid?.length>0&&this.defaultOid[0]>-1&&this._table&&(await this._selectDefaultFeature(this.defaultOid),this._defaultOidHonored=!0,this.defaultOid=void 0,this._showOnlySelected=!1,this._toggleShowSelected()),!this._defaultGlobalIdHonored&&this.defaultGlobalId?.length>0&&this._table){const t=await p(this.defaultGlobalId,this._layer),i=t?.length>0?t.map((t=>t.getObjectId())):void 0;i&&await this._selectDefaultFeature(i),this._defaultGlobalIdHonored=!0,this.defaultGlobalId=void 0,this._showOnlySelected=!1,this._toggleShowSelected()}}_initColumnsInfo(t){const i=this._table?.columns.reduce(((i,s)=>((!t||t?.indexOf(s.name)>-1)&&(i[s.name]=!s.hidden),i)),{}),s=this._table?.columns.map((t=>t.name));(t?t.filter((t=>s.indexOf(t)<0)):[]).forEach((t=>{i[t]=!0})),this._columnsInfo=t?t.reduce(((t,s)=>(t[s]=i[s],t)),{}):i}async _selectDefaultFeature(t){t.length>0&&this._table.highlightIds.addMany(t)}_checkEditEnabled(){this._editEnabled=this._layer.editingEnabled&&this._layer.capabilities.operations.supportsUpdate,this._deleteEnabled=this._layer.editingEnabled&&this._layer.capabilities.operations.supportsDelete}async _sortTable(){let t,i=this._layer?.objectIdField,s="desc";this.mapInfo?.layerOptions?.layers?.length>0&&this._layer?.id&&(t=this.mapInfo.layerOptions.layers.filter((t=>t.id===this._layer.id)),t&&t.length>0&&(t=t[0],t.sortField&&t.fields?.includes(t.sortField)&&(i=t.sortField),s=t?.sortOrder?t.sortOrder:"desc")),this._table&&this._layer&&(await this._table.when(),await this._layer.when((()=>{this._table.sortColumn(i,s)})))}_forceShowHide(){this._showHideDropdown&&(this._showHideDropdown.open=this._showHideOpen),this._moreDropdown&&(this._moreDropdown.open=this._showHideOpen)}_toggleShowHide(){this._showHideOpen=!this._showHideOpen}_closeShowHide(){this._showHideOpen=!1}_handleDocumentClick(t){const i=t.target?.id;i.startsWith("layer-table-")?this._moreDropdown.open=!0:this._showHideOpen&&Object.keys(this._columnsInfo).indexOf(i)<0&&"chevron-right"!==i&&(this._closeShowHide(),this._moreDropdown&&(this._moreDropdown.open=!1),this._showHideDropdown&&(this._showHideDropdown.open=!1))}_handleKeyDown(t){this._ctrlIsPressed=t.ctrlKey,this._shiftIsPressed=t.shiftKey}_handleKeyUp(t){this._ctrlIsPressed=t.ctrlKey,this._shiftIsPressed=t.shiftKey}_filterModal(){return e("calcite-modal",{"aria-labelledby":"modal-title",class:"modal",kind:"brand",onCalciteModalClose:()=>{this._closeFilter()},open:this._filterOpen,widthScale:"s"},e("div",{class:"display-flex align-center",id:"modal-title",slot:"header"},this._translations?.filter?.replace("{{title}}",this._layer?.title)),e("div",{slot:"content"},e("instant-apps-filter-list",{autoUpdateUrl:!1,closeBtn:!0,closeBtnOnClick:async()=>this._closeFilter(),comboboxOverlayPositioning:"fixed",layerExpressions:this._layerExpressions,onFilterListReset:()=>{this._handleFilterListReset()},onFilterUpdate:()=>{this._handleFilterUpdate()},ref:t=>this._filterList=t,view:this.mapView,zoomBtn:!1})))}async _handleFilterListReset(){this._filterActive=!1,this._updateShareUrl(),await this._searchFullText()}async _handleFilterUpdate(){const t=this._layer.definitionExpression;if(this._floorExpression){const i=new RegExp(`${this._floorField} = ['].+[']`,"gm");this._layer.definitionExpression=t&&this._floorField&&t.indexOf(`${this._floorField} = '`)>-1?t.replace(i,this._floorExpression):t?`${t} AND (${this._floorExpression})`:this._floorExpression}this._filterActive=this._definitionExpression!==this._layer.definitionExpression&&(!this._floorExpression||this._layer.definitionExpression!==this._floorExpression),this._updateShareUrl(),await this._searchFullText()}async _closeFilter(){this._filterOpen&&(this._allIds=await d(this._layer),this._filterOpen=!1)}async _mapClicked(t){const i={include:this._layer},s=await this.mapView.hitTest(t.screenPoint,i);s.results.length>0?(s.results.forEach((t=>{const i=t.graphic.getObjectId();this._table.highlightIds.indexOf(i)<0&&(this._selectionFromMap=!0,this._table.highlightIds.add(i))})),this._showOnlySelected&&this._table.filterBySelection()):this._clearSelection()}_selectAll(){const t=this._allIds;this._table.highlightIds.removeAll(),this._skipOnChange=!0,this._table.highlightIds.addMany(t),this.selectedIds=t,this._finishOnChange(),this._selectAllActive=!0}_toggleShowSelected(){this._showOnlySelected=!this._showOnlySelected,this._showOnlySelected?this._table.filterBySelection():this._table.clearSelectionFilter()}_clearSelection(){this.selectedIds=[],this._table?.highlightIds.removeAll(),this._table?.rowHighlightIds.removeAll(),this._finishOnChange()}_toggleFilter(){this._filterOpen=!this._filterOpen}_initLayerExpressions(){const t=this.mapInfo?.filterConfig?.layerExpressions;this._layerExpressions=t?t.filter((t=>t.id===this._layer?.id)):[],this._filterList.layerExpressions=this._layerExpressions,this._filterActive=this._layerExpressions.filter((t=>t.expressions.filter((t=>t.active)).length>0)).length>0}_switchSelected(){const t=[...this.selectedIds];this._table.highlightIds.removeAll();const i=this._allIds.reduce(((i,s)=>(t.indexOf(s)<0&&i.push(s),i)),[]).sort(((t,i)=>t-i));this._skipOnChange=!0,this._table.highlightIds.addMany(i),this.selectedIds=i,this._finishOnChange()}async _exportToCSV(){const t={},i=this._table.highlightIds.toArray();t[this._layer.id]={selectionSetNames:[this._layer.title],ids:i,layer:this._layer};const s=this._table.columns.toArray().reduce(((t,i)=>(i.hidden||t.push(i.name.toLocaleLowerCase()),t)),[]);this._updateToolInfoLoading("export",!0),this._csvExporting=!0,await f(null,t,!1,!1,!0,s,!0,!0),this._updateToolInfoLoading("export",!1),this._csvExporting=!1}_updateToolInfoLoading(t,i){this._toolInfos.some((s=>{if(s?.icon===t)return s.loading=i,!0}))}async _refresh(){await this._table.refresh(),this._allIds=await d(this._layer),this.featureSelectionChange.emit(this.selectedIds)}async _zoom(){if(this._layer){const t=await b(this.mapView,this._layer.id);await c(this.selectedIds,t,this.mapView,!0,void 0,this.zoomToScale)}}async _layerSelectionChanged(t){const i=t.detail[0];if(i!==this._layer?.id||this._featuresEmpty()){this._fetchingData=!0;const t=await l(this.mapView,i);t&&await t.when((()=>{this._layer=t,this._getFullTextSearchInfo()}))}this._fetchingData=!1}_getColumnTemplates(t,i){let s;this.mapInfo?.layerOptions?.layers.some((i=>{if(i.id===t)return s=i,!0}));const e=s?.fields&&s?.fieldOrder?s.fieldOrder.filter((t=>s.fields.indexOf(t)>-1)):void 0;let h;return i&&(h=s&&s?.fields?i.reduce(((t,i)=>{if(s.fields.indexOf(i.name)>-1){const s={type:"field",fieldName:i.name,label:i.alias,menuConfig:this._getMenuConfig(i.name)};t.push(s)}return t}),[]).sort(this._sortFields.bind(this,s?.fieldOrder)):i.map((t=>({type:"field",fieldName:t.name,label:t.alias,menuConfig:this._getMenuConfig(t.name)})))),e?h?.sort(this._sortFields.bind(this,e)):h}_sortFields(t,i,s){return t?.indexOf(i.fieldName)-t.indexOf(s.fieldName)}_getMenuConfig(t){return{items:[{label:this._translations.hideField,icon:"view-hide",autoCloseMenu:!0,clickFunction:()=>{this._handleHideClick(t)}}]}}_handleHideClick(t){this._columnsInfo[t]=!1,this._table.hideColumn(t),this._table.tableTemplate.columnTemplates.forEach((i=>{i.fieldName===t&&(i.visible=!1)}))}async _getTranslations(){const t=await a(this.el);this._translations=t[0]}static get watchers(){return{appLayout:["appLayoutWatchHandler"],defaultOid:["defaultOidWatchHandler"],defaultGlobalId:["defaultGlobalIdWatchHandler"],enableCSV:["enableCSVWatchHandler"],enableInlineEdit:["enableInlineEditWatchHandler"],enableShare:["enableShareWatchHandler"],_controlsThatFit:["_controlsThatFitWatchHandler"],mapHidden:["mapHiddenWatchHandler"],isMobile:["isMobileWatchHandler"],mapInfo:["mapInfoWatchHandler"],mapView:["mapViewWatchHandler"],_layer:["_layerWatchHandler"],selectedIds:["selectedIdsWatchHandler"]}}};function v(t){return function(t){return-1!==t?.indexOf("http://")}(t)?t.replace(/^http:\/\//,"https://"):t}m.style=':host{display:block}.height-full{height:100%}.height-full-adjusted{height:calc(100% - 20px)}.width-full{width:100%}.display-flex{display:flex}.table-border{border:1px solid var(--calcite-color-border-2)}.border-end{border-inline-end:1px solid var(--calcite-color-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51-px{height:51px}.height-50-px{height:50px}.bottom-left{position:absolute;left:0;bottom:0;padding-left:5px}html[dir="rtl"] .bottom-left{position:absolute;right:0;bottom:0;padding-right:5px}.height-19{height:19px}.background{background-color:var(--calcite-color-background)}.text-color{color:var(--calcite-color-text-1)}.align-center{align-items:center}.danger-color{color:var(--calcite-color-status-danger)}.esri-feature-table vaadin-grid{border:none !important}vaadin-grid-cell-content{font-size:14px !important;color:var(--calcite-color-text-3) !important}.share-action{position:absolute;right:0}html[dir="rtl"] .share-action{left:0}.disabled{cursor:default !important;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled);pointer-events:none}.instant-app-share{height:50px !important;display:inline-flex}.border-top{border-top:1px solid var(--calcite-color-border-2)}.modal{--calcite-modal-content-padding:0}.esri-feature-table__table-container{height:100%}.search-container{background-color:var(--calcite-color-foreground-1) !important}.search{--calcite-color-border-input:var(--calcite-color-border-3);width:60%;padding:10px}';const y=class{constructor(s){t(this,s),this.mapChanged=i(this,"mapChanged",7),this.beforeMapChanged=i(this,"beforeMapChanged",7),this.toggleFilter=i(this,"toggleFilter",7),this.clearSelection=i(this,"clearSelection",7),this.appLayout=void 0,this.appProxies=void 0,this.defaultWebmapId="",this.defaultLayerId=void 0,this.enableHome=void 0,this.enableLegend=void 0,this.enableFloorFilter=void 0,this.enableFullscreen=void 0,this.enableShare=!1,this.enableSingleExpand=!0,this.enableSearch=void 0,this.enableBasemap=void 0,this.basemapConfig=void 0,this.hidden=void 0,this.homeZoomIndex=3,this.homeZoomPosition="top-left",this.homeZoomToolsSize="m",this.mapInfos=[],this.mapWidgetsIndex=0,this.mapWidgetsPosition="top-right",this.mapWidgetsSize="m",this.mapView=void 0,this.stackTools=!0,this.theme=void 0,this.toolOrder=void 0,this.isMapLayout=void 0,this.shareIncludeEmbed=void 0,this.shareIncludeSocial=void 0,this.selectedFeaturesIds=void 0,this.selectedLayer=void 0,this.zoomToScale=void 0,this.onlyShowUpdatableLayers=void 0,this.isMobile=void 0,this.mapInfo=void 0,this._translations=void 0,this._searchConfiguration=void 0,this._webMapInfo=void 0,this._showHideOpen=!1,this._toolInfos=void 0,this._controlsThatFit=void 0}get el(){return s(this)}esriConfig;Home;MapView;WebMap;_defaultWebmapHonored=!1;_homeWidget;_loadedId="";_mapDiv;_mapPicker;_mapTools;_moreDropdown;_mapListExpanded=!1;_filterActive=!1;_definitionExpression;_mapLayerPicker;_resizeObserver;_shareNode;_showHideDropdown;_toolbar;_timeout;_toolbarSizeInfos;_defaultVisibleToolSizeInfos;_observerSet=!1;appLayoutWatchHandler(){this._updateShareUrl()}enableHomeWatchHandler(){this._initHome()}enableShareWatchHandler(){this._toolbar&&this._updateToolbar()}async mapViewWatchHandler(){this.mapView&&this._updateShareUrl()}async selectedLayerWatchHandler(){await(this.selectedLayer?.when((async()=>{this._definitionExpression=this.selectedLayer.definitionExpression})))}async selectedFeaturesIdsWatchHandler(){this._updateShareUrl(),this._validateEnabledActions()}_controlsThatFitWatchHandler(){const t=this._controlsThatFit?this._controlsThatFit.reduce(((t,i)=>(t.push(i.id),t)),[]):[];this._toolInfos=this._toolInfos?.map((i=>{if(i&&this._controlsThatFit){const s=this._getId(i.icon);return i.isOverflow=t.indexOf(s)<0,i}}))}async resetFilter(){this._filterActive=!1,this._updateShareUrl()}async updateFilterState(){this._filterActive=this._definitionExpression!==this.selectedLayer.definitionExpression,this._updateShareUrl()}async updateLayer(){this._mapLayerPicker.updateLayer()}mapChanged;beforeMapChanged;toggleFilter;clearSelection;async mapInfoChange(t){await this._loadMap(t.detail)}noLayersFound(){this.selectedLayer=void 0,this.selectedFeaturesIds=[]}layerSelectionChange(){setTimeout((()=>{this._initToolInfos()}),50)}async componentWillLoad(){await this._getTranslations(),await this._initModules(),this._initToolInfos(),this._resizeObserver||(this._resizeObserver=new ResizeObserver((()=>this._updateToolbar())))}render(){const t=this.isMapLayout?"display-flex height-49-px":"",i=this.hidden?"visibility-hidden-1":"",s="dark"===this.theme?"calcite-mode-dark":"calcite-mode-light",a=this.mapInfos?.length>1||this.isMapLayout?"map-height":"height-full",o=this.isMapLayout?"":"display-none";return this._validateActiveActions(),e(h,{key:"790599924cf104116f6961380103aef7c55e6d76"},e("div",{key:"5467a5d4e3998807fdf243ada3088dba8e69941f",class:`${t} width-full`,ref:t=>this._toolbar=t},this._getActionBar(),!this.isMobile&&this.isMapLayout&&this._getDropdown("more-table-options"),this.enableShare&&!this.isMobile&&this.isMapLayout?this._getShare("share"):void 0),e("calcite-progress",{key:"5c82042e0206be05e12d29ba588b26344b1017b8",class:o,value:0}),e("div",{key:"0831bc4593f5a7680a8599a9868990734cb013b9",class:`${a} ${i}`,ref:t=>this._mapDiv=t}),e("map-tools",{key:"5bbf14428cc845d8b889e72d707672250f820686",basemapConfig:this.basemapConfig,class:`box-shadow ${s}`,enableBasemap:this.enableBasemap,enableFloorFilter:this.enableFloorFilter,enableFullscreen:this.enableFullscreen,enableHome:this.enableHome,enableLegend:this.enableLegend,enableSearch:this.enableSearch,enableSingleExpand:this.enableSingleExpand,homeZoomToolsSize:this.homeZoomToolsSize,mapView:this.mapView,mapWidgetsSize:this.mapWidgetsSize,position:this.mapWidgetsPosition,ref:t=>this._mapTools=t,searchConfiguration:this._searchConfiguration,stackTools:this.stackTools,toolOrder:this.toolOrder}))}async componentDidRender(){this.isMapLayout&&this._updateToolbar(),document.onclick=t=>this._handleDocumentClick(t)}async componentDidLoad(){this.isMobile||this._observerSet||(this._resizeObserver.observe(this._toolbar),this._observerSet=!0),this._updateShareUrl()}async _initModules(){const[t,i,s,e]=await o(["esri/WebMap","esri/views/MapView","esri/widgets/Home","esri/config"]);this.WebMap=t,this.MapView=i,this.Home=s,this.esriConfig=e}async _loadMap(t){const i=!this._defaultWebmapHonored&&this.defaultWebmapId,s=this.mapInfos?.filter((t=>t.id===this.defaultWebmapId)),e=JSON.stringify(t)!==JSON.stringify(this._webMapInfo);this._webMapInfo=i&&s?s[0]:!t?.id&&this.mapInfos.length>0?this.mapInfos[0]:t;const h=this._webMapInfo.id,a=i&&t?.id===this.defaultWebmapId;if(this._loadedId!==h&&!i||a){const t=new this.WebMap({portalItem:{id:h}});this.appProxies&&(await t.load(),await(o=t,l=this.esriConfig,n=this.appProxies,n&&n.forEach((t=>{o.allLayers.forEach((i=>{i&&i.url===t.sourceUrl&&(i.url=v(t.proxyUrl),i.portalItem&&i.portalItem.when((()=>{i.portalItem.url=v(t.proxyUrl)})),l.request?.interceptors?.push({urls:t.sourceUrl,before:i=>{i.url&&i.url===t.sourceUrl&&(i.url=v(t.proxyUrl))}}))}))})),o)),this.mapView=new this.MapView({container:this._mapDiv,map:t,resizeAlign:"center"}),this._loadedId=h,this._searchConfiguration=this._webMapInfo.searchConfiguration,this.beforeMapChanged.emit(),await this.mapView.when((()=>{this._initHome(),this.mapView.ui.add(this._mapTools,{position:this.mapWidgetsPosition,index:this.mapWidgetsIndex}),this._defaultWebmapHonored=!!a||this._defaultWebmapHonored,this.mapChanged.emit({id:h,mapView:this.mapView})}))}else i?(this._defaultWebmapHonored=!0,this._mapPicker.setMapByID(h)):e&&(this._searchConfiguration=this._webMapInfo.searchConfiguration,this.beforeMapChanged.emit(),this.mapChanged.emit({id:h,mapView:this.mapView}));var o,l,n;this._updateShareUrl()}_updateToolbar(){this._timeout&&clearTimeout(this._timeout),!this.isMobile&&this._toolbar&&this._toolInfos&&(this._timeout=setTimeout((()=>{clearTimeout(this._timeout),this._setToolbarSizeInfos();const t=this._toolbar.offsetWidth;let i=this._toolbarSizeInfos.reduce(((t,i)=>t+i.width),0);const s=["solutions-more","solutions-map-layer-picker-container","map-picker","solutions-action-share"];if(i>t){if(this._toolbarSizeInfos.length>0){const e=[...this._toolbarSizeInfos].reverse().reduce(((e,h)=>(s.indexOf(h.id)<0&&(i>t?i-=h.width:e.push(h)),e)),[]).reverse();this._setControlsThatFit(e,s)}}else if(this._defaultVisibleToolSizeInfos){const e=this._toolbarSizeInfos.reduce(((t,i)=>(t.push(i.id),t)),[]);let h=!1;const a=[...this._defaultVisibleToolSizeInfos].reduce(((a,o)=>(!h&&s.indexOf(o.id)<0&&(e.indexOf(o.id)>-1||i+o.width<=t)?(e.indexOf(o.id)<0&&(i+=o.width),a.push(o)):s.indexOf(o.id)<0&&i+o.width>t&&(h=!0),a)),[]);this._setControlsThatFit(a,s)}}),250))}_setControlsThatFit(t,i){let s=JSON.stringify(t)!==JSON.stringify(this._controlsThatFit);const e=document.getElementById("solutions-action-bar");e?.childNodes?.forEach((t=>{i.indexOf(t.id)<0&&!s&&(s=this._controlsThatFit.map((t=>t.id)).indexOf(t.id)<0)})),s&&(this._controlsThatFit=[...t])}_setToolbarSizeInfos(){let t=!1;this._toolbarSizeInfos=[],this._toolbar.childNodes.forEach(((i,s)=>{0===s?i.childNodes.forEach((i=>{this._toolbarSizeInfos.push({id:i.id,width:i.offsetWidth}),t||(t=i.offsetWidth>0)})):i.referenceElement||(this._toolbarSizeInfos.push({id:i.id,width:i.offsetWidth}),t||(t=i.offsetWidth>0))})),t&&!this._defaultVisibleToolSizeInfos&&(this._defaultVisibleToolSizeInfos=[...this._toolbarSizeInfos])}_getActionBar(){const t=this.mapInfos?.length>1?"":"display-none",i=this.isMapLayout?"display-flex":"display-block",s=this.isMobile?"border-top":"",h=this.isMapLayout?"":"display-none";return e("calcite-action-bar",{class:i,expandDisabled:!0,expanded:!0,id:this._getId("bar"),layout:"horizontal"},e("map-picker",{class:t,isMapLayout:this.isMapLayout,mapInfos:this.mapInfos,ref:t=>this._mapPicker=t}),e("div",{class:`mapView-header display-flex ${h}`},e("div",{class:`border-end ${i} ${s}`,id:"solutions-map-layer-picker-container"},this.mapView&&e("map-layer-picker",{appearance:"transparent",defaultLayerId:this.defaultLayerId,display:"inline-flex",height:50,isMobile:this.isMobile,mapView:this.mapView,onlyShowUpdatableLayers:this.onlyShowUpdatableLayers,placeholderIcon:"layers",ref:t=>this._mapLayerPicker=t,scale:"l",selectedIds:this.selectedLayer?[this.selectedLayer.id]:[],showSingleLayerAsLabel:!0,showTables:!0,showTablesDisabled:!0,type:"dropdown"}))),!this.isMobile&&this.isMapLayout?this._getActions():void 0)}_getDropdown(t){const i=this._getDropdownItems();return i.length>0?e("calcite-dropdown",{closeOnSelectDisabled:!0,disabled:void 0===this.selectedLayer,id:"solutions-more",onCalciteDropdownBeforeClose:()=>this._forceShowHide(),ref:t=>this._moreDropdown=t},e("calcite-action",{appearance:"solid",id:t,label:"",onClick:()=>this._closeShowHide(),slot:"trigger",text:""},e("calcite-button",{appearance:"transparent",iconEnd:"chevron-down",kind:"neutral"},this._translations.more)),e("calcite-dropdown-group",{"selection-mode":"none"},i.map((t=>e("calcite-dropdown-group",{class:t.disabled?"disabled":"",selectionMode:"none"},e("calcite-dropdown-item",{disabled:t.loading,iconStart:t.icon,id:"solutions-subset-list",onClick:t.func},t.loading?e("div",{class:"display-flex"},e("calcite-loader",{inline:!0,label:t.label,scale:"m"}),t.label):t.label)))))):void 0}_getShare(t){return e("div",{class:"share-action",id:this._getId(t)},e("instant-apps-social-share",{autoUpdateShareUrl:!1,class:"instant-app-share",embed:this.shareIncludeEmbed,popoverButtonIconScale:"s",ref:t=>{this._shareNode=t,this._updateShareUrl()},scale:"m",shareButtonColor:"neutral",shareButtonType:"action",socialMedia:this.shareIncludeSocial,view:this.mapView}),this._getToolTip("bottom",t,this._translations.share))}_updateShareUrl(){const t=this._shareNode?.shareUrl;if(!t)return;const i=new URL(t);this._loadedId?i.searchParams.set("webmap",this._loadedId):i.searchParams.delete("webmap"),this.selectedLayer?.id?i.searchParams.set("layer",this.selectedLayer.id):i.searchParams.delete("layer"),this.selectedFeaturesIds?.length>0?i.searchParams.set("oid",this.selectedFeaturesIds.join(",")):i.searchParams.delete("oid"),i.searchParams.set("applayout",this.appLayout),this._shareNode.shareUrl=i.href}_closeShowHide(){this._showHideOpen=!1}_getDropdownItems(){return this._toolInfos?.filter((t=>t&&t.isOverflow))}_initToolInfos(){const t=this.selectedFeaturesIds?.length>0,i=this._hasFilterExpressions(),s=this.selectedFeaturesIds?.length>1&&!1;this._translations&&(this._toolInfos=[{active:!1,icon:"zoom-to-object",indicator:!1,label:this._translations.zoom,func:()=>this._zoom(),disabled:!t,isOverflow:!1},i?{active:!1,icon:"filter",indicator:!1,label:this._translations.filters,func:()=>this._toggleFilter(),disabled:!1,isOverflow:!1}:void 0,s?{active:!1,icon:"pencil",indicator:!1,label:this._translations.editMultiple,func:()=>alert(this._translations.editMultiple),disabled:!s,isOverflow:!1}:void 0,{active:!1,icon:"refresh",indicator:!1,label:this._translations.refresh,func:()=>this.selectedLayer.refresh(),disabled:!1,isOverflow:!1},{active:!1,icon:"erase",indicator:!1,label:this._translations.clearSelection,func:()=>this.clearSelection.emit(),disabled:!t,isOverflow:!1}],this._defaultVisibleToolSizeInfos=void 0)}_validateActiveActions(){const t=["filter"];this._toolInfos?.forEach((i=>{i&&t.indexOf(i.icon)>-1&&"filter"===i.icon&&(i.indicator=this._filterActive)}))}_validateEnabledActions(){const t=this.selectedFeaturesIds?.length>0,i=this.selectedFeaturesIds?.length>1&&this.selectedLayer?.capabilities?.operations?.supportsUpdate,s=["zoom-to-object","pencil","erase"];this._toolInfos?.forEach((e=>{e&&s.indexOf(e.icon)>-1&&(e.disabled="pencil"===e.icon?!i:!t)}))}_initHome(){if(this.enableHome){this._homeWidget=new this.Home({view:this.mapView}),this.mapView.ui.add(this._homeWidget,{position:this.homeZoomPosition,index:this.homeZoomIndex});const t="s"===this.homeZoomToolsSize?"32px":"m"===this.homeZoomToolsSize?"40px":"48px";this._homeWidget.domNode.style.height=t,this._homeWidget.domNode.style.width=t}else this._homeWidget&&this.mapView.ui.remove(this._homeWidget)}_toggleShowHide(){this._showHideOpen=!this._showHideOpen}_forceShowHide(){this._moreDropdown&&(this._moreDropdown.open=this._showHideOpen)}_handleDocumentClick(t){const i=t.target?.id;"solutions-subset-list"===i?this._moreDropdown.open=!0:this._showHideOpen&&"solutions-subset-list"!==i&&"solutions-more"!==i&&"chevron-down"!==i&&this._moreDropdown&&(this._showHideOpen=!1,this._moreDropdown.open=!1),"MAP-PICKER"===t.target.tagName&&(this._mapListExpanded=!this._mapListExpanded,this._mapPicker.toggle(this._mapListExpanded)),"MAP-PICKER"!==t.target.tagName&&(this._mapListExpanded=!1,this._mapPicker.close())}async _zoom(){if(this.selectedLayer){const t=await b(this.mapView,this.selectedLayer.id);await c(this.selectedFeaturesIds,t,this.mapView,!0,void 0,this.zoomToScale)}}async _toggleFilter(){this.toggleFilter.emit()}_hasFilterExpressions(){let t;return this.mapInfo?.filterConfig?.layerExpressions&&this.selectedLayer?.id&&(t=this.mapInfo.filterConfig.layerExpressions.filter((t=>t.id===this.selectedLayer.id))),t?.length>0}_getActions(){const t=this._getActionItems();return t?.reduce(((t,i)=>(i&&!i.isOverflow&&t.push(this._getAction(i.active,i.icon,i.indicator,i.label,i.func,i.disabled,i.loading)),t)),[])}_getToolTip(t,i,s){return document.getElementById(i)?e("calcite-tooltip",{placement:t,"reference-element":"map-"+i},e("span",null,s)):void 0}_getActionItems(){return this._toolInfos?.filter((t=>t&&!t.isOverflow))}_getAction(t,i,s,h,a,o,l,n){const c=void 0===this.selectedLayer||o;return e("div",{class:"display-flex",id:this._getId(i),slot:n},e("calcite-action",{active:t,appearance:"solid",disabled:c,icon:i,id:"map-"+i,indicator:s,label:h,loading:l,onClick:a,text:h,textEnabled:!0}),this._getToolTip("bottom",i,h))}_getId(t){return`solutions-action-${t}`}async _getTranslations(){const t=await a(this.el);this._translations=t[0]}static get watchers(){return{appLayout:["appLayoutWatchHandler"],enableHome:["enableHomeWatchHandler"],enableShare:["enableShareWatchHandler"],mapView:["mapViewWatchHandler"],selectedLayer:["selectedLayerWatchHandler"],selectedFeaturesIds:["selectedFeaturesIdsWatchHandler"],_controlsThatFit:["_controlsThatFitWatchHandler"]}}};y.style=":host{display:block;--calcite-label-margin-bottom:0;--calcite-block-padding:0}.map-height{height:calc(100% - 53px)}.height-full{height:100%}.height-49-px{height:49px}.box-shadow{box-shadow:none !important}.visibility-hidden-1{visibility:hidden;height:1px;}.display-none{display:none}.display-block{display:block}";export{u as card_manager,m as layer_table,y as map_card}
|
@@ -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 a,g as e,h as s,H as t}from"./p-4e6eb06e.js";const r=class{constructor(e){a(this,e)}get el(){return e(this)}render(){return s(t,{key:"9d6d06f2466bbbfba74ead0dd8af4354834006c6"},s("slot",{key:"25722c28a43a7a005a0c55b16c0df536a7a19a61"}))}};r.style=":host{display:block}";export{r as feature_comments}
|
@@ -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-4e6eb06e.js";import{c as l}from"./p-747d4b59.js";const s=class{constructor(a){e(this,a),this.showAddDeduct=!1}get el(){return a(this)}_deductValuesElement;render(){const e=this.showAddDeduct?"position-relative":"display-none";return i(t,{key:"ed87d1027005d190e25bf5e1d7290e84d9d17ba0"},i("div",{key:"d9396264216f810a3bdcf5fce4872580b3abebe2",class:this.showAddDeduct?"display-none":"display-grid"},i("div",{key:"a4235f8123959cf0d27faa2146de5aec798e5179",class:"label-display"},i("calcite-label",{key:"6393ded2cce33388aed760d1a3ceefe395718020",class:"label-display"},"Enter comma delimited deduct values",this._getDeductValuesInput())),i("div",{key:"e172c646a39a69e7a69d3646389907ce561fb4ff"},this._getCalculateButton())),i("div",{key:"c9659b510e86cebd0170dc73a1ba5afc3173dc8a",class:e},i("div",{key:"45a9b444a79863644a330e72598ce7c33565db77",class:"position-right"},i("calcite-action",{key:"250c4da105f5d33f058d7770e83e4c6d89741f90",appearance:"transparent",class:"float-end",icon:"x",onClick:()=>this._toggleShowAddDeduct(),scale:"s",text:""})),i("deduct-calculator",{key:"b51cb55ab07b8e5556e6eb6e04d23d7e1b767850",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")}};s.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{s as pci_calculator}
|