Hi everyone,
I think, this will be useful for some or many!!!
I am sharing a code I got while searching and with some modifications…
Here’s what I am sharing with you, all, today …
When the mouse pointer enters the container the image will start the effect!!!
For this →
#dataset1 - dataset
#repeater1 - repeater connected to dataset1
#container1 - container in the repeater
#image1 - image for the effect
import { timeline } from 'wix-animations';
$w.onReady(function () {
$w('#dataset1').onReady(() => {
$w('#repeater1').forEachItem(($item, itemData, index) => {
$item('#container1').onMouseIn((event) => {
timeline()
.add($item('#image1'), { y: 4, x: 4, scale: 1.40, duration: 600, easing: 'easeOutCirc' })
.play()
});
$item('#container1').onMouseOut((event) => {
const reset = { y: 0, x: 0, scale: 1, duration: 600, easing: 'easeOutCirc' };
timeline()
.add($item('#image1'), reset)
.play()
})
});
});
});
Instead of ‘easeOutCirc’ you can use many …
from here → easeOutCirc constant - Curves class - animation library - Dart API
Hope, this will be useful !!!