Is there any way to show/hide (open/close) google chart tooltip programatically? My tooltip is html enabled, trigger by 'selection'. I am trying to add a close icon to the tooltip.
You can show it using setSelection()
method, for example:
var options = {
....
tooltip: { trigger: 'selection' }
...
}
chart.setSelection([{row:0, column:1}]);
See example at jsbin.
And hide it using empty object:
chart.setSelection([{}]);
See example at jsbin.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With