enszrlu / NextStep

Lightweight onboarding library for Next.js
https://nextstepjs.com
149 stars 8 forks source link

Disabling scroll #8

Open verellino opened 2 weeks ago

verellino commented 2 weeks ago

When using nextStep in custom card component, my viewport scrolls to top of the selected component on selector id, causing the scroll to jump around to the sections.

Is there a possible way to disable scroll when component is in viewport?

enszrlu commented 1 week ago

Hello @verellino . Have you checked "Using NextStepViewport and viewportID" section in the docs.

Your issue is not very clear to me but this might be the solution to your problem. 😊 If not, can you please eloborate the issue?

verellino commented 1 week ago

I tried playing around with the NextStepViewport but still scrolled to element. Let me show you an example, this is my full dashboard image

But when I assign a step id it automatically scrolls down to the top of element. Screenshot 2024-11-06 182544

What I want to do is disable the scroll to element, because it is still visible on screen. Can we assign a step to be not scrollable?

enszrlu commented 1 week ago

I tried playing around with the NextStepViewport but still scrolled to element. Let me show you an example, this is my full dashboard image

But when I assign a step id it automatically scrolls down to the top of element. Screenshot 2024-11-06 182544

What I want to do is disable the scroll to element, because it is still visible on screen. Can we assign a step to be not scrollable?

Oh I better understand it now. Yes, we can do that. I am very busy nowadays, but I will add it to the list and try to sort it out as soon as possible.