LP1811288 Combobox support entrylist+async / id labels
[working/Evergreen.git] / Open-ILS / src / eg2 / src / app / share / combobox / combobox.component.html
1
2 <!-- todo disabled -->
3 <ng-template #displayTemplate let-r="result">
4 {{r.label || r.id}}
5 </ng-template>
6
7 <div class="d-flex">
8   <input type="text" 
9     class="form-control"
10     [ngClass]="{'text-success font-italic font-weight-bold': selected && selected.freetext}"
11     [placeholder]="placeholder"
12     [name]="name"
13     [disabled]="isDisabled"
14     [required]="isRequired"
15     [(ngModel)]="selected" 
16     [ngbTypeahead]="filter"
17     [resultTemplate]="displayTemplate"
18     [inputFormatter]="formatDisplayString"
19     (click)="click$.next($event.target.value)"
20     (blur)="onBlur()"
21     (selectItem)="selectorChanged($event)"
22     #instance="ngbTypeahead"/>
23   <div class="d-flex flex-column icons" (click)="openMe($event)">
24     <span class="material-icons">keyboard_arrow_up</span>
25     <span class="material-icons">keyboard_arrow_down</span>
26   </div>
27 </div>