Change default background color of md-slider of Angular Material

后端 未结 7 634
野的像风
野的像风 2021-02-04 20:06

I am using md-slider of Angular Material version 2.0.0-beta.8

I have selected the indigo-pink theme and imported it in

7条回答
  •  梦谈多话
    2021-02-04 20:46

    Angular material components are using themes https://material.angular.io/guide/theming

    Slider's background colors can be changed this way:

    @include mat-slider-theme(map_merge(mat-light-theme, (
        accent: mat-palette(map_merge($mat-deep-orange, (
            500: green,
        ))),
        foreground: (
            base: #848484,
            slider-min: white,
            slider-off: #bebebe,
            slider-off-active: #bebebe,
        ),
    )));
    

提交回复
热议问题