fix: increase fitBounds padding to keep route markers inside viewport#360
fix: increase fitBounds padding to keep route markers inside viewport#360Pbhacks wants to merge 4 commits intovalhalla:masterfrom
Conversation
Fixes valhalla#265 The fitBounds padding was only 50px, which was insufficient for the 45px-tall pin markers, causing end-of-route markers to fall halfway off the screen. Increased padding to 80px on all sides (and 450px when side panels are open) to ensure markers remain fully visible.
There was a problem hiding this comment.
Pull request overview
Updates map fitBounds padding so route endpoint markers stay fully visible within the viewport, addressing the “final marker clipped at edge” behavior reported in #265.
Changes:
- Increased default
fitBoundspadding from 50px to 80px. - Increased side-panel padding from 420px to 450px when directions/settings panels are open.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ding Addresses Copilot review feedback on PR valhalla#360. screen.width reflects the physical device screen, not the browser viewport, so it doesn't respond to window resizes or split-screen. Using window.innerWidth ensures padding matches the actual viewport.
|
Preview is ready! 🚀 You can view it here: https://valhalla-app-tests.gis-ops.com/360 |
|
looks good, thanks. do note, that if this is gsoc, then this PR won't count unless you follow the gsoc guidelines. also tests are failing. |
…ding Addresses Copilot review feedback on PR valhalla#360. screen.width reflects the physical device screen, not the browser viewport, so it doesn't respond to window resizes or split-screen. Using window.innerWidth ensures padding matches the actual viewport.
7234628 to
a18884d
Compare
|
Yes sir I am eager to participate in your GSOC idea project " |
|
did you understand that you have to follow the gsoc guidelines on this PR? I won't tell you explicitly what I want to see, that document is too easy to read and understand. |
|
Yes sir I'll make the changes on the pr and also make sure the information is accurate and in depth. Also for now the tests have passed. 3/3 checks passed |
Fixes #265
The fitBounds padding was only 50px, which was insufficient for the 45px-tall pin markers, causing end-of-route markers to fall halfway off the screen. Increased padding to 80px on all sides (and 450px when side panels are open) to ensure markers remain fully visible.
🛠️ Fixes Issue
'Closes #265'
📷 Screenshots