visgl / visgl/react-map-gl

[Bug] Resizing the window, bugs the Popup's position.

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

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
8.5k
Forks
1.4k
Avg merge
5d 17h
Merged PRs (30d)
3

Description

Description

Hello, I've been trying to figure out how to fix this behaviour of the Popup but can't find the right solution, any help will be greatly appreciated.

Here's a recording on the issue:

https://github.com/user-attachments/assets/743edbf9-7d2c-4ab4-a9e0-1375819a09ae

Expected Behavior

The Popup should stay on the same position on the map, regardless of window size.

Steps to Reproduce

Resize the window when the Popup is displayed.

Environment
  • Framework version: "react-map-gl": "^7.0.21"
  • Map library: "mapbox-gl": "^2.12.0",
  • Browser: Arc / Chrome
  • OS: MacOS Sonoma 14.6.1 (23G93)
Logs

No response

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 Popup position issue while resizing the window with react-map-gl 7.0.21 and mapbox-gl 2.12.0. Inspect the Popup behavior and resize handling, then verify that the Popup remains at the same map position after resizing.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
data-visualization, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.