From 7013620c9d13e91d8fd168633a45d266e09bd09d Mon Sep 17 00:00:00 2001 From: ian <152932566+ianthirdweb@users.noreply.github.com> Date: Mon, 18 Dec 2023 09:48:49 -0500 Subject: [PATCH] Follow up Quick Fixes (#1123) * Quick fix for Overview page * Remove thirdweb contracts from sidebar. * Add alt text to images on Embedded Elements pages --------- Co-authored-by: Ian Mukherjee --- .../22 NFT Checkouts/0 Overview.mdx | 5 +- .../1 CheckoutWithCard.mdx | 2 +- ...Link.mdx => 3 One-Time Checkout Links.mdx} | 2 +- .../5 Pre-Built Contracts.mdx | 2 +- .../5 Thirdweb Contracts.mdx | 91 ------------------- 5 files changed, 4 insertions(+), 98 deletions(-) rename docs/onboarding/22 NFT Checkouts/1b Advanced Guides/{3 One Time Checkout Link.mdx => 3 One-Time Checkout Links.mdx} (97%) delete mode 100644 docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Thirdweb Contracts.mdx diff --git a/docs/onboarding/22 NFT Checkouts/0 Overview.mdx b/docs/onboarding/22 NFT Checkouts/0 Overview.mdx index 545026783..ae480a364 100644 --- a/docs/onboarding/22 NFT Checkouts/0 Overview.mdx +++ b/docs/onboarding/22 NFT Checkouts/0 Overview.mdx @@ -42,10 +42,7 @@ Card and other fiat payments are accepted from all 50 US states and US-sanctione | Sepolia | ETH | | Zora Testnet | ETH | -<<<<<<< HEAD \* - ERC-20 payments are available for pro or enterprise customers only. -======= \* - ERC-20 tokens are available for pro or enterprise customers only. - -> > > > > > > main +\* - ERC-20 tokens are available for pro or enterprise customers only. ### Fraud prevention & chargeback protection diff --git a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/0 Embedded Elements/1 CheckoutWithCard.mdx b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/0 Embedded Elements/1 CheckoutWithCard.mdx index 3f813e446..d5194dbae 100644 --- a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/0 Embedded Elements/1 CheckoutWithCard.mdx +++ b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/0 Embedded Elements/1 CheckoutWithCard.mdx @@ -159,7 +159,7 @@ Here's an example component with the following props: } ``` -![](../../assets/checkout-with-card-customization-demo.png) +![CheckoutWithCard form customization demo](../../assets/checkout-with-card-customization-demo.png) ## Important Notes diff --git a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/3 One Time Checkout Link.mdx b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/3 One-Time Checkout Links.mdx similarity index 97% rename from docs/onboarding/22 NFT Checkouts/1b Advanced Guides/3 One Time Checkout Link.mdx rename to docs/onboarding/22 NFT Checkouts/1b Advanced Guides/3 One-Time Checkout Links.mdx index 1a74daf28..cb3a3c5ee 100644 --- a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/3 One Time Checkout Link.mdx +++ b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/3 One-Time Checkout Links.mdx @@ -1,6 +1,6 @@ --- slug: /checkouts/one-time-checkout-link -title: One-time Checkout Links +title: One-Time Checkout Links --- A one-time Checkout Link is a prebuilt checkout experience that is customized per buyer by providing a fixed price, email, wallet address, quantity, and more. diff --git a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Pre-Built Contracts.mdx b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Pre-Built Contracts.mdx index f47d500fe..7b50ca539 100644 --- a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Pre-Built Contracts.mdx +++ b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Pre-Built Contracts.mdx @@ -1,5 +1,5 @@ --- -slug: /checkouts/thirdweb-contracts +slug: /checkouts/pre-built-contracts title: Pre-Built Contracts --- diff --git a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Thirdweb Contracts.mdx b/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Thirdweb Contracts.mdx deleted file mode 100644 index 3727e6a86..000000000 --- a/docs/onboarding/22 NFT Checkouts/1b Advanced Guides/5 Thirdweb Contracts.mdx +++ /dev/null @@ -1,91 +0,0 @@ ---- -slug: /checkouts/thirdweb-contracts -title: thirdweb Contracts ---- - -## Integration - -For some thirdweb contracts, set `contractArgs` when creating [Shareable Checkout Links](/checkouts/checkout-link), [One-Time Checkout Links](/checkouts/one-time-checkout-link), or [Checkout Elements](/checkouts/elements). - -### Signature Drop - -This is an ERC-721A contract where the NFT metadata is unique but the claim configuration can be modified for each buyer by creating a _signature_ on your backend. If you don't plan to use signatures, you should consider using the [NFT Drop](https://portal.thirdweb.com/pre-built-contracts/nft-drop) contract. - -To customize the NFT metadata, allow dynamic pricing, or enforce an off-chain allowlist, generate a signature on your backend and set `contractArgs`: - -```typescript -const signatureDrop = thirdwebSdk.getContract('signature-drop'); - -// Generate a signature from a payload that provides some configuration override. -const payload = { - to: buyerWalletAddress, - price: "0.01", - mintStartTime: new Date(0), -}; -const signature = await signatureDrop.signature.generate(payload); - -// Set contractArgs with the payload and signature. -contractArgs = { - payload, - signature, -} -``` - -See guide: [Create an ERC721A NFT Drop with Signature-Based Minting](https://blog.thirdweb.com/guides/signature-drop/) - -### NFT Drop - -This is an ERC-721A contract where the NFT metadata is unique but the claim configuration is identical for all buyers. No `contractArgs` should be set. - -### Edition Drop - -This is an ERC-1155 contract where the NFT metadata and claim configuration is identical for all buyers. Set `contractArgs` with the token ID to mint: - -```typescript -contractArgs = { tokenId: "0" } -``` - -### Marketplace - -This is a contract that allows other users to purchase already-minted NFTs. Set `contractArgs` with an array of the marketplace listing IDs of each of the direct listing: - -```typescript -contractArgs = { - listings: [ - { listingId: "0" }, - { listingId: "1" }, - ... - ] -} -``` - -## Configure the Claim Condition - -Your thirdweb contract must have at least one active claim condition, meaning the **When will this phase start?** date is in the past. - -![Claim Condition Configuration Image](https://files.readme.io/994d683-image.png) - -Helpful tips for each field: - -| Field | Notes | -|-------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| **When will this phase start?** | thirdweb can only mint NFTs after this date. | -| **How many NFTs will you drop in this phase?** | Remember to create NFTs on the **NFTs** tab for NFT Drop contracts. | -| **How much do you want to charge to claim each NFT?** | For Mumbai, this price must be ≤ 0.0001 MATIC.
For Goerli, this price must be ≤ 0.0001 ETH.

On production, there is a $2,000 price limit. Please fill out [this Typeform](https://fw3786mcxwl.typeform.com/to/B0xIFoiu) to request an increase. | -| **What currency do you want to use?** | Supported currencies on thirdweb:
- Mumbai: MATIC
- Polygon: MATIC, USDC, WETH
- Goerli: ETH
- Ethereum: ETH, USDC | -| **Who can claim NFTs during this phase?** | If you have an allowlist, please add thirdweb's minter wallets.
Otherwise leave this blank. | -| **How many NFTs can be claimed per transaction?** | This value must be Unlimited. Otherwise thirdweb's minter wallets will not be able to mint more than this amount. | -| **How many seconds do wallets have to wait in-between claiming?** | This value must be 0. Otherwise thirdweb's minter wallets will fail when many mints occur at once. | - -## Debug common blockchain error responses - -| Error Message | Description | Solution | -|-------------------|----------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| `!Qty` | The buyer is attempting to purchase more than allowed per wallet. | **:warning: Your Claim Condition must allow thirdweb Wallets to mint an unlimited amount.**

The **How many NFTs can be claimed per transaction?** setting must be set to Unlimited. Alternatively, allow thirdweb's minter wallets to mint the full supply in a snapshot. | -| `!MaxSupply` | The buyer is attempting to purchase more than the available supply, or the drop is sold out. | Allow more NFTs to be sold, or prevent buyers from navigating to the checkout page if sold out. | -| `cant claim yet` | There is no claim phase, or the claim phase has not started. | Wait until the claim phase has started, or set one claim phase's start date to a past date. | -| `!PriceOrCurrency`| thirdweb sent the incorrect amount or currency to the contract. | thirdweb may be auto-detecting the price incorrectly. Please reach out on [Discord](https://discord.gg/thirdweb). | - -_Source: Drop.sol from thirdweb contracts_ - -If your transactions are failing for these reasons, please update the active **Claim Condition** on your thirdweb contract.