Why is there a flex gap around the first and last item in a wrapped row?

I have a flex row 1rem gap justify content flex-start, when wrapping it ends up being three rows. When it doesn't wrap, the first and last items are at the edges and there's a 1rem gap between columns and everything's fine. But when the row wraps, suddenly the first and last items are not at the edges - they have the 1rem gap around both sides of them. If I take out the gap while wrapping, it's also fine and aligns properly. But when wrapped, there's this noticeable gap at the front! Any ideas??
No description
4 Replies
Jenny P
Jenny POP6d ago
Nevermind.......... I figured it out......... dumb element has a "clearfix" class surrounding it and there's a :before element and an :after element being displayed as table and messing everything up.
vince
vince6d ago
Classic haah
Jenny P
Jenny POP6d ago
Haaaaaate clearfix...... hate when everything defaulted to floats........
13eck
13eck6d ago
No description

Did you find this page helpful?