Files
barker/bookie/src/app/devices/device-detail/device-detail.component.html
Amritanshu efa2af396d Chore: Moved from css to sass, god knows what to do now.
Chore: Prettier line length changed to 120 from 100
Fix: Hard coded the face as the primary color to make the buttons stand out
2023-03-13 23:52:44 +05:30

36 lines
1.4 KiB
HTML

<mat-card class="flex-auto lg:max-w-[50%]">
<mat-card-header>
<mat-card-title>Device</mat-card-title>
</mat-card-header>
<mat-card-content>
<form [formGroup]="form" class="flex flex-col">
<div class="flex flex-row justify-around content-start items-start">
<mat-form-field class="flex-auto">
<mat-label>Name</mat-label>
<input matInput #nameElement formControlName="name" (keyup.enter)="save()" />
</mat-form-field>
</div>
<div class="flex flex-row justify-around content-start items-start">
<mat-form-field class="flex-auto">
<mat-label>Section</mat-label>
<mat-select formControlName="section">
<mat-option *ngFor="let s of sections" [value]="s.id">
{{ s.name }}
</mat-option>
</mat-select>
</mat-form-field>
</div>
<div class="flex flex-row justify-around content-start items-start">
<mat-checkbox formControlName="enabled" class="flex-auto">Enabled?</mat-checkbox>
</div>
</form>
</mat-card-content>
<mat-card-actions>
<button mat-raised-button color="primary" class="mr-5" (click)="save()">Save</button>
<button mat-raised-button color="warn" (click)="confirmDelete()" *ngIf="!!item.id">Delete</button>
</mat-card-actions>
<mat-card-subtitle>
Created on <strong>{{ item.creationDate | localTime }}</strong>
</mat-card-subtitle>
</mat-card>