Move public editing content into its own partial
This makes the editing page easier to read, and simplifies the i18n in the public editing section.
This commit is contained in:
parent
c7e9888bb6
commit
e11c70f751
3 changed files with 25 additions and 24 deletions
14
app/views/accounts/_go_public.html.erb
Normal file
14
app/views/accounts/_go_public.html.erb
Normal file
|
@ -0,0 +1,14 @@
|
|||
<hr class="mb-3" />
|
||||
<a name="public"></a>
|
||||
<h2><%= t ".heading" %></h2>
|
||||
<p>
|
||||
<%= t ".currently_not_public" %>
|
||||
<strong><%= t ".only_public_can_edit" %></strong>
|
||||
<%= t ".find_out_why_html", :link => link_to(t(".find_out_why"),
|
||||
t(".find_out_why_url")) %>
|
||||
</p>
|
||||
<ul>
|
||||
<li><%= t ".email_not_revealed" %></li>
|
||||
<li><%= t ".not_reversible" %></li>
|
||||
</ul>
|
||||
<%= button_to t(".make_edits_public_button"), user_go_public_path, :class => "btn btn-primary" %>
|
|
@ -65,18 +65,5 @@
|
|||
<% end %>
|
||||
|
||||
<% unless current_user.data_public? %>
|
||||
<hr class="mb-3" />
|
||||
<a name="public"></a>
|
||||
<h2><%= t ".public editing note.heading" %></h2>
|
||||
<p>
|
||||
<%= t ".public editing note.currently_not_public" %>
|
||||
<strong><%= t ".public editing note.only_public_can_edit" %></strong>
|
||||
<%= t ".public editing note.find_out_why_html", :link => link_to(t(".public editing note.find_out_why"),
|
||||
t(".public editing note.find_out_why_url")) %>
|
||||
</p>
|
||||
<ul>
|
||||
<li><%= t ".public editing note.email_not_revealed" %></li>
|
||||
<li><%= t ".public editing note.not_reversible" %></li>
|
||||
</ul>
|
||||
<%= button_to t(".make edits public button"), user_go_public_path, :class => "btn btn-primary" %>
|
||||
<%= render :partial => "go_public" %>
|
||||
<% end %>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue