Hello I would like to create an endless text block where there is no interruption in the text. Right now my text just reaches over the screen. In the animation I created, the text goes completely across the screen before it repeats, meaning I have a gap in text. How can I avoid this? That no interruption of the text takes place.
import { timeline } from 'wix-animations';
import wixWindow from 'wix-window';
function getWindowSize() {
return wixWindow.getBoundingRect ()
.then ((windowSize) => {
return windowSize.window;
});
}
$w.onReady(function () {
// Scroll text
let scrollRtL = $w('#text');
// Timelines
let scrollingTextRtL = timeline({ repeat: -1 });
getWindowSize ()
.then ((windowSize) => {
scrollingTextRtL
.add(scrollRtL, {
x: -windowSize.width,
duration: 10000,
easing: 'easeLinear'
});
scrollingTextRtL.play();
});
});
This is how it looks at the moment.
And this is how it should be looped.
I would be happy if you have any tips for me!