title: Angular Ngx Charts not increasing width
body: <p>I have a basic stacked bar chart using the angular framework Ngx Charts and I would like the chars to grow horizontally when the parent div expands. I am using angular flex to align a couple of cards next to each other in a row and then once the screen gets smaller each card should take up 100% width of the screen and each card has 1 graph in it. My current code is this:</p>
  
  <pre><code>                &lt;div
                      *ngIf="data.length &gt; 0"
                      fxLayout="row"
                      fxLayout.lt-md="column"
                      fxLayoutGap="5px"
                    &gt;
                      &lt;mat-card *ngFor="let array of data"
                                fxFlex="0 1 0"
                                fxFlex.lt-md="0 1 100%"
                                fxFlex.lt-sm="100%"
                                class="max-height"
                      &gt;
                        &lt;mat-card-title style="font-size: 14px"&gt;
                          {{array.name}}
                        &lt;/mat-card-title&gt;
                          &lt;div style="height: 100%; width: 100%"&gt;
                            &lt;ngx-charts-bar-horizontal-stacked
                              (window:resize)="onResize($event)"
                              [results]="array.data"
                              [showXAxisLabel]="true"
                              [showYAxisLabel]="true"
                              [yAxis]="true"
                              [xAxis]="true"
                              [xAxisTickFormatting]="formatXAxis"
                              (select)="chartClicked($event)"
                            &gt;
                            &lt;/ngx-charts-bar-horizontal-stacked&gt;
                          &lt;/div&gt;
                      &lt;/mat-card&gt;
                    &lt;/div&gt;
  </code></pre>
  
  <p>There is no set number of charts so there could be 2 or 10 or more but so far everything works but when the cards grow to 100% of the screen width, the charts still stay small and dont strength horizontally to fit the new card width. I wrapped each chart in a div and set the div to 100% width and height so the charts should auto scale.</p>