• 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. let chartConfig = {
    17. type: 'gauge',
    18. scaleR: {
    19. markers: [{
    20. type: 'area',
    21. range: [10, 30],
    22.  
    23. alpha: 1,
    24. backgroundColor: '#ff4d4d',
    25. borderColor: 'red',
    26. borderWidth: 1,
    27. offsetEnd: 0.1,
    28. offsetStart: 0.5,
    29.  
    30. label: {
    31. text: 'Area Marker',
    32.  
    33. alpha: 1,
    34. angle: 0,
    35. backgroundColor: '#ffe6e6',
    36. borderColor: 'red',
    37. borderRadius: '3px',
    38. borderWidth: 1,
    39. fontColor: 'red',
    40. fontFamily: 'Courier',
    41. fontSize: 10,
    42. fontStyle: 'normal',
    43. fontWeight: 'normal',
    44. lineStyle: 'solid',
    45. offsetR: 50,
    46. padding: 5,
    47. textAlign: 'left',
    48. textAlpha: 1,
    49. width: '100%'
    50. }
    51. },
    52. {
    53. type: 'line',
    54. range: [70],
    55.  
    56. alpha: 1,
    57. lineColor: 'red',
    58. lineStyle: 'solid',
    59. lineWidth: 3,
    60.  
    61. label: {
    62. text: 'Line Marker',
    63.  
    64. alpha: 1,
    65. angle: 0,
    66. backgroundColor: '#ffe6e6',
    67. borderColor: 'red',
    68. borderRadius: '3px',
    69. borderWidth: 1,
    70. fontColor: 'red',
    71. fontFamily: 'Courier',
    72. fontSize: 10,
    73. fontStyle: 'normal',
    74. fontWeight: 'normal',
    75. lineStyle: 'solid',
    76. offsetR: -5,
    77. padding: 5,
    78. textAlign: 'left',
    79. textAlpha: 1,
    80. width: '100%',
    81. }
    82. }
    83. ],
    84. values: '0:90:10'
    85. },
    86. series: [{
    87. values: [35]
    88. }]
    89. };
    90.  
    91. zingchart.render({
    92. id: 'myChart',
    93. data: chartConfig,
    94. height: 400,
    95. width: '100%'
    96. });
    97. </script>
    98. </body>
    99.  
    100. </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. let chartConfig = {
    2. type: 'gauge',
    3. scaleR: {
    4. markers: [{
    5. type: 'area',
    6. range: [10, 30],
    7.  
    8. alpha: 1,
    9. backgroundColor: '#ff4d4d',
    10. borderColor: 'red',
    11. borderWidth: 1,
    12. offsetEnd: 0.1,
    13. offsetStart: 0.5,
    14.  
    15. label: {
    16. text: 'Area Marker',
    17.  
    18. alpha: 1,
    19. angle: 0,
    20. backgroundColor: '#ffe6e6',
    21. borderColor: 'red',
    22. borderRadius: '3px',
    23. borderWidth: 1,
    24. fontColor: 'red',
    25. fontFamily: 'Courier',
    26. fontSize: 10,
    27. fontStyle: 'normal',
    28. fontWeight: 'normal',
    29. lineStyle: 'solid',
    30. offsetR: 50,
    31. padding: 5,
    32. textAlign: 'left',
    33. textAlpha: 1,
    34. width: '100%'
    35. }
    36. },
    37. {
    38. type: 'line',
    39. range: [70],
    40.  
    41. alpha: 1,
    42. lineColor: 'red',
    43. lineStyle: 'solid',
    44. lineWidth: 3,
    45.  
    46. label: {
    47. text: 'Line Marker',
    48.  
    49. alpha: 1,
    50. angle: 0,
    51. backgroundColor: '#ffe6e6',
    52. borderColor: 'red',
    53. borderRadius: '3px',
    54. borderWidth: 1,
    55. fontColor: 'red',
    56. fontFamily: 'Courier',
    57. fontSize: 10,
    58. fontStyle: 'normal',
    59. fontWeight: 'normal',
    60. lineStyle: 'solid',
    61. offsetR: -5,
    62. padding: 5,
    63. textAlign: 'left',
    64. textAlpha: 1,
    65. width: '100%',
    66. }
    67. }
    68. ],
    69. values: '0:90:10'
    70. },
    71. series: [{
    72. values: [35]
    73. }]
    74. };
    75.  
    76. zingchart.render({
    77. id: 'myChart',
    78. data: chartConfig,
    79. height: 400,
    80. width: '100%'
    81. });