simple-scroll-snap icon indicating copy to clipboard operation
simple-scroll-snap copied to clipboard

Excess snapping animation to Starting Panel with no 'Use Automatic Layout'

Open Maligan opened this issue 2 years ago • 1 comments

In case of using non automatic scroll-snap layout there is a problem with excess animation lerp to the first panel.

These lines in Setup can fix this behaviour:

private void Setup()
{
    ...
    
    // Starting Panel
    ...
    
    Vector2 targetPosition = -Panels[CenteredPanel].anchoredPosition + offset;
    Content.anchoredPosition = targetPosition;
    
    // Buttons
    ...
}

Or may be you can consider another solution.

Maligan avatar Nov 06 '22 14:11 Maligan