Answer the question
In order to leave comments, you need to log in
How to make Popover in Bootstrap not retract on hover?
Greetings!
Tell me how to make a tooltip that would not be removed when hovering over it using Bootstrap Popover?
As an option, hang the tooltip on focus, when mouseover triggers focus, and when mouseout is on the tooltip, remove focus from the element, but it sounds like a crutch. There must be an adequate way .. Or not?
const popoverTriggerNodeList = document.querySelectorAll(
'[data-bs-toggle="popover"]'
);
popoverTriggerNodeList.forEach(
(popoverTriggerEl) =>
new Popover(popoverTriggerEl, {
container: popoverTriggerEl,
html: true,
trigger: "hover"
})
);
<button data-bs-toggle="popover"
data-trigger="hover focus"
title="Popover title"
data-bs-content="And here's some amazing content. It's very engaging. Right?">
Подробнее
</button>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question