HoloMap.Control.Navigation (HoloMap v0.1.0)

Copy Markdown View Source

Zoom in/out buttons and a compass.

<HoloMap.Control.Navigation position="top-right" visualize_pitch />

Props

PropTypeNotes
positionstringCorner to place the control in. Default "top-right"
show_compassbooleanShow the compass. Default true
show_zoombooleanShow the zoom buttons. Default true
visualize_pitchbooleanTilt the compass needle to reflect pitch

The compass is also how a user resets a rotated map. Clicking it returns north to up. Hiding it on a map where drag_rotate is enabled leaves them with no way back.

Summary

Functions

Returns true to indicate that the callee module is a component module (has "use Hologram.Component" directive).

Returns the list of property definitions for the compiled component.

Functions

__is_hologram_component__()

@spec __is_hologram_component__() :: boolean()

Returns true to indicate that the callee module is a component module (has "use Hologram.Component" directive).

Examples

iex> __is_hologram_component__()
true

__props__()

@spec __props__() :: [{atom(), atom(), keyword()}]

Returns the list of property definitions for the compiled component.