diff options
| author | erdgeist <erdgeist@erdgeist.org> | 2026-07-14 02:17:04 +0200 |
|---|---|---|
| committer | erdgeist <erdgeist@erdgeist.org> | 2026-07-14 02:17:04 +0200 |
| commit | 88ebeaac7fcf140cbab489e841bf9c197f84c4ea (patch) | |
| tree | ff97b50deebdaa44eb6a40d8550e912457c2fb8f /app/views/page_translations | |
| parent | c693069db6ddce4582209a1cf60a564f6947bd56 (diff) | |
Make revisions locale aware
Diffstat (limited to 'app/views/page_translations')
| -rw-r--r-- | app/views/page_translations/edit.html.erb | 2 | ||||
| -rw-r--r-- | app/views/page_translations/index.html.erb | 19 | ||||
| -rw-r--r-- | app/views/page_translations/show.html.erb | 2 |
3 files changed, 4 insertions, 19 deletions
diff --git a/app/views/page_translations/edit.html.erb b/app/views/page_translations/edit.html.erb index 89b594e8..981fb743 100644 --- a/app/views/page_translations/edit.html.erb +++ b/app/views/page_translations/edit.html.erb | |||
| @@ -2,6 +2,8 @@ | |||
| 2 | Editing the <strong><%= @locale.to_s.upcase %></strong> translation of <strong><%= title_for_node(@node) %></strong>. | 2 | Editing the <strong><%= @locale.to_s.upcase %></strong> translation of <strong><%= title_for_node(@node) %></strong>. |
| 3 | </div> | 3 | </div> |
| 4 | 4 | ||
| 5 | <p class="node_action_bar standalone_action_bar"><%= link_to 'View revision history', node_revisions_path(@node, :locale => @locale) %></p> | ||
| 6 | |||
| 5 | <p class="field_hint"> | 7 | <p class="field_hint"> |
| 6 | Metadata such as images, tags, template, and author belong to the page | 8 | Metadata such as images, tags, template, and author belong to the page |
| 7 | as a whole, not to a single translation — change those from the | 9 | as a whole, not to a single translation — change those from the |
diff --git a/app/views/page_translations/index.html.erb b/app/views/page_translations/index.html.erb deleted file mode 100644 index a8c4f5dc..00000000 --- a/app/views/page_translations/index.html.erb +++ /dev/null | |||
| @@ -1,19 +0,0 @@ | |||
| 1 | <h1>Translations — <%= title_for_node(@node) %></h1> | ||
| 2 | |||
| 3 | <div class="node_content node_info_group"> | ||
| 4 | <div class="node_info_group_items"> | ||
| 5 | <% @translations.each do |t| %> | ||
| 6 | <div class="node_info_item"> | ||
| 7 | <span class="node_info_label"><%= t[:locale].to_s.upcase %></span> | ||
| 8 | <% if t[:exists] %> | ||
| 9 | <%= t[:title] %> — updated <%= t[:updated_at] %> | ||
| 10 | <% if t[:outdated] %><span class="warning">may be outdated</span><% end %> | ||
| 11 | <%= link_to 'Edit', edit_node_translation_path(@node, t[:locale]) %> | ||
| 12 | <% else %> | ||
| 13 | <span class="field_hint">Not yet translated.</span> | ||
| 14 | <%= link_to 'Add', edit_node_translation_path(@node, t[:locale]) %> | ||
| 15 | <% end %> | ||
| 16 | </div> | ||
| 17 | <% end %> | ||
| 18 | </div> | ||
| 19 | </div> | ||
diff --git a/app/views/page_translations/show.html.erb b/app/views/page_translations/show.html.erb index c5bd151f..60eb7cf7 100644 --- a/app/views/page_translations/show.html.erb +++ b/app/views/page_translations/show.html.erb | |||
| @@ -1,5 +1,7 @@ | |||
| 1 | <h1>Compare — <%= title_for_node(@node) %></h1> | 1 | <h1>Compare — <%= title_for_node(@node) %></h1> |
| 2 | 2 | ||
| 3 | <p class="node_action_bar standalone_action_bar"><%= link_to 'View revision history', node_revisions_path(@node, :locale => @locale) %></p> | ||
| 4 | |||
| 3 | <div class="translation_compare"> | 5 | <div class="translation_compare"> |
| 4 | <div class="translation_compare_column"> | 6 | <div class="translation_compare_column"> |
| 5 | <h2><%= @locale.to_s.upcase %></h2> | 7 | <h2><%= @locale.to_s.upcase %></h2> |
