antvis / antvis/G2Plot

🐛 [BUG]柱状图在设置自定义颜色后meta中的alias失效

Open
#3,402 0 comments 0 reactions 0 assignees View on GitHub
Bug
Dominant language
TypeScript
Stars
2.7k
Forks
591
PR merge metrics
No merged PRs in 30d

Description

### 🐛 Bug description 柱状图在设置自定义颜色后meta中的alias失效

**Link to minimal reproduction**: https://codesandbox.io/s/hungry-carson-xb8gh7

### 📷 Step to reproduce
Column配置项:
```
meta: {
type: {
alias: '类别',
},
sales: {
alias: '销售额',
},
},
color:(arg) => {
return '#6596f9'
}
```

### 🏞 Expected result

柱状图颜色与Tooltip 按配置显示

### 🚑 Any additional [like screenshots]
颜色生效 但Tooltip未按照配置进行显示
![image](https://user-images.githubusercontent.com/16083363/203517032-01f40bf7-b6a0-4473-bd66-503ccfc9173f.png)

* **G2Plot Version**:
* **Platform**:

Contributor guide

Open the contributing guide

Research direction

Start with the linked CodeSandbox reproduction and the Column configuration using meta aliases together with a custom color function. Trace the Column chart's tooltip and alias handling, then confirm that the custom color still applies while the configured aliases appear in the tooltip.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
data-visualization, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.