Commit e0f8e022 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Improve comment toggle button in diff

parent e7e329d3
...@@ -169,9 +169,7 @@ $ -> ...@@ -169,9 +169,7 @@ $ ->
# Show/hide comments on diff # Show/hide comments on diff
$("body").on "click", ".js-toggle-diff-comments", (e) -> $("body").on "click", ".js-toggle-diff-comments", (e) ->
$(@).find('i'). $(@).toggleClass('active')
toggleClass('fa fa-chevron-down').
toggleClass('fa fa-chevron-up')
$(@).closest(".diff-file").find(".notes_holder").toggle() $(@).closest(".diff-file").find(".notes_holder").toggle()
e.preventDefault() e.preventDefault()
......
...@@ -22,9 +22,8 @@ ...@@ -22,9 +22,8 @@
.diff-btn-group .diff-btn-group
- if blob.text? - if blob.text?
= link_to '#', class: 'js-toggle-diff-comments btn btn-sm' do = link_to '#', class: 'js-toggle-diff-comments btn btn-sm active' do
%i.fa.fa-chevron-down %i.fa.fa-comments
Show/Hide comments
   
- if @merge_request && @merge_request.source_project - if @merge_request && @merge_request.source_project
......
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