import { Component, Input, Output, EventEmitter, TemplateRef, ContentChild } from '@angular/core';
import { FormGroup } from '@angular/forms';
@Component({
selector: 'app-targeting-form-array',
template: `
`,
styles: [`
.targeting-form__controls {
position: relative;
display: flex;
align-items: flex-start;
margin-bottom: 5px;
}
.targeting-form__control {
flex-grow: 2;
}
[formArrayName] {
margin-bottom: 10px;
}
app-targeting-form-add {
margin-top: 10px;
}
app-close {
position: relative;
top: 7px;
right: -5px;
}
`]
})
export class TargetingFormArrayComponent {
@Input() name: string;
@Input() single: boolean;
@Input() group: FormGroup;
@Output() add = new EventEmitter();
@Output() remove = new EventEmitter();
@ContentChild(TemplateRef) template: TemplateRef;
}