Internationalize Views::Compare templates
This commit is contained in:
@@ -0,0 +1,8 @@
|
|||||||
|
en:
|
||||||
|
precious/views/compare:
|
||||||
|
back_to_page_history: Back to Page History
|
||||||
|
back_to_top: Back to Top
|
||||||
|
comparison_of: Comparison of
|
||||||
|
comparing_versions_of: Comparing versions of
|
||||||
|
comparing_from: "Comparing %{before} to %{after}"
|
||||||
|
revert: Revert Changes
|
||||||
@@ -4,55 +4,84 @@
|
|||||||
|
|
||||||
<h1 class="header-title text-center text-md-left py-4">
|
<h1 class="header-title text-center text-md-left py-4">
|
||||||
<span class="f1-light text-gray-light">
|
<span class="f1-light text-gray-light">
|
||||||
Comparing versions of
|
{{t.comparing_versions_of}}
|
||||||
</span>
|
</span>
|
||||||
{{name}}
|
{{name}}
|
||||||
</h1>
|
</h1>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{#message}}
|
{{#message}}
|
||||||
<p>{{message}}</p>
|
<p>{{message}}</p>
|
||||||
{{/message}}
|
{{/message}}
|
||||||
|
|
||||||
<div id="compare-content">
|
<div id="compare-content">
|
||||||
|
|
||||||
<div class="py-4" id="actions">
|
<div class="py-4" id="actions">
|
||||||
{{#show_revert}}
|
{{#show_revert}}
|
||||||
{{#allow_editing}}
|
{{#allow_editing}}
|
||||||
<form name="gollum-revert" action="{{revert_path}}/{{escaped_url_path}}/{{before}}/{{after}}" method="post" id="gollum-revert-form"></form>
|
<form name="gollum-revert" action="{{revert_path}}/{{escaped_url_path}}/{{before}}/{{after}}" method="post" id="gollum-revert-form"></form>
|
||||||
<span class="pb-4">
|
<span class="pb-4">
|
||||||
<button class="btn btn-sm" type="submit" onclick="$('#gollum-revert-form').submit()">Revert Changes</button>
|
<button
|
||||||
</span>
|
class="btn btn-sm"
|
||||||
{{/allow_editing}}
|
onclick="$('#gollum-revert-form').submit()"
|
||||||
{{/show_revert}}
|
type="submit"
|
||||||
<a href="{{history_path}}/{{escaped_url_path}}" class="btn btn-sm action-page-history">Back to Page History</a>
|
>
|
||||||
</div>
|
{{t.revert}}
|
||||||
|
</button>
|
||||||
|
</span>
|
||||||
|
{{/allow_editing}}
|
||||||
|
{{/show_revert}}
|
||||||
|
|
||||||
<div class="Box data highlight">
|
<a
|
||||||
<div class="Box-header Box--condensed Box-header--gray">{{path}} <span class="px-2 float-right">Comparing {{before}} to {{after}}</span></div>
|
class="btn btn-sm action-page-history"
|
||||||
<table >
|
href="{{history_path}}/{{escaped_url_path}}"
|
||||||
{{#lines}}
|
>
|
||||||
<tr>
|
{{t.back_to_page_history}}
|
||||||
<td class="line_numbers">{{ldln}}</td>
|
</a>
|
||||||
<td class="line_numbers">{{rdln}}</td>
|
</div>
|
||||||
<td>
|
|
||||||
<div class="{{class}} pl-2">{{line}}</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
{{/lines}}
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="pt-4" id="footer">
|
<div class="Box data highlight">
|
||||||
{{#show_revert}}
|
<div class="Box-header Box--condensed Box-header--gray">
|
||||||
{{#allow_editing}}
|
{{path}}
|
||||||
<span class="pt-4"><button class="btn btn-sm gollum-revert-button" type="submit" onclick="$('#gollum-revert-form').submit()">Revert Changes</button></span>
|
|
||||||
{{/allow_editing}}
|
<span class="px-2 float-right">
|
||||||
{{/show_revert}}
|
{{t.comparing_from}}
|
||||||
<div class="pt-4">
|
</span>
|
||||||
<a href="#">Back to Top</a>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
<table>
|
||||||
|
{{#lines}}
|
||||||
|
<tr>
|
||||||
|
<td class="line_numbers">{{ldln}}</td>
|
||||||
|
<td class="line_numbers">{{rdln}}</td>
|
||||||
|
<td>
|
||||||
|
<div class="{{class}} pl-2">{{line}}</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
{{/lines}}
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="pt-4" id="footer">
|
||||||
|
{{#show_revert}}
|
||||||
|
{{#allow_editing}}
|
||||||
|
<span class="pt-4">
|
||||||
|
<button
|
||||||
|
class="btn btn-sm gollum-revert-button"
|
||||||
|
onclick="$('#gollum-revert-form').submit()"
|
||||||
|
type="submit"
|
||||||
|
>
|
||||||
|
{{t.revert}}
|
||||||
|
</button>
|
||||||
|
</span>
|
||||||
|
{{/allow_editing}}
|
||||||
|
{{/show_revert}}
|
||||||
|
|
||||||
|
<div class="pt-4">
|
||||||
|
<a href="#">
|
||||||
|
{{t.back_to_top}}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ module Precious
|
|||||||
attr_reader :page, :diff, :versions, :message, :allow_editing
|
attr_reader :page, :diff, :versions, :message, :allow_editing
|
||||||
|
|
||||||
def title
|
def title
|
||||||
"Comparison of #{@page.title}"
|
[t[:comparison_of], @page.title].join(" ")
|
||||||
end
|
end
|
||||||
|
|
||||||
def before
|
def before
|
||||||
|
|||||||
Reference in New Issue
Block a user