Commit 4694666f authored by Aron Fiechter's avatar Aron Fiechter
Browse files

Positioning of YearRange chart

parent e4847a5a
......@@ -435,7 +435,7 @@ class Voronoi extends React.Component {
<div className="pt-sm-5 pb-sm-5">
<Container>
<Row>
<Col xs={8}>
<Col xs={7}>
<svg
ref={(node) => (this.voronoiSvg = node)}
viewBox={`0 0 ${width} ${height}`}
......
......@@ -43,15 +43,10 @@ export default function YearRange() {
});
const options = {
title: {
text: 'Yearly results',
left: 10,
},
tooltip: {
trigger: 'axis',
axisPointer: {
// 坐标轴指示器,坐标轴触发有效
type: 'shadow', // 默认为直线,可选为:'line' | 'shadow'
type: 'line', // 默认为直线,可选为:'line' | 'shadow'
},
},
grid: {
......@@ -67,6 +62,7 @@ export default function YearRange() {
],
xAxis: {
type: 'category',
name: 'year',
data: years.x,
silent: false,
splitLine: {
......@@ -78,6 +74,7 @@ export default function YearRange() {
},
yAxis: {
type: 'value',
name: 'count',
splitArea: {
show: false,
},
......@@ -96,7 +93,8 @@ export default function YearRange() {
<ReactEcharts
ref={chartRef}
option={options}
style={{ height: '350px', width: '100%' }}
style={{ height: '200px', width: '100%', marginTop: '-50px' }}
opts={{ renderer: 'svg' }}
className="bar_chart"
/>
</div>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment