fxFlex not resizing elements

Viewed 1560

fxFlex directive not working on width, however when I manually set a width it works, how can I make it work?

I have tried making the mat-card element width 100% in the styles.scss file but that takes all of the space available in the div

The div grabs all the available space

<div fxLayout="column" fxLayoutAlign="start center" fxLayoutGap="10px" fxFill>

    <mat-card fxFlex.lt-sm="90" fxFlex.lt-md="80"  fxFlex="70">
        <mat-card-title>Create a new user</mat-card-title>
        <mat-card-content>

        </mat-card-content>
    </mat-card>
</div>

I get this got this

But I want this using only directives expected

1 Answers

You may want to try using fxLayout="row" instead of "column".

Related