@esri/solutions-components 0.7.27 → 0.7.29

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. package/dist/assets/t9n/card-manager/resources.json +1 -4
  2. package/dist/assets/t9n/card-manager/resources_en.json +1 -4
  3. package/dist/cjs/calcite-alert_4.cjs.entry.js +12 -3
  4. package/dist/cjs/calcite-combobox_6.cjs.entry.js +1 -1
  5. package/dist/cjs/card-manager_3.cjs.entry.js +4 -3
  6. package/dist/cjs/crowdsource-manager.cjs.entry.js +12 -8
  7. package/dist/cjs/loader.cjs.js +1 -1
  8. package/dist/cjs/solutions-components.cjs.js +1 -1
  9. package/dist/collection/components/crowdsource-manager/crowdsource-manager.css +8 -0
  10. package/dist/collection/components/crowdsource-manager/crowdsource-manager.js +11 -7
  11. package/dist/collection/components/info-card/info-card.css +4 -4
  12. package/dist/collection/components/info-card/info-card.js +11 -2
  13. package/dist/collection/components/layer-table/layer-table.js +5 -4
  14. package/dist/collection/components/map-layer-picker/map-layer-picker.js +1 -1
  15. package/dist/components/crowdsource-manager.js +12 -8
  16. package/dist/components/info-card2.js +12 -3
  17. package/dist/components/layer-table2.js +5 -4
  18. package/dist/components/map-layer-picker2.js +1 -1
  19. package/dist/esm/calcite-alert_4.entry.js +12 -3
  20. package/dist/esm/calcite-combobox_6.entry.js +1 -1
  21. package/dist/esm/card-manager_3.entry.js +4 -3
  22. package/dist/esm/crowdsource-manager.entry.js +12 -8
  23. package/dist/esm/loader.js +1 -1
  24. package/dist/esm/solutions-components.js +1 -1
  25. package/dist/solutions-components/{p-dded59a7.entry.js → p-12de822a.entry.js} +1 -1
  26. package/dist/solutions-components/{p-934cbe40.entry.js → p-643e7ee1.entry.js} +1 -1
  27. package/dist/solutions-components/p-78e720cc.entry.js +6 -0
  28. package/dist/solutions-components/p-dbe62aaf.entry.js +6 -0
  29. package/dist/solutions-components/solutions-components.esm.js +1 -1
  30. package/dist/types/components/crowdsource-manager/crowdsource-manager.d.ts +4 -2
  31. package/dist/types/components/info-card/info-card.d.ts +9 -1
  32. package/dist/types/components/layer-table/layer-table.d.ts +1 -1
  33. package/package.json +1 -1
  34. package/dist/solutions-components/p-8308f64c.entry.js +0 -6
  35. package/dist/solutions-components/p-9549b5b1.entry.js +0 -6
@@ -1,6 +1,3 @@
1
1
  {
2
- "information": "Information",
3
- "media": "Media",
4
- "comments": "Comments",
5
- "selectFeaturesToStart": "Select a record to get started"
2
+ "selectFeaturesToStart": "Select a record to get started. Click while pressing the Ctrl key to select multiple records in the table."
6
3
  }
@@ -1,6 +1,3 @@
1
1
  {
2
- "information": "Information",
3
- "media": "Media",
4
- "comments": "Comments",
5
- "selectFeaturesToStart": "Select a record to get started"
2
+ "selectFeaturesToStart": "Select a record to get started. Click while pressing the Ctrl key to select multiple records in the table."
6
3
  }
@@ -654,7 +654,7 @@ const EditCard = class {
654
654
  };
655
655
  EditCard.style = editCardCss;
656
656
 
