{# v-on="$listeners" needed becaues vue/compat removes them from $attrs #}
{# New mt-text-field component #}
<mt-text-field
    v-if="useMeteorComponent"
    v-bind="$attrs"
    :model-value="compatValue"
    v-on="listeners"
    @update:modelValue="handleUpdateModelValue"
>
    <template
        v-for="(index, name) in getSlots()"
        #[name]="data"
    >
        <slot
            :name="name"
            v-bind="data"
        >
        </slot>
    </template>
    <slot></slot>
</mt-text-field>

{# v-on="$listeners" needed becaues vue/compat removes them from $attrs #}
{# Deprecated component #}
<sw-text-field-deprecated
    v-else
    v-bind="$attrs"
    :value="value"
    v-on="listeners"
>
    <template
        v-for="(index, name) in getSlots()"
        #[name]="data"
    >
        <slot
            :name="name"
            v-bind="data || {}"
        >
        </slot>
    </template>
</sw-text-field-deprecated>
