Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 

193 righe
8.4 KiB

  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>Frappe Charts</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1">
  7. <meta name="keywords" content="open source javascript js charts library svg zero-dependency interactive data visualization beautiful drag resize">
  8. <meta name="description" content="A simple, responsive, modern charts library for the web.">
  9. <link rel="stylesheet" type="text/css" href="assets/css/normalize.css" media="screen">
  10. <!--<link href='https://fonts.googleapis.com/css?family=Roboto:400,700' rel='stylesheet' type='text/css'>-->
  11. <link rel="stylesheet" type="text/css" href="assets/css/bootstrap.min.css" media="screen">
  12. <link rel="stylesheet" type="text/css" href="assets/css/frappe_theme.css" media="screen">
  13. <link rel="stylesheet" type="text/css" href="assets/css/index.css" media="screen">
  14. <link rel="stylesheet" type="text/css" href="assets/css/default.css" media="screen">
  15. <link rel="stylesheet" type="text/css" href="../src/charts.css" media="screen">
  16. <script src="assets/js/highlight.pack.js"></script>
  17. <script>hljs.initHighlightingOnLoad();</script>
  18. <!--<link rel="shortcut icon" href="https://frappe.github.io/frappe/assets/img/favicon.png" type="image/x-icon">
  19. <link rel="icon" href="https://frappe.github.io/frappe/assets/img/favicon.png" type="image/x-icon">-->
  20. </head>
  21. <body>
  22. <div class="container">
  23. <div class="row hero" style="padding-top: 30px; padding-bottom: 0px;">
  24. <div class="jumbotron" style="background: transparent;">
  25. <h1>Frappé Charts</h1>
  26. <p class="mt-2">GitHub-style simple and modern charts for the web</p>
  27. <p class="mt-2">with zero dependencies.</p>
  28. </div>
  29. <div class="col-sm-10 push-sm-1 later" style="font-size: 14px;">
  30. <div id="charts-1" class="chart-container"></div>
  31. <p class="mt-1"><strong>Try it!</strong> Use arrow keys to navigate data points</p>
  32. </div>
  33. <div class="col-sm-10 push-sm-1 later" style="font-size: 14px;">
  34. <div id="charts-2" class="chart-container"></div>
  35. </div>
  36. </div>
  37. <div class="group later">
  38. <div class="row section">
  39. <div class="col-sm-10 push-sm-1">
  40. <div class="dashboard-section">
  41. <h1>Installation</h1>
  42. <pre>
  43. <code class="hljs">npm install frappe-charts</code>
  44. </pre>
  45. <svg class="chart" width="720" height="140">
  46. <rect class="bar mini fill green" x="449.99999999999994" y="15.32519666666667" width="23.076923076923077" height="10">
  47. </rect>
  48. <!--<animate
  49. attributeName="height"
  50. from="10"
  51. to="110"
  52. begin="0.2s"
  53. dur="2s"
  54. values="10;110"
  55. keySplines="0 0 1 1"
  56. keyTimes="
  57. 0;1"
  58. calcMode="spline"
  59. />-->
  60. <!--<animate
  61. attributeName="height"
  62. from="10"
  63. to="110"
  64. begin="0s"
  65. dur="1s"
  66. values="10;110"
  67. keySplines="0.1 0.8 0.2 1"
  68. keyTimes="
  69. 0;1"
  70. calcMode="spline"
  71. />
  72. <animate
  73. attributeName="y"
  74. from="15"
  75. to="50"
  76. begin="0s"
  77. dur="1s"
  78. values="15;50"
  79. keySplines="0.1 0.8 0.2 1"
  80. keyTimes="
  81. 0;1"
  82. calcMode="spline"
  83. />-->
  84. <path class="stroke green"
  85. d="M0,100L54.55,100L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,100L381.82,100L436.36,95.69L490.91,15.33L545.45,80.53L600,100">
  86. <animate
  87. attributeName="d"
  88. from="M0,100L54.55,100L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,100L381.82,100L436.36,95.69L490.91,15.33L545.45,80.53L600,100"
  89. to="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L222.73,96L267.27,32L381.82,45L436.36,95.69L490.91,65.33L545.45,80.53L600,100"
  90. begin="1s"
  91. dur="1s"
  92. values="M0,100L54.55,100L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,100L381.82,100L436.36,95.69L490.91,15.33L545.45,80.53L600,100;
  93. M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L222.73,96L267.27,32L381.82,45L436.36,95.69L490.91,65.33L545.45,80.53L600,100"
  94. keySplines="0.1 0.8 0.2 1"
  95. keyTimes="
  96. 0;1"
  97. calcMode="spline"
  98. repeatCount="indefinite"
  99. />
  100. </path>
  101. <!--<path class="stroke green"
  102. d="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L530,20">
  103. <animate
  104. attributeName="d"
  105. from="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L530,20"
  106. to="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L530,20L560,80L600,50"
  107. begin="0s"
  108. dur="6s"
  109. values="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L530,20;
  110. M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L530,20L560,80L600,50"
  111. keySplines="0.1 0.8 0.2 1"
  112. keyTimes="
  113. 0;1"
  114. calcMode="spline"
  115. repeatCount="indefinite"
  116. />
  117. </path>-->
  118. <!--<path class="stroke green" d="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L600,100"></path>-->
  119. </svg>
  120. <!--<svg class="chart" width="720" height="140">
  121. <path class="stroke green" d="M0,100L54.55,35L109.09,100L163.64,89.75L218.18,86.18L272.73,96L327.27,32L381.82,45L436.36,95.69L490.91,65.33L500.45,80.53L530,20L560,80L600,50"></path>
  122. </svg>-->
  123. </div>
  124. </div>
  125. <div class="col-sm-10 push-sm-1">
  126. <div class="dashboard-section">
  127. <h1>Usage</h1>
  128. <h6 style="margin:2em 0 0 0">
  129. Include it in your html
  130. </h6>
  131. <pre>
  132. <code class="hljs html">&lt;script src="frappe-charts.min.js" /&gt;</code>
  133. </pre>
  134. <h6 style="margin:0">Create an svg element</h6>
  135. <pre>
  136. <code class="hljs html">&lt;svg id="chart"&gt;&lt;/svg&gt;</code>
  137. </pre>
  138. <h6 style="margin:0">Initiliaze a new Chart object</h6>
  139. <pre>
  140. <code class="hljs javascript">var tasks = [
  141. {
  142. id: 'Task 1',
  143. name: 'Redesign website',
  144. start: '2016-12-28',
  145. end: '2016-12-31',
  146. progress: 20,
  147. dependencies: 'Task 2, Task 3'
  148. },
  149. ...
  150. ]
  151. var chart = new Chart;
  152. </code>
  153. </pre>
  154. </div>
  155. </div>
  156. <div class="col-sm-10 push-sm-1">
  157. <div class="dashboard-section">
  158. <h1>Examples</h1>
  159. <!-- Closing -->
  160. <div class="text-center" style="margin-top: 70px">
  161. <a href=""><button class="large blue button">Download</button></a>
  162. <p class="mt-2"><a href="https://github.com/frappe" target="_blank">View on GitHub</a></p>
  163. <p>License: MIT</p>
  164. </div>
  165. </div>
  166. </div>
  167. </div>
  168. </div>
  169. </div>
  170. <script src="../src/charts.js"></script>
  171. <script src="assets/js/index.js"></script>
  172. </body>
  173. </html>