@esri/solutions-components 0.7.21 → 0.7.22
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/card-manager_3.cjs.entry.js +103 -88
- package/dist/collection/components/layer-table/layer-table.js +103 -88
- package/dist/components/layer-table2.js +103 -88
- package/dist/esm/card-manager_3.entry.js +103 -88
- package/dist/solutions-components/p-630e274b.entry.js +6 -0
- package/dist/solutions-components/solutions-components.esm.js +1 -1
- package/package.json +1 -1
- package/dist/solutions-components/p-5302f406.entry.js +0 -6
@@ -530,93 +530,95 @@ const LayerTable = class {
|
|
530
530
|
const featuresSelected = this._featuresSelected();
|
531
531
|
const featuresEmpty = this._featuresEmpty();
|
532
532
|
const hasFilterExpressions = this._hasFilterExpressions();
|
533
|
-
this.
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
|
555
|
-
|
556
|
-
|
557
|
-
|
558
|
-
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
573
|
-
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
|
579
|
-
|
580
|
-
|
581
|
-
|
582
|
-
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
|
591
|
-
|
592
|
-
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
|
616
|
-
|
617
|
-
|
618
|
-
|
619
|
-
|
533
|
+
if (this._translations) {
|
534
|
+
this._toolInfos = [{
|
535
|
+
active: false,
|
536
|
+
icon: "zoom-to-object",
|
537
|
+
indicator: false,
|
538
|
+
label: this._translations.zoom,
|
539
|
+
func: () => this._zoom(),
|
540
|
+
disabled: !featuresSelected,
|
541
|
+
isOverflow: false
|
542
|
+
},
|
543
|
+
hasFilterExpressions ? {
|
544
|
+
active: false,
|
545
|
+
icon: "filter",
|
546
|
+
indicator: false,
|
547
|
+
label: this._translations.filters,
|
548
|
+
func: () => this._toggleFilter(),
|
549
|
+
disabled: false,
|
550
|
+
isOverflow: false
|
551
|
+
} : undefined,
|
552
|
+
this._deleteEnabled ? {
|
553
|
+
active: false,
|
554
|
+
icon: "trash",
|
555
|
+
indicator: false,
|
556
|
+
label: this._translations.delete,
|
557
|
+
func: () => this._delete(),
|
558
|
+
disabled: !featuresSelected,
|
559
|
+
isDanger: true,
|
560
|
+
isOverflow: false
|
561
|
+
} : undefined, {
|
562
|
+
active: false,
|
563
|
+
icon: "erase",
|
564
|
+
indicator: false,
|
565
|
+
label: this._translations.clearSelection,
|
566
|
+
func: () => this._clearSelection(),
|
567
|
+
disabled: !featuresSelected,
|
568
|
+
isOverflow: false
|
569
|
+
}, {
|
570
|
+
active: false,
|
571
|
+
icon: "selected-items-filter",
|
572
|
+
indicator: false,
|
573
|
+
label: this._showOnlySelected ? this._translations.showAll : this._translations.showSelected,
|
574
|
+
func: () => this._toggleShowSelected(),
|
575
|
+
disabled: !featuresSelected,
|
576
|
+
isOverflow: false
|
577
|
+
}, {
|
578
|
+
active: false,
|
579
|
+
icon: "list-check-all",
|
580
|
+
indicator: false,
|
581
|
+
func: () => this._selectAll(),
|
582
|
+
label: this._translations.selectAll,
|
583
|
+
disabled: featuresEmpty,
|
584
|
+
isOverflow: false
|
585
|
+
}, {
|
586
|
+
active: false,
|
587
|
+
icon: "compare",
|
588
|
+
indicator: false,
|
589
|
+
func: () => this._switchSelected(),
|
590
|
+
label: this._translations.switchSelected,
|
591
|
+
disabled: featuresEmpty,
|
592
|
+
isOverflow: false
|
593
|
+
}, {
|
594
|
+
active: false,
|
595
|
+
icon: "refresh",
|
596
|
+
indicator: false,
|
597
|
+
func: () => this._refresh(),
|
598
|
+
label: this._translations.refresh,
|
599
|
+
disabled: false,
|
600
|
+
isOverflow: false
|
601
|
+
},
|
602
|
+
this.enableCSV ? {
|
603
|
+
active: false,
|
604
|
+
icon: "export",
|
605
|
+
indicator: false,
|
606
|
+
func: () => void this._exportToCSV(),
|
607
|
+
label: this._translations.exportCSV,
|
608
|
+
disabled: featuresEmpty,
|
609
|
+
isOverflow: false
|
610
|
+
} : undefined, {
|
611
|
+
active: false,
|
612
|
+
icon: this._showHideOpen ? "chevron-down" : "chevron-right",
|
613
|
+
indicator: false,
|
614
|
+
func: () => this._toggleShowHide(),
|
615
|
+
label: this._translations.showHideColumns,
|
616
|
+
disabled: false,
|
617
|
+
isOverflow: false,
|
618
|
+
isSublist: true
|
619
|
+
}];
|
620
|
+
this._defaultVisibleToolSizeInfos = undefined;
|
621
|
+
}
|
620
622
|
}
|
621
623
|
/**
|
622
624
|
* Returns true when one ore more features are selected
|
@@ -827,12 +829,21 @@ const LayerTable = class {
|
|
827
829
|
if ((_b = this.mapInfo) === null || _b === void 0 ? void 0 : _b.id) {
|
828
830
|
urlObj.searchParams.set("webmap", this.mapInfo.id);
|
829
831
|
}
|
832
|
+
else {
|
833
|
+
urlObj.searchParams.delete("webmap");
|
834
|
+
}
|
830
835
|
if ((_c = this._layer) === null || _c === void 0 ? void 0 : _c.id) {
|
831
836
|
urlObj.searchParams.set("layer", this._layer.id);
|
832
837
|
}
|
838
|
+
else {
|
839
|
+
urlObj.searchParams.delete("layer");
|
840
|
+
}
|
833
841
|
if (((_d = this._selectedIndexes) === null || _d === void 0 ? void 0 : _d.length) > 0) {
|
834
842
|
urlObj.searchParams.set("oid", this._selectedIndexes.join(","));
|
835
843
|
}
|
844
|
+
else {
|
845
|
+
urlObj.searchParams.delete("oid");
|
846
|
+
}
|
836
847
|
if (this._filterActive) {
|
837
848
|
const filter = JSON.parse(this._filterList.urlParams.get("filter"));
|
838
849
|
const layerExpressions = this._filterList.layerExpressions.map(layerExp => {
|
@@ -846,7 +857,11 @@ const LayerTable = class {
|
|
846
857
|
});
|
847
858
|
urlObj.searchParams.set("filter", JSON.stringify(layerExpressions));
|
848
859
|
}
|
860
|
+
else {
|
861
|
+
urlObj.searchParams.delete("filter");
|
862
|
+
}
|
849
863
|
this._shareNode.shareUrl = urlObj.href;
|
864
|
+
history.pushState(history.state, document.title, urlObj.href);
|
850
865
|
}
|
851
866
|
/**
|
852
867
|
* Get a tooltip
|
@@ -1166,7 +1181,7 @@ const LayerTable = class {
|
|
1166
1181
|
*/
|
1167
1182
|
_filterModal() {
|
1168
1183
|
var _a, _b, _c;
|
1169
|
-
return (index.h("calcite-modal", { "aria-labelledby": "modal-title", class: "modal", kind: "brand", onCalciteModalClose: async () => this._closeFilter(), open: this._filterOpen, widthScale: "s" }, index.h("div", { class: "display-flex align-center", id: "modal-title", slot: "header" }, (_b = (_a = this._translations) === null || _a === void 0 ? void 0 : _a.filter) === null || _b === void 0 ? void 0 : _b.replace("{{title}}", (_c = this._layer) === null || _c === void 0 ? void 0 : _c.title)), index.h("div", { slot: "content" }, index.h("instant-apps-filter-list", { autoUpdateUrl:
|
1184
|
+
return (index.h("calcite-modal", { "aria-labelledby": "modal-title", class: "modal", kind: "brand", onCalciteModalClose: async () => this._closeFilter(), open: this._filterOpen, widthScale: "s" }, index.h("div", { class: "display-flex align-center", id: "modal-title", slot: "header" }, (_b = (_a = this._translations) === null || _a === void 0 ? void 0 : _a.filter) === null || _b === void 0 ? void 0 : _b.replace("{{title}}", (_c = this._layer) === null || _c === void 0 ? void 0 : _c.title)), index.h("div", { slot: "content" }, index.h("instant-apps-filter-list", { autoUpdateUrl: true, closeBtn: true, closeBtnOnClick: async () => this._closeFilter(), layerExpressions: this._layerExpressions, onFilterListReset: () => this._handleFilterListReset(), onFilterUpdate: () => this._handleFilterUpdate(), ref: (el) => this._filterList = el, view: this.mapView, zoomBtn: false }))));
|
1170
1185
|
}
|
1171
1186
|
/**
|
1172
1187
|
* Reset the filter active prop
|
@@ -444,93 +444,95 @@ export class LayerTable {
|
|
444
444
|
const featuresSelected = this._featuresSelected();
|
445
445
|
const featuresEmpty = this._featuresEmpty();
|
446
446
|
const hasFilterExpressions = this._hasFilterExpressions();
|
447
|
-
this.
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
|
506
|
-
|
507
|
-
|
508
|
-
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
|
527
|
-
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
447
|
+
if (this._translations) {
|
448
|
+
this._toolInfos = [{
|
449
|
+
active: false,
|
450
|
+
icon: "zoom-to-object",
|
451
|
+
indicator: false,
|
452
|
+
label: this._translations.zoom,
|
453
|
+
func: () => this._zoom(),
|
454
|
+
disabled: !featuresSelected,
|
455
|
+
isOverflow: false
|
456
|
+
},
|
457
|
+
hasFilterExpressions ? {
|
458
|
+
active: false,
|
459
|
+
icon: "filter",
|
460
|
+
indicator: false,
|
461
|
+
label: this._translations.filters,
|
462
|
+
func: () => this._toggleFilter(),
|
463
|
+
disabled: false,
|
464
|
+
isOverflow: false
|
465
|
+
} : undefined,
|
466
|
+
this._deleteEnabled ? {
|
467
|
+
active: false,
|
468
|
+
icon: "trash",
|
469
|
+
indicator: false,
|
470
|
+
label: this._translations.delete,
|
471
|
+
func: () => this._delete(),
|
472
|
+
disabled: !featuresSelected,
|
473
|
+
isDanger: true,
|
474
|
+
isOverflow: false
|
475
|
+
} : undefined, {
|
476
|
+
active: false,
|
477
|
+
icon: "erase",
|
478
|
+
indicator: false,
|
479
|
+
label: this._translations.clearSelection,
|
480
|
+
func: () => this._clearSelection(),
|
481
|
+
disabled: !featuresSelected,
|
482
|
+
isOverflow: false
|
483
|
+
}, {
|
484
|
+
active: false,
|
485
|
+
icon: "selected-items-filter",
|
486
|
+
indicator: false,
|
487
|
+
label: this._showOnlySelected ? this._translations.showAll : this._translations.showSelected,
|
488
|
+
func: () => this._toggleShowSelected(),
|
489
|
+
disabled: !featuresSelected,
|
490
|
+
isOverflow: false
|
491
|
+
}, {
|
492
|
+
active: false,
|
493
|
+
icon: "list-check-all",
|
494
|
+
indicator: false,
|
495
|
+
func: () => this._selectAll(),
|
496
|
+
label: this._translations.selectAll,
|
497
|
+
disabled: featuresEmpty,
|
498
|
+
isOverflow: false
|
499
|
+
}, {
|
500
|
+
active: false,
|
501
|
+
icon: "compare",
|
502
|
+
indicator: false,
|
503
|
+
func: () => this._switchSelected(),
|
504
|
+
label: this._translations.switchSelected,
|
505
|
+
disabled: featuresEmpty,
|
506
|
+
isOverflow: false
|
507
|
+
}, {
|
508
|
+
active: false,
|
509
|
+
icon: "refresh",
|
510
|
+
indicator: false,
|
511
|
+
func: () => this._refresh(),
|
512
|
+
label: this._translations.refresh,
|
513
|
+
disabled: false,
|
514
|
+
isOverflow: false
|
515
|
+
},
|
516
|
+
this.enableCSV ? {
|
517
|
+
active: false,
|
518
|
+
icon: "export",
|
519
|
+
indicator: false,
|
520
|
+
func: () => void this._exportToCSV(),
|
521
|
+
label: this._translations.exportCSV,
|
522
|
+
disabled: featuresEmpty,
|
523
|
+
isOverflow: false
|
524
|
+
} : undefined, {
|
525
|
+
active: false,
|
526
|
+
icon: this._showHideOpen ? "chevron-down" : "chevron-right",
|
527
|
+
indicator: false,
|
528
|
+
func: () => this._toggleShowHide(),
|
529
|
+
label: this._translations.showHideColumns,
|
530
|
+
disabled: false,
|
531
|
+
isOverflow: false,
|
532
|
+
isSublist: true
|
533
|
+
}];
|
534
|
+
this._defaultVisibleToolSizeInfos = undefined;
|
535
|
+
}
|
534
536
|
}
|
535
537
|
/**
|
536
538
|
* Returns true when one ore more features are selected
|
@@ -741,12 +743,21 @@ export class LayerTable {
|
|
741
743
|
if ((_b = this.mapInfo) === null || _b === void 0 ? void 0 : _b.id) {
|
742
744
|
urlObj.searchParams.set("webmap", this.mapInfo.id);
|
743
745
|
}
|
746
|
+
else {
|
747
|
+
urlObj.searchParams.delete("webmap");
|
748
|
+
}
|
744
749
|
if ((_c = this._layer) === null || _c === void 0 ? void 0 : _c.id) {
|
745
750
|
urlObj.searchParams.set("layer", this._layer.id);
|
746
751
|
}
|
752
|
+
else {
|
753
|
+
urlObj.searchParams.delete("layer");
|
754
|
+
}
|
747
755
|
if (((_d = this._selectedIndexes) === null || _d === void 0 ? void 0 : _d.length) > 0) {
|
748
756
|
urlObj.searchParams.set("oid", this._selectedIndexes.join(","));
|
749
757
|
}
|
758
|
+
else {
|
759
|
+
urlObj.searchParams.delete("oid");
|
760
|
+
}
|
750
761
|
if (this._filterActive) {
|
751
762
|
const filter = JSON.parse(this._filterList.urlParams.get("filter"));
|
752
763
|
const layerExpressions = this._filterList.layerExpressions.map(layerExp => {
|
@@ -760,7 +771,11 @@ export class LayerTable {
|
|
760
771
|
});
|
761
772
|
urlObj.searchParams.set("filter", JSON.stringify(layerExpressions));
|
762
773
|
}
|
774
|
+
else {
|
775
|
+
urlObj.searchParams.delete("filter");
|
776
|
+
}
|
763
777
|
this._shareNode.shareUrl = urlObj.href;
|
778
|
+
history.pushState(history.state, document.title, urlObj.href);
|
764
779
|
}
|
765
780
|
/**
|
766
781
|
* Get a tooltip
|
@@ -1080,7 +1095,7 @@ export class LayerTable {
|
|
1080
1095
|
*/
|
1081
1096
|
_filterModal() {
|
1082
1097
|
var _a, _b, _c;
|
1083
|
-
return (h("calcite-modal", { "aria-labelledby": "modal-title", class: "modal", kind: "brand", onCalciteModalClose: async () => this._closeFilter(), open: this._filterOpen, widthScale: "s" }, h("div", { class: "display-flex align-center", id: "modal-title", slot: "header" }, (_b = (_a = this._translations) === null || _a === void 0 ? void 0 : _a.filter) === null || _b === void 0 ? void 0 : _b.replace("{{title}}", (_c = this._layer) === null || _c === void 0 ? void 0 : _c.title)), h("div", { slot: "content" }, h("instant-apps-filter-list", { autoUpdateUrl:
|
1098
|
+
return (h("calcite-modal", { "aria-labelledby": "modal-title", class: "modal", kind: "brand", onCalciteModalClose: async () => this._closeFilter(), open: this._filterOpen, widthScale: "s" }, h("div", { class: "display-flex align-center", id: "modal-title", slot: "header" }, (_b = (_a = this._translations) === null || _a === void 0 ? void 0 : _a.filter) === null || _b === void 0 ? void 0 : _b.replace("{{title}}", (_c = this._layer) === null || _c === void 0 ? void 0 : _c.title)), h("div", { slot: "content" }, h("instant-apps-filter-list", { autoUpdateUrl: true, closeBtn: true, closeBtnOnClick: async () => this._closeFilter(), layerExpressions: this._layerExpressions, onFilterListReset: () => this._handleFilterListReset(), onFilterUpdate: () => this._handleFilterUpdate(), ref: (el) => this._filterList = el, view: this.mapView, zoomBtn: false }))));
|
1084
1099
|
}
|
1085
1100
|
/**
|
1086
1101
|
* Reset the filter active prop
|