debian-mirror-gitlab/app/views/projects/diffs/_warning.html.haml

15 lines
1.2 KiB
Text
Raw Normal View History

2021-09-30 23:02:18 +05:30
= render 'shared/global_alert',
title: _('Too many changes to show.'),
variant: :warning,
is_contained: true,
alert_class: 'gl-mb-5' do
2021-01-03 14:25:43 +05:30
.gl-alert-body
2020-10-24 23:57:45 +05:30
= html_escape(_("To preserve performance only %{strong_open}%{display_size} of %{real_size}%{strong_close} files are displayed.")) % { display_size: diff_files.size, real_size: diff_files.real_size, strong_open: '<strong>'.html_safe, strong_close: '</strong>'.html_safe }
2021-01-03 14:25:43 +05:30
.gl-alert-actions
- if current_controller?(:commit)
= link_to _("Plain diff"), project_commit_path(@project, @commit, format: :diff), class: "btn gl-alert-action btn-default gl-button btn-default-secondary"
= link_to _("Email patch"), project_commit_path(@project, @commit, format: :patch), class: "btn gl-alert-action btn-default gl-button btn-default-secondary"
- elsif current_controller?('projects/merge_requests/diffs') && @merge_request&.persisted?
= link_to _("Plain diff"), merge_request_path(@merge_request, format: :diff), class: "btn gl-alert-action btn-default gl-button btn-default-secondary"
= link_to _("Email patch"), merge_request_path(@merge_request, format: :patch), class: "btn gl-alert-action btn-default gl-button btn-default-secondary"