Commit 2cd9542e authored by Clement Ho's avatar Clement Ho

Fix diff stats sticky bar

parent ed385e4b
......@@ -604,19 +604,23 @@
top: 76px;
}
&:not(.is-stuck) .diff-stats-additions-deletions-collapsed {
display: none;
}
&.is-stuck {
padding-top: 0;
padding-bottom: 0;
border-bottom: 1px solid $white-dark;
transform: translateY(16px);
transform: translateY(52px);
.diff-stats-additions-deletions-expanded,
.inline-parallel-buttons {
display: none;
display: none !important;
}
}
}
@include media-breakpoint-up(lg) {
&.is-stuck {
.diff-stats-additions-deletions-collapsed {
display: block !important;
}
}
}
......
......@@ -11,7 +11,7 @@
= link_to 'Expand all', url_for(params.merge(expanded: 1, format: nil)), class: 'btn btn-secondary'
- if show_whitespace_toggle
- if current_controller?(:commit)
= commit_diff_whitespace_link(diffs.project, @commit, class: 'd-none d-sm-block')
= commit_diff_whitespace_link(diffs.project, @commit, class: 'd-none d-sm-inline-block')
- elsif current_controller?('projects/merge_requests/diffs')
= diff_merge_request_whitespace_link(diffs.project, @merge_request, class: 'd-none d-sm-block')
- elsif current_controller?(:compare)
......
......@@ -10,7 +10,7 @@
%strong.cgreen= pluralize(sum_added_lines, 'addition')
and
%strong.cred= pluralize(sum_removed_lines, 'deletion')
.diff-stats-additions-deletions-collapsed.float-right.d-none.d-sm-none.d-md-block{ "aria-hidden": "true", "aria-describedby": "diff-stats" }
.diff-stats-additions-deletions-collapsed.float-right.d-none.d-sm-none{ "aria-hidden": "true", "aria-describedby": "diff-stats" }
%strong.cgreen<
+#{sum_added_lines}
%strong.cred<
......
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