2018-10-05 16:34:08 +02:00
|
|
|
<mat-toolbar color='primary' [ngClass]="{'during-scroll': stickyToolbar}">
|
2018-08-28 13:54:25 +02:00
|
|
|
|
2018-10-05 16:34:08 +02:00
|
|
|
<mat-toolbar-row [ngClass]="{'hidden-bar': stickyToolbar}">
|
|
|
|
<!-- Nav menu -->
|
|
|
|
<button mat-icon-button *ngIf="vp.isMobile && nav" (click)='clickHamburgerMenu()'>
|
|
|
|
<mat-icon>menu</mat-icon>
|
|
|
|
</button>
|
|
|
|
</mat-toolbar-row>
|
2018-08-28 13:54:25 +02:00
|
|
|
|
2018-10-05 16:34:08 +02:00
|
|
|
<mat-toolbar-row [ngClass]="{'during-scroll': stickyToolbar}">
|
|
|
|
<div class="toolbar-left on-transition-fade">
|
|
|
|
<!-- Fab Button "Plus" -->
|
|
|
|
<button mat-fab class="head-button" *ngIf="plusButton && !editMode" (click)=clickPlusButton()>
|
|
|
|
<mat-icon>add</mat-icon>
|
|
|
|
</button>
|
2018-08-28 13:54:25 +02:00
|
|
|
|
2018-10-05 16:34:08 +02:00
|
|
|
<!-- Exit / Back button -->
|
|
|
|
<button mat-icon-button class="on-transition-fade" *ngIf="backButton && !editMode" (click)="onBackButton()">
|
|
|
|
<mat-icon>arrow_back</mat-icon>
|
|
|
|
</button>
|
2018-08-28 13:54:25 +02:00
|
|
|
|
2018-10-05 16:34:08 +02:00
|
|
|
<!-- Cancel edit button -->
|
|
|
|
<button mat-icon-button class="on-transition-fade" *ngIf="editMode" (click)="toggleEditMode()">
|
|
|
|
<mat-icon>close</mat-icon>
|
|
|
|
</button>
|
2018-09-18 18:27:14 +02:00
|
|
|
|
2018-10-05 16:34:08 +02:00
|
|
|
<div class="toolbar-left-text">
|
|
|
|
<!-- Title slot -->
|
|
|
|
<ng-content select=".title-slot"></ng-content>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="toolbar-right on-transition-fade" [ngClass]="{'toolbar-right-scroll': stickyToolbar, 'toolbar-right-top': !stickyToolbar}">
|
2018-10-11 14:03:44 +02:00
|
|
|
|
2018-10-05 16:34:08 +02:00
|
|
|
<!-- Extra controls slot -->
|
|
|
|
<div class="extra-controls-wrapper on-transition-fade">
|
|
|
|
<ng-content select=".extra-controls-slot"></ng-content>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Save button -->
|
|
|
|
<button mat-button *ngIf="editMode" (click)="save()">
|
|
|
|
<strong translate class="upper">Save</strong>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<!-- Edit button-->
|
|
|
|
<button mat-icon-button *ngIf="!editMode && allowEdit" (click)="toggleEditMode()">
|
|
|
|
<mat-icon>{{ editIcon }}</mat-icon>
|
|
|
|
</button>
|
|
|
|
|
|
|
|
<!-- Menu button slot -->
|
|
|
|
<ng-content *ngIf="!editMode" select=".menu-slot"></ng-content>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</mat-toolbar-row>
|
|
|
|
|
|
|
|
</mat-toolbar>
|
|
|
|
|
|
|
|
<!-- fake mat-toolbar to keep the distance when the real one gets a fixed position -->
|
|
|
|
<div class="fake-bar" [ngClass]="{'hidden-bar': !stickyToolbar}"></div>
|