How to use zIndex in react-native

后端 未结 5 1242
攒了一身酷
攒了一身酷 2020-12-23 13:19

I\'ve want to achieve the following:

The following images are what I can do right now, but that\'s NOT what I want.

Sample of code I have right now

5条回答
  •  渐次进展
    2020-12-23 13:57

    You cannot achieve the desired solution with CSS z-index either, as z-index is only relative to the parent element. So if you have parents A and B with respective children a and b, b's z-index is only relative to other children of B and a's z-index is only relative to other children of A.

    The z-index of A and B are relative to each other if they share the same parent element, but all of the children of one will share the same relative z-index at this level.

提交回复
热议问题