• 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: [20, 40],
    22. mediaRules: [{
    23. maxWidth: 400,
    24. backgroundColor: 'blue'
    25. }],
    26.  
    27. alpha: 1,
    28. backgroundColor: '#ff4d4d',
    29. borderColor: 'red',
    30. borderWidth: 1,
    31. offsetEnd: 0.1,
    32. offsetStart: 0.5
    33. },
    34. {
    35. type: 'line',
    36. range: [60],
    37. mediaRules: [{
    38. maxWidth: 400,
    39. lineColor: 'blue'
    40. }],
    41.  
    42. alpha: 1,
    43. lineColor: 'red',
    44. lineStyle: 'solid',
    45. lineWidth: 3
    46. }
    47. ],
    48. values: '0:90:10'
    49. },
    50. series: [{
    51. values: [35]
    52. }]
    53. };
    54.  
    55. zingchart.render({
    56. id: 'myChart',
    57. data: chartConfig,
    58. height: 400,
    59. width: '100%'
    60. });
    61. </script>
    62. </body>
    63.  
    64. </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: [20, 40],
    7. mediaRules: [{
    8. maxWidth: 400,
    9. backgroundColor: 'blue'
    10. }],
    11.  
    12. alpha: 1,
    13. backgroundColor: '#ff4d4d',
    14. borderColor: 'red',
    15. borderWidth: 1,
    16. offsetEnd: 0.1,
    17. offsetStart: 0.5
    18. },
    19. {
    20. type: 'line',
    21. range: [60],
    22. mediaRules: [{
    23. maxWidth: 400,
    24. lineColor: 'blue'
    25. }],
    26.  
    27. alpha: 1,
    28. lineColor: 'red',
    29. lineStyle: 'solid',
    30. lineWidth: 3
    31. }
    32. ],
    33. values: '0:90:10'
    34. },
    35. series: [{
    36. values: [35]
    37. }]
    38. };
    39.  
    40. zingchart.render({
    41. id: 'myChart',
    42. data: chartConfig,
    43. height: 400,
    44. width: '100%'
    45. });