-
Notifications
You must be signed in to change notification settings - Fork 49
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
Store a reference to the tooltip/popover on insert #766
Conversation
…t we can more reliably use it to restore when hidden
); | ||
} | ||
const body = tip.querySelector(".popover-body"); | ||
const el = this.bsPopoverEl; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we unset this element at some point? Or do we just update it when a new popover is inserted?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yes, good point. Addressed in cc0ac46
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm still left with the general feeling that the references we should track in the class instance should be to elements that we control, i.e. the popover body and title. But I also understand that this may be a quicker and easier way to solve the current bug. I'm happy if we just make a note to think about this again if we end up in this area again.
Yea, I had another quick look into this. That approach would definitely simplify some logic and make it more robust to changes to Bootstrap. The downside though is that, if we don't reach into the tooltip/popover element (to return the contents to their rightful place), then we'd open ourselves up to restoring "stale" content, which is a problem for popovers especially |
c0b95a9
to
cc0ac46
Compare
Closes #765