如何删除ngx-echarts中图网格上部边框的显示?

问题描述 投票:0回答:1

{ grid: { left: 20, right: 25, top: 0, bottom: 40, }, xAxis: { type: 'category', data: [ '9 фев', '16 фев', '23 фев', '1 мар', '8 мар', '15 мар', '22 мар', '29 мар', '5 апр', '12 апр', ], boundaryGap: false, axisLabel: { interval: 0, overflow: 'truncate', color: '#86909C', fontSize: 14, fontWeight: 'normal', margin: 10, formatter: (value: string) => { const [day, month] = value.split(' '); return `{a|${day}}\n{b|${month}}`; }, rich: { a: { fontSize: 14, align: 'center', }, b: { fontSize: 14, align: 'center', }, }, }, axisLine: { show: false, }, axisTick: { show: false, }, splitLine: { show: true, lineStyle: { type: 'dashed', }, }, }, yAxis: { type: 'value', min: 1, max: 6, interval: 1, position: 'right', splitLine: { show: true, lineStyle: { type: 'solid', }, }, axisLabel: { color: '#0B1F33', fontSize: 16, fontWeight: 'bold', margin: 12, formatter: (value: number) => { if (value < 2 || value > 5) { return ''; } else { return value.toString(); } }, }, }, series: [ { name: 'Test', type: 'line', smooth: true, data: [null, 4, null, null, 4.57, 5, 4], connectNulls: true, emphasis: { focus: 'series', }, itemStyle: { color: '#0E69D5', borderColor: '#ffffff', borderWidth: 1, }, lineStyle: { color: '#185AC5', }, symbol: 'circle', symbolSize: 7, markLine: { symbol: 'none', tooltip: { show: false }, label: { show: false }, data: [ { xAxis: 6, lineStyle: { color: '#0E69D5', width: 1, type: 'solid', }, emphasis: { disabled: true, }, }, ], }, areaStyle: { color: { type: 'linear', x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: 'rgba(192, 216, 253, 0.80)' }, { offset: 1, color: 'rgba(237, 247, 255, 0.08)' }, ], }, }, }, ], }

这就是外观:

如何隐藏我标记为红色的线?还是这与Echarts不可能?如果不可能,您能推荐其他图书馆吗?
	
trory设置

top属性my chartgrid属性属于隐藏顶线的值。

grid: { left: '3%', right: '4%', bottom: '3%', top: '-2%', containLabel: true },
javascript angular echarts ngx-echarts
1个回答
0
投票

编号

	
最新问题
© www.soinside.com 2019 - 2025. All rights reserved.