mirror of
https://github.com/keven1024/015.git
synced 2026-06-03 10:59:35 +00:00
25 lines
600 B
Vue
25 lines
600 B
Vue
<script lang="ts" setup>
|
|
import type { DrawerTitleProps } from 'vaul-vue'
|
|
import { cn } from '@/lib/utils'
|
|
import { DrawerTitle } from 'vaul-vue'
|
|
import { computed, type HtmlHTMLAttributes } from 'vue'
|
|
|
|
const props = defineProps<DrawerTitleProps & { class?: HtmlHTMLAttributes['class'] }>()
|
|
|
|
const delegatedProps = computed(() => {
|
|
const { class: _, ...delegated } = props
|
|
|
|
return delegated
|
|
})
|
|
</script>
|
|
|
|
<template>
|
|
<DrawerTitle
|
|
data-slot="drawer-title"
|
|
v-bind="delegatedProps"
|
|
:class="cn('text-foreground font-semibold', props.class)"
|
|
>
|
|
<slot />
|
|
</DrawerTitle>
|
|
</template>
|