• Edit
  • Download
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7.  
    8. <script nonce="undefined" src="https://cdn.zingchart.com/zingchart.min.js"></script>
    9. <style></style>
    10. </head>
    11.  
    12. <body>
    13. <div id='myChart'></div>
    14. <script>
    15. ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "b55b025e438fa8a98e32482b5f768ff5"];
    16. let chartConfig = {
    17. type: 'area',
    18. legend: {},
    19. series: [{
    20. values: [
    21. [1, 22],
    22. [1.5, 34],
    23. [2, 55],
    24. [2.5, 71],
    25. [3, 42],
    26. [3.5, 39],
    27. [4, 50],
    28. [4.5, 70]
    29. ],
    30. lineColor: '#E91E63',
    31. backgroundColor: '#7986CB',
    32. marker: {
    33. backgroundColor: '#FCE4EC',
    34. borderColor: '#E91E63',
    35. borderWidth: 1,
    36. size: 5,
    37. type: 'star9',
    38. },
    39.  
    40. legendItem: {
    41. fontColor: '#3F51B5',
    42. fontFamily: 'Georgia',
    43. fontSize: 12,
    44. mediaRules: [{
    45. maxWidth: 400,
    46. fontColor: 'red'
    47. }]
    48. },
    49. legendMarker: {
    50. backgroundColor: '#FCE4EC',
    51. borderColor: '#E91E63',
    52. borderWidth: 1,
    53. size: 6,
    54. type: 'star9',
    55. }
    56. },
    57. {
    58. values: [
    59. [5.5, 35],
    60. [6, 42],
    61. [6.5, 67],
    62. [7, 89],
    63. [7.5, 25],
    64. [8, 34],
    65. [8.5, 67],
    66. [9, 85]
    67. ],
    68. lineColor: '#9C27B0',
    69. backgroundColor: '#64B5F6',
    70. marker: {
    71. backgroundColor: '#F3E5F5',
    72. borderColor: '#9C27B0',
    73. borderWidth: 1,
    74. size: 4,
    75. type: 'gear9',
    76. },
    77.  
    78. legendItem: {
    79. fontColor: '#2196F3',
    80. fontFamily: 'Georgia',
    81. fontSize: 12,
    82. mediaRules: [{
    83. maxWidth: 400,
    84. fontColor: 'purple'
    85. }]
    86. },
    87. legendMarker: {
    88. backgroundColor: '#F3E5F5',
    89. borderColor: '#9C27B0',
    90. borderWidth: 1,
    91. size: 5,
    92. type: 'gear9',
    93. }
    94. }
    95. ]
    96. };
    97.  
    98. zingchart.render({
    99. id: 'myChart',
    100. data: chartConfig,
    101. height: 400,
    102. width: '100%'
    103. });
    104. </script>
    105. </body>
    106.  
    107. </html>
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7.  
    8. <script src="https://cdn.zingchart.com/zingchart.min.js"></script>
    9. </head>
    10.  
    11. <body>
    12. <div id='myChart'></div>
    13. </body>
    14.  
    15. </html>
    1.  
    1. let chartConfig = {
    2. type: 'area',
    3. legend: {},
    4. series: [{
    5. values: [
    6. [1, 22],
    7. [1.5, 34],
    8. [2, 55],
    9. [2.5, 71],
    10. [3, 42],
    11. [3.5, 39],
    12. [4, 50],
    13. [4.5, 70]
    14. ],
    15. lineColor: '#E91E63',
    16. backgroundColor: '#7986CB',
    17. marker: {
    18. backgroundColor: '#FCE4EC',
    19. borderColor: '#E91E63',
    20. borderWidth: 1,
    21. size: 5,
    22. type: 'star9',
    23. },
    24.  
    25. legendItem: {
    26. fontColor: '#3F51B5',
    27. fontFamily: 'Georgia',
    28. fontSize: 12,
    29. mediaRules: [{
    30. maxWidth: 400,
    31. fontColor: 'red'
    32. }]
    33. },
    34. legendMarker: {
    35. backgroundColor: '#FCE4EC',
    36. borderColor: '#E91E63',
    37. borderWidth: 1,
    38. size: 6,
    39. type: 'star9',
    40. }
    41. },
    42. {
    43. values: [
    44. [5.5, 35],
    45. [6, 42],
    46. [6.5, 67],
    47. [7, 89],
    48. [7.5, 25],
    49. [8, 34],
    50. [8.5, 67],
    51. [9, 85]
    52. ],
    53. lineColor: '#9C27B0',
    54. backgroundColor: '#64B5F6',
    55. marker: {
    56. backgroundColor: '#F3E5F5',
    57. borderColor: '#9C27B0',
    58. borderWidth: 1,
    59. size: 4,
    60. type: 'gear9',
    61. },
    62.  
    63. legendItem: {
    64. fontColor: '#2196F3',
    65. fontFamily: 'Georgia',
    66. fontSize: 12,
    67. mediaRules: [{
    68. maxWidth: 400,
    69. fontColor: 'purple'
    70. }]
    71. },
    72. legendMarker: {
    73. backgroundColor: '#F3E5F5',
    74. borderColor: '#9C27B0',
    75. borderWidth: 1,
    76. size: 5,
    77. type: 'gear9',
    78. }
    79. }
    80. ]
    81. };
    82.  
    83. zingchart.render({
    84. id: 'myChart',
    85. data: chartConfig,
    86. height: 400,
    87. width: '100%'
    88. });