in frontend/frontend-flutter/lib/screens/bot.dart [1052:1087]
Widget getGoogleTable(dynamic dataViz) {
print("bot: getGoogleTable() : START");
if (dataViz!["chart_div_1"]! != null) {
print(
'bot: getGoogleTable() : dataViz!["chart_div_1"]! = ${dataViz!["chart_div_1"]!}');
String htmlPre = """<html>
<head>
<!--Load the AJAX API-->
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
<script type="text/javascript"> """;
String htmlPost = """</script>
</head>
<body>
<!--Div that will hold the pie chart-->
<div id="chart_div_1"></div>
</body>
</html>""";
return Container(
child: InAppWebView(
initialData: InAppWebViewInitialData(
data:
htmlPre + "\n" + dataViz!["chart_div_1"]!.replaceAll('width: 600,','width: 1200,').replaceAll('height: 300,', 'height: 600,') + htmlPost + "\n"),
onWebViewCreated: (controller) {
webViewController = controller;
},
),
);
} else
return Text("No data",
style: TextStyle(
fontSize: 16,
color: Colors.indigoAccent,
fontWeight: FontWeight.bold));
}