Duration now matches CFG as one wheel; tap the digits to type a length. Touch drags move at a quarter of the desktop rate. Co-authored-by: Cursor <cursoragent@cursor.com>
34 lines
589 B
Vue
34 lines
589 B
Vue
<template>
|
|
<div>
|
|
<Thumbwheel
|
|
v-model="model"
|
|
:label="label || 'Duration'"
|
|
lock-key="duration"
|
|
:min="MIN"
|
|
:max="MAX"
|
|
:step="0.1"
|
|
:fine-step="0.1"
|
|
:coarse-step="1"
|
|
:drag-range="29"
|
|
editable
|
|
unit="s"
|
|
/>
|
|
<p v-if="hint" class="mt-1 text-[11px] text-zinc-500">{{ hint }}</p>
|
|
</div>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
const MIN = 0.5
|
|
const MAX = 120
|
|
|
|
withDefaults(defineProps<{
|
|
label?: string
|
|
hint?: string
|
|
}>(), {
|
|
label: '',
|
|
hint: ''
|
|
})
|
|
|
|
const model = defineModel<number>({ required: true })
|
|
</script>
|