cssangularangular-material2

Angular Material2 md-checkbox border color


I am using Angular Material 2 and I am trying to apply css on md-checkbox. So far I managed to change background color, but there is no documentation on how to apply on border color.

My code for height-width:

:host /deep/ .mat-checkbox-inner-container{
     height:15px;
     width:15px; 
}

code for background color on check:

 :host /deep/  .mat-checkbox-checked .mat-checkbox-background {
    background-color: #72addc;
} 

but still cannot apply on border color.

Any help is welcome!


Solution

  • For Angular 5+ version

    /deep/ .mat-checkbox-frame { 
        border-color: grey 
    }
    

    You can learn more about styling components here https://angular.io/guide/component-styles