-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathline_chart_test.go
981 lines (958 loc) · 264 KB
/
line_chart_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
package charts
import (
"strconv"
"testing"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
func makeFullLineChartOption() LineChartOption {
values := [][]float64{
{120, 132, 101, 134, 90, 230, 210},
{220, 182, 191, 234, 290, 330, 310},
{150, 232, 201, 154, 190, 330, 410},
{320, 332, 301, 334, 390, 330, 320},
{820, 932, 901, 934, 1290, 1330, 1320},
}
return LineChartOption{
Title: TitleOption{
Text: "Line",
},
Padding: NewBoxEqual(10),
XAxis: XAxisOption{
Labels: []string{"Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"},
},
YAxis: make([]YAxisOption, 1),
Legend: LegendOption{
SeriesNames: []string{"Email", "Union Ads", "Video Ads", "Direct", "Search Engine"},
Symbol: SymbolDot,
},
SeriesList: NewSeriesListLine(values),
}
}
func makeBasicLineChartOption() LineChartOption {
values := [][]float64{
{120, 132, 101, 134, 90, 230, 210},
{820, 932, 901, 934, 1290, 1330, 1320},
}
return LineChartOption{
Title: TitleOption{
Text: "Line",
},
Padding: NewBoxEqual(10),
XAxis: XAxisOption{
Labels: []string{"A", "B", "C", "D", "E", "F", "G"},
},
YAxis: make([]YAxisOption, 1),
Legend: LegendOption{
SeriesNames: []string{"1", "2"},
Symbol: SymbolDot,
},
SeriesList: NewSeriesListLine(values),
}
}
func makeMinimalLineChartLegendOption() LineChartOption {
opt := makeMinimalLineChartOption()
opt.Legend = LegendOption{
SeriesNames: []string{"1", "2"},
}
return opt
}
func makeMinimalLineChartOption() LineChartOption {
values := [][]float64{
{120, 132, 101, 134, 90, 230, 210},
{820, 932, 901, 934, 1290, 1330, 1320},
}
return LineChartOption{
Padding: NewBoxEqual(10),
XAxis: XAxisOption{
Labels: []string{"1", "2", "3", "4", "5", "6", "7"},
Show: Ptr(false),
},
Legend: LegendOption{
Symbol: SymbolDot,
},
YAxis: make([]YAxisOption, 1),
Symbol: SymbolNone,
SeriesList: NewSeriesListLine(values),
}
}
func makeFullLineChartStackedOption() LineChartOption {
seriesList := NewSeriesListLine([][]float64{
{4.9, 23.2, 25.6, 102.6, 142.2, 32.6, 20.0, 3.3},
{9.0, 26.4, 28.7, 144.6, 122.2, 48.7, 18.8, 2.3},
{80.0, 40.4, 28.4, 28.8, 24.4, 24.2, 40.8, 80.8},
}, LineSeriesOption{
Label: SeriesLabel{
Show: Ptr(true),
},
MarkPoint: NewMarkPoint("min", "max"),
})
return LineChartOption{
Padding: NewBoxEqual(20),
SeriesList: seriesList,
StackSeries: Ptr(true),
XAxis: XAxisOption{
Labels: []string{"1", "2", "3", "4", "5", "6", "7", "8"},
BoundaryGap: Ptr(true),
},
Legend: LegendOption{
SeriesNames: []string{"A", "B", "C"},
Symbol: SymbolDot,
},
YAxis: []YAxisOption{
{
RangeValuePaddingScale: Ptr(1.0),
},
},
}
}
func TestNewLineChartOptionWithData(t *testing.T) {
t.Parallel()
opt := NewLineChartOptionWithData([][]float64{
{12, 24},
{24, 48},
})
assert.Len(t, opt.SeriesList, 2)
assert.Equal(t, ChartTypeLine, opt.SeriesList[0].getType())
assert.Len(t, opt.YAxis, 1)
assert.Equal(t, defaultPadding, opt.Padding)
p := NewPainter(PainterOptions{})
assert.NoError(t, p.LineChart(opt))
}
func TestLineChart(t *testing.T) {
t.Parallel()
tests := []struct {
name string
themed bool
makeOptions func() LineChartOption
result string
}{
{
name: "basic_themed",
themed: true,
makeOptions: makeFullLineChartOption,
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:rgb(40,40,40)\"/><path d=\"M 20 19\nL 50 19\" style=\"stroke-width:3;stroke:rgb(255,100,100);fill:none\"/><circle cx=\"35\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(255,100,100);fill:rgb(255,100,100)\"/><text x=\"52\" y=\"25\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Email</text><path d=\"M 111 19\nL 141 19\" style=\"stroke-width:3;stroke:rgb(255,210,100);fill:none\"/><circle cx=\"126\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(255,210,100);fill:rgb(255,210,100)\"/><text x=\"143\" y=\"25\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Union Ads</text><path d=\"M 234 19\nL 264 19\" style=\"stroke-width:3;stroke:rgb(100,180,210);fill:none\"/><circle cx=\"249\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(100,180,210);fill:rgb(100,180,210)\"/><text x=\"266\" y=\"25\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Video Ads</text><path d=\"M 357 19\nL 387 19\" style=\"stroke-width:3;stroke:rgb(64,160,110);fill:none\"/><circle cx=\"372\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(64,160,110);fill:rgb(64,160,110)\"/><text x=\"389\" y=\"25\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Direct</text><path d=\"M 450 19\nL 480 19\" style=\"stroke-width:3;stroke:rgb(154,100,180);fill:none\"/><circle cx=\"465\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(154,100,180);fill:rgb(154,100,180)\"/><text x=\"482\" y=\"25\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Search Engine</text><text x=\"10\" y=\"26\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"52\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"87\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"122\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"157\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"192\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"227\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"262\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"297\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"332\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"368\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 46\nL 590 46\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 81\nL 590 81\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 116\nL 590 116\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 152\nL 590 152\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 187\nL 590 187\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 222\nL 590 222\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 258\nL 590 258\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 293\nL 590 293\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 54 328\nL 590 328\" style=\"stroke-width:1;stroke:rgb(72,71,83);fill:none\"/><path d=\"M 58 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 58 369\nL 58 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 134 369\nL 134 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 210 369\nL 210 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 286 369\nL 286 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 362 369\nL 362 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 438 369\nL 438 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 514 369\nL 514 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(185,184,206);fill:none\"/><text x=\"81\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Mon</text><text x=\"159\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Tue</text><text x=\"233\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Wed</text><text x=\"311\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Thu</text><text x=\"391\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Fri</text><text x=\"465\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sat</text><text x=\"539\" y=\"390\" style=\"stroke:none;fill:rgb(238,238,238);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sun</text><path d=\"M 96 338\nL 172 335\nL 248 342\nL 324 335\nL 400 345\nL 476 314\nL 552 318\" style=\"stroke-width:2;stroke:rgb(255,100,100);fill:none\"/><circle cx=\"96\" cy=\"338\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><circle cx=\"172\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><circle cx=\"248\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><circle cx=\"324\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><circle cx=\"400\" cy=\"345\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><circle cx=\"476\" cy=\"314\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><circle cx=\"552\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,100,100);fill:rgb(40,40,40)\"/><path d=\"M 96 316\nL 172 324\nL 248 322\nL 324 313\nL 400 300\nL 476 292\nL 552 296\" style=\"stroke-width:2;stroke:rgb(255,210,100);fill:none\"/><circle cx=\"96\" cy=\"316\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><circle cx=\"172\" cy=\"324\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><circle cx=\"248\" cy=\"322\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><circle cx=\"324\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><circle cx=\"400\" cy=\"300\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><circle cx=\"476\" cy=\"292\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><circle cx=\"552\" cy=\"296\" r=\"2\" style=\"stroke-width:1;stroke:rgb(255,210,100);fill:rgb(40,40,40)\"/><path d=\"M 96 331\nL 172 313\nL 248 320\nL 324 330\nL 400 323\nL 476 292\nL 552 274\" style=\"stroke-width:2;stroke:rgb(100,180,210);fill:none\"/><circle cx=\"96\" cy=\"331\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><circle cx=\"172\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><circle cx=\"248\" cy=\"320\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><circle cx=\"324\" cy=\"330\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><circle cx=\"400\" cy=\"323\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><circle cx=\"476\" cy=\"292\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><circle cx=\"552\" cy=\"274\" r=\"2\" style=\"stroke-width:1;stroke:rgb(100,180,210);fill:rgb(40,40,40)\"/><path d=\"M 96 294\nL 172 291\nL 248 298\nL 324 291\nL 400 278\nL 476 292\nL 552 294\" style=\"stroke-width:2;stroke:rgb(64,160,110);fill:none\"/><circle cx=\"96\" cy=\"294\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><circle cx=\"172\" cy=\"291\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><circle cx=\"248\" cy=\"298\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><circle cx=\"324\" cy=\"291\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><circle cx=\"400\" cy=\"278\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><circle cx=\"476\" cy=\"292\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><circle cx=\"552\" cy=\"294\" r=\"2\" style=\"stroke-width:1;stroke:rgb(64,160,110);fill:rgb(40,40,40)\"/><path d=\"M 96 183\nL 172 159\nL 248 166\nL 324 158\nL 400 80\nL 476 71\nL 552 73\" style=\"stroke-width:2;stroke:rgb(154,100,180);fill:none\"/><circle cx=\"96\" cy=\"183\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/><circle cx=\"172\" cy=\"159\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/><circle cx=\"248\" cy=\"166\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/><circle cx=\"324\" cy=\"158\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/><circle cx=\"400\" cy=\"80\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/><circle cx=\"476\" cy=\"71\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/><circle cx=\"552\" cy=\"73\" r=\"2\" style=\"stroke-width:1;stroke:rgb(154,100,180);fill:rgb(40,40,40)\"/></svg>",
},
{
name: "boundary_gap_disable",
makeOptions: func() LineChartOption {
opt := makeFullLineChartOption()
opt.XAxis.BoundaryGap = Ptr(false)
// disable extras
opt.Title.Show = Ptr(false)
opt.Legend.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"55\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"94\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"133\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"172\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"211\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"250\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"289\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"328\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"368\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 49\nL 590 49\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 88\nL 590 88\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 128\nL 590 128\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 167\nL 590 167\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 206\nL 590 206\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 246\nL 590 246\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 285\nL 590 285\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 324\nL 590 324\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 369\nL 58 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 146 369\nL 146 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 235 369\nL 235 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 324 369\nL 324 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 412 369\nL 412 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 501 369\nL 501 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"57\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Mon</text><text x=\"145\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Tue</text><text x=\"234\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Wed</text><text x=\"323\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Thu</text><text x=\"411\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Fri</text><text x=\"500\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sat</text><text x=\"563\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sun</text><path d=\"M 58 335\nL 146 332\nL 235 340\nL 324 332\nL 412 342\nL 501 308\nL 590 313\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"58\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"146\" cy=\"332\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"235\" cy=\"340\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"332\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"412\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"501\" cy=\"308\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"590\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 58 310\nL 146 320\nL 235 318\nL 324 307\nL 412 293\nL 501 283\nL 590 288\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"58\" cy=\"310\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"146\" cy=\"320\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"235\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"307\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"412\" cy=\"293\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"501\" cy=\"283\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"590\" cy=\"288\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 58 328\nL 146 307\nL 235 315\nL 324 327\nL 412 318\nL 501 283\nL 590 264\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"58\" cy=\"328\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"146\" cy=\"307\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"235\" cy=\"315\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"324\" cy=\"327\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"412\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"501\" cy=\"283\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"590\" cy=\"264\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><path d=\"M 58 286\nL 146 283\nL 235 291\nL 324 282\nL 412 269\nL 501 283\nL 590 286\" style=\"stroke-width:2;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"58\" cy=\"286\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"146\" cy=\"283\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"235\" cy=\"291\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"324\" cy=\"282\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"412\" cy=\"269\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"501\" cy=\"283\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"590\" cy=\"286\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><path d=\"M 58 163\nL 146 135\nL 235 143\nL 324 135\nL 412 47\nL 501 38\nL 590 40\" style=\"stroke-width:2;stroke:rgb(115,192,222);fill:none\"/><circle cx=\"58\" cy=\"163\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"146\" cy=\"135\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"235\" cy=\"143\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"324\" cy=\"135\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"412\" cy=\"47\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"501\" cy=\"38\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"590\" cy=\"40\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/></svg>",
},
{
name: "boundary_gap_enable",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.XAxis.BoundaryGap = Ptr(true)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "08Y_skip1",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 8,
LabelSkipCount: 1,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.4k</text><text x=\"22\" y=\"124\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1k</text><text x=\"12\" y=\"232\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">600</text><text x=\"12\" y=\"340\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">200</text><text x=\"30\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 45 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 64\nL 590 64\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 118\nL 590 118\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 172\nL 590 172\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 227\nL 590 227\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 281\nL 590 281\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 335\nL 590 335\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 87 358\nL 164 355\nL 241 363\nL 319 354\nL 396 366\nL 473 328\nL 551 333\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 87 168\nL 164 138\nL 241 146\nL 319 137\nL 396 40\nL 473 29\nL 551 32\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "09Y_skip1",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 9,
LabelSkipCount: 1,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"110\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.08k</text><text x=\"21\" y=\"205\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">720</text><text x=\"21\" y=\"299\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">360</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 57\nL 590 57\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 105\nL 590 105\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 152\nL 590 152\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 200\nL 590 200\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 247\nL 590 247\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 295\nL 590 295\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 342\nL 590 342\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "08Y_skip2",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 8,
LabelSkipCount: 2,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.4k</text><text x=\"12\" y=\"178\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"12\" y=\"340\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">200</text><text x=\"30\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 45 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 64\nL 590 64\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 118\nL 590 118\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 172\nL 590 172\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 227\nL 590 227\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 281\nL 590 281\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 335\nL 590 335\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 87 358\nL 164 355\nL 241 363\nL 319 354\nL 396 366\nL 473 328\nL 551 333\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 87 168\nL 164 138\nL 241 146\nL 319 137\nL 396 40\nL 473 29\nL 551 32\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "09Y_skip2",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 9,
LabelSkipCount: 2,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"21\" y=\"157\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">900</text><text x=\"21\" y=\"299\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">360</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 57\nL 590 57\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 105\nL 590 105\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 152\nL 590 152\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 200\nL 590 200\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 247\nL 590 247\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 295\nL 590 295\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 342\nL 590 342\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "10Y_skip2",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 10,
LabelSkipCount: 2,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "08Y_skip3",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 8,
LabelSkipCount: 3,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.4k</text><text x=\"12\" y=\"232\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">600</text><text x=\"30\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 45 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 64\nL 590 64\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 118\nL 590 118\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 172\nL 590 172\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 227\nL 590 227\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 281\nL 590 281\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 335\nL 590 335\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 87 358\nL 164 355\nL 241 363\nL 319 354\nL 396 366\nL 473 328\nL 551 333\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 87 168\nL 164 138\nL 241 146\nL 319 137\nL 396 40\nL 473 29\nL 551 32\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "09Y_skip3",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 9,
LabelSkipCount: 3,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"21\" y=\"205\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">720</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 57\nL 590 57\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 105\nL 590 105\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 152\nL 590 152\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 200\nL 590 200\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 247\nL 590 247\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 295\nL 590 295\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 342\nL 590 342\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "10Y_skip3",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 10,
LabelSkipCount: 3,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "11Y_skip3",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 11,
LabelSkipCount: 3,
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"18\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.4k</text><text x=\"21\" y=\"167\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">840</text><text x=\"21\" y=\"318\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">280</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 48\nL 590 48\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 86\nL 590 86\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 124\nL 590 124\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 162\nL 590 162\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 200\nL 590 200\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 238\nL 590 238\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 276\nL 590 276\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 314\nL 590 314\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 352\nL 590 352\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 358\nL 172 355\nL 248 363\nL 324 354\nL 400 366\nL 476 328\nL 552 333\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 168\nL 172 138\nL 248 146\nL 324 137\nL 400 40\nL 476 29\nL 552 32\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "no_yaxis_split_line",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 4,
SplitLineShow: Ptr(false),
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.5k</text><text x=\"22\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1k</text><text x=\"12\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">500</text><text x=\"30\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 87 360\nL 164 357\nL 241 365\nL 319 357\nL 396 368\nL 473 332\nL 551 337\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 87 183\nL 164 154\nL 241 162\nL 319 154\nL 396 64\nL 473 54\nL 551 56\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "yaxis_spine_line_show",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis = []YAxisOption{
{
LabelCount: 4,
SpineLineShow: Ptr(true),
},
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 49 10\nL 49 390\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 44 10\nL 49 10\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 44 136\nL 49 136\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 44 263\nL 49 263\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 44 390\nL 49 390\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.5k</text><text x=\"22\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1k</text><text x=\"12\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">500</text><text x=\"30\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 45 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 45 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 88 360\nL 165 357\nL 242 365\nL 319 357\nL 396 368\nL 473 332\nL 551 337\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 88 183\nL 165 154\nL 242 162\nL 319 154\nL 396 64\nL 473 54\nL 551 56\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "double_yaxis",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Theme = GetTheme(ThemeLight)
opt.SeriesList[1].YAxisIndex = 1
opt.YAxis = append(opt.YAxis, opt.YAxis[0])
opt.YAxis[0].Theme = opt.Theme.WithYAxisSeriesColor(0)
opt.YAxis[1].Theme = opt.Theme.WithYAxisSeriesColor(1)
// disable extras
opt.Title.Text = ""
opt.Legend.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"552\" y=\"16\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.43k</text><text x=\"552\" y=\"55\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.36k</text><text x=\"552\" y=\"94\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.29k</text><text x=\"552\" y=\"133\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.22k</text><text x=\"552\" y=\"172\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.15k</text><text x=\"552\" y=\"211\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.08k</text><text x=\"552\" y=\"250\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.01k</text><text x=\"552\" y=\"289\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">940</text><text x=\"552\" y=\"328\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">870</text><text x=\"552\" y=\"368\" style=\"stroke:none;fill:rgb(145,204,117);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">234</text><text x=\"9\" y=\"55\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">218</text><text x=\"9\" y=\"94\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">202</text><text x=\"9\" y=\"133\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">186</text><text x=\"9\" y=\"172\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">170</text><text x=\"9\" y=\"211\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">154</text><text x=\"9\" y=\"250\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">138</text><text x=\"9\" y=\"289\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">122</text><text x=\"9\" y=\"328\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">106</text><text x=\"18\" y=\"368\" style=\"stroke:none;fill:rgb(84,112,198);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">90</text><path d=\"M 42 10\nL 542 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 49\nL 542 49\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 88\nL 542 88\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 128\nL 542 128\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 167\nL 542 167\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 206\nL 542 206\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 246\nL 542 246\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 285\nL 542 285\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 42 324\nL 542 324\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 46 364\nL 542 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 46 369\nL 46 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 116 369\nL 116 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 187 369\nL 187 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 258 369\nL 258 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 329 369\nL 329 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 400 369\nL 400 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 471 369\nL 471 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 542 369\nL 542 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"76\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"146\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"217\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"288\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"360\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"431\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"501\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 81 291\nL 151 261\nL 222 337\nL 293 256\nL 364 364\nL 435 20\nL 506 69\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"81\" cy=\"291\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"151\" cy=\"261\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"222\" cy=\"337\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"293\" cy=\"256\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"364\" cy=\"364\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"435\" cy=\"20\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"506\" cy=\"69\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 81 353\nL 151 290\nL 222 308\nL 293 289\nL 364 89\nL 435 67\nL 506 72\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"81\" cy=\"353\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"151\" cy=\"290\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"222\" cy=\"308\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"293\" cy=\"289\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"364\" cy=\"89\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"435\" cy=\"67\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"506\" cy=\"72\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "right_yaxis",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Theme = GetTheme(ThemeLight)
opt.YAxis[0].Position = PositionRight
// disable extras
opt.Title.Text = ""
opt.Legend.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"552\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"552\" y=\"55\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"552\" y=\"94\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"552\" y=\"133\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"552\" y=\"172\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"552\" y=\"211\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"552\" y=\"250\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"552\" y=\"289\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"552\" y=\"328\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"552\" y=\"368\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 10 10\nL 542 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 49\nL 542 49\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 88\nL 542 88\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 128\nL 542 128\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 167\nL 542 167\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 206\nL 542 206\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 246\nL 542 246\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 285\nL 542 285\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 324\nL 542 324\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 10 364\nL 542 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 10 369\nL 10 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 86 369\nL 86 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 162 369\nL 162 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 238 369\nL 238 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 314 369\nL 314 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 390 369\nL 390 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 466 369\nL 466 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 542 369\nL 542 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"43\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"119\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"195\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"271\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"348\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"424\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"499\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 48 335\nL 124 332\nL 200 340\nL 276 332\nL 352 342\nL 428 308\nL 504 313\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"48\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"124\" cy=\"332\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"200\" cy=\"340\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"276\" cy=\"332\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"352\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"428\" cy=\"308\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"504\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 48 163\nL 124 135\nL 200 143\nL 276 135\nL 352 47\nL 428 38\nL 504 40\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"48\" cy=\"163\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"124\" cy=\"135\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"200\" cy=\"143\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"276\" cy=\"135\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"352\" cy=\"47\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"428\" cy=\"38\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"504\" cy=\"40\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "zero_data",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
values := [][]float64{
{0, 0, 0, 0, 0, 0, 0},
{0, 0, 0, 0, 0, 0, 0},
}
opt.SeriesList = NewSeriesListLine(values)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"9\" y=\"205\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><text x=\"9\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 24 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 24 200\nL 590 200\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 68 390\nL 148 390\nL 228 390\nL 308 390\nL 389 390\nL 469 390\nL 549 390\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 68 390\nL 148 390\nL 228 390\nL 308 390\nL 389 390\nL 469 390\nL 549 390\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "tiny_range",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
values := [][]float64{
{0.1, 0.2, 0.1, 0.2, 0.4, 0.2, 0.1},
{0.2, 0.4, 0.8, 0.4, 0.2, 0.1, 0.2},
}
opt.SeriesList = NewSeriesListLine(values)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"22\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"9\" y=\"91\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.6</text><text x=\"9\" y=\"167\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.2</text><text x=\"9\" y=\"242\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0.8</text><text x=\"9\" y=\"318\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0.4</text><text x=\"22\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 37 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 37 86\nL 590 86\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 37 162\nL 590 162\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 37 238\nL 590 238\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 37 314\nL 590 314\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 80 371\nL 158 352\nL 236 371\nL 315 352\nL 393 314\nL 472 352\nL 550 371\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 80 352\nL 158 314\nL 236 238\nL 315 314\nL 393 352\nL 472 371\nL 550 352\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "custom_font",
makeOptions: func() LineChartOption {
opt := makeFullLineChartOption()
customFont := NewFontStyleWithSize(4.0).WithColor(ColorBlue)
opt.Legend.FontStyle = customFont
opt.XAxis.FontStyle = customFont
opt.Title.FontStyle = customFont
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 127 19\nL 157 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"142\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"159\" y=\"25\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Email</text><path d=\"M 192 19\nL 222 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"207\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"224\" y=\"25\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Union Ads</text><path d=\"M 268 19\nL 298 19\" style=\"stroke-width:3;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"283\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><text x=\"300\" y=\"25\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Video Ads</text><path d=\"M 344 19\nL 374 19\" style=\"stroke-width:3;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"359\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><text x=\"376\" y=\"25\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Direct</text><path d=\"M 410 19\nL 440 19\" style=\"stroke-width:3;stroke:rgb(115,192,222);fill:none\"/><circle cx=\"425\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(115,192,222);fill:rgb(115,192,222)\"/><text x=\"442\" y=\"25\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Search Engine</text><text x=\"10\" y=\"16\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"42\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"78\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"114\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"151\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"187\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"223\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"260\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"296\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"332\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"369\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 36\nL 590 36\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 72\nL 590 72\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 109\nL 590 109\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 145\nL 590 145\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 182\nL 590 182\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 218\nL 590 218\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 255\nL 590 255\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 291\nL 590 291\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 328\nL 590 328\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 365\nL 590 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 370\nL 58 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 370\nL 134 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 370\nL 210 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 370\nL 286 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 370\nL 362 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 370\nL 438 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 370\nL 514 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 370\nL 590 365\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Mon</text><text x=\"168\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Tue</text><text x=\"243\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Wed</text><text x=\"320\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Thu</text><text x=\"397\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Fri</text><text x=\"472\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Sat</text><text x=\"548\" y=\"381\" style=\"stroke:none;fill:blue;font-size:5.1px;font-family:'Roboto Medium',sans-serif\">Sun</text><path d=\"M 96 338\nL 172 335\nL 248 342\nL 324 335\nL 400 345\nL 476 313\nL 552 318\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"338\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"345\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 315\nL 172 324\nL 248 322\nL 324 312\nL 400 299\nL 476 290\nL 552 295\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"315\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"324\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"322\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"312\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"299\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"290\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"295\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 96 331\nL 172 312\nL 248 320\nL 324 330\nL 400 322\nL 476 290\nL 552 272\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"96\" cy=\"331\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"172\" cy=\"312\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"248\" cy=\"320\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"324\" cy=\"330\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"400\" cy=\"322\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"476\" cy=\"290\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"552\" cy=\"272\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><path d=\"M 96 292\nL 172 290\nL 248 297\nL 324 289\nL 400 276\nL 476 290\nL 552 292\" style=\"stroke-width:2;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"96\" cy=\"292\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"172\" cy=\"290\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"248\" cy=\"297\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"324\" cy=\"289\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"400\" cy=\"276\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"476\" cy=\"290\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"552\" cy=\"292\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><path d=\"M 96 178\nL 172 153\nL 248 160\nL 324 152\nL 400 71\nL 476 62\nL 552 64\" style=\"stroke-width:2;stroke:rgb(115,192,222);fill:none\"/><circle cx=\"96\" cy=\"178\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"172\" cy=\"153\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"248\" cy=\"160\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"324\" cy=\"152\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"400\" cy=\"71\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"476\" cy=\"62\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"552\" cy=\"64\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/></svg>",
},
{
name: "title_offset_center_legend_right",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Title.Offset = OffsetCenter
opt.Legend.Offset = OffsetRight
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 490 19\nL 520 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"505\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"522\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 551 19\nL 581 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"566\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"583\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"286\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"52\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"87\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"122\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"157\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"192\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"227\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"262\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"297\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"332\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"368\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 46\nL 590 46\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 81\nL 590 81\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 116\nL 590 116\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 152\nL 590 152\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 187\nL 590 187\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 222\nL 590 222\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 258\nL 590 258\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 293\nL 590 293\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 328\nL 590 328\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 369\nL 58 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 369\nL 134 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 369\nL 210 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 369\nL 286 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 369\nL 362 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 369\nL 438 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 369\nL 514 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"167\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"243\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"319\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"396\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"472\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"547\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 96 338\nL 172 335\nL 248 342\nL 324 335\nL 400 345\nL 476 314\nL 552 318\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"338\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"345\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"314\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 183\nL 172 159\nL 248 166\nL 324 158\nL 400 80\nL 476 71\nL 552 73\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"183\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"159\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"166\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"158\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"80\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"71\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"73\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "title_offset_right",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Title.Offset = OffsetRight
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 19\nL 280 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 19\nL 341 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"561\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"52\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"87\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"122\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"157\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"192\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"227\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"262\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"297\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"332\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"368\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 46\nL 590 46\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 81\nL 590 81\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 116\nL 590 116\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 152\nL 590 152\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 187\nL 590 187\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 222\nL 590 222\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 258\nL 590 258\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 293\nL 590 293\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 328\nL 590 328\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 369\nL 58 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 369\nL 134 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 369\nL 210 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 369\nL 286 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 369\nL 362 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 369\nL 438 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 369\nL 514 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"167\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"243\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"319\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"396\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"472\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"547\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 96 338\nL 172 335\nL 248 342\nL 324 335\nL 400 345\nL 476 314\nL 552 318\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"338\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"345\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"314\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 183\nL 172 159\nL 248 166\nL 324 158\nL 400 80\nL 476 71\nL 552 73\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"183\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"159\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"166\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"158\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"80\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"71\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"73\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "title_offset_bottom_center",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Title.Offset = OffsetStr{
Top: PositionBottom,
Left: PositionCenter,
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 19\nL 280 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 19\nL 341 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"286\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"52\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"85\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"118\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"152\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"185\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"218\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"252\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"285\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"318\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 46\nL 590 46\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 79\nL 590 79\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 113\nL 590 113\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 146\nL 590 146\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 180\nL 590 180\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 213\nL 590 213\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 247\nL 590 247\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 280\nL 590 280\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 314\nL 590 314\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 348\nL 590 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 353\nL 58 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 353\nL 134 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 353\nL 210 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 353\nL 286 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 353\nL 362 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 353\nL 438 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 353\nL 514 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 353\nL 590 348\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"167\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"243\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"319\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"396\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"472\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"547\" y=\"374\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 96 323\nL 172 321\nL 248 327\nL 324 320\nL 400 330\nL 476 300\nL 552 304\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"323\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"321\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"327\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"320\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"330\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"300\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"304\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 177\nL 172 153\nL 248 160\nL 324 153\nL 400 78\nL 476 70\nL 552 72\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"177\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"153\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"160\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"153\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"78\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"70\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"72\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "legend_offset_bottom",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Legend.Offset = OffsetStr{
Top: PositionBottom,
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 374\nL 280 374\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"374\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 374\nL 341 374\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"374\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"10\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"47\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"78\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"110\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"173\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"205\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"237\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"300\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"332\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 41\nL 590 41\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 72\nL 590 72\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 104\nL 590 104\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 168\nL 590 168\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 200\nL 590 200\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 232\nL 590 232\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 264\nL 590 264\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 296\nL 590 296\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 328\nL 590 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 333\nL 58 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 333\nL 134 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 333\nL 210 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 333\nL 286 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 333\nL 362 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 333\nL 438 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 333\nL 514 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 333\nL 590 328\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"167\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"243\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"319\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"396\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"472\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"547\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 96 305\nL 172 302\nL 248 308\nL 324 302\nL 400 311\nL 476 283\nL 552 287\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"305\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"302\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"308\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"302\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"311\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"283\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"287\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 165\nL 172 143\nL 248 149\nL 324 142\nL 400 71\nL 476 63\nL 552 65\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"165\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"143\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"149\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"142\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"71\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"63\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"65\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "legend_padding_top",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Legend.Padding = NewBoxEqual(50)
opt.Legend.BorderWidth = 1.0
// disable extra stuff
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 64\nL 280 64\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"64\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"70\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 64\nL 341 64\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"64\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"70\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 190 136\nL 190 0\nL 410 0\nL 410 136\nL 190 136\" style=\"stroke-width:1;stroke:black;fill:none\"/><text x=\"10\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><path d=\"M 10 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 10 369\nL 10 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 92 369\nL 92 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 175 369\nL 175 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 258 369\nL 258 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 341 369\nL 341 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 424 369\nL 424 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 507 369\nL 507 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"46\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"128\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"211\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"294\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"378\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"461\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"543\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 51 346\nL 133 344\nL 216 349\nL 299 344\nL 382 351\nL 465 329\nL 548 332\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"51\" cy=\"346\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"133\" cy=\"344\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"216\" cy=\"349\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"299\" cy=\"344\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"382\" cy=\"351\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"465\" cy=\"329\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"548\" cy=\"332\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 51 238\nL 133 220\nL 216 225\nL 299 220\nL 382 165\nL 465 159\nL 548 160\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"51\" cy=\"238\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"133\" cy=\"220\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"216\" cy=\"225\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"299\" cy=\"220\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"382\" cy=\"165\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"465\" cy=\"159\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"548\" cy=\"160\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "legend_padding_bottom",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Legend.Padding = NewBoxEqual(50)
opt.Legend.Offset = OffsetStr{
Top: PositionBottom,
}
opt.Legend.BorderWidth = 1.0
// disable extra stuff
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 324\nL 280 324\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"324\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"330\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 324\nL 341 324\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"324\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"330\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 190 396\nL 190 260\nL 410 260\nL 410 396\nL 190 396\" style=\"stroke-width:1;stroke:black;fill:none\"/><text x=\"10\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><path d=\"M 10 233\nL 590 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 10 238\nL 10 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 92 238\nL 92 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 175 238\nL 175 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 258 238\nL 258 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 341 238\nL 341 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 424 238\nL 424 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 507 238\nL 507 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 238\nL 590 233\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"46\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"128\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"211\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"294\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"378\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"461\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"543\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 51 217\nL 133 216\nL 216 220\nL 299 216\nL 382 221\nL 465 203\nL 548 205\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"51\" cy=\"217\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"133\" cy=\"216\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"216\" cy=\"220\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"299\" cy=\"216\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"382\" cy=\"221\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"465\" cy=\"203\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"548\" cy=\"205\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 51 124\nL 133 109\nL 216 113\nL 299 109\nL 382 61\nL 465 56\nL 548 57\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"51\" cy=\"124\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"133\" cy=\"109\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"216\" cy=\"113\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"299\" cy=\"109\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"382\" cy=\"61\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"465\" cy=\"56\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"548\" cy=\"57\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "title_and_legend_offset_bottom",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
bottomOffset := OffsetStr{
Top: PositionBottom,
Left: PositionCenter,
}
opt.Title.Offset = bottomOffset
opt.Legend.Offset = bottomOffset
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 374\nL 280 374\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"374\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 374\nL 341 374\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"374\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"286\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"49\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"82\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"116\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"149\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"182\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"216\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"249\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"282\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"316\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 43\nL 590 43\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 77\nL 590 77\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 110\nL 590 110\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 144\nL 590 144\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 177\nL 590 177\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 211\nL 590 211\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 244\nL 590 244\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 278\nL 590 278\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 312\nL 590 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 317\nL 58 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 317\nL 134 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 317\nL 210 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 317\nL 286 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 317\nL 362 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 317\nL 438 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 317\nL 514 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 317\nL 590 312\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"167\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"243\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"319\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"396\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"472\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"547\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 96 287\nL 172 285\nL 248 291\nL 324 284\nL 400 294\nL 476 264\nL 552 268\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"287\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"285\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"291\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"284\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"294\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"264\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"268\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 141\nL 172 117\nL 248 124\nL 324 117\nL 400 42\nL 476 34\nL 552 36\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"141\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"117\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"124\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"117\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"42\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"34\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"36\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "vertical_legend_offset_right",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Legend.Vertical = Ptr(true)
opt.Legend.Offset = OffsetRight
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 549 19\nL 579 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"564\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"581\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 549 39\nL 579 39\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"564\" cy=\"39\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"581\" y=\"45\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"10\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"9\" y=\"47\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"82\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"118\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"154\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"189\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"225\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"261\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"296\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"332\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"368\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 41\nL 590 41\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 76\nL 590 76\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 112\nL 590 112\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 148\nL 590 148\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 184\nL 590 184\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 220\nL 590 220\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 256\nL 590 256\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 292\nL 590 292\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 328\nL 590 328\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 58 369\nL 58 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 134 369\nL 134 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 210 369\nL 210 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 286 369\nL 286 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 362 369\nL 362 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 438 369\nL 438 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 369\nL 514 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"91\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"167\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"243\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"319\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"396\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"472\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"547\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 96 338\nL 172 335\nL 248 342\nL 324 334\nL 400 344\nL 476 313\nL 552 317\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"338\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"334\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"344\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"317\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 181\nL 172 155\nL 248 162\nL 324 155\nL 400 75\nL 476 66\nL 552 68\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"181\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"155\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"162\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"155\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"75\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"66\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"68\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "legend_overlap_chart",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Title.Show = Ptr(false)
opt.Legend.Offset = OffsetRight
opt.Legend.OverlayChart = Ptr(true)
// disable extra
opt.Title.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 490 19\nL 520 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"505\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"522\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 551 19\nL 581 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"566\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"583\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"96\" cy=\"359\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"172\" cy=\"356\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"248\" cy=\"364\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"324\" cy=\"355\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"400\" cy=\"367\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"476\" cy=\"330\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"552\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"174\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"172\" cy=\"145\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"248\" cy=\"153\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"324\" cy=\"144\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"400\" cy=\"50\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"476\" cy=\"40\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"552\" cy=\"42\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "legend_boxed_offset_bottom",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartLegendOption()
opt.Legend.Offset = OffsetStr{
Top: PositionBottom,
}
opt.Legend.BorderWidth = 2.0
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 374\nL 280 374\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"374\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 374\nL 341 374\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"374\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 240 396\nL 240 355\nL 360 355\nL 360 396\nL 240 396\" style=\"stroke-width:2;stroke:black;fill:none\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"54\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"92\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"130\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"168\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"206\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"244\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"282\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"320\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"358\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 48\nL 590 48\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 86\nL 590 86\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 124\nL 590 124\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 162\nL 590 162\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 201\nL 590 201\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 239\nL 590 239\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 277\nL 590 277\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 315\nL 590 315\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 326\nL 172 323\nL 248 330\nL 324 322\nL 400 333\nL 476 300\nL 552 304\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 159\nL 172 132\nL 248 139\nL 324 131\nL 400 46\nL 476 37\nL 552 39\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "vertical_legend_boxed_offset_right",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartLegendOption()
opt.Legend.Vertical = Ptr(true)
opt.Legend.Offset = OffsetRight
opt.Legend.BorderWidth = 2.0
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 549 19\nL 579 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"564\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"581\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 549 39\nL 579 39\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"564\" cy=\"39\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"581\" y=\"45\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 539 65\nL 539 0\nL 600 0\nL 600 65\nL 539 65\" style=\"stroke-width:2;stroke:black;fill:none\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "legend_boxed_overlap_chart",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartLegendOption()
opt.Title.Show = Ptr(false)
opt.Legend.Offset = OffsetRight
opt.Legend.OverlayChart = Ptr(true)
opt.Legend.BorderWidth = 2.0
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 490 19\nL 520 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"505\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"522\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 551 19\nL 581 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"566\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"583\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 480 41\nL 480 0\nL 600 0\nL 600 41\nL 480 41\" style=\"stroke-width:2;stroke:black;fill:none\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\nL 324 355\nL 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "curved_line",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.StrokeSmoothingTension = 0.8
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nQ172,356 202,359\nQ248,364 278,360\nQ324,355 354,359\nQ400,367 430,352\nQ476,330 506,332\nQ476,330 552,335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nQ172,145 202,148\nQ248,153 278,149\nQ324,144 354,106\nQ400,50 430,46\nQ476,40 506,40\nQ476,40 552,42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "line_gap",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.SeriesList[0].Values[3] = GetNullValue()
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 400 367\nL 476 330\nL 552 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "line_gap_dot",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.Symbol = SymbolDot
opt.SeriesList[0].Values[3] = GetNullValue()
opt.SeriesList[0].Values[5] = GetNullValue()
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nL 172 356\nL 248 364\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"400\" cy=\"367\" r=\"2\" style=\"stroke:none;fill:none\"/><circle cx=\"552\" cy=\"335\" r=\"2\" style=\"stroke:none;fill:none\"/><circle cx=\"96\" cy=\"359\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"172\" cy=\"356\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"248\" cy=\"364\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"324\" cy=\"2147483657\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"400\" cy=\"367\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"476\" cy=\"2147483657\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"552\" cy=\"335\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path d=\"M 96 174\nL 172 145\nL 248 153\nL 324 144\nL 400 50\nL 476 40\nL 552 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"96\" cy=\"174\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"172\" cy=\"145\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"248\" cy=\"153\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"324\" cy=\"144\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"400\" cy=\"50\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"476\" cy=\"40\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"552\" cy=\"42\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/></svg>",
},
{
name: "line_gap_fill_area",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.SeriesList[0].Values[3] = GetNullValue()
opt.FillArea = Ptr(true)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 359\nL 146 356\nL 235 364\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 412 367\nL 501 330\nL 590 335\nL 590 390\nL 58 390\nL 58 359\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 58 359\nL 146 356\nL 235 364\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 412 367\nL 501 330\nL 590 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 58 174\nL 146 145\nL 235 153\nL 324 144\nL 412 50\nL 501 40\nL 590 42\nL 590 390\nL 58 390\nL 58 174\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 58 174\nL 146 145\nL 235 153\nL 324 144\nL 412 50\nL 501 40\nL 590 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "line_gap_start_fill_area",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.SeriesList[0].Values[0] = GetNullValue()
opt.SeriesList[0].Values[1] = GetNullValue()
opt.SeriesList[1].Values[0] = GetNullValue()
opt.FillArea = Ptr(true)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 235 364\nL 324 355\nL 412 367\nL 501 330\nL 590 335\nL 590 390\nL 235 390\nL 235 364\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 235 364\nL 324 355\nL 412 367\nL 501 330\nL 590 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 146 145\nL 235 153\nL 324 144\nL 412 50\nL 501 40\nL 590 42\nL 590 390\nL 146 390\nL 146 145\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 146 145\nL 235 153\nL 324 144\nL 412 50\nL 501 40\nL 590 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "curved_line_gap",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.StrokeSmoothingTension = 0.8
opt.SeriesList[0].Values[3] = GetNullValue()
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nQ172,356 202,359\nQ172,356 248,364\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 400 367\nQ476,330 506,332\nQ476,330 552,335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nQ172,145 202,148\nQ248,153 278,149\nQ324,144 354,106\nQ400,50 430,46\nQ476,40 506,40\nQ476,40 552,42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "curved_line_gap_fill_area",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.StrokeSmoothingTension = 0.8
opt.SeriesList[0].Values[3] = GetNullValue()
opt.FillArea = Ptr(true)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 359\nQ146,356 181,359\nQ146,356 235,364\nM 412 367\nQ501,330 536,332\nQ501,330 590,335\nL 590 390\nL 58 390\nL 58 359\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 58 359\nQ146,356 181,359\nQ146,356 235,364\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 412 367\nQ501,330 536,332\nQ501,330 590,335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 58 174\nQ146,145 181,148\nQ235,153 270,149\nQ324,144 359,106\nQ412,50 447,46\nQ501,40 536,40\nQ501,40 590,42\nL 590 390\nL 58 390\nL 58 174\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 58 174\nQ146,145 181,148\nQ235,153 270,149\nQ324,144 359,106\nQ412,50 447,46\nQ501,40 536,40\nQ501,40 590,42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "fill_area",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.FillArea = Ptr(true)
opt.FillOpacity = 100
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 359\nL 146 356\nL 235 364\nL 324 355\nL 412 367\nL 501 330\nL 590 335\nL 590 390\nL 58 390\nL 58 359\" style=\"stroke:none;fill:rgba(84,112,198,0.4)\"/><path d=\"M 58 359\nL 146 356\nL 235 364\nL 324 355\nL 412 367\nL 501 330\nL 590 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 58 174\nL 146 145\nL 235 153\nL 324 144\nL 412 50\nL 501 40\nL 590 42\nL 590 390\nL 58 390\nL 58 174\" style=\"stroke:none;fill:rgba(145,204,117,0.4)\"/><path d=\"M 58 174\nL 146 145\nL 235 153\nL 324 144\nL 412 50\nL 501 40\nL 590 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "fill_area_boundary_gap",
makeOptions: func() LineChartOption {
opt := makeFullLineChartOption()
opt.FillArea = Ptr(true)
opt.FillOpacity = 100
opt.XAxis.BoundaryGap = Ptr(true)
// disable extra
opt.Symbol = SymbolNone
opt.Title.Show = Ptr(false)
opt.Legend.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 10 364\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 10 369\nL 10 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 92 369\nL 92 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 175 369\nL 175 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 258 369\nL 258 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 341 369\nL 341 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 424 369\nL 424 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 507 369\nL 507 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 590 369\nL 590 364\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"36\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Mon</text><text x=\"120\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Tue</text><text x=\"201\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Wed</text><text x=\"286\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Thu</text><text x=\"373\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Fri</text><text x=\"454\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sat</text><text x=\"535\" y=\"390\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sun</text><path d=\"M 51 335\nL 133 332\nL 216 340\nL 299 332\nL 382 342\nL 465 308\nL 548 313\nL 548 364\nL 51 364\nL 51 335\" style=\"stroke:none;fill:rgba(84,112,198,0.4)\"/><path d=\"M 51 335\nL 133 332\nL 216 340\nL 299 332\nL 382 342\nL 465 308\nL 548 313\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 51 310\nL 133 320\nL 216 318\nL 299 307\nL 382 293\nL 465 283\nL 548 288\nL 548 364\nL 51 364\nL 51 310\" style=\"stroke:none;fill:rgba(145,204,117,0.4)\"/><path d=\"M 51 310\nL 133 320\nL 216 318\nL 299 307\nL 382 293\nL 465 283\nL 548 288\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><path d=\"M 51 328\nL 133 307\nL 216 315\nL 299 327\nL 382 318\nL 465 283\nL 548 264\nL 548 364\nL 51 364\nL 51 328\" style=\"stroke:none;fill:rgba(250,200,88,0.4)\"/><path d=\"M 51 328\nL 133 307\nL 216 315\nL 299 327\nL 382 318\nL 465 283\nL 548 264\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><path d=\"M 51 286\nL 133 283\nL 216 291\nL 299 282\nL 382 269\nL 465 283\nL 548 286\nL 548 364\nL 51 364\nL 51 286\" style=\"stroke:none;fill:rgba(238,102,102,0.4)\"/><path d=\"M 51 286\nL 133 283\nL 216 291\nL 299 282\nL 382 269\nL 465 283\nL 548 286\" style=\"stroke-width:2;stroke:rgb(238,102,102);fill:none\"/><path d=\"M 51 163\nL 133 135\nL 216 143\nL 299 135\nL 382 47\nL 465 38\nL 548 40\nL 548 364\nL 51 364\nL 51 163\" style=\"stroke:none;fill:rgba(115,192,222,0.4)\"/><path d=\"M 51 163\nL 133 135\nL 216 143\nL 299 135\nL 382 47\nL 465 38\nL 548 40\" style=\"stroke-width:2;stroke:rgb(115,192,222);fill:none\"/></svg>",
},
{
name: "fill_area_curved_boundary_gap",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.FillArea = Ptr(true)
opt.StrokeSmoothingTension = 0.8
opt.XAxis.BoundaryGap = Ptr(true)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 96 359\nQ172,356 202,359\nQ248,364 278,360\nQ324,355 354,359\nQ400,367 430,352\nQ476,330 506,332\nQ476,330 552,335\nL 552 390\nL 96 390\nL 96 359\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 96 359\nQ172,356 202,359\nQ248,364 278,360\nQ324,355 354,359\nQ400,367 430,352\nQ476,330 506,332\nQ476,330 552,335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 96 174\nQ172,145 202,148\nQ248,153 278,149\nQ324,144 354,106\nQ400,50 430,46\nQ476,40 506,40\nQ476,40 552,42\nL 552 390\nL 96 390\nL 96 174\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 96 174\nQ172,145 202,148\nQ248,153 278,149\nQ324,144 354,106\nQ400,50 430,46\nQ476,40 506,40\nQ476,40 552,42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "fill_area_curved_no_gap",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.FillArea = Ptr(true)
opt.StrokeSmoothingTension = 0.8
opt.XAxis.BoundaryGap = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.44k</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.28k</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.12k</text><text x=\"21\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">960</text><text x=\"21\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"21\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">640</text><text x=\"21\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">480</text><text x=\"21\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">320</text><text x=\"21\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">160</text><text x=\"39\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 54 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 54 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 58 359\nQ146,356 181,359\nQ235,364 270,360\nQ324,355 359,359\nQ412,367 447,352\nQ501,330 536,332\nQ501,330 590,335\nL 590 390\nL 58 390\nL 58 359\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 58 359\nQ146,356 181,359\nQ235,364 270,360\nQ324,355 359,359\nQ412,367 447,352\nQ501,330 536,332\nQ501,330 590,335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 58 174\nQ146,145 181,148\nQ235,153 270,149\nQ324,144 359,106\nQ412,50 447,46\nQ501,40 536,40\nQ501,40 590,42\nL 590 390\nL 58 390\nL 58 174\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 58 174\nQ146,145 181,148\nQ235,153 270,149\nQ324,144 359,106\nQ412,50 447,46\nQ501,40 536,40\nQ501,40 590,42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "value_formatter",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis[0].ValueFormatter = func(f float64) string {
return "f"
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"9\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"58\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"100\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"142\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"184\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"310\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"352\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><text x=\"9\" y=\"394\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">f</text><path d=\"M 21 10\nL 590 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 52\nL 590 52\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 94\nL 590 94\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 136\nL 590 136\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 178\nL 590 178\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 221\nL 590 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 263\nL 590 263\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 305\nL 590 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 21 347\nL 590 347\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 65 359\nL 145 356\nL 226 364\nL 307 355\nL 387 367\nL 468 330\nL 549 335\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 65 174\nL 145 145\nL 226 153\nL 307 144\nL 387 50\nL 468 40\nL 549 42\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/></svg>",
},
{
name: "mark_line",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.Padding = NewBoxEqual(40)
opt.YAxis[0].Show = Ptr(false)
for i := range opt.SeriesList {
markLine := NewMarkLine("min", "max", "average")
markLine.ValueFormatter = func(f float64) string {
return FormatValueHumanizeShort(f, 0, false)
}
opt.SeriesList[i].MarkLine = markLine
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 77 334\nL 151 331\nL 225 338\nL 299 331\nL 374 340\nL 448 309\nL 522 314\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 77 178\nL 151 153\nL 225 160\nL 299 153\nL 374 74\nL 448 65\nL 522 67\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"43\" cy=\"340\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 49 340\nL 542 340\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 335\nL 558 340\nL 542 345\nL 547 340\nL 542 335\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"560\" y=\"344\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">90</text><circle cx=\"43\" cy=\"309\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 49 309\nL 542 309\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 304\nL 558 309\nL 542 314\nL 547 309\nL 542 304\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"560\" y=\"313\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">230</text><circle cx=\"43\" cy=\"328\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 49 328\nL 542 328\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 323\nL 558 328\nL 542 333\nL 547 328\nL 542 323\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"560\" y=\"332\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">145</text><circle cx=\"43\" cy=\"178\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 49 178\nL 542 178\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 173\nL 558 178\nL 542 183\nL 547 178\nL 542 173\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"560\" y=\"182\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">820</text><circle cx=\"43\" cy=\"65\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 49 65\nL 542 65\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 60\nL 558 65\nL 542 70\nL 547 65\nL 542 60\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"560\" y=\"69\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">1k</text><circle cx=\"43\" cy=\"122\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 49 122\nL 542 122\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 117\nL 558 122\nL 542 127\nL 547 122\nL 542 117\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"560\" y=\"126\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">1k</text></svg>",
},
{
name: "mark_point",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis[0].Show = Ptr(false)
for i := range opt.SeriesList {
markPoint := NewMarkPoint("min", "max")
markPoint.ValueFormatter = func(f float64) string {
return FormatValueHumanizeShort(f, 0, false)
}
opt.SeriesList[i].MarkPoint = markPoint
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 51 365\nL 133 363\nL 216 369\nL 299 362\nL 382 371\nL 465 342\nL 548 346\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 51 217\nL 133 194\nL 216 200\nL 299 193\nL 382 118\nL 465 110\nL 548 112\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><path d=\"M 378 364\nA 14 14 330.00 1 1 386 364\nL 382 350\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 368 350\nQ382,385 396,350\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"375\" y=\"355\" style=\"stroke:none;fill:rgb(238,238,238);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">90</text><path d=\"M 461 335\nA 14 14 330.00 1 1 469 335\nL 465 321\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 451 321\nQ465,356 479,321\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"454\" y=\"326\" style=\"stroke:none;fill:rgb(238,238,238);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">230</text><path d=\"M 47 210\nA 14 14 330.00 1 1 55 210\nL 51 196\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 37 196\nQ51,231 65,196\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"40\" y=\"201\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">820</text><path d=\"M 461 103\nA 14 14 330.00 1 1 469 103\nL 465 89\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 451 89\nQ465,124 479,89\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"458\" y=\"94\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">1k</text></svg>",
},
{
name: "series_label",
makeOptions: func() LineChartOption {
opt := makeMinimalLineChartOption()
opt.YAxis[0].Show = Ptr(false)
for i := range opt.SeriesList {
opt.SeriesList[i].Label.Show = Ptr(true)
opt.SeriesList[i].Label.FontStyle = FontStyle{
FontSize: 12.0,
Font: GetDefaultFont(),
FontColor: ColorBlue,
}
opt.SeriesList[i].MarkPoint = NewMarkPoint("min", "max")
opt.SeriesList[i].Label.ValueFormatter = func(f float64) string {
return FormatValueHumanizeShort(f, 2, false)
}
}
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 51 365\nL 133 363\nL 216 369\nL 299 362\nL 382 371\nL 465 342\nL 548 346\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 51 217\nL 133 194\nL 216 200\nL 299 193\nL 382 118\nL 465 110\nL 548 112\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><path d=\"M 378 364\nA 14 14 330.00 1 1 386 364\nL 382 350\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 368 350\nQ382,385 396,350\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"375\" y=\"355\" style=\"stroke:none;fill:rgb(238,238,238);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">90</text><path d=\"M 461 335\nA 14 14 330.00 1 1 469 335\nL 465 321\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 451 321\nQ465,356 479,321\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"454\" y=\"326\" style=\"stroke:none;fill:rgb(238,238,238);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">230</text><path d=\"M 47 210\nA 14 14 330.00 1 1 55 210\nL 51 196\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 37 196\nQ51,231 65,196\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"40\" y=\"201\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">820</text><path d=\"M 461 103\nA 14 14 330.00 1 1 469 103\nL 465 89\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 451 89\nQ465,124 479,89\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"452\" y=\"94\" style=\"stroke:none;fill:rgb(70,70,70);font-size:10.2px;font-family:'Roboto Medium',sans-serif\">1.33k</text><text x=\"56\" y=\"371\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">120</text><text x=\"138\" y=\"369\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">132</text><text x=\"221\" y=\"375\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">101</text><text x=\"304\" y=\"368\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">134</text><text x=\"553\" y=\"352\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">210</text><text x=\"138\" y=\"200\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">932</text><text x=\"221\" y=\"206\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">901</text><text x=\"304\" y=\"199\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">934</text><text x=\"387\" y=\"124\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.29k</text><text x=\"553\" y=\"118\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.32k</text></svg>",
},
{
name: "stack_series",
makeOptions: makeFullLineChartStackedOption,
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 217 29\nL 247 29\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"232\" cy=\"29\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"249\" y=\"35\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><path d=\"M 280 29\nL 310 29\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"295\" cy=\"29\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"312\" y=\"35\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><path d=\"M 342 29\nL 372 29\" style=\"stroke-width:3;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"357\" cy=\"29\" r=\"5\" style=\"stroke-width:3;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><text x=\"374\" y=\"35\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"19\" y=\"62\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">297</text><text x=\"19\" y=\"94\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">264</text><text x=\"19\" y=\"127\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">231</text><text x=\"19\" y=\"160\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">198</text><text x=\"19\" y=\"193\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">165</text><text x=\"19\" y=\"226\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">132</text><text x=\"28\" y=\"259\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">99</text><text x=\"28\" y=\"292\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">66</text><text x=\"28\" y=\"325\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">33</text><text x=\"37\" y=\"358\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 52 56\nL 580 56\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 89\nL 580 89\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 122\nL 580 122\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 155\nL 580 155\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 188\nL 580 188\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 221\nL 580 221\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 254\nL 580 254\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 287\nL 580 287\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 320\nL 580 320\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 56 354\nL 580 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 56 359\nL 56 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 121 359\nL 121 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 187 359\nL 187 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 252 359\nL 252 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 318 359\nL 318 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 383 359\nL 383 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 449 359\nL 449 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 359\nL 514 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 580 359\nL 580 354\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"84\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><text x=\"150\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><text x=\"215\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">3</text><text x=\"281\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">4</text><text x=\"346\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">5</text><text x=\"412\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">6</text><text x=\"477\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">7</text><text x=\"543\" y=\"380\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">8</text><path d=\"M 88 350\nL 154 331\nL 219 329\nL 285 252\nL 350 212\nL 416 322\nL 481 334\nL 547 351\nL 547 354\nL 88 354\nL 88 350\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 88 350\nL 154 331\nL 219 329\nL 285 252\nL 350 212\nL 416 322\nL 481 334\nL 547 351\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"88\" cy=\"350\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"154\" cy=\"331\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"219\" cy=\"329\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"285\" cy=\"252\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"350\" cy=\"212\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"416\" cy=\"322\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"481\" cy=\"334\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"547\" cy=\"351\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 88 341\nL 154 305\nL 219 300\nL 285 106\nL 350 89\nL 416 273\nL 481 316\nL 547 349\nL 547 351\nL 481 334\nL 416 322\nL 350 212\nL 285 252\nL 219 329\nL 154 331\nL 88 350\nL 88 341\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 88 341\nL 154 305\nL 219 300\nL 285 106\nL 350 89\nL 416 273\nL 481 316\nL 547 349\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"88\" cy=\"341\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"154\" cy=\"305\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"219\" cy=\"300\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"285\" cy=\"106\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"350\" cy=\"89\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"416\" cy=\"273\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"481\" cy=\"316\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"547\" cy=\"349\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 88 260\nL 154 264\nL 219 272\nL 285 78\nL 350 65\nL 416 249\nL 481 275\nL 547 268\nL 547 349\nL 481 316\nL 416 273\nL 350 89\nL 285 106\nL 219 300\nL 154 305\nL 88 341\nL 88 260\" style=\"stroke:none;fill:rgba(250,200,88,0.8)\"/><path d=\"M 88 260\nL 154 264\nL 219 272\nL 285 78\nL 350 65\nL 416 249\nL 481 275\nL 547 268\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"88\" cy=\"260\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"154\" cy=\"264\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"219\" cy=\"272\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"285\" cy=\"78\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"350\" cy=\"65\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"416\" cy=\"249\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"481\" cy=\"275\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"547\" cy=\"268\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><path d=\"M 543 344\nA 14 14 330.00 1 1 551 344\nL 547 330\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 533 330\nQ547,365 561,330\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"538\" y=\"335\" style=\"stroke:none;fill:rgb(238,238,238);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">3.3</text><path d=\"M 346 205\nA 14 14 330.00 1 1 354 205\nL 350 191\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 336 191\nQ350,226 364,191\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"337\" y=\"196\" style=\"stroke:none;fill:rgb(238,238,238);font-size:10.2px;font-family:'Roboto Medium',sans-serif\">142.2</text><path d=\"M 543 342\nA 14 14 330.00 1 1 551 342\nL 547 328\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 533 328\nQ547,363 561,328\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"538\" y=\"333\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">2.3</text><path d=\"M 281 99\nA 14 14 330.00 1 1 289 99\nL 285 85\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 271 85\nQ285,120 299,85\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"272\" y=\"90\" style=\"stroke:none;fill:rgb(70,70,70);font-size:10.2px;font-family:'Roboto Medium',sans-serif\">144.6</text><path d=\"M 412 242\nA 14 14 330.00 1 1 420 242\nL 416 228\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><path d=\"M 402 228\nQ416,263 430,228\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><text x=\"403\" y=\"233\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">24.2</text><path d=\"M 543 261\nA 14 14 330.00 1 1 551 261\nL 547 247\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><path d=\"M 533 247\nQ547,282 561,247\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><text x=\"534\" y=\"252\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">80.8</text><text x=\"93\" y=\"354\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">4.9</text><text x=\"159\" y=\"335\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">23.2</text><text x=\"224\" y=\"333\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">25.6</text><text x=\"290\" y=\"256\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">102.6</text><text x=\"421\" y=\"326\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">32.6</text><text x=\"486\" y=\"338\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">20</text><text x=\"93\" y=\"345\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">9</text><text x=\"159\" y=\"309\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">26.4</text><text x=\"224\" y=\"304\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">28.7</text><text x=\"355\" y=\"93\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">122.2</text><text x=\"421\" y=\"277\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">48.7</text><text x=\"486\" y=\"320\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">18.8</text><text x=\"93\" y=\"264\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">80</text><text x=\"159\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">40.4</text><text x=\"224\" y=\"276\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">28.4</text><text x=\"290\" y=\"82\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">28.8</text><text x=\"355\" y=\"69\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">24.4</text><text x=\"486\" y=\"279\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">40.8</text></svg>",
},
{
name: "stack_series_global_mark_point",
makeOptions: func() LineChartOption {
opt := makeFullLineChartStackedOption()
// add global point configurations
opt.SeriesList[len(opt.SeriesList)-1].MarkPoint.AddGlobalPoints(SeriesMarkTypeMin, SeriesMarkTypeMax)
// disable extra stuff
opt.Padding = NewBox(20, 40, 20, 20)
opt.Legend.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 55 375\nL 125 354\nL 195 351\nL 265 263\nL 335 218\nL 405 343\nL 475 358\nL 545 377\nL 545 380\nL 55 380\nL 55 375\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 55 375\nL 125 354\nL 195 351\nL 265 263\nL 335 218\nL 405 343\nL 475 358\nL 545 377\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"55\" cy=\"375\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"125\" cy=\"354\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"195\" cy=\"351\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"265\" cy=\"263\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"335\" cy=\"218\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"405\" cy=\"343\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"475\" cy=\"358\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"545\" cy=\"377\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 55 365\nL 125 324\nL 195 318\nL 265 98\nL 335 78\nL 405 287\nL 475 336\nL 545 374\nL 545 377\nL 475 358\nL 405 343\nL 335 218\nL 265 263\nL 195 351\nL 125 354\nL 55 375\nL 55 365\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 55 365\nL 125 324\nL 195 318\nL 265 98\nL 335 78\nL 405 287\nL 475 336\nL 545 374\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"55\" cy=\"365\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"125\" cy=\"324\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"195\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"265\" cy=\"98\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"335\" cy=\"78\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"405\" cy=\"287\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"475\" cy=\"336\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"545\" cy=\"374\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 55 273\nL 125 277\nL 195 286\nL 265 65\nL 335 50\nL 405 260\nL 475 289\nL 545 282\nL 545 374\nL 475 336\nL 405 287\nL 335 78\nL 265 98\nL 195 318\nL 125 324\nL 55 365\nL 55 273\" style=\"stroke:none;fill:rgba(250,200,88,0.8)\"/><path d=\"M 55 273\nL 125 277\nL 195 286\nL 265 65\nL 335 50\nL 405 260\nL 475 289\nL 545 282\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"55\" cy=\"273\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"125\" cy=\"277\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"195\" cy=\"286\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"265\" cy=\"65\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"335\" cy=\"50\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"405\" cy=\"260\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"475\" cy=\"289\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"545\" cy=\"282\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><path d=\"M 541 370\nA 14 14 330.00 1 1 549 370\nL 545 356\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 531 356\nQ545,391 559,356\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"536\" y=\"361\" style=\"stroke:none;fill:rgb(238,238,238);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">3.3</text><path d=\"M 331 211\nA 14 14 330.00 1 1 339 211\nL 335 197\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><path d=\"M 321 197\nQ335,232 349,197\nZ\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"322\" y=\"202\" style=\"stroke:none;fill:rgb(238,238,238);font-size:10.2px;font-family:'Roboto Medium',sans-serif\">142.2</text><path d=\"M 541 367\nA 14 14 330.00 1 1 549 367\nL 545 353\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 531 353\nQ545,388 559,353\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"536\" y=\"358\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">2.3</text><path d=\"M 261 91\nA 14 14 330.00 1 1 269 91\nL 265 77\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><path d=\"M 251 77\nQ265,112 279,77\nZ\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"252\" y=\"82\" style=\"stroke:none;fill:rgb(70,70,70);font-size:10.2px;font-family:'Roboto Medium',sans-serif\">144.6</text><path d=\"M 401 253\nA 14 14 330.00 1 1 409 253\nL 405 239\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><path d=\"M 391 239\nQ405,274 419,239\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><text x=\"392\" y=\"244\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">24.2</text><path d=\"M 541 275\nA 14 14 330.00 1 1 549 275\nL 545 261\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><path d=\"M 531 261\nQ545,296 559,261\nZ\" style=\"stroke:none;fill:rgb(250,200,88)\"/><text x=\"532\" y=\"266\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">80.8</text><path d=\"M 471 282\nA 14 14 330.00 1 1 479 282\nL 475 268\nZ\" style=\"stroke:none;fill:rgb(211,211,211)\"/><path d=\"M 461 268\nQ475,303 489,268\nZ\" style=\"stroke:none;fill:rgb(211,211,211)\"/><text x=\"462\" y=\"273\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">79.6</text><path d=\"M 331 43\nA 14 14 330.00 1 1 339 43\nL 335 29\nZ\" style=\"stroke:none;fill:rgb(211,211,211)\"/><path d=\"M 321 29\nQ335,64 349,29\nZ\" style=\"stroke:none;fill:rgb(211,211,211)\"/><text x=\"322\" y=\"34\" style=\"stroke:none;fill:rgb(70,70,70);font-size:10.2px;font-family:'Roboto Medium',sans-serif\">288.8</text><text x=\"60\" y=\"379\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">4.9</text><text x=\"130\" y=\"358\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">23.2</text><text x=\"200\" y=\"355\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">25.6</text><text x=\"270\" y=\"267\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">102.6</text><text x=\"410\" y=\"347\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">32.6</text><text x=\"480\" y=\"362\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">20</text><text x=\"60\" y=\"369\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">9</text><text x=\"130\" y=\"328\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">26.4</text><text x=\"200\" y=\"322\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">28.7</text><text x=\"340\" y=\"82\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">122.2</text><text x=\"410\" y=\"291\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">48.7</text><text x=\"480\" y=\"340\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">18.8</text><text x=\"60\" y=\"277\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">80</text><text x=\"130\" y=\"281\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">40.4</text><text x=\"200\" y=\"290\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">28.4</text><text x=\"270\" y=\"69\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">28.8</text></svg>",
},
{
name: "stack_series_global_mark_line",
makeOptions: func() LineChartOption {
opt := makeFullLineChartStackedOption()
// add global line configurations
opt.SeriesList[len(opt.SeriesList)-1].MarkLine.AddGlobalLines(SeriesMarkTypeAverage,
SeriesMarkTypeMin, SeriesMarkTypeMax)
// disable extra stuff
for i := range opt.SeriesList {
opt.SeriesList[i].MarkPoint = SeriesMarkPoint{}
opt.SeriesList[i].Label.Show = Ptr(false)
}
opt.Padding = NewBox(20, 40, 20, 20)
opt.Legend.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 55 375\nL 125 354\nL 195 351\nL 265 263\nL 335 218\nL 405 343\nL 475 358\nL 545 377\nL 545 380\nL 55 380\nL 55 375\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 55 375\nL 125 354\nL 195 351\nL 265 263\nL 335 218\nL 405 343\nL 475 358\nL 545 377\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"55\" cy=\"375\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"125\" cy=\"354\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"195\" cy=\"351\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"265\" cy=\"263\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"335\" cy=\"218\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"405\" cy=\"343\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"475\" cy=\"358\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"545\" cy=\"377\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 55 365\nL 125 324\nL 195 318\nL 265 98\nL 335 78\nL 405 287\nL 475 336\nL 545 374\nL 545 377\nL 475 358\nL 405 343\nL 335 218\nL 265 263\nL 195 351\nL 125 354\nL 55 375\nL 55 365\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 55 365\nL 125 324\nL 195 318\nL 265 98\nL 335 78\nL 405 287\nL 475 336\nL 545 374\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"55\" cy=\"365\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"125\" cy=\"324\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"195\" cy=\"318\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"265\" cy=\"98\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"335\" cy=\"78\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"405\" cy=\"287\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"475\" cy=\"336\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"545\" cy=\"374\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 55 273\nL 125 277\nL 195 286\nL 265 65\nL 335 50\nL 405 260\nL 475 289\nL 545 282\nL 545 374\nL 475 336\nL 405 287\nL 335 78\nL 265 98\nL 195 318\nL 125 324\nL 55 365\nL 55 273\" style=\"stroke:none;fill:rgba(250,200,88,0.8)\"/><path d=\"M 55 273\nL 125 277\nL 195 286\nL 265 65\nL 335 50\nL 405 260\nL 475 289\nL 545 282\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"55\" cy=\"273\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"125\" cy=\"277\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"195\" cy=\"286\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"265\" cy=\"65\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"335\" cy=\"50\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"405\" cy=\"260\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"475\" cy=\"289\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"545\" cy=\"282\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"23\" cy=\"223\" r=\"3\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 29 223\nL 562 223\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 562 218\nL 578 223\nL 562 228\nL 567 223\nL 562 218\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><text x=\"580\" y=\"227\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">137.86</text><circle cx=\"23\" cy=\"289\" r=\"3\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 29 289\nL 562 289\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 562 284\nL 578 289\nL 562 294\nL 567 289\nL 562 284\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><text x=\"580\" y=\"293\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">79.6</text><circle cx=\"23\" cy=\"50\" r=\"3\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 29 50\nL 562 50\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 562 45\nL 578 50\nL 562 55\nL 567 50\nL 562 45\" style=\"stroke-width:1;stroke:rgb(211,211,211);fill:rgb(211,211,211)\"/><text x=\"580\" y=\"54\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">288.8</text></svg>",
},
{
name: "stack_series_double_yaxis",
makeOptions: func() LineChartOption {
opt := makeFullLineChartStackedOption()
opt.SeriesList[len(opt.SeriesList)-1].YAxisIndex = 1
// disable extra stuff
for i := range opt.SeriesList {
opt.SeriesList[i].MarkLine = SeriesMarkLine{}
opt.SeriesList[i].MarkPoint = SeriesMarkPoint{}
opt.SeriesList[i].Label.Show = Ptr(false)
}
opt.Legend.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"563\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">83</text><text x=\"563\" y=\"65\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">76</text><text x=\"563\" y=\"105\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">69</text><text x=\"563\" y=\"145\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">62</text><text x=\"563\" y=\"185\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">55</text><text x=\"563\" y=\"224\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">48</text><text x=\"563\" y=\"264\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">41</text><text x=\"563\" y=\"304\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">34</text><text x=\"563\" y=\"344\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">27</text><text x=\"563\" y=\"384\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">20</text><text x=\"19\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">270</text><text x=\"19\" y=\"65\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">240</text><text x=\"19\" y=\"105\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">210</text><text x=\"19\" y=\"145\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">180</text><text x=\"19\" y=\"185\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">150</text><text x=\"19\" y=\"224\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">120</text><text x=\"28\" y=\"264\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">90</text><text x=\"28\" y=\"304\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">60</text><text x=\"28\" y=\"344\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">30</text><text x=\"37\" y=\"384\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">0</text><path d=\"M 52 20\nL 553 20\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 60\nL 553 60\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 100\nL 553 100\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 140\nL 553 140\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 180\nL 553 180\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 220\nL 553 220\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 260\nL 553 260\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 300\nL 553 300\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 52 340\nL 553 340\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 87 374\nL 149 350\nL 211 346\nL 273 244\nL 335 191\nL 397 337\nL 459 354\nL 521 376\nL 521 380\nL 87 380\nL 87 374\" style=\"stroke:none;fill:rgba(84,112,198,0.8)\"/><path d=\"M 87 374\nL 149 350\nL 211 346\nL 273 244\nL 335 191\nL 397 337\nL 459 354\nL 521 376\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"87\" cy=\"374\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"149\" cy=\"350\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"211\" cy=\"346\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"273\" cy=\"244\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"335\" cy=\"191\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"397\" cy=\"337\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"459\" cy=\"354\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"521\" cy=\"376\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 87 362\nL 149 314\nL 211 308\nL 273 51\nL 335 28\nL 397 272\nL 459 329\nL 521 373\nL 521 376\nL 459 354\nL 397 337\nL 335 191\nL 273 244\nL 211 346\nL 149 350\nL 87 374\nL 87 362\" style=\"stroke:none;fill:rgba(145,204,117,0.8)\"/><path d=\"M 87 362\nL 149 314\nL 211 308\nL 273 51\nL 335 28\nL 397 272\nL 459 329\nL 521 373\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"87\" cy=\"362\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"149\" cy=\"314\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"211\" cy=\"308\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"273\" cy=\"51\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"335\" cy=\"28\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"397\" cy=\"272\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"459\" cy=\"329\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"521\" cy=\"373\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 87 38\nL 149 264\nL 211 333\nL 273 330\nL 335 355\nL 397 357\nL 459 262\nL 521 33\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"87\" cy=\"38\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"149\" cy=\"264\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"211\" cy=\"333\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"273\" cy=\"330\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"335\" cy=\"355\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"397\" cy=\"357\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"459\" cy=\"262\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"521\" cy=\"33\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/></svg>",
},
{
name: "series_legend_order_sync",
makeOptions: func() LineChartOption {
opt := makeFullLineChartOption()
// set names in weird order, series should shuffle to match legend order
opt.SeriesList[0].Name = opt.Legend.SeriesNames[3]
opt.SeriesList[1].Name = opt.Legend.SeriesNames[4]
opt.SeriesList[2].Name = opt.Legend.SeriesNames[0]
opt.SeriesList[3].Name = opt.Legend.SeriesNames[1]
opt.SeriesList[4].Name = opt.Legend.SeriesNames[2]
opt.SeriesList[4].MarkLine = NewMarkLine("min")
// disable extra stuff
opt.YAxis[0].Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 20 19\nL 50 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"35\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"52\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Email</text><path d=\"M 111 19\nL 141 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"126\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"143\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Union Ads</text><path d=\"M 234 19\nL 264 19\" style=\"stroke-width:3;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"249\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><text x=\"266\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Video Ads</text><path d=\"M 357 19\nL 387 19\" style=\"stroke-width:3;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"372\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><text x=\"389\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Direct</text><path d=\"M 450 19\nL 480 19\" style=\"stroke-width:3;stroke:rgb(115,192,222);fill:none\"/><circle cx=\"465\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(115,192,222);fill:rgb(115,192,222)\"/><text x=\"482\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Search Engine</text><text x=\"10\" y=\"26\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><path d=\"M 51 355\nL 133 335\nL 216 342\nL 299 354\nL 382 345\nL 465 312\nL 548 293\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"51\" cy=\"355\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"133\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"216\" cy=\"342\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"299\" cy=\"354\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"382\" cy=\"345\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"465\" cy=\"312\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"548\" cy=\"293\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 51 314\nL 133 311\nL 216 319\nL 299 311\nL 382 297\nL 465 312\nL 548 314\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"51\" cy=\"314\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"133\" cy=\"311\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"216\" cy=\"319\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"299\" cy=\"311\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"382\" cy=\"297\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"465\" cy=\"312\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"548\" cy=\"314\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><path d=\"M 51 195\nL 133 168\nL 216 175\nL 299 167\nL 382 82\nL 465 73\nL 548 75\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><circle cx=\"51\" cy=\"195\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"133\" cy=\"168\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"216\" cy=\"175\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"299\" cy=\"167\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"382\" cy=\"82\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"465\" cy=\"73\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><circle cx=\"548\" cy=\"75\" r=\"2\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:white\"/><path d=\"M 51 362\nL 133 359\nL 216 366\nL 299 358\nL 382 369\nL 465 336\nL 548 340\" style=\"stroke-width:2;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"51\" cy=\"362\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"133\" cy=\"359\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"216\" cy=\"366\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"299\" cy=\"358\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"382\" cy=\"369\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"465\" cy=\"336\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><circle cx=\"548\" cy=\"340\" r=\"2\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:white\"/><path d=\"M 51 338\nL 133 347\nL 216 345\nL 299 335\nL 382 321\nL 465 312\nL 548 316\" style=\"stroke-width:2;stroke:rgb(115,192,222);fill:none\"/><circle cx=\"51\" cy=\"338\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"133\" cy=\"347\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"216\" cy=\"345\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"299\" cy=\"335\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"382\" cy=\"321\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"465\" cy=\"312\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"548\" cy=\"316\" r=\"2\" style=\"stroke-width:1;stroke:rgb(115,192,222);fill:white\"/><circle cx=\"13\" cy=\"195\" r=\"3\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 19 195\nL 572 195\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 572 190\nL 588 195\nL 572 200\nL 577 195\nL 572 190\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><text x=\"590\" y=\"199\" style=\"stroke:none;fill:rgb(70,70,70);font-size:12.8px;font-family:'Roboto Medium',sans-serif\">820</text></svg>",
},
{
name: "symbol_dot",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Symbol = SymbolDot
opt.Legend.Symbol = SymbolDot
opt.Title.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 19\nL 280 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><text x=\"282\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 19\nL 341 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><text x=\"343\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 51 362\nL 133 359\nL 216 366\nL 299 358\nL 382 369\nL 465 336\nL 548 340\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"51\" cy=\"362\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"133\" cy=\"359\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"216\" cy=\"366\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"299\" cy=\"358\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"382\" cy=\"369\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"465\" cy=\"336\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"548\" cy=\"340\" r=\"3\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path d=\"M 51 195\nL 133 168\nL 216 175\nL 299 167\nL 382 82\nL 465 73\nL 548 75\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"51\" cy=\"195\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"133\" cy=\"168\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"216\" cy=\"175\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"299\" cy=\"167\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"382\" cy=\"82\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"465\" cy=\"73\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"548\" cy=\"75\" r=\"3\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/></svg>",
},
{
name: "symbol_circle",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Symbol = SymbolCircle
opt.Legend.Symbol = SymbolCircle
opt.Title.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 19\nL 280 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"265\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"265\" cy=\"19\" r=\"2\" style=\"stroke-width:3;stroke:white;fill:white\"/><text x=\"282\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 19\nL 341 19\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"326\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><circle cx=\"326\" cy=\"19\" r=\"2\" style=\"stroke-width:3;stroke:white;fill:white\"/><text x=\"343\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 51 362\nL 133 359\nL 216 366\nL 299 358\nL 382 369\nL 465 336\nL 548 340\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"51\" cy=\"362\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"133\" cy=\"359\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"216\" cy=\"366\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"299\" cy=\"358\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"382\" cy=\"369\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"465\" cy=\"336\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"548\" cy=\"340\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 51 195\nL 133 168\nL 216 175\nL 299 167\nL 382 82\nL 465 73\nL 548 75\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"51\" cy=\"195\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"133\" cy=\"168\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"216\" cy=\"175\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"299\" cy=\"167\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"382\" cy=\"82\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"465\" cy=\"73\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"548\" cy=\"75\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
{
name: "symbol_square",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Symbol = SymbolSquare
opt.Legend.Symbol = SymbolSquare
opt.Title.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 250 13\nL 280 13\nL 280 26\nL 250 26\nL 250 13\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"282\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 311 13\nL 341 13\nL 341 26\nL 311 26\nL 311 13\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"343\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 51 362\nL 133 359\nL 216 366\nL 299 358\nL 382 369\nL 465 336\nL 548 340\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 48 359\nL 54 359\nL 54 365\nL 48 365\nL 48 359\nM 130 356\nL 136 356\nL 136 362\nL 130 362\nL 130 356\nM 213 363\nL 219 363\nL 219 369\nL 213 369\nL 213 363\nM 296 355\nL 302 355\nL 302 361\nL 296 361\nL 296 355\nM 379 366\nL 385 366\nL 385 372\nL 379 372\nL 379 366\nM 462 333\nL 468 333\nL 468 339\nL 462 339\nL 462 333\nM 545 337\nL 551 337\nL 551 343\nL 545 343\nL 545 337\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path d=\"M 51 195\nL 133 168\nL 216 175\nL 299 167\nL 382 82\nL 465 73\nL 548 75\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><path d=\"M 48 192\nL 54 192\nL 54 198\nL 48 198\nL 48 192\nM 130 165\nL 136 165\nL 136 171\nL 130 171\nL 130 165\nM 213 172\nL 219 172\nL 219 178\nL 213 178\nL 213 172\nM 296 164\nL 302 164\nL 302 170\nL 296 170\nL 296 164\nM 379 79\nL 385 79\nL 385 85\nL 379 85\nL 379 79\nM 462 70\nL 468 70\nL 468 76\nL 462 76\nL 462 70\nM 545 72\nL 551 72\nL 551 78\nL 545 78\nL 545 72\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/></svg>",
},
{
name: "symbol_diamond",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Symbol = SymbolDiamond
opt.Legend.Symbol = SymbolDiamond
opt.Title.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 255 10\nL 262 20\nL 255 30\nL 248 20\nL 255 10\" style=\"stroke:none;fill:rgb(84,112,198)\"/><text x=\"272\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1</text><path d=\"M 306 10\nL 313 20\nL 306 30\nL 299 20\nL 306 10\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"323\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">2</text><path d=\"M 51 362\nL 133 359\nL 216 366\nL 299 358\nL 382 369\nL 465 336\nL 548 340\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><path d=\"M 51 358\nL 55 362\nL 51 366\nL 47 362\nL 51 358\nM 133 355\nL 137 359\nL 133 363\nL 129 359\nL 133 355\nM 216 362\nL 220 366\nL 216 370\nL 212 366\nL 216 362\nM 299 354\nL 303 358\nL 299 362\nL 295 358\nL 299 354\nM 382 365\nL 386 369\nL 382 373\nL 378 369\nL 382 365\nM 465 332\nL 469 336\nL 465 340\nL 461 336\nL 465 332\nM 548 336\nL 552 340\nL 548 344\nL 544 340\nL 548 336\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><path d=\"M 51 195\nL 133 168\nL 216 175\nL 299 167\nL 382 82\nL 465 73\nL 548 75\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><path d=\"M 51 191\nL 55 195\nL 51 199\nL 47 195\nL 51 191\nM 133 164\nL 137 168\nL 133 172\nL 129 168\nL 133 164\nM 216 171\nL 220 175\nL 216 179\nL 212 175\nL 216 171\nM 299 163\nL 303 167\nL 299 171\nL 295 167\nL 299 163\nM 382 78\nL 386 82\nL 382 86\nL 378 82\nL 382 78\nM 465 69\nL 469 73\nL 465 77\nL 461 73\nL 465 69\nM 548 71\nL 552 75\nL 548 79\nL 544 75\nL 548 71\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/></svg>",
},
{
name: "symbol_mixed",
makeOptions: func() LineChartOption {
opt := makeFullLineChartOption()
opt.XAxis.Labels = opt.XAxis.Labels[:5]
for i := range opt.SeriesList {
opt.SeriesList[i].Values = opt.SeriesList[i].Values[:5]
}
opt.Symbol = SymbolNone
opt.SeriesList[0].Symbol = SymbolCircle
opt.SeriesList[1].Symbol = SymbolSquare
opt.SeriesList[2].Symbol = SymbolDiamond
opt.SeriesList[3].Symbol = SymbolDot
opt.Title.Show = Ptr(false)
opt.XAxis.Show = Ptr(false)
opt.YAxis[0].Show = Ptr(false)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 20 19\nL 50 19\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"35\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(84,112,198);fill:rgb(84,112,198)\"/><circle cx=\"35\" cy=\"19\" r=\"2\" style=\"stroke-width:3;stroke:white;fill:white\"/><text x=\"52\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Email</text><path d=\"M 111 13\nL 141 13\nL 141 26\nL 111 26\nL 111 13\" style=\"stroke:none;fill:rgb(145,204,117)\"/><text x=\"143\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Union Ads</text><path d=\"M 239 10\nL 246 20\nL 239 30\nL 232 20\nL 239 10\" style=\"stroke:none;fill:rgb(250,200,88)\"/><text x=\"256\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Video Ads</text><path d=\"M 347 19\nL 377 19\" style=\"stroke-width:3;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"362\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><text x=\"379\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Direct</text><path d=\"M 440 19\nL 470 19\" style=\"stroke-width:3;stroke:rgb(115,192,222);fill:none\"/><circle cx=\"455\" cy=\"19\" r=\"5\" style=\"stroke-width:3;stroke:rgb(115,192,222);fill:rgb(115,192,222)\"/><text x=\"472\" y=\"25\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Search Engine</text><path d=\"M 68 362\nL 184 359\nL 300 366\nL 416 358\nL 532 369\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"68\" cy=\"362\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"184\" cy=\"359\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"300\" cy=\"366\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"416\" cy=\"358\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"532\" cy=\"369\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 68 338\nL 184 347\nL 300 345\nL 416 335\nL 532 321\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><path d=\"M 65 335\nL 71 335\nL 71 341\nL 65 341\nL 65 335\nM 181 344\nL 187 344\nL 187 350\nL 181 350\nL 181 344\nM 297 342\nL 303 342\nL 303 348\nL 297 348\nL 297 342\nM 413 332\nL 419 332\nL 419 338\nL 413 338\nL 413 332\nM 529 318\nL 535 318\nL 535 324\nL 529 324\nL 529 318\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:rgb(145,204,117)\"/><path d=\"M 68 355\nL 184 335\nL 300 342\nL 416 354\nL 532 345\" style=\"stroke-width:2;stroke:rgb(250,200,88);fill:none\"/><path d=\"M 68 351\nL 72 355\nL 68 359\nL 64 355\nL 68 351\nM 184 331\nL 188 335\nL 184 339\nL 180 335\nL 184 331\nM 300 338\nL 304 342\nL 300 346\nL 296 342\nL 300 338\nM 416 350\nL 420 354\nL 416 358\nL 412 354\nL 416 350\nM 532 341\nL 536 345\nL 532 349\nL 528 345\nL 532 341\" style=\"stroke-width:1;stroke:rgb(250,200,88);fill:rgb(250,200,88)\"/><path d=\"M 68 314\nL 184 311\nL 300 319\nL 416 311\nL 532 297\" style=\"stroke-width:2;stroke:rgb(238,102,102);fill:none\"/><circle cx=\"68\" cy=\"314\" r=\"3\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><circle cx=\"184\" cy=\"311\" r=\"3\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><circle cx=\"300\" cy=\"319\" r=\"3\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><circle cx=\"416\" cy=\"311\" r=\"3\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><circle cx=\"532\" cy=\"297\" r=\"3\" style=\"stroke-width:1;stroke:rgb(238,102,102);fill:rgb(238,102,102)\"/><path d=\"M 68 195\nL 184 168\nL 300 175\nL 416 167\nL 532 82\" style=\"stroke-width:2;stroke:rgb(115,192,222);fill:none\"/></svg>",
},
{
name: "text_color_themes",
makeOptions: func() LineChartOption {
opt := makeFullLineChartOption()
opt.Padding = NewBoxEqual(40)
for i := range opt.SeriesList {
markLine := NewMarkLine(SeriesMarkTypeAverage)
markLine.ValueFormatter = func(f float64) string {
return FormatValueHumanizeShort(f, 0, false)
}
opt.SeriesList[i].MarkLine = markLine
}
opt.Theme = GetTheme(ThemeAnt).WithTitleTextColor(ColorRed).WithLegendTextColor(ColorBlue).
WithYAxisTextColor(ColorGreen).WithXAxisTextColor(ColorAqua).WithMarkTextColor(ColorPurple).
WithLabelTextColor(ColorGold)
opt.SeriesList = opt.SeriesList[:2]
opt.Legend.SeriesNames = opt.Legend.SeriesNames[:2]
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><path d=\"M 204 49\nL 234 49\" style=\"stroke-width:3;stroke:rgb(91,143,249);fill:none\"/><circle cx=\"219\" cy=\"49\" r=\"5\" style=\"stroke-width:3;stroke:rgb(91,143,249);fill:rgb(91,143,249)\"/><text x=\"236\" y=\"55\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Email</text><path d=\"M 295 49\nL 325 49\" style=\"stroke-width:3;stroke:rgb(90,216,166);fill:none\"/><circle cx=\"310\" cy=\"49\" r=\"5\" style=\"stroke-width:3;stroke:rgb(90,216,166);fill:rgb(90,216,166)\"/><text x=\"327\" y=\"55\" style=\"stroke:none;fill:blue;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Union Ads</text><text x=\"40\" y=\"56\" style=\"stroke:none;fill:red;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Line</text><text x=\"39\" y=\"82\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">360</text><text x=\"39\" y=\"110\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">330</text><text x=\"39\" y=\"138\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">300</text><text x=\"39\" y=\"167\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">270</text><text x=\"39\" y=\"195\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">240</text><text x=\"39\" y=\"224\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">210</text><text x=\"39\" y=\"252\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">180</text><text x=\"39\" y=\"281\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">150</text><text x=\"39\" y=\"309\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">120</text><text x=\"48\" y=\"338\" style=\"stroke:none;fill:green;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">90</text><path d=\"M 72 76\nL 560 76\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 104\nL 560 104\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 133\nL 560 133\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 162\nL 560 162\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 190\nL 560 190\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 219\nL 560 219\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 248\nL 560 248\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 276\nL 560 276\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 72 305\nL 560 305\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 76 334\nL 560 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 76 339\nL 76 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 145 339\nL 145 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 214 339\nL 214 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 283 339\nL 283 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 352 339\nL 352 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 421 339\nL 421 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 490 339\nL 490 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 560 339\nL 560 334\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"95\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Mon</text><text x=\"166\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Tue</text><text x=\"233\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Wed</text><text x=\"304\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Thu</text><text x=\"377\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Fri</text><text x=\"444\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sat</text><text x=\"512\" y=\"360\" style=\"stroke:none;fill:aqua;font-size:15.3px;font-family:'Roboto Medium',sans-serif\">Sun</text><path d=\"M 110 306\nL 179 294\nL 248 324\nL 317 292\nL 386 334\nL 455 201\nL 525 220\" style=\"stroke-width:2;stroke:rgb(91,143,249);fill:none\"/><circle cx=\"110\" cy=\"306\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><circle cx=\"179\" cy=\"294\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><circle cx=\"248\" cy=\"324\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><circle cx=\"317\" cy=\"292\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><circle cx=\"386\" cy=\"334\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><circle cx=\"455\" cy=\"201\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><circle cx=\"525\" cy=\"220\" r=\"2\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:white\"/><path d=\"M 110 210\nL 179 247\nL 248 238\nL 317 197\nL 386 143\nL 455 105\nL 525 124\" style=\"stroke-width:2;stroke:rgb(90,216,166);fill:none\"/><circle cx=\"110\" cy=\"210\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"179\" cy=\"247\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"248\" cy=\"238\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"317\" cy=\"197\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"386\" cy=\"143\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"455\" cy=\"105\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"525\" cy=\"124\" r=\"2\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:white\"/><circle cx=\"79\" cy=\"282\" r=\"3\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:rgb(91,143,249)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 85 282\nL 542 282\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:rgb(91,143,249)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 277\nL 558 282\nL 542 287\nL 547 282\nL 542 277\" style=\"stroke-width:1;stroke:rgb(91,143,249);fill:rgb(91,143,249)\"/><text x=\"560\" y=\"286\" style=\"stroke:none;fill:purple;font-size:12.8px;font-family:'Roboto Medium',sans-serif\">145</text><circle cx=\"79\" cy=\"181\" r=\"3\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:rgb(90,216,166)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 85 181\nL 542 181\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:rgb(90,216,166)\"/><path stroke-dasharray=\"4.0, 2.0\" d=\"M 542 176\nL 558 181\nL 542 186\nL 547 181\nL 542 176\" style=\"stroke-width:1;stroke:rgb(90,216,166);fill:rgb(90,216,166)\"/><text x=\"560\" y=\"185\" style=\"stroke:none;fill:purple;font-size:12.8px;font-family:'Roboto Medium',sans-serif\">251</text></svg>",
},
{
name: "axis_titles",
makeOptions: func() LineChartOption {
opt := makeBasicLineChartOption()
opt.Title.Text = ""
opt.Legend.Show = Ptr(false)
opt.XAxis.Title = "x-axis"
opt.XAxis.TitleFontStyle.FontColor = ColorBlue
opt.XAxis.TitleFontStyle.FontSize = 18
opt.SeriesList[1].YAxisIndex = 1
opt.YAxis = append(opt.YAxis, opt.YAxis[0])
opt.YAxis[0].Title = "left y-axis"
opt.YAxis[0].TitleFontStyle.FontColor = ColorBlue
opt.YAxis[0].TitleFontStyle.FontSize = 18
opt.YAxis[0].SpineLineShow = Ptr(true)
opt.YAxis[1].Title = "right y-axis"
opt.YAxis[1].TitleFontStyle.FontColor = ColorBlue
opt.YAxis[1].TitleFontStyle.FontSize = 18
opt.YAxis[1].SpineLineShow = Ptr(true)
return opt
},
result: "<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 600 400\"><path d=\"M 0 0\nL 600 0\nL 600 400\nL 0 400\nL 0 0\" style=\"stroke:none;fill:white\"/><text x=\"573\" y=\"116\" style=\"stroke:none;fill:blue;font-size:23px;font-family:'Roboto Medium',sans-serif\" transform=\"rotate(90.00,573,116)\">right y-axis</text><path d=\"M 515 10\nL 515 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 10\nL 520 10\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 46\nL 520 46\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 82\nL 520 82\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 119\nL 520 119\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 155\nL 520 155\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 191\nL 520 191\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 228\nL 520 228\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 264\nL 520 264\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 300\nL 520 300\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 515 337\nL 520 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"525\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.43k</text><text x=\"525\" y=\"52\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.36k</text><text x=\"525\" y=\"88\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.29k</text><text x=\"525\" y=\"124\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.22k</text><text x=\"525\" y=\"160\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.15k</text><text x=\"525\" y=\"196\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.08k</text><text x=\"525\" y=\"232\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">1.01k</text><text x=\"525\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">940</text><text x=\"525\" y=\"304\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">870</text><text x=\"525\" y=\"341\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">800</text><text x=\"27\" y=\"223\" style=\"stroke:none;fill:blue;font-size:23px;font-family:'Roboto Medium',sans-serif\" transform=\"rotate(270.00,27,223)\">left y-axis</text><path d=\"M 73 10\nL 73 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 10\nL 73 10\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 46\nL 73 46\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 82\nL 73 82\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 119\nL 73 119\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 155\nL 73 155\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 191\nL 73 191\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 228\nL 73 228\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 264\nL 73 264\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 300\nL 73 300\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 68 337\nL 73 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"36\" y=\"16\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">234</text><text x=\"36\" y=\"52\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">218</text><text x=\"36\" y=\"88\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">202</text><text x=\"36\" y=\"124\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">186</text><text x=\"36\" y=\"160\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">170</text><text x=\"36\" y=\"196\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">154</text><text x=\"36\" y=\"232\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">138</text><text x=\"36\" y=\"268\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">122</text><text x=\"36\" y=\"304\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">106</text><text x=\"45\" y=\"341\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">90</text><path d=\"M 69 10\nL 514 10\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 46\nL 514 46\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 82\nL 514 82\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 119\nL 514 119\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 155\nL 514 155\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 191\nL 514 191\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 228\nL 514 228\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 264\nL 514 264\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><path d=\"M 69 300\nL 514 300\" style=\"stroke-width:1;stroke:rgb(224,230,242);fill:none\"/><text x=\"263\" y=\"386\" style=\"stroke:none;fill:blue;font-size:23px;font-family:'Roboto Medium',sans-serif\">x-axis</text><path d=\"M 74 337\nL 514 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 74 342\nL 74 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 136 342\nL 136 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 199 342\nL 199 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 262 342\nL 262 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 325 342\nL 325 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 388 342\nL 388 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 451 342\nL 451 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><path d=\"M 514 342\nL 514 337\" style=\"stroke-width:1;stroke:rgb(110,112,121);fill:none\"/><text x=\"100\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">A</text><text x=\"162\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">B</text><text x=\"225\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">C</text><text x=\"288\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">D</text><text x=\"352\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">E</text><text x=\"415\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">F</text><text x=\"477\" y=\"363\" style=\"stroke:none;fill:rgb(70,70,70);font-size:15.3px;font-family:'Roboto Medium',sans-serif\">G</text><path d=\"M 105 269\nL 167 242\nL 230 313\nL 293 238\nL 356 337\nL 419 20\nL 482 65\" style=\"stroke-width:2;stroke:rgb(84,112,198);fill:none\"/><circle cx=\"105\" cy=\"269\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"167\" cy=\"242\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"230\" cy=\"313\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"293\" cy=\"238\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"356\" cy=\"337\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"419\" cy=\"20\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><circle cx=\"482\" cy=\"65\" r=\"2\" style=\"stroke-width:1;stroke:rgb(84,112,198);fill:white\"/><path d=\"M 105 327\nL 167 269\nL 230 285\nL 293 268\nL 356 83\nL 419 62\nL 482 68\" style=\"stroke-width:2;stroke:rgb(145,204,117);fill:none\"/><circle cx=\"105\" cy=\"327\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"167\" cy=\"269\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"230\" cy=\"285\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"293\" cy=\"268\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"356\" cy=\"83\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"419\" cy=\"62\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/><circle cx=\"482\" cy=\"68\" r=\"2\" style=\"stroke-width:1;stroke:rgb(145,204,117);fill:white\"/></svg>",
},
}
for i, tt := range tests {
painterOptions := PainterOptions{
OutputFormat: ChartOutputSVG,
Width: 600,
Height: 400,
}
if !tt.themed {
t.Run(strconv.Itoa(i)+"-"+tt.name, func(t *testing.T) {
p := NewPainter(painterOptions)
validateLineChartRender(t, p, tt.makeOptions(), tt.result)
})
} else {
theme := GetTheme(ThemeVividDark)
t.Run(strconv.Itoa(i)+"-"+tt.name+"-theme_painter", func(t *testing.T) {
p := NewPainter(painterOptions, PainterThemeOption(theme))
validateLineChartRender(t, p, tt.makeOptions(), tt.result)
})
t.Run(strconv.Itoa(i)+"-"+tt.name+"-theme_opt", func(t *testing.T) {
p := NewPainter(painterOptions)
opt := tt.makeOptions()
opt.Theme = theme
validateLineChartRender(t, p, opt, tt.result)
})
}
}
}
func validateLineChartRender(t *testing.T, p *Painter, opt LineChartOption, expectedResult string) {
t.Helper()
err := p.LineChart(opt)
require.NoError(t, err)
data, err := p.Bytes()
require.NoError(t, err)
assertEqualSVG(t, expectedResult, data)
}
func TestLineChartError(t *testing.T) {
t.Parallel()
tests := []struct {
name string
makeOptions func() LineChartOption
errorMsgContains string
}{
{
name: "empty_series",
makeOptions: func() LineChartOption {
return NewLineChartOptionWithData([][]float64{})
},
errorMsgContains: "empty series list",
},
}
for i, tt := range tests {
t.Run(strconv.Itoa(i)+"-"+tt.name, func(t *testing.T) {
p := NewPainter(PainterOptions{
OutputFormat: ChartOutputSVG,
Width: 600,
Height: 400,
})
err := p.LineChart(tt.makeOptions())
require.Error(t, err)
require.ErrorContains(t, err, tt.errorMsgContains)
})
}
}