From cbb15692a7151c7ccb2878be294f54cef45b536e Mon Sep 17 00:00:00 2001
From: MananTank
Date: Mon, 31 Mar 2025 19:37:09 +0000
Subject: [PATCH] [TOOL-3880] Playground: Add utm_source on links (#6597)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## PR-Codex overview
This PR primarily updates various `docsLink` URLs across multiple components in the `playground-web` application to include a query parameter (`?utm_source=playground`). This change likely aims to track traffic sources more effectively.
### Detailed summary
- Updated `docsLink` in `apps/playground-web/src/app/connect/auth/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/pay/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/blockchain-api/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/pay/commerce/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/pay/fund-wallet/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/pay/transactions/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/sign-in/embed/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/sign-in/button/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/ui/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/sign-in/headless/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/in-app-wallet/layout.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/insight/layout.tsx`
- Updated `docsLink` in `apps/playground-web/src/components/blocks/APIHeader.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/pay/backend/layout.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/account-abstraction/connect/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/account-abstraction/sponsor/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/ui/nft/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/otherLinks.ts`
- Updated `docsLink` in `apps/playground-web/src/app/connect/account-abstraction/native-aa/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/ui/chain/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/ui/token/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/social/page.tsx`
- Updated `docsLink` in `apps/playground-web/src/app/connect/ui/wallet/page.tsx`
- Updated `href` in `apps/playground-web/src/app/connect/pay/embed/LeftSection.tsx`
- Updated `href` in `apps/playground-web/src/app/insight/page.tsx`
- Updated `href` in `apps/playground-web/src/components/auth/gated-content.tsx`
- Updated `href` in `apps/playground-web/src/components/engine/minting/erc1155-mint-to.tsx`
- Updated `href` in `apps/playground-web/src/app/connect/sign-in/components/InAppWalletFormGroup.tsx`
- Updated `href` in `apps/playground-web/src/app/connect/sign-in/button/LeftSection.tsx`
> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`
---
.../src/app/connect/account-abstraction/connect/page.tsx | 2 +-
.../src/app/connect/account-abstraction/native-aa/page.tsx | 2 +-
.../src/app/connect/account-abstraction/sponsor/page.tsx | 2 +-
apps/playground-web/src/app/connect/auth/page.tsx | 2 +-
apps/playground-web/src/app/connect/blockchain-api/page.tsx | 2 +-
apps/playground-web/src/app/connect/in-app-wallet/layout.tsx | 2 +-
apps/playground-web/src/app/connect/pay/backend/layout.tsx | 2 +-
apps/playground-web/src/app/connect/pay/commerce/page.tsx | 2 +-
.../playground-web/src/app/connect/pay/embed/LeftSection.tsx | 2 +-
apps/playground-web/src/app/connect/pay/fund-wallet/page.tsx | 2 +-
apps/playground-web/src/app/connect/pay/page.tsx | 2 +-
.../playground-web/src/app/connect/pay/transactions/page.tsx | 2 +-
.../src/app/connect/sign-in/button/LeftSection.tsx | 4 ++--
apps/playground-web/src/app/connect/sign-in/button/page.tsx | 2 +-
.../app/connect/sign-in/components/InAppWalletFormGroup.tsx | 2 +-
apps/playground-web/src/app/connect/sign-in/embed/page.tsx | 2 +-
.../playground-web/src/app/connect/sign-in/headless/page.tsx | 2 +-
apps/playground-web/src/app/connect/social/page.tsx | 2 +-
apps/playground-web/src/app/connect/ui/chain/page.tsx | 2 +-
apps/playground-web/src/app/connect/ui/nft/page.tsx | 2 +-
apps/playground-web/src/app/connect/ui/page.tsx | 2 +-
apps/playground-web/src/app/connect/ui/token/page.tsx | 2 +-
apps/playground-web/src/app/connect/ui/wallet/page.tsx | 2 +-
apps/playground-web/src/app/insight/layout.tsx | 2 +-
apps/playground-web/src/app/insight/page.tsx | 2 +-
apps/playground-web/src/app/otherLinks.ts | 4 ++--
apps/playground-web/src/components/auth/gated-content.tsx | 2 +-
apps/playground-web/src/components/blocks/APIHeader.tsx | 5 ++++-
.../src/components/engine/minting/erc1155-mint-to.tsx | 2 +-
29 files changed, 34 insertions(+), 31 deletions(-)
diff --git a/apps/playground-web/src/app/connect/account-abstraction/connect/page.tsx b/apps/playground-web/src/app/connect/account-abstraction/connect/page.tsx
index 13847c5cc9f..56d00013f4c 100644
--- a/apps/playground-web/src/app/connect/account-abstraction/connect/page.tsx
+++ b/apps/playground-web/src/app/connect/account-abstraction/connect/page.tsx
@@ -28,7 +28,7 @@ export default function Page() {
full wallet programmability.
>
}
- docsLink="https://portal.thirdweb.com/connect/account-abstraction/overview"
+ docsLink="https://portal.thirdweb.com/connect/account-abstraction/overview?utm_source=playground"
heroLink="/account-abstraction.png"
/>
diff --git a/apps/playground-web/src/app/connect/account-abstraction/native-aa/page.tsx b/apps/playground-web/src/app/connect/account-abstraction/native-aa/page.tsx
index 7d11de26c25..e558b5de621 100644
--- a/apps/playground-web/src/app/connect/account-abstraction/native-aa/page.tsx
+++ b/apps/playground-web/src/app/connect/account-abstraction/native-aa/page.tsx
@@ -25,7 +25,7 @@ export default function Page() {
full wallet programmability.
>
}
- docsLink="https://portal.thirdweb.com/connect/account-abstraction/overview"
+ docsLink="https://portal.thirdweb.com/connect/account-abstraction/overview?utm_source=playground"
heroLink="/account-abstraction.png"
/>
diff --git a/apps/playground-web/src/app/connect/account-abstraction/sponsor/page.tsx b/apps/playground-web/src/app/connect/account-abstraction/sponsor/page.tsx
index ec0ff9afcb1..373e2982ffd 100644
--- a/apps/playground-web/src/app/connect/account-abstraction/sponsor/page.tsx
+++ b/apps/playground-web/src/app/connect/account-abstraction/sponsor/page.tsx
@@ -25,7 +25,7 @@ export default function Page() {
full wallet programmability.
>
}
- docsLink="https://portal.thirdweb.com/connect/account-abstraction/overview"
+ docsLink="https://portal.thirdweb.com/connect/account-abstraction/overview?utm_source=playground"
heroLink="/account-abstraction.png"
/>
diff --git a/apps/playground-web/src/app/connect/auth/page.tsx b/apps/playground-web/src/app/connect/auth/page.tsx
index 975ff1349bb..65eb7b51689 100644
--- a/apps/playground-web/src/app/connect/auth/page.tsx
+++ b/apps/playground-web/src/app/connect/auth/page.tsx
@@ -28,7 +28,7 @@ export default function Page() {
them to create an additional account.
>
}
- docsLink="https://portal.thirdweb.com/typescript/v5/auth"
+ docsLink="https://portal.thirdweb.com/typescript/v5/auth?utm_source=playground"
heroLink="/auth.png"
/>
diff --git a/apps/playground-web/src/app/connect/blockchain-api/page.tsx b/apps/playground-web/src/app/connect/blockchain-api/page.tsx
index 7aa75121d9d..bdec25701c2 100644
--- a/apps/playground-web/src/app/connect/blockchain-api/page.tsx
+++ b/apps/playground-web/src/app/connect/blockchain-api/page.tsx
@@ -28,7 +28,7 @@ export default function Page() {
contract on any EVM chain through our RPC Edge endpoints.
>
}
- docsLink="https://portal.thirdweb.com/typescript/v5"
+ docsLink="https://portal.thirdweb.com/typescript/v5?utm_source=playground"
heroLink="/blockchain-api.png"
/>
diff --git a/apps/playground-web/src/app/connect/in-app-wallet/layout.tsx b/apps/playground-web/src/app/connect/in-app-wallet/layout.tsx
index c8771f4e575..a387f2747db 100644
--- a/apps/playground-web/src/app/connect/in-app-wallet/layout.tsx
+++ b/apps/playground-web/src/app/connect/in-app-wallet/layout.tsx
@@ -20,7 +20,7 @@ export default function Page(props: { children: React.ReactNode }) {
and smart account integration.
>
}
- docsLink="https://portal.thirdweb.com/connect/in-app-wallet/overview"
+ docsLink="https://portal.thirdweb.com/connect/in-app-wallet/overview?utm_source=playground"
heroLink="/in-app-wallet.png"
/>
diff --git a/apps/playground-web/src/app/connect/pay/backend/layout.tsx b/apps/playground-web/src/app/connect/pay/backend/layout.tsx
index 0b0c4052825..b3c1e518e8e 100644
--- a/apps/playground-web/src/app/connect/pay/backend/layout.tsx
+++ b/apps/playground-web/src/app/connect/pay/backend/layout.tsx
@@ -11,7 +11,7 @@ export default function Layout(props: {
description={
<>HTTP API to bridge, swap and onramp to and from any currency>
}
- docsLink="https://portal.thirdweb.com/connect/pay/overview"
+ docsLink="https://portal.thirdweb.com/connect/pay/overview?utm_source=playground"
heroLink="/ub.png"
/>
diff --git a/apps/playground-web/src/app/connect/pay/commerce/page.tsx b/apps/playground-web/src/app/connect/pay/commerce/page.tsx
index 3f62acd9b6b..03b8ce45086 100644
--- a/apps/playground-web/src/app/connect/pay/commerce/page.tsx
+++ b/apps/playground-web/src/app/connect/pay/commerce/page.tsx
@@ -24,7 +24,7 @@ export default function Page() {
chain.
>
}
- docsLink="https://portal.thirdweb.com/connect/pay/get-started"
+ docsLink="https://portal.thirdweb.com/connect/pay/get-started?utm_source=playground"
heroLink="/pay.png"
/>
diff --git a/apps/playground-web/src/app/connect/pay/embed/LeftSection.tsx b/apps/playground-web/src/app/connect/pay/embed/LeftSection.tsx
index 0c65afe20a3..51f0f46cb62 100644
--- a/apps/playground-web/src/app/connect/pay/embed/LeftSection.tsx
+++ b/apps/playground-web/src/app/connect/pay/embed/LeftSection.tsx
@@ -529,7 +529,7 @@ export function LeftSection(props: {
diff --git a/apps/playground-web/src/app/connect/pay/fund-wallet/page.tsx b/apps/playground-web/src/app/connect/pay/fund-wallet/page.tsx
index 9478d7a8f33..d08fe37a517 100644
--- a/apps/playground-web/src/app/connect/pay/fund-wallet/page.tsx
+++ b/apps/playground-web/src/app/connect/pay/fund-wallet/page.tsx
@@ -24,7 +24,7 @@ export default function Page() {
and generate revenue for each user transaction.
>
}
- docsLink="https://portal.thirdweb.com/connect/pay/get-started"
+ docsLink="https://portal.thirdweb.com/connect/pay/get-started?utm_source=playground"
heroLink="/pay.png"
/>
diff --git a/apps/playground-web/src/app/connect/pay/page.tsx b/apps/playground-web/src/app/connect/pay/page.tsx
index 27a57696618..d4a12b1746c 100644
--- a/apps/playground-web/src/app/connect/pay/page.tsx
+++ b/apps/playground-web/src/app/connect/pay/page.tsx
@@ -26,7 +26,7 @@ export default function Page(props: {
and generate revenue for each user transaction.
>
}
- docsLink="https://portal.thirdweb.com/connect/pay/get-started"
+ docsLink="https://portal.thirdweb.com/connect/pay/get-started?utm_source=playground"
heroLink="/pay.png"
/>
diff --git a/apps/playground-web/src/app/connect/pay/transactions/page.tsx b/apps/playground-web/src/app/connect/pay/transactions/page.tsx
index 00db4054ae7..04197921b55 100644
--- a/apps/playground-web/src/app/connect/pay/transactions/page.tsx
+++ b/apps/playground-web/src/app/connect/pay/transactions/page.tsx
@@ -27,7 +27,7 @@ export default function Page() {
any chain.
>
}
- docsLink="https://portal.thirdweb.com/connect/pay/get-started"
+ docsLink="https://portal.thirdweb.com/connect/pay/get-started?utm_source=playground"
heroLink="/pay.png"
/>
diff --git a/apps/playground-web/src/app/connect/sign-in/button/LeftSection.tsx b/apps/playground-web/src/app/connect/sign-in/button/LeftSection.tsx
index 38bcdc9ce82..507f2ffbe5c 100644
--- a/apps/playground-web/src/app/connect/sign-in/button/LeftSection.tsx
+++ b/apps/playground-web/src/app/connect/sign-in/button/LeftSection.tsx
@@ -219,7 +219,7 @@ export function LeftSection(props: {
after connecting wallet
@@ -248,7 +248,7 @@ export function LeftSection(props: {
diff --git a/apps/playground-web/src/app/connect/sign-in/button/page.tsx b/apps/playground-web/src/app/connect/sign-in/button/page.tsx
index c51a74c0d53..5dbd63bde2c 100644
--- a/apps/playground-web/src/app/connect/sign-in/button/page.tsx
+++ b/apps/playground-web/src/app/connect/sign-in/button/page.tsx
@@ -71,7 +71,7 @@ export default function Page(props: {
Ethereum)
>
}
- docsLink="https://portal.thirdweb.com/connect/sign-in/overview"
+ docsLink="https://portal.thirdweb.com/connect/sign-in/overview?utm_source=playground"
heroLink="/connectors.png"
/>
diff --git a/apps/playground-web/src/app/connect/sign-in/components/InAppWalletFormGroup.tsx b/apps/playground-web/src/app/connect/sign-in/components/InAppWalletFormGroup.tsx
index 727ac25f19a..fcf5046d439 100644
--- a/apps/playground-web/src/app/connect/sign-in/components/InAppWalletFormGroup.tsx
+++ b/apps/playground-web/src/app/connect/sign-in/components/InAppWalletFormGroup.tsx
@@ -39,7 +39,7 @@ export function InAppWalletFormGroup(props: {
In-App Wallet
diff --git a/apps/playground-web/src/app/connect/sign-in/embed/page.tsx b/apps/playground-web/src/app/connect/sign-in/embed/page.tsx
index cbcc70c56cc..28c94bd22bc 100644
--- a/apps/playground-web/src/app/connect/sign-in/embed/page.tsx
+++ b/apps/playground-web/src/app/connect/sign-in/embed/page.tsx
@@ -25,7 +25,7 @@ export default function Page() {
that fits your brand.
>
}
- docsLink="https://portal.thirdweb.com/connect/sign-in/overview"
+ docsLink="https://portal.thirdweb.com/connect/sign-in/overview?utm_source=playground"
heroLink="/connectors.png"
/>
diff --git a/apps/playground-web/src/app/connect/sign-in/headless/page.tsx b/apps/playground-web/src/app/connect/sign-in/headless/page.tsx
index e7c45eca6e9..78cc1ee708f 100644
--- a/apps/playground-web/src/app/connect/sign-in/headless/page.tsx
+++ b/apps/playground-web/src/app/connect/sign-in/headless/page.tsx
@@ -26,7 +26,7 @@ export default function Page() {
that fits your brand.
>
}
- docsLink="https://portal.thirdweb.com/connect/sign-in/overview"
+ docsLink="https://portal.thirdweb.com/connect/sign-in/overview?utm_source=playground"
heroLink="/connectors.png"
/>
diff --git a/apps/playground-web/src/app/connect/social/page.tsx b/apps/playground-web/src/app/connect/social/page.tsx
index 3a7df544e0c..2c8f07fcf23 100644
--- a/apps/playground-web/src/app/connect/social/page.tsx
+++ b/apps/playground-web/src/app/connect/social/page.tsx
@@ -24,7 +24,7 @@ export default function Page() {
as soon as they sign into your app.
>
}
- docsLink="https://portal.thirdweb.com/connect" // TODO: update this once we have Social API docs
+ docsLink="https://portal.thirdweb.com/connect?utm_source=playground" // TODO: update this once we have Social API docs
heroLink="/in-app-wallet.png"
/>
diff --git a/apps/playground-web/src/app/connect/ui/chain/page.tsx b/apps/playground-web/src/app/connect/ui/chain/page.tsx
index 1956ff07554..7cf55d15d6e 100644
--- a/apps/playground-web/src/app/connect/ui/chain/page.tsx
+++ b/apps/playground-web/src/app/connect/ui/chain/page.tsx
@@ -29,7 +29,7 @@ export default function Page() {
in their user interfaces.
>
}
- docsLink="https://portal.thirdweb.com/react/v5/components/onchain#chains"
+ docsLink="https://portal.thirdweb.com/react/v5/components/onchain#chains?utm_source=playground"
heroLink="/headless-ui-header.png"
/>
diff --git a/apps/playground-web/src/app/connect/ui/nft/page.tsx b/apps/playground-web/src/app/connect/ui/nft/page.tsx
index 461f67c530b..544dc2c1a01 100644
--- a/apps/playground-web/src/app/connect/ui/nft/page.tsx
+++ b/apps/playground-web/src/app/connect/ui/nft/page.tsx
@@ -32,7 +32,7 @@ export default function Page() {
their perfect user interface.
>
}
- docsLink="https://portal.thirdweb.com/react/v5/components/onchain#nfts"
+ docsLink="https://portal.thirdweb.com/react/v5/components/onchain#nfts?utm_source=playground"
heroLink="/headless-ui-header.png"
/>
diff --git a/apps/playground-web/src/app/connect/ui/page.tsx b/apps/playground-web/src/app/connect/ui/page.tsx
index 2b522a17162..961d1928617 100644
--- a/apps/playground-web/src/app/connect/ui/page.tsx
+++ b/apps/playground-web/src/app/connect/ui/page.tsx
@@ -37,7 +37,7 @@ export default function Page() {
complete control over your dApp's design.
>
}
- docsLink="https://portal.thirdweb.com/react/v5/components/account"
+ docsLink="https://portal.thirdweb.com/react/v5/components/account?utm_source=playground"
heroLink="/headless-ui-header.png"
/>
diff --git a/apps/playground-web/src/app/connect/ui/token/page.tsx b/apps/playground-web/src/app/connect/ui/token/page.tsx
index 4dc116d41d5..4c3dd256b6d 100644
--- a/apps/playground-web/src/app/connect/ui/token/page.tsx
+++ b/apps/playground-web/src/app/connect/ui/token/page.tsx
@@ -33,7 +33,7 @@ export default function Page() {
other crypto applications.
>
}
- docsLink="https://portal.thirdweb.com/react/v5/components/onchain#tokens"
+ docsLink="https://portal.thirdweb.com/react/v5/components/onchain#tokens?utm_source=playground"
heroLink="/headless-ui-header.png"
/>
diff --git a/apps/playground-web/src/app/connect/ui/wallet/page.tsx b/apps/playground-web/src/app/connect/ui/wallet/page.tsx
index e97a2dd5599..fa8e02765c6 100644
--- a/apps/playground-web/src/app/connect/ui/wallet/page.tsx
+++ b/apps/playground-web/src/app/connect/ui/wallet/page.tsx
@@ -31,7 +31,7 @@ export default function Page() {
design.
>
}
- docsLink="https://portal.thirdweb.com/react/v5/connecting-wallets/ui-components"
+ docsLink="https://portal.thirdweb.com/react/v5/connecting-wallets/ui-components?utm_source=playground"
heroLink="/headless-ui-header.png"
/>
diff --git a/apps/playground-web/src/app/insight/layout.tsx b/apps/playground-web/src/app/insight/layout.tsx
index 9760ee429f4..3c0d307cfc2 100644
--- a/apps/playground-web/src/app/insight/layout.tsx
+++ b/apps/playground-web/src/app/insight/layout.tsx
@@ -11,7 +11,7 @@ export default function Layout(props: {
description={
<>Simple & customizable endpoints for querying rich blockchain data>
}
- docsLink="https://portal.thirdweb.com/insight"
+ docsLink="https://portal.thirdweb.com/insight?utm_source=playground"
heroLink="/insight-hero.avif"
/>
diff --git a/apps/playground-web/src/app/insight/page.tsx b/apps/playground-web/src/app/insight/page.tsx
index 47e5f96dc87..0b023ded214 100644
--- a/apps/playground-web/src/app/insight/page.tsx
+++ b/apps/playground-web/src/app/insight/page.tsx
@@ -14,7 +14,7 @@ export default async function Page() {
user-friendly format.
There is no need for ABIs, decoding, RPC,
or web3 knowledge to fetch blockchain data.{" "}
diff --git a/apps/playground-web/src/app/otherLinks.ts b/apps/playground-web/src/app/otherLinks.ts
index 2faaab2a7c2..6f38620fa5c 100644
--- a/apps/playground-web/src/app/otherLinks.ts
+++ b/apps/playground-web/src/app/otherLinks.ts
@@ -1,11 +1,11 @@
export const otherLinks: { name: string; href: string }[] = [
{
name: "Dashboard",
- href: "https://thirdweb.com/team",
+ href: "https://thirdweb.com/team?utm_source=playground",
},
{
name: "Docs",
- href: "https://portal.thirdweb.com/",
+ href: "https://portal.thirdweb.com?utm_source=playground",
},
{
name: "Github",
diff --git a/apps/playground-web/src/components/auth/gated-content.tsx b/apps/playground-web/src/components/auth/gated-content.tsx
index 52b0df5d3f4..5c7da700f76 100644
--- a/apps/playground-web/src/components/auth/gated-content.tsx
+++ b/apps/playground-web/src/components/auth/gated-content.tsx
@@ -82,7 +82,7 @@ export async function GatedContentPreview() {
Mint a free commemorative NFT{" "}
diff --git a/apps/playground-web/src/components/engine/minting/erc1155-mint-to.tsx b/apps/playground-web/src/components/engine/minting/erc1155-mint-to.tsx
index 6d085ca489b..28c0476fb3c 100644
--- a/apps/playground-web/src/components/engine/minting/erc1155-mint-to.tsx
+++ b/apps/playground-web/src/components/engine/minting/erc1155-mint-to.tsx
@@ -248,7 +248,7 @@ export function ERC1155MintTo() {
thirdweb Engine Playground{" "}