Commit fa5900fb authored by Phil Hughes's avatar Phil Hughes

Merge branch 'gt-externalize-app-views-projects-diffs' into 'master'

Externalize strings from `/app/views/projects/diffs`

See merge request gitlab-org/gitlab-ce!23230
parents 3cf5ae31 58b3b773
- diff_file = viewer.diff_file
- url = url_for(safe_params.merge(action: :diff_for_path, old_path: diff_file.old_path, new_path: diff_file.new_path, file_identifier: diff_file.file_identifier))
.nothing-here-block.diff-collapsed{ data: { diff_for_path: url } }
This diff is collapsed.
%button.click-to-expand.btn.btn-link Click to expand it.
= _("This diff is collapsed.")
%button.click-to-expand.btn.btn-link= _("Click to expand it.")
......@@ -8,7 +8,7 @@
.files-changed-inner
.inline-parallel-buttons.d-none.d-sm-none.d-md-block
- if !diffs_expanded? && diff_files.any? { |diff_file| diff_file.collapsed? }
= link_to 'Expand all', url_for(safe_params.merge(expanded: 1, format: nil)), class: 'btn btn-default'
= link_to _('Expand all'), url_for(safe_params.merge(expanded: 1, format: nil)), class: 'btn btn-default'
- if show_whitespace_toggle
- if current_controller?(:commit)
= commit_diff_whitespace_link(diffs.project, @commit, class: 'd-none d-sm-inline-block')
......
......@@ -12,7 +12,7 @@
- blob = diff_file.blob
.file-actions.d-none.d-sm-block
- if blob&.readable_text?
= link_to '#', class: 'js-toggle-diff-comments btn active has-tooltip', title: "Toggle comments for this file", disabled: @diff_notes_disabled do
= link_to '#', class: 'js-toggle-diff-comments btn active has-tooltip', title: _("Toggle comments for this file"), disabled: @diff_notes_disabled do
= icon('comment')
\
- if editable_diff?(diff_file)
......
......@@ -28,7 +28,7 @@
= diff_file.file_path
- if diff_file.deleted_file?
deleted
= _("deleted")
= copy_file_path_button(diff_file.file_path)
......
.nothing-here-block
This #{viewer.switcher_title} could not be displayed because #{diff_render_error_reason(viewer)}.
= _("This %{viewer} could not be displayed because %{reason}.") % { viewer: viewer.switcher_title, reason: diff_render_error_reason(viewer) }
You can
= diff_render_error_options(viewer).to_sentence(two_words_connector: ' or ', last_word_connector: ', or ').html_safe
......
......@@ -38,4 +38,4 @@
\-#{diff_file.removed_lines}
%li.dropdown-menu-empty-item.hidden
%a
No files found.
= _("No files found.")
- too_big = diff_file.diff_lines.count > Commit::DIFF_SAFE_LINES
- if too_big
.suppressed-container
%a.show-suppressed-diff.js-show-suppressed-diff Changes suppressed. Click to show.
%a.show-suppressed-diff.js-show-suppressed-diff= _("Changes suppressed. Click to show.")
%table.text-file.diff-wrap-lines.code.js-syntax-highlight.commit-diff{ data: diff_view_data, class: too_big ? 'hide' : '' }
= render partial: "projects/diffs/line",
......
.alert.alert-warning
%h4
Too many changes to show.
= _("Too many changes to show.")
.float-right
- if current_controller?(:commit)
= link_to "Plain diff", project_commit_path(@project, @commit, format: :diff), class: "btn btn-sm"
= link_to "Email patch", project_commit_path(@project, @commit, format: :patch), class: "btn btn-sm"
= link_to _("Plain diff"), project_commit_path(@project, @commit, format: :diff), class: "btn btn-sm"
= link_to _("Email patch"), project_commit_path(@project, @commit, format: :patch), class: "btn btn-sm"
- elsif current_controller?('projects/merge_requests/diffs') && @merge_request&.persisted?
= link_to "Plain diff", merge_request_path(@merge_request, format: :diff), class: "btn btn-sm"
= link_to "Email patch", merge_request_path(@merge_request, format: :patch), class: "btn btn-sm"
= link_to _("Plain diff"), merge_request_path(@merge_request, format: :diff), class: "btn btn-sm"
= link_to _("Email patch"), merge_request_path(@merge_request, format: :patch), class: "btn btn-sm"
%p
To preserve performance only
%strong #{diff_files.size} of #{diff_files.real_size}
files are displayed.
= _("To preserve performance only <strong>%{display_size} of ${real_size}</strong> files are displayed.").html_safe % { display_size: diff_files.size, real_size: diff_files.real_size }
.nothing-here-block
File added
= _("File added")
.nothing-here-block
File deleted
= _("File deleted")
- diff_file = viewer.diff_file
.nothing-here-block
File mode changed from #{diff_file.a_mode} to #{diff_file.b_mode}
= _("File mode changed from %{a_mode} to %{b_mode}") % { a_mode: diff_file.a_mode, b_mode: diff_file.b_mode }
.nothing-here-block
No preview for this file type
= _("No preview for this file type")
.nothing-here-block
This diff was suppressed by a .gitattributes entry.
= _("This diff was suppressed by a .gitattributes entry.")
......@@ -1172,6 +1172,9 @@ msgstr ""
msgid "Changes are shown as if the <b>source</b> revision was being merged into the <b>target</b> revision."
msgstr ""
msgid "Changes suppressed. Click to show."
msgstr ""
msgid "Charts"
msgstr ""
......@@ -2861,6 +2864,18 @@ msgstr ""
msgid "Fields on this page are now uneditable, you can configure"
msgstr ""
msgid "File added"
msgstr ""
msgid "File deleted"
msgstr ""
msgid "File mode changed from %{a_mode} to %{b_mode}"
msgstr ""
msgid "File moved"
msgstr ""
msgid "File templates"
msgstr ""
......@@ -4177,6 +4192,9 @@ msgstr ""
msgid "No other labels with such name or description"
msgstr ""
msgid "No preview for this file type"
msgstr ""
msgid "No prioritised labels with such name or description"
msgstr ""
......@@ -6275,6 +6293,9 @@ msgstr ""
msgid "Third party offers"
msgstr ""
msgid "This %{viewer} could not be displayed because %{reason}."
msgstr ""
msgid "This GitLab instance does not provide any shared Runners yet. Instance administrators can register shared Runners in the admin area."
msgstr ""
......@@ -6293,6 +6314,9 @@ msgstr ""
msgid "This diff is collapsed."
msgstr ""
msgid "This diff was suppressed by a .gitattributes entry."
msgstr ""
msgid "This directory"
msgstr ""
......@@ -6648,6 +6672,9 @@ msgstr ""
msgid "To move or copy an entire GitLab project from another GitLab installation to this one, navigate to the original project's settings page, generate an export file, and upload it here."
msgstr ""
msgid "To preserve performance only <strong>%{display_size} of ${real_size}</strong> files are displayed."
msgstr ""
msgid "To start serving your jobs you can add Runners to your group"
msgstr ""
......@@ -6669,6 +6696,9 @@ msgstr ""
msgid "Toggle Sidebar"
msgstr ""
msgid "Toggle comments for this file"
msgstr ""
msgid "Toggle commit description"
msgstr ""
......@@ -7385,6 +7415,9 @@ msgid_plural "days"
msgstr[0] ""
msgstr[1] ""
msgid "deleted"
msgstr ""
msgid "deploy token"
msgstr ""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment