github.com/google/syzkaller@v0.0.0-20251211124644-a066d2bc4b02/pkg/html/pages/stats.html (about)

     1  {{/*
     2  Copyright 2024 syzkaller project authors. All rights reserved.
     3  Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
     4  */}}
     5  
     6  <script type="text/javascript" src="https://www.google.com/jsapi"></script>
     7  <script type="text/javascript">
     8  	google.load("visualization", "1", {packages:["corechart"]});
     9  	google.setOnLoadCallback(function() {
    10  		{{range $g := .}}
    11  		new google.visualization. {{if $g.Stacked}} AreaChart {{else}} LineChart {{end}} (
    12  			document.getElementById('div_{{$g.ID}}')).
    13  			draw(google.visualization.arrayToDataTable([
    14  				["-" {{range $line := $g.Lines}} , '{{$line}}' {{end}}],
    15  				{{range $p := $g.Points}} [ {{$p.X}} {{range $y := $p.Y}} , {{$y}} {{end}} ], {{end}}
    16  			]), {
    17  				title: '{{$g.Title}}',
    18  				titlePosition: 'in',
    19  				width: "95%",
    20  				height: "400",
    21  				chartArea: {width: '95%', height: '85%'},
    22  				legend: {position: 'in'},
    23  				lineWidth: 2,
    24  				focusTarget: "category",
    25  				{{if $g.Stacked}} isStacked: true, {{end}}
    26  				vAxis: {minValue: 1, textPosition: 'in', gridlines: {multiple: 1}, minorGridlines: {multiple: 1}},
    27  				hAxis: {minValue: 1, textPosition: 'out', maxAlternation: 1, gridlines: {multiple: 1},
    28  					minorGridlines: {multiple: 1}},
    29  			})
    30  		{{end}}
    31  
    32  		{{/* Preserve vertical scroll position after page reloads. Otherwise it's random. */}}
    33  		window.scroll(0, window.location.hash.substring(1));
    34  		document.onscroll = function(e) { window.location.hash = Math.round(window.scrollY); };
    35  	});
    36  </script>
    37  
    38  {{range $g := .}}
    39  	<div id="div_{{$g.ID}}"></div>
    40  {{end}}