diff --git a/packages/nextjs/app/simpleMint/page.tsx b/packages/nextjs/app/simpleMint/page.tsx index 8857a83..81e0d7a 100644 --- a/packages/nextjs/app/simpleMint/page.tsx +++ b/packages/nextjs/app/simpleMint/page.tsx @@ -153,7 +153,7 @@ const SimpleMint: NextPage = () => {

Enter your NFT details here

- * are required fields + * required fields
@@ -256,47 +256,70 @@ const SimpleMint: NextPage = () => { {/* Flex container for media and text */}
{/* Media Section */} -
+ {/* Media Section */} +
{image ? ( - NFT Preview + NFT Preview ) : ( -
+
No image provided
)} - - {animationUrl && ( - - )}
{/* Text Section */}

- Collection Name: {collectionName || "Not provided"} + Collection Name:{" "} + {collectionName ? ( + {collectionName} + ) : ( + Not provided + )}

- Symbol: {collectionSymbol || "Not provided"} + Symbol:{" "} + {collectionSymbol ? ( + {collectionSymbol} + ) : ( + Not provided + )}

- Description: {description || "Not provided"} -

-

- Attributes: -

-
    - {attributes.length > 0 && attributes[0].traitType && attributes[0].value ? ( - attributes.map((attr, index) => ( -
  • - {attr.traitType ? `${attr.traitType}: ${attr.value}` : "No attributes provided"} -
  • - )) + Description:{" "} + {description ? ( + {description} ) : ( -
  • No attributes provided
  • + Not provided )} -
+

+ + {/* Conditionally render the attributes section only if there are valid attributes */} + {attributes.length > 0 && attributes.some(attr => attr.traitType && attr.value) && ( + <> +

+ Attributes: +

+
    + {attributes.map( + (attr, index) => + attr.traitType && + attr.value && ( +
  • + {attr.traitType}: {attr.value} +
  • + ), + )} +
+ + )} + + {/* Conditionally render a music player if there is an animationUrl */} + {animationUrl && ( + + )}