UI Settings
The UI accepts a settings object to customise certain features and behaviours. The settings are merged with the defaults on load.
boolean 60 "long", "short" or undefined true// ... UI setup
uiElement.wayfinder = wayfinder;
uiElement.settings = {
features: {
zoomControls: false,
},
behaviour: {
showEmptyCategories: true,
}
}
// ... rest of map setup
Features
All feature flags are within a parent features object.
| Key | Type | Default | Description | |
| floorSelector | boolean | true |
Show/hide the floor selector | |
| zoomControls | boolean | true |
Show/hide the zoom controls | |
| currentLocation | boolean | true |
Show/hide the 'current location' button | |
| routing | boolean | true |
Show/hide the routing button on destinations | |
| routingInfo | boolean | true |
Show/hide the routing information, such as distance and time. If routing is disabled, routingInfo is disabled too. |
|
| suggestions | boolean | Show destination/amenity suggestions |
Behaviour
All behaviour modifiers are within a parent behaviour object.
| Key | Type | Default | Description |
| zoomToDestination | boolean | true |
Whether to zoom into a destination on the map when it is selected. |
| showEmptyCategories | boolean | false |
Whether to show destination categories and amenity types that have no destinations. |
| floorNamePreference | "long", "short" or undefined |
undefined |
By default, the UI shows long floor names on desktop, and short floor names on mobile. You can override this behaviour and always show 'long' or 'short' names. |
| openingHoursPreference | "long", "short" or undefined |
undefined |
By default, the UI shows full day names (e.g. Monday) on desktop and short day names (e.g. Mon) on mobile. You can override this behaviour and always show 'long' or 'short' day names. |
| enableLinks | boolean | true |
Whether to enable hyperlinks. If set to false, links will be rendered as text. This is useful in kiosk environments |
| soonDuration | number | 60 |
Duration in minutes used for calculating 'Opening Soon' and 'Closing Soon' |
| maxCategoriesTags | number | 5 |
Maximum number of Categories / Tags to show before truncating |
| dragHidesInfo | boolean | true |
Whether the info box should be collapsed when the user drags the map. |
| zoomOnInitialLoad | boolean | true |
Whether to zoom into the starting map once it has loaded |
| distanceUnits | 'meters' or 'yards | 'meters' |
Option to show distance in meters or yards. |
| timeFormat | '12h' or '24h' | '12h' |
Option to show time in 12 or 24 hour format. |