<template>
	<v-card-text>
		<v-textarea
			:label="element.label"
			:placeholder="element.placeholder"
			:hint="element.hint"
			:color="element.color"
			:append-icon="element.append_icon"
			:prepend-icon="element.prepend_icon || 'fas fa-align-right' "
			v-model="values[element.slug]"
			@input="changeValue"
			:data-vv-name="element.slug"
			:data-vv-as="element.label"
			v-validate="element.validations"
			:error-messages="errors.collect(element.slug)"
		></v-textarea>
	</v-card-text>
</template>
<script>
export default {
	props: {
		element: {
			type: Object
		},
		values: {
			type: Object,
			default: () => ({})
		}
	},
	methods: {
		changeValue() {
			this.$emit('input', this.values);
		}
	}
};
</script>