• 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": "nestedpie",
    18. "title": {
    19. "text": "Tooltips"
    20. },
    21. "plot": {
    22. "tooltip": {
    23. "text": "Ages %t: %v",
    24. "font-color": "black",
    25. "font-family": "Georgia",
    26. "font-size": 12,
    27. "background-color": "white",
    28. "border-width": 1,
    29. "border-color": "gray",
    30. "border-radius": "3px",
    31. "line-style": "dashdot",
    32. "padding": "10%",
    33. "text-alpha": 1,
    34. "alpha": 0.7
    35. },
    36. "value-box": {
    37. "visible": false
    38. },
    39. "alpha": 0.8,
    40. "shadow": false,
    41. "border-width": 1,
    42. "border-color": "white",
    43. "slice-start": "30%",
    44. },
    45. "series": [{
    46. "values": [59, 55, 30],
    47. "background-color": "orange red",
    48. "text": "0-18"
    49. },
    50. {
    51. "values": [60, 50, 35],
    52. "background-color": "yellow orange",
    53. "text": "19-30"
    54. },
    55. {
    56. "values": [50, 40, 30],
    57. "background-color": "green blue",
    58. "text": "31-34"
    59. },
    60. {
    61. "values": [61, 59, 35],
    62. "background-color": "blue purple",
    63. "text": "46-64"
    64. },
    65. {
    66. "values": [65, 55, 45],
    67. "background-color": "purple red",
    68. "text": "65 and over"
    69. }
    70. ]
    71. };
    72.  
    73. zingchart.render({
    74. id: 'myChart',
    75. data: myConfig,
    76. height: 400,
    77. width: "100%"
    78. });
    79. </script>
    80. </body>
    81.  
    82. </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": "nestedpie",
    3. "title": {
    4. "text": "Tooltips"
    5. },
    6. "plot": {
    7. "tooltip": {
    8. "text": "Ages %t: %v",
    9. "font-color": "black",
    10. "font-family": "Georgia",
    11. "font-size": 12,
    12. "background-color": "white",
    13. "border-width": 1,
    14. "border-color": "gray",
    15. "border-radius": "3px",
    16. "line-style": "dashdot",
    17. "padding": "10%",
    18. "text-alpha": 1,
    19. "alpha": 0.7
    20. },
    21. "value-box": {
    22. "visible": false
    23. },
    24. "alpha": 0.8,
    25. "shadow": false,
    26. "border-width": 1,
    27. "border-color": "white",
    28. "slice-start": "30%",
    29. },
    30. "series": [{
    31. "values": [59, 55, 30],
    32. "background-color": "orange red",
    33. "text": "0-18"
    34. },
    35. {
    36. "values": [60, 50, 35],
    37. "background-color": "yellow orange",
    38. "text": "19-30"
    39. },
    40. {
    41. "values": [50, 40, 30],
    42. "background-color": "green blue",
    43. "text": "31-34"
    44. },
    45. {
    46. "values": [61, 59, 35],
    47. "background-color": "blue purple",
    48. "text": "46-64"
    49. },
    50. {
    51. "values": [65, 55, 45],
    52. "background-color": "purple red",
    53. "text": "65 and over"
    54. }
    55. ]
    56. };
    57.  
    58. zingchart.render({
    59. id: 'myChart',
    60. data: myConfig,
    61. height: 400,
    62. width: "100%"
    63. });