I use GSAP to animate the individual page changes. The process is as follows:
- user clicks on a link that has the class “.has-page-transition”
- black area is animated from left to right over the entire viewport so that the page content is not visible
- the new page is loaded, the black area is still displayed
- as soon as the page has finished loading, the black area is animated from left to right to show the new content
Unfortunately, I encounter several problems:
- the links do not get their active css styling, I thought it would be enough to pass the class “.active” to the links
- my animation is only triggered in the main navigation, not on normal links, such as “read about me” or the first project “Canyon Bicycles” at the bottom in the project list.
I assume that it is due to the routing and the single app structure of webstudio. Can you give me some input so that I can customize my script.