/ui/layers/legends/categorized
The categorized theme legend module exports the categorizedTheme to the ui.layers.legend{}
library object.
Requires
Methods
(inner) catToggle(e, layer, cat)
The method toggles the disabled class on the event target element.
If toggled [on] the filterAdd method will be called and the style will be set to null.
If toggled [off] the filterRemove method will be called and the style will be restored from the cat._style.
Name | Type | Description |
---|---|---|
e | Event | The cat label click event. |
layer | layer | The decorated mapp layer. |
cat | object | The cat object from the theme. |
(inner) categorizedTheme(layer) → {HTMLElement}
The categorizedTheme method creates and returns a categorized theme legend for the current layer.style.theme.
Name | Type | Description |
---|---|---|
layer | layer | The decorated mapp layer. |
The categorized theme legend element.
- Type:
- HTMLElement
(inner) filterAdd(layer, cat)
Add the cat value to the current filter.
Name | Type | Description |
---|---|---|
layer | layer | The decorated mapp layer. |
cat | object | The cat object from the theme. |
(inner) filterRemove(layer, cat)
Remove the cat value to the current filter.
Name | Type | Description |
---|---|---|
layer | layer | The decorated mapp layer. |
cat | object | The cat object from the theme. |