page2Char2Schema.js 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. /*
  2. * @LastEditors: gcz
  3. */
  4. import themeColor from "./color"
  5. let page2Char2Schema = {
  6. title: {
  7. text: '树种分布统计',
  8. textStyle: {
  9. color: themeColor.mainColor,
  10. },
  11. show: false
  12. },
  13. grid: {
  14. containLabel: true,
  15. top: "30px",
  16. left: '10px',
  17. bottom: '20px',
  18. right: '24px'
  19. },
  20. tooltip: {
  21. trigger: 'axis',
  22. axisPointer: {
  23. type: 'shadow'
  24. }
  25. },
  26. legend: {
  27. textStyle: {
  28. color: '#fff',
  29. }
  30. },
  31. yAxis: {
  32. type: 'value',
  33. axisLabel: {
  34. color: "rgba(255, 255, 255, 1)"
  35. },
  36. splitLine: {
  37. show: true,
  38. lineStyle: {
  39. color: 'rgba(255,255,255,0.05)',
  40. }
  41. }
  42. },
  43. xAxis: {
  44. type: 'category',
  45. data: ['1', '2', '3', '4', '5', '6', '7'],
  46. axisLabel: {
  47. color: "rgba(255, 255, 255, 1)"
  48. }
  49. },
  50. dataZoom: [
  51. {
  52. xAxisIndex: 0, //这里是从X轴的0刻度开始
  53. show: true, //是否显示滑动条,不影响使用
  54. type: 'slider', // 这个 dataZoom 组件是 slider 型 dataZoom 组件
  55. startValue: 0, // 从头开始。
  56. endValue: 7, // 一次性展示6个
  57. height: 5, //组件高度
  58. width: '50%',
  59. left: '30%',
  60. bottom: '10px',
  61. borderColor: 'transparent',
  62. fillerColor: '#14c6d3',
  63. zoomLock: true,
  64. showDataShadow: false, //是否显示数据阴影 默认auto
  65. backgroundColor: '#0b1511',
  66. showDetail: false, //即拖拽时候是否显示详细数值信息 默认true
  67. realtime: true, //是否实时更新
  68. filterMode: 'filter',
  69. handleIcon: 'M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z',
  70. handleStyle: {
  71. color: '#14c6d3',
  72. borderColor: 'transparent',
  73. borderRadius: 10
  74. },
  75. moveHandleSize: 20,
  76. moveOnMouseMove: true,
  77. maxValueSpan: 7,
  78. minValueSpan: 7,
  79. moveHandleSize: 0,
  80. brushSelect: false, //刷选功能,设为false可以防止拖动条长度改变 ************(这是一个坑)
  81. },
  82. ],
  83. series: [
  84. {
  85. name: '松树',
  86. type: 'bar',
  87. stack: 'total',
  88. label: {
  89. show: false
  90. },
  91. emphasis: {
  92. focus: 'series'
  93. },
  94. data: [1, 1, 1, 2, 2, 1, 0]
  95. },
  96. {
  97. name: '马尾松',
  98. type: 'bar',
  99. stack: 'total',
  100. label: {
  101. show: false
  102. },
  103. emphasis: {
  104. focus: 'series'
  105. },
  106. data: [1, 8, 8, 2, 6, 9, 9]
  107. },
  108. {
  109. name: '杉树',
  110. type: 'bar',
  111. stack: 'total',
  112. label: {
  113. show: false
  114. },
  115. emphasis: {
  116. focus: 'series'
  117. },
  118. data: [8, 1, 1, 6, 2, 0, 1]
  119. }
  120. ]
  121. }
  122. export default page2Char2Schema