{"id":303002,"date":"2020-02-06T17:59:30","date_gmt":"2020-02-07T00:59:30","guid":{"rendered":"https:\/\/css-tricks.com\/?p=303002"},"modified":"2020-02-06T17:59:31","modified_gmt":"2020-02-07T00:59:31","slug":"getting-fancy-with-position-sticky","status":"publish","type":"post","link":"https:\/\/css-tricks.com\/getting-fancy-with-position-sticky\/","title":{"rendered":"Getting Fancy with position: sticky;"},"content":{"rendered":"\n

Mike Solomon<\/a> worked on a fancy scrollytelling post for Esquire<\/a> and blogged about it<\/a>. It has GIFs of each step along the way of figuring out not just position: sticky;<\/code> but also using negative margins, wrapper divs, backgrounds, and even a smidge of JavaScript measuring to get it all right. <\/p>\n\n\n\n

What it doesn’t have is any isolated demo of the effect. I figured I’d give a crack at reverse engineering it. <\/p>\n\n\n\n\n\n\n\n

Here’s mine, which I’ll call “Sticky Figcaption with Protruding Figure”:<\/p>\n\n\n\n