Fixed div with an image inside and on scroll effect

Hello there

Following setup:

section->div->img

div is set to fixed position.

image has a scale effect on scroll: enter scale 1, exit scale 0.5.
Event: in and out = scoll up image scales down, scroll down image scales up.

As soon as I change the origin of the object to any “top” setting, the effect jumps to the exit position and nothing happens at scroll.

why?

thx for any hint

EDIT: sometimes it works, sometimes it does not. no caching at the moment whatsoever. The behavior is very inconsistent.

EDIT II: There’s a video in the secure note describing the issue.

EDIT III: Changig the the offset value of the effect from 10% to 0 brought it back to life. Why oh why.

Hello @VRANKOVINA,

Thank you for the inquiry.

This is expected because when the origin is set to Top , the element is effectively pulled upwards, perpetually triggering the exit transform or effect. To compensate for this, you need to either adjust the element’s top margin or use a negative top/bottom offset value, such as -50% . Same behavior should happen when you set it to Bottom. With this in mind, the ideal Origin value should be Center to avoid the need to adjust the top/bottom offset value.

Let us know if you need more info.

Best regards.

Roger. Good to know. Thx a heap.
Looks good so far.

Great! Feel free to open another thread if you have more questions. Have a nice day.