From 9239b804875627a7bf02e7fbf4670640938106b0 Mon Sep 17 00:00:00 2001 From: Danish Arora Date: Tue, 5 Nov 2024 11:43:50 +0530 Subject: [PATCH] chore(buddybook): fix modal CSS --- .../Chain/Create/CreationPreview.tsx | 2 +- .../src/components/Chain/View/ChainList.tsx | 14 +++++++----- .../buddybook/src/components/ui/dialog.tsx | 22 +++++++++++-------- 3 files changed, 22 insertions(+), 16 deletions(-) diff --git a/examples/buddybook/src/components/Chain/Create/CreationPreview.tsx b/examples/buddybook/src/components/Chain/Create/CreationPreview.tsx index eb3bcc8..43604fb 100644 --- a/examples/buddybook/src/components/Chain/Create/CreationPreview.tsx +++ b/examples/buddybook/src/components/Chain/Create/CreationPreview.tsx @@ -165,7 +165,7 @@ const ChainCreationForm: React.FC = () => { - + {isSuccess ? "Chain Created" : "Chain Preview"} diff --git a/examples/buddybook/src/components/Chain/View/ChainList.tsx b/examples/buddybook/src/components/Chain/View/ChainList.tsx index a6abaed..2a0369b 100644 --- a/examples/buddybook/src/components/Chain/View/ChainList.tsx +++ b/examples/buddybook/src/components/Chain/View/ChainList.tsx @@ -42,7 +42,7 @@ const ChainList: React.FC = ({ chainsData, onChainUpdate, isLoad

{block.description}

- Created by: +

Created at: {new Date(block.timestamp).toLocaleString()} @@ -88,7 +88,9 @@ const ChainList: React.FC = ({ chainsData, onChainUpdate, isLoad ) : (

- +

+ +

)}
@@ -129,13 +131,13 @@ const ChainList: React.FC = ({ chainsData, onChainUpdate, isLoad ); }; -const SignerName: React.FC<{ address: `0x${string}` }> = ({ address }) => { +const SignerName: React.FC<{ address: `0x${string}`; prefix?: string }> = ({ address, prefix }) => { const { data: ensName } = useEnsName({ address }) return ( -

- Signed by: {ensName || `${address.slice(0, 6)}...${address.slice(-4)}`} -

+ + {prefix && `${prefix}: `}{ensName || `${address.slice(0, 6)}...${address.slice(-4)}`} + ); }; diff --git a/examples/buddybook/src/components/ui/dialog.tsx b/examples/buddybook/src/components/ui/dialog.tsx index 2943cdd..f2ca1ce 100644 --- a/examples/buddybook/src/components/ui/dialog.tsx +++ b/examples/buddybook/src/components/ui/dialog.tsx @@ -31,15 +31,19 @@ const DialogContent = React.forwardRef< React.ElementRef, React.ComponentPropsWithoutRef >(({ className, ...props }, ref) => ( - + + + + )) DialogContent.displayName = DialogPrimitive.Content.displayName