ng-select icon indicating copy to clipboard operation
ng-select copied to clipboard

Remote data while searching

Open ezzkht opened this issue 8 years ago • 5 comments

I couldn't find such an option. Is there a way to implement that while the user is typing in the search box?

ezzkht avatar Aug 28 '17 09:08 ezzkht

I'd like to help out with this issue. I needed this feature few days ago and as I did not find it already implemented so I created it in the fork. All I did is added: @Output() inputChanged = new EventEmitter<string>(); and @Input() disableClientFilter: boolean = false; in select.component.ts

these changes let's me use new event emitter in my component to query server for new options each time user input any symbol in search box.

keymatic avatar Sep 10 '17 07:09 keymatic

Additional to the noOptionsFound output event, I could add a search output event that simply returns the current search term if the filter input changes. This search term can then be used to load remote data and replace the list of options with the returned data. Would that help?

basvandenberg avatar Sep 23 '17 13:09 basvandenberg

+1 for this please

St-Bun avatar Sep 26 '17 13:09 St-Bun

I added an onFilterInputChanged output to enable retrieving data from remote server. I have also added an example of how to use it in the project app component.

fork

I will create a pull request for this. I would be appreciated if this can be included in the future release.

yang-zhang-syd avatar Nov 13 '17 03:11 yang-zhang-syd

+1

penniath avatar Feb 27 '18 10:02 penniath