657
- const infoCardCss = ":host{display:block;--calcite-label-margin-bottom:0}.padding-1-2{padding:0.5rem}.display-none{display:none !important}.display-flex{display:flex}.position-absolute{position:absolute;top:0;right:0;bottom:0;left:0;overflow:auto}.esri-features__footer{display:none !important}.button-container{justify-content:space-between;align-items:center}.top-border{border-top:1px solid var(--calcite-color-border-1)}.min-width-100{min-width:100px}.width-100{width:100%}.esri-features__container{padding:0.5rem !important;background-color:var(--calcite-color-foreground-1) !important;height:100% !important}.overflow-hidden{overflow:hidden}.height-40{height:40px}.padding-top-46{padding-top:46px}.end-border{border-inline-end:1px solid var(--calcite-color-border-1)}.font-bold{font-weight:bold}.visibility-hidden{visibility:hidden;height:0px}.padding-inline-start-1{padding-inline-start:1rem}";
657
+ const infoCardCss = ":host{display:block;--calcite-label-margin-bottom:0}.padding-1-2{padding:0.5rem}.display-none{display:none !important}.display-flex{display:flex}.position-absolute{position:absolute;top:0;right:0;bottom:0;left:0;overflow:auto}.esri-features__footer{display:none !important}.button-container{justify-content:space-between;align-items:center}.top-border{border-top:1px solid var(--calcite-color-border-1)}.min-width-100{min-width:100px}.width-100{width:100%}.esri-features__container{padding:0.5rem !important;background-color:var(--calcite-color-foreground-1) !important;height:100% !important}.overflow-hidden{overflow:hidden}.height-40{height:40px}.end-border{border-inline-end:1px solid var(--calcite-color-border-1)}.font-bold{font-weight:bold}.visibility-hidden{visibility:hidden;height:0px}.padding-inline-start-1{padding-inline-start:1rem}.border-width-0{border-width:0px}";
658
658
 
