Refactor financial chart implementation
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { col } from '../csv.js';
|
||||
import {
|
||||
PALETTE, FONT, axisCommon, periodAxis, titleStyle, legendStyle,
|
||||
PALETTE, FONT, axisCommon, periodAxis, titleStyle, standardLegend,
|
||||
lineSeries, footnote, watermarks, LAYOUT,
|
||||
} from '../theme.js';
|
||||
|
||||
@@ -64,18 +64,7 @@ export function ppmtMarginsChart(rows, { width, height }) {
|
||||
text: '泡泡玛特利润率与费用率拆解(2020H1-2026H1)',
|
||||
subtext: '毛利率抬升叠加费用率下降,共同推动净利率走高(H1为半年,H2为全年累计)',
|
||||
},
|
||||
legend: {
|
||||
// 不继承 legendStyle:它带 icon:'roundRect',会盖掉 ECharts 按系列
|
||||
// 自动生成的「短线+空心圆」图例
|
||||
top: LAYOUT.legendTop,
|
||||
itemGap: 28,
|
||||
textStyle: {
|
||||
color: PALETTE.ink,
|
||||
fontSize: 14,
|
||||
fontFamily: FONT,
|
||||
},
|
||||
data: SERIES.map((s) => s.name),
|
||||
},
|
||||
legend: standardLegend(SERIES.map((series) => series.name)),
|
||||
grid: { left: 78, right: 56, top: LAYOUT.gridTop, bottom: 80 },
|
||||
tooltip: {
|
||||
trigger: 'axis',
|
||||
|
||||
Reference in New Issue
Block a user