Files
dashboard/frontend/src/app/components/item-form/item-form.html
2026-01-31 00:09:53 +01:00

33 lines
1.1 KiB
HTML

<div class="container">
<mat-card>
<mat-card-title>{{ isEditMode ? 'Edit Item' : 'Create Item' }}</mat-card-title>
<mat-card-content>
<form [formGroup]="itemForm" (ngSubmit)="onSubmit()">
<mat-form-field appearance="fill">
<mat-label>Name</mat-label>
<input matInput formControlName="name">
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Display Name</mat-label>
<input matInput formControlName="displayName">
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Target</mat-label>
<input matInput formControlName="target">
</mat-form-field>
<mat-form-field appearance="fill">
<mat-label>Icon URL</mat-label>
<input matInput formControlName="iconUrl">
</mat-form-field>
<div class="actions">
<button type="button" mat-stroked-button (click)="cancel()">Cancel</button>
<button type="submit" mat-raised-button color="primary" [disabled]="itemForm.invalid">Save</button>
</div>
</form>
</mat-card-content>
</mat-card>
</div>