Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide empty optgroup #606

Closed
williangd opened this issue Jun 8, 2018 · 1 comment · Fixed by #613
Closed

Hide empty optgroup #606

williangd opened this issue Jun 8, 2018 · 1 comment · Fixed by #613
Assignees
Labels

Comments

@williangd
Copy link

I'm using hideSelected to hide selected options. Is it possible to hide the optgroup when all the options are hidden?

@anjmao
Copy link
Member

anjmao commented Jun 8, 2018

Hi @williangd, it is not supported yet, some logic is missing here https://github.com/ng-select/ng-select/blob/master/src/ng-select/items-list.ts#L74. It removes only current item from dropdown and doesn't check if parent has more child items.

@anjmao anjmao added the bug label Jun 8, 2018
@anjmao anjmao self-assigned this Jun 8, 2018
anjmao added a commit that referenced this issue Jun 21, 2018
jakemdunn pushed a commit to jakemdunn/ng-select that referenced this issue Oct 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants