Change z-index of stacked elements on hover
-
Hi!
I'm looking to change the z-index of stacked elements (mostly carousels) on hover so that every element can be visible.
I have here an example here:.
https://debutdebut.com/simonhaemmerli/home-2I achived to make it work with the first element with additional css like
.stack-wrap:nth-child(1):hover > .stack-element { z-index: -1; }but it's not working with:
.stack-wrap:nth-child(2):hover > .stack-element { z-index: -1; }maybe there is also a js approach to this?
Thx for any feedback.Cheers
Max -
Dear @debutdebut
you can give each element an ID.
Then you can address them individually.
Hope that helps!
Marius
-
Dear @debutdebut
you can give each element an ID.
Then you can address them individually.
Hope that helps!
Marius
@mariusjopen thx! Will try this approach
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login