Browse Source

Fixes bug in jquery waypoint usage

pull/313/head
jlukic 11 years ago
parent
commit
870b62a377
1 changed files with 1 additions and 2 deletions
  1. 3
      server/files/javascript/library/waypoints.js

3
server/files/javascript/library/waypoints.js

@ -554,10 +554,9 @@ https://github.com/imakewebthings/jquery-waypoints/blob/master/licenses.txt
originalHandler = options.handler;
options.handler = function(direction) {
var $sticky, shouldBeStuck;
$sticky = $(this).children(':first');
shouldBeStuck = direction === 'down' || direction === 'right';
$sticky.toggleClass(options.stuckClass, shouldBeStuck);
$wrap.toggleClass(options.stuckClass, shouldBeStuck);
$wrap.height(shouldBeStuck ? $sticky.outerHeight() : '');
if (originalHandler != null) {
return originalHandler.call(this, direction);

Loading…
Cancel
Save