I am using Angular material 2 and I am getting this problem where the md-sidenav-content only takes up the height of the content. However, I want it to be either 100% of the height or the content height (whichever is largest). Note that the parent container which is md-sidenav-container does have the full height that I wanted.
However, at no place in my app I used md-sidenav-content. It seems to be something generated by Angular Material 2 itself. So I cant change the property of it.
With this problem present, I can't get the green background to span the full height.
// app.component.html
<md-sidenav-container>
<!--side nav-->
<md-sidenav #sidenav mode="over" class="app-sidenav">
<!--header-->
<div id="side-nav-header">
<img id="side-menu-logo" src="../assets/images/logo_small.png"> MyApp
</div>
<!--body-->
<a [mdTooltip]="!isCurrentUserExist ? 'Please login first!': ''" [routerLink]="['/create-timesheet']" (click)="sidenav.close()">Timesheet</a>
</md-sidenav>
<br><br>
<!--main content-->
<router-outlet></router-outlet>
</md-sidenav-container>
// login.component.html
<div id="login-container" class="container-fluid">
<div class="row">
<div id="login-component" class="col-md-6 offset-md-3">
<md-card>
<h2>Login</h2>
<br>
<form name="form" [formGroup]="loginForm" (ngSubmit)="onLogin()">
<!--email-->
<md-input type="email" placeholder="Email" formControlName="email"></md-input>
<label class="errorMessage" *ngIf="!loginForm.controls['email'].valid && loginForm.controls['email'].dirty" for="email">
Email is required</label>
<!--password-->
<md-input type="password" placeholder="Password" formControlName="password"></md-input>
<label class="errorMessage" *ngIf="!loginForm.controls['password'].valid && loginForm.controls['password'].dirty" for="lastName">
Password is required</label>
<br><br>
<div class="form-group">
<button [disabled]="loading || !loginForm.valid" class="btn btn-primary">Login</button>
<a *ngIf="!isLoading" [routerLink]="['/forgot-password']" (click)="onForgotPassword()">forgot password</a>
</div>
</form>
</md-card>
</div>
</div>
</div>
// loging.component.css
#login-container {
min-height: 100%;
background-color: green;
}