File tree Expand file tree Collapse file tree 2 files changed +15
-10
lines changed
projects/components/src/toggle-switch Expand file tree Collapse file tree 2 files changed +15
-10
lines changed Original file line number Diff line number Diff line change 11@import ' color-palette' ;
22@import ' font' ;
33
4- :host {
4+ .toggle-switch {
5+ display : flex ;
6+ align-items : center ;
7+
58 ::ng- deep {
69 .mat- slide- toggle {
710 &.disabled {
Original file line number Diff line number Diff line change @@ -7,15 +7,17 @@ import { ToggleSwitchSize } from './toggle-switch-size';
77 styleUrls : [ './toggle-switch.component.scss' ] ,
88 changeDetection : ChangeDetectionStrategy . OnPush ,
99 template : `
10- <mat-slide-toggle
11- color="primary"
12- [checked]="this.checked"
13- [ngClass]="{ 'small-slide-toggle': this.size === '${ ToggleSwitchSize . Small } ', disabled: this.disabled }"
14- [disabled]="this.disabled"
15- (change)="this.onToggle($event)"
16- >
17- <div class="label">{{ this.label }}</div>
18- </mat-slide-toggle>
10+ <div class="toggle-switch">
11+ <mat-slide-toggle
12+ color="primary"
13+ [checked]="this.checked"
14+ [ngClass]="{ 'small-slide-toggle': this.size === '${ ToggleSwitchSize . Small } ', disabled: this.disabled }"
15+ [disabled]="this.disabled"
16+ (change)="this.onToggle($event)"
17+ >
18+ <div class="label">{{ this.label }}</div>
19+ </mat-slide-toggle>
20+ </div>
1921 `
2022} )
2123export class ToggleSwitchComponent {
You can’t perform that action at this time.
0 commit comments