]> git.openstreetmap.org Git - rails.git/commitdiff
Merge remote-tracking branch 'upstream/pull/4731'
authorTom Hughes <tom@compton.nu>
Sun, 28 Apr 2024 17:41:17 +0000 (18:41 +0100)
committerTom Hughes <tom@compton.nu>
Sun, 28 Apr 2024 17:41:17 +0000 (18:41 +0100)
app/assets/stylesheets/common.scss
app/helpers/application_helper.rb
app/views/diary_entries/index.html.erb
test/helpers/application_helper_test.rb

index 4a3317edcd78110ea2a98aa4baf5f7c08908bbfd..9aefd3d695978e929ac7517497c26a13f6bbb3ba 100644 (file)
@@ -21,11 +21,6 @@ time[title] {
 
 #container { position: relative; }
 
-.small_icon {
-  vertical-align: middle;
-  margin-right: $lineheight * 0.25;
-}
-
 /* Rules for icons */
 
 .icon {
index 368668a9bbf4fbb5c82637595ab0a09560032d56..fcf253289ea45ff65e11f0f30c5909146bfa1f10 100644 (file)
@@ -10,11 +10,11 @@ module ApplicationHelper
   end
 
   def rss_link_to(args = {})
-    link_to(image_tag("RSS.png", :size => "16x16", :border => 0), args, :class => "rsssmall")
+    link_to image_tag("RSS.png", :size => "16x16", :class => "align-text-bottom"), args
   end
 
   def atom_link_to(args = {})
-    link_to(image_tag("RSS.png", :size => "16x16", :border => 0), args, :class => "rsssmall")
+    link_to image_tag("RSS.png", :size => "16x16", :class => "align-text-bottom"), args
   end
 
   def dir
index 78ac0dcf869976bf05d4a020172e1e2c0202b90e..a0ab0264a4f7383e73d850779d6c5d0aea2aa136 100644 (file)
@@ -25,7 +25,7 @@
           <% end %>
 
           <% if @user && @user == current_user || !@user && current_user %>
-            <li><%= link_to image_tag("new.png", :class => "small_icon") + t(".new"), new_diary_entry_path, :title => t(".new_title") %></li>
+            <li><%= link_to image_tag("new.png") + t(".new"), new_diary_entry_path, :class => "icon-link", :title => t(".new_title") %></li>
           <% end %>
         </ul>
       </nav>
index a905090dba6133a8c20908f8ee308a6fbb817015..24d74c85f3b0ad5d1a06aaad93f8eaf6f4739e2d 100644 (file)
@@ -31,12 +31,12 @@ class ApplicationHelperTest < ActionView::TestCase
 
   def test_rss_link_to
     link = rss_link_to(:controller => :diary_entries, :action => :rss)
-    assert_dom_equal "<a class=\"rsssmall\" href=\"/diary/rss\"><img border=\"0\" height=\"16\" src=\"/images/RSS.png\" width=\"16\" /></a>", link
+    assert_dom_equal "<a href=\"/diary/rss\"><img height=\"16\" src=\"/images/RSS.png\" width=\"16\" class=\"align-text-bottom\" /></a>", link
   end
 
   def test_atom_link_to
     link = atom_link_to(:controller => :changesets, :action => :feed)
-    assert_dom_equal "<a class=\"rsssmall\" href=\"/history/feed\"><img border=\"0\" height=\"16\" src=\"/images/RSS.png\" width=\"16\" /></a>", link
+    assert_dom_equal "<a href=\"/history/feed\"><img height=\"16\" src=\"/images/RSS.png\" width=\"16\" class=\"align-text-bottom\" /></a>", link
   end
 
   def test_dir