Skip to content

Commit

Permalink
Fixed footer not animating
Browse files Browse the repository at this point in the history
  • Loading branch information
Matija Čupić committed Aug 31, 2016
1 parent 8ae3d47 commit 8b135b9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions assets/js/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,21 @@

var headerWaypoint = new Waypoint({
element: document.getElementById('masthead'),
offset: -5,
handler: function (direction) {
if (direction === 'down')
this.element.classList.remove('animation-on');
else
this.element.classList.add('animation-on');
}
},
offset: -5
});

var footerWaypoint = new Waypoint({
element: document.getElementById('footer'),
handler: function (direction) {
this.element.classList.toggle('animation-on');
}
},
offset: 'bottom-in-view'
});

}
Expand Down

0 comments on commit 8b135b9

Please sign in to comment.