From 596ba2173c7626fa41ffa5c3b5ab62ac8b3903b9 Mon Sep 17 00:00:00 2001 From: abhay Date: Thu, 13 Oct 2016 11:55:10 -0700 Subject: [PATCH 1/2] fixed typo. This fixes the following issue - when we land on in the middle of the page the top is applied without 'px' so it never gets applied --- sticky-kit.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sticky-kit.coffee b/sticky-kit.coffee index 73c3b13..5a6a4a3 100644 --- a/sticky-kit.coffee +++ b/sticky-kit.coffee @@ -182,7 +182,7 @@ $.fn.stick_in_parent = (opts={}) -> fixed = true css = { position: "fixed" - top: offset + top: offset + "px" } css.width = if elm.css("box-sizing") == "border-box" From 5ff7c72cb48797526de6677a8cadaab8b523529f Mon Sep 17 00:00:00 2001 From: Abhay Date: Wed, 16 Nov 2016 10:13:07 -0800 Subject: [PATCH 2/2] added z index --- dist/sticky-kit.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dist/sticky-kit.js b/dist/sticky-kit.js index 9597bd0..a848e93 100644 --- a/dist/sticky-kit.js +++ b/dist/sticky-kit.js @@ -106,7 +106,8 @@ height: height, display: elm.css("display"), "vertical-align": elm.css("vertical-align"), - "float": el_float + "float": el_float, + "z-index": -1 }); } if (restore) {