@esri/solutions-components 0.6.29 → 0.6.32
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/calcite-alert_3.cjs.entry.js +17 -8
- package/dist/cjs/card-manager_3.cjs.entry.js +28 -44
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/solutions-components.cjs.js +1 -1
- package/dist/collection/components/edit-card/edit-card.css +9 -0
- package/dist/collection/components/edit-card/edit-card.js +25 -7
- package/dist/collection/components/layer-table/layer-table.css +4 -2
- package/dist/collection/components/layer-table/layer-table.js +27 -43
- package/dist/components/edit-card2.js +18 -9
- package/dist/components/layer-table2.js +28 -44
- package/dist/esm/calcite-alert_3.entry.js +17 -8
- package/dist/esm/card-manager_3.entry.js +28 -44
- package/dist/esm/loader.js +1 -1
- package/dist/esm/solutions-components.js +1 -1
- package/dist/solutions-components/{p-3c702004.entry.js → p-792e171f.entry.js} +1 -1
- package/dist/solutions-components/{p-f8687049.entry.js → p-e05cf92d.entry.js} +2 -2
- package/dist/solutions-components/solutions-components.esm.js +1 -1
- package/dist/types/components/edit-card/edit-card.d.ts +2 -1
- package/package.json +1 -1
- package/dist/esm/polyfills/core-js.js +0 -11
- package/dist/esm/polyfills/dom.js +0 -79
- package/dist/esm/polyfills/es5-html-element.js +0 -1
- package/dist/esm/polyfills/index.js +0 -34
- package/dist/esm/polyfills/system.js +0 -6
@@ -60,14 +60,16 @@
|
|
60
60
|
|
61
61
|
.bottom-left {
|
62
62
|
position: absolute;
|
63
|
-
left:
|
63
|
+
left: 0;
|
64
64
|
bottom: 0;
|
65
|
+
padding-left: 5px;
|
65
66
|
}
|
66
67
|
|
67
68
|
html[dir="rtl"] .bottom-left {
|
68
69
|
position: absolute;
|
69
|
-
right:
|
70
|
+
right: 0;
|
70
71
|
bottom: 0;
|
72
|
+
padding-right: 5px;
|
71
73
|
}
|
72
74
|
|
73
75
|
.height-19 {
|
@@ -599,33 +599,30 @@ export class LayerTable {
|
|
599
599
|
* @returns void
|
600
600
|
*/
|
601
601
|
async _resetTable() {
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
|
612
|
-
|
613
|
-
this._checkEditEnabled();
|
614
|
-
this._table.editingEnabled = this._editEnabled && this.enableInlineEdit;
|
615
|
-
this._initToolInfos();
|
616
|
-
});
|
617
|
-
await this._table.when(() => {
|
618
|
-
this._table.clearSelectionFilter();
|
619
|
-
});
|
620
|
-
this._showOnlySelected = false;
|
621
|
-
this._sortActive = false;
|
622
|
-
await this._sortTable();
|
623
|
-
}
|
624
|
-
else {
|
625
|
-
this._table.view = this.mapView;
|
626
|
-
this._table.layer = this._layer;
|
627
|
-
}
|
602
|
+
var _a, _b;
|
603
|
+
this._clearSelection();
|
604
|
+
this._allIds = [];
|
605
|
+
this.featureSelectionChange.emit(this._selectedIndexes);
|
606
|
+
const columnTemplates = this._getColumnTemplates(this._layer.id, (_b = (_a = this._layer) === null || _a === void 0 ? void 0 : _a.popupTemplate) === null || _b === void 0 ? void 0 : _b.fieldInfos);
|
607
|
+
this._allIds = await queryAllIds(this._layer);
|
608
|
+
if (!this._table) {
|
609
|
+
await this._getTable(this._tableNode, columnTemplates);
|
610
|
+
}
|
611
|
+
else if (columnTemplates) {
|
612
|
+
this._table.tableTemplate.columnTemplates = columnTemplates;
|
628
613
|
}
|
614
|
+
this._table.layer = this._layer;
|
615
|
+
this._table.view = this.mapView;
|
616
|
+
this._checkEditEnabled();
|
617
|
+
this._table.editingEnabled = this._editEnabled && this.enableInlineEdit;
|
618
|
+
this._initToolInfos();
|
619
|
+
await this._table.when(() => {
|
620
|
+
this._table.highlightIds.removeAll();
|
621
|
+
this._table.clearSelectionFilter();
|
622
|
+
});
|
623
|
+
this._showOnlySelected = false;
|
624
|
+
this._sortActive = false;
|
625
|
+
await this._sortTable();
|
629
626
|
}
|
630
627
|
/**
|
631
628
|
* Verify edit capabilities of the layer
|
@@ -827,28 +824,15 @@ export class LayerTable {
|
|
827
824
|
* @returns a promise that will resolve when the operation is complete
|
828
825
|
*/
|
829
826
|
async _layerSelectionChanged(evt) {
|
830
|
-
var _a
|
827
|
+
var _a;
|
831
828
|
const id = evt.detail[0];
|
832
829
|
if (id !== ((_a = this._layer) === null || _a === void 0 ? void 0 : _a.id) || this._allIds.length === 0) {
|
833
830
|
this._fetchingData = true;
|
834
|
-
|
835
|
-
|
836
|
-
|
837
|
-
if (!this._table) {
|
838
|
-
await this._getTable(this._tableNode, columnTemplates);
|
839
|
-
}
|
840
|
-
else if (columnTemplates) {
|
841
|
-
this._table.tableTemplate.columnTemplates = columnTemplates;
|
842
|
-
}
|
843
|
-
await this._table.when(() => {
|
844
|
-
this._table.highlightIds.removeAll();
|
831
|
+
const layer = await getLayerOrTable(this.mapView, id);
|
832
|
+
await layer.when(() => {
|
833
|
+
this._layer = layer;
|
845
834
|
});
|
846
|
-
this._selectedIndexes = [];
|
847
|
-
this._table.layer = this._layer;
|
848
|
-
this._table.render();
|
849
835
|
}
|
850
|
-
this._sortActive = false;
|
851
|
-
await this._sortTable();
|
852
836
|
this._fetchingData = false;
|
853
837
|
}
|
854
838
|
/**
|
@@ -10,7 +10,7 @@ import { d as defineCustomElement$3 } from './icon.js';
|
|
10
10
|
import { d as defineCustomElement$2 } from './loader.js';
|
11
11
|
import { d as defineCustomElement$1 } from './notice.js';
|
12
12
|
|
13
|
-
const editCardCss = ":host{display:block}.padding-bottom-1{padding-bottom:1rem}.font-bold{font-weight:var(--calcite-font-weight-bold)}.font-500{font-weight:var(--calcite-font-weight-medium)}.font-italic{font-style:italic}#feature-form{--calcite-ui-background:none;padding-top:0px}.padding-sides-bottom-1{padding:0 1rem 1rem 1rem}.position-relative{position:relative}.esri-editor__prompt--danger{position:relative !important;width:100% !important;background-color:var(--calcite-ui-foreground-1) !important}.esri-feature__content-node{background-color:var(--calcite-ui-foreground-1) !important}.esri-editor__panel-toolbar{display:none !important}";
|
13
|
+
const editCardCss = ":host{display:block}.padding-bottom-1{padding-bottom:1rem}.font-bold{font-weight:var(--calcite-font-weight-bold)}.font-500{font-weight:var(--calcite-font-weight-medium)}.font-italic{font-style:italic}#feature-form{--calcite-ui-background:none;padding-top:0px}.padding-sides-bottom-1{padding:0 1rem 1rem 1rem}.position-relative{position:relative}.esri-editor__prompt--danger{position:relative !important;width:100% !important;background-color:var(--calcite-ui-foreground-1) !important}.esri-feature__content-node{background-color:var(--calcite-ui-foreground-1) !important}.esri-editor__panel-toolbar{display:none !important}.position-absolute{position:absolute;top:0;right:0;bottom:0;left:0;overflow:auto}";
|
14
14
|
|
15
15
|
const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLElement {
|
16
16
|
constructor() {
|
@@ -39,7 +39,7 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
39
39
|
*/
|
40
40
|
async graphicsWatchHandler() {
|
41
41
|
if (this.graphics.length === 0) {
|
42
|
-
this._closeEdit();
|
42
|
+
await this._closeEdit();
|
43
43
|
}
|
44
44
|
}
|
45
45
|
async openWatchHandler(v) {
|
@@ -53,9 +53,12 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
53
53
|
this._editorLoading = false;
|
54
54
|
}
|
55
55
|
if (!v) {
|
56
|
-
this._closeEdit();
|
56
|
+
await this._closeEdit();
|
57
57
|
}
|
58
58
|
}
|
59
|
+
async featureSelectionChange() {
|
60
|
+
await this._closeEdit();
|
61
|
+
}
|
59
62
|
//--------------------------------------------------------------------------
|
60
63
|
//
|
61
64
|
// Functions (lifecycle)
|
@@ -85,7 +88,7 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
85
88
|
}
|
86
89
|
this._layerEditHandle = this._layer.on("edits", () => {
|
87
90
|
this.editsComplete.emit();
|
88
|
-
this._closeEdit();
|
91
|
+
void this._closeEdit();
|
89
92
|
});
|
90
93
|
}
|
91
94
|
}
|
@@ -98,9 +101,9 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
98
101
|
// when you use MULTI edit mode...is fine in SINGLE
|
99
102
|
const editDisabled = ((_a = this.graphics) === null || _a === void 0 ? void 0 : _a.length) > 0 && this.graphics[0] ?
|
100
103
|
!this.graphics[0].layer.editingEnabled : true;
|
101
|
-
const tableNodeClass = this._editorLoading ? "display-none" : "";
|
104
|
+
const tableNodeClass = this._editorLoading ? "display-none" : "position-absolute";
|
102
105
|
const loadingClass = this._editorLoading ? "" : "display-none";
|
103
|
-
return (h(Host, null, h("div", { class: "position-
|
106
|
+
return (h(Host, null, h("div", { class: "position-absolute" }, editDisabled ? (h("calcite-notice", { kind: "warning", open: true, slot: "content-top", width: "full" }, h("div", { slot: "message" }, this._translations.enableEditing))) : undefined, h("div", { class: "position-absolute", slot: "content" }, h("div", { class: tableNodeClass, id: "feature-form", ref: (el) => this._editContainer = el }), h("calcite-loader", { class: loadingClass, scale: "s" })))));
|
104
107
|
}
|
105
108
|
//--------------------------------------------------------------------------
|
106
109
|
//
|
@@ -156,7 +159,7 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
156
159
|
});
|
157
160
|
this._editHandle = this.reactiveUtils.when(() => this._editor.viewModel.state === "ready", () => {
|
158
161
|
if (this._shouldClose) {
|
159
|
-
this._closeEdit();
|
162
|
+
void this._closeEdit();
|
160
163
|
}
|
161
164
|
else if (this.graphicIndex > -1 && this.graphics.length > 0 && this.open && !this._shouldClose) {
|
162
165
|
void this._startUpdate();
|
@@ -176,7 +179,13 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
176
179
|
*
|
177
180
|
* @returns void
|
178
181
|
*/
|
179
|
-
_closeEdit() {
|
182
|
+
async _closeEdit() {
|
183
|
+
var _a, _b, _c;
|
184
|
+
this._shouldClose = true;
|
185
|
+
if ((_a = this._editor) === null || _a === void 0 ? void 0 : _a.activeWorkflow) {
|
186
|
+
await ((_b = this._editor) === null || _b === void 0 ? void 0 : _b.cancelWorkflow());
|
187
|
+
}
|
188
|
+
(_c = this._editor) === null || _c === void 0 ? void 0 : _c.destroy();
|
180
189
|
this._shouldClose = false;
|
181
190
|
this.closeEdit.emit();
|
182
191
|
}
|
@@ -211,7 +220,7 @@ const EditCard = /*@__PURE__*/ proxyCustomElement(class EditCard extends HTMLEle
|
|
211
220
|
"graphicIndex": [2, "graphic-index"],
|
212
221
|
"_editorLoading": [32],
|
213
222
|
"_translations": [32]
|
214
|
-
},
|
223
|
+
}, [[8, "featureSelectionChange", "featureSelectionChange"]], {
|
215
224
|
"graphics": ["graphicsWatchHandler"],
|
216
225
|
"open": ["openWatchHandler"]
|
217
226
|
}]);
|
@@ -33,7 +33,7 @@ import { d as defineCustomElement$3 } from './shell.js';
|
|
33
33
|
import { d as defineCustomElement$2 } from './tooltip.js';
|
34
34
|
import { d as defineCustomElement$1 } from './map-layer-picker2.js';
|
35
35
|
|
36
|
-
const layerTableCss = ":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-ui-border-2)}.border-end{border-inline-end:1px solid var(--calcite-ui-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-ui-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51{height:51px}.bottom-left{position:absolute;left:
|
36
|
+
const layerTableCss = ":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-ui-border-2)}.border-end{border-inline-end:1px solid var(--calcite-ui-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-ui-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51{height:51px}.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-ui-background)}.text-color{color:var(--calcite-ui-text-1)}.align-center{align-items:center}.danger-color{color:var(--calcite-ui-danger)}.esri-feature-table vaadin-grid{border:none !important}vaadin-grid-cell-content{padding:var(--lumo-space-xs) var(--lumo-space-m) !important;font-size:14px !important}";
|
37
37
|
|
38
38
|
const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTMLElement {
|
39
39
|
constructor() {
|
@@ -614,33 +614,30 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
614
614
|
* @returns void
|
615
615
|
*/
|
616
616
|
async _resetTable() {
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
this._checkEditEnabled();
|
629
|
-
this._table.editingEnabled = this._editEnabled && this.enableInlineEdit;
|
630
|
-
this._initToolInfos();
|
631
|
-
});
|
632
|
-
await this._table.when(() => {
|
633
|
-
this._table.clearSelectionFilter();
|
634
|
-
});
|
635
|
-
this._showOnlySelected = false;
|
636
|
-
this._sortActive = false;
|
637
|
-
await this._sortTable();
|
638
|
-
}
|
639
|
-
else {
|
640
|
-
this._table.view = this.mapView;
|
641
|
-
this._table.layer = this._layer;
|
642
|
-
}
|
617
|
+
var _a, _b;
|
618
|
+
this._clearSelection();
|
619
|
+
this._allIds = [];
|
620
|
+
this.featureSelectionChange.emit(this._selectedIndexes);
|
621
|
+
const columnTemplates = this._getColumnTemplates(this._layer.id, (_b = (_a = this._layer) === null || _a === void 0 ? void 0 : _a.popupTemplate) === null || _b === void 0 ? void 0 : _b.fieldInfos);
|
622
|
+
this._allIds = await queryAllIds(this._layer);
|
623
|
+
if (!this._table) {
|
624
|
+
await this._getTable(this._tableNode, columnTemplates);
|
625
|
+
}
|
626
|
+
else if (columnTemplates) {
|
627
|
+
this._table.tableTemplate.columnTemplates = columnTemplates;
|
643
628
|
}
|
629
|
+
this._table.layer = this._layer;
|
630
|
+
this._table.view = this.mapView;
|
631
|
+
this._checkEditEnabled();
|
632
|
+
this._table.editingEnabled = this._editEnabled && this.enableInlineEdit;
|
633
|
+
this._initToolInfos();
|
634
|
+
await this._table.when(() => {
|
635
|
+
this._table.highlightIds.removeAll();
|
636
|
+
this._table.clearSelectionFilter();
|
637
|
+
});
|
638
|
+
this._showOnlySelected = false;
|
639
|
+
this._sortActive = false;
|
640
|
+
await this._sortTable();
|
644
641
|
}
|
645
642
|
/**
|
646
643
|
* Verify edit capabilities of the layer
|
@@ -842,28 +839,15 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
842
839
|
* @returns a promise that will resolve when the operation is complete
|
843
840
|
*/
|
844
841
|
async _layerSelectionChanged(evt) {
|
845
|
-
var _a
|
842
|
+
var _a;
|
846
843
|
const id = evt.detail[0];
|
847
844
|
if (id !== ((_a = this._layer) === null || _a === void 0 ? void 0 : _a.id) || this._allIds.length === 0) {
|
848
845
|
this._fetchingData = true;
|
849
|
-
|
850
|
-
|
851
|
-
|
852
|
-
if (!this._table) {
|
853
|
-
await this._getTable(this._tableNode, columnTemplates);
|
854
|
-
}
|
855
|
-
else if (columnTemplates) {
|
856
|
-
this._table.tableTemplate.columnTemplates = columnTemplates;
|
857
|
-
}
|
858
|
-
await this._table.when(() => {
|
859
|
-
this._table.highlightIds.removeAll();
|
846
|
+
const layer = await getLayerOrTable(this.mapView, id);
|
847
|
+
await layer.when(() => {
|
848
|
+
this._layer = layer;
|
860
849
|
});
|
861
|
-
this._selectedIndexes = [];
|
862
|
-
this._table.layer = this._layer;
|
863
|
-
this._table.render();
|
864
850
|
}
|
865
|
-
this._sortActive = false;
|
866
|
-
await this._sortTable();
|
867
851
|
this._fetchingData = false;
|
868
852
|
}
|
869
853
|
/**
|
@@ -319,7 +319,7 @@ const Alert = class {
|
|
319
319
|
};
|
320
320
|
Alert.style = alertCss;
|
321
321
|
|
322
|
-
const editCardCss = ":host{display:block}.padding-bottom-1{padding-bottom:1rem}.font-bold{font-weight:var(--calcite-font-weight-bold)}.font-500{font-weight:var(--calcite-font-weight-medium)}.font-italic{font-style:italic}#feature-form{--calcite-ui-background:none;padding-top:0px}.padding-sides-bottom-1{padding:0 1rem 1rem 1rem}.position-relative{position:relative}.esri-editor__prompt--danger{position:relative !important;width:100% !important;background-color:var(--calcite-ui-foreground-1) !important}.esri-feature__content-node{background-color:var(--calcite-ui-foreground-1) !important}.esri-editor__panel-toolbar{display:none !important}";
|
322
|
+
const editCardCss = ":host{display:block}.padding-bottom-1{padding-bottom:1rem}.font-bold{font-weight:var(--calcite-font-weight-bold)}.font-500{font-weight:var(--calcite-font-weight-medium)}.font-italic{font-style:italic}#feature-form{--calcite-ui-background:none;padding-top:0px}.padding-sides-bottom-1{padding:0 1rem 1rem 1rem}.position-relative{position:relative}.esri-editor__prompt--danger{position:relative !important;width:100% !important;background-color:var(--calcite-ui-foreground-1) !important}.esri-feature__content-node{background-color:var(--calcite-ui-foreground-1) !important}.esri-editor__panel-toolbar{display:none !important}.position-absolute{position:absolute;top:0;right:0;bottom:0;left:0;overflow:auto}";
|
323
323
|
|
324
324
|
const EditCard = class {
|
325
325
|
constructor(hostRef) {
|
@@ -347,7 +347,7 @@ const EditCard = class {
|
|
347
347
|
*/
|
348
348
|
async graphicsWatchHandler() {
|
349
349
|
if (this.graphics.length === 0) {
|
350
|
-
this._closeEdit();
|
350
|
+
await this._closeEdit();
|
351
351
|
}
|
352
352
|
}
|
353
353
|
async openWatchHandler(v) {
|
@@ -361,9 +361,12 @@ const EditCard = class {
|
|
361
361
|
this._editorLoading = false;
|
362
362
|
}
|
363
363
|
if (!v) {
|
364
|
-
this._closeEdit();
|
364
|
+
await this._closeEdit();
|
365
365
|
}
|
366
366
|
}
|
367
|
+
async featureSelectionChange() {
|
368
|
+
await this._closeEdit();
|
369
|
+
}
|
367
370
|
//--------------------------------------------------------------------------
|
368
371
|
//
|
369
372
|
// Functions (lifecycle)
|
@@ -393,7 +396,7 @@ const EditCard = class {
|
|
393
396
|
}
|
394
397
|
this._layerEditHandle = this._layer.on("edits", () => {
|
395
398
|
this.editsComplete.emit();
|
396
|
-
this._closeEdit();
|
399
|
+
void this._closeEdit();
|
397
400
|
});
|
398
401
|
}
|
399
402
|
}
|
@@ -406,9 +409,9 @@ const EditCard = class {
|
|
406
409
|
// when you use MULTI edit mode...is fine in SINGLE
|
407
410
|
const editDisabled = ((_a = this.graphics) === null || _a === void 0 ? void 0 : _a.length) > 0 && this.graphics[0] ?
|
408
411
|
!this.graphics[0].layer.editingEnabled : true;
|
409
|
-
const tableNodeClass = this._editorLoading ? "display-none" : "";
|
412
|
+
const tableNodeClass = this._editorLoading ? "display-none" : "position-absolute";
|
410
413
|
const loadingClass = this._editorLoading ? "" : "display-none";
|
411
|
-
return (h(Host, null, h("div", { class: "position-
|
414
|
+
return (h(Host, null, h("div", { class: "position-absolute" }, editDisabled ? (h("calcite-notice", { kind: "warning", open: true, slot: "content-top", width: "full" }, h("div", { slot: "message" }, this._translations.enableEditing))) : undefined, h("div", { class: "position-absolute", slot: "content" }, h("div", { class: tableNodeClass, id: "feature-form", ref: (el) => this._editContainer = el }), h("calcite-loader", { class: loadingClass, scale: "s" })))));
|
412
415
|
}
|
413
416
|
//--------------------------------------------------------------------------
|
414
417
|
//
|
@@ -464,7 +467,7 @@ const EditCard = class {
|
|
464
467
|
});
|
465
468
|
this._editHandle = this.reactiveUtils.when(() => this._editor.viewModel.state === "ready", () => {
|
466
469
|
if (this._shouldClose) {
|
467
|
-
this._closeEdit();
|
470
|
+
void this._closeEdit();
|
468
471
|
}
|
469
472
|
else if (this.graphicIndex > -1 && this.graphics.length > 0 && this.open && !this._shouldClose) {
|
470
473
|
void this._startUpdate();
|
@@ -484,7 +487,13 @@ const EditCard = class {
|
|
484
487
|
*
|
485
488
|
* @returns void
|
486
489
|
*/
|
487
|
-
_closeEdit() {
|
490
|
+
async _closeEdit() {
|
491
|
+
var _a, _b, _c;
|
492
|
+
this._shouldClose = true;
|
493
|
+
if ((_a = this._editor) === null || _a === void 0 ? void 0 : _a.activeWorkflow) {
|
494
|
+
await ((_b = this._editor) === null || _b === void 0 ? void 0 : _b.cancelWorkflow());
|
495
|
+
}
|
496
|
+
(_c = this._editor) === null || _c === void 0 ? void 0 : _c.destroy();
|
488
497
|
this._shouldClose = false;
|
489
498
|
this.closeEdit.emit();
|
490
499
|
}
|
@@ -99,7 +99,7 @@ const CardManager = class {
|
|
99
99
|
};
|
100
100
|
CardManager.style = cardManagerCss;
|
101
101
|
|
102
|
-
const layerTableCss = ":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-ui-border-2)}.border-end{border-inline-end:1px solid var(--calcite-ui-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-ui-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51{height:51px}.bottom-left{position:absolute;left:
|
102
|
+
const layerTableCss = ":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-ui-border-2)}.border-end{border-inline-end:1px solid var(--calcite-ui-border-2)}.border-bottom{border-bottom:1px solid var(--calcite-ui-border-2)}.padding-5{padding:5px}.padding-end-1{padding-inline-end:1rem}.height-51{height:51px}.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-ui-background)}.text-color{color:var(--calcite-ui-text-1)}.align-center{align-items:center}.danger-color{color:var(--calcite-ui-danger)}.esri-feature-table vaadin-grid{border:none !important}vaadin-grid-cell-content{padding:var(--lumo-space-xs) var(--lumo-space-m) !important;font-size:14px !important}";
|
103
103
|
|
104
104
|
const LayerTable = class {
|
105
105
|
constructor(hostRef) {
|
@@ -679,33 +679,30 @@ const LayerTable = class {
|
|
679
679
|
* @returns void
|
680
680
|
*/
|
681
681
|
async _resetTable() {
|
682
|
-
|
683
|
-
|
684
|
-
|
685
|
-
|
686
|
-
|
687
|
-
|
688
|
-
|
689
|
-
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
this._checkEditEnabled();
|
694
|
-
this._table.editingEnabled = this._editEnabled && this.enableInlineEdit;
|
695
|
-
this._initToolInfos();
|
696
|
-
});
|
697
|
-
await this._table.when(() => {
|
698
|
-
this._table.clearSelectionFilter();
|
699
|
-
});
|
700
|
-
this._showOnlySelected = false;
|
701
|
-
this._sortActive = false;
|
702
|
-
await this._sortTable();
|
703
|
-
}
|
704
|
-
else {
|
705
|
-
this._table.view = this.mapView;
|
706
|
-
this._table.layer = this._layer;
|
707
|
-
}
|
682
|
+
var _a, _b;
|
683
|
+
this._clearSelection();
|
684
|
+
this._allIds = [];
|
685
|
+
this.featureSelectionChange.emit(this._selectedIndexes);
|
686
|
+
const columnTemplates = this._getColumnTemplates(this._layer.id, (_b = (_a = this._layer) === null || _a === void 0 ? void 0 : _a.popupTemplate) === null || _b === void 0 ? void 0 : _b.fieldInfos);
|
687
|
+
this._allIds = await queryAllIds(this._layer);
|
688
|
+
if (!this._table) {
|
689
|
+
await this._getTable(this._tableNode, columnTemplates);
|
690
|
+
}
|
691
|
+
else if (columnTemplates) {
|
692
|
+
this._table.tableTemplate.columnTemplates = columnTemplates;
|
708
693
|
}
|
694
|
+
this._table.layer = this._layer;
|
695
|
+
this._table.view = this.mapView;
|
696
|
+
this._checkEditEnabled();
|
697
|
+
this._table.editingEnabled = this._editEnabled && this.enableInlineEdit;
|
698
|
+
this._initToolInfos();
|
699
|
+
await this._table.when(() => {
|
700
|
+
this._table.highlightIds.removeAll();
|
701
|
+
this._table.clearSelectionFilter();
|
702
|
+
});
|
703
|
+
this._showOnlySelected = false;
|
704
|
+
this._sortActive = false;
|
705
|
+
await this._sortTable();
|
709
706
|
}
|
710
707
|
/**
|
711
708
|
* Verify edit capabilities of the layer
|
@@ -907,28 +904,15 @@ const LayerTable = class {
|
|
907
904
|
* @returns a promise that will resolve when the operation is complete
|
908
905
|
*/
|
909
906
|
async _layerSelectionChanged(evt) {
|
910
|
-
var _a
|
907
|
+
var _a;
|
911
908
|
const id = evt.detail[0];
|
912
909
|
if (id !== ((_a = this._layer) === null || _a === void 0 ? void 0 : _a.id) || this._allIds.length === 0) {
|
913
910
|
this._fetchingData = true;
|
914
|
-
|
915
|
-
|
916
|
-
|
917
|
-
if (!this._table) {
|
918
|
-
await this._getTable(this._tableNode, columnTemplates);
|
919
|
-
}
|
920
|
-
else if (columnTemplates) {
|
921
|
-
this._table.tableTemplate.columnTemplates = columnTemplates;
|
922
|
-
}
|
923
|
-
await this._table.when(() => {
|
924
|
-
this._table.highlightIds.removeAll();
|
911
|
+
const layer = await getLayerOrTable(this.mapView, id);
|
912
|
+
await layer.when(() => {
|
913
|
+
this._layer = layer;
|
925
914
|
});
|
926
|
-
this._selectedIndexes = [];
|
927
|
-
this._table.layer = this._layer;
|
928
|
-
this._table.render();
|
929
915
|
}
|
930
|
-
this._sortActive = false;
|
931
|
-
await this._sortTable();
|
932
916
|
this._fetchingData = false;
|
933
917
|
}
|
934
918
|
/**
|