@esri/solutions-components 0.7.39 → 0.7.41
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/cjs/calcite-alert_4.cjs.entry.js +1 -1
- package/dist/cjs/calcite-combobox_5.cjs.entry.js +1 -1
- package/dist/cjs/calcite-flow_5.cjs.entry.js +4 -2
- package/dist/cjs/calcite-input-date-picker_3.cjs.entry.js +70 -31
- package/dist/cjs/card-manager_3.cjs.entry.js +29 -13
- package/dist/cjs/crowdsource-manager.cjs.entry.js +1 -1
- package/dist/cjs/crowdsource-reporter.cjs.entry.js +15 -4
- package/dist/cjs/{downloadUtils-c22a71da.js → downloadUtils-b10e3b8c.js} +2 -2
- package/dist/cjs/{index.es-8d317f5e.js → index.es-b9d6eff6.js} +2 -2
- package/dist/cjs/instant-apps-ckeditor-wrapper_3.cjs.entry.js +5 -4
- package/dist/cjs/instant-apps-export.cjs.entry.js +20 -21
- package/dist/cjs/instant-apps-header.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-language-switcher.cjs.entry.js +3 -3
- package/dist/cjs/instant-apps-language-translator.cjs.entry.js +1 -1
- package/dist/cjs/instant-apps-splash.cjs.entry.js +2 -6
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/map-select-tools_3.cjs.entry.js +2 -2
- package/dist/cjs/{mapViewUtils-cd29b129.js → mapViewUtils-290dbc9e.js} +4 -0
- package/dist/cjs/public-notification.cjs.entry.js +2 -2
- package/dist/cjs/solutions-components.cjs.js +1 -1
- package/dist/collection/components/basemap-gallery/basemap-gallery.css +19 -19
- package/dist/collection/components/crowdsource-reporter/crowdsource-reporter.js +48 -3
- package/dist/collection/components/layer-list/layer-list.js +3 -1
- package/dist/collection/components/layer-table/layer-table.js +28 -11
- package/dist/collection/components/map-fullscreen/map-fullscreen.css +19 -19
- package/dist/collection/components/map-legend/map-legend.css +3 -3
- package/dist/collection/demos/crowdsource-reporter.html +5 -2
- package/dist/collection/utils/interfaces.ts +1 -0
- package/dist/collection/utils/queryUtils.js +4 -0
- package/dist/collection/utils/queryUtils.ts +5 -0
- package/dist/components/crowdsource-reporter.js +16 -3
- package/dist/components/instant-apps-export.js +20 -21
- package/dist/components/instant-apps-filter-list2.js +70 -31
- package/dist/components/instant-apps-header2.js +1 -1
- package/dist/components/instant-apps-language-switcher.js +3 -3
- package/dist/components/instant-apps-language-translator-item2.js +5 -4
- package/dist/components/instant-apps-language-translator2.js +1 -1
- package/dist/components/instant-apps-splash.js +3 -7
- package/dist/components/layer-list2.js +3 -1
- package/dist/components/layer-table2.js +28 -11
- package/dist/components/queryUtils.js +4 -0
- package/dist/esm/calcite-alert_4.entry.js +1 -1
- package/dist/esm/calcite-combobox_5.entry.js +1 -1
- package/dist/esm/calcite-flow_5.entry.js +4 -2
- package/dist/esm/calcite-input-date-picker_3.entry.js +70 -31
- package/dist/esm/card-manager_3.entry.js +29 -13
- package/dist/esm/crowdsource-manager.entry.js +1 -1
- package/dist/esm/crowdsource-reporter.entry.js +15 -4
- package/dist/esm/{downloadUtils-985dcd1c.js → downloadUtils-20d22198.js} +2 -2
- package/dist/esm/{index.es-03d8386e.js → index.es-8b85f68d.js} +2 -2
- package/dist/esm/instant-apps-ckeditor-wrapper_3.entry.js +5 -4
- package/dist/esm/instant-apps-export.entry.js +20 -21
- package/dist/esm/instant-apps-header.entry.js +1 -1
- package/dist/esm/instant-apps-language-switcher.entry.js +3 -3
- package/dist/esm/instant-apps-language-translator.entry.js +1 -1
- package/dist/esm/instant-apps-splash.entry.js +3 -7
- package/dist/esm/loader.js +1 -1
- package/dist/esm/map-select-tools_3.entry.js +2 -2
- package/dist/esm/{mapViewUtils-257bc9b3.js → mapViewUtils-a177d4f9.js} +4 -0
- package/dist/esm/public-notification.entry.js +2 -2
- package/dist/esm/solutions-components.js +1 -1
- package/dist/node_modules/@esri/instant-apps-components/dist/collection/components/instant-apps-filter-list/instant-apps-filter-list.css +8 -1
- package/dist/node_modules/@esri/instant-apps-components/dist/collection/components/instant-apps-header/instant-apps-header.css +3 -0
- package/dist/node_modules/@esri/instant-apps-components/dist/collection/components/instant-apps-splash/instant-apps-splash.css +3 -0
- package/dist/solutions-components/demos/crowdsource-reporter.html +5 -2
- package/dist/solutions-components/{p-8571c89f.entry.js → p-044cd52c.entry.js} +1 -1
- package/dist/solutions-components/{p-df048b47.js → p-17e328bb.js} +1 -1
- package/dist/solutions-components/{p-12492469.entry.js → p-2283ae14.entry.js} +1 -1
- package/dist/solutions-components/p-2f017ad2.entry.js +6 -0
- package/dist/solutions-components/{p-20b206f3.entry.js → p-32adb2cc.entry.js} +1 -1
- package/dist/solutions-components/p-3eedaead.js +36 -0
- package/dist/solutions-components/{p-2f840f08.entry.js → p-42233edc.entry.js} +1 -1
- package/dist/solutions-components/p-4742efa8.entry.js +6 -0
- package/dist/solutions-components/p-57087d57.entry.js +17 -0
- package/dist/solutions-components/{p-34eaca46.entry.js → p-69a1df0f.entry.js} +1 -1
- package/dist/solutions-components/{p-23e58d7c.entry.js → p-6c86a392.entry.js} +3 -3
- package/dist/solutions-components/{p-6419f8d7.entry.js → p-6fe5e1d5.entry.js} +1 -1
- package/dist/solutions-components/p-7480ac64.entry.js +6 -0
- package/dist/solutions-components/p-aecf92f4.entry.js +6 -0
- package/dist/solutions-components/p-c6af6407.entry.js +6 -0
- package/dist/solutions-components/p-cacd0307.entry.js +6 -0
- package/dist/solutions-components/p-e2b0b3fa.entry.js +6 -0
- package/dist/solutions-components/{p-00ba5a2a.js → p-f6536eae.js} +2 -2
- package/dist/solutions-components/solutions-components.esm.js +1 -1
- package/dist/solutions-components/utils/interfaces.ts +1 -0
- package/dist/solutions-components/utils/queryUtils.ts +5 -0
- package/dist/types/components/crowdsource-reporter/crowdsource-reporter.d.ts +9 -0
- package/dist/types/components/layer-list/layer-list.d.ts +1 -0
- package/dist/types/components/layer-table/layer-table.d.ts +9 -1
- package/dist/types/components.d.ts +16 -0
- package/dist/types/utils/interfaces.d.ts +1 -0
- package/dist/types/utils/queryUtils.d.ts +1 -0
- package/package.json +2 -2
- package/dist/solutions-components/p-09b48b1b.entry.js +0 -6
- package/dist/solutions-components/p-32fed23c.entry.js +0 -17
- package/dist/solutions-components/p-6a61c742.entry.js +0 -6
- package/dist/solutions-components/p-9161dca9.entry.js +0 -6
- package/dist/solutions-components/p-93369c9f.entry.js +0 -6
- package/dist/solutions-components/p-96f5be25.js +0 -36
- package/dist/solutions-components/p-97425481.entry.js +0 -6
- package/dist/solutions-components/p-ae4c8b8c.entry.js +0 -6
- package/dist/solutions-components/p-eb0f4ede.entry.js +0 -6
|
@@ -65,7 +65,7 @@ function resetDatePicker(datePicker) {
|
|
|
65
65
|
}
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
const instantAppsFilterListCss = ":host{display:block}.instant-apps-filter-list *{box-sizing:border-box}.instant-apps-filter-list__container{height:100%}.instant-apps-filter-list__container calcite-block:last-of-type{margin-bottom:0}.instant-apps-filter-list__footer{padding:12px;display:flex}.instant-apps-filter-list__footer calcite-button:nth-child(2){margin-left:6px}.instant-apps-filter-list__item-container,.instant-apps-filter-list__item-container--user-input{display:flex;justify-content:space-between;align-items:center}.instant-apps-filter-list__item-container:not(:last-child),.instant-apps-filter-list__item-container--user-input:not(:last-child){padding-bottom:20px}.instant-apps-filter-list__item-container--user-input{margin:0;display:flex;flex-direction:column;align-items:flex-start}.instant-apps-filter-list__item-container--user-input>span{margin:0 0 6px;font-size:14px;font-weight:normal}.instant-apps-filter-list__item-container--user-input calcite-combobox{width:100
|
|
68
|
+
const instantAppsFilterListCss = ":host{display:block}.instant-apps-filter-list *{box-sizing:border-box}.instant-apps-filter-list__container{height:100%}.instant-apps-filter-list__container calcite-block:last-of-type{margin-bottom:0}.instant-apps-filter-list__footer{padding:12px;display:flex}.instant-apps-filter-list__footer calcite-button:nth-child(2){margin-left:6px}.instant-apps-filter-list__item-container,.instant-apps-filter-list__item-container--user-input{display:flex;justify-content:space-between;align-items:center}.instant-apps-filter-list__item-container:not(:last-child),.instant-apps-filter-list__item-container--user-input:not(:last-child){padding-bottom:20px}.instant-apps-filter-list__item-container--user-input{margin:0;display:flex;flex-direction:column;align-items:flex-start}.instant-apps-filter-list__item-container--user-input>span{margin:0 0 6px;font-size:14px;font-weight:normal}.instant-apps-filter-list__item-container--user-input calcite-combobox{width:100%;--calcite-font-size--1:16px}.instant-apps-filter-list__item-container--user-input calcite-combobox-item{--calcite-font-size--1:12px}.instant-apps-filter-list__number-input-container{width:100%;display:flex;justify-content:center}.instant-apps-filter-list__number-input-container calcite-slider{width:90%}.instant-apps-filter-list__date-picker-input-container{display:flex;align-items:center;justify-content:unset;width:100%}.instant-apps-filter-list__date-picker-input-container calcite-action{height:64px;border-top:1px solid var(--calcite-color-border-input);border-right:1px solid var(--calcite-color-border-input);border-bottom:1px solid var(--calcite-color-border-input)}.instant-apps-filter-list__title{margin-right:20px}.instant-apps-filter-list__title>p{font-size:14px;font-weight:normal;margin:0}.instant-apps-filter-list__checkbox-container{display:flex}.instant-apps-filter-list__checkbox-container calcite-checkbox{height:18px}.instant-apps-filter-list__operator-description{margin:0;--calcite-font-size--1:12px}.instant-apps-filter-list__zoom-to{display:flex;justify-content:flex-end;margin:8px 0 20px}.instant-apps-filter-list__zoom-to calcite-action{width:-moz-min-content;width:min-content}.instant-apps-filter-list calcite-input-date-picker{--calcite-font-size--1:16px}@media (prefers-reduced-motion){.instant-apps-filter-list calcite-loader{--calcite-internal-duration-factor:2;--calcite-internal-animation-timing-slow:calc(300ms * 2)}}.instant-apps-filter-list.calcite-mode-dark .instant-apps-filter-list__header-container{background:#2b2b2b;color:#fff}.instant-apps-filter-list.calcite-mode-dark .instant-apps-filter-list__operator-description{background:#353535}";
|
|
69
69
|
|
|
70
70
|
const CSS = {
|
|
71
71
|
base: 'instant-apps-filter-list',
|
|
@@ -154,6 +154,7 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
154
154
|
this.geometryJsonUtils = geometryJsonUtils;
|
|
155
155
|
this.reactiveUtils = reactiveUtils;
|
|
156
156
|
this.locale = intl.getLocale();
|
|
157
|
+
this.intl = intl;
|
|
157
158
|
return Promise.resolve();
|
|
158
159
|
}
|
|
159
160
|
render() {
|
|
@@ -185,24 +186,13 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
185
186
|
}
|
|
186
187
|
renderCombobox(layerExpression, expression) {
|
|
187
188
|
var _a;
|
|
188
|
-
return (h("label", { key: "combo-select", class: CSS.filterUIItemContainer }, h("span", null, expression.name), h("calcite-combobox", { id: expression.id.toString(), onCalciteComboboxChange: this.handleComboSelect.bind(this, expression, layerExpression), label: expression.name, placeholder: expression.placeholder,
|
|
189
|
+
return (h("label", { key: "combo-select", class: CSS.filterUIItemContainer }, h("span", null, expression.name), h("calcite-combobox", { id: expression.id.toString(), onCalciteComboboxChange: this.handleComboSelect.bind(this, expression, layerExpression), label: expression.name, placeholder: expression.placeholder, selectionMode: "multiple", "max-items": "6" }, (_a = expression.fields) === null || _a === void 0 ? void 0 : _a.map((value, index) => this.renderComboboxItem(expression, value, index)))));
|
|
189
190
|
}
|
|
190
191
|
renderComboboxItem(expression, value, index) {
|
|
191
|
-
var _a
|
|
192
|
-
|
|
193
|
-
if (expression.type === 'coded-value') {
|
|
194
|
-
label = (_a = expression.codedValues) === null || _a === void 0 ? void 0 : _a[value];
|
|
195
|
-
}
|
|
196
|
-
else if (expression.type === 'number' && typeof value === 'number' && expression.format != null) {
|
|
197
|
-
if (expression.format.places != null) {
|
|
198
|
-
label = this.roundNumber(value, expression.format.places);
|
|
199
|
-
}
|
|
200
|
-
if (expression.format.digitSeparator) {
|
|
201
|
-
label = this.numberWithCommas(label);
|
|
202
|
-
}
|
|
203
|
-
}
|
|
192
|
+
var _a;
|
|
193
|
+
const label = this.createLabel(expression, value);
|
|
204
194
|
const selectedFields = expression === null || expression === void 0 ? void 0 : expression.selectedFields;
|
|
205
|
-
const selected = (
|
|
195
|
+
const selected = (_a = selectedFields === null || selectedFields === void 0 ? void 0 : selectedFields.includes(value)) !== null && _a !== void 0 ? _a : false;
|
|
206
196
|
return h("calcite-combobox-item", { key: `${label}-${index}`, value: value, textLabel: `${label}`, selected: selected });
|
|
207
197
|
}
|
|
208
198
|
initFilterConfig() {
|
|
@@ -234,11 +224,10 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
234
224
|
}
|
|
235
225
|
renderDatePicker(layerExpression, expression) {
|
|
236
226
|
var _a, _b, _c, _d;
|
|
237
|
-
const min =
|
|
238
|
-
const max = convertToDate(expression.max);
|
|
227
|
+
const { min, max } = expression;
|
|
239
228
|
const value = [(_a = expression === null || expression === void 0 ? void 0 : expression.range) === null || _a === void 0 ? void 0 : _a.min, (_b = expression === null || expression === void 0 ? void 0 : expression.range) === null || _b === void 0 ? void 0 : _b.max];
|
|
240
229
|
const check = min != null && max != null;
|
|
241
|
-
return check ? (h("label", { class: CSS.filterUIItemContainer }, h("span", null, expression === null || expression === void 0 ? void 0 : expression.name), h("div", { class: CSS.dateInputContainer }, h("calcite-input-date-picker", { id: expression === null || expression === void 0 ? void 0 : expression.id.toString(), onCalciteInputDatePickerChange: this.handleDatePickerRangeChange.bind(this, expression, layerExpression), min: min, max: max,
|
|
230
|
+
return check ? (h("label", { class: CSS.filterUIItemContainer }, h("span", null, expression === null || expression === void 0 ? void 0 : expression.name), h("div", { class: CSS.dateInputContainer }, h("calcite-input-date-picker", { id: expression === null || expression === void 0 ? void 0 : expression.id.toString(), onCalciteInputDatePickerChange: this.handleDatePickerRangeChange.bind(this, expression, layerExpression), min: min, max: max, "overlay-positioning": "fixed", lang: (_c = this.locale) !== null && _c !== void 0 ? _c : 'en', layout: "vertical", value: value, range: true }), h("calcite-action", { onClick: this.handleResetDatePicker.bind(this, expression, layerExpression), icon: "reset", text: (_d = this.messages) === null || _d === void 0 ? void 0 : _d.resetDatePicker, scale: "s" })))) : null;
|
|
242
231
|
}
|
|
243
232
|
renderFooter() {
|
|
244
233
|
var _a;
|
|
@@ -308,7 +297,12 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
308
297
|
this.resetCombobox(expression);
|
|
309
298
|
}
|
|
310
299
|
else if (type === 'date') {
|
|
311
|
-
|
|
300
|
+
if ((expression === null || expression === void 0 ? void 0 : expression.numDisplayOption) === 'drop-down' || (expression === null || expression === void 0 ? void 0 : expression.displayOption) === 'drop-down') {
|
|
301
|
+
this.resetCombobox(expression);
|
|
302
|
+
}
|
|
303
|
+
else {
|
|
304
|
+
this.resetDatePicker(expression);
|
|
305
|
+
}
|
|
312
306
|
}
|
|
313
307
|
else if (type === 'number' || type === 'range') {
|
|
314
308
|
if ((expression === null || expression === void 0 ? void 0 : expression.numDisplayOption) === 'drop-down' || (expression === null || expression === void 0 ? void 0 : expression.displayOption) === 'drop-down') {
|
|
@@ -384,9 +378,15 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
384
378
|
});
|
|
385
379
|
}
|
|
386
380
|
async updateStringExpression(layerExpression, expression) {
|
|
387
|
-
const { field } = expression;
|
|
381
|
+
const { field, type } = expression;
|
|
388
382
|
const layer = this.findFilterLayer(layerExpression);
|
|
389
383
|
expression.fields = await this.getFeatureAttributes(layer, field);
|
|
384
|
+
if (type === 'date') {
|
|
385
|
+
const layerField = layer.fields.find(({ name }) => name === field);
|
|
386
|
+
if ((layerField === null || layerField === void 0 ? void 0 : layerField.type) === 'date-only') {
|
|
387
|
+
expression.dateOnly = true;
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
390
|
if (expression === null || expression === void 0 ? void 0 : expression.selectedFields) {
|
|
391
391
|
const selectedFields = expression.selectedFields.map((field) => (typeof field === 'number' ? field : `'${handleSingleQuote(field)}'`));
|
|
392
392
|
expression.definitionExpression = `${field} IN (${selectedFields.join(',')})`;
|
|
@@ -647,12 +647,18 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
647
647
|
handleComboSelect(expression, layerExpression, event) {
|
|
648
648
|
const combobox = event.target;
|
|
649
649
|
const items = combobox.selectedItems;
|
|
650
|
-
const { field } = expression;
|
|
650
|
+
const { field, type } = expression;
|
|
651
651
|
if (items && items.length) {
|
|
652
652
|
const values = items.map(({ value }) => (typeof value === 'number' ? value : `'${handleSingleQuote(value)}'`));
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
653
|
+
if (type === 'date') {
|
|
654
|
+
expression.selectedFields = items.map(({ value }) => value);
|
|
655
|
+
expression.definitionExpression = values.map(value => this.buildDateExpression(value, field)).join(' OR ');
|
|
656
|
+
}
|
|
657
|
+
else {
|
|
658
|
+
expression.selectedFields = items.map(({ value }) => value);
|
|
659
|
+
const definitionExpression = `${field} IN (${values.join(',')})`;
|
|
660
|
+
expression.definitionExpression = definitionExpression;
|
|
661
|
+
}
|
|
656
662
|
expression.active = true;
|
|
657
663
|
}
|
|
658
664
|
else {
|
|
@@ -709,20 +715,20 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
709
715
|
}
|
|
710
716
|
createURLParamExpression(layerExpression, expression) {
|
|
711
717
|
const { id, range, selectedFields, type } = expression;
|
|
712
|
-
if (type === '
|
|
718
|
+
if (type === 'string' || type === 'coded-value' || (expression === null || expression === void 0 ? void 0 : expression.numDisplayOption) === 'drop-down' || (expression === null || expression === void 0 ? void 0 : expression.displayOption) === 'drop-down') {
|
|
713
719
|
return {
|
|
714
|
-
type: '
|
|
720
|
+
type: 'select',
|
|
715
721
|
layerId: layerExpression.id,
|
|
716
722
|
expressionId: id.toString(),
|
|
717
|
-
|
|
723
|
+
selectedFields,
|
|
718
724
|
};
|
|
719
725
|
}
|
|
720
|
-
else if (type === '
|
|
726
|
+
else if (type === 'number' || type === 'range' || type === 'date') {
|
|
721
727
|
return {
|
|
722
|
-
type: '
|
|
728
|
+
type: 'range',
|
|
723
729
|
layerId: layerExpression.id,
|
|
724
730
|
expressionId: id.toString(),
|
|
725
|
-
|
|
731
|
+
range,
|
|
726
732
|
};
|
|
727
733
|
}
|
|
728
734
|
else {
|
|
@@ -1018,6 +1024,39 @@ const InstantAppsFilterList = /*@__PURE__*/ proxyCustomElement(class InstantApps
|
|
|
1018
1024
|
return layer;
|
|
1019
1025
|
}
|
|
1020
1026
|
}
|
|
1027
|
+
createLabel(expression, value) {
|
|
1028
|
+
var _a;
|
|
1029
|
+
let label = value;
|
|
1030
|
+
if (expression.type === 'coded-value') {
|
|
1031
|
+
label = (_a = expression.codedValues) === null || _a === void 0 ? void 0 : _a[value];
|
|
1032
|
+
}
|
|
1033
|
+
else if (expression.type === 'number' && typeof value === 'number' && expression.format != null) {
|
|
1034
|
+
if (expression.format.places != null) {
|
|
1035
|
+
label = this.roundNumber(value, expression.format.places);
|
|
1036
|
+
}
|
|
1037
|
+
if (expression.format.digitSeparator) {
|
|
1038
|
+
label = this.numberWithCommas(label);
|
|
1039
|
+
}
|
|
1040
|
+
}
|
|
1041
|
+
else if (expression.type === 'date' && !expression.dateOnly) {
|
|
1042
|
+
const format = expression.dateOnly ? this.intl.convertDateFormatToIntlOptions('short-date-long-time') : undefined;
|
|
1043
|
+
label = this.intl.formatDate(value, format);
|
|
1044
|
+
}
|
|
1045
|
+
return label;
|
|
1046
|
+
}
|
|
1047
|
+
buildDateExpression(date, field) {
|
|
1048
|
+
if (date) {
|
|
1049
|
+
const tmpDate = new Date(date);
|
|
1050
|
+
const tmpCompareDate = new Date(date);
|
|
1051
|
+
const tmpCompareDate1 = new Date(tmpCompareDate.setDate(tmpDate.getDate() + 1));
|
|
1052
|
+
const formattedDate = `${tmpDate.getFullYear()}-${tmpDate.getMonth() + 1}-${tmpDate.getDate()}`;
|
|
1053
|
+
const time = `${tmpDate.getHours()}:${tmpDate.getMinutes()}:${tmpDate.getSeconds()}`;
|
|
1054
|
+
const compareTime = `${tmpCompareDate1.getHours()}:${tmpCompareDate1.getMinutes()}:${tmpCompareDate1.getSeconds()}`;
|
|
1055
|
+
const compareFormattedDate = `${tmpCompareDate1.getFullYear()}-${tmpCompareDate1.getMonth() + 1}-${tmpCompareDate1.getDate()}`;
|
|
1056
|
+
return `${field} BETWEEN '${formattedDate} ${time}' AND '${compareFormattedDate} ${compareTime}'`;
|
|
1057
|
+
}
|
|
1058
|
+
return;
|
|
1059
|
+
}
|
|
1021
1060
|
get el() { return this; }
|
|
1022
1061
|
static get watchers() { return {
|
|
1023
1062
|
"view": ["watchViewHandler"],
|
|
@@ -12,7 +12,7 @@ import { d as defineCustomElement$3 } from './button.js';
|
|
|
12
12
|
import { d as defineCustomElement$2 } from './icon.js';
|
|
13
13
|
import { d as defineCustomElement$1 } from './loader.js';
|
|
14
14
|
|
|
15
|
-
const instantAppsHeaderCss = ":host{--instant-apps-header-height:auto;--instant-apps-header-min-height:50px;--instant-apps-header-title-text-link-decoration:underline;--instant-apps-header-height--logo-scale--s:55px;--instant-apps-header-logo-width--logo-scale--s:35px;--instant-apps-header-logo-height--logo-scale--s:35px;--instant-apps-header-height--logo-scale--m:70px;--instant-apps-header-logo-width--logo-scale--m:50px;--instant-apps-header-logo-height--logo-scale--m:50px;--instant-apps-header-height--logo-scale--l:80px;--instant-apps-header-logo-width--logo-scale--l:60px;--instant-apps-header-logo-height--logo-scale--l:60px;width:100%}:host .instant-apps-header--standard{box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;width:100%;height:var(--instant-apps-header-height);background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-1);font-family:var(--calcite-sans-family);min-height:var(--instant-apps-header-min-height)}:host .instant-apps-header--standard .instant-apps-header__header-container{display:flex;align-items:center;width:100%;height:inherit}:host .instant-apps-header--standard .instant-apps-header__header-container slot{display:flex;height:inherit}:host .instant-apps-header--standard .instant-apps-header__header-container ::slotted(*){display:flex;min-height:var(--instant-apps-header-min-height);height:var(--instant-apps-header-height)}:host .instant-apps-header--standard .instant-apps-header__header-container ::slotted(*) calcite-button{height:100%}:host .instant-apps-header--standard .instant-apps-header__header-content{box-sizing:border-box;display:flex;align-items:center;width:100%;min-width:0;height:inherit;padding:5px 10px}:host .instant-apps-header--standard .instant-apps-header__header-content a{display:flex;align-items:center;-webkit-text-decoration:var(--instant-apps-header-title-text-link-decoration);text-decoration:var(--instant-apps-header-title-text-link-decoration)}:host .instant-apps-header--standard .instant-apps-header__header-content a img{padding-right:0}:host .instant-apps-header--standard .instant-apps-header__header-content img{margin:10px}:host .instant-apps-header--standard .instant-apps-header__header-content h1{margin:0;font-size:1.25rem;color:var(--calcite-color-text-1);font-weight:430;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}:host .instant-apps-header--standard .instant-apps-header__header-content #infoButton{margin-inline-start:10px}:host .instant-apps-header--standard .instant-apps-header__header-content--center{justify-content:center}:host .instant-apps-header--standard .instant-apps-header__header-content--right{justify-content:end}:host .instant-apps-header__logo-height--s{height:var(--instant-apps-header-height--logo-scale--s)}:host .instant-apps-header__logo-height--s .instant-apps-header__header-content h1{font-size:1.125rem}:host .instant-apps-header__logo-scale--s{width:var(--instant-apps-header-logo-width--logo-scale--s);height:var(--instant-apps-header-logo-height--logo-scale--s)}:host .instant-apps-header__logo-height--m{height:var(--instant-apps-header-height--logo-scale--m)}:host .instant-apps-header__logo-scale--m{width:var(--instant-apps-header-logo-width--logo-scale--m);height:var(--instant-apps-header-logo-height--logo-scale--m)}:host .instant-apps-header__logo-height--l{height:var(--instant-apps-header-height--logo-scale--l)}:host .instant-apps-header__logo-height--l .instant-apps-header__header-content h1{font-size:1.375rem}:host .instant-apps-header__logo-scale--l{width:var(--instant-apps-header-logo-width--logo-scale--l);height:var(--instant-apps-header-logo-height--logo-scale--l)}:host .instant-apps-header__logo-height--s,:host .instant-apps-header__logo-height--m,:host .instant-apps-header__logo-height--l{padding-right:10px}:host .instant-apps-header--rtl.instant-apps-header__logo-height--s,:host .instant-apps-header--rtl.instant-apps-header__logo-height--m,:host .instant-apps-header--rtl.instant-apps-header__logo-height--l{padding-right:0;padding-left:10px}";
|
|
15
|
+
const instantAppsHeaderCss = ":host{--instant-apps-header-height:auto;--instant-apps-header-min-height:50px;--instant-apps-header-title-text-link-decoration:underline;--instant-apps-header-height--logo-scale--s:55px;--instant-apps-header-logo-width--logo-scale--s:35px;--instant-apps-header-logo-height--logo-scale--s:35px;--instant-apps-header-height--logo-scale--m:70px;--instant-apps-header-logo-width--logo-scale--m:50px;--instant-apps-header-logo-height--logo-scale--m:50px;--instant-apps-header-height--logo-scale--l:80px;--instant-apps-header-logo-width--logo-scale--l:60px;--instant-apps-header-logo-height--logo-scale--l:60px;width:100%}:host .image.image_resized img{width:100%}:host .instant-apps-header--standard{box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;width:100%;height:var(--instant-apps-header-height);background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-1);font-family:var(--calcite-sans-family);min-height:var(--instant-apps-header-min-height)}:host .instant-apps-header--standard .instant-apps-header__header-container{display:flex;align-items:center;width:100%;height:inherit}:host .instant-apps-header--standard .instant-apps-header__header-container slot{display:flex;height:inherit}:host .instant-apps-header--standard .instant-apps-header__header-container ::slotted(*){display:flex;min-height:var(--instant-apps-header-min-height);height:var(--instant-apps-header-height)}:host .instant-apps-header--standard .instant-apps-header__header-container ::slotted(*) calcite-button{height:100%}:host .instant-apps-header--standard .instant-apps-header__header-content{box-sizing:border-box;display:flex;align-items:center;width:100%;min-width:0;height:inherit;padding:5px 10px}:host .instant-apps-header--standard .instant-apps-header__header-content a{display:flex;align-items:center;-webkit-text-decoration:var(--instant-apps-header-title-text-link-decoration);text-decoration:var(--instant-apps-header-title-text-link-decoration)}:host .instant-apps-header--standard .instant-apps-header__header-content a img{padding-right:0}:host .instant-apps-header--standard .instant-apps-header__header-content img{margin:10px}:host .instant-apps-header--standard .instant-apps-header__header-content h1{margin:0;font-size:1.25rem;color:var(--calcite-color-text-1);font-weight:430;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}:host .instant-apps-header--standard .instant-apps-header__header-content #infoButton{margin-inline-start:10px}:host .instant-apps-header--standard .instant-apps-header__header-content--center{justify-content:center}:host .instant-apps-header--standard .instant-apps-header__header-content--right{justify-content:end}:host .instant-apps-header__logo-height--s{height:var(--instant-apps-header-height--logo-scale--s)}:host .instant-apps-header__logo-height--s .instant-apps-header__header-content h1{font-size:1.125rem}:host .instant-apps-header__logo-scale--s{width:var(--instant-apps-header-logo-width--logo-scale--s);height:var(--instant-apps-header-logo-height--logo-scale--s)}:host .instant-apps-header__logo-height--m{height:var(--instant-apps-header-height--logo-scale--m)}:host .instant-apps-header__logo-scale--m{width:var(--instant-apps-header-logo-width--logo-scale--m);height:var(--instant-apps-header-logo-height--logo-scale--m)}:host .instant-apps-header__logo-height--l{height:var(--instant-apps-header-height--logo-scale--l)}:host .instant-apps-header__logo-height--l .instant-apps-header__header-content h1{font-size:1.375rem}:host .instant-apps-header__logo-scale--l{width:var(--instant-apps-header-logo-width--logo-scale--l);height:var(--instant-apps-header-logo-height--logo-scale--l)}:host .instant-apps-header__logo-height--s,:host .instant-apps-header__logo-height--m,:host .instant-apps-header__logo-height--l{padding-right:10px}:host .instant-apps-header--rtl.instant-apps-header__logo-height--s,:host .instant-apps-header--rtl.instant-apps-header__logo-height--m,:host .instant-apps-header--rtl.instant-apps-header__logo-height--l{padding-right:0;padding-left:10px}";
|
|
16
16
|
|
|
17
17
|
const CSS = {
|
|
18
18
|
base: 'instant-apps-header--standard',
|
|
@@ -45,7 +45,7 @@ const InstantAppsLanguageSwitcher$1 = /*@__PURE__*/ proxyCustomElement(class Ins
|
|
|
45
45
|
this.t9nData = null;
|
|
46
46
|
}
|
|
47
47
|
async componentWillLoad() {
|
|
48
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
48
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
49
49
|
const [intl, WebMap, request] = await loadModules(['esri/intl', 'esri/WebMap', 'esri/request']);
|
|
50
50
|
this.intl = intl;
|
|
51
51
|
this.request = request;
|
|
@@ -77,8 +77,8 @@ const InstantAppsLanguageSwitcher$1 = /*@__PURE__*/ proxyCustomElement(class Ins
|
|
|
77
77
|
}
|
|
78
78
|
if (this.view) {
|
|
79
79
|
const webmap = this.view.map;
|
|
80
|
-
this.defaultWebMapId = webmap.portalItem.id;
|
|
81
|
-
const translatedWebmap = (
|
|
80
|
+
this.defaultWebMapId = (_j = webmap === null || webmap === void 0 ? void 0 : webmap.portalItem) === null || _j === void 0 ? void 0 : _j.id;
|
|
81
|
+
const translatedWebmap = (_m = (_l = (_k = this.locales) === null || _k === void 0 ? void 0 : _k.filter(localeItem => (localeItem === null || localeItem === void 0 ? void 0 : localeItem.webmap) && (localeItem === null || localeItem === void 0 ? void 0 : localeItem.webmap) !== this.defaultWebMapId && (localeItem === null || localeItem === void 0 ? void 0 : localeItem.locale) === this.selectedLanguage)) === null || _l === void 0 ? void 0 : _l[0]) === null || _m === void 0 ? void 0 : _m.webmap;
|
|
82
82
|
if (translatedWebmap) {
|
|
83
83
|
this.view.map = new WebMap({
|
|
84
84
|
portalItem: {
|
|
@@ -89,13 +89,13 @@ const InstantAppsLanguageTranslatorItem = /*@__PURE__*/ proxyCustomElement(class
|
|
|
89
89
|
return (h("div", { class: `${CSS.section}${selected}` }, this.renderItemHeader(EInputType.User, label, uid), this.handleInputRender(EInputType.User, value, uid)));
|
|
90
90
|
}
|
|
91
91
|
renderTranslatedLanguageSection() {
|
|
92
|
-
var _a;
|
|
92
|
+
var _a, _b;
|
|
93
93
|
const uiDataItem = this.getUIDataItem();
|
|
94
94
|
const uid = this.setting.id;
|
|
95
95
|
const locale = store.get('currentLanguage');
|
|
96
96
|
const data = store.get('portalItemResourceT9n');
|
|
97
|
-
const label = this.translatedLanguageLabels[this.fieldName];
|
|
98
|
-
const value = (
|
|
97
|
+
const label = (_a = this.translatedLanguageLabels) === null || _a === void 0 ? void 0 : _a[this.fieldName];
|
|
98
|
+
const value = (_b = data === null || data === void 0 ? void 0 : data[locale]) === null || _b === void 0 ? void 0 : _b[uid];
|
|
99
99
|
const selected = (uiDataItem === null || uiDataItem === void 0 ? void 0 : uiDataItem.selected) ? ` ${CSS.selected}` : '';
|
|
100
100
|
return (h("div", { class: `${CSS.section}${selected}` }, this.renderItemHeader(EInputType.Translation, label, uid), this.handleInputRender(EInputType.Translation, value, uid)));
|
|
101
101
|
}
|
|
@@ -110,13 +110,14 @@ const InstantAppsLanguageTranslatorItem = /*@__PURE__*/ proxyCustomElement(class
|
|
|
110
110
|
return content === null || content === void 0 ? void 0 : content.map(contentItem => (contentItem.hasOwnProperty('content') ? this.renderNestedInputs(inputType, contentItem) : this.renderNestedInput(inputType, contentItem)));
|
|
111
111
|
}
|
|
112
112
|
renderNestedInput(inputType, contentItem) {
|
|
113
|
+
var _a;
|
|
113
114
|
const locale = store.get('currentLanguage');
|
|
114
115
|
const data = store.get('portalItemResourceT9n');
|
|
115
116
|
const uid = contentItem === null || contentItem === void 0 ? void 0 : contentItem.id;
|
|
116
117
|
const localeData = data === null || data === void 0 ? void 0 : data[locale];
|
|
117
118
|
const translatedValue = localeData === null || localeData === void 0 ? void 0 : localeData[uid];
|
|
118
119
|
const { label, value, id } = contentItem;
|
|
119
|
-
const inputLabel = inputType === EInputType.Translation ? this.translatedLanguageLabels[id] : label;
|
|
120
|
+
const inputLabel = inputType === EInputType.Translation ? (_a = this.translatedLanguageLabels) === null || _a === void 0 ? void 0 : _a[id] : label;
|
|
120
121
|
const isUser = inputType === EInputType.User;
|
|
121
122
|
const inputValue = isUser ? value : translatedValue;
|
|
122
123
|
return (h("div", { class: CSS.nestedInput }, this.renderItemHeader(inputType, inputLabel, uid, contentItem), this.renderInput(inputType, inputValue, uid, contentItem)));
|
|
@@ -221,7 +221,7 @@ const InstantAppsLanguageTranslator = /*@__PURE__*/ proxyCustomElement(class Ins
|
|
|
221
221
|
return (h("instant-apps-language-translator-search", { onSuggestionSelected: this.onSuggestionSelect.bind(this), t9nPlaceholder: (_a = this.messages) === null || _a === void 0 ? void 0 : _a.searchPlaceholder }));
|
|
222
222
|
}
|
|
223
223
|
renderTrailingTopBarSection() {
|
|
224
|
-
return h("div", { class: CSS.topBarSection }, this.renderLanguageSelection());
|
|
224
|
+
return (h("div", { class: CSS.topBarSection }, this.renderLanguageSelection(), h("slot", { name: "translation-custom-action" })));
|
|
225
225
|
}
|
|
226
226
|
renderLanguageSelection() {
|
|
227
227
|
var _a;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
7
7
|
import { S as Sanitizer } from './index3.js';
|
|
8
|
-
import {
|
|
8
|
+
import { g as getMessages } from './locale3.js';
|
|
9
9
|
import { d as defineCustomElement$8 } from './button.js';
|
|
10
10
|
import { d as defineCustomElement$7 } from './checkbox.js';
|
|
11
11
|
import { d as defineCustomElement$6 } from './icon.js';
|
|
@@ -53,7 +53,7 @@ function removeItemFromLocalStorage(key) {
|
|
|
53
53
|
(_a = window === null || window === void 0 ? void 0 : window.localStorage) === null || _a === void 0 ? void 0 : _a.removeItem(key);
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
const instantAppsSplashCss = ":host{display:block}:host .instant-apps-splash__back-content{display:flex;align-items:center}:host .instant-apps-splash__back-content calcite-label{--calcite-label-margin-bottom:0}";
|
|
56
|
+
const instantAppsSplashCss = ":host{display:block}:host .image.image_resized img{width:100%}:host .instant-apps-splash__back-content{display:flex;align-items:center}:host .instant-apps-splash__back-content calcite-label{--calcite-label-margin-bottom:0}";
|
|
57
57
|
|
|
58
58
|
const CSS = {
|
|
59
59
|
back: 'instant-apps-splash__back-content',
|
|
@@ -90,7 +90,7 @@ const InstantAppsSplash$1 = /*@__PURE__*/ proxyCustomElement(class InstantAppsSp
|
|
|
90
90
|
this.sanitizeContent();
|
|
91
91
|
}
|
|
92
92
|
componentDidLoad() {
|
|
93
|
-
this
|
|
93
|
+
getMessages(this);
|
|
94
94
|
}
|
|
95
95
|
render() {
|
|
96
96
|
return (h("calcite-modal", { onCalciteModalClose: this.close.bind(this), open: this.open, closeButtonDisabled: this.closeButtonDisabled }, this.renderHeader(), this.renderContent(), this.localStorageKey ? this.renderDontShowThisAgainCheckbox() : null, this.renderPrimaryButton()));
|
|
@@ -117,10 +117,6 @@ const InstantAppsSplash$1 = /*@__PURE__*/ proxyCustomElement(class InstantAppsSp
|
|
|
117
117
|
this.open = false;
|
|
118
118
|
this.splashClose.emit();
|
|
119
119
|
}
|
|
120
|
-
async setMessages() {
|
|
121
|
-
const messages = await getLocaleComponentStrings(this.el);
|
|
122
|
-
this.messages = messages[0];
|
|
123
|
-
}
|
|
124
120
|
handleDontShowThisAgain(event) {
|
|
125
121
|
const { localStorageKey } = this;
|
|
126
122
|
if (!localStorageKey)
|
|
@@ -27,6 +27,8 @@ const LayerList = /*@__PURE__*/ proxyCustomElement(class LayerList extends HTMLE
|
|
|
27
27
|
this.__registerHost();
|
|
28
28
|
this.layerSelect = createEvent(this, "layerSelect", 7);
|
|
29
29
|
this.layersListLoaded = createEvent(this, "layersListLoaded", 7);
|
|
30
|
+
//HARDCODED IN EN
|
|
31
|
+
this._noLayerToDisplayErrorMsg = "Web map does not contain any editable layers.";
|
|
30
32
|
this.mapView = undefined;
|
|
31
33
|
this.layers = undefined;
|
|
32
34
|
this.noLayerErrorMsg = undefined;
|
|
@@ -79,7 +81,7 @@ const LayerList = /*@__PURE__*/ proxyCustomElement(class LayerList extends HTMLE
|
|
|
79
81
|
*/
|
|
80
82
|
render() {
|
|
81
83
|
return (h(Fragment, null, this._isLoading && h("calcite-loader", { label: "", scale: "m" }), !this._isLoading && this.mapView && this._noLayersToDisplay &&
|
|
82
|
-
h("calcite-notice", { class: "error-msg", icon: "layers-reference", kind: "danger", open: true }, h("div", { slot: "title" }, this._translations.error), h("div", { slot: "message" }, this.noLayerErrorMsg ? this.noLayerErrorMsg : this.
|
|
84
|
+
h("calcite-notice", { class: "error-msg", icon: "layers-reference", kind: "danger", open: true }, h("div", { slot: "title" }, this._translations.error), h("div", { slot: "message" }, this.noLayerErrorMsg ? this.noLayerErrorMsg : this._noLayerToDisplayErrorMsg)), !this._isLoading && this.mapView &&
|
|
83
85
|
h("calcite-list", { "selection-appearance": "border", "selection-mode": this.showNextIcon ? "none" : "single-persist" }, this.renderLayerList())));
|
|
84
86
|
}
|
|
85
87
|
//--------------------------------------------------------------------------
|
|
@@ -120,6 +120,7 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
120
120
|
this.showNewestFirst = undefined;
|
|
121
121
|
this.zoomAndScrollToSelected = undefined;
|
|
122
122
|
this._controlsThatFit = undefined;
|
|
123
|
+
this._csvExporting = false;
|
|
123
124
|
this._fetchingData = false;
|
|
124
125
|
this._filterActive = false;
|
|
125
126
|
this._filterOpen = false;
|
|
@@ -396,8 +397,8 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
396
397
|
if (cur && !cur.isOverflow) {
|
|
397
398
|
prev.push(cur.isDanger ?
|
|
398
399
|
this._getDangerAction(cur.icon, cur.label, cur.func, cur.disabled) :
|
|
399
|
-
cur.isSublist ? (h("calcite-dropdown", { closeOnSelectDisabled: true, id: this._getId(cur.icon), onCalciteDropdownBeforeClose: () => this._forceShowHide(), ref: (el) => this._showHideDropdown = el }, this._getAction(cur.active, this._showHideOpen ? "chevron-down" : cur.icon, cur.indicator, cur.label, cur.func, cur.disabled, "trigger"), this._showHideOpen ? this._getFieldlist() : undefined)) :
|
|
400
|
-
this._getAction(cur.active, cur.icon, cur.indicator, cur.label, cur.func, cur.disabled));
|
|
400
|
+
cur.isSublist ? (h("calcite-dropdown", { closeOnSelectDisabled: true, id: this._getId(cur.icon), onCalciteDropdownBeforeClose: () => this._forceShowHide(), ref: (el) => this._showHideDropdown = el }, this._getAction(cur.active, this._showHideOpen ? "chevron-down" : cur.icon, cur.indicator, cur.label, cur.func, cur.disabled, cur.loading, "trigger"), this._showHideOpen ? this._getFieldlist() : undefined)) :
|
|
401
|
+
this._getAction(cur.active, cur.icon, cur.indicator, cur.label, cur.func, cur.disabled, cur.loading));
|
|
401
402
|
}
|
|
402
403
|
return prev;
|
|
403
404
|
}, []);
|
|
@@ -549,6 +550,7 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
549
550
|
indicator: false,
|
|
550
551
|
func: () => void this._exportToCSV(),
|
|
551
552
|
label: this._translations.exportCSV,
|
|
553
|
+
loading: this._csvExporting,
|
|
552
554
|
disabled: featuresEmpty,
|
|
553
555
|
isOverflow: false
|
|
554
556
|
} : undefined, {
|
|
@@ -733,7 +735,7 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
733
735
|
_getDropdown(id) {
|
|
734
736
|
const dropdownItems = this._getDropdownItems();
|
|
735
737
|
return dropdownItems.length > 0 ? (h("calcite-dropdown", { closeOnSelectDisabled: true, disabled: this._layer === undefined, id: "solutions-more", onCalciteDropdownBeforeClose: () => this._forceShowHide(), ref: (el) => this._moreDropdown = el }, h("calcite-action", { appearance: "solid", id: id, label: "", onClick: () => this._closeShowHide(), slot: "trigger", text: "" }, h("calcite-button", { appearance: "transparent", iconEnd: "chevron-down", kind: "neutral" }, this._translations.more)), h("calcite-dropdown-group", { "selection-mode": "none" }, dropdownItems.map(item => {
|
|
736
|
-
return (h("calcite-dropdown-group", { class: item.disabled ? "disabled" : "", selectionMode: item.disabled ? "none" : "single" }, h("calcite-dropdown-item", { iconStart: item.isSublist && this._showHideOpen ? "chevron-down" : item.icon, id: "solutions-subset-list", onClick: item.func }, item.label)));
|
|
738
|
+
return (h("calcite-dropdown-group", { class: item.disabled ? "disabled" : "", selectionMode: item.disabled ? "none" : "single" }, h("calcite-dropdown-item", { disabled: item.loading, iconStart: item.isSublist && this._showHideOpen ? "chevron-down" : item.loading ? "" : item.icon, id: "solutions-subset-list", onClick: item.func }, item.loading ? (h("div", { class: "display-flex" }, h("calcite-loader", { inline: true, label: item.label, scale: "m" }), item.label)) : item.label)));
|
|
737
739
|
})), this._showHideOpen ? this._getFieldlist() : undefined)) : undefined;
|
|
738
740
|
}
|
|
739
741
|
/**
|
|
@@ -755,9 +757,9 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
755
757
|
*
|
|
756
758
|
* @returns VNode The node representing the DOM element that will contain the action
|
|
757
759
|
*/
|
|
758
|
-
_getAction(active, icon, indicator, label, func, disabled, slot) {
|
|
760
|
+
_getAction(active, icon, indicator, label, func, disabled, loading, slot) {
|
|
759
761
|
const _disabled = this._layer === undefined ? true : disabled;
|
|
760
|
-
return (h("div", { class: "display-flex", id: this._getId(icon), slot: slot }, h("calcite-action", { active: active, appearance: "solid", disabled: _disabled, icon: icon, id: icon, indicator: indicator, label: label, onClick: func, text: label, textEnabled: true }), this._getToolTip("bottom", icon, label)));
|
|
762
|
+
return (h("div", { class: "display-flex", id: this._getId(icon), slot: slot }, h("calcite-action", { active: active, appearance: "solid", disabled: _disabled, icon: icon, id: icon, indicator: indicator, label: label, loading: loading, onClick: func, text: label, textEnabled: true }), this._getToolTip("bottom", icon, label)));
|
|
761
763
|
}
|
|
762
764
|
/**
|
|
763
765
|
* Get an action and tooltip for share
|
|
@@ -1211,13 +1213,9 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
1211
1213
|
const hitTestResult = await this.mapView.hitTest(evt.screenPoint, opts);
|
|
1212
1214
|
if (hitTestResult.results.length > 0) {
|
|
1213
1215
|
hitTestResult.results.forEach((result) => {
|
|
1214
|
-
this._clearSelection();
|
|
1215
1216
|
const id = result.graphic.getObjectId();
|
|
1216
1217
|
const index = this._table.highlightIds.indexOf(id);
|
|
1217
|
-
if (index
|
|
1218
|
-
this._table.highlightIds.removeAt(index);
|
|
1219
|
-
}
|
|
1220
|
-
else {
|
|
1218
|
+
if (index < 0) {
|
|
1221
1219
|
this._table.highlightIds.add(id);
|
|
1222
1220
|
}
|
|
1223
1221
|
});
|
|
@@ -1225,6 +1223,9 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
1225
1223
|
this._table.filterBySelection();
|
|
1226
1224
|
}
|
|
1227
1225
|
}
|
|
1226
|
+
else {
|
|
1227
|
+
this._clearSelection();
|
|
1228
|
+
}
|
|
1228
1229
|
}
|
|
1229
1230
|
/**
|
|
1230
1231
|
* Select or deselect all rows
|
|
@@ -1313,11 +1314,26 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
1313
1314
|
}
|
|
1314
1315
|
return prev;
|
|
1315
1316
|
}, []);
|
|
1316
|
-
|
|
1317
|
+
this._updateToolInfoLoading("export", true);
|
|
1318
|
+
this._csvExporting = true;
|
|
1319
|
+
await downloadCSV(null, //???
|
|
1317
1320
|
exportInfos, false, // formatUsingLayerPopup
|
|
1318
1321
|
false, // removeDuplicates
|
|
1319
1322
|
true, // addColumnTitle
|
|
1320
1323
|
fields, true);
|
|
1324
|
+
this._updateToolInfoLoading("export", false);
|
|
1325
|
+
this._csvExporting = false;
|
|
1326
|
+
}
|
|
1327
|
+
/**
|
|
1328
|
+
* Set the loading prop in the stored toolInfos
|
|
1329
|
+
*/
|
|
1330
|
+
_updateToolInfoLoading(name, isLoading) {
|
|
1331
|
+
this._toolInfos.some(tool => {
|
|
1332
|
+
if ((tool === null || tool === void 0 ? void 0 : tool.icon) === name) {
|
|
1333
|
+
tool.loading = isLoading;
|
|
1334
|
+
return true;
|
|
1335
|
+
}
|
|
1336
|
+
});
|
|
1321
1337
|
}
|
|
1322
1338
|
/**
|
|
1323
1339
|
* Refreshes the table and maintains the curent scroll position
|
|
@@ -1475,6 +1491,7 @@ const LayerTable = /*@__PURE__*/ proxyCustomElement(class LayerTable extends HTM
|
|
|
1475
1491
|
"showNewestFirst": [4, "show-newest-first"],
|
|
1476
1492
|
"zoomAndScrollToSelected": [4, "zoom-and-scroll-to-selected"],
|
|
1477
1493
|
"_controlsThatFit": [32],
|
|
1494
|
+
"_csvExporting": [32],
|
|
1478
1495
|
"_fetchingData": [32],
|
|
1479
1496
|
"_filterActive": [32],
|
|
1480
1497
|
"_filterOpen": [32],
|
|
@@ -52,6 +52,7 @@ async function queryObjectIds(geometries, layer) {
|
|
|
52
52
|
}
|
|
53
53
|
/**
|
|
54
54
|
* Query the layer for features that have the provided OIDs
|
|
55
|
+
* If no ids are provided all features will be returned
|
|
55
56
|
*
|
|
56
57
|
* @param ids array of ObjectIDs to be used to query for features in a layer
|
|
57
58
|
* @param layer the layer to retrieve features from
|
|
@@ -76,6 +77,9 @@ async function queryFeaturesByID(ids, layer, graphics, returnGeometry, outSpatia
|
|
|
76
77
|
if (fields) {
|
|
77
78
|
q.outFields = fields;
|
|
78
79
|
}
|
|
80
|
+
if (ids.length === 0) {
|
|
81
|
+
ids = await layer.queryObjectIds();
|
|
82
|
+
}
|
|
79
83
|
const result = await layer.queryFeatures(q);
|
|
80
84
|
graphics = graphics.concat(result.features);
|
|
81
85
|
const remainingIds = ids.slice(num, ids.length);
|
|
@@ -12,7 +12,7 @@ import { o as onToggleOpenCloseComponent } from './openCloseComponent-9f90f493.j
|
|
|
12
12
|
import { c as connectMessages, s as setUpMessages, d as disconnectMessages, u as updateMessages } from './t9n-436fb2b1.js';
|
|
13
13
|
import { K as KindIcons } from './resources-88a48c5c.js';
|
|
14
14
|
import { g as getLocaleComponentStrings, l as loadModules } from './locale-25a5ae3e.js';
|
|
15
|
-
import { a as getAllLayers } from './mapViewUtils-
|
|
15
|
+
import { a as getAllLayers } from './mapViewUtils-a177d4f9.js';
|
|
16
16
|
import { P as PopupUtils } from './popupUtils-23fe3c9f.js';
|
|
17
17
|
import './guid-b75a5f7b.js';
|
|
18
18
|
import './resources-8834f920.js';
|
|
@@ -22,7 +22,7 @@ import { V as Validation } from './Validation-ea480265.js';
|
|
|
22
22
|
import { d as debounce } from './debounce-229b1a22.js';
|
|
23
23
|
import { i as isActivationKey } from './key-c83d835f.js';
|
|
24
24
|
import { g as getLocaleComponentStrings } from './locale-25a5ae3e.js';
|
|
25
|
-
import { d as getMapLayerHash, o as getMapTableHash } from './mapViewUtils-
|
|
25
|
+
import { d as getMapLayerHash, o as getMapTableHash } from './mapViewUtils-a177d4f9.js';
|
|
26
26
|
import { s as state } from './publicNotificationStore-3bf4de75.js';
|
|
27
27
|
import './resources-8834f920.js';
|
|
28
28
|
import './browser-d60104bd.js';
|
|
@@ -12,7 +12,7 @@ import { c as connectLocalized, d as disconnectLocalized } from './locale-904407
|
|
|
12
12
|
import { c as connectMessages, s as setUpMessages, d as disconnectMessages, u as updateMessages } from './t9n-436fb2b1.js';
|
|
13
13
|
import { S as SLOTS$1 } from './resources-00983bd3.js';
|
|
14
14
|
import { l as loadModules, g as getLocaleComponentStrings, f as formatNumber } from './locale-25a5ae3e.js';
|
|
15
|
-
import { a as getAllLayers, g as getLayerOrTable, b as getFeatureLayerView, h as highlightFeatures, d as getMapLayerHash } from './mapViewUtils-
|
|
15
|
+
import { a as getAllLayers, g as getLayerOrTable, b as getFeatureLayerView, h as highlightFeatures, d as getMapLayerHash } from './mapViewUtils-a177d4f9.js';
|
|
16
16
|
import { P as PopupUtils } from './popupUtils-23fe3c9f.js';
|
|
17
17
|
import './guid-b75a5f7b.js';
|
|
18
18
|
import './resources-8834f920.js';
|
|
@@ -767,6 +767,8 @@ const LayerList = class {
|
|
|
767
767
|
registerInstance(this, hostRef);
|
|
768
768
|
this.layerSelect = createEvent(this, "layerSelect", 7);
|
|
769
769
|
this.layersListLoaded = createEvent(this, "layersListLoaded", 7);
|
|
770
|
+
//HARDCODED IN EN
|
|
771
|
+
this._noLayerToDisplayErrorMsg = "Web map does not contain any editable layers.";
|
|
770
772
|
this.mapView = undefined;
|
|
771
773
|
this.layers = undefined;
|
|
772
774
|
this.noLayerErrorMsg = undefined;
|
|
@@ -819,7 +821,7 @@ const LayerList = class {
|
|
|
819
821
|
*/
|
|
820
822
|
render() {
|
|
821
823
|
return (h(Fragment, null, this._isLoading && h("calcite-loader", { label: "", scale: "m" }), !this._isLoading && this.mapView && this._noLayersToDisplay &&
|
|
822
|
-
h("calcite-notice", { class: "error-msg", icon: "layers-reference", kind: "danger", open: true }, h("div", { slot: "title" }, this._translations.error), h("div", { slot: "message" }, this.noLayerErrorMsg ? this.noLayerErrorMsg : this.
|
|
824
|
+
h("calcite-notice", { class: "error-msg", icon: "layers-reference", kind: "danger", open: true }, h("div", { slot: "title" }, this._translations.error), h("div", { slot: "message" }, this.noLayerErrorMsg ? this.noLayerErrorMsg : this._noLayerToDisplayErrorMsg)), !this._isLoading && this.mapView &&
|
|
823
825
|
h("calcite-list", { "selection-appearance": "border", "selection-mode": this.showNextIcon ? "none" : "single-persist" }, this.renderLayerList())));
|
|
824
826
|
}
|
|
825
827
|
//--------------------------------------------------------------------------
|