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

点图层标签支持 #2341

Open
foxii-cn opened this issue Mar 11, 2024 · 3 comments
Open

点图层标签支持 #2341

foxii-cn opened this issue Mar 11, 2024 · 3 comments
Assignees

Comments

@foxii-cn
Copy link

问题描述

目前官网示例点图层标签的解决方案是再加一个使用相同数据的点图层,但是这样有很多不方便的地方,比如鼠标的hover高亮、鼠标点击,标签和点作为两个对象行为并不一致,有割裂感(标签hover的时候点不会高亮,点击也是类似,是两个事件),要么就需要额外很多代码手动去维护这个一致性

重现链接

No response

重现步骤

No response

预期行为

点图层支持设置标签,并且默认提供一致的鼠标交互行为,就像一个整体

平台

  • 操作系统: [macOS, Windows, Linux, React Native ...]
  • 网页浏览器: [Google Chrome, Safari, Firefox]

屏幕截图或视频(可选)

No response

补充说明(可选)

No response

@lzxue
Copy link
Contributor

lzxue commented Mar 11, 2024

最好的方案还是通过 通过 setSelect或者setActive 进行联动

@foxii-cn
Copy link
Author

最好的方案还是通过 通过 setSelect或者setActive 进行联动

另一个问题,有办法在Active中更改透明度吗

试了下颜色值传rgba没有作用,由于地图主题能更换所以提前计算颜色替换也行不通

@lzxue
Copy link
Contributor

lzxue commented Mar 15, 2024

最好的方案还是通过 通过 setSelect或者setActive 进行联动

另一个问题,有办法在Active中更改透明度吗

试了下颜色值传rgba没有作用,由于地图主题能更换所以提前计算颜色替换也行不通

目前active 的的透明度和设图层的opacity 的一致的

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