echarts [Bug] graph关系图 节点x或者y相同时,关系线显示异常,出现偏移。

up9lanfz  于 4个月前  发布在  Echarts
关注(0)|答案(3)|浏览(103)

Version

5.3.3

No response

Steps to Reproduce

设置chart option(节点y值相同)

option = {
   series: [
    {
      type: 'graph',
      data: [
          {
              "name": "A",
              "x": 40,
              "y": 10
          },
          {
              "name": "B",
              "x": 45,
              "y": 10
          }
      ],
      links: [
          {
              "source": "A",
              "target": "B",
          }
      ],
    }
  ]
};

Current Behavior

上述option配置时,关系线出现偏移:

节点x值相同时,同样会出现:

但是当设置lineStyle(大于1.5)时,关系线位置正常:

Expected Behavior

关系线位置应该保持正确

Environment

- OS: windows
- Browser: Chroem  104.0.5112.101
- Framework:

Any additional comments?

No response

pzfprimi

pzfprimi1#

@stay3hungry It seems you are not using English, I've helped translate the content automatically. To make your issue understood by more people and get helped, we'd like to suggest using English next time. 🤗
TRANSLATED

TITLE

[Bug] The graph relationship line is displayed abnormally and is offset.

BODY

Version

5.3.3

No response

Steps to Reproduce

set chart option

option = {
   series: [
    {
      type: 'graph',
      data: [
          {
              "name": "A",
              "x": 40,
              "y": 10
          },
          {
              "name": "B",
              "x": 42,
              "y": 10
          }
      ],
      links: [
          {
              "source": "A",
              "target": "B",
          }
      ],
    }
  ]
};

Current Behavior

When the above option is configured, the relationship line is offset:

But when the lineStyle is set (greater than 1.5), the relationship line position is normal:

Expected Behavior

Relationship line position should remain correct

Environment

- OS: windows
- Browser: Chroem 104.0.5112.101
- Framework:

Any additional comments?

No response

5kgi1eie

5kgi1eie2#

我出现了类似的问题,在重复加载数据时,边与节点会跑偏,但layoutAnimation打开后就好了。

相关问题