Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]:[V5] Using Polyline and setting router to orth will result in an error when you click to create an edge or drag and drop to create an edge #6654

Open
2 of 10 tasks
FESSXX opened this issue Dec 19, 2024 · 2 comments
Labels
Need Improvement Lack of information or incorrect format status: waiting for maintainer These issues have not yet been reviewed by a maintainer

Comments

@FESSXX
Copy link

FESSXX commented Dec 19, 2024

Describe the bug / 问题描述

使用Polyline 折线并设置router为orth 点击创建边或拖拽创建边控制台都会报错,官网案例加上
edge: { type: 'polyline', style: { router: { type: 'orth' } } }
鼠标在点击节点开始创建线后在图中多次移动后出现。
image

Reproduction link / 复现链接

No response

Steps to Reproduce the Bug or Issue / 重现步骤

import { Graph } from '@antv/g6';

const graph = new Graph({
container: 'container',
data: {
nodes: [
{ id: 'node1' },
{ id: 'node2' },
{ id: 'node3' },
{ id: 'node4' },
{ id: 'node5' }
],
edges: [
{ source: 'node1', target: 'node2' },
{ source: 'node1', target: 'node3' },
{ source: 'node1', target: 'node4' },
{ source: 'node2', target: 'node3' },
{ source: 'node3', target: 'node4' },
{ source: 'node4', target: 'node5' },
],
},
layout: {
type: 'grid',
},
edge: {
type: 'polyline',
style: {
router: {
type: 'orth',
},
},
},
behaviors: [
{
type: 'create-edge',
trigger: 'click',
style: {
stroke: 'red',
lineWidth: 2,
},
},
],
});

graph.render();

G6 Version / G6 版本

🆕 5.x

OS / 操作系统

  • macOS
  • Windows
  • Linux
  • Others / 其他

Browser / 浏览器

  • Chrome
  • Edge
  • Firefox
  • Safari (Limited support / 有限支持)
  • IE (Nonsupport / 不支持)
  • Others / 其他
@FESSXX FESSXX added the status: waiting for maintainer These issues have not yet been reviewed by a maintainer label Dec 19, 2024
@github-actions github-actions bot changed the title [Bug]: V5】使用Polyline 折线并设置router为orth 点击创建边或拖拽创建边控制台都会报错 [Bug]: V5: Using Polyline and setting router to orth Clicking to create edge or dragging to create edge console will give an error Dec 19, 2024
@FESSXX FESSXX changed the title [Bug]: V5: Using Polyline and setting router to orth Clicking to create edge or dragging to create edge console will give an error [Bug]:【 V5】使用Polyline 折线并设置router为orth 点击创建边或拖拽创建边控制台都会报错 Dec 19, 2024
@github-actions github-actions bot changed the title [Bug]:【 V5】使用Polyline 折线并设置router为orth 点击创建边或拖拽创建边控制台都会报错 [ Bug]: [ V5] Using Polyline and setting router to orth will give an error when clicking to create an edge or dragging and dropping to create an edge Dec 19, 2024
@FESSXX FESSXX changed the title [ Bug]: [ V5] Using Polyline and setting router to orth will give an error when clicking to create an edge or dragging and dropping to create an edge [Bug]:【V5】 使用Polyline 折线并设置router为orth 点击创建边或拖拽创建边控制台都会报错 Dec 19, 2024
@github-actions github-actions bot changed the title [Bug]:【V5】 使用Polyline 折线并设置router为orth 点击创建边或拖拽创建边控制台都会报错 [Bug]:[V5] Using Polyline and setting router to orth will result in an error when you click to create an edge or drag and drop to create an edge Dec 19, 2024
@FESSXX
Copy link
Author

FESSXX commented Dec 19, 2024

这个点击创建边时复现错误的操作

Jietu20241219-182621-HD.mp4

这个是拖拽创建边是复现错误的操作

Jietu20241219-182839-HD.mp4

@Aarebecca Aarebecca added the Need Improvement Lack of information or incorrect format label Dec 20, 2024
Copy link

Please provide more information, or use the standard format, otherwise we will not process this issue.
Reference document:


请提供更多信息,或者使用规范的格式,否则我们不会处理这个 issue。
参考文档:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Need Improvement Lack of information or incorrect format status: waiting for maintainer These issues have not yet been reviewed by a maintainer
Projects
None yet
Development

No branches or pull requests

2 participants