Fix sticky shim having zero height

We ‘shim’ the sticky element so that its space in the page is reserved
while it is sticky.

This means the shim have have the same height as the sticky element.
It’s height was not getting set because of a missing semicolon in the
shim element’s `style` attribute.
This commit is contained in:
Chris Hill-Scott
2018-12-10 15:57:40 +00:00
parent 77c61238e9
commit cac2ce661b

View File

@@ -235,7 +235,7 @@
return windowTop > el.scrolledTo;
};
stickAtTop.addShimForEl = function ($el, width, height) {
$el.before('<div class="shim" style="width: ' + width + 'px height: ' + height + 'px">&nbsp</div>');
$el.before('<div class="shim" style="width: ' + width + 'px; height: ' + height + 'px">&nbsp;</div>');
};
stickAtTop.stop = function (el) {
if (!el.stopped()) {