Skip to contents

This function generates an HTML representation of a legend entry for a vector overlay layer. The legend entry consists of a colored circle with a label indicating the layer's name.

Usage

map_legend_vector_overlayer(layer_label, color)

Arguments

layer_label

A character string representing the label or name of the vector overlay layer.

color

text the legend marker color.

Value

An HTML div element representing the legend entry for the vector overlay layer.

Examples

# Create a legend entry for a vector overlay layer
legend_entry <- map_legend_vector_overlayer(layer_label = "ROE", color = "blue")
print(legend_entry)
#> <div style="display: flex; align-items: center;">
#>   <div style="background-color: blue;&#10;border-radius: 50%; width: 10px;&#10;height: 10px; margin-top: 3px;"></div>
#>   <span style="margin-left: 5px; font-size: 0.8rem;">ROE</span>
#> </div>