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

Popover autoClose not dynamic #4680

Open
tjw02 opened this issue Mar 4, 2024 · 4 comments · May be fixed by #4695
Open

Popover autoClose not dynamic #4680

tjw02 opened this issue Mar 4, 2024 · 4 comments · May be fixed by #4695

Comments

@tjw02
Copy link

tjw02 commented Mar 4, 2024

Please remember, the issues forum is NOT for support requests. It is for bugs and feature requests only.
Please read https://github.com/ng-bootstrap/ng-bootstrap/blob/master/CONTRIBUTING.md and search
existing issues (both open and closed) prior to opening any new issue and ensure you follow the instructions therein.

Bug description:

Hi,

We have a need for the popover to have a dynamically working autoClose property. Currently looking at the ngbootstrap, the autoClose value is being used only during the opening of the popover. However, we have the use case where some action means that the popover can temporarily not be closed for the popover that is currently being displayed. An example use case is if some action inside the popover triggers a server call, and we want to keep the popover open with a small spinner in the corner until the server response is returned.

Cheers,
Tom.

Link to minimally-working StackBlitz that reproduces the issue:

You can fork a StackBlitz from one of our demos and use it as a starting point.

Please note that we can not act on bug reports without a minimal reproduction scenario in a StackBlitz. Here is why:
https://github.com/ng-bootstrap/ng-bootstrap#you-think-youve-found-a-bug

Versions of Angular, ng-bootstrap and Bootstrap:

Angular:
17.2
ng-bootstrap:
16.0
Bootstrap:
5.3

@janwidmer-work
Copy link

See comment here #4683

@shyamal890
Copy link

@janwidmer-work I think your issue and corresponding solution shared doesn't really address the problem noted here.

Please checkout this stackblitz example - Link

Even after updating the auto_close setting the popover doesn't dynamically update how it should work

shyamal890 added a commit to shyamal890/ng-bootstrap that referenced this issue May 10, 2024
@shyamal890 shyamal890 linked a pull request May 10, 2024 that will close this issue
5 tasks
@janwidmer
Copy link

@shyamal890 It seems to work, but you need to close the popover once after clicking on the button "Toggle AutoClose" in the case it was open, when you clicked "Toggle AutoClose"

@shyamal890
Copy link

Yes, I agree but that's the point once the popover is opened and if I change auto_close it should update how popover works. This shouldn't require closing and opening the popover again. I have already pushed a PR that solves this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants