格式化
This commit is contained in:
@@ -17,7 +17,7 @@ export interface StandardProps {
|
||||
min?: number;
|
||||
max?: number;
|
||||
showDots?: boolean;
|
||||
backgroundColor:string;
|
||||
backgroundColor: string;
|
||||
}
|
||||
|
||||
const props = withDefaults(defineProps<StandardProps>(), {
|
||||
@@ -27,7 +27,7 @@ const props = withDefaults(defineProps<StandardProps>(), {
|
||||
min: 0,
|
||||
max: 100,
|
||||
showDots: false,
|
||||
backgroundColor:"#ccc"
|
||||
backgroundColor: "#ccc",
|
||||
});
|
||||
|
||||
const moveAction = throttle(standardMove);
|
||||
@@ -119,9 +119,12 @@ const focusDot = (val: number) => {
|
||||
class="layui-slider-rate-v"
|
||||
:class="[disabled ? 'layui-slider-disabled disable-line' : '']"
|
||||
></div>
|
||||
<div class="layui-slider-line-v" :style="{
|
||||
backgroundColor:props.backgroundColor
|
||||
}"></div>
|
||||
<div
|
||||
class="layui-slider-line-v"
|
||||
:style="{
|
||||
backgroundColor: props.backgroundColor,
|
||||
}"
|
||||
></div>
|
||||
<div
|
||||
v-show="showDots"
|
||||
@click="focusDot(item)"
|
||||
|
||||
@@ -22,7 +22,7 @@ export interface SliderProps {
|
||||
range?: boolean;
|
||||
rangeValue?: number[];
|
||||
showDots?: boolean;
|
||||
backgroundColor:string;
|
||||
backgroundColor: string;
|
||||
}
|
||||
|
||||
const emit = defineEmits(["update:modelValue"]);
|
||||
@@ -35,7 +35,7 @@ const props = withDefaults(defineProps<SliderProps>(), {
|
||||
min: 0,
|
||||
max: 100,
|
||||
showDots: false,
|
||||
backgroundColor:"#ccc"
|
||||
backgroundColor: "#ccc",
|
||||
});
|
||||
|
||||
let rangeValues: Ref<number[]> | any = toRef(props, "rangeValue");
|
||||
|
||||
Reference in New Issue
Block a user