Skip to content

Commit

Permalink
Minor tweaks to copyright heading
Browse files Browse the repository at this point in the history
This fixes a small bug where the hr was shown even when not required,
by ensuring the test is run before creating the content.

Also fixes where an h1 tag was used instead of a div.
  • Loading branch information
gravitystorm committed Jan 15, 2020
1 parent 2190aad commit 1a75b1b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/views/site/copyright.html.erb
Expand Up @@ -3,7 +3,7 @@
<!-- Maybe ease foreigners back to their native page -->

<% if t(".legal_babble", :locale => I18n.locale) != t(".legal_babble", :locale => :en) %>
<%= tag.h1 :lang => @locale, :dir => t("html.dir", :locale => @locale) do %>
<%= tag.div :lang => @locale, :dir => t("html.dir", :locale => @locale) do %>
<h1><%= t ".native.title" %></h1>
<p>
<%= t ".native.html",
Expand All @@ -20,8 +20,8 @@
<% end %>
<% else %>
<!-- Maybe note that this page has been translated -->
<%= tag.div :lang => "en", :dir => t("html.dir", :locale => "en") do %>
<% if t(".legal_babble", :locale => @locale) != t(".legal_babble", :locale => :en) %>
<% if t(".legal_babble", :locale => @locale) != t(".legal_babble", :locale => :en) %>
<%= tag.div :lang => "en", :dir => t("html.dir", :locale => "en") do %>
<h1><%= t ".foreign.title" %></h1>
<p>
<%= t ".foreign.html",
Expand Down

0 comments on commit 1a75b1b

Please sign in to comment.