From 8bec907f2740599daf68653284d7b9112f504a84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81ngel=20Montero=20Lamas?= Date: Fri, 8 May 2026 20:43:11 +0200 Subject: [PATCH] Style.js lists in alphabetical order --- public/modules/ui/style.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/public/modules/ui/style.js b/public/modules/ui/style.js index b94a21c5a..b99c42cf3 100644 --- a/public/modules/ui/style.js +++ b/public/modules/ui/style.js @@ -88,14 +88,14 @@ function selectStyleElement() { styleIsOff.style.display = isLayerOff ? "block" : "none"; // active group element - if (["routes", "labels", "coastline", "lakes", "anchors", "burgIcons", "borders", "terrs"].includes(styleElement)) { + if (["anchors", "borders", "burgIcons", "coastline", "lakes", "labels", "routes", "terrs"].includes(styleElement)) { const group = styleGroupSelect.value; const defaultGroupSelector = styleElement === "terrs" ? "#landHeights" : "g"; el = group && el.select("#" + group).size() ? el.select("#" + group) : el.select(defaultGroupSelector); } // opacity - if (!["landmass", "ocean", "regions", "legend"].includes(styleElement)) { + if (!["landmass", "legend", "ocean", "regions"].includes(styleElement)) { styleOpacity.style.display = "block"; styleOpacityInput.value = el.attr("opacity") || 1; } @@ -107,7 +107,7 @@ function selectStyleElement() { } // fill - if (["rivers", "lakes", "landmass", "prec", "ice", "fogging", "scaleBar", "vignette"].includes(styleElement)) { + if (["fogging", "ice", "lakes", "landmass", "prec", "rivers", "scaleBar", "vignette"].includes(styleElement)) { styleFill.style.display = "block"; styleFillInput.value = styleFillOutput.value = el.attr("fill"); } @@ -372,7 +372,7 @@ function selectStyleElement() { // update group options styleGroupSelect.options.length = 0; // remove all options - if (["routes", "labels", "coastline", "lakes", "anchors", "burgIcons", "borders", "terrs"].includes(styleElement)) { + if (["anchors", "borders", "burgIcons", "coastline", "lakes", "labels", "routes", "terrs"].includes(styleElement)) { const groups = ensureEl(styleElement).querySelectorAll("g"); groups.forEach(el => { if (el.id === "burgLabels") return;