init commit

This commit is contained in:
Gundersen 2022-02-28 13:49:43 -06:00
commit 5b7c7d4d19
25 changed files with 8503 additions and 0 deletions

View file

@ -0,0 +1,38 @@
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
@Component({
selector: 'app-radio',
template: `
<div class="radio">
<div *ngFor="let choice of field.options.choices">
<input type="radio" name="field.id" class="choice"
[value]="choice"
[(ngModel)]="field.value"
(ngModelChange)="check()"
/>
<label>{{ choice }}</label>
</div>
</div>
`
})
export class RadioComponent implements OnInit {
@Input() field: Field;
@Output() update: EventEmitter<null> = new EventEmitter();
ngOnInit() { console.log("Text", this.field.id); }
check() {
this.field.ok = true;
this.update.emit();
}
}