I have 2 images side by side with no space in between. On hover the image scales in size 30%. One of the images when you hover on it grows but part of the image remains behind the image next to it. The other image grows and stay in front. Any ideas how to get both images to stay in front when hovered on.
Changing the z index doesn’t during the animation does not work
Those transforms (I believe) do not effect the document flow. Meaning applying any of those doesn’t move surrounding elements:
“Use 2D and 3D transforms to manipulate an element’s appearance and position without affecting surrounding elements.” – Transforms | Webflow University
So I’m not sure a z-index would help here:
"Positioned elements may overlap other elements in the natural document flow, therefore you can alter the Z-index value of any positioned element to change its default stacking order. " – Position | Webflow University
There may be some way I’m not aware of (maybe someone else can clue us in) but my first thought would be to not only “scale”, but also “move” on hover to avoid that.