Skip to content

Commit

Permalink
fix: earnings tokenId (#1531)
Browse files Browse the repository at this point in the history
  • Loading branch information
alessey authored Oct 30, 2024
1 parent 79d846c commit b96b350
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 3 deletions.
4 changes: 2 additions & 2 deletions playground/nextjs-app-router/app/mint/MintComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ export default function MintComponent() {
<main className="flex w-full items-center justify-center">
<NFTMintCard
contractAddress="0x1D6b183bD47F914F9f1d3208EDCF8BefD7F84E63"
tokenId="2"
tokenId="3"
useNFTData={useEarningsData}
buildMintTransaction={buildMintTransaction}
onStatus={handleOnStatus}
>
<NFTCreator className="-mt-1 pt-0" />
<NFTMedia />
<NFTCollectionTitle />
<NFTMintButton />
<NFTMintButton className="[&_button]:bg-[#0052ff] [&_button]:hover:bg-[#014ceb] [&_button]:active:bg-[#0148dc] [&_button]:disabled:bg-[#80a8ff]" />
</NFTMintCard>
</main>
);
Expand Down
8 changes: 8 additions & 0 deletions playground/nextjs-app-router/components/DemoOptions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,20 @@ export default function DemoOptions({
</>
);
case OnchainKitComponent.NFTCard:
return (
<>
{commonOptions}
<Chain />
<NFTOptions />
</>
);
case OnchainKitComponent.NFTMintCard:
return (
<>
{commonOptions}
<Chain />
<PaymasterUrl />
<IsSponsored />
<NFTOptions />
</>
);
Expand Down
3 changes: 2 additions & 1 deletion playground/nextjs-app-router/components/demo/NFTMintCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import type { TransactionReceipt } from 'viem';
import { AppContext } from '../AppProvider';

function NFTMintCardDemo() {
const { nftToken } = useContext(AppContext);
const { nftToken, isSponsored } = useContext(AppContext);

const [contractAddress, tokenId] = (
nftToken ?? '0x1D6b183bD47F914F9f1d3208EDCF8BefD7F84E63:2'
Expand All @@ -47,6 +47,7 @@ function NFTMintCardDemo() {
tokenId={tokenId}
useNFTData={useReservoirMintData}
buildMintTransaction={buildMintTransaction}
isSponsored={isSponsored}
onStatus={handleOnStatus}
onSuccess={handleOnSuccess}
onError={handleOnError}
Expand Down
3 changes: 3 additions & 0 deletions playground/nextjs-app-router/lib/nft/testAddresses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,6 @@
// cb quarterly earnings 0x1D6b183bD47F914F9f1d3208EDCF8BefD7F84E63
// audio - 0x05a28e3d5f68c8b4a521ab7f74bd887fae6a598d base song
// ink base - 0xff93d3f49ec467B61BF61D42DDdCFDbA5c732446 ERC721
// yellow digital meltdown 0x19Ef6FdBddd2752fBA1B419cD43a1Fab5b0101Db ERC721
// base around the world 0xFE12c6d7555B4A94B352998f8e1E96aDFbE628e9 ERC721

0 comments on commit b96b350

Please sign in to comment.