@esri/solutions-components 5.1.0-next.145 → 5.1.0-next.147
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/{LL647FJR.js → 2IGILR4T.js} +1 -1
- package/dist/cdn/{BQE6IVEF.js → 3A2YSBVB.js} +1 -1
- package/dist/cdn/{ZHXREM2D.js → 3KYQE6O5.js} +1 -1
- package/dist/cdn/{MEZL3ZHS.js → 3MRR3HKE.js} +25 -25
- package/dist/cdn/{QKJJHBMB.js → 42GXADY4.js} +1 -1
- package/dist/cdn/{L3UI7EZZ.js → 4DAGSZIC.js} +1 -1
- package/dist/cdn/{7ADKNWWI.js → 4FRYNYQ6.js} +1 -1
- package/dist/cdn/{5OFQVDNK.js → 4MAZNAHZ.js} +1 -1
- package/dist/cdn/{7CLM77HQ.js → 4SBOBTOR.js} +1 -1
- package/dist/cdn/{3V2UWENT.js → 4YCLQ3RW.js} +1 -1
- package/dist/cdn/{CVRBLJ5O.js → 5MPDXVRM.js} +1 -1
- package/dist/cdn/{ULUJKWT5.js → 6AUKNSKW.js} +1 -1
- package/dist/cdn/{RIHOGDUV.js → 6IUKH3E3.js} +1 -1
- package/dist/cdn/6K3C5JX2.js +2 -0
- package/dist/cdn/6VCG2ITQ.js +2 -0
- package/dist/cdn/{NOXANMDF.js → 757HAEJS.js} +1 -1
- package/dist/cdn/{P4XNRWG7.js → 7Q5BT35O.js} +1 -1
- package/dist/cdn/{RSCBZIAN.js → 7WIFBTQF.js} +12 -1
- package/dist/cdn/{I7XBRB6B.js → 7WYPODAB.js} +1 -1
- package/dist/cdn/AH3PJQ6A.js +2 -0
- package/dist/cdn/{C5ZH23YO.js → B5MBF4JC.js} +13 -13
- package/dist/cdn/BG4LNU44.js +2 -0
- package/dist/cdn/{IEN3TA4W.js → BH42V5CR.js} +1 -1
- package/dist/cdn/DD2Y5NOB.js +2 -0
- package/dist/cdn/{J5K2SIY6.js → DMM5WA5Q.js} +3 -3
- package/dist/cdn/{UKQPYE7U.js → DQQTSOMQ.js} +1 -1
- package/dist/cdn/{Y4KGXRSD.js → FWLPMS4Q.js} +1 -1
- package/dist/cdn/{M4II4TSX.js → G3C6IL5Y.js} +1 -1
- package/dist/cdn/{3DCFUYKP.js → GG4IIHQE.js} +1 -1
- package/dist/cdn/{MHVLVLRA.js → HYQVSB6C.js} +1 -1
- package/dist/cdn/I46CXTVR.js +2 -0
- package/dist/cdn/{A27DLHRU.js → IFONVCBL.js} +1 -1
- package/dist/cdn/IZSM7ZJK.js +2 -0
- package/dist/cdn/{MIH5YMTN.js → JMBANG5V.js} +1 -1
- package/dist/cdn/{G3F52QRW.js → JOAEH3CI.js} +1 -1
- package/dist/cdn/KETYOYXQ.js +2 -0
- package/dist/cdn/{GJD7AOUI.js → KH5WPLZK.js} +1 -1
- package/dist/cdn/{IDEOFV22.js → LTLR4VF3.js} +1 -1
- package/dist/cdn/{NIHPHDXG.js → LWT3JEQ6.js} +21 -52
- package/dist/cdn/LZDMYPQ2.js +75 -0
- package/dist/cdn/{Y6QJCLML.js → M3NML7ZV.js} +1 -1
- package/dist/cdn/NQH7ZZWD.js +2 -0
- package/dist/cdn/{6MOTC6CE.js → NV2DLQDN.js} +1 -1
- package/dist/cdn/OANAQ6HY.js +2 -0
- package/dist/cdn/PQL3UL3P.js +2 -0
- package/dist/cdn/{L6P26BYB.js → Q2DJUFVO.js} +1 -1
- package/dist/cdn/{LCV5GKUD.js → Q35DDH7J.js} +123 -123
- package/dist/cdn/QDKHYQJB.js +2 -0
- package/dist/cdn/{HPWNNMVU.js → QU25YPPX.js} +1 -1
- package/dist/cdn/{5NQNJZTE.js → RMO244NW.js} +1 -1
- package/dist/cdn/{HLKEBN2O.js → RRD4QUQS.js} +1 -1
- package/dist/cdn/RY6KZ77P.js +2 -0
- package/dist/cdn/{PBGG3TGN.js → RYBSWXQQ.js} +1 -1
- package/dist/cdn/{2UMMLVCR.js → SYQ5E5TV.js} +1 -1
- package/dist/cdn/U56TK45K.js +113 -0
- package/dist/cdn/{UM3P3Q52.js → U6JZYJ4D.js} +1 -1
- package/dist/cdn/UBEU6ULP.js +2 -0
- package/dist/cdn/{MPCJZCL5.js → UTZUXO5F.js} +2 -2
- package/dist/cdn/UXKH44PB.js +2 -0
- package/dist/cdn/{34CZ4EWR.js → V3MSUKLX.js} +6 -4
- package/dist/cdn/{2PUK3PST.js → W7I22AW3.js} +1 -1
- package/dist/cdn/{72X4E4QW.js → WC37HMOI.js} +1 -1
- package/dist/cdn/{RUQ4RO4T.js → WUEJANIZ.js} +1 -1
- package/dist/cdn/{LJY6BB64.js → X6JL6SAH.js} +1 -1
- package/dist/cdn/{XGYNSCTA.js → Y37QLEAM.js} +1 -1
- package/dist/cdn/{XGWDWPRK.js → YFJZN5K5.js} +1 -1
- package/dist/cdn/{6T35OGRG.js → YTU2BYBP.js} +1 -1
- package/dist/cdn/{5LF6C3S5.js → YWALGZAG.js} +1 -1
- package/dist/cdn/{QFZK4TD4.js → Z23BVIGQ.js} +1 -1
- package/dist/cdn/{QQXQAU33.js → ZCPVOS4Q.js} +1 -1
- package/dist/cdn/{F26SXWZ5.js → ZNH7LRND.js} +1 -1
- package/dist/cdn/{BMMIXOTR.js → ZWQWBXHR.js} +1 -1
- package/dist/cdn/index.js +1 -1
- package/dist/chunks/Auth.js +1 -1
- package/dist/chunks/assessBuildRequest.js +116 -0
- package/dist/chunks/assessUpdateRequest.js +78 -0
- package/dist/chunks/assistantResponse.js +12 -1
- package/dist/chunks/classifyIntent.js +21 -52
- package/dist/chunks/deployFlowController.js +1 -1
- package/dist/chunks/designSolution.js +6 -4
- package/dist/chunks/helpers.js +47 -43
- package/dist/chunks/interfaces.js +105 -102
- package/dist/chunks/solution-builder-assistant.js +185 -121
- package/dist/chunks/solution-deploy-dialog.js +4 -4
- package/dist/chunks/solutions-deploy-app-nav.js +2 -2
- package/dist/chunks/templates.js +2 -2
- package/dist/chunks/updateDesign.js +1 -1
- package/dist/components/arcgis-solutions-assistant/customElement.js +340 -278
- package/dist/components/arcgis-solutions-assistant/index.js +1 -0
- package/dist/components/card-manager/customElement.js +8 -8
- package/dist/components/create-feature/customElement.js +107 -113
- package/dist/components/crowdsource-reporter/customElement.js +1 -1
- package/dist/components/layer-table/customElement.d.ts +3 -0
- package/dist/components/layer-table/customElement.js +110 -100
- package/dist/components/solution-configure-titles/customElement.js +11 -10
- package/dist/components/solution-delete-dialog/customElement.js +9 -8
- package/dist/components/solution-deploy-dialog/customElement.d.ts +6 -2
- package/dist/components/solution-deployed-card-panel/customElement.js +40 -37
- package/dist/components/solution-details-card/customElement.js +1 -1
- package/dist/components/solution-details-panel/customElement.js +78 -64
- package/dist/components/solution-item-diagram/customElement.js +321 -285
- package/dist/components/solution-resource-card/customElement.js +1 -1
- package/dist/components/solution-snapshot-gallery/customElement.js +1 -1
- package/dist/components/solutions-all-panel/customElement.js +5 -5
- package/dist/components/solutions-deploy-app/customElement.js +13 -15
- package/dist/components/solutions-deployed-panel/customElement.js +7 -7
- package/dist/components/solutions-deployed-shell/customElement.js +1 -1
- package/dist/components/solutions-filter-panel/customElement.js +1 -1
- package/dist/components/solutions-searchsort-toolbar/customElement.js +1 -1
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/solutions-components_commit.txt +5 -8
- package/dist/types/lumina.d.ts +1 -0
- package/dist/types/preact.d.ts +1 -0
- package/dist/types/react.d.ts +1 -0
- package/dist/types/stencil.d.ts +1 -0
- package/package.json +1 -1
- package/dist/cdn/25NZZKXC.js +0 -2
- package/dist/cdn/3JQ2RXVJ.js +0 -2
- package/dist/cdn/4JVDUPVW.js +0 -2
- package/dist/cdn/54AE7WD2.js +0 -2
- package/dist/cdn/56A5UMZG.js +0 -9
- package/dist/cdn/AZN2E5DL.js +0 -2
- package/dist/cdn/DFZZNKPK.js +0 -76
- package/dist/cdn/G3FTF6WH.js +0 -2
- package/dist/cdn/KDNGZ47C.js +0 -2
- package/dist/cdn/NIYB3TEW.js +0 -2
- package/dist/cdn/PBMTIFFX.js +0 -2
- package/dist/cdn/PECGJO2P.js +0 -2
- package/dist/cdn/Q5TICZRX.js +0 -15
- package/dist/cdn/QGCF64WY.js +0 -2
- package/dist/cdn/VO53567V.js +0 -2
- package/dist/cdn/WKS3TKDC.js +0 -2
- package/dist/cdn/YVIEKHQQ.js +0 -2
- package/dist/cdn/Z3B5KW2S.js +0 -2
- package/dist/chunks/initialAssessment.js +0 -79
- package/dist/chunks/responseOptionsBuilderExclusion.js +0 -12
- package/dist/chunks/responseOptionsDefault.js +0 -18
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import { c as
|
|
3
|
-
import { e as I, g as
|
|
4
|
-
import { b as
|
|
5
|
-
import { d as
|
|
6
|
-
import { b } from "../../chunks/interfaces.js";
|
|
7
|
-
import { defineCustomElements as
|
|
8
|
-
import { u as
|
|
9
|
-
import { css as
|
|
10
|
-
import { createRef as
|
|
11
|
-
import { LitElement as
|
|
12
|
-
import { f as
|
|
13
|
-
import
|
|
14
|
-
import * as
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
const
|
|
18
|
-
class
|
|
2
|
+
import { c as v } from "../../chunks/runtime.js";
|
|
3
|
+
import { e as I, g as T, c as E } from "../../chunks/mapViewUtils.js";
|
|
4
|
+
import { b as x } from "../../chunks/queryUtils.js";
|
|
5
|
+
import { d as F } from "../../chunks/downloadUtils.js";
|
|
6
|
+
import { b as g } from "../../chunks/interfaces.js";
|
|
7
|
+
import { defineCustomElements as S } from "@arcgis/instant-apps-components/loader";
|
|
8
|
+
import { u as O } from "../../chunks/useT9n.js";
|
|
9
|
+
import { css as C, html as o, nothing as u } from "lit";
|
|
10
|
+
import { createRef as y, ref as b } from "lit-html/directives/ref.js";
|
|
11
|
+
import { LitElement as A, createEvent as c, noShadowRoot as H, safeClassMap as m } from "@arcgis/lumina";
|
|
12
|
+
import { f as L } from "../../chunks/helpers.js";
|
|
13
|
+
import $ from "@arcgis/core/widgets/FeatureTable.js";
|
|
14
|
+
import * as p from "@arcgis/core/core/reactiveUtils.js";
|
|
15
|
+
import D from "@arcgis/core/rest/support/RelationshipQuery.js";
|
|
16
|
+
import w from "@arcgis/core/widgets/FeatureTable/support/TableTemplate.js";
|
|
17
|
+
const M = C`@layer{:host{display:block}.height-full{height:100%}.height-full-adjusted{height:calc(100% - 20px)}.width-full{width:100%}.display-flex{display:flex}.display-none{display:none}.table-border{border:1px solid var(--calcite-color-border-2)}.border-end{border-inline-end:1px solid var(--calcite-color-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51-px{height:51px}.height-50-px{height:50px}.bottom-left{position:absolute;left:0;bottom:0;padding-left:5px}html[dir=rtl] .bottom-left{position:absolute;right:0;bottom:0;padding-right:5px}.height-19{height:19px}.background{background-color:var(--calcite-color-surface-1)}.text-color{color:var(--calcite-color-text-1)}.align-center{align-items:center}.danger-color{color:var(--calcite-color-status-danger)}.esri-feature-table vaadin-grid{border:none!important}vaadin-grid-cell-content{font-size:14px!important;color:var(--calcite-color-text-3)!important}.absolute-right{position:absolute;right:0;left:unset}html[dir=rtl] .absolute-right{left:0;right:unset}.disabled{cursor:default!important;user-select:none;opacity:var(--calcite-opacity-disabled);pointer-events:none}.actions-end{height:50px!important;display:inline-flex}.border-top{border-top:1px solid var(--calcite-color-border-2)}.modal{--calcite-dialog-content-space: 0}.esri-feature-table__table-container{height:100%}.search-container{background-color:var(--calcite-color-surface-2)!important}.search{--calcite-color-border-input: var(--calcite-color-border-3);width:60%;padding:10px}.delete-red{--calcite-icon-color: var(--calcite-color-status-danger);--calcite-color-text-1: var(--calcite-color-status-danger);--calcite-color-text-3: var(--calcite-color-status-danger)}.label-override{white-space:nowrap}.padding-start-1-4{padding-inline-start:.5rem}.panel-header-override{--calcite-panel-header-content-space: 0px}.danger-label-color{color:var(--calcite-color-status-danger)}.danger-icon-color{--calcite-icon-color: var(--calcite-color-status-danger)}.width-51{width:51px}.height-51{height:51px}calcite-action-bar{--calcite-internal-action-bar-gap: 0px;--calcite-internal-action-bar-padding: 0px}}`;
|
|
18
|
+
class R extends A {
|
|
19
19
|
constructor() {
|
|
20
|
-
super(), this.defaultGlobalId = [], this.defaultLayerId = "", this.defaultOid = [], this.enableAutoRefresh = !1, this.enableColumnReorder = !0, this.enableCSV = !1, this.enableInlineEdit = !1, this.enableShare = !1, this.enableTableAutosave = !0, this.featureSelectionMode = "multiple", this.selectedRelatedIds = [], this.honorMapFieldSettings = !1, this.isMobile = !1, this.mapHidden = !1, this.showOnlyUpdatableLayers = !1, this.selectedIds = [], this.shareIncludeEmbed = !1, this.shareIncludeSocial = !1, this.showNewestFirst = !1, this.zoomAndScrollToSelected = !1, this.pasteEnabled = !1, this.showCopyPasteActions = !1, this.layerIds = [], this._allIds = [], this._configLayerOrderDefined = !1, this._csvExporting = !1, this._fetchingData = !1, this._hideTable = !1, this._filterActive = !1, this._selectAllActive = !1, this._showHideOpen = !1, this._showOnlySelected = !1, this._toolInfos = [], this._translations =
|
|
20
|
+
super(), this.defaultGlobalId = [], this.defaultLayerId = "", this.defaultOid = [], this.enableAutoRefresh = !1, this.enableColumnReorder = !0, this.enableCSV = !1, this.enableInlineEdit = !1, this.enableShare = !1, this.enableTableAutosave = !0, this.featureSelectionMode = "multiple", this.selectedRelatedIds = [], this.honorMapFieldSettings = !1, this.isMobile = !1, this.mapHidden = !1, this.showOnlyUpdatableLayers = !1, this.selectedIds = [], this.shareIncludeEmbed = !1, this.shareIncludeSocial = !1, this.showNewestFirst = !1, this.zoomAndScrollToSelected = !1, this.pasteEnabled = !1, this.showCopyPasteActions = !1, this.layerIds = [], this._allIds = [], this._configLayerOrderDefined = !1, this._csvExporting = !1, this._fetchingData = !1, this._hideTable = !1, this._filterActive = !1, this._selectAllActive = !1, this._showHideOpen = !1, this._showOnlySelected = !1, this._toolInfos = [], this._translations = O({ name: "layer-table", blocking: !0 }), this._fullTextSearchInfo = [], this._searchPlaceHolder = "", this._size = 0, this._queryingData = !1, this._editEnabled = !1, this._enabledLayerIds = [], this._defaultGlobalIdHonored = !1, this._defaultOidHonored = !1, this._deleteEnabled = !1, this._floorExpression = "", this._floorField = "", this._floorLevel = "", this._loaded = !1, this._shareNode = y(), this._toolbar = y(), this._searchExpression = "", this._skipEditCheck = !1, this._tempSelectedIds = [], this._outOFExtentOids = [], this._shouldUpdateTableOnExtentChange = !0, this._creatingFeature = !1, this._searchNode = y(), this._layerEditsHandles = [], this._pastedFeaturesIds = [], this._shouldSelectCreatedFeatures = !1, this.columnReorder = c(), this.featureSelectionChange = c(), this.toggleFilter = c(), this.showDelete = c(), this.relatedRecordToggled = c(), this.editMultipleFeatures = c(), this.copyFeatures = c(), this.pasteFeatures = c(), this.featuresAdded = c(), this.initCreateComponent = c(), this.requestLayerSelectionChange = c(), this.listenOn(window, "beforeMapInfoChange", this.beforeMapInfoChange, { capture: !0 }), this.listenOn(window, "editorInitialized", this.editorInitialized), this.listenOn(window, "closeEdit", this.closeEdit), this.listenOn(window, "selectionChanged", this.selectionChanged), this.listenOn(window, "beforeLayerSelectionChange", this.beforeLayerSelectionChange), this.listenOn(window, "layerSelectionChange", this.layerSelectionChange), this.listenOn(window, "editsComplete", this.editsComplete), this.listenOn(window, "facilityChanged", this.facilityChanged), this.listenOn(window, "levelChanged", this.levelChanged), this.listenOn(window, "siteChanged", this.siteChanged), this.listenOn(window, "noLayersFound", this.noLayersFound), this.listenOn(window, "clearSelection", this.clearSelection), this.listenOn(window, "mapChanged", this.mapChanged), this.listenOn(window, "featuresSelected", this.featuresSelected), this.listenOn(window, "createWorkFlowStarted", this.createWorkFlowStarted), this.listenOn(window, "backFromCreateWorkFlow", this.backFromCreateWorkFlow), this.listenOn(window, "pasteFeatures", this._pasteFeatures), this.listenOn(window, "featuresPasted", this._featuresPasted), S(window);
|
|
21
21
|
}
|
|
22
22
|
static {
|
|
23
23
|
this.properties = { appLayout: 1, defaultGlobalId: 0, defaultLayerId: 1, defaultOid: 0, enableAutoRefresh: 5, enableColumnReorder: 5, enableCSV: 5, enableInlineEdit: 5, enableShare: 5, enableTableAutosave: 5, featureSelectionMode: 1, selectedRelatedIds: 0, honorMapFieldSettings: 5, isMobile: 5, mapHidden: 5, mapInfo: 0, mapView: 0, showOnlyUpdatableLayers: 5, selectedIds: 0, shareIncludeEmbed: 5, shareIncludeSocial: 5, showNewestFirst: 5, zoomAndScrollToSelected: 5, zoomToScale: 9, pasteEnabled: 5, showCopyPasteActions: 5, layerIds: 0, _allIds: 16, _configLayerOrderDefined: 16, _csvExporting: 16, _fetchingData: 16, _hideTable: 16, _filterActive: 16, _layer: 16, _selectAllActive: 16, _showHideOpen: 16, _showOnlySelected: 16, _toolInfos: 16, _translations: 16, _fullTextSearchInfo: 16, _searchPlaceHolder: 16, _size: 16, _queryingData: 16 };
|
|
24
24
|
}
|
|
25
25
|
static {
|
|
26
|
-
this.styles =
|
|
26
|
+
this.styles = M;
|
|
27
27
|
}
|
|
28
28
|
static {
|
|
29
|
-
this.shadowRootOptions =
|
|
29
|
+
this.shadowRootOptions = H;
|
|
30
30
|
}
|
|
31
31
|
willUpdate(e) {
|
|
32
32
|
if (e.has("appLayout") && this.appLayoutWatchHandler(), e.has("defaultOid") && this.defaultOidWatchHandler(), e.has("defaultGlobalId") && this.defaultGlobalIdWatchHandler(), e.has("enableCSV") && this.enableCSVWatchHandler(), e.has("enableInlineEdit") && this.enableInlineEditWatchHandler(), e.has("mapHidden") && this.mapHiddenWatchHandler(), e.has("isMobile") && this.isMobileWatchHandler(), e.has("mapInfo") && this.mapInfoWatchHandler(), e.has("mapView") && this.mapViewWatchHandler(), e.has("_layer") && this._layerWatchHandler(), e.has("selectedIds") && (this.hasUpdated || JSON.stringify(e.get("selectedIds")) !== JSON.stringify(this.selectedIds)) && this.selectedIdsWatchHandler(), e.has("selectedRelatedIds") && (this.hasUpdated || JSON.stringify(e.get("selectedRelatedIds")) !== JSON.stringify(this.selectedRelatedIds)) && this.selectedRelatedIdsWatchHandler(), e.has("enableTableAutosave") && this.hasUpdated && this._table && (this._table.autoSaveEnabled = this.enableTableAutosave), e.has("_translations")) {
|
|
@@ -61,7 +61,7 @@ class M extends C {
|
|
|
61
61
|
!this._toolInfos && !this.isMobile && await this._initToolInfos();
|
|
62
62
|
}
|
|
63
63
|
async mapInfoWatchHandler() {
|
|
64
|
-
this._configLayerOrderDefined = "configLayerOrder" in (this.mapInfo?.layerOptions || {}), this._enabledLayerIds =
|
|
64
|
+
this._configLayerOrderDefined = "configLayerOrder" in (this.mapInfo?.layerOptions || {}), this._enabledLayerIds = L(this.mapInfo?.layerOptions?.layers || [], this.mapInfo?.layerOptions?.configLayerOrder), this._table && (this._resetColumnTemplates(), this._sortTable(), await this._initToolInfos());
|
|
65
65
|
}
|
|
66
66
|
async mapViewWatchHandler() {
|
|
67
67
|
this._mapClickHandle && this._mapClickHandle.remove(), this.mapView && (this._floorExpression = "", this._searchExpression = "", this.mapView.highlights = [
|
|
@@ -77,7 +77,7 @@ class M extends C {
|
|
|
77
77
|
name: "temporary",
|
|
78
78
|
color: "#FFFF00"
|
|
79
79
|
}
|
|
80
|
-
], this._updateShareUrl(), this._mapClickHandle =
|
|
80
|
+
], this._updateShareUrl(), this._mapClickHandle = p.on(() => this.mapView, "click", (e) => {
|
|
81
81
|
this._creatingFeature || this._mapClicked(e);
|
|
82
82
|
}));
|
|
83
83
|
}
|
|
@@ -144,7 +144,7 @@ class M extends C {
|
|
|
144
144
|
s.scrollToIndex(a);
|
|
145
145
|
const l = t.layer, h = this.mapView.allLayerViews.toArray();
|
|
146
146
|
let r;
|
|
147
|
-
h.some(async (
|
|
147
|
+
h.some(async (n) => n.layer.title === l?.title && n.layer.type === "feature" ? (r = n, this.mapView && await I([i], r, this.mapView, !0, void 0, this.zoomToScale), !0) : !1);
|
|
148
148
|
}
|
|
149
149
|
}
|
|
150
150
|
async beforeLayerSelectionChange(e) {
|
|
@@ -195,16 +195,16 @@ class M extends C {
|
|
|
195
195
|
this._layer?.isTable || this._zoom();
|
|
196
196
|
}
|
|
197
197
|
_featuresPasted() {
|
|
198
|
-
this.
|
|
198
|
+
this._shouldSelectCreatedFeatures = !0;
|
|
199
199
|
}
|
|
200
200
|
async load() {
|
|
201
201
|
await this._initToolInfos();
|
|
202
202
|
}
|
|
203
203
|
render() {
|
|
204
204
|
const e = this._fetchingData || this._hideTable ? "display-none" : "height-full", t = this._fetchingData ? "" : "display-none", i = this._queryingData ? "" : "display-none", s = this._size.toString(), a = this.selectedIds.length.toString(), l = this.isMobile ? "height-full" : "height-full-adjusted", h = this._canShowFullTextSearch();
|
|
205
|
-
return this._validateActiveActions(), o`<div><calcite-scrim class=${
|
|
205
|
+
return this._validateActiveActions(), o`<div><calcite-scrim class=${m(i)} .loading=${this._queryingData}></calcite-scrim><calcite-shell><div class=${`width-full ${l}`}><calcite-panel class="height-full width-full panel-header-override">${this._getMapLayerPicker("header-actions-start")}${!this.isMobile && o`${this._getTableControlRow("header-content")}${this._getActionsEnd("header-actions-end")}` || ""}${h && o`<div class="search-container border-bottom"><calcite-input class=search clearable icon=search @calciteInputChange=${(r) => {
|
|
206
206
|
this._searchTextChanged(r);
|
|
207
|
-
}} .placeholder=${this._searchPlaceHolder} title=${this._searchPlaceHolder ??
|
|
207
|
+
}} .placeholder=${this._searchPlaceHolder} title=${this._searchPlaceHolder ?? u} type=search ${b(this._searchNode)}></calcite-input></div>` || ""}<calcite-loader class=${m(t)} .label=${this._translations.fetchingData} scale=l></calcite-loader><div class=${m(e)} ${b(this.onTableNodeCreate)}></div></calcite-panel></div>${this.isMobile ? void 0 : o`<div class="bottom-left text-color height-19" id=solutions-selected-count-div>${(this._translations.recordsTotal?.replace("{{total-number-of-records}}", s) + " | " + this._translations.recordsSelected.replace("{{selected-number-of-records}}", a)).replace("{{total}}", s).replace("{{selected}}", a)}</div>`}</calcite-shell></div>`;
|
|
208
208
|
}
|
|
209
209
|
updated() {
|
|
210
210
|
this._table && this.updateRelatedAttachmentColumns();
|
|
@@ -268,7 +268,7 @@ class M extends C {
|
|
|
268
268
|
}
|
|
269
269
|
_getMapLayerPicker(e) {
|
|
270
270
|
const t = this.isMobile ? "display-none" : "";
|
|
271
|
-
return o`<div class=${`border-end ${t}`} id=solutions-map-layer-picker-container slot=${e ??
|
|
271
|
+
return o`<div class=${`border-end ${t}`} id=solutions-map-layer-picker-container slot=${e ?? u}><map-layer-picker appearance=transparent .configLayerOrderDefined=${this._configLayerOrderDefined} .defaultLayerId=${this.defaultLayerId} display=inline-flex .enabledLayerIds=${this._enabledLayerIds} height=50 .isMobile=${this.isMobile} .mapView=${this.mapView} .showOnlyUpdatableLayers=${this.showOnlyUpdatableLayers} placeholder-icon=layers scale=l .selectedIds=${this._layer ? [this._layer?.id] : []} show-single-layer-as-label show-tables type=dropdown></map-layer-picker></div>`;
|
|
272
272
|
}
|
|
273
273
|
_getLayerOption(e) {
|
|
274
274
|
let t;
|
|
@@ -277,13 +277,13 @@ class M extends C {
|
|
|
277
277
|
_getActionsEnd(e) {
|
|
278
278
|
const t = this._relatedFeatureTable ? this._relatedFeatureTable.layer : this._layer, i = this._relatedFeatureTable || this._table;
|
|
279
279
|
let s = this._getLayerOption(t?.id || "");
|
|
280
|
-
return o`<div class="display-flex" slot=${e ??
|
|
280
|
+
return o`<div class="display-flex" slot=${e ?? u}><field-selection .configExtraFields=${s?.extraFields} .layer=${t} .mapView=${this.mapView} .table=${i} .tableRef=${this.el}></field-selection>${this.enableShare && !this.isMobile ? this._getShare("share") : void 0}</div>`;
|
|
281
281
|
}
|
|
282
282
|
_getTableControlRow(e) {
|
|
283
|
-
return o`<div class=${"height-51-px width-full display-flex"} slot=${e ??
|
|
283
|
+
return o`<div class=${"height-51-px width-full display-flex"} slot=${e ?? u} ${b(this._toolbar)}>${this._getActionBar()}</div>`;
|
|
284
284
|
}
|
|
285
285
|
_getActionBar() {
|
|
286
|
-
return o`<calcite-action-bar class=width-full expand-disabled id=${this._getId("bar") ??
|
|
286
|
+
return o`<calcite-action-bar class=width-full expand-disabled id=${this._getId("bar") ?? u} layout=horizontal><calcite-action-group>${this.isMobile ? void 0 : this._getActions()}</calcite-action-group></calcite-action-bar>`;
|
|
287
287
|
}
|
|
288
288
|
_getActions() {
|
|
289
289
|
return this._toolInfos?.reduce((e, t) => (t && e.push(t.isDanger ? this._getDangerAction(t.icon, t.label, t.func, t.disabled) : this._getAction(t.active, t.icon, t.indicator, t.label, t.func, t.disabled, !!t.loading, t.toolTip)), e), []);
|
|
@@ -291,7 +291,7 @@ class M extends C {
|
|
|
291
291
|
_validateEnabledActions() {
|
|
292
292
|
const e = this._getIds().length, t = ["zoom-to-object", "pencil", "trash", "erase", "selected-items-filter", "copy"];
|
|
293
293
|
this._toolInfos?.forEach((i) => {
|
|
294
|
-
i && t.indexOf(i.icon) > -1 && (i.disabled = i.icon === "pencil" ? e < 2 || e >
|
|
294
|
+
i && t.indexOf(i.icon) > -1 && (i.disabled = i.icon === "pencil" ? e < 2 || e > g : e < 1, i.toolTip = i.icon === "pencil" ? e > g ? this._translations.featureEditLimitNotice : this._translations.editMultiple : i.toolTip);
|
|
295
295
|
});
|
|
296
296
|
}
|
|
297
297
|
_validateActiveActions() {
|
|
@@ -301,14 +301,14 @@ class M extends C {
|
|
|
301
301
|
});
|
|
302
302
|
}
|
|
303
303
|
async _initToolInfos() {
|
|
304
|
-
const e = this._getIds().length > 0, t = this._relatedFeatureTable ? this._relatedFeatureTable.layer.isTable : this._layer?.isTable, i = this.featureSelectionMode === "multiple" && this._layer?.capabilities?.operations.supportsUpdate, s = this._getSelectedIds().length < 2 || this._getSelectedIds().length >
|
|
305
|
-
let
|
|
304
|
+
const e = this._getIds().length > 0, t = this._relatedFeatureTable ? this._relatedFeatureTable.layer.isTable : this._layer?.isTable, i = this.featureSelectionMode === "multiple" && this._layer?.capabilities?.operations.supportsUpdate, s = this._getSelectedIds().length < 2 || this._getSelectedIds().length > g, a = !this.mapHidden && !t, l = !this._relatedFeatureTable && (!this._layer?.isTable || this._hasFilterExpressions()), h = this._featuresEmpty(), r = this.featureSelectionMode === "single";
|
|
305
|
+
let n = this.enableCSV;
|
|
306
306
|
if (this._relatedFeatureTable) {
|
|
307
307
|
const f = await this._queryRelatedFeatures();
|
|
308
|
-
|
|
308
|
+
n = f && Object.keys(f).length > 0;
|
|
309
309
|
}
|
|
310
|
-
const
|
|
311
|
-
l &&
|
|
310
|
+
const d = [];
|
|
311
|
+
l && d.push({
|
|
312
312
|
active: !1,
|
|
313
313
|
icon: "filter",
|
|
314
314
|
indicator: !1,
|
|
@@ -316,7 +316,7 @@ class M extends C {
|
|
|
316
316
|
func: () => this.toggleFilter.emit(),
|
|
317
317
|
disabled: !1,
|
|
318
318
|
toolTip: this._translations.filters
|
|
319
|
-
}), a &&
|
|
319
|
+
}), a && d.push({
|
|
320
320
|
active: !1,
|
|
321
321
|
icon: "zoom-to-object",
|
|
322
322
|
indicator: !1,
|
|
@@ -326,7 +326,7 @@ class M extends C {
|
|
|
326
326
|
},
|
|
327
327
|
disabled: !e,
|
|
328
328
|
toolTip: this._translations.zoom
|
|
329
|
-
}), i &&
|
|
329
|
+
}), i && d.push({
|
|
330
330
|
active: !1,
|
|
331
331
|
icon: "pencil",
|
|
332
332
|
indicator: !1,
|
|
@@ -334,7 +334,7 @@ class M extends C {
|
|
|
334
334
|
func: () => this.editMultipleFeatures.emit(this._getSelectedIds()),
|
|
335
335
|
disabled: s,
|
|
336
336
|
toolTip: this._translations.editMultiple
|
|
337
|
-
}), this.showCopyPasteActions && (
|
|
337
|
+
}), this.showCopyPasteActions && (d.push({
|
|
338
338
|
active: !1,
|
|
339
339
|
icon: "copy",
|
|
340
340
|
indicator: !1,
|
|
@@ -342,7 +342,7 @@ class M extends C {
|
|
|
342
342
|
func: () => this.copyFeatures.emit({ featuresIds: this._getIds(), layerId: this._layer?.id }),
|
|
343
343
|
disabled: !e,
|
|
344
344
|
toolTip: this._translations.copy
|
|
345
|
-
}),
|
|
345
|
+
}), d.push({
|
|
346
346
|
active: !1,
|
|
347
347
|
icon: "paste-with-attribute",
|
|
348
348
|
indicator: !1,
|
|
@@ -350,7 +350,7 @@ class M extends C {
|
|
|
350
350
|
func: () => this.pasteFeatures.emit(),
|
|
351
351
|
disabled: !this.pasteEnabled,
|
|
352
352
|
toolTip: this._translations.paste
|
|
353
|
-
})), this._deleteEnabled &&
|
|
353
|
+
})), this._deleteEnabled && d.push({
|
|
354
354
|
active: !1,
|
|
355
355
|
icon: "trash",
|
|
356
356
|
indicator: !1,
|
|
@@ -359,7 +359,7 @@ class M extends C {
|
|
|
359
359
|
disabled: !e,
|
|
360
360
|
isDanger: !0,
|
|
361
361
|
toolTip: this._translations.delete
|
|
362
|
-
}),
|
|
362
|
+
}), d.push({
|
|
363
363
|
active: !1,
|
|
364
364
|
icon: "erase",
|
|
365
365
|
indicator: !1,
|
|
@@ -369,7 +369,7 @@ class M extends C {
|
|
|
369
369
|
},
|
|
370
370
|
disabled: !e,
|
|
371
371
|
toolTip: this._translations.clearSelection
|
|
372
|
-
}), this._relatedFeatureTable ||
|
|
372
|
+
}), this._relatedFeatureTable || d.push({
|
|
373
373
|
active: !1,
|
|
374
374
|
icon: "selected-items-filter",
|
|
375
375
|
indicator: !1,
|
|
@@ -377,7 +377,7 @@ class M extends C {
|
|
|
377
377
|
func: () => this._toggleShowSelected(),
|
|
378
378
|
disabled: !e,
|
|
379
379
|
toolTip: this._showOnlySelected ? this._translations.showAll : this._translations.showSelected
|
|
380
|
-
}), !r && !this._relatedFeatureTable &&
|
|
380
|
+
}), !r && !this._relatedFeatureTable && d.push({
|
|
381
381
|
active: !1,
|
|
382
382
|
icon: "list-check-all",
|
|
383
383
|
indicator: !1,
|
|
@@ -385,7 +385,7 @@ class M extends C {
|
|
|
385
385
|
label: this._translations.selectAll,
|
|
386
386
|
disabled: h,
|
|
387
387
|
toolTip: this._translations.selectAll
|
|
388
|
-
}), !r && !this._relatedFeatureTable &&
|
|
388
|
+
}), !r && !this._relatedFeatureTable && d.push({
|
|
389
389
|
active: !1,
|
|
390
390
|
icon: "compare",
|
|
391
391
|
indicator: !1,
|
|
@@ -393,7 +393,7 @@ class M extends C {
|
|
|
393
393
|
label: this._translations.switchSelected,
|
|
394
394
|
disabled: h,
|
|
395
395
|
toolTip: this._translations.switchSelected
|
|
396
|
-
}),
|
|
396
|
+
}), d.push({
|
|
397
397
|
active: !1,
|
|
398
398
|
icon: "refresh",
|
|
399
399
|
indicator: !1,
|
|
@@ -403,7 +403,7 @@ class M extends C {
|
|
|
403
403
|
label: this._translations.refresh,
|
|
404
404
|
disabled: !1,
|
|
405
405
|
toolTip: this._translations.refresh
|
|
406
|
-
}),
|
|
406
|
+
}), n && d.push({
|
|
407
407
|
active: !1,
|
|
408
408
|
icon: "export",
|
|
409
409
|
indicator: !1,
|
|
@@ -414,42 +414,48 @@ class M extends C {
|
|
|
414
414
|
loading: this._csvExporting,
|
|
415
415
|
disabled: h,
|
|
416
416
|
toolTip: this._translations.exportCSV
|
|
417
|
-
}), this._toolInfos = [...
|
|
417
|
+
}), this._toolInfos = [...d];
|
|
418
418
|
}
|
|
419
419
|
async _addListenersForLayers() {
|
|
420
420
|
this._layerEditsHandles.forEach((i) => i.remove()), this._layerEditsHandles = [];
|
|
421
421
|
const e = this.mapView, t = [...new Set(this.layerIds)];
|
|
422
422
|
if (!(!e || t.length === 0))
|
|
423
423
|
for (const i of t) {
|
|
424
|
-
const s = await
|
|
424
|
+
const s = await T(e, i);
|
|
425
425
|
if (!s)
|
|
426
426
|
continue;
|
|
427
427
|
const a = s.on("edits", async (l) => {
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
const n = [];
|
|
440
|
-
for (const f of r)
|
|
441
|
-
this._allIds.includes(f) && n.push(f);
|
|
442
|
-
n.length > 0 ? this._table?.highlightIds.addMany(n) : await this._refresh(), this.featuresAdded.emit(r);
|
|
443
|
-
} else
|
|
444
|
-
this._clearSelection(), this._pastedFeaturesIds = r, this.requestLayerSelectionChange.emit(s.id);
|
|
445
|
-
this._shouldSelectFeatureAfterCreate = !1;
|
|
446
|
-
} catch (h) {
|
|
447
|
-
this._shouldSelectFeatureAfterCreate = !1, console.error("Failed processing layer edits event", { layerId: i, error: h });
|
|
448
|
-
}
|
|
428
|
+
const h = Array.isArray(l?.addedFeatures) ? l.addedFeatures : [], r = Array.isArray(l?.updatedFeatures) ? l.updatedFeatures : [];
|
|
429
|
+
if (h.length === 0 && r.length === 0)
|
|
430
|
+
return;
|
|
431
|
+
const n = h.map((_) => _.objectId).filter((_) => _ != null), d = r.map((_) => _.objectId).filter((_) => _ != null);
|
|
432
|
+
if (n.length === 0 && d.length === 0)
|
|
433
|
+
return;
|
|
434
|
+
const f = this._layer?.id;
|
|
435
|
+
if (this._shouldSelectCreatedFeatures) {
|
|
436
|
+
await this._selectFeatures(n, i), i === f && this.featuresAdded.emit(n);
|
|
437
|
+
return;
|
|
438
|
+
} else i === f && n.length > 0 ? (this._searchExpression && (await this._refresh(), this._clearSelection(), await this._searchFullText()), await this._refresh(), this.initCreateComponent.emit()) : i === f && d.length > 0 && this._searchExpression && (await this._selectFeatures(d, i), await this._refresh());
|
|
449
439
|
});
|
|
450
440
|
a && this._layerEditsHandles.push(a);
|
|
451
441
|
}
|
|
452
442
|
}
|
|
443
|
+
async _selectFeatures(e, t) {
|
|
444
|
+
try {
|
|
445
|
+
const i = this._layer?.id;
|
|
446
|
+
if (t === i) {
|
|
447
|
+
await this._refresh(), this._clearSelection(), this._searchExpression && await this._searchFullText();
|
|
448
|
+
const s = [];
|
|
449
|
+
for (const a of e)
|
|
450
|
+
this._allIds.includes(a) && s.push(a);
|
|
451
|
+
s.length > 0 ? this._table?.highlightIds.addMany(s) : await this._refresh();
|
|
452
|
+
} else
|
|
453
|
+
this._clearSelection(), this._pastedFeaturesIds = e, this.requestLayerSelectionChange.emit(t);
|
|
454
|
+
this._shouldSelectCreatedFeatures = !1;
|
|
455
|
+
} catch (i) {
|
|
456
|
+
this._shouldSelectCreatedFeatures = !1, console.error("Failed processing layer edits event", { layerId: t, error: i });
|
|
457
|
+
}
|
|
458
|
+
}
|
|
453
459
|
_updateFloorDefinitionExpression() {
|
|
454
460
|
if (this._floorField && this._floorLevel) {
|
|
455
461
|
const e = `${this._floorField} = '${this._floorLevel}'`, t = this._layer?.definitionExpression;
|
|
@@ -465,8 +471,8 @@ class M extends C {
|
|
|
465
471
|
return this.mapInfo?.filterConfig?.layerExpressions && t !== void 0 && (e = this.mapInfo.filterConfig.layerExpressions.filter((i) => i.id === t)), e.length > 0;
|
|
466
472
|
}
|
|
467
473
|
_getAction(e, t, i, s, a, l, h, r) {
|
|
468
|
-
const
|
|
469
|
-
return o`<calcite-action .active=${e} .disabled=${
|
|
474
|
+
const n = this._layer === void 0 ? !0 : l;
|
|
475
|
+
return o`<calcite-action .active=${e} .disabled=${n} .icon=${t} .id=${`layer-table-${t}`} .indicator=${i} .label=${s} .loading=${h} @click=${a} text text-enabled><div class="display-flex"><span class="label-override padding-start-1-4">${s}</span></div></calcite-action>${this._getToolTip("auto", `layer-table-${t}`, r)}`;
|
|
470
476
|
}
|
|
471
477
|
_showDelete() {
|
|
472
478
|
this.showDelete.emit({
|
|
@@ -474,7 +480,7 @@ class M extends C {
|
|
|
474
480
|
});
|
|
475
481
|
}
|
|
476
482
|
_getShare(e) {
|
|
477
|
-
return o`<div id=${this._getId(e) ??
|
|
483
|
+
return o`<div id=${this._getId(e) ?? u}><instant-apps-social-share class="height-51 width-51 display-flex" .embed=${this.shareIncludeEmbed} flip-rtl popover-button-icon-scale=s scale=m share-button-color=neutral share-button-type=action .socialMedia=${this.shareIncludeSocial} .view=${this.mapView} ${b(this._shareNode)}></instant-apps-social-share>${this._getToolTip("bottom", e, this._translations.share)}</div>`;
|
|
478
484
|
}
|
|
479
485
|
_updateShareUrl() {
|
|
480
486
|
const e = this._shareNode.value?.shareUrl;
|
|
@@ -502,7 +508,7 @@ class M extends C {
|
|
|
502
508
|
}
|
|
503
509
|
async _getTable(e, t) {
|
|
504
510
|
this._layer && (await this._layer.when(() => {
|
|
505
|
-
this._table = new
|
|
511
|
+
this._table = new $({
|
|
506
512
|
autoRefreshEnabled: this.enableAutoRefresh,
|
|
507
513
|
autoSaveEnabled: this.enableTableAutosave,
|
|
508
514
|
layer: this._layer,
|
|
@@ -527,9 +533,9 @@ class M extends C {
|
|
|
527
533
|
}), await this._table?.when(() => {
|
|
528
534
|
this._table?.viewModel.addHandles(this._table.highlightIds.on("change", (i) => {
|
|
529
535
|
this._handleOnChange(i);
|
|
530
|
-
})), this._table?.viewModel.addHandles(this._table.on("cell-pointerover", this.tempHighlightOnHover.bind(this))), this._table?.viewModel.addHandles(this._table.on("cell-pointerout", this._removeTempHighlight.bind(this))), this._table?.viewModel.addHandles(this._table.on("column-reorder", this._handleColumnReorder.bind(this))), this.listenOn(this._tableNode, "mouseleave", this._removeTempHighlight), this._table?.viewModel.addHandles(
|
|
536
|
+
})), this._table?.viewModel.addHandles(this._table.on("cell-pointerover", this.tempHighlightOnHover.bind(this))), this._table?.viewModel.addHandles(this._table.on("cell-pointerout", this._removeTempHighlight.bind(this))), this._table?.viewModel.addHandles(this._table.on("column-reorder", this._handleColumnReorder.bind(this))), this.listenOn(this._tableNode, "mouseleave", this._removeTempHighlight), this._table?.viewModel.addHandles(p.watch(() => this._table.size, (i) => {
|
|
531
537
|
this._size = i;
|
|
532
|
-
})),
|
|
538
|
+
})), p?.watch(
|
|
533
539
|
() => this._table?.relatedTable,
|
|
534
540
|
// eslint-disable-next-line @typescript-eslint/no-misused-promises
|
|
535
541
|
async (i) => {
|
|
@@ -546,7 +552,7 @@ class M extends C {
|
|
|
546
552
|
await new Promise((a) => setTimeout(a, 50)), await this._refresh(!0);
|
|
547
553
|
}), this._checkEditEnabled(s), i.editingEnabled = this._editEnabled && this.enableInlineEdit, i.autoSaveEnabled = this.enableTableAutosave, this._relatedFeatureTable = i, typeof i.layer?.id == "string" && i.layer?.fields) {
|
|
548
554
|
const a = i.layer.popupTemplate?.fieldInfos, l = this._getColumnTemplates(i.layer.id, i.layer.fields, a);
|
|
549
|
-
this._relatedFeatureTable.tableTemplate = new
|
|
555
|
+
this._relatedFeatureTable.tableTemplate = new w({
|
|
550
556
|
columnTemplates: l
|
|
551
557
|
});
|
|
552
558
|
}
|
|
@@ -585,9 +591,13 @@ class M extends C {
|
|
|
585
591
|
if (this._hasPendingEdits()) {
|
|
586
592
|
let a = !1;
|
|
587
593
|
try {
|
|
588
|
-
this._editor.activeWorkflow
|
|
589
|
-
|
|
590
|
-
|
|
594
|
+
if (this._editor.activeWorkflow) {
|
|
595
|
+
const l = new Promise((h, r) => setTimeout(() => r(new Error("cancel-timeout")), 1e3));
|
|
596
|
+
await Promise.race([
|
|
597
|
+
this._editor.activeWorkflow.cancel({ force: !1 }),
|
|
598
|
+
l
|
|
599
|
+
]);
|
|
600
|
+
}
|
|
591
601
|
} catch (l) {
|
|
592
602
|
a = l?.name === "workflow:cancel-denied";
|
|
593
603
|
}
|
|
@@ -637,7 +647,7 @@ class M extends C {
|
|
|
637
647
|
t?.length === 0 ? this._tableNode?.classList.add("display-none") : this._tableNode?.classList.remove("display-none");
|
|
638
648
|
const i = this._table?.tableTemplate?.columnTemplates, s = i && t && i.length !== t.length || t?.some((a, l) => i && i[l] ? JSON.stringify(i[l]) !== JSON.stringify(a) : !1);
|
|
639
649
|
if (this._table && t && (s || !this._columnsInfo)) {
|
|
640
|
-
this._table.tableTemplate = new
|
|
650
|
+
this._table.tableTemplate = new w({
|
|
641
651
|
columnTemplates: t
|
|
642
652
|
});
|
|
643
653
|
const a = t.map((l) => l.fieldName);
|
|
@@ -646,7 +656,7 @@ class M extends C {
|
|
|
646
656
|
}
|
|
647
657
|
}
|
|
648
658
|
_setColumnTemplates(e) {
|
|
649
|
-
this._table && e && (this._table.tableTemplate = new
|
|
659
|
+
this._table && e && (this._table.tableTemplate = new w({
|
|
650
660
|
columnTemplates: e
|
|
651
661
|
}));
|
|
652
662
|
}
|
|
@@ -657,7 +667,7 @@ class M extends C {
|
|
|
657
667
|
} else this._table && (this._table.view = this.mapView, this._table.layer = this._layer);
|
|
658
668
|
await this._initLayerRefresh(), this._checkEditEnabled(this._layer), this._table && (this._table.editingEnabled = this._editEnabled && this.enableInlineEdit, this._table.autoSaveEnabled = this.enableTableAutosave, await this._table.when(), setTimeout(() => {
|
|
659
669
|
this._loaded || this.finishLoading();
|
|
660
|
-
}, 1e3), await
|
|
670
|
+
}, 1e3), await p.once(() => this._table?.state === "loaded").then(async () => {
|
|
661
671
|
await this.finishLoading();
|
|
662
672
|
}));
|
|
663
673
|
}
|
|
@@ -689,7 +699,7 @@ class M extends C {
|
|
|
689
699
|
}
|
|
690
700
|
async _handleDefaults() {
|
|
691
701
|
if (!this._defaultOidHonored && this.defaultOid?.length > 0 && this.defaultOid[0] > -1 && this._table && (await this._selectDefaultFeature(this.defaultOid), this._defaultOidHonored = !0, this.defaultOid = [], this._showOnlySelected = !1, this._toggleShowSelected()), !this._defaultGlobalIdHonored && this.defaultGlobalId && this.defaultGlobalId?.length > 0 && this._table && this._layer) {
|
|
692
|
-
const e = await
|
|
702
|
+
const e = await x(this.defaultGlobalId, this._layer), t = e?.length > 0 ? e.map((i) => Number(i.getObjectId())) : void 0;
|
|
693
703
|
t && await this._selectDefaultFeature(t), this._defaultGlobalIdHonored = !0, this.defaultGlobalId = [], this._showOnlySelected = !1, this._toggleShowSelected();
|
|
694
704
|
}
|
|
695
705
|
}
|
|
@@ -723,7 +733,7 @@ class M extends C {
|
|
|
723
733
|
this._filterActive = e, this._updateShareUrl(), await this._searchFullText();
|
|
724
734
|
}
|
|
725
735
|
_handleTableOnMapExtent() {
|
|
726
|
-
this._table && (this._filterByExtentHandle =
|
|
736
|
+
this._table && (this._filterByExtentHandle = p.when(
|
|
727
737
|
() => this.mapView?.stationary,
|
|
728
738
|
// eslint-disable-next-line @typescript-eslint/no-misused-promises
|
|
729
739
|
async () => {
|
|
@@ -798,8 +808,8 @@ class M extends C {
|
|
|
798
808
|
const l = this._relatedFeatureTable.tableParent.highlightIds?.getItemAt(0);
|
|
799
809
|
if (l !== void 0) {
|
|
800
810
|
const h = await this._queryRelatedFeatures(), r = [];
|
|
801
|
-
h && h[l]?.features && (h[l].features.forEach((
|
|
802
|
-
|
|
811
|
+
h && h[l]?.features && (h[l].features.forEach((n) => {
|
|
812
|
+
n.attributes && r.push(n.attributes[e.objectIdField]);
|
|
803
813
|
}), i = r.length > 0 ? r : []);
|
|
804
814
|
}
|
|
805
815
|
}
|
|
@@ -818,7 +828,7 @@ class M extends C {
|
|
|
818
828
|
}
|
|
819
829
|
return l;
|
|
820
830
|
}, []);
|
|
821
|
-
this._updateToolInfoLoading("export", !0), this._csvExporting = !0, this.mapView?.map && await
|
|
831
|
+
this._updateToolInfoLoading("export", !0), this._csvExporting = !0, this.mapView?.map && await F(
|
|
822
832
|
this.mapView.map,
|
|
823
833
|
t,
|
|
824
834
|
!1,
|
|
@@ -833,7 +843,7 @@ class M extends C {
|
|
|
833
843
|
), this._updateToolInfoLoading("export", !1), this._csvExporting = !1;
|
|
834
844
|
}
|
|
835
845
|
async _queryRelatedFeatures() {
|
|
836
|
-
const e = this._relatedFeatureTable ? this._relatedFeatureTable ? this._relatedFeatureTable.layer : this._relatedFeatureTable.tableParent?.layer : this._layer, t = this._relatedFeatureTable?.tableParent?.highlightIds?.items[0], i = this._relatedFeatureTable?.tableParent?.layer, s = e?.relationships?.find((h) => i.relationships?.some((r) => r.id === h.id)), a = new
|
|
846
|
+
const e = this._relatedFeatureTable ? this._relatedFeatureTable ? this._relatedFeatureTable.layer : this._relatedFeatureTable.tableParent?.layer : this._layer, t = this._relatedFeatureTable?.tableParent?.highlightIds?.items[0], i = this._relatedFeatureTable?.tableParent?.layer, s = e?.relationships?.find((h) => i.relationships?.some((r) => r.id === h.id)), a = new D({
|
|
837
847
|
objectIds: [t],
|
|
838
848
|
outFields: ["*"],
|
|
839
849
|
relationshipId: s?.id
|
|
@@ -881,9 +891,9 @@ class M extends C {
|
|
|
881
891
|
const t = e.detail[0];
|
|
882
892
|
if (t !== this._layer?.id || this._featuresEmpty()) {
|
|
883
893
|
this._fetchingData = !0, await this._clearSearchText();
|
|
884
|
-
const i = this.mapView && await
|
|
894
|
+
const i = this.mapView && await T(this.mapView, t);
|
|
885
895
|
i && await i.when(async () => {
|
|
886
|
-
this._selectedLayerView = !i.isTable && this.mapView ? await
|
|
896
|
+
this._selectedLayerView = !i.isTable && this.mapView ? await E(this.mapView, i.id) : null, this._table && this._table?.viewModel?.attachmentsViewOptions?.objectId && this._table.viewModel.hideAttachmentsView(), this._shouldUpdateTableOnExtentChange = !0, this._layer = i, await this._initToolInfos(), this._getFullTextSearchInfo();
|
|
887
897
|
});
|
|
888
898
|
}
|
|
889
899
|
this._creatingFeature = !1, this._fetchingData = !1;
|
|
@@ -892,17 +902,17 @@ class M extends C {
|
|
|
892
902
|
let s = this._getLayerOption(e);
|
|
893
903
|
const a = this._layer?.attributeTableTemplate?.elements;
|
|
894
904
|
let l = [];
|
|
895
|
-
a?.length > 0 && this.honorMapFieldSettings && (l = a.map((
|
|
896
|
-
const h = s?.fields && s?.fieldOrder ? s.fieldOrder.filter((
|
|
905
|
+
a?.length > 0 && this.honorMapFieldSettings && (l = a.map((n) => n.fieldName));
|
|
906
|
+
const h = s?.fields && s?.fieldOrder ? s.fieldOrder.filter((n) => s?.fields && s.fields.indexOf(n) > -1) : l.length > 0 ? l : void 0;
|
|
897
907
|
let r;
|
|
898
|
-
return t && (r = t.reduce((
|
|
908
|
+
return t && (r = t.reduce((n, d) => {
|
|
899
909
|
const f = {
|
|
900
910
|
type: "field",
|
|
901
|
-
fieldName:
|
|
902
|
-
label: this.getFieldLabel(
|
|
903
|
-
menuConfig: this._getMenuConfig(
|
|
911
|
+
fieldName: d.name,
|
|
912
|
+
label: this.getFieldLabel(d, i),
|
|
913
|
+
menuConfig: this._getMenuConfig(d.name)
|
|
904
914
|
};
|
|
905
|
-
return s && s.fields && s?.fields?.length > 0 ? s.fields.indexOf(
|
|
915
|
+
return s && s.fields && s?.fields?.length > 0 ? s.fields.indexOf(d.name) > -1 && n.push(f) : l.length > 0 ? l.indexOf(d.name) > -1 && n.push(f) : n.push(f), n;
|
|
906
916
|
}, [])), r ? h ? r?.sort(this._sortFields.bind(this, h)) : r : [];
|
|
907
917
|
}
|
|
908
918
|
updateRelatedAttachmentColumns() {
|
|
@@ -939,7 +949,7 @@ class M extends C {
|
|
|
939
949
|
}));
|
|
940
950
|
}
|
|
941
951
|
}
|
|
942
|
-
|
|
952
|
+
v("layer-table", R);
|
|
943
953
|
export {
|
|
944
|
-
|
|
954
|
+
R as LayerTable
|
|
945
955
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import { c as
|
|
2
|
+
import { c as v } from "../../chunks/runtime.js";
|
|
3
3
|
import { u as T } from "../../chunks/useT9n.js";
|
|
4
4
|
import { LitElement as D, createEvent as m, safeClassMap as u } from "@arcgis/lumina";
|
|
5
5
|
import { useContextConsumer as $ } from "@arcgis/lumina/context";
|
|
@@ -11,9 +11,9 @@ import * as E from "@esri/solution-common";
|
|
|
11
11
|
import { updateGroup as x, updateItem as g, updateItemExtended as W } from "@esri/solution-common";
|
|
12
12
|
import { v as C } from "../../chunks/validators.js";
|
|
13
13
|
import { g as L } from "../../chunks/getRelatedInfos.js";
|
|
14
|
-
import { h as N, i as y } from "../../chunks/helpers.js";
|
|
15
|
-
const
|
|
16
|
-
class
|
|
14
|
+
import { h as N, i as y, j as O } from "../../chunks/helpers.js";
|
|
15
|
+
const R = P`*[tabindex]:focus-visible{outline-style:solid!important;outline-width:2px!important;outline-color:var(--calcite-color-brand)!important;outline-offset:2px!important}.display-flex{display:flex}.display-none{display:none}.flex-direction-column{flex-direction:column}.flex-direction-row{flex-direction:row}.font-weight-medium{font-weight:var(--calcite-font-weight-medium)}.font-style-1{font-size:1rem;color:var(--calcite-color-text-2)}.margin-top-0{margin-top:0}.padding-top-20{padding-top:20px}.padding-bottom-2{padding-bottom:2rem}.padding-left-2{padding-left:2rem}.padding-right-2{padding-right:2rem}.padding-end-1{padding-inline-end:1rem}.padding-end-1-2{padding-inline-end:.5rem}.width-full{width:100%}.justify-content-space{justify-content:space-between}`;
|
|
16
|
+
class k extends D {
|
|
17
17
|
constructor() {
|
|
18
18
|
super(...arguments), this.open = !1, this.source = "Card Dropdown", this.solutionData = {}, this.templateInfos = [], this._saveDisabled = !1, this._displayTemplateInfos = [], this._hasNameLengthError = !1, this._nonSolutionDependencyItems = [], this._solutionItemsTitlesUpdating = !1, this._translations = T({ name: "solution-configure-titles", blocking: !0 }), this._configContextConsumer = $({
|
|
19
19
|
context: w,
|
|
@@ -24,7 +24,7 @@ class R extends D {
|
|
|
24
24
|
this.properties = { card: 0, open: 5, source: 1, solutionData: 1, templateInfos: 0, _saveDisabled: 16, _displayTemplateInfos: 16, _hasNameLengthError: 16, _nonSolutionDependencyItems: 16, _solutionItemsTitlesUpdating: 16, _translations: 16 };
|
|
25
25
|
}
|
|
26
26
|
static {
|
|
27
|
-
this.styles =
|
|
27
|
+
this.styles = R;
|
|
28
28
|
}
|
|
29
29
|
async willUpdate(e) {
|
|
30
30
|
if (e.has("templateInfos") && (this._templateInfos = JSON.parse(JSON.stringify(this.templateInfos)), this._updateTemplates()), e.has("open")) {
|
|
@@ -51,8 +51,8 @@ class R extends D {
|
|
|
51
51
|
}} .open=${this.open} outside-close-disabled width=l>${this._getPrefixSuffixControls()}${this._getAccordion()}${this._getDialogButtons()}</calcite-dialog>`;
|
|
52
52
|
}
|
|
53
53
|
_getPrefixSuffixControls() {
|
|
54
|
-
const e = C(this._prefixValue), i = this._hasNameLengthError && this._prefixValue.length > 0, a = e.errorType !== "special-character", t = !i, s = a ? "display-none" : "", n = t ? "display-none" : "", d = a && t ? "valid" : "invalid", c = C(this._suffixValue), l = this._hasNameLengthError && this._suffixValue.length > 0, o = c.errorType !== "special-character", r = !l, f = o ? "display-none" : "", I = r ? "display-none" : "",
|
|
55
|
-
return this._saveDisabled = !a || !t || !o || !r || !this._hasChanges(), h`<div class="display-flex flex-direction-column padding-left-2 padding-right-2 padding-top-20"><calcite-label scale=l class="font-weight-medium"><span tabindex=0>${this._translations.configureTitlesDialogHeader}</span></calcite-label><p class="font-style-1 margin-top-0" tabindex=0>${this._translations.addPrefixOrSuffixToItems}</p><div class="display-flex flex-direction-row justify-content-space"><calcite-label class="width-full padding-end-1" scale=l>${this._translations.prefixToAddToItems}<calcite-input clearable @blur=${this._prefixInput} @input=${this._prefixInput} .placeholder=${this._translations.enterPrefixPlaceholder} .status=${d} .value=${this._prefixValue} ${p(this._prefixRef)}></calcite-input><calcite-input-message class=${u(s)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixCharsError}</calcite-input-message><calcite-input-message class=${u(n)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixLengthError}</calcite-input-message></calcite-label><calcite-label class="width-full" scale=l>${this._translations.suffixToAddToItems}<calcite-input clearable @blur=${this._suffixInput} @input=${this._suffixInput} .placeholder=${this._translations.enterSuffixPlaceholder} .status=${
|
|
54
|
+
const e = C(this._prefixValue), i = this._hasNameLengthError && this._prefixValue.length > 0, a = e.errorType !== "special-character", t = !i, s = a ? "display-none" : "", n = t ? "display-none" : "", d = a && t ? "valid" : "invalid", c = C(this._suffixValue), l = this._hasNameLengthError && this._suffixValue.length > 0, o = c.errorType !== "special-character", r = !l, f = o ? "display-none" : "", I = r ? "display-none" : "", S = o && r ? "valid" : "invalid";
|
|
55
|
+
return this._saveDisabled = !a || !t || !o || !r || !this._hasChanges(), h`<div class="display-flex flex-direction-column padding-left-2 padding-right-2 padding-top-20"><calcite-label scale=l class="font-weight-medium"><span tabindex=0>${this._translations.configureTitlesDialogHeader}</span></calcite-label><p class="font-style-1 margin-top-0" tabindex=0>${this._translations.addPrefixOrSuffixToItems}</p><div class="display-flex flex-direction-row justify-content-space"><calcite-label class="width-full padding-end-1" scale=l>${this._translations.prefixToAddToItems}<calcite-input clearable @blur=${this._prefixInput} @input=${this._prefixInput} .placeholder=${this._translations.enterPrefixPlaceholder} .status=${d} .value=${this._prefixValue} ${p(this._prefixRef)}></calcite-input><calcite-input-message class=${u(s)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixCharsError}</calcite-input-message><calcite-input-message class=${u(n)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixLengthError}</calcite-input-message></calcite-label><calcite-label class="width-full" scale=l>${this._translations.suffixToAddToItems}<calcite-input clearable @blur=${this._suffixInput} @input=${this._suffixInput} .placeholder=${this._translations.enterSuffixPlaceholder} .status=${S} .value=${this._suffixValue} ${p(this._suffixRef)}></calcite-input><calcite-input-message class=${u(f)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixCharsError}</calcite-input-message><calcite-input-message class=${u(I)} icon=exclamation-mark-triangle status=invalid>${this._translations.invalidPrefixOrSuffixLengthError}</calcite-input-message></calcite-label></div></div>`;
|
|
56
56
|
}
|
|
57
57
|
_getAccordion() {
|
|
58
58
|
const e = N(this._nonSolutionDependencyItems, this.card.id);
|
|
@@ -119,7 +119,8 @@ class R extends D {
|
|
|
119
119
|
this.card?.title || "",
|
|
120
120
|
this.card?.deployCommonId || "",
|
|
121
121
|
this.card?.deployVersion || "",
|
|
122
|
-
this.source
|
|
122
|
+
this.source,
|
|
123
|
+
O(this.card?.typeKeywords)
|
|
123
124
|
]
|
|
124
125
|
}), this._solutionItemsTitlesUpdating = !0;
|
|
125
126
|
const e = this._configContextConsumer.value?.authentication?.CanUpdateSolution ?? !1, i = this._configContextConsumer.value?.authentication?.PortalUserName, a = this._displayTemplateInfos.reduce((t, s) => {
|
|
@@ -158,7 +159,7 @@ class R extends D {
|
|
|
158
159
|
}
|
|
159
160
|
}
|
|
160
161
|
}
|
|
161
|
-
|
|
162
|
+
v("solution-configure-titles", k);
|
|
162
163
|
export {
|
|
163
|
-
|
|
164
|
+
k as SolutionConfigureTitles
|
|
164
165
|
};
|