]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/traces/_trace.html.erb
Localisation updates from https://translatewiki.net.
[rails.git] / app / views / traces / _trace.html.erb
index 9b377eb8148252bc5535c94467dd762f9ee4c825..8b754a591d35803eb2312378fa8d8897cc8f1d2d 100644 (file)
       ... <%= time_ago_in_words(trace.timestamp, :scope => :'datetime.distance_in_words_ago') %></span>
       <%= link_to_if trace.inserted?, t(".map"), { :controller => "site", :action => "index", :mlat => trace.latitude, :mlon => trace.longitude, :anchor => "map=14/#{trace.latitude}/#{trace.longitude}" }, { :title => t(".view_map") } %> /
       <%= link_to t(".edit"), { :controller => "site", :action => "edit", :gpx => trace.id }, { :title => t(".edit_map") } %>
-      <span class="trace_<%= trace.visibility %>"><%= t("." + trace.visibility) %></span>
+
+      <% badge_class = case trace.visibility
+                       when "public", "identifiable" then "success"
+                       else "danger"
+                       end %>
+      <span class="badge badge-<%= badge_class %> text-white"><%= t("." + trace.visibility) %></span>
+
       <br />
       <%= trace.description %>
     <br />