style(图表): 优化条形图辅助线文本位置为固定在上方,不随横轴位置改变

This commit is contained in:
jianneng-fit2cloud
2024-12-04 15:34:27 +08:00
parent 3fd167316b
commit 5b6adbf180

View File

@@ -836,9 +836,9 @@ export function getAnalyseHorizontal(chart: Chart) {
})
assistLine.push({
type: 'text',
position: [xAxisPosition === 'left' ? 'start' : 'end', value],
position: ['start', value],
content: content,
offsetY: xAxisPosition === 'left' ? -2 : -10 * (content.length - 2),
offsetY: 5,
offsetX: 2,
rotate: Math.PI / 2,
style: {