Android how to create gradient shadow on left and right of view?
10:41 21 Dec 2015

I cannot use Lollipop elevation property because I need to target devices from API 18.

I need to place a shadow on the right and left side of a view.

This is what I tried so far :




    
        
            
            

            

            

            
        
    

    

    
        
            
            
        
    

I tried adding gradients in the first item, but it spreads from left to right which is not what I am looking fo. Is there a way to isolate two unique gradients for each side ?

This is what I am trying to do :

enter image description here

android xml user-interface gradient shadow