diff options
author | Filipa Lacerda <filipa@gitlab.com> | 2018-01-04 22:39:01 +0000 |
---|---|---|
committer | Filipa Lacerda <filipa@gitlab.com> | 2018-01-04 22:39:01 +0000 |
commit | a29a91f02d5de7a42a423f1c9ea2a18e325ef9ee (patch) | |
tree | 63956a640c01370f929fa25dad43f83e4714dec5 /app/views/projects/compare | |
parent | 3b8cee95a7d62bce3b3890ff8618073958dc2fb0 (diff) | |
parent | 6f1b4dc76b4619f538b7216ad3a10ca9336d0c2b (diff) | |
download | gitlab-ce-a29a91f02d5de7a42a423f1c9ea2a18e325ef9ee.tar.gz |
Merge branch 'master' into 22643-manual-job-page
* master: (200 commits)
Fix issue boards scroll config.
Added multi editor setting on the profile preferences page
fix missing import of timeWeek which would cause errors in prometheus graphs with deployments
Remove downcase from special path helper
Rename db:seed_fu-{pg,mysql} to gitlab:setup-{pg,mysql}
Fix error when viewing diffs without blobs
Moves prettier to dev dependency
Eager load event target authors whenever possible
Do not run ee_compat_check on security branches
Include integration tests in CE/EE testing documentation
41054-Disallow creation of new Kubernetes integrations
Resolve "Resizable file list and commit panel"
Make tooltip placement bottom by default as per design guidelines
Fix groups list icon, timestamp alignment and row height
Avoid leaving a push event empty if payload cannot be created
Move git operations for UpdateRemoteMirrorService into Gitlab::Git
Move delete_remote_branches from Gitlab::Shell to Gitlab::Git::Repository
Move push_remote_branches from Gitlab::Shell to Gitlab::Git::Repository
Update Kubernetes service documentation
fix issue #37843
...
Diffstat (limited to 'app/views/projects/compare')
-rw-r--r-- | app/views/projects/compare/_form.html.haml | 16 | ||||
-rw-r--r-- | app/views/projects/compare/index.html.haml | 18 | ||||
-rw-r--r-- | app/views/projects/compare/show.html.haml | 15 |
3 files changed, 23 insertions, 26 deletions
diff --git a/app/views/projects/compare/_form.html.haml b/app/views/projects/compare/_form.html.haml index a518fced2b4..d0c8a699608 100644 --- a/app/views/projects/compare/_form.html.haml +++ b/app/views/projects/compare/_form.html.haml @@ -5,22 +5,24 @@ = link_to icon('exchange'), { from: params[:to], to: params[:from] }, class: 'commits-compare-switch has-tooltip btn btn-white', title: 'Swap revisions' .form-group.dropdown.compare-form-group.to.js-compare-to-dropdown .input-group.inline-input-group - %span.input-group-addon Source + %span.input-group-addon + = s_("CompareBranches|Source") = hidden_field_tag :to, params[:to] = button_tag type: 'button', title: params[:to], class: "form-control compare-dropdown-toggle js-compare-dropdown has-tooltip git-revision-dropdown-toggle", required: true, data: { refs_url: refs_project_path(@project), toggle: "dropdown", target: ".js-compare-to-dropdown", selected: params[:to], field_name: :to } do - .dropdown-toggle-text.str-truncated= params[:to] || 'Select branch/tag' + .dropdown-toggle-text.str-truncated= params[:to] || _("Select branch/tag") = render 'shared/ref_dropdown' .compare-ellipsis.inline ... .form-group.dropdown.compare-form-group.from.js-compare-from-dropdown .input-group.inline-input-group - %span.input-group-addon Target + %span.input-group-addon + = s_("CompareBranches|Target") = hidden_field_tag :from, params[:from] = button_tag type: 'button', title: params[:from], class: "form-control compare-dropdown-toggle js-compare-dropdown has-tooltip git-revision-dropdown-toggle", required: true, data: { refs_url: refs_project_path(@project), toggle: "dropdown", target: ".js-compare-from-dropdown", selected: params[:from], field_name: :from } do - .dropdown-toggle-text.str-truncated= params[:from] || 'Select branch/tag' + .dropdown-toggle-text.str-truncated= params[:from] || _("Select branch/tag") = render 'shared/ref_dropdown' - = button_tag "Compare", class: "btn btn-create commits-compare-btn" + = button_tag s_("CompareBranches|Compare"), class: "btn btn-create commits-compare-btn" - if @merge_request.present? - = link_to "View open merge request", project_merge_request_path(@project, @merge_request), class: 'prepend-left-10 btn' + = link_to _("View open merge request"), project_merge_request_path(@project, @merge_request), class: 'prepend-left-10 btn' - elsif create_mr_button? - = link_to "Create merge request", create_mr_path, class: 'prepend-left-10 btn' + = link_to _("Create merge request"), create_mr_path, class: 'prepend-left-10 btn' diff --git a/app/views/projects/compare/index.html.haml b/app/views/projects/compare/index.html.haml index 3ad0166e9cd..14c64b3534a 100644 --- a/app/views/projects/compare/index.html.haml +++ b/app/views/projects/compare/index.html.haml @@ -3,22 +3,16 @@ - page_title "Compare" %div{ class: container_class } + %h3.page-title + = _("Compare Git revisions") .sub-header-block - Compare Git revisions. - %br - Choose a branch/tag (e.g. - = succeed ')' do + - example_master = capture do %code.ref-name master - or enter a commit SHA (e.g. - = succeed ')' do + - example_sha = capture do %code.ref-name 4eedf23 - to see what's changed or to create a merge request. + = (_("Choose a branch/tag (e.g. %{master}) or enter a commit (e.g. %{sha}) to see what's changed or to create a merge request.") % { master: example_master, sha: example_sha }).html_safe %br - Changes are shown as if the - %b source - revision was being merged into the - %b target - revision. + = (_("Changes are shown as if the <b>source</b> revision was being merged into the <b>target</b> revision.")).html_safe .prepend-top-20 = render "form" diff --git a/app/views/projects/compare/show.html.haml b/app/views/projects/compare/show.html.haml index f87f1d476f5..8da55664878 100644 --- a/app/views/projects/compare/show.html.haml +++ b/app/views/projects/compare/show.html.haml @@ -1,5 +1,5 @@ - @no_container = true -- add_to_breadcrumbs "Compare Revisions", project_compare_index_path(@project) +- add_to_breadcrumbs _("Compare Revisions"), project_compare_index_path(@project) - page_title "#{params[:from]}...#{params[:to]}" %div{ class: container_class } @@ -13,12 +13,13 @@ .light-well .center %h4 - There isn't anything to compare. + = s_("CompareBranches|There isn't anything to compare.") %p.slead - if params[:to] == params[:from] - %span.ref-name= params[:from] - and - %span.ref-name= params[:to] - are the same. + - source_branch = capture do + %span.ref-name= params[:from] + - target_branch = capture do + %span.ref-name= params[:to] + = (s_("CompareBranches|%{source_branch} and %{target_branch} are the same.") % { source_branch: source_branch, target_branch: target_branch }).html_safe - else - You'll need to use different branch names to get a valid comparison. + = _("You'll need to use different branch names to get a valid comparison.") |