659
659
  const InfoCard = class {
660
660
  constructor(hostRef) {
@@ -773,11 +773,10 @@ const InfoCard = class {
773
773
  const editButtonClass = (!this.isLoading && this._editRecordOpen) || this._showListView ? "display-none" : "";
774
774
  const nextBackDisabled = ((_b = (_a = this._features) === null || _a === void 0 ? void 0 : _a.features) === null || _b === void 0 ? void 0 : _b.length) < 2;
775
775
  const nextBackClass = this.isMobile ? "display-none" : "";
776
- const shellClass = this.isMobile && !this._editRecordOpen ? "padding-top-46" : "";
777
776
  const id = (_d = (_c = this._features) === null || _c === void 0 ? void 0 : _c.selectedFeature) === null || _d === void 0 ? void 0 : _d.getObjectId();
778
777
  const ids = parseInt(id === null || id === void 0 ? void 0 : id.toString(), 10) > -1 ? [id] : [];
779
778
  const deleteEnabled = ((_e = this._layer) === null || _e === void 0 ? void 0 : _e.editingEnabled) && ((_h = (_g = (_f = this._layer) === null || _f === void 0 ? void 0 : _f.capabilities) === null || _g === void 0 ? void 0 : _g.operations) === null || _h === void 0 ? void 0 : _h.supportsDelete);
780
- return (index.h(index.Host, null, this.isMobile && !this._editRecordOpen ? (index.h("calcite-panel", null, index.h("calcite-action", { class: "end-border", icon: "chevron-left", iconFlipRtl: true, onClick: () => this._closePopup(), scale: "s", slot: "header-actions-start", text: "" }), index.h("span", { class: "font-bold", slot: "header-content" }, this._mobileTitle))) : undefined, index.h("calcite-shell", { class: shellClass }, index.h("calcite-loader", { class: loadingClass, label: this._translations.fetchingData }), index.h("div", { class: "esri-widget " + featureNodeClass, id: "features-node" }), index.h("div", { class: `${editButtonClass} width-100`, slot: "footer" }, this.allowEditing &&
779
+ return (index.h(index.Host, null, index.h("calcite-shell", null, this._getHeader(), index.h("calcite-loader", { class: loadingClass, label: this._translations.fetchingData }), index.h("div", { class: "esri-widget " + featureNodeClass, id: "features-node" }), index.h("div", { class: `${editButtonClass} width-100`, slot: "footer" }, this.allowEditing &&
781
780
  index.h("div", { class: "display-flex top-border padding-1-2" }, index.h("calcite-button", { appearance: "solid", id: "solutions-edit", onClick: () => this._openEditRecord(), width: "full" }, this._translations.edit), this.isMobile && deleteEnabled ? (index.h("delete-button", { class: "padding-inline-start-1 width-100", id: "solutions-delete", ids: ids, layer: this._layer, onEditsComplete: () => this._closePopup() })) : undefined, index.h("calcite-tooltip", { label: "", placement: "bottom", "reference-element": "solutions-edit" }, index.h("span", null, this._translations.edit)), this.isMobile ? (index.h("calcite-tooltip", { label: "", placement: "bottom", "reference-element": "solutions-delete" }, index.h("span", null, this._translations.delete))) : undefined), !nextBackDisabled && index.h("div", { class: `display-flex padding-1-2 button-container top-border ${nextBackClass}` }, index.h("div", { class: "min-width-100" }, index.h("calcite-button", { appearance: "outline", disabled: nextBackDisabled, id: "solutions-back", onClick: () => this._back(), width: "full" }, this._translations.back), index.h("calcite-tooltip", { label: "", placement: "top", "reference-element": "solutions-back" }, index.h("span", null, this._translations.back))), index.h("div", null, index.h("calcite-action", { icon: "list", onClick: () => this._toggleListView(), scale: "s", text: this._count, textEnabled: true })), index.h("div", { class: "min-width-100" }, index.h("calcite-button", { appearance: "outline", disabled: nextBackDisabled, id: "solutions-next", onClick: () => this._next(), width: "full" }, this._translations.next), index.h("calcite-tooltip", { label: "", placement: "top", "reference-element": "solutions-next" }, index.h("span", null, this._translations.next))))), index.h("edit-card", { class: editClass, graphicIndex: (_j = this._features) === null || _j === void 0 ? void 0 : _j.selectedFeatureIndex, graphics: this.graphics, mapView: this.mapView, open: this._editRecordOpen }), index.h("calcite-alert", { icon: "layer-broken", kind: "warning", label: "", onCalciteAlertClose: () => this._alertClosed(), open: this._alertOpen, placement: "top" }, index.h("div", { slot: "title" }, this._translations.editDisabled), index.h("div", { slot: "message" }, this._translations.enableEditing)))));
782
781
  }
783
782
  //--------------------------------------------------------------------------
@@ -865,6 +864,16 @@ const InfoCard = class {
865
864
  }
866
865
  })) : Promise.resolve();
867
866
  }
867
+ /**
868
+ * Get the mobile header
869
+ *
870
+ * @returns the header node to display when in mobile mode
871
+ *
872
+ * @protected
873
+ */
874
+ _getHeader() {
875
+ return this.isMobile && !this._editRecordOpen ? (index.h("calcite-panel", { class: "border-width-0", slot: "header" }, index.h("calcite-action", { class: "end-border", icon: "chevron-left", iconFlipRtl: true, onClick: () => this._closePopup(), scale: "s", slot: "header-actions-start", text: "" }), index.h("span", { class: "font-bold", slot: "header-content" }, this._mobileTitle))) : undefined;
876
+ }
868
877
  /**
869
878
  * Close the popup and emit the selected features
870
879
  */
@@ -1983,7 +1983,7 @@ const MapLayerPicker = class {
1983
1983
  return (index.h(index.Host, null, index.h("div", { class: "map-layer-picker-container", style: style }, index.h("div", { class: "map-layer-picker", style: style }, !this._hasValidLayers ? this._getInvalidPlaceholder() :
1984
1984
  !this._hasMultipleLayers && this.showSingleLayerAsLabel ? this._getSingleLayerPlaceholder() :
1985
1985
  this.type === "combobox" ? this._getCombobox(id) :
1986
- this.type === "select" ? this._getSelect(id) : this._getDropdown(id), index.h("calcite-tooltip", { label: "", placement: "bottom", "reference-element": id }, index.h("span", null, this._translations.switchLayer))))));
1986
+ this.type === "select" ? this._getSelect(id) : this._getDropdown(id)))));
1987
1987
  }
