Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(290)

Side by Side Diff: packages/charted/examples/charts/demo_charts.dart

Issue 2213693002: Updated charted DEP to 0.4.X (Closed) Base URL: https://github.com/dart-lang/observatory_pub_packages.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 library charted.demo.charts; 1 library charted.demo.charts;
2 2
3 import "package:charted/charts/charts.dart"; 3 import "package:charted/charts/charts.dart";
4 4
5 /// Helper method to create default behaviors for cartesian chart demos. 5 /// Helper method to create default behaviors for cartesian chart demos.
6 Iterable<ChartBehavior> createDefaultCartesianBehaviors() => 6 List<ChartBehavior> createDefaultCartesianBehaviors() =>
7 new List.from([ 7 new List.from([
8 new Hovercard(isMultiValue: true), 8 new Hovercard(isMultiValue: true),
9 new AxisLabelTooltip() 9 new AxisLabelTooltip()
10 ]); 10 ]);
11 11
12 /// Helper method to create default behaviors for layout chart demos. 12 /// Helper method to create default behaviors for layout chart demos.
13 Iterable<ChartBehavior> createDefaultLayoutBehaviors() => 13 List<ChartBehavior> createDefaultLayoutBehaviors() =>
14 new List.from([new ChartTooltip()]); 14 new List.from([new ChartTooltip()]);
15 15
16 /// Sample columns used by demos with quantitative dimension scale 16 /// Sample columns used by demos with quantitative dimension scale
17 Iterable ORDINAL_DATA_COLUMNS = [ 17 List<ChartColumnSpec> ORDINAL_DATA_COLUMNS = <ChartColumnSpec>[
18 new ChartColumnSpec(label: 'Month', type: ChartColumnSpec.TYPE_STRING), 18 new ChartColumnSpec(label: 'Month', type: ChartColumnSpec.TYPE_STRING),
19 new ChartColumnSpec(label: 'Grains'), 19 new ChartColumnSpec(label: 'Grains'),
20 new ChartColumnSpec(label: 'Fruits'), 20 new ChartColumnSpec(label: 'Fruits'),
21 new ChartColumnSpec(label: 'Vegetables') 21 new ChartColumnSpec(label: 'Vegetables')
22 ]; 22 ];
23 23
24 /// Sample values used by demos with quantitative dimension scale 24 /// Sample values used by demos with quantitative dimension scale
25 Iterable ORDINAL_DATA = const [ 25 List<List> ORDINAL_DATA = const <List>[
26 const ['January', 4.50, 7, 6], 26 const ['January', 4.50, 7, 6],
27 const ['February', 5.61, 16, 8], 27 const ['February', 5.61, 16, 8],
28 const ['March', 8.26, 36, 9], 28 const ['March', 8.26, 36, 9],
29 const ['April', 15.46, 63, 49], 29 const ['April', 15.46, 63, 49],
30 const ['May', 18.50, 77, 46], 30 const ['May', 18.50, 77, 46],
31 const ['June', 14.61, 60, 8], 31 const ['June', 14.61, 60, 8],
32 const ['July', 3.26, 9, 6], 32 const ['July', 3.26, 9, 6],
33 const ['August', 1.46, 9, 3], 33 const ['August', 1.46, 9, 3],
34 const ['September', 1.46, 13, 9], 34 const ['September', 1.46, 13, 9],
35 const ['October', 2.46, 29, 3], 35 const ['October', 2.46, 29, 3],
36 const ['November', 4.46, 33, 9], 36 const ['November', 4.46, 33, 9],
37 const ['December', 8.46, 19, 3] 37 const ['December', 8.46, 19, 3]
38 ]; 38 ];
39 39
40 /// Sample values used by RTL demos with quantitative dimension scale 40 /// Sample values used by RTL demos with quantitative dimension scale
41 Iterable ORDINAL_DATA_RTL = const [ 41 List<List> ORDINAL_DATA_RTL = const <List>[
42 const ['كانون الثاني', 4.50, 7, 6], 42 const ['كانون الثاني', 4.50, 7, 6],
43 const ['شباط', 5.61, 16, 8], 43 const ['شباط', 5.61, 16, 8],
44 const ['آذار', 8.26, 36, 9], 44 const ['آذار', 8.26, 36, 9],
45 const ['نيسان', 15.46, 63, 49], 45 const ['نيسان', 15.46, 63, 49],
46 const ['أيار', 18.50, 77, 46], 46 const ['أيار', 18.50, 77, 46],
47 const ['حزيران', 14.61, 60, 8], 47 const ['حزيران', 14.61, 60, 8],
48 const ['تموز', 3.26, 9, 6], 48 const ['تموز', 3.26, 9, 6],
49 const ['آب', 1.46, 9, 3], 49 const ['آب', 1.46, 9, 3],
50 const ['أيلول', 1.46, 13, 9], 50 const ['أيلول', 1.46, 13, 9],
51 const ['تشرين الأول', 2.46, 29, 3], 51 const ['تشرين الأول', 2.46, 29, 3],
52 const ['تشرين الثاني', 4.46, 33, 9], 52 const ['تشرين الثاني', 4.46, 33, 9],
53 const ['كانون الأول', 8.46, 19, 3] 53 const ['كانون الأول', 8.46, 19, 3]
54 ]; 54 ];
55 55
56 Iterable ORDINAL_DATA_WITH_NEGATIVE = const [ 56 List<List> ORDINAL_DATA_WITH_NEGATIVE = const <List>[
57 const ['January', 4.50, -7, 6], 57 const ['January', 4.50, -7, 6],
58 const ['February', 5.61, -16, 8], 58 const ['February', 5.61, -16, 8],
59 const ['March', 8.26, 36, 9], 59 const ['March', 8.26, 36, 9],
60 const ['April', 15.46, 63, 49], 60 const ['April', 15.46, 63, 49],
61 const ['May', 18.50, 77, -46], 61 const ['May', 18.50, 77, -46],
62 const ['June', 14.61, 60, 8], 62 const ['June', 14.61, 60, 8],
63 const ['July', 3.26, 9, 6], 63 const ['July', 3.26, 9, 6],
64 const ['August', 1.46, 9, 3], 64 const ['August', 1.46, 9, 3],
65 const ['September', 1.46, 13, 9], 65 const ['September', 1.46, 13, 9],
66 const ['October', 2.46, 29, 3], 66 const ['October', 2.46, 29, 3],
67 const ['November', 4.46, 33, 9], 67 const ['November', 4.46, 33, 9],
68 const ['December', 8.46, 19, 3] 68 const ['December', 8.46, 19, 3]
69 ]; 69 ];
70 70
71 Iterable ORDINAL_DATA_WITH_BREAKS = const [ 71 List<List> ORDINAL_DATA_WITH_BREAKS = const <List>[
72 const ['January', 4.50, -7, 6], 72 const ['January', 4.50, -7, 6],
73 const ['February', 5.61, -16, 8], 73 const ['February', 5.61, -16, 8],
74 const ['March', 8.26, 36, 9], 74 const ['March', 8.26, 36, 9],
75 const ['April', null, null, null], 75 const ['April', null, null, null],
76 const ['May', null, null, null], 76 const ['May', null, null, null],
77 const ['June', 14.61, 60, 8], 77 const ['June', 14.61, 60, 8],
78 const ['July', 3.26, 9, 6], 78 const ['July', 3.26, 9, 6],
79 const ['August', 1.46, 9, 3], 79 const ['August', 1.46, 9, 3],
80 const ['September', 1.46, 13, 9], 80 const ['September', 1.46, 13, 9],
81 const ['October', null, null, null], 81 const ['October', null, null, null],
82 const ['November', 4.46, 33, 9], 82 const ['November', 4.46, 33, 9],
83 const ['December', 8.46, 19, 3] 83 const ['December', 8.46, 19, 3]
84 ]; 84 ];
85 85
86 /// Sample columns used by demos with quantitative dimension scale 86 /// Sample columns used by demos with quantitative dimension scale
87 Iterable TIMESERIES_DATA_COLUMNS = [ 87 List<ChartColumnSpec> TIMESERIES_DATA_COLUMNS = <ChartColumnSpec>[
88 new ChartColumnSpec(label: 'Time', type: ChartColumnSpec.TYPE_TIMESTAMP), 88 new ChartColumnSpec(label: 'Time', type: ChartColumnSpec.TYPE_TIMESTAMP),
89 new ChartColumnSpec(label: 'New York'), 89 new ChartColumnSpec(label: 'New York'),
90 new ChartColumnSpec(label: 'San Fransisco'), 90 new ChartColumnSpec(label: 'San Fransisco'),
91 new ChartColumnSpec(label: 'Austin') 91 new ChartColumnSpec(label: 'Austin')
92 ]; 92 ];
93 93
94 Iterable TIMESERIES_DATA = const [ 94 List<List<num>> TIMESERIES_DATA = const <List<num>>[
95 const [1317452400000, 63.4, 62.7, 72.2], 95 const [1317452400000, 63.4, 62.7, 72.2],
96 const [1317538800000, 58.0, 59.9, 67.7], 96 const [1317538800000, 58.0, 59.9, 67.7],
97 const [1317625200000, 53.3, 59.1, 69.4], 97 const [1317625200000, 53.3, 59.1, 69.4],
98 const [1317711600000, 55.7, 58.8, 68.0], 98 const [1317711600000, 55.7, 58.8, 68.0],
99 const [1317798000000, 64.2, 58.7, 72.4], 99 const [1317798000000, 64.2, 58.7, 72.4],
100 const [1317884400000, 58.8, 57.0, 77.0], 100 const [1317884400000, 58.8, 57.0, 77.0],
101 const [1317970800000, 57.9, 56.7, 82.3], 101 const [1317970800000, 57.9, 56.7, 82.3],
102 const [1318057200000, 61.8, 56.8, 78.9], 102 const [1318057200000, 61.8, 56.8, 78.9],
103 const [1318143600000, 69.3, 56.7, 68.8], 103 const [1318143600000, 69.3, 56.7, 68.8],
104 const [1318230000000, 71.2, 60.1, 68.7], 104 const [1318230000000, 71.2, 60.1, 68.7],
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after
453 const [1348383600000, 65.7, 52.8, 75.6], 453 const [1348383600000, 65.7, 52.8, 75.6],
454 const [1348470000000, 60.4, 54.5, 78.3], 454 const [1348470000000, 60.4, 54.5, 78.3],
455 const [1348556400000, 63.2, 53.3, 78.3], 455 const [1348556400000, 63.2, 53.3, 78.3],
456 const [1348642800000, 68.5, 53.6, 79.6], 456 const [1348642800000, 68.5, 53.6, 79.6],
457 const [1348729200000, 69.2, 52.1, 76.4], 457 const [1348729200000, 69.2, 52.1, 76.4],
458 const [1348815600000, 68.7, 52.6, 77.2], 458 const [1348815600000, 68.7, 52.6, 77.2],
459 const [1348902000000, 62.5, 53.9, 75.2], 459 const [1348902000000, 62.5, 53.9, 75.2],
460 const [1348988400000, 62.3, 55.1, 71.9] 460 const [1348988400000, 62.3, 55.1, 71.9]
461 ]; 461 ];
462 462
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698