react-native style opacity for parent and child

前端 未结 6 1815
再見小時候
再見小時候 2021-02-05 00:03

react-native : I have one View and the child of View is an Image , I applied opacity: 0.5 for View and opacity: 0.9 for an Image but it doesn\'t apply for Image ,the parent opac

6条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-02-05 00:07

    Try changing the opacity using alpha-value of the background color instead. Then it should be possible applying different opacities for children.

    For example:

    
    

提交回复
热议问题