From cb749c6d1692fef54c1bb99ae4bd4a1a65f03e20 Mon Sep 17 00:00:00 2001 From: naiba Date: Thu, 2 Oct 2025 15:26:31 +0800 Subject: [PATCH] fix: Cannot read properties of undefined (reading 'displayName') --- src/components/ui/alert-dialog.tsx | 2 +- src/components/ui/dialog.tsx | 4 ++-- src/components/ui/drawer.tsx | 4 ++-- src/components/xui/overlayless-sheet.tsx | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/components/ui/alert-dialog.tsx b/src/components/ui/alert-dialog.tsx index f22dbd4..1105492 100644 --- a/src/components/ui/alert-dialog.tsx +++ b/src/components/ui/alert-dialog.tsx @@ -65,7 +65,7 @@ const AlertDialogTitle = React.forwardRef< {...props} /> )) -AlertDialogTitle.displayName = AlertDialogPrimitive.Title.displayName +AlertDialogTitle.displayName = "AlertDialogTitle" const AlertDialogDescription = React.forwardRef< React.ComponentRef, diff --git a/src/components/ui/dialog.tsx b/src/components/ui/dialog.tsx index eb1782c..fec7731 100644 --- a/src/components/ui/dialog.tsx +++ b/src/components/ui/dialog.tsx @@ -76,7 +76,7 @@ const DialogTitle = React.forwardRef< {...props} /> )) -DialogTitle.displayName = DialogPrimitive.Title.displayName +DialogTitle.displayName = "DialogTitle" const DialogDescription = React.forwardRef< React.ComponentRef, @@ -88,7 +88,7 @@ const DialogDescription = React.forwardRef< {...props} /> )) -DialogDescription.displayName = DialogPrimitive.Description.displayName +DialogDescription.displayName = "DialogDescription" export { Dialog, diff --git a/src/components/ui/drawer.tsx b/src/components/ui/drawer.tsx index e412f5d..9c596b0 100644 --- a/src/components/ui/drawer.tsx +++ b/src/components/ui/drawer.tsx @@ -69,7 +69,7 @@ const DrawerTitle = React.forwardRef< {...props} /> )) -DrawerTitle.displayName = DrawerPrimitive.Title.displayName +DrawerTitle.displayName = "DrawerTitle" const DrawerDescription = React.forwardRef< React.ComponentRef, @@ -81,7 +81,7 @@ const DrawerDescription = React.forwardRef< {...props} /> )) -DrawerDescription.displayName = DrawerPrimitive.Description.displayName +DrawerDescription.displayName = "DrawerDescription" export { Drawer, diff --git a/src/components/xui/overlayless-sheet.tsx b/src/components/xui/overlayless-sheet.tsx index 4fe81ec..1c28a9e 100644 --- a/src/components/xui/overlayless-sheet.tsx +++ b/src/components/xui/overlayless-sheet.tsx @@ -83,7 +83,7 @@ const SheetTitle = React.forwardRef< {...props} /> )) -SheetTitle.displayName = SheetPrimitive.Title.displayName +SheetTitle.displayName = "SheetTitle" const SheetDescription = React.forwardRef< React.ComponentRef, @@ -95,7 +95,7 @@ const SheetDescription = React.forwardRef< {...props} /> )) -SheetDescription.displayName = SheetPrimitive.Description.displayName +SheetDescription.displayName = "SheetDescription" export { Sheet,