Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

Popover doesn't show on load #5773

Closed
nadyav opened this issue Apr 10, 2016 · 5 comments
Closed

Popover doesn't show on load #5773

nadyav opened this issue Apr 10, 2016 · 5 comments

Comments

@nadyav
Copy link

nadyav commented Apr 10, 2016

The issues forum is NOT for support requests. It is for bugs and feature requests only.
Please read https://github.com/angular-ui/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:

This is a reference to the issue described on #4264 (comment). It was closed, but there is no working plunker in the thread. I was asked to create a new plunker with the latest Angular UI version, but cannot get popover working at all with Angular UI 1.3.1, so using 0.13.3, as it was in the original thread.

I'm trying to show a popover on page load only. I'm setting $scope.openPopoverOnLoad = true in the controller, and using popover-is-open="{{openPopoverOnLoad}}" in the view, so true is a boolean and not a string. Should I create a trigger in the controller as well, if I add popover-trigger="none"?

It's said on https://angular-ui.github.io/bootstrap/ ", for any non-supported value, the trigger will be used to both show and hide the popover. Using the 'none' trigger will disable the internal trigger(s), one can then use the popover-is-open attribute exclusively to show and hide the popover.", but adding popover-trigger="none" to the above code doesn't help as well. Popover just doesn't get displayed at all.

Thank you!

Link to minimally-working plunker that reproduces the issue: http://plnkr.co/edit/5fUqQ4A02eTrZ0QRd5H3

Version of Angular, UIBS, and Bootstrap

Angular: 1.4.5

UIBS: 0.13.3

Bootstrap: 3.1.1

@RobJacobs
Copy link
Contributor

Works for me in this plunk.

@nadyav
Copy link
Author

nadyav commented Apr 11, 2016

Thanks, @RobJacobs. Looks like I need to upgrade my UI Bootstrap.

@nadyav
Copy link
Author

nadyav commented Apr 11, 2016

Question to @RobJacobs - why is it uib-popover="text" vs popover="text"? I didn't see in the documentation uib-popover. Thanks.

@icfantv
Copy link
Contributor

icfantv commented Apr 11, 2016

@nadyav, because we added the uib- prefix to all of our directives back in one of the 0.14.x versions due to namespace clashes (we should have done this originally, but c'est la vie).

@sbyrx
Copy link

sbyrx commented Apr 10, 2017

I've run into a similar issue when the element with the popover attached to it is conditionally shown/hidden using ng-if.

See: http://plnkr.co/edit/f4S3iHIF7bE4riTjhDIV?p=preview

When I click the button, I would expect the <span> to appear with a popover. However, I have to click the button three times (show/hide/show) in order to get the expected behavior.

Any ideas?

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

No branches or pull requests

4 participants