feat: add navbar component to multiple pages
This commit is contained in:
parent
e5bd173be9
commit
b2f4d9d0d8
5 changed files with 16 additions and 15 deletions
|
@ -1,7 +1,6 @@
|
||||||
<div class="min-h-screen flex flex-col">
|
<div class="min-h-screen flex flex-col">
|
||||||
<app-navbar></app-navbar>
|
|
||||||
<main class="flex-grow">
|
<main class="flex-grow">
|
||||||
<router-outlet></router-outlet>
|
<router-outlet></router-outlet>
|
||||||
</main>
|
</main>
|
||||||
<app-footer></app-footer>
|
<app-footer></app-footer>
|
||||||
</div>
|
</div>
|
|
@ -1,14 +1,4 @@
|
||||||
<nav class="bg-black border-b border-amber-600/30 sticky top-0 z-50">
|
<app-navbar></app-navbar>
|
||||||
<div class="container mx-auto px-4 py-3 flex justify-between items-center">
|
|
||||||
<!-- logo goes here -->
|
|
||||||
<div class="flex gap-4">
|
|
||||||
<button class="btn-primary" (click)="logout()">Ausloggen</button>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<button (click)="openDialog()">Einzahlen</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="grid grid-cols-3">
|
<div class="grid grid-cols-3">
|
||||||
<div class="w-1/3 h-1/4">
|
<div class="w-1/3 h-1/4">
|
||||||
|
|
|
@ -3,11 +3,12 @@ import { KeycloakService } from 'keycloak-angular';
|
||||||
import { MatDialog } from '@angular/material/dialog';
|
import { MatDialog } from '@angular/material/dialog';
|
||||||
import { DepositComponent } from '../deposit/deposit.component';
|
import { DepositComponent } from '../deposit/deposit.component';
|
||||||
|
|
||||||
|
import { NavbarComponent } from '../../shared/components/navbar/navbar.component';
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-homepage',
|
selector: 'app-homepage',
|
||||||
standalone: true,
|
standalone: true,
|
||||||
imports: [],
|
imports: [NavbarComponent],
|
||||||
templateUrl: './home.component.html',
|
templateUrl: './homepage.component.html',
|
||||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
})
|
})
|
||||||
export class HomeComponent {
|
export class HomeComponent {
|
||||||
|
|
|
@ -1 +1,2 @@
|
||||||
|
<app-navbar></app-navbar>
|
||||||
<button (click)="login()">Einloggen</button>
|
<button (click)="login()">Einloggen</button>
|
||||||
|
|
10
frontend/src/app/landing-page/landing-page.component.ts
Normal file
10
frontend/src/app/landing-page/landing-page.component.ts
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
import { Component } from '@angular/core';
|
||||||
|
import { NavbarComponent } from '../shared/components/navbar/navbar.component';
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'app-landing-page',
|
||||||
|
standalone: true,
|
||||||
|
imports: [NavbarComponent],
|
||||||
|
templateUrl: './landing-page.component.html',
|
||||||
|
})
|
||||||
|
export class LandingPageComponent {}
|
Reference in a new issue