@hlfan commented on this pull request.
> }
function showSearchResult() {
- let marker = $(this).data("marker");
-
- if (!marker) {
- const data = $(this).find("a.set_position").data();
-
- marker = L.marker([data.lat, data.lon], { icon: OSM.getMarker({}) });
-
- $(this).data("marker", marker);
- }
-
+ const index = processedResults++;
+ const listItem = $(this);
+ const color = `hwb(${(index * (Math.sqrt(5) - 1) * 180) % 360}deg 5% 5%)`;
I found that the first colors, when rotating the other way, line up more with
the other marker colors:
|+angle|-angle|
|-|-|
|`#0df250`|`#0d50f2`|
|`#930df2`|`#93f20d`|
Yeah, pulling out that variable is a good idea.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6235#discussion_r2233905196
You are receiving this because you are subscribed to this thread.
Message ID:
<openstreetmap/openstreetmap-website/pull/6235/review/[email protected]>_______________________________________________
rails-dev mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/rails-dev