This repository was archived by the owner on Jan 6, 2025. It is now read-only.
This repository was archived by the owner on Jan 6, 2025. It is now read-only.
Setting flex-basis to 0 results in max-width: 0 #277
Closed
Description
I'm trying to set up rows with equal-width columns. I can tell flexbox to not consider the contents in its calculations by setting a flex-basis of 0. This lets flex-grow distribute all available space in consistent proportions.
I tried the following:
<div fxLayout="row">
<div fxFlex="1 1 0px">Grows to 25% width</div>
<div fxFlex="3 1 0px">Grows to 75% width</div>
</div>
What resulted was both child divs having max-width: 0px
set, which ruined my layout. If I remove this max-width property, the row renders correctly. Here's a plunker demonstrating the issue.