From f0698441142683baea3838f448e1f7ab394ae85e Mon Sep 17 00:00:00 2001 From: Sudev Kiyada Date: Tue, 3 Jun 2025 13:12:46 +0530 Subject: [PATCH] fixes error --- src/components/ScrollyVideo/js/ScrollyVideo.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/ScrollyVideo/js/ScrollyVideo.ts b/src/components/ScrollyVideo/js/ScrollyVideo.ts index 94d85e7c..8ee20319 100644 --- a/src/components/ScrollyVideo/js/ScrollyVideo.ts +++ b/src/components/ScrollyVideo/js/ScrollyVideo.ts @@ -331,7 +331,10 @@ class ScrollyVideo { * - transitionSpeed: number - Defines the speed of the transition when `jump` is false. Represents the duration of the transition in milliseconds. Default is 8. * - easing: (progress: number) => number - A function that defines the easing curve for the transition. It takes the progress ratio (a number between 0 and 1) as an argument and returns the eased value, affecting the playback speed during the transition. */ - setVideoPercentage(percentage: number, options: TransitionOptions): void { + setVideoPercentage( + percentage: number, + options: TransitionOptions = { jump: false, transitionSpeed: 8 } + ): void { // Early termination if the video percentage is already at the percentage that is intended. if (this.videoPercentage === percentage) return;