• 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: "line",
    18. arrows: [{
    19. backgroundColor: "red",
    20. alpha: 0.7,
    21. direction: "top", //location of node in relation to end of arrow
    22. length: 75, //length of arrow
    23. mediaRules: [{
    24. maxWidth: 400,
    25. backgroundColor: 'blue',
    26. }],
    27. to: { //either to or from are required, but not both
    28. hook: "node:plot=0,index=4" //hooks or x,y postions can be used
    29. },
    30. label: {
    31. text: "Look Here",
    32. bold: true,
    33. backgroundColor: "none",
    34. borderWidth: 0,
    35. fontAngle: 90,
    36. offsetX: -10,
    37. offsetY: 8
    38. }
    39. },
    40. {
    41. backgroundColor: "green",
    42. alpha: 0.2,
    43. borderAlpha: 1,
    44. from: {
    45. hook: "node:plot=1,index=4"
    46. },
    47. to: {
    48. hook: "node:plot=1,index=7"
    49. }
    50. }
    51. ],
    52. series: [{
    53. "values": [182, 155, 161, 125, 95, 150, 140, 150, 173, 147, 208, 136]
    54. },
    55. {
    56. "values": [243, 189, 213, 190, 267, 226, 245, 294, 220, 255, 107, 192]
    57. },
    58. ]
    59. };
    60.  
    61. zingchart.render({
    62. id: 'myChart',
    63. data: chartConfig,
    64. height: 400,
    65. width: '100%'
    66. });
    67. </script>
    68. </body>
    69.  
    70. </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: "line",
    3. arrows: [{
    4. backgroundColor: "red",
    5. alpha: 0.7,
    6. direction: "top", //location of node in relation to end of arrow
    7. length: 75, //length of arrow
    8. mediaRules: [{
    9. maxWidth: 400,
    10. backgroundColor: 'blue',
    11. }],
    12. to: { //either to or from are required, but not both
    13. hook: "node:plot=0,index=4" //hooks or x,y postions can be used
    14. },
    15. label: {
    16. text: "Look Here",
    17. bold: true,
    18. backgroundColor: "none",
    19. borderWidth: 0,
    20. fontAngle: 90,
    21. offsetX: -10,
    22. offsetY: 8
    23. }
    24. },
    25. {
    26. backgroundColor: "green",
    27. alpha: 0.2,
    28. borderAlpha: 1,
    29. from: {
    30. hook: "node:plot=1,index=4"
    31. },
    32. to: {
    33. hook: "node:plot=1,index=7"
    34. }
    35. }
    36. ],
    37. series: [{
    38. "values": [182, 155, 161, 125, 95, 150, 140, 150, 173, 147, 208, 136]
    39. },
    40. {
    41. "values": [243, 189, 213, 190, 267, 226, 245, 294, 220, 255, 107, 192]
    42. },
    43. ]
    44. };
    45.  
    46. zingchart.render({
    47. id: 'myChart',
    48. data: chartConfig,
    49. height: 400,
    50. width: '100%'
    51. });