• 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. var myConfig = {
    17. "type": "pie",
    18. "title": {
    19. "text": "Legend Minimization"
    20. },
    21. "subtitle": {
    22. "text": "Minimize the legend.",
    23. "font-weight": "normal"
    24. },
    25. "legend": {
    26. "minimize": true, //automatically adds header
    27. "icon": {
    28. "line-color": "red"
    29. },
    30. "header": {
    31. "background-color": "#ffe6e6",
    32. "border-left": "1px solid red",
    33. "border-right": "1px solid red",
    34. "border-top": "1px solid red",
    35. "border-bottom": "1px solid red"
    36. },
    37. "x": "75%",
    38. "y": "25%"
    39. },
    40. "plotarea": {
    41. "margin-right": "30%",
    42. "margin-top": "15%"
    43. },
    44. "plot": {
    45. "value-box": {
    46. "font-size": 11,
    47. "font-weight": "normal",
    48. "offset-r": "50%"
    49. }
    50. },
    51. "series": [{
    52. "values": [234]
    53. },
    54. {
    55. "values": [121]
    56. },
    57. {
    58. "values": [77]
    59. },
    60. {
    61. "values": [65]
    62. },
    63. {
    64. "values": [59]
    65. },
    66. {
    67. "values": [35]
    68. },
    69. {
    70. "values": [34]
    71. },
    72. {
    73. "values": [31]
    74. },
    75. {
    76. "values": [16]
    77. },
    78. {
    79. "values": [14]
    80. }
    81. ]
    82. };
    83.  
    84. zingchart.render({
    85. id: 'myChart',
    86. data: myConfig,
    87. height: 400,
    88. width: "100%"
    89. });
    90. </script>
    91. </body>
    92.  
    93. </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. var myConfig = {
    2. "type": "pie",
    3. "title": {
    4. "text": "Legend Minimization"
    5. },
    6. "subtitle": {
    7. "text": "Minimize the legend.",
    8. "font-weight": "normal"
    9. },
    10. "legend": {
    11. "minimize": true, //automatically adds header
    12. "icon": {
    13. "line-color": "red"
    14. },
    15. "header": {
    16. "background-color": "#ffe6e6",
    17. "border-left": "1px solid red",
    18. "border-right": "1px solid red",
    19. "border-top": "1px solid red",
    20. "border-bottom": "1px solid red"
    21. },
    22. "x": "75%",
    23. "y": "25%"
    24. },
    25. "plotarea": {
    26. "margin-right": "30%",
    27. "margin-top": "15%"
    28. },
    29. "plot": {
    30. "value-box": {
    31. "font-size": 11,
    32. "font-weight": "normal",
    33. "offset-r": "50%"
    34. }
    35. },
    36. "series": [{
    37. "values": [234]
    38. },
    39. {
    40. "values": [121]
    41. },
    42. {
    43. "values": [77]
    44. },
    45. {
    46. "values": [65]
    47. },
    48. {
    49. "values": [59]
    50. },
    51. {
    52. "values": [35]
    53. },
    54. {
    55. "values": [34]
    56. },
    57. {
    58. "values": [31]
    59. },
    60. {
    61. "values": [16]
    62. },
    63. {
    64. "values": [14]
    65. }
    66. ]
    67. };
    68.  
    69. zingchart.render({
    70. id: 'myChart',
    71. data: myConfig,
    72. height: 400,
    73. width: "100%"
    74. });