14 lines
418 B
Plaintext
Raw Normal View History

2017-07-07 00:37:43 +00:00
component Statistics(screenSizes []*utils.PieChartSlice)
2017-07-07 00:07:34 +00:00
h1 Statistics
.statistics
h3 Screen size
2017-07-07 00:37:43 +00:00
PieChart(screenSizes)
2017-07-07 00:07:34 +00:00
//- canvas#screen-sizes.graph(data-values=utils.ToJSON(screenSizes))
2017-07-07 00:37:43 +00:00
component PieChart(slices []*utils.PieChartSlice)
2017-07-07 00:07:34 +00:00
svg.graph(viewBox="-1.05 -1.05 2.1 2.1")
2017-07-07 00:37:43 +00:00
each slice in slices
g
title= slice.Title
path.slice(d=utils.SVGSlicePath(slice.From, slice.To), fill=slice.Color)