[openstreetmap/openstreetmap-website] Replace custom SVG map controls with Bootstrap Icons (Fixes #6681) (PR #6695)

Snehal Jadhav notifications at github.com
Fri Jan 16 15:58:29 UTC 2026


@snehaljadhav7317 commented on this pull request.



> +      if (button.classList.contains("maplibregl-ctrl-zoom-in")) {
+        const icon = document.createElement("i");
+        icon.className = "bi bi-plus-lg";
+        button.appendChild(icon);
+      } else if (button.classList.contains("maplibregl-ctrl-zoom-out")) {
+        const icon = document.createElement("i");
+        icon.className = "bi bi-dash-lg";
+        button.appendChild(icon);
+      } else if (button.classList.contains("maplibregl-ctrl-geolocate")) {
+        const icon = document.createElement("i");
+        icon.className = "bi bi-cursor-fill";
+        button.appendChild(icon);
+      }

@hlfan Thanks for the suggestion! I've updated the code to use an `iconMap` object. 

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6695#discussion_r2699076290
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/6695/review/3671582027 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20260116/ebb33d21/attachment.htm>


More information about the rails-dev mailing list