• 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/2.5.2/zingchart.min.js"></script>
    9. <style>
    10. html,
    11. body {
    12. height: 100%;
    13. width: 100%;
    14. margin: 0;
    15. padding: 0;
    16. }
    17.  
    18. #myChart {
    19. height: 100%;
    20. width: 100%;
    21. min-height: 150px;
    22. }
    23. </style>
    24. </head>
    25.  
    26. <body>
    27. <div id='myChart'></div>
    28. <script>
    29. var myConfig = {
    30. type: "bar",
    31. plot: {
    32. selectedState: {
    33. backgroundColor: 'green'
    34. },
    35. },
    36. series: [{
    37. dataIgnoreSelection: true,
    38. values: [35, 25, 15, 41, 2, 45, 14, 65, 40],
    39. },
    40. {
    41. values: [89, 40, 56, 78, 15, 10, 40, 45, 5]
    42. }
    43. ]
    44. };
    45.  
    46. // Load the selection-tool and render the charts once its loaded
    47. zingchart.loadModules('selection-tool', function() {
    48. zingchart.render({
    49. id: 'myChart',
    50. data: myConfig,
    51. height: 400,
    52. width: '100%',
    53. modules: 'selection-tool'
    54. });
    55. });
    56. </script>
    57. </body>
    58.  
    59. </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/2.5.2/zingchart.min.js"></script>
    9. </head>
    10.  
    11. <body>
    12. <div id='myChart'></div>
    13. </body>
    14.  
    15. </html>
    1. html,
    2. body {
    3. height: 100%;
    4. width: 100%;
    5. margin: 0;
    6. padding: 0;
    7. }
    8.  
    9. #myChart {
    10. height: 100%;
    11. width: 100%;
    12. min-height: 150px;
    13. }
    1. var myConfig = {
    2. type: "bar",
    3. plot: {
    4. selectedState: {
    5. backgroundColor: 'green'
    6. },
    7. },
    8. series: [{
    9. dataIgnoreSelection: true,
    10. values: [35, 25, 15, 41, 2, 45, 14, 65, 40],
    11. },
    12. {
    13. values: [89, 40, 56, 78, 15, 10, 40, 45, 5]
    14. }
    15. ]
    16. };
    17.  
    18. // Load the selection-tool and render the charts once its loaded
    19. zingchart.loadModules('selection-tool', function() {
    20. zingchart.render({
    21. id: 'myChart',
    22. data: myConfig,
    23. height: 400,
    24. width: '100%',
    25. modules: 'selection-tool'
    26. });
    27. });