dixonandmoe / rellax

Lightweight, vanilla javascript parallax library
https://dixonandmoe.com/rellax/
MIT License
7.04k stars 880 forks source link

Rellax does not apply Parallax Effect to Element (No 3D Translate) #219

Open Lukaskrojer opened 3 years ago

Lukaskrojer commented 3 years ago

Hey, so i am trying to apply a parallax Effect to a element. I implemented all i need to the project but it does not work. It does recognize the implemented Javascript, but it does not apply the translate 3D effect to the Element. (It always stays at 0px) I have to edit, that its a horizontal Scrolling page & the code for it to work does look like this:

Bildschirmfoto 2020-11-23 um 16 46 28

Does sb have an idea why this does not work or what is blocking the element to execute? Am i missing something?

Bildschirmfoto 2020-11-23 um 16 43 15

zangab commented 3 years ago

I have to edit, that its a horizontal Scrolling page ...

and then u set option horizontal: false. what u expect dude? 😄

Lukaskrojer commented 3 years ago

and then u set option horizontal: false. what u expect dude? 😄

It worked with horizontal: false, because for the horizontal parallax i created 1 container around the elements, and inside of the container i created a wrapper - again around the elements. So what i did is: i rotated the outer container 90deg and the inner wrapper again -90deg - thats why horizontal is false ;)