I want to create this layout
this is a cardview (gray view) and imageview(blue view) for that i use this code
Another way around it would be to wrap the image view in a card view. Just ensure the background is transparent with height and width wrapping content and it will go on top of the previous card view.