Skip to content
This repository has been archived by the owner on Dec 15, 2018. It is now read-only.

Stick To Top of Parent? #16

Closed
randallmeeker opened this issue Jan 28, 2014 · 5 comments
Closed

Stick To Top of Parent? #16

randallmeeker opened this issue Jan 28, 2014 · 5 comments

Comments

@randallmeeker
Copy link

Do you think it would be possible to stick to the top of the parent and not just to the top of the window? I'll start playing with the code, but thought I would see if anyone had tried yet.

@facundocabrera
Copy link

Please check https://github.com/marcosgallardo/jquery.sticky ... We are adding more documentation soon.

@Wilto
Copy link
Member

Wilto commented Jan 28, 2014

@dendril This doesn’t seem to address the question in the issue.

@zachleat
Copy link
Member

Not sure what you mean here, sticky elements are constrained to their parent containers by default. The plugin operates with that in mind.

@randallmeeker
Copy link
Author

Sorry, let me try and be a little more specific. If I have a scrollable div in the middle of my page. If a child contained in that element could be stuck to that specific element when scrolled. It appears the current implementation only works when my element and it's parent are scrolled to the top/bottom of the window.

If anyone here uses angular I just made a directive for this script
https://github.com/randallmeeker/psFixedsticky

@zachleat
Copy link
Member

See also #13.

Unfortunately, I don’t think we’ll be supporting this use case. We tend to avoid element-overflow whenever possible for the widest support on touch screens (and easiest true-to-native scrolling).

Sorry! Feel free to fork and I’d be happy to include a link in the README.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants