Move easings into global file
This commit is contained in:
@@ -176,7 +176,7 @@ const smoothScrollPromise = (target: HTMLElement, duration: number = 1600): Prom
|
||||
if (startTime === null) startTime = currentTime
|
||||
const timeElapsed = currentTime - startTime
|
||||
// Create easing value
|
||||
const easedYPosition = easeInOutQuart(timeElapsed, startPosition, distance, duration)
|
||||
const easedYPosition = quartInOutFunc(timeElapsed, startPosition, distance, duration)
|
||||
// Scroll to Y position
|
||||
window.scrollTo(0, easedYPosition)
|
||||
// Loop or end animation
|
||||
|
||||
Reference in New Issue
Block a user