[Bug] The `axisLabel.height` property does not take effect when no background color is set
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 35/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- typescript
调研方向
从链接的 ECharts 最小复现开始,比较两个 axisLabel 配置,先仅使用 height,然后再使用 backgroundColor。跟踪 axisLabel.height 如何影响类目轴标签布局,并通过确认在没有背景色的情况下 150px 高度生效,同时保留现有的背景色案例来验证修复。
由索引模型根据 Issue 内容生成。
描述
Version
6.0.0
Link to Minimal Reproduction
Steps to Reproduce
- Create a regular bar chart
- Set the height of the axis label without setting the background color
Current Behavior
option = {
color: ["#3398DB"],
tooltip: {
trigger: "axis",
axisPointer: {
type: "shadow"
}
},
grid: {},
xAxis: [{
type: "category",
data: ["Mo", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"],
axisLabel: {
height: 150
}
}],
yAxis: [{
type: "value"
}],
series: [{
name: "直接访问",
type: "bar",
barWidth: "60%",
data: [10, 52, 200, 334, 390, 330, 220]
}]
}
Expected Behavior
option = {
color: ["#3398DB"],
tooltip: {
trigger: "axis",
axisPointer: {
type: "shadow"
}
},
grid: {},
xAxis: [{
type: "category",
data: ["Mo", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"],
axisLabel: {
height: 150,
backgroundColor: 'red'
}
}],
yAxis: [{
type: "value"
}],
series: [{
name: "直接访问",
type: "bar",
barWidth: "60%",
data: [10, 52, 200, 334, 390, 330, 220]
}]
}
Environment
- OS: mac os
- Browser: chrome
Any additional comments?
No response
- 主要语言
- TypeScript
- 星标
- 67.7k
- 派生
- 19.9k
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
apache/echarts 的其他 Issue
-
[Bug] String formatter templates only replace the first occurrence of `{a}`/`{b}`/`{c}`可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭en pending
难度 2/5 1-3 小时 新手友好度 80/100
-
[Bug] Inverse axis collapses the grid with outerBoundsContain when a tick is near the axis edge可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭en pending
难度 2/5 1-3 小时 新手友好度 82/100
-
en pending
难度 2/5 1-3 小时 新手友好度 78/100
-
en pending
难度 2/5 1-3 小时 新手友好度 78/100
-
[Bug] The zoom cursor in the toolbox area is incorrect可能已有人在做 @waterWang 于 98 天前认领。 未关闭bug en pending
难度 2/5 1-3 小时 新手友好度 70/100
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 83/100
pollen-robotics/reachy-mini-desktop-app#341 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 77/100
mike-north/AgentMonitors#648 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
vercel-labs/ui#700 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
维护者通常 2 天内回复