<div>
	<form [formGroup]="editForm!" (ngSubmit)="onSubmitClick()">
		<ng-template #dialogActions>
			<button type="button" mat-flat-button class="dialog-btn-cancel" (click)="closeDialog()">Cancel</button>
			<button type="submit" class="btn-space" mat-raised-button color="primary">Save</button>
		</ng-template>

		<app-dialog-chrome title="Edit motion" [errorMessage]="errorMessage" [actions]="dialogActions">
			<div class="row">
				<div class="col-md-6">
					<div class="text-inside">
						<mat-form-field class="example-full-width">
							<mat-label>Name</mat-label>
							<input matInput value={{item.name}} formControlName="name" readonly>
						</mat-form-field>
					</div>
				</div>
				<div class="col-md-6">
					<div class="text-inside">
						<mat-form-field class="example-full-width">
							<mat-label>Category</mat-label>
							<mat-select formControlName="category">
								<mat-option *ngFor="let category of categories" [value]="category.id">
									{{category.name}}
								</mat-option>
							</mat-select>
						</mat-form-field>
					</div>
				</div>
			</div>
		</app-dialog-chrome>
	</form>
</div>
