OpenSlides/client/src/app/shared/components/head-bar/head-bar.component.html
Sean Engelhardt 9d37989ec7 Makes navigation from Legal notice and pp always possible.
Tracks the last history and evaluates if the last visited URL is safe to navigate to

also increases the version of djangorestframework.

fixes #4705
2019-06-25 10:45:24 +02:00

77 lines
2.6 KiB
HTML

<mat-toolbar color="primary" [ngClass]="multiSelectMode ? 'multi-select' : ''" *ngIf="!vp.isMobile">
<!-- Nav menu -->
<button mat-icon-button *ngIf="!multiSelectMode" (click)="clickHamburgerMenu()">
<mat-icon>menu</mat-icon>
</button>
</mat-toolbar>
<mat-toolbar color="primary" [ngClass]="multiSelectMode ? 'multi-select' : ''" class="sticky-toolbar">
<div class="toolbar-left">
<!-- Nav menu -->
<button mat-icon-button *ngIf="vp.isMobile && !showBackButton" (click)="clickHamburgerMenu()">
<mat-icon>menu</mat-icon>
</button>
<!-- Exit / Back button -->
<button mat-icon-button *ngIf="showBackButton" (click)="onBackButton()">
<mat-icon>arrow_back</mat-icon>
</button>
<!-- Cancel edit button -->
<button mat-icon-button *ngIf="editMode" (click)="sendMainEvent()">
<mat-icon>close</mat-icon>
</button>
<div class="toolbar-left-text" *ngIf="!multiSelectMode">
<!-- Title slot -->
<ng-content select=".title-slot"></ng-content>
</div>
</div>
<!-- centered information slot -->
<div *ngIf="!multiSelectMode" class="spacer"></div>
<div class="toolbar-centered" *ngIf="multiSelectMode">
<ng-content select=".central-info-slot"></ng-content>
</div>
<div class="spacer"></div>
<div class="toolbar-right">
<!-- Extra controls slot -->
<div class="extra-controls-wrapper">
<ng-content select=".extra-controls-slot"></ng-content>
</div>
<!-- Main action button - desktop -->
<button
mat-icon-button
*ngIf="mainButtonIcon == 'add' && mainButton && !editMode && !vp.isMobile && !multiSelectMode"
(click)="sendMainEvent()"
>
<mat-icon>add_circle</mat-icon>
</button>
<button
mat-icon-button
*ngIf="mainButtonIcon == 'edit' && mainButton && !editMode && !vp.isMobile && !multiSelectMode"
(click)="sendMainEvent()"
>
<mat-icon>edit</mat-icon>
</button>
<!-- Save button -->
<button mat-button *ngIf="editMode" (click)="save()"><strong translate class="upper">Save</strong></button>
<!-- Menu button slot -->
<ng-content *ngIf="!editMode" select=".menu-slot"></ng-content>
</div>
</mat-toolbar>
<!-- Main action button - mobile -->
<button
mat-fab
class="head-button "
*ngIf="mainButton && !editMode && vp.isMobile && !multiSelectMode"
(click)="sendMainEvent()"
>
<mat-icon>{{ mainButtonIcon }}</mat-icon>
</button>