I got animation like in the video attached that is triggered via the code below:
// tab is the html div object of the clicked tab button
// blue line is the html div object of the line below the buttons
gsap.to(
blueLine,
{
duration: 0.5,
left: tab.offsetLeft,
width: tab.offsetWidth,
overwrite: false,
lazy: false
}
)
As you can see on the video it looks like gsap is resetting the "left" property to 0 and animates it from there.
Is there a way to not reset the value and instead animate from the current property value?
I couldn't find anything about it in the docs or forum.
Screen Recording 2023-01-24 at 00.43.10.mov