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

边的阴影问题 #3990

Open
ajesses opened this issue Oct 25, 2023 · 1 comment
Open

边的阴影问题 #3990

ajesses opened this issue Oct 25, 2023 · 1 comment
Labels
type: discussion 讨论 Usage questions, guidance, and other discussions

Comments

@ajesses
Copy link

ajesses commented Oct 25, 2023

问题描述

当边是垂直(source与target的x坐标相同)或者水平(source与target的y坐标相同)时,阴影未显示,边也显示不出来

重现链接

https://codesandbox.io/s/epic-darkness-fxvvm6?file=/index.ts

重现步骤

数据:

graph.addEdge({
  source: { x: 340, y: 40 },
  target: { x: 340, y: 280 },
  attrs: {
    line: {
      stroke: '#f5222d',
      strokeWidth: 20,
      filter: {
        name: 'dropShadow',
        args: {   
          color: '#4943a3',
          dx: 10,
          dy: 10,
          blur: 10,
          opacity: 1,
        },
      },
    },
  },
})

添加阴影滤镜后:
image
image

未添加阴影滤镜:
image
image

预期行为

垂直方向和水平方向阴影正常显示

平台

  • 操作系统: Windows
  • 网页浏览器: Google Chrome
  • X6 版本: 2.15.2

屏幕截图或视频(可选)

No response

补充说明(可选)

No response

@NewByVector
Copy link
Contributor

参考这个 demo,使用 filterUnits 属性可以解决。

@NewByVector NewByVector added the type: discussion 讨论 Usage questions, guidance, and other discussions label Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: discussion 讨论 Usage questions, guidance, and other discussions
Projects
None yet
Development

No branches or pull requests

2 participants