Components
Map
Lightweight decorative map surface that plots labelled pins at relative coordinates.
Map is a lightweight, dependency-free map surface for dropping labelled pins
onto a stylised grid — handy for simple location callouts where a full mapping
library would be overkill. Pass markers, each with an id, label, and x/y
as percentages within the container, and set height (defaults to 320).
Example
Preview
WarehouseRoute AStore #42
import { Map } from '@officina/ui';
<Map
markers={[
{ id: 'hq', label: 'HQ', x: 40, y: 55 },
{ id: 'warehouse', label: 'Warehouse', x: 70, y: 30 },
]}
height={320}
/>;API
| Prop | Type | Default | Description |
|---|---|---|---|
| className | string | — | Extra classes for the map container. |
| height | number | 320 | Map height in px. |
| markers | MapMarker[] | [] | Pins to render on the map. |