1👍
If your tooltip content is displaying your html correctly, you should be able to simply add a <a>
link to it.
I don’t know how you want it to work, if for example you want to display a link in the end of your tooltip you can add, after <p> Source= ...</p>
:
<a :href="yourLink">website</a>
If you want your whole tooltip to redirect to a website you could try something like:
tooltip: {
enabled: true,
custom: function ({dataPointIndex}) {
return `<a href="yourLink"><div class="arrow-box
${
getDomainDataFromIndex(dataPointIndex).label === "low"
? "bg-yellow"
: "bg-blue"
}
">
<p> Label=
${getDomainDataFromIndex(dataPointIndex).label} credibility
</p>
<p> No of tweets=
${getDomainDataFromIndex(dataPointIndex).y}
</p>
<p> Website=
${getDomainDataFromIndex(dataPointIndex).x}
</p>
<p> Source=
${getDomainDataFromIndex(dataPointIndex).platform}
</p>
</div></a>`;
},
},
👤hnrd
- [Vuejs]-Vuetify search/filtering multiple data using checkbox cannot show the result
- [Vuejs]-How to import bootstrap or external js in Vue.js
Source:stackexchange.com