34 lines
811 B
Vue
34 lines
811 B
Vue
<template>
|
|
<div class="flex items-center gap-2">
|
|
<span class="text-sm text-neutral-600">Mode:</span>
|
|
<UButtonGroup>
|
|
<UButton
|
|
:variant="modelValue === 'minimum' ? 'solid' : 'ghost'"
|
|
color="neutral"
|
|
size="xs"
|
|
@click="$emit('update:modelValue', 'minimum')">
|
|
Min Mode
|
|
</UButton>
|
|
<UButton
|
|
:variant="modelValue === 'target' ? 'solid' : 'ghost'"
|
|
color="primary"
|
|
size="xs"
|
|
@click="$emit('update:modelValue', 'target')">
|
|
Target Mode
|
|
</UButton>
|
|
</UButtonGroup>
|
|
</div>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
interface Props {
|
|
modelValue: "minimum" | "target";
|
|
}
|
|
|
|
interface Emits {
|
|
(e: "update:modelValue", value: "minimum" | "target"): void;
|
|
}
|
|
|
|
defineProps<Props>();
|
|
defineEmits<Emits>();
|
|
</script>
|