Change theme
Help
Press space for more information.
Show links for this issue (Shortcut: i, l)
Copy issue ID
Previous Issue (Shortcut: k)
Next Issue (Shortcut: j)
Sign in to use full features.
Vote: I am impacted
Notification menu
Refresh (Shortcut: Shift+r)
Go home (Shortcut: u)
Pending code changes (auto-populated)
View issue level access limits(Press Alt + Right arrow for more information)
Unintended behavior
View staffing
Description
MotionLayout does not allow updating progress after an auto-completed scroll transition. When users manually scroll and leave the MotionLayout halfway, the framework completes the transition automatically. However, further updates to the MotionLayout's progress become blocked.
2. Environment
Device: [Specify device model]
Android Version: [Specify Android version]
Compose Version: 1.1.0-alpha09
MotionLayout Version: 1.1.0-alpha09 / 1.1.0-rc01
Compile SDK Version: [Specify SDK version]
Gradle Version: [Specify Gradle version]
3. Steps to Reproduce
Implement a MotionLayout in your Composable function using the specified version.
Set up a MotionScene with start and end ConstraintSets.
Manually scroll through the MotionLayout, leaving it halfway.
Observe the MotionLayout's auto-completion behavior to either the start or end state.
Attempt to programmatically change the progress after the auto-completion.
4. Expected Behavior
The MotionLayout should allow for updates to its progress after an auto-completed scroll, enabling transitions to new states programmatically.
5. Actual Behavior
After auto-completion, the MotionLayout does not accept further progress updates, blocking users from changing the state.
6. Additional Information
The issue is not present in version 1.1.0-alpha03, where all behaviors function as expected, allowing both manual and programmatic updates seamlessly.
The latest version 1.1.0-rc01 also exhibits the same issue, alongside the need for additional animation logic due to the absence of rememberMotionLayoutState().
7. Suggested Fix
Investigate the handling of progress updates after an auto-completion event within the MotionLayout's internal state management.
Consider implementing a mechanism to allow progress updates post-transition or ensure that state changes are not locked after the completion of an auto-transition.
8. Attachments
I used code from below project
Credits: