()
| 139 | readonly isZoneless = this._ngZone instanceof ɵNoopNgZone; |
| 140 | |
| 141 | constructor() { |
| 142 | this.testMode = this._route.queryParams.pipe(map(params => params['testonly'] === 'true')); |
| 143 | this.toggleTheme(this.state.darkTheme); |
| 144 | this.toggleSystemTheme(this.state.systemTheme); |
| 145 | this.toggleStrongFocus(this.state.strongFocusEnabled); |
| 146 | this.toggleDensity(Math.max(this._densityScales.indexOf(this.state.density), 0)); |
| 147 | this.toggleRippleDisabled(this.state.rippleDisabled); |
| 148 | this.toggleDirection(this.state.direction); |
| 149 | this.toggleM3(this.state.m3Enabled); |
| 150 | this.toggleColorApiBackCompat(this.state.colorApiBackCompat); |
| 151 | |
| 152 | this.testMode.subscribe(isTestOnly => { |
| 153 | if (isTestOnly) { |
| 154 | this.toggleM3(true); |
| 155 | this.toggleSystemTheme(true); |
| 156 | this._document.body.classList.add('demo-testonly-mode'); |
| 157 | } |
| 158 | }); |
| 159 | } |
| 160 | |
| 161 | toggleTheme(value = !this.state.darkTheme) { |
| 162 | this.state.darkTheme = value; |
nothing calls this directly
no test coverage detected