You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've a case where user input is used as tooltip. In the end I needed to overwrite the getTooltipContent function and changed return content to return escapeHTML(content) (escapeHTML exists already in my case). Would be nice if a simple option could be added.
The text was updated successfully, but these errors were encountered:
Due to variations in the HTML parsers in different browsers, the text returned may vary in newlines and other white space.
So I think that any HTML entities logic would be outside the scope of a humble little tooltip plugin.
However, it might make sense to provide an option to use .text() instead of .html() like it is doing today. I'm not sure how best to surface that option though.
Probably a simple event/jhook in the getTooltipContent function? That way it'd be possible to easily modify the acctual content of the tooltip (eg escaping it, but also change other things).
I've a case where user input is used as tooltip. In the end I needed to overwrite the
getTooltipContent
function and changedreturn content
toreturn escapeHTML(content)
(escapeHTML
exists already in my case). Would be nice if a simple option could be added.The text was updated successfully, but these errors were encountered: