maptalks / maptalks/maptalks.js

创建多个Marker.setInfoWindow,载入new ClusterLayer聚合中,缩小地图再放大地图窗口位置错误

Open
#2,116 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
HTML
Stars
4.5k
Forks
511
Avg merge
3d 58m
Merged PRs (30d)
1

Description

循环marker markerArr=[]
marker = new maptalks.Marker(center)
marker.setInfoWindow({ content: _this.$refs['MonitorWin']})
markerArr.push(marker)
new ClusterLayer('cluster', markerArr, {})

![image](https://github.com/maptalks/maptalks.js/assets/25587944/03ac352b-b783-4d2f-9193-623ff46af341)

![image](https://github.com/maptalks/maptalks.js/assets/25587944/589d5dab-53dd-47c0-a1b9-1d1fc2f5f084)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the shown Marker.setInfoWindow and ClusterLayer sequence, then zoom out and back in to observe the window position. Trace how ClusterLayer updates clustered markers and how Marker info windows are repositioned during zoom. Done means the info window remains aligned with its marker after repeated zoom changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.