From f66f5f41bdfed9e5d7223e8b4f1f7bf90423b9e1 Mon Sep 17 00:00:00 2001 From: dappsar Date: Mon, 23 Sep 2024 22:47:39 -0300 Subject: [PATCH 1/2] [fix] :adhesive_bandage: fix images not displayed (#95) --- src/sections/nfts/nft-item-claim.tsx | 6 +----- src/sections/nfts/nft-item.tsx | 2 +- src/types/wallet.ts | 2 +- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/src/sections/nfts/nft-item-claim.tsx b/src/sections/nfts/nft-item-claim.tsx index 26e03a4..94a5189 100644 --- a/src/sections/nfts/nft-item-claim.tsx +++ b/src/sections/nfts/nft-item-claim.tsx @@ -11,21 +11,17 @@ import { BOT_WAPP_URL, NFT_MARKETPLACE } from 'src/config-global' import { varFade } from 'src/components/animate' -import { INFTMetadata } from 'src/types/wallet' - // ---------------------------------------------------------------------- type NftItemClaimProps = { nftId: string - nftData: INFTMetadata + nftData: { image: string; description: string } } export default function NftItemClaim({ nftId, nftData }: NftItemClaimProps) { const mdUp = useResponsive('up', 'md') const { t } = useTranslate() - console.log('xxxxxxxxx', nftData) - const handleOpenOpenSea = () => { const url = `${NFT_MARKETPLACE.replace('ID', nftId)}` window.open(url, '_blank') diff --git a/src/sections/nfts/nft-item.tsx b/src/sections/nfts/nft-item.tsx index a163393..54c6144 100644 --- a/src/sections/nfts/nft-item.tsx +++ b/src/sections/nfts/nft-item.tsx @@ -71,7 +71,7 @@ export default function NftItem({ nft }: Props) { > Date: Mon, 23 Sep 2024 22:54:09 -0300 Subject: [PATCH 2/2] [fix :rotating_light: fix linter issues (#95) --- src/sections/nfts/view/nft-mint-view.tsx | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/sections/nfts/view/nft-mint-view.tsx b/src/sections/nfts/view/nft-mint-view.tsx index 83fbf17..c40194f 100644 --- a/src/sections/nfts/view/nft-mint-view.tsx +++ b/src/sections/nfts/view/nft-mint-view.tsx @@ -9,8 +9,6 @@ import EmptyContent from 'src/components/empty-content' import { useSettingsContext } from 'src/components/settings' import { LoadingScreen } from 'src/components/loading-screen' -import { INFTMetadata } from 'src/types/wallet' - import NftItemClaim from '../nft-item-claim' // ---------------------------------------------------------------------- @@ -22,10 +20,17 @@ export default function NftMintView({ nftId }: NftItemProps) { const { t } = useTranslate() const settings = useSettingsContext() - const { data: nftData, isLoading }: { data: INFTMetadata; isLoading: boolean } = - useGetNftById(nftId) + const { + data: nftData, + isLoading + }: { + data: { + image: string + description: string + } + isLoading: boolean + } = useGetNftById(nftId) - console.log('nftData', nftData) const notFound = !nftData const renderContent = (