Files
Caramel-CRM/resources/js/components/ui/separator/Separator.vue
T

30 lines
773 B
Vue
Raw Normal View History

2025-10-20 08:57:51 +02:00
<script setup lang="ts">
2025-11-04 13:47:37 +01:00
import type { SeparatorProps } from "reka-ui"
import type { HTMLAttributes } from "vue"
import { reactiveOmit } from "@vueuse/core"
import { Separator } from "reka-ui"
import { cn } from "@/lib/utils"
2025-10-20 08:57:51 +02:00
const props = withDefaults(defineProps<
2025-11-04 13:47:37 +01:00
SeparatorProps & { class?: HTMLAttributes["class"] }
2025-10-20 08:57:51 +02:00
>(), {
2025-11-04 13:47:37 +01:00
orientation: "horizontal",
2025-10-20 08:57:51 +02:00
decorative: true,
})
2025-11-04 13:47:37 +01:00
const delegatedProps = reactiveOmit(props, "class")
2025-10-20 08:57:51 +02:00
</script>
<template>
<Separator
data-slot="separator-root"
v-bind="delegatedProps"
:class="
cn(
2025-11-04 13:47:37 +01:00
'bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',
2025-10-20 08:57:51 +02:00
props.class,
)
"
/>
</template>