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

图例的Mode Api被删掉了嘛 #3771

Closed
1 task done
harrylu99 opened this issue Jan 5, 2022 · 1 comment
Closed
1 task done

图例的Mode Api被删掉了嘛 #3771

harrylu99 opened this issue Jan 5, 2022 · 1 comment

Comments

@harrylu99
Copy link

harrylu99 commented Jan 5, 2022

  • I have searched the issues of this repository and believe that this is not a duplicate.

What problem does this feature solve?

想在图例上实现单选的功能,看到旧版本是支持的

旧文档

现在文档中也没看到,加入后也不生效,是把这个功能删掉了嘛

What does the proposed API look like?

希望还可以继续支持这个功能

@visiky
Copy link
Member

visiky commented Jan 6, 2022

自己注册一个单选功能,就可以实现了。如下:单击单选,双击取消

    // 复写 图例筛选 交互。1、点击图例名称 进行 unchecked 状态的切换 2、点击图例 marker,进行 checked 状态的切换(进行聚焦)3、双击 重置状态
    chart.interaction('legend-filter', {
      start: [
        { trigger: 'legend-item:click', action: ['list-checked:checked', 'data-filter:filter'] },
      ],
      end: [{ trigger: 'legend-item:dblclick', action: ['list-checked:reset', 'data-filter:filter'] }],
    });

@hustcc hustcc closed this as completed Sep 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants