Difference between auto, 0, and no z-index?

前端 未结 5 751
温柔的废话
温柔的废话 2021-02-11 17:12

What is the difference between:

  1. z-index: auto
  2. z-index: 0
  3. no z-index at all

All the above sc

5条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-02-11 17:40

    n CSS, you can position 2 or more objects to overlap each other. Their z-indexes determine which objects are "in front of" or "behind" other objects that they overlap. The higher an object's z-index, the "higher in the stack" of objects it will display

提交回复
热议问题