<template>
    <div class="flex">
        <WarningIcon
            v-if="showWarningIcon"
            class="w-6 h-6 mr-3 shrink-0" />
        <p class="text-red italic text-sm mt-0.5">
            {{ text }}
        </p>
    </div>
</template>

<script>
export default {
    name: 'ErrorText',
    props: {
        showWarningIcon: {
            type: Boolean,
            default: false
        },
        text: {
            type: String,
            default: ''
        }
    }
}
</script>