We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
设置了cluster和clusterOption的maxZoom,point_min。但是依然在聚合数量为1的情况下,点标记显示的是聚合样式而非原本的点标记。有其他配置或者方法可以解决吗,MarkerLayer和PointLayer都尝试了,全都不行。
No response
The text was updated successfully, but these errors were encountered:
const markerLayer = new MarkerLayer({ cluster: true, clusterOption: { radius: 40, minZoom: 0, maxZoom: 8, point_min: 2, }, }); for (let i = 0; i < pointData.features.length; i++) { const el = document.createElement("label"); el.className = "labelclass"; el.textContent = pointData.features[i].properties.name; el.style.background = "#fff"; const marker = new Marker({ element: el, }).setLnglat({ lng: pointData.features[i].geometry.coordinates[0], lat: pointData.features[i].geometry.coordinates[1], }); markerLayer.addMarker(marker); } scene.addMarkerLayer(markerLayer);
想聚合为1时显示原本Marker的element
Sorry, something went wrong.
https://gw.alipayobjects.com/mdn/rms_855bab/afts/img/A*2vBbRYT2bgIAAAAAAAAAAABkARQnAQ 官网Marker文档这个图片的效果就是我想要的,但是没有找到相关配置和示例
找到了个解决办法,设置clusterOption的element,在没有cluster的时候这是点标记原本的dom样式
lvisei
No branches or pull requests
问题描述
设置了cluster和clusterOption的maxZoom,point_min。但是依然在聚合数量为1的情况下,点标记显示的是聚合样式而非原本的点标记。有其他配置或者方法可以解决吗,MarkerLayer和PointLayer都尝试了,全都不行。
重现链接
No response
重现步骤
No response
预期行为
No response
平台
屏幕截图或视频(可选)
No response
补充说明(可选)
No response
The text was updated successfully, but these errors were encountered: