<script setup lang="ts">
import type { TagsInputItemTextProps } from 'reka-ui';
import type { HTMLAttributes } from 'vue';
import { TagsInputItemText, useForwardProps } from 'reka-ui';
import { computed } from 'vue';
import { cn, omitClass } from '@/lib/utils';

const props = defineProps<
  TagsInputItemTextProps & { class?: HTMLAttributes['class'] }
>();

const delegatedProps = computed(() => omitClass(props));

const forwardedProps = useForwardProps(delegatedProps);
</script>

<template>
  <TagsInputItemText
    data-slot="tags-input-item-text"
    :class="cn('px-1', props.class)"
    v-bind="forwardedProps"
  />
</template>
