From a4e446238b9249e1a38d4fded078ee76a895de3c Mon Sep 17 00:00:00 2001 From: Mosiur Rahman Date: Mon, 10 Mar 2025 15:27:59 +0600 Subject: [PATCH] Adding Dashboard --- src/app/app.routes.ts | 3 +- .../pages/dashboard/dashboard.component.html | 14 ++++++ .../pages/dashboard/dashboard.component.scss | 49 +++++++++++++++++++ .../dashboard/dashboard.component.spec.ts | 23 +++++++++ .../pages/dashboard/dashboard.component.ts | 12 +++++ src/app/shared/scss/colors.scss | 14 +++--- 6 files changed, 108 insertions(+), 7 deletions(-) create mode 100644 src/app/components/pages/dashboard/dashboard.component.html create mode 100644 src/app/components/pages/dashboard/dashboard.component.scss create mode 100644 src/app/components/pages/dashboard/dashboard.component.spec.ts create mode 100644 src/app/components/pages/dashboard/dashboard.component.ts diff --git a/src/app/app.routes.ts b/src/app/app.routes.ts index a77a089..3d861d4 100644 --- a/src/app/app.routes.ts +++ b/src/app/app.routes.ts @@ -5,9 +5,10 @@ import { NoMansLandComponent } from './components/pages/no-mans-land/no-mans-lan import { ToolListComponent } from './components/pages/tool-list/tool-list.component'; import { LoginComponent } from './components/pages/login/login.component'; import { BitComponent } from './components/pages/bit/bit.component'; +import { DashboardComponent } from './components/pages/dashboard/dashboard.component'; export const routes: Routes = [ - {path: "", component: NoMansLandComponent}, + {path: "", component: DashboardComponent}, {path: "backup", component: BackupListComponent}, {path: "update", component: ShiftUpdateComponent}, {path: "creds", component: ToolListComponent }, diff --git a/src/app/components/pages/dashboard/dashboard.component.html b/src/app/components/pages/dashboard/dashboard.component.html new file mode 100644 index 0000000..d7f3c4d --- /dev/null +++ b/src/app/components/pages/dashboard/dashboard.component.html @@ -0,0 +1,14 @@ +
+ +
\ No newline at end of file diff --git a/src/app/components/pages/dashboard/dashboard.component.scss b/src/app/components/pages/dashboard/dashboard.component.scss new file mode 100644 index 0000000..dad0d6c --- /dev/null +++ b/src/app/components/pages/dashboard/dashboard.component.scss @@ -0,0 +1,49 @@ +@import "./../../../shared/scss/colors.scss"; + +.container { + color: $nav-text-color; +} + +.navbar { + background-color: $navcolor; + width: 100%; + height: 80px; +} + +.dropbtn { + background-color: $navcolor; + color: $nav-text-color; + padding: 16px; + font-size: 1rem; + border: none; +} + +.services-dropdown { + position: relative; + display: inline-block; +} + +.dropdown-content { + position: absolute; + display: none; + background-color: rgba($nav-text-color,0.3); + min-width: 160px; + box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2); + z-index: 1; +} + +.dropdown-content a { + color: black; + padding: 12px 16px; + text-decoration: none; + display: block; +} + +.dropdown-content a:hover {background-color: #ddd;} +.dropdown:hover .dropdown-content { + display: block; +} + +.dropdown:hover .dropbtn { + background-color: rgba($nav-text-color,0.1); +} \ No newline at end of file diff --git a/src/app/components/pages/dashboard/dashboard.component.spec.ts b/src/app/components/pages/dashboard/dashboard.component.spec.ts new file mode 100644 index 0000000..30e39a2 --- /dev/null +++ b/src/app/components/pages/dashboard/dashboard.component.spec.ts @@ -0,0 +1,23 @@ +import { ComponentFixture, TestBed } from '@angular/core/testing'; + +import { DashboardComponent } from './dashboard.component'; + +describe('DashboardComponent', () => { + let component: DashboardComponent; + let fixture: ComponentFixture; + + beforeEach(async () => { + await TestBed.configureTestingModule({ + imports: [DashboardComponent] + }) + .compileComponents(); + + fixture = TestBed.createComponent(DashboardComponent); + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should create', () => { + expect(component).toBeTruthy(); + }); +}); diff --git a/src/app/components/pages/dashboard/dashboard.component.ts b/src/app/components/pages/dashboard/dashboard.component.ts new file mode 100644 index 0000000..68e461a --- /dev/null +++ b/src/app/components/pages/dashboard/dashboard.component.ts @@ -0,0 +1,12 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'app-dashboard', + standalone: true, + imports: [], + templateUrl: './dashboard.component.html', + styleUrl: './dashboard.component.scss' +}) +export class DashboardComponent { + +} diff --git a/src/app/shared/scss/colors.scss b/src/app/shared/scss/colors.scss index 8ad1be8..09815b6 100644 --- a/src/app/shared/scss/colors.scss +++ b/src/app/shared/scss/colors.scss @@ -1,6 +1,8 @@ -$bg-color: #FEF9F2; -$txt-heading-color: #72BF78; -$txt-color: #1E201E; -$hover-color: #B6FFA1; -$title: #62825D; -$danger: #D91656; \ No newline at end of file +$bg-color: #f4f1de; +$txt-heading-color: #e07a5f; +$txt-color: #e07a5f; +$hover-color: #e07a5f; +$title: #e07a5f; +$danger: #D91656; +$navcolor: #352208; +$nav-text-color: #e1bb80; \ No newline at end of file