ngx-select-ex icon indicating copy to clipboard operation
ngx-select-ex copied to clipboard

blur event not working ngModel

Open m-saifuddin opened this issue 6 years ago • 1 comments

I am using below code to catch blur event.

<ngx-select  class="custom-select" [allowClear]="true" (blur)="validateTopic(EMIRATE)" (change)="validateTopic(EMIRATE)" [items]="emiratesList"  #EMIRATE="ngModel" [class.is-invalid]="topicHasError && EMIRATE.touched" name="EMIRATE" [(ngModel)]="model.EMIRATE">
                  </ngx-select>

and below code in

export class CoverComponent implements OnInit {
constructor(){ }
 validateTopic(value) {
        console.log(value);
        if (value === 'default') {
            this.topicHasError = true;
        } else {
            this.topicHasError = false;
        }
    }
}

but its not firing event.

Any help would be highly appreciated.

Thanks,

m-saifuddin avatar Nov 08 '18 08:11 m-saifuddin

@m-saifuddin Please, make a fork of https://stackblitz.com/edit/ngx-select-ex-issues-100 And reproduce the error to save my time. As soon as I will see it I'll try to fix it. Thanks!

optimistex avatar Nov 08 '18 09:11 optimistex