[openstreetmap/openstreetmap-website] Store routing icons separately (PR #6189)

Anton Khorev notifications at github.com
Sun Jul 13 15:50:37 UTC 2025


@AntonKhorev commented on this pull request.



> -    <path d="M9 14 v-8" opacity=".5" />
-    <path d="M9 17 v-3 q0 -2 2 -4 l5 -5 m0 0 h-3 l3 3 z" />
-  </symbol>
-  <symbol id="routing-sprite-exit-left">
-    <use href="#routing-sprite-exit-right" transform="matrix(-1 0 0 1 20 0)" />
-  </symbol>
-
-  <symbol id="routing-sprite-ferry" fill="none" stroke="currentColor" stroke-width="1">
-    <path d="M10.5 8 l-6 2 l2.5 2 v1.5 a2.828 2.828 0 0 1 1.5 1 a2.828 2.828 0 0 1 4 0 a2.828 2.828 0 0 1 1.5 -1 v-1.5 l2.5 -2 z" fill="currentColor" />
-    <path d="M6.5 9.5 v-5 h8 v5 m-5.5 -6 h3" />
-    <path d="M5.5 16.5 a1.414 2.828 0 0 1 2 0 a1.414 2.828 0 0 0 2 0 a1.414 2.828 0 0 1 2 0 a1.414 2.828 0 0 0 2 0 a1.414 2.828 0 0 1 2 0" />
-  </symbol>
+<svg class="d-none">
+  <% Rails.root.glob("app/assets/images/routing/*.svg").each do |path| %>
+    <%= inline_svg_tag "routing/#{File.basename(path)}", :id => "routing-sprite-#{File.basename(path, '.svg')}", :to_symbol => true %>
+  <% end %>
 </svg>

Why the mirroring had to be removed?

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

Message ID: <openstreetmap/openstreetmap-website/pull/6189/review/3014203210 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250713/d6698b34/attachment.htm>


More information about the rails-dev mailing list