mirror of https://github.com/nocodb/nocodb
1 changed files with 9 additions and 8 deletions
@ -1,23 +1,24 @@ |
|||||||
<script setup lang="ts"> |
<script setup lang="ts"> |
||||||
import Text from './Text.vue' |
import Text from './Text.vue' |
||||||
import { computed } from '#imports' |
|
||||||
|
|
||||||
interface Props { |
interface Props { |
||||||
modelValue: any |
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> |
</script> |
||||||
|
|
||||||
<template> |
<template> |
||||||
<Text v-model="VModal" /> |
<Text v-model="vModel" /> |
||||||
</template> |
</template> |
||||||
|
|
||||||
<style scoped></style> |
<style scoped></style> |
||||||
|
Loading…
Reference in new issue