Skip to content

Commit 5e85e63

Browse files
committed
fix(material/slider): form control w/ initial disabled state
1 parent 6011b7d commit 5e85e63

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/material/slider/slider-input.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,12 @@ export class MatSliderThumb implements _MatSliderThumb, OnDestroy, ControlValueA
275275
/** @docs-private */
276276
initProps(): void {
277277
this._updateWidthInactive();
278-
this.disabled = this._slider.disabled;
278+
279+
// If this or the parent slider is disabled, just make everything disabled.
280+
if (this.disabled !== this._slider.disabled) {
281+
this._slider.disabled = true;
282+
}
283+
279284
this.step = this._slider.step;
280285
this.min = this._slider.min;
281286
this.max = this._slider.max;

0 commit comments

Comments
 (0)