Skip to content

v0.1.0

Choose a tag to compare

@ecrespo ecrespo released this 11 Sep 01:36
· 34 commits to main since this release
f2e5fec

First public release of reflex-mapcn, mapcn map components for Reflex.

pip install reflex-mapcn

PyPI: https://pypi.org/project/reflex-mapcn/0.1.0/

What's in it

  • Free CARTO basemap that follows Reflex's light/dark color mode automatically
  • Markers with content, tooltips, popups, labels and dragging
  • Standalone popups, plus zoom, compass, locate and fullscreen controls
  • Routes with progress tracking and route-anchored markers
  • Curved arcs, GeoJSON fill and outline layers with hover state, native clustering
  • Controlled viewport, globe projection, custom styles and a blank basemap
  • map_camera, a Reflex-only extra for driving flyTo, easeTo, jumpTo and fitBounds from state

Every callback delivers JSON-serialisable payloads, so handlers bind directly to Reflex event handlers. maplibre-gl is the single npm dependency and Reflex installs it on the first compile. Type stubs ship with the package, so editors get autocomplete on every prop.

Demo app

The repository includes mapcn_demo, a Reflex app with one page per feature, including a Venezuela state map backed by a bundled GeoJSON.

Requirements

Python 3.10 or newer, Reflex 0.8.1 or newer.