支持范围选择

This commit is contained in:
icssoa
2025-07-29 22:47:12 +08:00
parent 27bb7e36b1
commit 66759392a4
2 changed files with 159 additions and 101 deletions

View File

@@ -24,6 +24,14 @@
:track-height="isSize ? 12 : 8"
:step="isStep ? 10 : 1"
:max="isMax ? 50 : 100"
:pt="{
thumb: {
className: isColor ? '!bg-red-500' : ''
},
progress: {
className: isColor ? '!bg-red-200' : ''
}
}"
></cl-slider>
<cl-list
@@ -44,6 +52,10 @@
<cl-switch v-model="isSize"></cl-switch>
</cl-list-item>
<cl-list-item :label="t('换个颜色')">
<cl-switch v-model="isColor"></cl-switch>
</cl-list-item>
<cl-list-item :label="t('最大50')">
<cl-switch v-model="isMax"></cl-switch>
</cl-list-item>
@@ -70,4 +82,5 @@ const isShowValue = ref(true);
const isStep = ref(false);
const isSize = ref(false);
const isMax = ref(false);
const isColor = ref(false);
</script>