Skip to content

Commit

Permalink
feat(layer-list): Fix layer filter on top of list (#882)
Browse files Browse the repository at this point in the history
* fixTop-LayerListFilter

* fix(map tools): fix Top-LayerListFilter for mapTools, map and mapDetails

Co-authored-by: Pierre-Etienne Lord <[email protected]>
  • Loading branch information
josee666 and pelord authored Jun 23, 2021
1 parent 5e4612d commit 5cdd067
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 5 deletions.
3 changes: 1 addition & 2 deletions packages/geo/src/lib/import-export/shared/import.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,7 @@ export class ImportService {
const errMsg = error.error.msg || '';
if (errMsg === 'No valid files found') {
observer.error(new ImportInvalidFileError());
} else if (
errMsg.startWith('ERROR 1: Failed to process SRS definition')
} else if (errMsg && errMsg.startWith('ERROR 1: Failed to process SRS definition')
) {
observer.error(new ImportSRSError());
} else {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<igo-list #igoList [ngClass]="(layerTool || selection) ? 'igo-list-min-height': 'igo-list-max-height'" [navigation]="false" [selection]="false">

<mat-list>
<igo-layer-list-tool *ngIf="showToolbar$ | async"
floatLabel="auto"
[layersAreAllVisible]="layersAreAllVisible"
Expand All @@ -8,7 +9,9 @@
(appliedFilterAndSort)="onAppliedFilterAndSortChange($event)"
(selection)="toggleSelectionMode($event)">
</igo-layer-list-tool>
</mat-list>

<igo-list #igoList [ngClass]="(layerTool || selection) ? 'igo-list-min-height': 'igo-list-max-height'" [navigation]="false" [selection]="false">
<ng-template ngFor let-layer let-i="index" [ngForOf]="layers$ | async">
<igo-layer-item *ngIf="!(excludeBaseLayers && layer.baseLayer)"
igoListItem
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
:host .igo-list-min-height {
height: calc(100% - 91px);
height: calc(100% - 151px);
padding-top: 8px;
}

:host .igo-list-max-height {
padding-top: 8px;
height: calc(100% - 55px);
}

mat-form-field.inputFilter {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<igo-layer-list *ngIf="(layers$ | async).length; else empty"
<igo-layer-list class="mapDetailsList" *ngIf="(layers$ | async).length; else empty"
[map]="map"
igoLayerListBinding
[excludeBaseLayers]="excludeBaseLayers"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,7 @@ mat-list-item ::ng-deep .mat-list-text {
mat-list.mat-list-base mat-list-item.mat-list-item ::ng-deep div.mat-list-item-content div.mat-list-text {
padding-left: 5px;
}

.mapDetailsList {
overflow: hidden;
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
mat-tab-group,
mat-tab-group ::ng-deep .mat-tab-body-wrapper {
height: 100%;
overflow: hidden;
}

:host ::ng-deep .mat-tab-body-content {
overflow: hidden;
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,10 @@ mat-list.mat-list-base mat-list-item.mat-list-item ::ng-deep div.mat-list-item-c
mat-tab-group,
mat-tab-group ::ng-deep .mat-tab-body-wrapper {
height: 100%;
overflow: hidden;
}

:host ::ng-deep .mat-tab-body-content {
overflow: hidden;
}

0 comments on commit 5cdd067

Please sign in to comment.