Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
N
NAP-wordpress
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Marwa Sfari
NAP-wordpress
Commits
9562ff6a
Commit
9562ff6a
authored
Aug 30, 2017
by
imac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Bugfix]Redmine #721 : Scroll image cover
parent
8cdefe57
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
6 deletions
+8
-6
main.js
wp-content/themes/nap/assets/js/main.js
+8
-6
No files found.
wp-content/themes/nap/assets/js/main.js
View file @
9562ff6a
...
...
@@ -581,19 +581,20 @@ $(items).each(function () {
var
refElement
=
$
(
currLink
.
attr
(
"href"
));
//console.log(currLink);
if
(
refElement
.
length
&&
refElement
.
position
().
top
-
(
$
(
".main"
).
outerHeight
()
/
2
-
titleHeight
-
$
(
".footer"
).
outerHeight
()
)
<=
scrollPos
&&
refElement
.
position
().
top
+
refElement
.
height
()
>
scrollPos
)
{
if
(
timer
)
clearTimeout
(
timer
);
timer
=
setTimeout
(
function
(){
$
(
'.subcat a'
).
removeClass
(
"active"
);
currLink
.
addClass
(
"active"
);
if
(
$
(
'nav ul ul'
).
find
(
'li.active'
)){
$
(
'nav ul li'
).
removeClass
(
'current'
).
addClass
(
'off'
);
parent
=
currLink
.
parent
().
parent
().
parent
();
parent
.
addClass
(
'current'
).
removeClass
(
'off'
);
$
(
'.phototheque .off .subcat'
).
stop
().
slideUp
();
parent
.
find
(
'ul'
).
stop
().
slideDown
();
if
(
timer2
)
clearTimeout
(
timer2
);
timer2
=
setTimeout
(
function
(){
$
(
'.phototheque .off .subcat'
).
stop
().
slideUp
();
parent
.
find
(
'ul'
).
stop
().
slideDown
();
},
330
);
}
},
330
);
}
else
{
currLink
.
removeClass
(
"active"
);
...
...
@@ -660,6 +661,7 @@ $(window).load( function() {
})
});
//END document load
var
timer
;
var
timer2
;
$
(
window
).
scroll
(
function
(
e
)
{
onScroll
(
e
);
var
elem
=
$
(
'.home-down-wrapper'
);
...
...
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