WFP-VAM / prism-app

PRISM is an interactive map-based dashboard that simplifies the integration of geospatial data on hazards, along with information on socioeconomic vulnerability
MIT License
49 stars 34 forks source link

[Bug]: Chart tooltip window resizes in error #1365

Open wadhwamatic opened 2 weeks ago

wadhwamatic commented 2 weeks ago

What happened?

If you chart tooltip window is open and you then drag the map, the window often reduces its width by half, cutting off content.

Steps to replicate:

  1. Country = Cambodia
  2. Open layer: Flood > Early warning > EWS 1294
  3. Click on a point
  4. After the tooltip window is open, drag the map

Note, I've not been able to replicate this for other tooltip charts (10-day rainfall, NDVI)

Which country / deployment are you running?

Cambodia / main

Also observed in PR 1332 when using the Google Floods layers

Add a screenshot (if relevant)

Screenshot 2024-11-08 at 17 02 20
gislawill commented 1 week ago

It looks like mapbox-gl is adding this automatically (on-purpose). We can prevent this by adding a max-width none !important. I'll include in #1328 👍

https://github.com/mapbox/mapbox-gl-js/issues/1862