config-ucharts.js 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865
  1. /*
  2. * uCharts®
  3. * 高性能跨平台图表库,支持H5、APP、小程序(微信/支付宝/百度/头条/QQ/360)、Vue、Taro等支持canvas的框架平台
  4. * Copyright (c) 2021 QIUN®秋云 https://www.ucharts.cn All rights reserved.
  5. * Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
  6. * 复制使用请保留本段注释,感谢支持开源!
  7. *
  8. * uCharts®官方网站
  9. * https://www.uCharts.cn
  10. *
  11. * 开源地址:
  12. * https://gitee.com/uCharts/uCharts
  13. *
  14. * uni-app插件市场地址:
  15. * http://ext.dcloud.net.cn/plugin?id=271
  16. *
  17. */
  18. // 主题颜色配置:如每个图表类型需要不同主题,请在对应图表类型上更改color属性
  19. const color = ['#1890FF', '#91CB74', '#FAC858', '#EE6666', '#73C0DE', '#3CA272', '#FC8452', '#9A60B4', '#ea7ccc'];
  20. //事件转换函数,主要用作格式化x轴为时间轴,根据需求自行修改
  21. const formatDateTime = (timeStamp, returnType) => {
  22. var date = new Date();
  23. date.setTime(timeStamp * 1000);
  24. var y = date.getFullYear();
  25. var m = date.getMonth() + 1;
  26. m = m < 10 ? ('0' + m) : m;
  27. var d = date.getDate();
  28. d = d < 10 ? ('0' + d) : d;
  29. var h = date.getHours();
  30. h = h < 10 ? ('0' + h) : h;
  31. var minute = date.getMinutes();
  32. var second = date.getSeconds();
  33. minute = minute < 10 ? ('0' + minute) : minute;
  34. second = second < 10 ? ('0' + second) : second;
  35. if (returnType == 'full') {
  36. return y + '-' + m + '-' + d + ' ' + h + ':' + minute + ':' + second;
  37. }
  38. if (returnType == 'y-m-d') {
  39. return y + '-' + m + '-' + d;
  40. }
  41. if (returnType == 'h:m') {
  42. return h + ':' + minute;
  43. }
  44. if (returnType == 'h:m:s') {
  45. return h + ':' + minute + ':' + second;
  46. }
  47. return [y, m, d, h, minute, second];
  48. }
  49. const cfu = {
  50. //demotype为自定义图表类型,一般不需要自定义图表类型,只需要改根节点上对应的类型即可
  51. "type": ["pie", "ring", "rose", "word", "funnel", "map", "arcbar", "line", "column", "mount", "bar", "area",
  52. "radar", "gauge", "candle", "mix", "tline", "tarea", "scatter", "bubble", "demotype","qy-line-gradual"
  53. ],
  54. "range": ["饼状图", "圆环图", "玫瑰图", "词云图", "漏斗图", "地图", "圆弧进度条", "折线图", "柱状图", "山峰图", "条状图", "区域图", "雷达图", "仪表盘",
  55. "K线图", "混合图", "时间轴折线", "时间轴区域", "散点图", "气泡图", "自定义类型"
  56. ],
  57. //增加自定义图表类型,如果需要categories,请在这里加入您的图表类型,例如最后的"demotype"
  58. //自定义类型时需要注意"tline","tarea","scatter","bubble"等时间轴(矢量x轴)类图表,没有categories,不需要加入categories
  59. "categories": ["line", "column", "mount", "bar", "area", "radar", "gauge", "candle", "mix", "demotype"],
  60. //instance为实例变量承载属性,不要删除
  61. "instance": {},
  62. //option为opts及eopts承载属性,不要删除
  63. "option": {},
  64. //下面是自定义format配置,因除H5端外的其他端无法通过props传递函数,只能通过此属性对应下标的方式来替换
  65. "formatter": {
  66. "yAxisDemo1": function(val, index, opts) {
  67. return val + '元'
  68. },
  69. "yAxisDemo2": function(val, index, opts) {
  70. return val.toFixed(2)
  71. },
  72. "xAxisDemo1": function(val, index, opts) {
  73. return val + '年';
  74. },
  75. "xAxisDemo2": function(val, index, opts) {
  76. return formatDateTime(val, 'h:m')
  77. },
  78. "seriesDemo1": function(val, index, series, opts) {
  79. return val + '元'
  80. },
  81. "tooltipDemo1": function(item, category, index, opts) {
  82. if (index == 0) {
  83. return '随便用' + item.data + '年'
  84. } else {
  85. return '其他我没改' + item.data + '天'
  86. }
  87. },
  88. "pieDemo": function(val, index, series, opts) {
  89. if (index !== undefined) {
  90. return series[index].name + ':' + series[index].data + '元'
  91. }
  92. },
  93. "dateFormatMD": function(val) {
  94. return val+'天'
  95. },
  96. },
  97. //这里演示了自定义您的图表类型的option,可以随意命名,之后在组件上 type="demotype" 后,组件会调用这个花括号里的option,如果组件上还存在opts参数,会将demotype与opts中option合并后渲染图表。
  98. "demotype": {
  99. //我这里把曲线图当做了自定义图表类型,您可以根据需要随意指定类型或配置
  100. "type": "line",
  101. "color": color,
  102. "padding": [15, 10, 0, 15],
  103. "xAxis": {
  104. "disableGrid": true,
  105. },
  106. "yAxis": {
  107. "gridType": "dash",
  108. "dashLength": 2,
  109. },
  110. "legend": {},
  111. "extra": {
  112. "line": {
  113. "type": "curve",
  114. "width": 2
  115. },
  116. }
  117. },
  118. "cityTrafficLine": { //城市交通曲线图
  119. "type": "line",
  120. "canvasId": "",
  121. "canvas2d": false,
  122. "background": "none",
  123. "animation": true,
  124. "timing": "easeOut",
  125. "duration": 1000,
  126. "color": [
  127. "#F88E16",
  128. "#2D54EC",
  129. "#C584E4"
  130. ],
  131. "padding": [
  132. 0,
  133. 20,
  134. 0,
  135. 0
  136. ],
  137. "rotate": false,
  138. "errorReload": true,
  139. "fontSize": 13,
  140. "fontColor": "rgba(44, 53, 66, 0.45)",
  141. "enableScroll": false,
  142. "touchMoveLimit": 60,
  143. "enableMarkLine": false,
  144. "dataLabel": false,
  145. "dataPointShape": false,
  146. "dataPointShapeType": "solid",
  147. "tapLegend": true,
  148. "xAxis": {
  149. "disabled": false,
  150. "axisLine": true,
  151. "axisLineColor": "rgba(65, 97, 128, 0.45)",
  152. "calibration": false,
  153. "fontColor": "rgba(44, 53, 66, 0.45)",
  154. "fontSize": 13,
  155. "rotateLabel": true,
  156. "itemCount": 5,
  157. "boundaryGap": "center",
  158. "disableGrid": true,
  159. "gridColor": "#CCCCCC",
  160. "gridType": "solid",
  161. "dashLength": 4,
  162. "gridEval": 1,
  163. "scrollShow": true,
  164. "scrollAlign": "left",
  165. "scrollColor": "#A6A6A6",
  166. "scrollBackgroundColor": "#EFEBEF",
  167. "format": ""
  168. },
  169. "yAxis": {
  170. "disabled": false,
  171. "disableGrid": false,
  172. "splitNumber": 5,
  173. "gridType": "solid",
  174. "dashLength": 2,
  175. "gridColor": "rgba(65, 97, 128, 0.15)",
  176. "padding": 10,
  177. "showTitle": false,
  178. "data": []
  179. },
  180. "legend": {
  181. "show": true,
  182. "position": "top",
  183. "float": "center",
  184. "padding": 32,
  185. "margin": 5,
  186. "backgroundColor": "rgba(0,0,0,0)",
  187. "borderColor": "rgba(0,0,0,0)",
  188. "borderWidth": 0,
  189. "fontSize": 12,
  190. "fontColor": "rgba(44, 53, 66, 0.45)",
  191. "lineHeight": 11,
  192. "hiddenColor": "#CECECE",
  193. "itemGap": 10
  194. },
  195. "extra": {
  196. "line": {
  197. "type": "curve",
  198. "width": 2
  199. },
  200. "tooltip": {
  201. "showBox": true,
  202. "showArrow": true,
  203. "showCategory": false,
  204. "borderWidth": 0,
  205. "borderRadius": 0,
  206. "borderColor": "#000000",
  207. "borderOpacity": 0.7,
  208. "bgColor": "#000000",
  209. "bgOpacity": 0.7,
  210. "gridType": "solid",
  211. "dashLength": 4,
  212. "gridColor": "#CCCCCC",
  213. "fontColor": "#FFFFFF",
  214. "splitLine": true,
  215. "horizentalLine": false,
  216. "xAxisLabel": false,
  217. "yAxisLabel": false,
  218. "labelBgColor": "#FFFFFF",
  219. "labelBgOpacity": 0.7,
  220. "labelFontColor": "#666666"
  221. },
  222. "markLine": {
  223. "type": "solid",
  224. "dashLength": 4,
  225. "data": []
  226. }
  227. }
  228. },
  229. //下面是自定义配置,请添加项目所需的通用配置
  230. "eqLine": {
  231. "type": "line",
  232. "color": color,
  233. "padding": [15, 10, 0, 15],
  234. "xAxis": {
  235. "disableGrid": true,
  236. },
  237. "yAxis": {
  238. "gridType": "dash",
  239. "dashLength": 2,
  240. },
  241. "legend": {},
  242. "extra": {
  243. "line": {
  244. "type": "curve",
  245. "width": 2
  246. },
  247. }
  248. },
  249. "pie": {
  250. "type": "pie",
  251. "color": color,
  252. "padding": [5, 5, 5, 5],
  253. "extra": {
  254. "pie": {
  255. "activeOpacity": 0.5,
  256. "activeRadius": 10,
  257. "offsetAngle": 0,
  258. "labelWidth": 15,
  259. "border": true,
  260. "borderWidth": 3,
  261. "borderColor": "#FFFFFF"
  262. },
  263. }
  264. },
  265. "ring": {
  266. "type": "ring",
  267. "color": color,
  268. "padding": [5, 5, 5, 5],
  269. "rotate": false,
  270. "dataLabel": true,
  271. "legend": {
  272. "show": true,
  273. "position": "right",
  274. "lineHeight": 25,
  275. },
  276. "title": {
  277. "name": "收益率",
  278. "fontSize": 15,
  279. "color": "#666666"
  280. },
  281. "subtitle": {
  282. "name": "70%",
  283. "fontSize": 25,
  284. "color": "#7cb5ec"
  285. },
  286. "extra": {
  287. "ring": {
  288. "ringWidth": 30,
  289. "activeOpacity": 0.5,
  290. "activeRadius": 10,
  291. "offsetAngle": 0,
  292. "labelWidth": 15,
  293. "border": true,
  294. "borderWidth": 3,
  295. "borderColor": "#FFFFFF"
  296. },
  297. },
  298. },
  299. "rose": {
  300. "type": "rose",
  301. "color": color,
  302. "padding": [5, 5, 5, 5],
  303. "legend": {
  304. "show": true,
  305. "position": "left",
  306. "lineHeight": 25,
  307. },
  308. "extra": {
  309. "rose": {
  310. "type": "area",
  311. "minRadius": 50,
  312. "activeOpacity": 0.5,
  313. "activeRadius": 10,
  314. "offsetAngle": 0,
  315. "labelWidth": 15,
  316. "border": false,
  317. "borderWidth": 2,
  318. "borderColor": "#FFFFFF"
  319. },
  320. }
  321. },
  322. "word": {
  323. "type": "word",
  324. "color": color,
  325. "extra": {
  326. "word": {
  327. "type": "normal",
  328. "autoColors": false
  329. }
  330. }
  331. },
  332. "funnel": {
  333. "type": "funnel",
  334. "color": color,
  335. "padding": [15, 15, 0, 15],
  336. "extra": {
  337. "funnel": {
  338. "activeOpacity": 0.3,
  339. "activeWidth": 10,
  340. "border": true,
  341. "borderWidth": 2,
  342. "borderColor": "#FFFFFF",
  343. "fillOpacity": 1,
  344. "labelAlign": "right"
  345. },
  346. }
  347. },
  348. "map": {
  349. "type": "map",
  350. "color": color,
  351. "padding": [0, 0, 0, 0],
  352. "dataLabel": true,
  353. "extra": {
  354. "map": {
  355. "border": true,
  356. "borderWidth": 1,
  357. "borderColor": "#666666",
  358. "fillOpacity": 0.6,
  359. "activeBorderColor": "#F04864",
  360. "activeFillColor": "#FACC14",
  361. "activeFillOpacity": 1
  362. },
  363. }
  364. },
  365. "arcbar": {
  366. "type": "arcbar",
  367. "color": color,
  368. "title": {
  369. "name": "百分比",
  370. "fontSize": 25,
  371. "color": "#00FF00"
  372. },
  373. "subtitle": {
  374. "name": "默认标题",
  375. "fontSize": 15,
  376. "color": "#666666"
  377. },
  378. "extra": {
  379. "arcbar": {
  380. "type": "default",
  381. "width": 12,
  382. "backgroundColor": "#E9E9E9",
  383. "startAngle": 0.75,
  384. "endAngle": 0.25,
  385. "gap": 2
  386. }
  387. }
  388. },
  389. "line": {
  390. "type": "line",
  391. "color": color,
  392. "padding": [15, 10, 0, 15],
  393. "xAxis": {
  394. "disableGrid": true,
  395. },
  396. "yAxis": {
  397. "gridType": "dash",
  398. "dashLength": 2,
  399. },
  400. "legend": {},
  401. "extra": {
  402. "line": {
  403. "type": "straight",
  404. "width": 2,
  405. "activeType": "hollow"
  406. },
  407. }
  408. },
  409. "tline": {
  410. "type": "line",
  411. "color": color,
  412. "padding": [15, 10, 0, 15],
  413. "xAxis": {
  414. "disableGrid": false,
  415. "boundaryGap": "justify",
  416. },
  417. "yAxis": {
  418. "gridType": "dash",
  419. "dashLength": 2,
  420. "data": [{
  421. "min": 0,
  422. "max": 80
  423. }]
  424. },
  425. "legend": {},
  426. "extra": {
  427. "line": {
  428. "type": "curve",
  429. "width": 2,
  430. "activeType": "hollow"
  431. },
  432. }
  433. },
  434. "tarea": {
  435. "type": "area",
  436. "color": color,
  437. "padding": [15, 10, 0, 15],
  438. "xAxis": {
  439. "disableGrid": true,
  440. "boundaryGap": "justify",
  441. },
  442. "yAxis": {
  443. "gridType": "dash",
  444. "dashLength": 2,
  445. "data": [{
  446. "min": 0,
  447. "max": 80
  448. }]
  449. },
  450. "legend": {},
  451. "extra": {
  452. "area": {
  453. "type": "curve",
  454. "opacity": 0.2,
  455. "addLine": true,
  456. "width": 2,
  457. "gradient": true,
  458. "activeType": "hollow"
  459. },
  460. }
  461. },
  462. "column": {
  463. "type": "column",
  464. "color": color,
  465. "padding": [15, 15, 0, 5],
  466. "xAxis": {
  467. "disableGrid": true,
  468. },
  469. "yAxis": {
  470. "data": [{
  471. "min": 0
  472. }]
  473. },
  474. "legend": {},
  475. "extra": {
  476. "column": {
  477. "type": "group",
  478. "width": 30,
  479. "activeBgColor": "#000000",
  480. "activeBgOpacity": 0.08
  481. },
  482. }
  483. },
  484. "mount": {
  485. "type": "mount",
  486. "color": color,
  487. "padding": [15, 15, 0, 5],
  488. "xAxis": {
  489. "disableGrid": true,
  490. },
  491. "yAxis": {
  492. "data": [{
  493. "min": 0
  494. }]
  495. },
  496. "legend": {},
  497. "extra": {
  498. "mount": {
  499. "type": "mount",
  500. "widthRatio": 1.5,
  501. },
  502. }
  503. },
  504. "bar": {
  505. // "type": "bar",
  506. // "color": color,
  507. // "padding": [15, 30, 0, 5],
  508. // "xAxis": {
  509. // "boundaryGap": "justify",
  510. // "disableGrid": false,
  511. // "min": 0,
  512. // "axisLine": false
  513. // },
  514. // "yAxis": {},
  515. // "legend": {},
  516. // "extra": {
  517. // "bar": {
  518. // "type": "group",
  519. // "width": 30,
  520. // "meterBorde": 1,
  521. // "meterFillColor": "#FFFFFF",
  522. // "activeBgColor": "#000000",
  523. // "activeBgOpacity": 0.08
  524. // },
  525. // }
  526. },
  527. "area": {
  528. "type": "area",
  529. "color": color,
  530. "padding": [15, 15, 0, 15],
  531. "xAxis": {
  532. "disableGrid": true,
  533. },
  534. "yAxis": {
  535. "gridType": "dash",
  536. "dashLength": 2,
  537. },
  538. "legend": {},
  539. "extra": {
  540. "area": {
  541. "type": "straight",
  542. "opacity": 0.2,
  543. "addLine": true,
  544. "width": 2,
  545. "gradient": false,
  546. "activeType": "hollow"
  547. },
  548. }
  549. },
  550. "radar": {
  551. "type": "radar",
  552. "color": color,
  553. "padding": [5, 5, 5, 5],
  554. "dataLabel": false,
  555. "legend": {
  556. "show": true,
  557. "position": "right",
  558. "lineHeight": 25,
  559. },
  560. "extra": {
  561. "radar": {
  562. "gridType": "radar",
  563. "gridColor": "#CCCCCC",
  564. "gridCount": 3,
  565. "opacity": 0.2,
  566. "max": 200,
  567. "labelShow": true
  568. },
  569. }
  570. },
  571. "gauge": {
  572. "type": "gauge",
  573. "color": color,
  574. "title": {
  575. "name": "66Km/H",
  576. "fontSize": 25,
  577. "color": "#2fc25b",
  578. "offsetY": 50
  579. },
  580. "subtitle": {
  581. "name": "实时速度",
  582. "fontSize": 15,
  583. "color": "#1890ff",
  584. "offsetY": -50
  585. },
  586. "extra": {
  587. "gauge": {
  588. "type": "default",
  589. "width": 30,
  590. "labelColor": "#666666",
  591. "startAngle": 0.75,
  592. "endAngle": 0.25,
  593. "startNumber": 0,
  594. "endNumber": 100,
  595. "labelFormat": "",
  596. "splitLine": {
  597. "fixRadius": 0,
  598. "splitNumber": 10,
  599. "width": 30,
  600. "color": "#FFFFFF",
  601. "childNumber": 5,
  602. "childWidth": 12
  603. },
  604. "pointer": {
  605. "width": 24,
  606. "color": "auto"
  607. }
  608. }
  609. }
  610. },
  611. "candle": {
  612. "type": "candle",
  613. "color": color,
  614. "padding": [15, 15, 0, 15],
  615. "enableScroll": true,
  616. "enableMarkLine": true,
  617. "dataLabel": false,
  618. "xAxis": {
  619. "labelCount": 4,
  620. "itemCount": 40,
  621. "disableGrid": true,
  622. "gridColor": "#CCCCCC",
  623. "gridType": "solid",
  624. "dashLength": 4,
  625. "scrollShow": true,
  626. "scrollAlign": "left",
  627. "scrollColor": "#A6A6A6",
  628. "scrollBackgroundColor": "#EFEBEF"
  629. },
  630. "yAxis": {},
  631. "legend": {},
  632. "extra": {
  633. "candle": {
  634. "color": {
  635. "upLine": "#f04864",
  636. "upFill": "#f04864",
  637. "downLine": "#2fc25b",
  638. "downFill": "#2fc25b"
  639. },
  640. "average": {
  641. "show": true,
  642. "name": ["MA5", "MA10", "MA30"],
  643. "day": [5, 10, 20],
  644. "color": ["#1890ff", "#2fc25b", "#facc14"]
  645. }
  646. },
  647. "markLine": {
  648. "type": "dash",
  649. "dashLength": 5,
  650. "data": [{
  651. "value": 2150,
  652. "lineColor": "#f04864",
  653. "showLabel": true
  654. },
  655. {
  656. "value": 2350,
  657. "lineColor": "#f04864",
  658. "showLabel": true
  659. }
  660. ]
  661. }
  662. }
  663. },
  664. "mix": {
  665. "type": "mix",
  666. "color": color,
  667. "padding": [15, 15, 0, 15],
  668. "xAxis": {
  669. "disableGrid": true,
  670. },
  671. "yAxis": {
  672. "disabled": false,
  673. "disableGrid": false,
  674. "splitNumber": 5,
  675. "gridType": "dash",
  676. "dashLength": 4,
  677. "gridColor": "#CCCCCC",
  678. "padding": 10,
  679. "showTitle": true,
  680. "data": []
  681. },
  682. "legend": {},
  683. "extra": {
  684. "mix": {
  685. "column": {
  686. "width": 20
  687. }
  688. },
  689. }
  690. },
  691. "scatter": {
  692. "type": "scatter",
  693. "color": color,
  694. "padding": [15, 15, 0, 15],
  695. "dataLabel": false,
  696. "xAxis": {
  697. "disableGrid": false,
  698. "gridType": "dash",
  699. "splitNumber": 5,
  700. "boundaryGap": "justify",
  701. "min": 0
  702. },
  703. "yAxis": {
  704. "disableGrid": false,
  705. "gridType": "dash",
  706. },
  707. "legend": {},
  708. "extra": {
  709. "scatter": {},
  710. }
  711. },
  712. "bubble": {
  713. "type": "bubble",
  714. "color": color,
  715. "padding": [15, 15, 0, 15],
  716. "xAxis": {
  717. "disableGrid": false,
  718. "gridType": "dash",
  719. "splitNumber": 5,
  720. "boundaryGap": "justify",
  721. "min": 0,
  722. "max": 250
  723. },
  724. "yAxis": {
  725. "disableGrid": false,
  726. "gridType": "dash",
  727. "data": [{
  728. "min": 0,
  729. "max": 150
  730. }]
  731. },
  732. "legend": {},
  733. "extra": {
  734. "bubble": {
  735. "border": 2,
  736. "opacity": 0.5,
  737. },
  738. }
  739. },
  740. "qy-line-gradual": {
  741. "type": "area",
  742. "canvasId": "",
  743. "canvas2d": false,
  744. "background": "none",
  745. "animation": true,
  746. "timing": "easeOut",
  747. "duration": 1000,
  748. "color":["#2C6FF3", "#F9B237" ],
  749. "padding": [
  750. 0,
  751. 10,
  752. 10,
  753. 10
  754. ],
  755. "rotate": false,
  756. "errorReload": true,
  757. "fontSize": 13,
  758. "fontColor": "rgba(44, 53, 66, 0.45)",
  759. "enableScroll": false,
  760. "touchMoveLimit": 60,
  761. "enableMarkLine": false,
  762. "dataLabel": false,
  763. "dataPointShape": false,
  764. "dataPointShapeType": "solid",
  765. "tapLegend": true,
  766. "xAxis": {
  767. "fontColor": "#777777",
  768. // "disabled": false,
  769. // "axisLine": true,
  770. "axisLineColor": "#777777",
  771. // "calibration": false,
  772. // "fontColor": "rgba(44, 53, 66, 0.45)",
  773. // "fontSize": 13,
  774. "rotateLabel": true,
  775. "marginTop":10,
  776. // "itemCount": 5,
  777. // "boundaryGap": "center", //x轴刻度顶点开始
  778. "disableGrid": true, //网格状态
  779. // "gridColor": "#CCCCCC",
  780. // "gridType": "solid",
  781. // "dashLength": 4,
  782. // "gridEval": 1,
  783. // "scrollShow": false,
  784. // "scrollAlign": "left",
  785. // "scrollColor": "#A6A6A6",
  786. // "scrollBackgroundColor": "#EFEBEF",
  787. "labelCount":10,
  788. // "format": 'dateFormatMD'
  789. },
  790. "yAxis": {
  791. "disabled": false,
  792. "disableGrid": false,
  793. "splitNumber": 5,
  794. "gridType": "solid",
  795. "dashLength": 2,
  796. "fontColor": "#777777",
  797. "gridColor": "rgba(65, 97, 128, 0.15)",
  798. "padding": 10,
  799. "showTitle": false,
  800. "data": []
  801. },
  802. "legend": {
  803. "position": "top",
  804. "float": 'right',
  805. "padding": 20,
  806. "margin": 5,
  807. "backgroundColor": "rgba(0,0,0,0)",
  808. "borderColor": "rgba(0,0,0,0)",
  809. "borderWidth": 0,
  810. "fontSize": 12,
  811. "fontColor": "#777777",
  812. "lineHeight": 11,
  813. "hiddenColor": "#CECECE",
  814. "itemGap": 20
  815. },
  816. "extra": {
  817. "line": {
  818. "type": "curve",
  819. "width": 2
  820. },
  821. "tooltip": {
  822. "showBox": true,
  823. "showArrow": true,
  824. "showCategory": false,
  825. "borderWidth": 0,
  826. "borderRadius": 0,
  827. "borderColor": "#000000",
  828. "borderOpacity": 0.7,
  829. "bgColor": "#000000",
  830. "bgOpacity": 0.7,
  831. "gridType": "solid",
  832. "dashLength": 4,
  833. "gridColor": "#CCCCCC",
  834. "fontColor": "#FFFFFF",
  835. "splitLine": true,
  836. "horizentalLine": false,
  837. "xAxisLabel": false,
  838. "yAxisLabel": false,
  839. "labelBgColor": "#FFFFFF",
  840. "labelBgOpacity": 0.7,
  841. "labelFontColor": "#666666"
  842. },
  843. "markLine": {
  844. "type": "solid",
  845. "dashLength": 4,
  846. "data": []
  847. },
  848. "area": {
  849. "type": "curve",
  850. "opacity": 0.8,
  851. "addLine": true, //是否显示曲线
  852. "width": 2, //曲线宽度
  853. "gradient": true //渐变开关
  854. },
  855. }
  856. },
  857. }
  858. export default cfu;