diff options
author | Annabel Dunstone <annabel.dunstone@gmail.com> | 2016-03-31 13:37:27 -0500 |
---|---|---|
committer | Annabel Dunstone <annabel.dunstone@gmail.com> | 2016-04-07 15:33:18 -0700 |
commit | de63de18d77624d49b6a9d150f2581be0ac55e00 (patch) | |
tree | 270213cfd032289a857d786e97a66223cee7cd0a | |
parent | c80c1da7802c372607f5a025ef2f3e25202734c3 (diff) | |
download | gitlab-ce-de63de18d77624d49b6a9d150f2581be0ac55e00.tar.gz |
Update diff colors and icons
-rw-r--r-- | app/assets/stylesheets/framework/variables.scss | 14 | ||||
-rw-r--r-- | app/assets/stylesheets/highlight/white.scss | 4 | ||||
-rw-r--r-- | app/assets/stylesheets/pages/notes.scss | 15 | ||||
-rw-r--r-- | app/helpers/notes_helper.rb | 3 | ||||
-rw-r--r-- | app/views/projects/diffs/_file.html.haml | 2 | ||||
-rw-r--r-- | app/views/projects/notes/_note.html.haml | 4 | ||||
-rw-r--r-- | spec/features/notes_on_merge_requests_spec.rb | 2 |
7 files changed, 29 insertions, 15 deletions
diff --git a/app/assets/stylesheets/framework/variables.scss b/app/assets/stylesheets/framework/variables.scss index 9f231429653..49f62c8850a 100644 --- a/app/assets/stylesheets/framework/variables.scss +++ b/app/assets/stylesheets/framework/variables.scss @@ -160,14 +160,12 @@ $gl-btn-active-gradient: inset 0 0 4px $gl-btn-active-background; */ $added: #63c363; $deleted: #f77; -$line-added: #ebfdf0; -$line-added-dark: #a6f3a6; -$line-removed: #ffecec; -$line-removed-dark: #f8cbcb; -$line-number-old: #fdd; -$line-number-old-border: #f1c0c0; -$line-number-new: #dbffdb; -$line-number-new-border: #c1e9c1; +$line-added: #ecfdf0; +$line-added-dark: #c7f0d2; +$line-removed: #fbe9eb; +$line-removed-dark: #fac5cd; +$line-number-old: #f9d7dc; +$line-number-new: #ddfbe6; $match-line: #fafafa; /* * Fonts diff --git a/app/assets/stylesheets/highlight/white.scss b/app/assets/stylesheets/highlight/white.scss index 80918970a75..ea9bc98079a 100644 --- a/app/assets/stylesheets/highlight/white.scss +++ b/app/assets/stylesheets/highlight/white.scss @@ -24,12 +24,12 @@ .diff-line-num { &.old { background-color: $line-number-old; - border-color: $line-number-old-border; + border-color: $line-removed-dark; } &.new { background-color: $line-number-new; - border-color: $line-number-new-border; + border-color: $line-added-dark; } } diff --git a/app/assets/stylesheets/pages/notes.scss b/app/assets/stylesheets/pages/notes.scss index aca86457c70..d9dc7820184 100644 --- a/app/assets/stylesheets/pages/notes.scss +++ b/app/assets/stylesheets/pages/notes.scss @@ -212,6 +212,21 @@ ul.notes { top: 0; font-size: 16px; } + + .js-note-delete { + &:hover { + @extend .cgray; + &.danger { @extend .cred; } + } + } + + .js-note-edit { + i { + &:hover { + color: $gl-link-color; + } + } + } } .discussion-toggle-button { diff --git a/app/helpers/notes_helper.rb b/app/helpers/notes_helper.rb index 3363001fcdb..681df89836d 100644 --- a/app/helpers/notes_helper.rb +++ b/app/helpers/notes_helper.rb @@ -69,7 +69,8 @@ module NotesHelper line_type: line_type } - text_field_tag 'reply-field', nil, placeholder: 'Reply...', + text_field_tag 'reply-field', nil, + placeholder: 'Reply...', class: 'form-control note-reply-field js-discussion-reply-button', data: data end diff --git a/app/views/projects/diffs/_file.html.haml b/app/views/projects/diffs/_file.html.haml index 698ed02ea0e..4d5461afeb7 100644 --- a/app/views/projects/diffs/_file.html.haml +++ b/app/views/projects/diffs/_file.html.haml @@ -29,7 +29,7 @@ .file-actions.hidden-xs - if blob_text_viewable?(blob) = link_to '#', class: 'js-toggle-diff-comments btn active has-tooltip', title: "Toggle comments for this file" do - = icon('comments') + = icon('comment') \ - if editable_diff?(diff_file) diff --git a/app/views/projects/notes/_note.html.haml b/app/views/projects/notes/_note.html.haml index a681d6dece4..5c42423541e 100644 --- a/app/views/projects/notes/_note.html.haml +++ b/app/views/projects/notes/_note.html.haml @@ -17,8 +17,8 @@ %span.note-role = access = link_to '#', title: 'Edit comment', class: 'note-action-button js-note-edit' do - = icon('pencil-square-o') - = link_to namespace_project_note_path(note.project.namespace, note.project, note), title: 'Remove comment', method: :delete, data: { confirm: 'Are you sure you want to remove this comment?' }, remote: true, class: 'note-action-button js-note-delete' do + = icon('pencil') + = link_to namespace_project_note_path(note.project.namespace, note.project, note), title: 'Remove comment', method: :delete, data: { confirm: 'Are you sure you want to remove this comment?' }, remote: true, class: 'note-action-button js-note-delete danger' do = icon('trash-o') .note-body{class: note_editable?(note) ? 'js-task-list-container' : ''} .note-text diff --git a/spec/features/notes_on_merge_requests_spec.rb b/spec/features/notes_on_merge_requests_spec.rb index 70d0864783d..9b2351c15dc 100644 --- a/spec/features/notes_on_merge_requests_spec.rb +++ b/spec/features/notes_on_merge_requests_spec.rb @@ -210,7 +210,7 @@ describe 'Comments', feature: true do is_expected.to have_content('Another comment on line 10') is_expected.to have_css('.notes_holder') is_expected.to have_css('.notes_holder .note', count: 1) - is_expected.to have_button('Reply') + is_expected.to have_css('.note-reply-field') end end end |