Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

minter: add success page && metadata #136

Merged
merged 11 commits into from
Feb 19, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix minter success page
  • Loading branch information
rubenmarcus committed Feb 19, 2024
commit a0db3aa05683ee327f52383a9257589a21a53ede
11 changes: 6 additions & 5 deletions minter/src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,27 +25,28 @@ export async function generateMetadata(): Promise<Metadata> {


let pageTitle = "Mintbase Minter Example";
let pageDescription = "Learn how to Mint NFTs on NEAR with Mintbase Minter Example"

// Check if signMeta exists in the URL
const signMeta = referer ? extractSignMeta(referer) : "";
if (signMeta) {
const signMetaData = JSON.parse(decodeURIComponent(signMeta));

pageTitle = `Success! You just minted: ${signMetaData?.args?.title}`;

pageDescription = `Just Minted ${signMetaData?.args?.title} on Mintbase`
// Now you can further process the extracted signMeta value
}

return {
metadataBase: new URL("https://minter.mintbase.xyz"),
title: pageTitle,
openGraph: {
title: "Mintbase Drop",
description: "Claim this drop for free with the Mintbase Wallet.",
title:pageTitle,
description: pageDescription,
},
twitter: {
title: "Mintbase Minter Example",
description: "Claim this drop for free with the Mintbase Wallet.",
title: pageTitle,
description: pageDescription,
siteId: "1467726470533754880",
creator: "Mintbase",
card: "summary_large_image",
Expand Down
Loading