Problem/Motivation
At the moment the only way to add custom Labels/Values for each Legend class is based on the implementation of
leaflet_choropleth_color_scale_alter hook, defined here:
https://git.drupalcode.org/project/leaflet_choropleth/-/blob/1.0.x/src/P...
and documented in leaflet_choropleth.api.php
To make all this more user friendly, also for (no coders) site builders, we could add a new Leaflet Choropleth settings section specifically focusing on the multivalue text inputs of Legend %value(s), according to the number of classes.

Proposed resolution
Add a new Leaflet Choropleth settings section/element that allows dynamic input of Legend text %value(s).
This new section would be a multivalue texts element that would dynamic (via Ajax) adjust its number of items (granularity) according the chosen Choropleth classification classes.
API changes
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | Screenshot 2025-10-02 at 00.45.34.jpg | 318.84 KB | itamair |
Comments
Comment #2
itamair commentedComment #4
itamair commentedleaflet_choropleth 1.0.6 release implements/accomplishes all this.
Comment #6
itamair commentedComment #7
ressaThanks for adding this feature @itamair, and also for including an image -- I am inserting it in the Issue Summary.