Prevent body scrolling but allow overlay scrolling

Hi there,

just wondering if there is a way to create this example more or less with native webflow CSS.
Especially the arian-hidden function.

best kalli

Hi @Kalli2000!

Take a peek here, it shows some custom code that can be used to make the body overflow hidden on modal open and body set to overflow scroll when modal is closed:

I hope this helps! if not, share a link to your site and I am happy to take a look further:

I hope this helps!


thanks works perfect!

1 Like