antvis/G6

[Bug]: When the 'opacity' property is set to the state of a node, the state of the node is not restored after the 'hover-activate' event ends #6700

zh-lx posted onGitHub

Describe the bug / 问题描述

inactiveState 的状态设置了 opacity: 0.3 属性,hover-activate 事件结束后,节点还是保持 opacity: 0.3 无法复原

<img width="1519" alt="image" src="https://github.com/user-attachments/assets/609faaae-f7ea-4ebb-ad6e-c962d545c7c8" />

https://g6.antv.antgroup.com/en/examples/behavior/highlight-element#config-params

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

  1. 打开上述官网的复现链接
  2. 如下图所示修改 dim 中的代码为 opacity: 0.3,鼠标 Hover 到一个节点然后移出,发现其他节点的 opacity: 0.3 无法复原

<img width="1519" alt="image" src="https://github.com/user-attachments/assets/609faaae-f7ea-4ebb-ad6e-c962d545c7c8" />

G6 Version / G6 版本

🆕 5.x

OS / 操作系统

  • macOS
  • Windows
  • Linux
  • Others / 其他

Browser / 浏览器

  • Chrome
  • Edge
  • Firefox
  • Safari (Limited support / 有限支持)
  • IE (Nonsupport / 不支持)
  • Others / 其他

这个问题已经在 Issue #6700 中被报告。当前还没有其他类似的问题被记录。

您可以在这个问题的 GitHub 页面上关注进展,开发团队可能会在此处提供解决方案或修复更新。

如果您有其他问题或需要进一步的帮助,请随时告诉我。

<details> <summary>🪧 Tips</summary> For further assistance, please describe your question in the comments and @petercat-assistant to start a conversation with me. </details>

posted by petercat-assistant[bot] 4 months ago

在 style 下配置一下默认透明度

style.opacity: 1

posted by Aarebecca 3 months ago

Fund this Issue

$0.00
Funded

Pull requests