Can multiple y-axes share a single x-axis and be arranged vertically?

未关闭
#21,509 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
30/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
停滞
技术栈
typescript

调研方向

首先检查 ECharts 中现有的 xAxis、yAxis 和 series 选项是如何处理的。将该行为与提议的共享 x 轴、垂直排列的 y 轴项、同步标记以及按轴分组 series 进行比较。在不使用自定义 chart.render 矩形和文本的情况下,实现所请求的布局和交互即表示完成。

由索引模型根据 Issue 内容生成。

描述

en new-feature pending
What problem does this feature solve?
Image Hello: I want to achieve an effect like the one shown in Figure 1: 1. Display multiple ·yAxis· in a single group. 2. When the mouse moves, the marker lines remain consistent across each yAxis (correctly displaying the values corresponding to each indicator for the current date). 3. Be able to flexibly control which series are displayed in each yAxis

This chart is implemented using Highcharts12, where the height of each yAxis is calculated as plotHeight - (Vpadding * (item.length - 1)) / item.length. The space between each yAxis is used to draw the legend. Here, I achieved this by drawing rectangles and text using chart.render. I would like to ask if ECharts can achieve such graphic effects?

What does the proposed API look like?

option = {
xAxis: [
{
id: 'xAxis-1'
},
{
id: 'xAxis-1'
}
],
yAxis: [
{
id:'group1',
type: 'multiple',
items: [
{
xAxisId: 'xAxis-1',
top:0,
height'45%',
padding:'5%'
},
{
xAxisId: 'xAxis-1',
top:'50%',
height'45%',
padding:'5%'
},
{
//...
}
]
}
],
series: [
{
xAxisId: 'xAxis-1',
group: 'group1',
data: []
},
{
xAxisId: 'xAxis-1',
group: 'group1',
data: []
},
{
xAxisId: 'xAxis-1',
group: 'group2',
data: []
}
]
};
----PS: This options is how I imagine it 😀.

主要语言
TypeScript
星标
67.7k
派生
19.9k
PR 合并指标
30 天内没有已合并 PR

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

apache/echarts 的其他 Issue

查看 apache/echarts 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。