tooltop.js problem when another tooltip is initialize
See original GitHub issueThis happen when another tooltip is setup after the previous tooltip is setup.
Problem at tooltip.js#L16
The previous container of the tooltip is remove after the second tooltip is setup.
<a id="tp1" class="btn tooltipped col s4 offset-s4 l2 offset-l1" data-position="bottom" data-delay="50" data-tooltip="I'm TP1!">TP1</a>
<a id="tp2" class="btn tooltipped col s4 offset-s4 l2 offset-l1" data-position="bottom" data-delay="50" data-tooltip="Goodbye TP1!">TP2</a>
<script>
$(document).on("click", "#tp1", function(){
if (!$("#tp2").is(".ok")){
$("#tp2").addClass("ok").tooltip();
};
});
$("#tp1").tooltip();
</script>
Check this https://jsfiddle.net/8wxa2pym/
Issue Analytics
- State:
- Created 8 years ago
- Comments:10 (3 by maintainers)
Top Results From Across the Web
why bootstrap tool-tip is not initializing two times?
Therefore when you called tooltip a second time it would not initialize the tooltip again. Because of the following line:
Read more >Bootstrap Tooltip Plugin - W3Schools
The Tooltip plugin is small pop-up box that appears when the user moves the mouse ... Note: Tooltips must be initialized with jQuery:...
Read more >JavaScript - Bootstrap
For performance reasons, the Tooltip and Popover data-apis are opt-in, meaning you must initialize them yourself. One way to initialize all tooltips on...
Read more >Tooltip Widget - jQuery UI API Documentation
As a result, jQuery UI does not guarantee any level of support for tooltips attached to disabled elements. Unfortunately, this means that if...
Read more >How to initialize Bootstrap tooltip in JavaScript not jquery in ...
Currently I am using Vue/Nuxt.js and I am trying to initiate a Bootstrap tooltip using java script. I am aware it can be...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
There is simple solution for this for the time being till they fix it I use this
I tested the fiddle example with the latest version and it worked, please reopen if you are still having the problem