How do I maintain the width of the card here
8 Replies
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
i want it to overflow,
i just want the u-card to maintain a specific width, but it shrinks on flex
Flexbox respect max-width and min-width
So do with that what you want
If you want the card to be always width 100% just do min-width: 100%
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
flex children have flex-shrink set to 1 by default try setting it to 0 ;
ok
flex-shrink: 0; worked, thanks ✌️
other option would have been a
display: grid
and grid-auto-flow: column
on the container, then you can get rid of the flex-shrink: 0
on the children
you could even set the width on the columns, instead of the children
grid-auto-columns: 50rem;