diff options
Diffstat (limited to 'app/views/projects/compare')
-rw-r--r-- | app/views/projects/compare/index.html.haml | 14 | ||||
-rw-r--r-- | app/views/projects/compare/show.html.haml | 10 |
2 files changed, 7 insertions, 17 deletions
diff --git a/app/views/projects/compare/index.html.haml b/app/views/projects/compare/index.html.haml index 58da76a3231..4a29402bfe7 100644 --- a/app/views/projects/compare/index.html.haml +++ b/app/views/projects/compare/index.html.haml @@ -1,16 +1,6 @@ -- breadcrumb_title _("Compare revisions") -- page_title _("Compare revisions") +- breadcrumb_title s_("CompareRevisions|Compare revisions") -%h1.page-title.gl-font-size-h-display - = _("Compare Git revisions") -%div - - example_branch = capture do - %code.ref-name= @project.default_branch_or_main - - example_sha = capture do - %code.ref-name 4eedf23 - = html_escape(_("To see what's changed or create a merge request, choose a branch or tag (like %{branch}), or enter a commit (like %{sha}).")) % { branch: example_branch.html_safe, sha: example_sha.html_safe } - %br - = html_escape(_("Changes are shown as if the %{b_open}source%{b_close} revision was being merged into the %{b_open}target%{b_close} revision.")) % { b_open: '<b>'.html_safe, b_close: '</b>'.html_safe } +- page_title _("CompareRevisions|Compare revisions") .prepend-top-20 #js-compare-selector{ data: project_compare_selector_data(@project, @merge_request, @compare_params) } diff --git a/app/views/projects/compare/show.html.haml b/app/views/projects/compare/show.html.haml index 9185afc0771..5b6f7c392dd 100644 --- a/app/views/projects/compare/show.html.haml +++ b/app/views/projects/compare/show.html.haml @@ -1,7 +1,7 @@ -- add_to_breadcrumbs _("Compare revisions"), project_compare_index_path(@project) -- page_title "#{params[:from]}...#{params[:to]}" +- add_to_breadcrumbs s_("CompareRevisions|Compare revisions"), project_compare_index_path(@project) +- page_title "#{params[:from]} to #{params[:to]}" -.sub-header-block.gl-border-b-0.gl-mb-0 +.sub-header-block.gl-border-b-0.gl-mb-0.gl-pt-4 .js-signature-container{ data: { 'signatures-path' => signatures_namespace_project_compare_index_path } } #js-compare-selector{ data: project_compare_selector_data(@project, @merge_request, params) } @@ -20,13 +20,13 @@ = render Pajamas::CardComponent.new(card_options: { class: "gl-bg-gray-50 gl-mb-5 gl-border-none gl-text-center" }) do |c| - c.with_body do %h4 - = s_("CompareBranches|There isn't anything to compare.") + = s_("CompareRevisions|There isn't anything to compare.") %p.gl-mb-4.gl-line-height-24 - if params[:to] == params[:from] - 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 + = (s_("CompareRevisions|%{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.") |