Hi,
I'm using Metronic 8.1.6. on ASP.NET MVC web app (not Core!). I'm trying to implement tooltip on help button on page like in index.html in demo 1.
What js/css I should include beside mandatory js?
Kind Regards,
Valentin
Hi Valentin Faganel,
For tooltips you just need to include two mandatory js files listed below.
"plugins/global/plugins.bundle.js",
"js/scripts.bundle.js"
Hi,
I have those js's included already. It must be something else to blame.
Regards,
Valentin
Hi,
We are initializing tooltips inside src/js/components/app.js which should already be included inside scripts.bundle.js, if tooltips still don't work you need to make sure that KTApp.init function is triggered, if not you can trigger it manually from your code.
I would suggest you make sure that you are using tooltips correctly. Your tooltip toggle element should have data-bs-toggle
, data-bs-placement
and title
.
Here is an example:
<button type="button" class="btn btn-secondary" data-bs-toggle="tooltip" data-bs-placement="top" title="Tooltip on top">
Tooltip on top
</button>
Hi,
Here is my code in partial view, which i'm using to toggle help on editing text in my app:
Hi,
Can you try to call KTApp.init()
inside 500ms delay?
setTimeout(()=>{
KTApp.init()
}, 500)
Hi,
I found solution in removing data-kt-initialized="1" from button.
I tried your code and it worked right away. So I compared it with mine and found my error.
Thanks for your help!
Best Wishes,
Valentin
Hi Valentin Faganel,
Glad to hear that. All the best to your project!
Regards,
Lauris Stepanovs,
Keenthemes Support Team