From 3334db3fa2a1f58e3adfd95ad210cfb4f8735fee Mon Sep 17 00:00:00 2001 From: Yohan Boniface Date: Mon, 9 Oct 2023 12:38:10 +0200 Subject: [PATCH] Use Range input for choropleth steps, and limit to 9 This limit comes from ColorBrower sequential color sets, which we use. --- umap/static/umap/js/umap.layer.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/umap/static/umap/js/umap.layer.js b/umap/static/umap/js/umap.layer.js index 3b207142..21dc85e1 100644 --- a/umap/static/umap/js/umap.layer.js +++ b/umap/static/umap/js/umap.layer.js @@ -207,7 +207,10 @@ L.U.Layer.Choropleth = L.FeatureGroup.extend({ [ 'options.choropleth.steps', { - handler: 'IntInput', + handler: 'Range', + min: 3, + max: 9, + step: 1, placeholder: L._('Choropleth steps'), helpText: L._('Choropleth steps (default 5)'), },