X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/63303c22b704ca290c16ae908da1324f3ea25b2c..7406ae5dcc9cbb177a8ea33085af9caf6e3ebb1b:/app/helpers/browse_tags_helper.rb diff --git a/app/helpers/browse_tags_helper.rb b/app/helpers/browse_tags_helper.rb index 2bd547fde..04d9a6c20 100644 --- a/app/helpers/browse_tags_helper.rb +++ b/app/helpers/browse_tags_helper.rb @@ -34,9 +34,13 @@ module BrowseTagsHelper end safe_join(phones, "; ") elsif colour_value = colour_preview(key, value) - tag.span("", :class => "colour-preview-box", :"data-colour" => colour_value, :title => t("browse.tag_details.colour_preview", :colour_value => colour_value)) + colour_value + svg = tag.svg :width => 14, :height => 14, :class => "float-end m-1" do + concat tag.title t("browse.tag_details.colour_preview", :colour_value => colour_value) + concat tag.rect :x => 0.5, :y => 0.5, :width => 13, :height => 13, :fill => colour_value, :stroke => "#2222" + end + svg + colour_value else - safe_join(value.split(";").map { |x| linkify(h(x)) }, ";") + safe_join(value.split(";", -1).map { |x| linkify(h(x)) }, ";") end end