import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core'; @Component({ selector: 'cm-slider-doc-6', templateUrl: './slider-doc-6.component.html', styleUrls: ['./slider-doc-6.component.css'] }) export class SliderDoc6Component implements OnInit { sw: boolean = false; marks: any = { 0: '0°C', 26: '26°C', 37: '37°C', 100: { style: { color: '#f50', }, label: '100°C', } }; changeMarks() { if(!this.sw) { this.sw = true; this.marks = { 20: '20%', 99: '99%', } } else { this.sw = false; this.marks= { 0: '0°C', 26: '26°C', 37: '37°C', 100: { style: { color: '#f50', }, label: '100°C', } }; } } constructor() { } ngOnInit() {} }