Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
e0f8e022
Commit
e0f8e022
authored
Mar 18, 2015
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve comment toggle button in diff
parent
e7e329d3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
6 deletions
+3
-6
app/assets/javascripts/application.js.coffee
app/assets/javascripts/application.js.coffee
+1
-3
app/views/projects/diffs/_file.html.haml
app/views/projects/diffs/_file.html.haml
+2
-3
No files found.
app/assets/javascripts/application.js.coffee
View file @
e0f8e022
...
@@ -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
()
...
...
app/views/projects/diffs/_file.html.haml
View file @
e0f8e022
...
@@ -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
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment