|
27 | 27 | <hr> |
28 | 28 |
|
29 | 29 | <div *ngIf="!authService.isAuthenticated(); else logout"> |
30 | | - <button mat-button routerLink="/signup" (click)="sidenav.close()"> |
31 | | - <mat-icon class="signup">person_add</mat-icon> |
32 | | - <span>Signup</span> |
33 | | - </button> |
34 | | - |
35 | | - <button mat-button routerLink="/login" (click)="sidenav.close()"> |
| 30 | + <button mat-button routerLink="/auth" (click)="sidenav.close()"> |
36 | 31 | <mat-icon class="login">lock_open</mat-icon> |
37 | | - <span>Login</span> |
| 32 | + <span>Auth</span> |
38 | 33 | </button> |
39 | 34 | </div> |
40 | 35 |
|
|
69 | 64 |
|
70 | 65 | <span class="spacer-light"></span> |
71 | 66 |
|
72 | | - <div *ngIf="!authService.isAuthenticated(); else loggedin"> |
73 | | - <!-- <a routerLink="/signup"><mat-icon>person_add</mat-icon></a> --> |
74 | | - <a routerLink="/auth"><mat-icon>lock_open</mat-icon></a> |
75 | | - </div> |
| 67 | + <div *ngIf="!authService.isAuthenticated(); else loggedin"> |
| 68 | + <button type="button" routerLink="/auth" mat-icon-button> |
| 69 | + <mat-icon>lock_open</mat-icon> |
| 70 | + </button> |
| 71 | + </div> |
| 72 | + |
| 73 | + |
| 74 | + <ng-template #loggedin> |
| 75 | + <h4>Welcome</h4> |
| 76 | + |
| 77 | + <button mat-icon-button [matMenuTriggerFor]="menu"> |
| 78 | + <mat-icon>more_vert</mat-icon> |
| 79 | + </button> |
| 80 | + |
| 81 | + <mat-menu #menu="matMenu" > |
| 82 | + <a |
| 83 | + mat-menu-item |
| 84 | + [routerLink]="'/profile'"> |
| 85 | + <mat-icon class="profile">face</mat-icon> |
| 86 | + <span>Profile</span> |
| 87 | + </a> |
| 88 | + |
| 89 | + <a mat-menu-item *ngFor="let item of menuItems" href="{{item.link}}" target="_blank"> |
| 90 | + <mat-icon class="login">{{item.icon}}</mat-icon> |
| 91 | + <span>{{item.title}}</span> |
| 92 | + </a> |
| 93 | + |
| 94 | + <a |
| 95 | + mat-menu-item |
| 96 | + routerLink="/profile-settings" |
| 97 | + [queryParams]="{profile: '1'}" |
| 98 | + fragment="editProfile"> |
| 99 | + <mat-icon class="settings">settings</mat-icon> |
| 100 | + <span>Settings</span> |
| 101 | + </a> |
| 102 | + |
| 103 | + <a mat-menu-item (click)="onLogout()"> |
| 104 | + <mat-icon class="logout">lock_outline</mat-icon> |
| 105 | + <span>Logout</span> |
| 106 | + </a> |
| 107 | + </mat-menu> |
76 | 108 |
|
77 | | - <ng-template #loggedin> |
78 | | - <h4>(User: {{userEmail()}})</h4> |
79 | | - |
80 | | - <button mat-icon-button [matMenuTriggerFor]="menu"> |
81 | | - <mat-icon>more_vert</mat-icon> |
82 | | - </button> |
83 | | - |
84 | | - <mat-menu #menu="matMenu" > |
85 | | - |
86 | | - <!-- [routerLink]="['/profile', userUid(), userName()]" --> |
87 | | - <a |
88 | | - mat-menu-item |
89 | | - [routerLink]="'/profile'"> |
90 | | - <mat-icon class="profile">face</mat-icon> |
91 | | - <span>Profile</span> |
92 | | - </a> |
93 | | - |
94 | | - <a mat-menu-item *ngFor="let item of menuItems" href="{{item.link}}"> |
95 | | - <mat-icon class="login">{{item.icon}}</mat-icon> |
96 | | - <span>{{item.title}}</span> |
97 | | - </a> |
98 | | - |
99 | | - <a |
100 | | - mat-menu-item |
101 | | - routerLink="/profile-settings" |
102 | | - [queryParams]="{profile: '1'}" |
103 | | - fragment="editProfile"> |
104 | | - <mat-icon class="settings">settings</mat-icon> |
105 | | - <span>Settings</span> |
106 | | - </a> |
107 | | - |
108 | | - <a mat-menu-item (click)="onLogout()"> |
109 | | - <mat-icon class="logout">lock_outline</mat-icon> |
110 | | - <span>Logout</span> |
111 | | - </a> |
112 | | - </mat-menu> |
113 | | - |
114 | | - </ng-template> |
| 109 | + </ng-template> |
115 | 110 | </mat-toolbar> |
0 commit comments