[openstreetmap/openstreetmap-website] Fix incorrect z-order of dashboard map markers (fixes #6639) (PR #6654)

Anshul Zilpe notifications at github.com
Thu Jan 1 05:29:45 UTC 2026


@aNsHuL5217 commented on this pull request.



>            .setPopup(OSM.MapLibre.getPopup(user.description))
           .addTo(map);
-      }
-    });
+
+        return { marker, lat, lon };
+      })
+      .get();
+
+    const updateZIndex = () => {
+      markerObjects.forEach((item) => {
+        item.currentY = map.project([item.lon, item.lat]).y;
+      });
+      markerObjects.sort((a, b) => a.currentY - b.currentY);
+      markerObjects.forEach((item, index) => {

I have replaced the `forEach` with `for-of `loops.

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

Message ID: <openstreetmap/openstreetmap-website/pull/6654/review/3621615992 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20251231/03051ef1/attachment.htm>


More information about the rails-dev mailing list