Remove vertical dots, put lang menu in nav

This commit is contained in:
Sean Engelhardt 2018-08-09 13:45:48 +02:00 committed by FinnStutzenstein
parent 0099c34615
commit 7856b7e07f

View File

@ -13,7 +13,10 @@
{{username}} {{username}}
</mat-expansion-panel-header> </mat-expansion-panel-header>
<mat-nav-list> <mat-nav-list>
<!-- <mat-list-item> --> <a mat-list-item [matMenuTriggerFor]="languageMenu">
<fa-icon icon='globe-americas'></fa-icon>
<span> {{getLangName(this.translate.currentLang)}} </span>
</a>
<a (click)='logOutButton()' mat-list-item> <a (click)='logOutButton()' mat-list-item>
<fa-icon icon='user-cog'></fa-icon> <fa-icon icon='user-cog'></fa-icon>
<span translate>Edit Profile</span> <span translate>Edit Profile</span>
@ -29,6 +32,12 @@
</a> </a>
</mat-nav-list> </mat-nav-list>
</mat-expansion-panel> </mat-expansion-panel>
<!-- TODO: Could use translate.getLangs() to fetch available languages-->
<mat-menu #languageMenu="matMenu">
<button mat-menu-item (click)='selectLang("en")' translate>English</button>
<button mat-menu-item (click)='selectLang("de")' translate>German</button>
<button mat-menu-item (click)='selectLang("fr")' translate>French</button>
</mat-menu>
<!-- navigation --> <!-- navigation -->
<mat-nav-list class='main-nav'> <mat-nav-list class='main-nav'>
@ -94,20 +103,7 @@
<button mat-icon-button (click)='sideNav.toggle()'> <button mat-icon-button (click)='sideNav.toggle()'>
<fa-icon icon='search'></fa-icon> <fa-icon icon='search'></fa-icon>
</button> </button>
<button mat-icon-button (click)='sideNav.toggle()'>
<fa-icon icon='ellipsis-v'></fa-icon>
</button>
<button mat-button [matMenuTriggerFor]="languageMenu">
<fa-icon icon='globe-americas'></fa-icon>
<span> {{getLangName(this.translate.currentLang)}} </span>
</button>
<!-- TODO: Could use translate.getLangs() to fetch available languages-->
<mat-menu #languageMenu="matMenu">
<button mat-menu-item (click)='selectLang("en")' translate>English</button>
<button mat-menu-item (click)='selectLang("de")' translate>German</button>
<button mat-menu-item (click)='selectLang("fr")' translate>French</button>
</mat-menu>
</mat-toolbar> </mat-toolbar>
<!-- continue with <mat-toolbar> in the app--> <!-- continue with <mat-toolbar> in the app-->