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

[V5] Wrong custom arrow style #6425

Closed
IceLeach opened this issue Oct 22, 2024 · 1 comment · Fixed by #6448
Closed

[V5] Wrong custom arrow style #6425

IceLeach opened this issue Oct 22, 2024 · 1 comment · Fixed by #6448
Labels
element Issue about elements v5

Comments

@IceLeach
Copy link

Describe the bug / 问题描述

使用style.endArrowD自定义箭头,箭头显示位置不正确
image

Reproduction link / 重现链接

https://stackblitz.com/edit/react-1xbp7e?file=index.js

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

拖动节点,如图所示

G6 Version / G6 版本

🆕 5.x

Operating System / 操作系统

Windows

Browser / 浏览器

Chrome

Additional context / 补充说明

No response

@yvonneyx
Copy link
Contributor

yvonneyx commented Oct 29, 2024

自定义需要确保箭头形状基于原点x、y轴对称,可以调整为下述代码块:

{
    endArrowD: 'M-14,0 L-4,-4 L0,-14 L4,-4 L14,0 L4,4 L0,14 L-4,4 Z',
    endArrowOffset: 14,
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
element Issue about elements v5
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants