Closed ft115637850 closed 4 years ago
you can use a function to bind to [format-tooltip], which will return an anonymous function with a parameter to calculate your step. like this:
<el-slider [min]="1" [max]="9" [model]="data" [format-tooltip]="sliderFormat()"></el-slider>
sliderFormat() {
return function (val) {
return (val * 10).toString();
}
}
This will achieve the ten-step with one slide.
It is a bug, element ui always take this property as a String, but only Number is accepted.
Issue Type:
Description: I want to set step for el-slider. How can I do this ?