ui/locations/entries/key
The key entry module exports a default [location] entry method to process infoj type:key entries.
Dictionary entries:
- layer_visibility
Requires
Methods
(inner) key(entry) → {HTMLElement}
mapp.ui.locations.entries.key(entry)
The entry method returns a button HTML element which will toggle the location.layer display.
The button classList reflects whether the layer is displayed or not.
{
"type":"key",
"hideLayer": true
}
Parameters:
Properties| Name | Type | Description |
|---|---|---|
entry | object |
| Name | Type | Attributes | Description |
|---|---|---|---|
entry.location.layer | location | The Mapp location object. | |
location.layer | layer | The Mapp location layer object. | |
entry.hideLayer | boolean | <optional> | Optional flag to hide the layer on load. |
Returns:
The button key element, with an onclick event to toggle the visibility of the layer.
- Type:
- HTMLElement