Standardize import paths across UI components to use ~/lib/utils alias instead of @/lib/utils for better consistency and maintainability.
21 lines
564 B
Vue
21 lines
564 B
Vue
<script lang="ts" setup>
|
|
import type { DialogOverlayProps } from 'radix-vue'
|
|
import type { HtmlHTMLAttributes } from 'vue'
|
|
import { DrawerOverlay } from 'vaul-vue'
|
|
import { computed } from 'vue'
|
|
import { cn } from '~/lib/utils'
|
|
|
|
|
|
const props = defineProps<DialogOverlayProps & { class?: HtmlHTMLAttributes['class'] }>()
|
|
|
|
const delegatedProps = computed(() => {
|
|
const { class: _, ...delegated } = props
|
|
|
|
return delegated
|
|
})
|
|
</script>
|
|
|
|
<template>
|
|
<DrawerOverlay v-bind="delegatedProps" :class="cn('fixed inset-0 z-50 bg-black/80', props.class)" />
|
|
</template>
|