• 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>
    10. #myChart {
    11. width: 100%;
    12. height: 100%;
    13. }
    14.  
    15. #customTooltip {
    16. position: absolute;
    17. background-color: black;
    18. color: white;
    19. width: 100px;
    20. height: 100px;
    21. }
    22. </style>
    23. </head>
    24.  
    25. <body>
    26. <div id='myChart'></div>
    27. <script>
    28. ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "b55b025e438fa8a98e32482b5f768ff5"];
    29. var myConfig = {
    30. type: "line",
    31. guide: {
    32. plotLabel: {
    33. text: '%t - %kl Value: %v',
    34. borderWidth: 2,
    35. bold: true,
    36.  
    37. mediaRules: [{
    38. maxWidth: 400,
    39. backgroundColor: 'red'
    40. }]
    41. }
    42. },
    43. plot: {
    44. tooltip: {
    45. visible: false
    46. }
    47. },
    48. scaleX: {
    49. labels: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug"]
    50. },
    51. series: [{
    52. values: [26, 35, 34, 10, 16, 38, 45, 35],
    53. text: 'Series 1'
    54. },
    55. {
    56. values: [50, 27, 42, 55, 35, 57, 60, 30],
    57. text: 'Series 2'
    58. }
    59. ]
    60. };
    61.  
    62. zingchart.render({
    63. id: 'myChart',
    64. data: myConfig,
    65. height: 400,
    66. width: "100%"
    67. });
    68. </script>
    69. </body>
    70.  
    71. </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. #myChart {
    2. width: 100%;
    3. height: 100%;
    4. }
    5.  
    6. #customTooltip {
    7. position: absolute;
    8. background-color: black;
    9. color: white;
    10. width: 100px;
    11. height: 100px;
    12. }
    1. var myConfig = {
    2. type: "line",
    3. guide: {
    4. plotLabel: {
    5. text: '%t - %kl Value: %v',
    6. borderWidth: 2,
    7. bold: true,
    8.  
    9. mediaRules: [{
    10. maxWidth: 400,
    11. backgroundColor: 'red'
    12. }]
    13. }
    14. },
    15. plot: {
    16. tooltip: {
    17. visible: false
    18. }
    19. },
    20. scaleX: {
    21. labels: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug"]
    22. },
    23. series: [{
    24. values: [26, 35, 34, 10, 16, 38, 45, 35],
    25. text: 'Series 1'
    26. },
    27. {
    28. values: [50, 27, 42, 55, 35, 57, 60, 30],
    29. text: 'Series 2'
    30. }
    31. ]
    32. };
    33.  
    34. zingchart.render({
    35. id: 'myChart',
    36. data: myConfig,
    37. height: 400,
    38. width: "100%"
    39. });