adminforth 2.17.0-next.16 → 2.17.0-next.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -53,9 +53,6 @@ const emit = defineEmits(['update:valueStart', 'update:valueEnd']);
|
|
|
53
53
|
const minFormatted = computed(() => Math.floor(<number>props.min));
|
|
54
54
|
const maxFormatted = computed(() => Math.ceil(<number>props.max));
|
|
55
55
|
|
|
56
|
-
const isChanged = computed(() => {
|
|
57
|
-
return start.value && start.value !== minFormatted.value || end.value && end.value !== maxFormatted.value;
|
|
58
|
-
});
|
|
59
56
|
|
|
60
57
|
const start = ref<string | number>(props.valueStart);
|
|
61
58
|
const end = ref<string | number>(props.valueEnd);
|
|
@@ -102,7 +99,15 @@ watch(end, () => {
|
|
|
102
99
|
})
|
|
103
100
|
|
|
104
101
|
watch([minFormatted,maxFormatted], () => {
|
|
105
|
-
|
|
102
|
+
if ( !start.value && end.value ) {
|
|
103
|
+
setSliderValues(minFormatted.value, end.value);
|
|
104
|
+
} else if ( start.value && !end.value ) {
|
|
105
|
+
setSliderValues(start.value, maxFormatted.value);
|
|
106
|
+
} else if ( !start.value && !end.value ) {
|
|
107
|
+
setSliderValues(minFormatted.value, maxFormatted.value);
|
|
108
|
+
} else {
|
|
109
|
+
setSliderValues(start.value, end.value);
|
|
110
|
+
}
|
|
106
111
|
})
|
|
107
112
|
|
|
108
113
|
function setSliderValues(start: any, end: any) {
|