-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat(rotation): show azimuth on map view rotation (issue igo2 780) * i18n(rotation): add degree north °N * i18n(rotation): typo * lint * wip Co-authored-by: Pierre-Étienne Lord <[email protected]>
- Loading branch information
Showing
6 changed files
with
48 additions
and
54 deletions.
There are no files selected for viewing
18 changes: 4 additions & 14 deletions
18
packages/geo/src/lib/map/rotation-button/rotation-button.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,9 @@ | ||
<div *ngIf="rotated && !showIfNoRotation" class="igo-rotation-button-container" | ||
[matTooltip]="rotated ? ('igo.geo.mapButtons.resetRotation' | translate): ('igo.geo.mapButtons.tipRotation' | translate)" | ||
<div *ngIf="((rotated$ | async) && !showIfNoRotation) || showIfNoRotation" class="igo-rotation-button-container" | ||
[matTooltip]="(rotated$ | async) ? ('igo.geo.mapButtons.resetRotation' | translate: {azimuth: azimuthRounded, rotation: rotationRounded}): ('igo.geo.mapButtons.tipRotation' | translate)" | ||
matTooltipPosition="left"> | ||
<button mat-icon-button matTooltipPosition="left" [color]="color" [disabled]="!rotated" | ||
<button mat-icon-button matTooltipPosition="left" [color]="color" [disabled]="(rotated$ | async) === false" | ||
(click)="map.viewController.resetRotation()"> | ||
<mat-icon [ngStyle]="rotationStyle(map.viewController.getRotation())" svgIcon="navigation"> | ||
<mat-icon [ngStyle]="currentStyle$ | async" svgIcon="navigation"> | ||
</mat-icon> | ||
</button> | ||
</div> | ||
|
||
<div *ngIf="showIfNoRotation" class="igo-rotation-button-container" | ||
[matTooltip]="rotated ? ('igo.geo.mapButtons.resetRotation' | translate): ('igo.geo.mapButtons.tipRotation' | translate)" | ||
matTooltipPosition="left"> | ||
<button mat-icon-button matTooltipPosition="left" [color]="color" [disabled]="!rotated" | ||
(click)="map.viewController.resetRotation()"> | ||
<mat-icon [ngStyle]="rotationStyle(map.viewController.getRotation())" svgIcon="navigation"> | ||
</mat-icon> | ||
</button> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters