diff --git a/src/app/components/simple-layout/simple-layout.html b/src/app/components/simple-layout/simple-layout.html index 00d229a..d2d063c 100644 --- a/src/app/components/simple-layout/simple-layout.html +++ b/src/app/components/simple-layout/simple-layout.html @@ -1,4 +1,11 @@
-

{{title()|translate|titlecase}}

+
+ @if(withBackBtn()){ + + } +

{{title()|translate|titlecase}}

+
\ No newline at end of file diff --git a/src/app/components/simple-layout/simple-layout.scss b/src/app/components/simple-layout/simple-layout.scss index 830bc27..e81d922 100644 --- a/src/app/components/simple-layout/simple-layout.scss +++ b/src/app/components/simple-layout/simple-layout.scss @@ -1,3 +1,19 @@ +header { + display: flex; + button { + background-color: unset; + border: unset; + } + & .icon { + align-items: center; + display: flex; + padding-right: 16px; + } +} + .content { + display: flex; + flex-direction: column; + height: 100%; padding: 0px 16px; } \ No newline at end of file diff --git a/src/app/components/simple-layout/simple-layout.ts b/src/app/components/simple-layout/simple-layout.ts index 0bd2e1a..295368e 100644 --- a/src/app/components/simple-layout/simple-layout.ts +++ b/src/app/components/simple-layout/simple-layout.ts @@ -1,13 +1,18 @@ import { TitleCasePipe } from '@angular/common'; -import { Component, input } from '@angular/core'; +import { Component, inject, input } from '@angular/core'; import { TranslatePipe } from '@ngx-translate/core'; - +import { RouterLink } from "@angular/router"; +import { Location } from '@angular/common'; +import { MatIcon } from "@angular/material/icon"; +import { MatAnchor, MatButton } from "@angular/material/button"; @Component({ selector: 'app-simple-layout', - imports: [TranslatePipe, TitleCasePipe], + imports: [TranslatePipe, TitleCasePipe, MatIcon], templateUrl: './simple-layout.html', styleUrl: './simple-layout.scss', }) export class SimpleLayout { + protected location = inject(Location) readonly title = input(''); + readonly withBackBtn = input(false); }