Is there a way to block the scroll of the page for x seconds ? I have made a animation intro for my website but you can still scroll and go to th rest of the website.
Right now I used velo to not display sections till after the animation but It also happen when you change page and return to the homepage
Maybe itās simpler to go a page with only the animations & then redirect to the a ārealā main page ?
There are several ways. But the most efficient way depends on whether or not you have a premium account connect to your own domain (if you do, use custom element to set the style of the body & #SITE_CONTAINER to overflow-y: hidden!important; and pass a value to the custom element to remove this style once the video is done
. if you donāt - use setInterval(wixWindow.scrollTo(0,0), 20) and run clearInterval once the video is done, in the latter case the scrollbar will be displayed all the time you just wonāt be able to scroll. In the first option, the scrollbar will be hidden during the video play time).
I already published several posts on the subject. Try to search the forum first.
Sorry ! i didnt find anything on this. Itās my first time using velo, so to be honest if you can give me a example of the first solution ( I have a premium account) that would be Awesome !
Thanks again,
Thanks ! I think I understand how this works but not how to made it works. Like I said its the first time using velo and there is a pile of things I donāt understand even with the turotials. Like, HTMLElement is returning a error, where can I fix that ? Iāve seen that I must add someting to the tsconfig but again donāt really know how.
Thanks again a lot for your help
Add the code snippets I linked to the public/custom-elements folder in a new file.
Add the page code to the page.
Add a custom element to the page an configure its settings to point to the relevant custom code file with the custom element tag name.
Almost everything work at perfection. I just donāt understand why every section I have is a HiddenCollapsedElement & I canāt use setAttribute on them neither can I on the page itself