mirror of https://github.com/nocodb/nocodb
1 changed files with 9 additions and 8 deletions
@ -1,23 +1,24 @@
|
||||
<script setup lang="ts"> |
||||
import Text from './Text.vue' |
||||
import { computed } from '#imports' |
||||
|
||||
interface Props { |
||||
modelValue: any |
||||
} |
||||
|
||||
const { modelValue: value } = defineProps<Props>() |
||||
interface Emits { |
||||
(event: 'update:modelValue', model: number): void |
||||
} |
||||
|
||||
const props = defineProps<Props>() |
||||
|
||||
const emits = defineEmits<Emits>() |
||||
|
||||
const emit = defineEmits(['update:modelValue']) |
||||
const vModel = useVModel(props, 'modelValue', emits) |
||||
|
||||
const VModal = computed({ |
||||
get: () => value, |
||||
set: (val) => emit('update:modelValue', val), |
||||
}) |
||||
</script> |
||||
|
||||
<template> |
||||
<Text v-model="VModal" /> |
||||
<Text v-model="vModel" /> |
||||
</template> |
||||
|
||||
<style scoped></style> |
||||
|
Loading…
Reference in new issue