widget.js 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369
  1. $(function () {
  2. "use strict";
  3. /* Circle-progress */
  4. $('#circle').circleProgress({
  5. value: 0.85,
  6. size: 70,
  7. fill: {
  8. color: ["#05c3fb"]
  9. }
  10. });
  11. /* Circle-progress closed */
  12. /* Circle-progress-1 */
  13. $('#circle-1').circleProgress({
  14. value: 0.64,
  15. size: 70,
  16. fill: {
  17. color: ["#09ad95"]
  18. }
  19. });
  20. /* Circle-progress-1 closed */
  21. /* Circle-progress-2 */
  22. $('#circle-2').circleProgress({
  23. value: 0.74,
  24. size: 70,
  25. fill: {
  26. color: ["#f7b731"]
  27. }
  28. });
  29. /* Circle-progress-2 closed */
  30. /* Circle-progress-3 */
  31. $('#circle-3').circleProgress({
  32. value: 0.55,
  33. size: 70,
  34. fill: {
  35. gradient: ["#e82646"]
  36. }
  37. });
  38. /* Circle-progress-3 closed */
  39. /* Chartjs (#areaChart1) */
  40. var ctx = document.getElementById('areaChart1').getContext('2d');
  41. var myChart = new Chart(ctx, {
  42. type: 'line',
  43. data: {
  44. labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
  45. type: 'line',
  46. datasets: [{
  47. label: 'Market value',
  48. data: [30, 70, 30, 100, 50, 130, 100, 140],
  49. backgroundColor: 'transparent',
  50. borderColor: '#1170e4',
  51. pointBackgroundColor: '#fff',
  52. pointHoverBackgroundColor: '#1170e4',
  53. pointBorderColor: '#1170e4',
  54. pointHoverBorderColor: '#1170e4',
  55. pointBorderWidth: 2,
  56. pointRadius: 2,
  57. pointHoverRadius: 2,
  58. borderWidth: 4,
  59. lineTension: 0.3,
  60. },]
  61. },
  62. options: {
  63. maintainAspectRatio: false,
  64. plugins: {
  65. legend: {
  66. display: false,
  67. labels: {
  68. display: false
  69. }
  70. },
  71. tooltip: {
  72. mode: 'index',
  73. backgroundColor: '#fff',
  74. titleColor: '#000',
  75. bodyColor: '#000',
  76. cornerRadius: 3,
  77. intersect: false,
  78. }
  79. },
  80. responsive: true,
  81. scales: {
  82. x: {
  83. display: false,
  84. gridLines: {
  85. color: 'transparent',
  86. zeroLineColor: 'transparent'
  87. },
  88. ticks: {
  89. fontSize: 2,
  90. display: false,
  91. fontColor: 'transparent'
  92. }
  93. },
  94. y: {
  95. display: false,
  96. ticks: {
  97. display: false,
  98. }
  99. }
  100. },
  101. title: {
  102. display: false,
  103. },
  104. elements: {
  105. line: {
  106. borderWidth: 1
  107. },
  108. point: {
  109. radius: 4,
  110. hitRadius: 10,
  111. hoverRadius: 4
  112. }
  113. }
  114. }
  115. });
  116. /* Chartjs (#areaChart1) closed */
  117. /* Chartjs (#areaChart2) */
  118. var ctx = document.getElementById('areaChart2').getContext('2d');
  119. var myChart = new Chart(ctx, {
  120. type: 'line',
  121. data: {
  122. labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
  123. type: 'line',
  124. datasets: [{
  125. label: 'Market value',
  126. data: [24, 18, 28, 21, 32, 28, 30],
  127. backgroundColor: 'transparent',
  128. borderColor: '#09ad95',
  129. pointBackgroundColor: '#fff',
  130. pointHoverBackgroundColor: '#09ad95',
  131. pointBorderColor: '#09ad95',
  132. pointHoverBorderColor: '#09ad95',
  133. pointBorderWidth: 2,
  134. pointRadius: 2,
  135. pointHoverRadius: 2,
  136. borderWidth: 4,
  137. lineTension: 0.3,
  138. },]
  139. },
  140. options: {
  141. maintainAspectRatio: false,
  142. plugins: {
  143. legend: {
  144. display: false,
  145. labels: {
  146. display: false
  147. }
  148. },
  149. tooltip: {
  150. mode: 'index',
  151. backgroundColor: '#fff',
  152. titleColor: '#000',
  153. bodyColor: '#000',
  154. cornerRadius: 3,
  155. intersect: false,
  156. }
  157. },
  158. responsive: true,
  159. scales: {
  160. x: {
  161. display: false,
  162. gridLines: {
  163. color: 'transparent',
  164. zeroLineColor: 'transparent'
  165. },
  166. ticks: {
  167. fontSize: 2,
  168. fontColor: 'transparent'
  169. }
  170. },
  171. y: {
  172. display: false,
  173. ticks: {
  174. display: false,
  175. }
  176. }
  177. },
  178. title: {
  179. display: false,
  180. },
  181. elements: {
  182. line: {
  183. borderWidth: 1
  184. },
  185. point: {
  186. radius: 4,
  187. hitRadius: 10,
  188. hoverRadius: 4
  189. }
  190. }
  191. }
  192. });
  193. /* Chartjs (#areaChart2) closed */
  194. /* Chartjs (#areaChart3) */
  195. var ctx = document.getElementById('areaChart3').getContext('2d');
  196. var myChart = new Chart(ctx, {
  197. type: 'line',
  198. data: {
  199. labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
  200. type: 'line',
  201. datasets: [{
  202. label: 'Market value',
  203. data: [30, 70, 30, 100, 50, 130, 100, 140],
  204. backgroundColor: 'transparent',
  205. borderColor: '#f7b731',
  206. pointBackgroundColor: '#fff',
  207. pointHoverBackgroundColor: '#f7b731',
  208. pointBorderColor: '#f7b731',
  209. pointHoverBorderColor: '#f7b731',
  210. pointBorderWidth: 2,
  211. pointRadius: 2,
  212. pointHoverRadius: 2,
  213. borderWidth: 4,
  214. lineTension: 0.3,
  215. },]
  216. },
  217. options: {
  218. maintainAspectRatio: false,
  219. plugins: {
  220. legend: {
  221. display: false,
  222. labels: {
  223. display: false
  224. }
  225. },
  226. tooltip: {
  227. mode: 'index',
  228. backgroundColor: '#fff',
  229. titleColor: '#000',
  230. bodyColor: '#000',
  231. cornerRadius: 3,
  232. intersect: false,
  233. }
  234. },
  235. responsive: true,
  236. scales: {
  237. x: {
  238. display: false,
  239. gridLines: {
  240. color: 'transparent',
  241. zeroLineColor: 'transparent'
  242. },
  243. ticks: {
  244. fontSize: 2,
  245. fontColor: 'transparent'
  246. }
  247. },
  248. y: {
  249. display: false,
  250. ticks: {
  251. display: false,
  252. }
  253. }
  254. },
  255. title: {
  256. display: false,
  257. },
  258. elements: {
  259. line: {
  260. borderWidth: 1
  261. },
  262. point: {
  263. radius: 4,
  264. hitRadius: 10,
  265. hoverRadius: 4
  266. }
  267. }
  268. }
  269. });
  270. /* Chartjs (#areaChart3) closed */
  271. /* Chartjs (#areaChart4) */
  272. var ctx = document.getElementById('areaChart4').getContext('2d');
  273. var myChart = new Chart(ctx, {
  274. type: 'line',
  275. data: {
  276. labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
  277. type: 'line',
  278. datasets: [{
  279. label: 'Market value',
  280. data: [24, 18, 28, 21, 32, 28, 30],
  281. backgroundColor: 'transparent',
  282. borderColor: '#e82646',
  283. pointBackgroundColor: '#fff',
  284. pointHoverBackgroundColor: '#e82646',
  285. pointBorderColor: '#e82646',
  286. pointHoverBorderColor: '#e82646',
  287. pointBorderWidth: 2,
  288. pointRadius: 2,
  289. pointHoverRadius: 2,
  290. borderWidth: 4,
  291. lineTension: 0.3,
  292. },]
  293. },
  294. options: {
  295. maintainAspectRatio: false,
  296. plugins: {
  297. legend: {
  298. display: false,
  299. labels: {
  300. display: false
  301. }
  302. },
  303. tooltip: {
  304. mode: 'index',
  305. backgroundColor: '#fff',
  306. titleColor: '#000',
  307. bodyColor: '#000',
  308. cornerRadius: 3,
  309. intersect: false,
  310. }
  311. },
  312. responsive: true,
  313. scales: {
  314. x: {
  315. display: false,
  316. gridLines: {
  317. color: 'transparent',
  318. zeroLineColor: 'transparent'
  319. },
  320. ticks: {
  321. fontSize: 2,
  322. fontColor: 'transparent'
  323. }
  324. },
  325. y: {
  326. display: false,
  327. ticks: {
  328. display: false,
  329. }
  330. }
  331. },
  332. title: {
  333. display: false,
  334. },
  335. elements: {
  336. line: {
  337. borderWidth: 1
  338. },
  339. point: {
  340. radius: 4,
  341. hitRadius: 10,
  342. hoverRadius: 4
  343. }
  344. }
  345. }
  346. });
  347. /* Chartjs (#areaChart4) closed */
  348. });