'use client' import * as React from 'react' import { Drawer as DrawerPrimitive } from 'vaul' import { cn } from '../../utils' import { ButtonSet, type ButtonSetSize, type ButtonSetOrientation, } from '../Button/ButtonSet' import { typographyVariants } from '../Typography' type DrawerTriggerProps = React.ComponentPropsWithoutRef< typeof DrawerPrimitive.Trigger > type DrawerCloseProps = React.ComponentPropsWithoutRef< typeof DrawerPrimitive.Close > type DrawerOverlayProps = React.ComponentPropsWithoutRef< typeof DrawerPrimitive.Overlay > type DrawerContentProps = React.ComponentPropsWithoutRef< typeof DrawerPrimitive.Content > type DrawerTitleProps = React.ComponentPropsWithoutRef< typeof DrawerPrimitive.Title > type DrawerDescriptionProps = React.ComponentPropsWithoutRef< typeof DrawerPrimitive.Description > const Drawer = ({ shouldScaleBackground = true, ...props }: React.ComponentProps) => ( ) Drawer.displayName = 'Drawer' const DrawerTrigger: React.FC = (props) => ( ) DrawerTrigger.displayName = 'DrawerTrigger' const DrawerPortal = DrawerPrimitive.Portal const DrawerClose: React.FC = (props) => ( ) DrawerClose.displayName = 'DrawerClose' const DrawerOverlay: React.ForwardRefExoticComponent< DrawerOverlayProps & React.RefAttributes > = React.forwardRef( ({ className, ...props }, ref) => ( ), ) DrawerOverlay.displayName = 'DrawerOverlay' const DrawerHandle = React.forwardRef< React.ElementRef, React.ComponentPropsWithoutRef >(({ className, ...props }, ref) => ( )) DrawerHandle.displayName = 'DrawerHandle' const DrawerContent: React.ForwardRefExoticComponent< DrawerContentProps & React.RefAttributes > = React.forwardRef( ({ className, children, ...props }, ref) => ( {children} ), ) DrawerContent.displayName = 'DrawerContent' const DrawerHeader = ({ className, ...props }: React.HTMLAttributes) => (
) DrawerHeader.displayName = 'DrawerHeader' const DrawerFooter = ({ className, size, orientation, children, ...props }: React.HTMLAttributes & { size?: ButtonSetSize orientation?: ButtonSetOrientation }) => ( {children} ) DrawerFooter.displayName = 'DrawerFooter' const DrawerTitle: React.ForwardRefExoticComponent< DrawerTitleProps & React.RefAttributes > = React.forwardRef( ({ className, ...props }, ref) => ( ), ) DrawerTitle.displayName = 'DrawerTitle' const DrawerDescription: React.ForwardRefExoticComponent< DrawerDescriptionProps & React.RefAttributes > = React.forwardRef( ({ className, ...props }, ref) => ( ), ) DrawerDescription.displayName = 'DrawerDescription' export { Drawer, DrawerPortal, DrawerOverlay, DrawerTrigger, DrawerClose, DrawerContent, DrawerHeader, DrawerFooter, DrawerTitle, DrawerDescription, DrawerHandle, }