Skip to content

feat(dashboard): zoom + pan on the world map - #7

Merged
bartbeecoders merged 1 commit into
mainfrom
feat/world-map-zoom-pan
Jun 15, 2026
Merged

feat(dashboard): zoom + pan on the world map#7
bartbeecoders merged 1 commit into
mainfrom
feat/world-map-zoom-pan

Conversation

@bartbeecoders

Copy link
Copy Markdown
Owner

Closes #3.

What

The dashboard world map is now zoomable and pannable.

  • Zoom — mouse wheel, or the + / buttons (top-right). Bounded 1×–8×.
  • Pan — drag the map (grab cursor).
  • Reset — a button returns to the default center/zoom; all controls disable when they'd be no-ops.

How

The geographies + markers are wrapped in react-simple-maps' ZoomableGroup, driven by controlled { coordinates, zoom } state shared between gestures (onMoveEnd) and the buttons. Markers counter-scale by 1/zoom so they keep a constant screen size at any zoom, and the hover tooltip is dismissed on drag start.

Test

  • npm run build
  • Dashboard → scroll to zoom, drag to pan, use the buttons; markers stay clickable and constant-sized.

🤖 Generated with Claude Code

Closes #3. The dashboard world map content is wrapped in a
ZoomableGroup so it supports wheel-zoom and drag-to-pan, plus a
top-right control cluster (zoom in / out / reset). Zoom/center is
controlled state shared by the gestures and the buttons. Markers
counter-scale by 1/zoom so they stay a constant screen size, and the
tooltip is hidden while dragging.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@bartbeecoders
bartbeecoders merged commit de30290 into main Jun 15, 2026
3 checks passed
@bartbeecoders
bartbeecoders deleted the feat/world-map-zoom-pan branch June 15, 2026 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

add zoom on world map

1 participant