antvis / antvis/G2Plot

🐛 [BUG]xAxis label autoRotate 超出canvas范围

Open
#3,648 1 comment 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 [Please make everyone to understand it]

配置label自动旋转的时候,改变浏览器宽度。会出现label超出canvas范围的情况
[官方链接](https://g2plot.antv.antgroup.com/zh/examples/column/basic#basic)

### 📷 Step to reproduce
1. 52行左右。将autoRotate设为true。autoHide设为false
```js
xAxis: {
label: {
autoHide: false,
autoRotate: true,
},
}
```
2. 缩小屏幕
![image](https://github.com/antvis/G2Plot/assets/24927686/aecb4405-9835-44c8-ac87-21564dd32504)

### 🏞 Expected result
完整展示出label
### 🚑 Any additional [like screenshots]

* **G2Plot Version**: 官方链接版本
* **Platform**: 官方web网站

Contributor guide

Open the contributing guide

Research direction

Start with the official G2Plot column/basic example linked in the issue and reproduce the xAxis label behavior with autoHide false and autoRotate true while narrowing the browser. Trace the responsive label layout and rotation handling; done means labels remain fully within the canvas after resizing.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
data-visualization
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.