1 <cd-modal [modalRef]="bsModalRef">
2 <ng-container class="modal-title"
3 i18n>Matcher</ng-container>
5 <ng-container class="modal-content">
10 <div class="modal-body">
12 <div class="form-group row">
13 <label class="cd-col-form-label required"
16 <div class="cd-col-form-input">
17 <select class="form-control"
19 formControlName="name"
21 <option [ngValue]="null"
22 i18n>-- Select an attribute to match against --</option>
23 <option *ngFor="let attribute of nameAttributes"
28 <span class="help-block"
29 *ngIf="form.showError('name', formDir, 'required')"
30 i18n>This field is required!</span>
35 <div class="form-group row">
36 <label class="cd-col-form-label required"
39 <div class="cd-col-form-input">
43 [ngbTypeahead]="search"
44 formControlName="value">
45 <span *ngIf="form.showError('value', formDir, 'required')"
47 i18n>This field is required!</span>
49 <div *ngIf="form.getValue('value') && !form.getValue('isRegex') && matcherMatch"
50 class="cd-col-form-offset {{matcherMatch.cssClass}}"
52 <span class="text-muted {{matcherMatch.cssClass}}">
53 {{matcherMatch.status}}
59 <div class="form-group row">
60 <div class="cd-col-form-offset">
61 <div class="custom-control custom-checkbox">
62 <input type="checkbox"
63 class="custom-control-input"
64 formControlName="isRegex"
68 class="custom-control-label"
69 i18n>Use regular expression</label>
75 <div class="modal-footer">
76 <cd-submit-button (submitAction)="onSubmit()"
78 <ng-container i18n>{editMode, select, 1 {Update} other {Add}}</ng-container>
80 <cd-back-button [back]="bsModalRef.hide"