I use a fragment to show comments and rating, I want to apply an effect, for example, when we pull a fragment up or down, it closes or disappears with animation, for example, a facebook comment layout.
This is my layout. It contains a Recyclerview.

I want that when I drag this layout up or down, it closes the way the facebook comment layout does.

Can you suggest me a way how I can achieve this functionality.
rahul source share