mirror of
https://github.com/LukeHagar/better-auth.git
synced 2025-12-07 04:19:22 +00:00
32 lines
787 B
Vue
32 lines
787 B
Vue
<script lang="ts" setup>
|
|
import { type HTMLAttributes, computed } from 'vue'
|
|
import type { StepperSeparatorProps } from 'radix-vue'
|
|
import { StepperSeparator, useForwardProps } from 'radix-vue'
|
|
|
|
import { cn } from '@/lib/utils'
|
|
|
|
const props = defineProps<StepperSeparatorProps & { class?: HTMLAttributes['class'] }>()
|
|
|
|
const delegatedProps = computed(() => {
|
|
const { class: _, ...delegated } = props
|
|
|
|
return delegated
|
|
})
|
|
|
|
const forwarded = useForwardProps(delegatedProps)
|
|
</script>
|
|
|
|
<template>
|
|
<StepperSeparator
|
|
v-bind="forwarded"
|
|
:class="cn(
|
|
'bg-muted',
|
|
// Disabled
|
|
'group-data-[disabled]:bg-muted group-data-[disabled]:opacity-50',
|
|
// Completed
|
|
'group-data-[state=completed]:bg-accent-foreground',
|
|
props.class,
|
|
)"
|
|
/>
|
|
</template>
|