jQuery fadeIn on position:absolute causes z-index issue

后端 未结 5 517
青春惊慌失措
青春惊慌失措 2020-12-15 07:57

Technically I\'m using fadeToggle() but they\'re cousins... basically my issue is that I have an absolutely positioned div which I am using slideToggle()<

5条回答
  •  再見小時候
    2020-12-15 08:24

    Put a div around your toggling div. Add style with position relative and correct z-index. (It can happen, that z-index 1 is not enough big for you, then try with higher level, etc. 100)

    ...

    This way the toggling component will hide when it supposed to but the div around will never and it will never loose it's z-index.

提交回复
热议问题