oferh / ng2-completer

Angular 2 autocomplete component
http://oferh.github.io/ng2-completer/
MIT License
347 stars 172 forks source link

click out of the input #349

Closed andrejm7 closed 7 years ago

andrejm7 commented 7 years ago

When searching for the name underneath it is 'No results'. If you click the mouse anywhere else, the name is not filled.

Check the image. Input when selecting and after clicking out of the input.

Is it bug? ng2-complete

detail .. I'm using it this way because I need to concatenate the name and surname this.dataServicePaciente = this.completerService.local(this.pacientes, 'name,surname', 'name,surname');

oferh commented 7 years ago

is the initial data the combination of name and surname?

andrejm7 commented 7 years ago

the field is empty and I type the initials but with a click outside the field the ng2-completer only fills in what I typed.

oferh commented 7 years ago

when is no results displayed?

andrejm7 commented 7 years ago

when typing Albe .. and the input behind Alberto .. but when I click outside the input the field is filled with only 'Albe'

See the picture at the opening of the case

andrejm7 commented 7 years ago

The error is similar to that reported in # 320

oferh commented 7 years ago

can you provide the HTML that your'e using for ng2-completer?

andrejm7 commented 7 years ago

Sure...

<ng2-completer [inputClass]="['form-control']" [inputName]="'paciente'" name='paciente' [inputId]="'paciente'" [(ngModel)]="agenda.paciente" #paciente="ngModel" [datasource]="dataServicePaciente" [minSearchLength]="3" [textNoResults]="'Não há resultados' [textSearching]="'Buscando...'">

oferh commented 7 years ago

can you try with fillHighlighted="false"

andrejm7 commented 7 years ago

Good man thanks