ConstraintLayout version: 2.0.0-alpha3
So I am using MotionLayout I wanted to create something similar to this. https://blog.stylingandroid.com/motionlayout-collapsi
The bug is now fixed! Go and live your merry life without any visibility glitches :)
For future readers: This was known bug in MotionLayout where the state reset when the user touched something. Nicolas is talking about this around here: https://youtu.be/r8cYDlBOPaA?t=2276
The team fixed it in Alpha 4.