|
@@ -1,47 +0,0 @@
|
|
|
-<template>
|
|
|
- <div :style="{ width: item.width ? item.width + 'px' : '100%' }">
|
|
|
- <v-textarea
|
|
|
- v-model="value"
|
|
|
- variant="outlined"
|
|
|
- :counter="item.counter || 200"
|
|
|
- color="primary"
|
|
|
- :validate-on="item.validateOn || 'input'"
|
|
|
- :rules="item.rules"
|
|
|
- :disabled="item.disabled"
|
|
|
- :style="{width: item.width}"
|
|
|
- :label="item.label"
|
|
|
- :placeholder="item.placeholder || item.label"
|
|
|
- :autofocus="item.autofocus"
|
|
|
- :required="item.required"
|
|
|
- :class="item.class"
|
|
|
- :suffix="item.suffix"
|
|
|
- :append-inner-icon="item.appendInnerIcon"
|
|
|
- :clearable="item.clearable"
|
|
|
- :readonly="item.readonly"
|
|
|
- :prepend-inner-icon="item.prependInnerIcon"
|
|
|
- hide-spin-buttons
|
|
|
- :hide-details="item.hideDetails || false"
|
|
|
- @update:modelValue="modelValueUpDate"
|
|
|
- ></v-textarea>
|
|
|
- </div>
|
|
|
-</template>
|
|
|
-<script setup>
|
|
|
-import { defineEmits, ref, watch } from 'vue';
|
|
|
-defineOptions({ name:'FormUI-v-textarea'})
|
|
|
-
|
|
|
-const props = defineProps({item: Object, modelValue: String})
|
|
|
-const emit = defineEmits(['update:modelValue'])
|
|
|
-const item = props.item
|
|
|
-const value = ref(props.modelValue)
|
|
|
-
|
|
|
-watch(() => props.modelValue, (newVal) => {
|
|
|
- value.value = newVal
|
|
|
-})
|
|
|
-const modelValueUpDate = (val) => {
|
|
|
- value.value = val
|
|
|
- emit('update:modelValue', value.value)
|
|
|
-}
|
|
|
-</script>
|
|
|
-<style lang="scss" scoped>
|
|
|
-
|
|
|
-</style>
|