Fix hotspot overlay positioning during map drag#43
Merged
koala73 merged 2 commits intoFeb 12, 2026
Merged
Conversation
- Add updateHotspotPositions() method that updates overlay positions in real-time during map movement - Call updateHotspotPositions() on 'move' event to prevent overlays from lagging behind their geographic positions - Fixes issue where high-activity/breaking hotspot markers would drift during drag and snap back on release - Add dev mode helper to force 3 random hotspots as breaking for testing overlay behavior The HTML overlays for high-activity hotspots (level=high or hasBreaking=true) were only updating positions on a throttled/delayed basis (100ms), causing them to maintain screen position while the map moved underneath, then snap back when the update triggered. Now they update smoothly every frame during map movement.
|
@Ahmadhamdan47 is attempting to deploy a commit to the eliehabib projects Team on Vercel. A member of the Team first needs to authorize it. |
Owner
|
thank you @Ahmadhamdan47 |
facusturla
pushed a commit
to facusturla/worldmonitor
that referenced
this pull request
Feb 27, 2026
## Summary Fixes visual lag where high-activity hotspot overlays drift from their geographic positions during map panning operations. ## Problem HTML overlays for high-activity hotspots (`level=high` or `hasBreaking=true`) were only updating positions on a throttled 100ms delay. During map drag operations, this caused overlays to maintain their screen position while the map moved underneath, resulting in a "drift and snap" effect where markers would float away from their true locations then jump back when the update triggered. ## Solution - Added `updateHotspotPositions()` method that synchronizes overlay positions with the map viewport in real-time during movement - Bound method to the map `'move'` event for frame-by-frame position updates during drag operations - Eliminated the 100ms throttle delay for position calculations during active map movement ## Changes - **Added** `updateHotspotPositions()` method for real-time overlay position synchronization - **Added** `'move'` event listener to trigger position updates during map drag/pan - **Fixed** drifting issue for high-activity and breaking hotspot markers - **Added** dev mode helper to force 3 random hotspots as `breaking` for easier overlay behavior testing (for some reason they just weren't appearing on localhost) https://github.com/user-attachments/assets/a1cfe749-69bb-499c-b396-24054e7891ce https://github.com/user-attachments/assets/59c4265a-0667-4ea9-a657-a4f67f983f1e
8 tasks
scorphx
pushed a commit
to scorphx/sauron
that referenced
this pull request
Apr 6, 2026
- koala73#34: Remove isProUser() guard from setupAuthWidget(). New users now see the sign-in button and can create accounts. The guard was intentionally deferred; removing it is the stated end-state. Close stale todos whose fixes already landed in prior PRs: - koala73#10: inferEntityClassFromName word-boundary regex (already in code) - koala73#11: entity key collision fix using candidateStateId (already in code) - koala73#12: priorWorldState threading to writeSimulationPackage (already in code) - koala73#13: sanitizeForPrompt on simulation builder strings (already in code) - koala73#14: allForecastIdSet Set-based lookup (already in code) - koala73#35: algorithms:['RS256'] in jwtVerify (already in auth-session.ts) - koala73#41: frameworkHash in deduct-situation cache key (already in code) - koala73#42: isCallerPremium server-side premium gate (already in code) - koala73#43: SSRF — ALLOWED_AGENTSKILLS_HOSTS + redirect:manual (already fixed) - koala73#44: sanitizeForPrompt on systemAppend before LLM (already in code) - koala73#45: systemAppend included in getCacheKey (already in code) - koala73#49: shippingStress/diseaseOutbreaks/socialVelocity in BOOTSTRAP_KEYS https://claude.ai/code/session_015fz1MvRuBJGYbgHubGEabA
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes visual lag where high-activity hotspot overlays drift from their geographic positions during map panning operations.
Problem
HTML overlays for high-activity hotspots (
level=highorhasBreaking=true) were only updating positions on a throttled 100ms delay. During map drag operations, this caused overlays to maintain their screen position while the map moved underneath, resulting in a "drift and snap" effect where markers would float away from their true locations then jump back when the update triggered.Solution
updateHotspotPositions()method that synchronizes overlay positions with the map viewport in real-time during movement'move'event for frame-by-frame position updates during drag operationsChanges
updateHotspotPositions()method for real-time overlay position synchronization'move'event listener to trigger position updates during map drag/panbreakingfor easier overlay behavior testing (for some reason they just weren't appearing on localhost)Before.mp4
After.mp4