feat: add base class for settings add screen
This commit is contained in:
@@ -0,0 +1,8 @@
|
|||||||
|
<h3>{{title|translate|upperfirst}}</h3>
|
||||||
|
<ng-content></ng-content>
|
||||||
|
<app-action-btn
|
||||||
|
(click)="save()"
|
||||||
|
[disabled]="this.form.invalid"
|
||||||
|
class="top-auto"
|
||||||
|
text="{{'common.save'|translate|upperfirst}}"
|
||||||
|
/>
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
:host {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
import { FormGroup } from '@angular/forms';
|
||||||
|
|
||||||
|
export abstract class SettingsBaseAdd {
|
||||||
|
title = '';
|
||||||
|
form = new FormGroup({})
|
||||||
|
|
||||||
|
protected abstract save(): Promise<void>
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user