Skip to content

Commit

Permalink
feat(auth): moved logout button to settings page
Browse files Browse the repository at this point in the history
undefined
  • Loading branch information
ZenSoftware committed Jun 8, 2023
1 parent 823d70a commit 30388b3
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
5 changes: 0 additions & 5 deletions apps/portal/src/app/app.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,6 @@
<i class="fa-solid fa-fw fa-user-shield me-2"></i>
Super
</a>

<a mat-list-item (click)="auth.logout()">
<i class="fa-solid fa-fw fa-sign-in-alt me-2"></i>
Logout
</a>
</mat-nav-list>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ <h1>
</div>
</div>

<button mat-raised-button color="primary" (click)="auth.logout()" class="w-100 fs-4 py-1 mb-4">
<i class="fa-solid fa-fw fa-sign-out-alt me-2"></i>
Logout
</button>

<div class="mb-4">
<zen-password-change *ngIf="accountInfo.hasPassword"/>
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import { AsyncPipe, NgIf } from '@angular/common';
import { Component } from '@angular/core';
import { MatButtonModule } from '@angular/material/button';
import { AuthService } from '@zen/auth';
import { ZenAccountInfoComponent, ZenPasswordChangeComponent } from '@zen/auth';

@Component({
selector: 'zen-settings',
templateUrl: 'zen-settings.component.html',
standalone: true,
imports: [AsyncPipe, NgIf, ZenAccountInfoComponent, ZenPasswordChangeComponent],
imports: [AsyncPipe, MatButtonModule, NgIf, ZenAccountInfoComponent, ZenPasswordChangeComponent],
})
export class ZenSettingsComponent {
constructor(public auth: AuthService) {}
Expand Down

0 comments on commit 30388b3

Please sign in to comment.