Commit 3dc347a3 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Cleanup diff stats UI

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 45623089
...@@ -112,7 +112,9 @@ ...@@ -112,7 +112,9 @@
.commit-stat-summary { .commit-stat-summary {
color: #666; color: #666;
line-height: 2; font-size: 14px;
font-weight: normal;
padding: 10px 0;
} }
.commit-info-row { .commit-info-row {
......
...@@ -23,7 +23,11 @@ ...@@ -23,7 +23,11 @@
If you still want to see the diff If you still want to see the diff
= link_to "click this link", url_for(force_show_diff: true), class: "underlined-link" = link_to "click this link", url_for(force_show_diff: true), class: "underlined-link"
%p.commit-stat-summary
.row
.col-md-8
.js-toggle-container
.commit-stat-summary
Showing Showing
%strong.cdark #{pluralize(diffs.count, "changed file")} %strong.cdark #{pluralize(diffs.count, "changed file")}
- if current_controller?(:commit) - if current_controller?(:commit)
...@@ -32,12 +36,18 @@ ...@@ -32,12 +36,18 @@
%strong.cgreen #{@commit.stats.additions} additions %strong.cgreen #{@commit.stats.additions} additions
and and
%strong.cred #{@commit.stats.deletions} deletions %strong.cred #{@commit.stats.deletions} deletions
- if params[:view] == 'parallel' &nbsp;
= link_to "Inline Diff", url_for(view: 'inline'), {id: "commit-diff-viewtype", class: 'btn btn-tiny pull-right'} = link_to '#', class: 'btn btn-small js-toggle-button' do
- else Show diff stats
= link_to "Side-by-side Diff", url_for(view: 'parallel'), {id: "commit-diff-viewtype", class: 'btn btn-tiny pull-right'} %i.icon-chevron-down
.file-stats .file-stats.js-toggle-content.hide
= render "projects/commits/diff_head", diffs: diffs = render "projects/commits/diff_head", diffs: diffs
.col-md-4
%ul.nav.nav-tabs
%li.pull-right{class: params[:view] == 'parallel' ? 'active' : ''}
= link_to "Side-by-side Diff", url_for(view: 'parallel'), {id: "commit-diff-viewtype"}
%li.pull-right{class: params[:view] != 'parallel' ? 'active' : ''}
= link_to "Inline Diff", url_for(view: 'inline'), {id: "commit-diff-viewtype"}
.files .files
- unless @suppress_diff - unless @suppress_diff
......
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