1988
1988
  /**
1989
1989
  * StencilJS: Called once just after the component is fully loaded and the first render() occurs.
@@ -241,6 +241,7 @@ const LayerTable = class {
241
241
  if (((_a = this._toolInfos) === null || _a === void 0 ? void 0 : _a.length) > 0) {
242
242
  this._initToolInfos();
243
243
  }
244
+ this._initLayerExpressions();
244
245
  }
245
246
  /**
246
247
  * watch for changes in map view and get the first layer
@@ -273,7 +274,7 @@ const LayerTable = class {
273
274
  /**
274
275
  * watch for selection changes
275
276
  */
276
- async _selectedIdsWatchHandler() {
277
+ async selectedIdsWatchHandler() {
277
278
  this._updateShareUrl();
278
279
  this._validateEnabledActions();
279
280
  if (this._selectAllActive && this.selectedIds.length !== this._allIds.length) {
@@ -1294,7 +1295,7 @@ const LayerTable = class {
1294
1295
  _initLayerExpressions() {
1295
1296
  var _a, _b;
1296
1297
  const layerExpressions = (_b = (_a = this.mapInfo) === null || _a === void 0 ? void 0 : _a.filterConfig) === null || _b === void 0 ? void 0 : _b.layerExpressions;
1297
- this._layerExpressions = layerExpressions ? layerExpressions.filter((exp) => exp.id === this._layer.id) : [];
1298
+ this._layerExpressions = layerExpressions ? layerExpressions.filter((exp) => { var _a; return exp.id === ((_a = this._layer) === null || _a === void 0 ? void 0 : _a.id); }) : [];
1298
1299
  this._filterList.layerExpressions = this._layerExpressions;
1299
1300
  this._filterActive = false;
1300
1301
  }
@@ -1460,7 +1461,7 @@ const LayerTable = class {
1460
1461
  "mapInfo": ["mapInfoWatchHandler"],
1461
1462
  "mapView": ["mapViewWatchHandler"],
1462
1463
  "_layer": ["_layerWatchHandler"],
1463
- "_selectedIds": ["_selectedIdsWatchHandler"],
1464
+ "selectedIds": ["selectedIdsWatchHandler"],
1464
1465
  "_sortActive": ["_sortActiveWatchHandler"]
1465
1466
  }; }
1466
1467
  };
@@ -14,7 +14,7 @@ const mapViewUtils = require('./mapViewUtils-8aa325de.js');
14
14
  require('./esri-loader-a91c0ec1.js');
15
15
  require('./_commonjsHelpers-384729db.js');
16
16
 
17
- const crowdsourceManagerCss = ":host{display:block;--calcite-label-margin-bottom:0px;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.padding-1-2{padding:0.5rem}.display-flex{display:flex}.width-full{width:100%}.width-1-2{position:relative;width:50%}.width-1-3{position:relative;width:33.33%}.width-2-3{position:relative;width:66.66%}.width-0{width:0}.height-full{height:100%}.height-1-2{position:relative;height:50%}.height-0{height:0}.toggle-node{width:51px;height:51px}.overflow-hidden{overflow:hidden}.flex-column{flex-direction:column}.border{border:1px solid var(--calcite-color-border-3)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.border-sides{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.position-relative{position:relative}.height-50{height:50%}.adjusted-height-50{height:calc(50% - 25px)}.adjusted-height-100{height:calc(100% - 50px)}.adjusted-height-100-50{height:calc(100% - 50px)}.display-none{display:none}.height-53{height:53px}.position-absolute-53{position:absolute;top:53px}.display-grid{display:grid}.height-50-px{height:50px}.padding-inline-start-75{padding-inline-start:0.75rem}.align-items-center{align-items:center}.esri-floor-filter__close-levels-button{width:40px !important;height:40px !important}.esri-floor-filter__level-button{width:40px !important;height:40px !important}.esri-floor-filter__browse-button{width:40px !important;height:40px !important}.position-absolute-50{position:absolute;top:50px;bottom:0px;left:0px;right:0px}.position-absolute-0{position:absolute;top:0px;bottom:0px;left:0px;right:0px}.visibility-hidden{visibility:hidden;height:0px}.position-fixed{position:fixed}";
17
+ const crowdsourceManagerCss = ":host{display:block;--calcite-label-margin-bottom:0px;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.padding-1-2{padding:0.5rem}.display-flex{display:flex}.width-full{width:100%}.width-1-2{position:relative;width:50%}.width-1-3{position:relative;width:33.33%}.width-2-3{position:relative;width:66.66%}.width-0{width:0}.height-full{height:100%}.height-1-2{position:relative;height:50%}.height-0{height:0}.toggle-node{width:51px;height:51px}.overflow-hidden{overflow:hidden}.flex-column{flex-direction:column}.border{border:1px solid var(--calcite-color-border-3)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.border-sides{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.position-relative{position:relative}.height-50{height:50%}.adjusted-height-50{height:calc(50% - 25px)}.adjusted-height-100{height:calc(100% - 50px)}.adjusted-height-100-50{height:calc(100% - 50px)}.display-none{display:none}.height-53{height:53px}.position-absolute-53{position:absolute;top:53px}.display-grid{display:grid}.height-50-px{height:50px}.padding-inline-start-75{padding-inline-start:0.75rem}.align-items-center{align-items:center}.esri-floor-filter__close-levels-button{width:40px !important;height:40px !important}.esri-floor-filter__level-button{width:40px !important;height:40px !important}.esri-floor-filter__browse-button{width:40px !important;height:40px !important}.position-absolute-50{position:absolute;top:50px;bottom:0px;left:0px;right:0px}.position-absolute-0{position:absolute;top:0px;bottom:0px;left:0px;right:0px}.visibility-hidden{visibility:hidden;height:0px}.position-fixed{position:fixed}.border-width-0{border-width:0px}.border-bottom-width-0{border-bottom-width:0px}";
18
18
 
19
19
  const CrowdsourceManager = class {
20
20
  constructor(hostRef) {
@@ -196,7 +196,9 @@ const CrowdsourceManager = class {
196
196
  * Renders the component.
197
197
  */
198
198
  render() {
199
- return (index.h(index.Host, null, index.h("calcite-shell", { class: "position-relative" }, index.h("calcite-panel", { class: "width-full height-full" }, this._getBody(this._layoutMode, this._panelOpen, this._hideTable)), this._getFooter())));
199
+ const borderClass = this._isMobile && this._hideTable ? "border-width-0" :
200
+ this._isMobile ? "border-bottom-width-0" : "";
201
+ return (index.h(index.Host, null, index.h("calcite-shell", { class: "position-relative" }, index.h("calcite-panel", { class: `width-full height-full ${borderClass}` }, this._getBody(this._layoutMode, this._panelOpen, this._hideTable)), this._getFooter())));
200
202
  }
201
203
  /**
202
204
  * Called after each render
@@ -260,15 +262,16 @@ const CrowdsourceManager = class {
260
262
  *
261
263
  * @param layoutMode ELayoutMode the current layout mode
262
264
  * @param panelOpen boolean indicates if all panels are open
265
+ * @param hideTable boolean when true the layer table is hidden
263
266
  *
264
267
  * @returns the css selectors
265
268
  * @protected
266
269
  */
267
- _getMapSizeClass(layoutMode, panelOpen) {
270
+ _getMapSizeClass(layoutMode, panelOpen, hideTable) {
268
271
  let sizeClass = "";
269
272
  switch (layoutMode) {
270
273
  case interfaces.ELayoutMode.HORIZONTAL:
271
- sizeClass = `${panelOpen ? "height-1-2 display-grid" : "height-0"} width-full position-relative`;
274
+ sizeClass = `${panelOpen && !hideTable ? "height-1-2 display-grid" : panelOpen && hideTable ? "height-full" : "height-0"} width-full position-relative`;
272
275
  break;
273
276
  case interfaces.ELayoutMode.GRID:
274
277
  sizeClass = `height-full position-relative ${panelOpen ? "width-1-3" : "width-0"}`;
@@ -314,19 +317,20 @@ const CrowdsourceManager = class {
314
317
  */
315
318
  _getBody(layoutMode, panelOpen, hideTable) {
316
319
  const contentClass = layoutMode === interfaces.ELayoutMode.HORIZONTAL ? "" : "display-flex";
317
- return (index.h("calcite-panel", { class: "width-full height-full" }, index.h("div", { class: `width-full height-full overflow-hidden ${contentClass}` }, this._getMapAndCard(layoutMode, panelOpen), this._getTable(layoutMode, panelOpen, hideTable))));
320
+ return (index.h("calcite-panel", { class: "width-full height-full" }, index.h("div", { class: `width-full height-full overflow-hidden ${contentClass}` }, this._getMapAndCard(layoutMode, panelOpen, hideTable), this._getTable(layoutMode, panelOpen, hideTable))));
318
321
  }
319
322
  /**
320
323
  * Get the map and card nodes based for the current layout options
321
324
  *
322
325
  * @param layoutMode ELayoutMode the current layout mode
323
326
  * @param panelOpen boolean indicates if all panels are open
327
+ * @param hideTable boolean when true the layer table is hidden
324
328
  *
325
329
  * @returns the map node
326
330
  * @protected
327
331
  */
328
- _getMapAndCard(layoutMode, panelOpen) {
329
- const mapSizeClass = this._getMapSizeClass(layoutMode, panelOpen);
332
+ _getMapAndCard(layoutMode, panelOpen, hideTable) {
333
+ const mapSizeClass = this._getMapSizeClass(layoutMode, panelOpen, hideTable);
330
334
  return (index.h("div", { class: `${mapSizeClass} overflow-hidden` }, this._getMapNode(layoutMode, panelOpen), this._getPopupExpandNode()));
331
335
  }
332
336
  /**
@@ -359,7 +363,7 @@ const CrowdsourceManager = class {
359
363
  const popupNodeClass = !this._expandPopup ? "height-full" : ((_a = this.mapInfos) === null || _a === void 0 ? void 0 : _a.length) === 1 || this._isMobile ? "position-absolute-0" : "position-absolute-50";
360
364
  const headerClass = this._isMobile ? "display-none height-0" : "";
361
365
  const headerTheme = !this._isMobile ? "calcite-mode-dark" : "calcite-mode-light";
362
- const containerClass = this._isMobile && this._hideTable ? "position-fixed width-full height-full" : this._isMobile ? "display-none height-0" : "";
366
+ const containerClass = this._isMobile && this._hideTable ? "position-absolute-0 width-full height-full" : this._isMobile ? "display-none height-0" : "";
363
367
  return (index.h("div", { class: `${headerTheme} ${popupNodeClass} ${containerClass}` }, index.h("calcite-panel", null, !this._isMobile ? (index.h("div", { class: `display-flex align-items-center ${headerClass}`, slot: "header-content" }, index.h("calcite-icon", { icon: "information", scale: "s" }), index.h("div", { class: "padding-inline-start-75" }, this._translations.information))) : undefined, index.h("calcite-action", { class: headerClass, disabled: this._tableOnly, icon: icon, id: id, onClick: () => this._togglePopup(), slot: "header-actions-end", text: "" }), !this._tableOnly ? index.h("calcite-tooltip", { class: themeClass, label: "", placement: "bottom", "reference-element": id }, index.h("span", null, tooltip)) : undefined, this._getCardNode())));
364
368
  }
365
369
  /**