From 58d8eee4a9777427ee1488bc236d3248313ffeb8 Mon Sep 17 00:00:00 2001 From: NidhiKJha Date: Wed, 26 Jul 2023 20:27:30 +0530 Subject: [PATCH] added placeholder valur --- ui/components/app/nft-details/nft-details.js | 2 ++ ui/components/app/nfts-items/nfts-items.js | 2 ++ ui/components/multichain/nft-item/nft-item.js | 4 +++- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ui/components/app/nft-details/nft-details.js b/ui/components/app/nft-details/nft-details.js index c0a9cbd33855..d80cc8f2d3d6 100644 --- a/ui/components/app/nft-details/nft-details.js +++ b/ui/components/app/nft-details/nft-details.js @@ -88,6 +88,7 @@ export default function NftDetails({ nft }) { const nftImageAlt = getNftImageAlt(nft); const nftImageURL = getAssetImageURL(imageOriginal ?? image, ipfsGateway); const isDataURI = nftImageURL.startsWith('data:'); + const showNftDefaultImage = image === nftImageURL; const formattedTimestamp = formatDate( new Date(lastSale?.event_timestamp).getTime(), @@ -193,6 +194,7 @@ export default function NftDetails({ nft }) { tokenId={tokenId} networkName={currentChain.nickname} networkSrc={currentChain.rpcPrefs?.imageUrl} + showNftDefaultImage={showNftDefaultImage} /> history.push(`${ASSET_ROUTE}/${address}/${tokenId}`); return ( @@ -190,6 +191,7 @@ export default function NftsItems({ networkSrc={currentChain.rpcPrefs?.imageUrl} onClick={handleImageClick} clickable + showNftDefaultImage={showNftDefaultImage} /> ); diff --git a/ui/components/multichain/nft-item/nft-item.js b/ui/components/multichain/nft-item/nft-item.js index 9bc86526f0a9..9815a0488d70 100644 --- a/ui/components/multichain/nft-item/nft-item.js +++ b/ui/components/multichain/nft-item/nft-item.js @@ -25,6 +25,7 @@ export const NftItem = ({ networkSrc, tokenId, onClick, + showNftDefaultImage, clickable = false, }) => { const testNetworkBackgroundColor = useSelector(getTestNetworkBackgroundColor); @@ -58,7 +59,7 @@ export const NftItem = ({ /> } > - {src ? ( + {showNftDefaultImage ? (