39 lines
1.4 KiB
HTML
39 lines
1.4 KiB
HTML
@if (itemResource.isLoading()) {
|
|
<app-skeleton-loader type="card" [count]="1" />
|
|
} @else if (itemResource.error()) {
|
|
<app-error-state (retryAction)="itemResource.reload()" />
|
|
} @else {
|
|
<h2>User</h2>
|
|
<form class="flex-col">
|
|
<div class="row-container">
|
|
<mat-form-field class="flex-auto">
|
|
<mat-label>Name</mat-label>
|
|
<input matInput [formField]="form.name" />
|
|
</mat-form-field>
|
|
</div>
|
|
<div class="row-container">
|
|
<mat-form-field class="flex-auto">
|
|
<mat-label>Password</mat-label>
|
|
<input matInput [formField]="form.password" [type]="hide ? 'password' : 'text'" />
|
|
<mat-icon matSuffix (click)="hide = !hide">{{ hide ? 'visibility' : 'visibility_off' }}</mat-icon>
|
|
</mat-form-field>
|
|
</div>
|
|
<div class="row-container">
|
|
<mat-checkbox [formField]="form.lockedOut">Is Locked Out?</mat-checkbox>
|
|
</div>
|
|
<mat-divider></mat-divider>
|
|
<div>
|
|
@for (r of form.roles; track r.id().value() || i; let i = $index) {
|
|
<div class="row-container">
|
|
<mat-checkbox [formField]="r.enabled" class="flex-auto">{{ r.name().value() }}</mat-checkbox>
|
|
</div>
|
|
}
|
|
</div>
|
|
</form>
|
|
|
|
<div class="row-container">
|
|
<button type="button" mat-raised-button color="primary" class="" (click)="save()">Save</button>
|
|
<button type="button" mat-raised-button color="warn" (click)="confirmDelete()">Delete</button>
|
|
</div>
|
|
}
|