Skip to content

Commit

Permalink
feat: Add information banner if logged out (#315)
Browse files Browse the repository at this point in the history
  • Loading branch information
thielpa authored Feb 4, 2025
1 parent 70e8dc9 commit d3fef31
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
7 changes: 7 additions & 0 deletions client/src/app/pages/main-layout/main-layout.component.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
@if (!isLoggedIn()) {
<div class="top-1 bg-gray-700 text-white rounded-b-2xl z-50 text-center flex items-center justify-center gap-1">
You are currently using Helios in readonly mode.
<button (click)="login()" class="p-0 text-white hover:text-gray-300 underline">Login here.</button>
</div>
}

<main class="h-screen overflow-hidden">
<div class="flex h-full p-3">
<!-- Fixed Navigation Bar -->
Expand Down
2 changes: 2 additions & 0 deletions client/src/app/pages/main-layout/main-layout.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ export class MainLayoutComponent {
this.keycloakService.login();
}

isLoggedIn = computed(() => this.keycloakService.isLoggedIn());

items = computed(() => {
const baseItems = [
{
Expand Down

0 comments on commit d3fef31

Please sign in to comment.