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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
6507c108
Commit
6507c108
authored
Jun 20, 2012
by
Zevs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Handle Commit "show suppressed diff" link with a doc-ready event handler."
This reverts commit
ef1598b4
.
parent
a9c7de88
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
8 deletions
+6
-8
app/assets/javascripts/application.js
app/assets/javascripts/application.js
+5
-0
app/assets/javascripts/commits.js
app/assets/javascripts/commits.js
+0
-7
app/views/commits/_text_file.html.haml
app/views/commits/_text_file.html.haml
+1
-1
No files found.
app/assets/javascripts/application.js
View file @
6507c108
...
...
@@ -75,6 +75,11 @@ function slugify(text) {
return
text
.
replace
(
/
[^
-a-zA-Z0-9
]
+/g
,
'
_
'
).
toLowerCase
();
}
function
showDiff
(
link
)
{
$
(
link
).
next
(
'
table
'
).
show
();
$
(
link
).
remove
();
}
(
function
(
$
){
var
_chosen
=
$
.
fn
.
chosen
;
$
.
fn
.
extend
({
...
...
app/assets/javascripts/commits.js
View file @
6507c108
...
...
@@ -57,10 +57,3 @@ var CommitsList = {
});
}
}
$
(
function
()
{
$
(
'
a.supp_diff_link
'
).
live
(
'
click
'
,
function
()
{
$
(
link
).
next
(
'
table
'
).
show
();
$
(
link
).
remove
();
});
});
app/views/commits/_text_file.html.haml
View file @
6507c108
-
too_big
=
max_lines
=
diff
.
diff
.
lines
.
count
>
1000
-
if
too_big
%a
.supp_diff_link
Diff suppressed. Click to show
=
link_to_function
"Diff suppressed. Click to show"
,
"showDiff(this)"
,
:class
=>
"supp_diff_link"
%table
{
:class
=>
"#{'hide' if too_big}"
}
-
each_diff_line
(
diff
.
diff
.
lines
.
to_a
,
index
)
do
|
line
,
type
,
line_code
,
line_new
,
line_old
|
...
...
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