-
\ No newline at end of file
diff --git a/frontend/src/app/admin/layout/dashboard-layout/dashboard-layout.component.ts b/frontend/src/app/admin/layout/dashboard-layout/dashboard-layout.component.ts
index 84a5368..8cacb1c 100644
--- a/frontend/src/app/admin/layout/dashboard-layout/dashboard-layout.component.ts
+++ b/frontend/src/app/admin/layout/dashboard-layout/dashboard-layout.component.ts
@@ -1,3 +1,4 @@
+import { NgClass, NgIf } from '@angular/common';
import { Component, OnInit } from '@angular/core';
import { RouterLink, RouterOutlet } from '@angular/router';
import { Router, NavigationEnd } from '@angular/router';
@@ -6,11 +7,13 @@ import { AuthService } from 'src/app/shared/services/auth.service';
@Component({
selector: 'app-dashboard-layout',
standalone: true,
- imports: [RouterOutlet, RouterLink],
+ imports: [RouterOutlet, RouterLink, NgClass, NgIf],
templateUrl: './dashboard-layout.component.html',
styleUrls: ['./dashboard-layout.component.scss'],
})
export class DashboardLayoutComponent implements OnInit {
+ sidebarOpen = true; // Change this to false if you want the sidebar to start closed
+
constructor(private router: Router, private authService: AuthService) {}
ngOnInit() {
@@ -21,6 +24,10 @@ export class DashboardLayoutComponent implements OnInit {
});
}
+ toggleSidebar() {
+ this.sidebarOpen = !this.sidebarOpen;
+ }
+
signOut() {
this.authService.logOut();
}
diff --git a/frontend/src/app/components/navbar/navbar.component.html b/frontend/src/app/components/navbar/navbar.component.html
index 6eb0adb..6a2f62b 100644
--- a/frontend/src/app/components/navbar/navbar.component.html
+++ b/frontend/src/app/components/navbar/navbar.component.html
@@ -11,17 +11,17 @@