I wanted to know if you can modify the attributes of a charts
of Google with a Jquery.
Example:
google.load("visualization", "1", {packages:["corechart"]});
google.setOnLoadCallback(drawChart);
function drawChart() {
var data = google.visualization.arrayToDataTable([
['Task', 'Hours per Day'],
['Work', 11],
['Eat', 2],
['Commute', 2],
['Watch TV', 2],
['Sleep', 7]
]);
var options = {
title: 'teste',
pieHole: 0.4,
};
var chart = new google.visualization.PieChart(document.getElementById('donutchart'));
chart.draw(data, options);
}
$(window).resize(function() {
if( $(window).width() < 500){
Alterar aqui!!!!
}
});
I wanted to change title there in var options
for example.