jump.js icon indicating copy to clipboard operation
jump.js copied to clipboard

Custom scroll container

Open josdejong opened this issue 8 years ago • 12 comments

Thanks for writing jump.js, it has a nice API!

I have a use case where I would like to scroll not the window as a whole, but the contents of a specific div. It would be great if I could configure a custom container element rather than using window. As far as I can see that's currently not possible or am I overlooking something?

josdejong avatar Jan 05 '17 11:01 josdejong

I see an old PR, #24, adding support for a custom scroll container. Would love to see that in the library :D

josdejong avatar Jan 05 '17 12:01 josdejong

I created a PR too, see #51

josdejong avatar Jan 05 '17 13:01 josdejong

Any plans for this to land in one of the next versions?

astoilkov avatar Feb 03 '17 11:02 astoilkov

Yes please merge this PR :)

powerbuoy avatar Feb 13 '17 13:02 powerbuoy

Any chance of getting this merged in? Can we do something to help with this?

niksy avatar Apr 12 '17 12:04 niksy

Disappointed this hasn't been addressed. PR #24 doesn't appear to bloat the library which was the initial concern, and this feature is necessary for SPAs

mikebywaters avatar May 14 '17 12:05 mikebywaters

Yea, I had to switch to Velocity.js which is unfortunate as it comes with plenty of features I never use.

powerbuoy avatar May 15 '17 08:05 powerbuoy

Would be great to get this merged for @mikebywaters reasonings. I have a div that I want to scroll instead of window.

karltaylor avatar Feb 06 '19 18:02 karltaylor

Please merge this PR!

macedomauriz avatar Apr 10 '19 19:04 macedomauriz

Please merge this PR!

Leesson avatar Jun 05 '19 07:06 Leesson

Any idea why this PR is not getting merged? Seems like a useful one!

michaelpumo avatar Nov 28 '19 17:11 michaelpumo

For what it's worth for anyone else coming across here, I personally decided to use Anime.js (only around 6KB).

See an example of how to smooth scroll here: https://codepen.io/rukiadia/pen/qYyLdw

As you can see a custom container element is quite easy to setup.

Since this PR hasn't been merged or looked at for so long I worry that something has happened to the original creator. I hope he/she is doing okay but I would consider this library effectively deprecated from new changes.

michaelpumo avatar Feb 18 '20 17:02 michaelpumo