• Edit
  • Download
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7. <script nonce="undefined" src="https://cdn.zingchart.com/zingchart.min.js"></script>
    8. <style>
    9. html,
    10. body {
    11. margin: 0;
    12. padding: 0;
    13. width: 100%;
    14. height: 100%;
    15. }
    16.  
    17. .chart--container {
    18. min-height: 150px;
    19. width: 100%;
    20. height: 100%;
    21. }
    22.  
    23. .zc-ref {
    24. display: none;
    25. }
    26. </style>
    27. </head>
    28.  
    29. <body>
    30. <!-- CHART CONTAINER -->
    31. <div id="myChart" class="chart--container">
    32. <a class="zc-ref" href="https://www.zingchart.com/">Powered by ZingChart</a>
    33. </div>
    34. <script>
    35. ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "b55b025e438fa8a98e32482b5f768ff5"];
    36. window.addEventListener('load', () => {
    37.  
    38. let chartConfig = {
    39. type: 'scorecard',
    40. options: {
    41. value: {
    42. text: '1,000'
    43. },
    44. title: {
    45. text: 'ZingPoints'
    46. },
    47. bars: [{
    48. text: 'Christopher',
    49. value: '675',
    50. tooltip: {
    51. backgroundColor: 'red',
    52. backgroundColor: '#f90',
    53. borderColor: '#f60',
    54. borderRadius: -5,
    55. borderWidth: 2,
    56. callout: true,
    57. calloutHeight: 20,
    58. calloutPosition: 'bottom',
    59. calloutWidth: 0,
    60. padding: 10,
    61. shadow: true,
    62. calloutTip: {
    63. type: 'circle',
    64. backgroundColor: '#fff',
    65. borderWidth: 2,
    66. borderColor: '#f60',
    67. size: 5,
    68. offsetY: 0
    69. }
    70. }
    71. },
    72. {
    73. text: 'Aaron',
    74. value: '50'
    75. },
    76. {
    77. text: 'Nick',
    78. value: '275'
    79. }
    80. ]
    81. }
    82. };
    83.  
    84. // render chart
    85. zingchart.render({
    86. id: 'myChart',
    87. data: chartConfig,
    88. height: '80px',
    89. width: '100%',
    90. });
    91. });
    92. </script>
    93. </body>
    94.  
    95. </html>
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7. <script src="https://cdn.zingchart.com/zingchart.min.js"></script>
    8. </head>
    9.  
    10. <body>
    11. <!-- CHART CONTAINER -->
    12. <div id="myChart" class="chart--container">
    13. <a class="zc-ref" href="https://www.zingchart.com/">Powered by ZingChart</a>
    14. </div>
    15. </body>
    16.  
    17. </html>
    1. html,
    2. body {
    3. margin: 0;
    4. padding: 0;
    5. width: 100%;
    6. height: 100%;
    7. }
    8.  
    9. .chart--container {
    10. min-height: 150px;
    11. width: 100%;
    12. height: 100%;
    13. }
    14.  
    15. .zc-ref {
    16. display: none;
    17. }
    1. window.addEventListener('load', () => {
    2.  
    3. let chartConfig = {
    4. type: 'scorecard',
    5. options: {
    6. value: {
    7. text: '1,000'
    8. },
    9. title: {
    10. text: 'ZingPoints'
    11. },
    12. bars: [{
    13. text: 'Christopher',
    14. value: '675',
    15. tooltip: {
    16. backgroundColor: 'red',
    17. backgroundColor: '#f90',
    18. borderColor: '#f60',
    19. borderRadius: -5,
    20. borderWidth: 2,
    21. callout: true,
    22. calloutHeight: 20,
    23. calloutPosition: 'bottom',
    24. calloutWidth: 0,
    25. padding: 10,
    26. shadow: true,
    27. calloutTip: {
    28. type: 'circle',
    29. backgroundColor: '#fff',
    30. borderWidth: 2,
    31. borderColor: '#f60',
    32. size: 5,
    33. offsetY: 0
    34. }
    35. }
    36. },
    37. {
    38. text: 'Aaron',
    39. value: '50'
    40. },
    41. {
    42. text: 'Nick',
    43. value: '275'
    44. }
    45. ]
    46. }
    47. };
    48.  
    49. // render chart
    50. zingchart.render({
    51. id: 'myChart',
    52. data: chartConfig,
    53. height: '80px',
    54. width: '100%',
    55. });
    56. });