Questions tagged [angular-ngselect]

Use this tag for the select component native to Angular that accepts multi-select and auto-complete options.

Select component native to Angular that accepts multi-select and auto-complete options

Repository: Github

369 questions
3
votes
1 answer

Ng-Select - Select/Unselect all items in custom component using the ControlValueAccessor interface

I'm trying to wrap all the configuration needed to setup a multiselect(using checkboxes for each option) combo using ng-select and the controlValueAccessor interface. So far it kinda works, except that if I choose to select or unselect all of the…
eddy
  • 4,373
  • 16
  • 60
  • 94
3
votes
3 answers

How to create ng-select with items in reactive forms

I searched a lot on different web portals on this, but still I didn't get any success. How we can create ng-select in reactive forms.I want to create following html tag with in reactive form. Following code snippet is taken from formGroup. HTML: …
Sunny
  • 3,185
  • 8
  • 34
  • 66
3
votes
1 answer

How to Avoid Cypress Flakiness Using Ng-Select Elements

We are using Cypress E2E testing framework on an Ionic 5 / Angular 9 project. Our tests mostly work as expected when running in the Cypress Test Runner GUI. However, when running in CLI-mode we get a lot of flakiness (i.e. not always, but certainly…
3
votes
1 answer

Angular ng-select - bindValue don't work and still binds to whole object

I have a problem with ng-select (I am using newest version and Angular 10). I am creating a common component called form-row-select-multiple, which I will be using in many other components. Here is shortened TS file of this component: @Input()…
microHoffman
  • 134
  • 1
  • 3
  • 12
3
votes
1 answer

ng select style group headers and items

I am using ng-select (https://ng-select.github.io/ng-select#/data-sources) library in my angular project to display a drop down as follows:
Karu
  • 935
  • 2
  • 13
  • 32
3
votes
3 answers

How to change the style of an ng-select control when an option is selected

I need to use the component ng-select , but when I select an option in the control I got this blue outline in the select component : I need to customize this to match the style in my other components. I tried changing the outline property in the…
eddy
  • 4,373
  • 16
  • 60
  • 94
3
votes
2 answers

why is ng-select type ahead causing performance issues?

I am using ng-select with type-ahead filtering of items in the select list. When you type to filter the results for the first item in the list, the performance is lightning fast. After you select that first item, however, everything becomes…
208_man
  • 1,440
  • 3
  • 28
  • 59
3
votes
1 answer

How to trigger keydown events on Ng Select DropDown - Get ng select panel in code behind

I am using ng select: https://www.npmjs.com/package/@ng-select/ng-select StackBlitz: https://stackblitz.com/edit/angular-rvo39c?file=src%2Fforms-with-options-example.component.ts I want to be able to highlight an object in the Listbox with arrows…
SirLanceLang
  • 45
  • 1
  • 1
  • 4
3
votes
0 answers

Console error : No value accessor for form controll with name:

I have added ng-select in my project for multiselect-searchable-grouping dropdown. I have followed the steps from https://ng-select.github.io/ng-select#/grouping, but unfortunately getting: ERROR Error: No value accessor for form control with name:…
3
votes
1 answer

Added ng-select reactive form validation messages not showing

I added an error message to ng-select component to show error messages when it's dirty and value not selected. But the error message is not showing. But the validation is working. https://ng-select.github.io/ng-select/
camille
  • 278
  • 1
  • 2
  • 20
3
votes
1 answer

How to get Selected Text and Selected Value of an ngSelect dropdown in angular 6

When form is posted, I want to get selected item Name and Value both of an ngSelect dropdown in angular 6. I have tried getting it with ngModel and with templateVariable, but Selected Name is not returned, I only managed to get Selected…
3
votes
1 answer

Cannot set selected item value using ngModel in angular7 ng-select

I am using angular7 ng-select library to implement a select control. I am using Angular CLI for development. I am trying to prevent event propagation when a change event is triggered. I found out that the change event propagation cannot be prevented…
3
votes
1 answer

How to insert values in Observable type of array in ng-select

I am using ng-select and specifically using typeahead to fetch the list from the server as user types. Following example as described in typeahead example : people3$. My requirement is to add value when user clicks a button (I have id and label and…
Mohd. Monis
  • 199
  • 4
  • 18
3
votes
1 answer

Avoid & in ng-select drop down in angular 7

I am using the ng-select drop-down list. If I use ng-option then if it gets "&" it adds "amp;" with "&". But if I only use ng-select it works perfectly. I can not use any directives to replace value because in the background the value does not…
Sabbir
  • 327
  • 5
  • 14
3
votes
2 answers

make ng-select width adjust to selected items / available options?

I'm using ng-select in an Ionic3 / Angular5 project and I'm using its multiple selection configuration. The presentation of the select input is always considerably wider than it needs to be to contain the selected items or any of the available…
vicatcu
  • 5,407
  • 7
  • 41
  • 65