Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

add launch week email

Steven Tey296e9a8368e4
diff --git a/apps/web/lib/email/email-templates-map.ts b/apps/web/lib/email/email-templates-map.ts
index 2eb6ffba49..a3f6f1a839 100644
--- a/apps/web/lib/email/email-templates-map.ts
+++ b/apps/web/lib/email/email-templates-map.ts
@@ -1,6 +1,6 @@
import BountyApproved from "@dub/email/templates/bounty-approved";
import IdentityVerificationAnnouncement from "@dub/email/templates/broadcasts/identity-verification-announcement";
-import DubLaunchWeekDay2 from "@dub/email/templates/broadcasts/launch-week-day-2";
+import DubLaunchWeekDay3 from "@dub/email/templates/broadcasts/launch-week-day-3";
import ConnectPayoutReminder from "@dub/email/templates/connect-payout-reminder";
import ConnectPlatformsReminder from "@dub/email/templates/connect-platforms-reminder";
import PartnerBanned from "@dub/email/templates/partner-banned";
@@ -30,5 +30,5 @@ export const EMAIL_TEMPLATES_MAP = {
// PayoutAutoWithdrawals,
// ProgramMarketplaceAnnouncement,
// StablecoinPayoutsAnnouncement,
- DubLaunchWeekDay2,
+ DubLaunchWeekDay3,
} as const;
diff --git a/apps/web/scripts/send-batch-emails.ts b/apps/web/scripts/send-batch-emails.ts
index 7a6718c8a0..8405ee79f2 100644
--- a/apps/web/scripts/send-batch-emails.ts
+++ b/apps/web/scripts/send-batch-emails.ts
@@ -1,4 +1,4 @@
-import DubLaunchWeekDay2 from "@dub/email/templates/broadcasts/launch-week-day-2";
+import DubLaunchWeekDay3 from "@dub/email/templates/broadcasts/launch-week-day-3";
import { prisma } from "@dub/prisma";
import { chunk } from "@dub/utils";
import "dotenv-flow/config";
@@ -43,12 +43,12 @@ async function main() {
}
console.log(`Found ${usersToNotify.length} users to notify`);
- const res = await queueBatchEmail<typeof DubLaunchWeekDay2>(
+ const res = await queueBatchEmail<typeof DubLaunchWeekDay3>(
usersToNotify.map((user) => ({
to: user.email!,
variant: "marketing",
- subject: "Dub Launch Week Day 2: Introducing Partner Tags",
- templateName: "DubLaunchWeekDay2",
+ subject: "Dub Launch Week Day 3: Introducing Commission Analytics",
+ templateName: "DubLaunchWeekDay3",
templateProps: {
email: user.email!,
unsubscribeUrl: `https://app.dub.co/unsubscribe/${generateUnsubscribeToken(user.email!)}`,
diff --git a/packages/email/src/templates/broadcasts/launch-week-day-3.tsx b/packages/email/src/templates/broadcasts/launch-week-day-3.tsx
new file mode 100644
index 0000000000..ad200f4405
--- /dev/null
+++ b/packages/email/src/templates/broadcasts/launch-week-day-3.tsx
@@ -0,0 +1,155 @@
+import { DUB_WORDMARK } from "@dub/utils";
+import {
+ Body,
+ Container,
+ Head,
+ Heading,
+ Hr,
+ Html,
+ Img,
+ Link,
+ Preview,
+ Section,
+ Tailwind,
+ Text,
+} from "@react-email/components";
+import { Footer } from "../../components/footer";
+
+export default function DubLaunchWeekDay3({
+ email = "[email protected]",
+ unsubscribeUrl = "https://app.dub.co/account/settings",
+}: {
+ email: string;
+ unsubscribeUrl: string;
+}) {
+ return (
+ <Html>
+ <Head>
+ <style>{`
+ @media only screen and (max-width: 600px) {
+ .email-container {
+ padding-left: 16px !important;
+ padding-right: 16px !important;
+ }
+ }
+ `}</style>
+ </Head>
+ <Preview>
+ You can now see a real-time analytics dashboard of your partner
+ commissions on Dub.
+ </Preview>
+ <Tailwind>
+ <Body className="mx-auto my-auto bg-white font-sans">
+ <Container className="email-container mx-auto my-10 max-w-[600px] px-10 py-5">
+ <Section className="mt-2 text-center">
+ <Img
+ src={DUB_WORDMARK}
+ width="65"
+ height="32"
+ alt="Dub"
+ style={{ display: "block", margin: "0 auto" }}
+ />
+ </Section>
+
+ <Heading className="mx-0 mb-2 mt-8 p-0 text-center text-2xl font-semibold text-black">
+ Dub Launch Week Day 3
+ </Heading>
+
+ <Text className="mx-auto mb-8 mt-0 max-w-sm text-center text-base leading-6 text-neutral-600">
+ Introducing Commission Analytics – real-time analytics for your
+ partner commissions
+ </Text>
+
+ <Text className="mx-0 mb-4 mt-0 text-sm leading-6 text-neutral-600">
+ 👋 Hey, it's Steven from Dub!
+ </Text>
+ <Text className="mx-0 mb-8 mt-0 text-sm leading-6 text-neutral-600">
+ Today is <strong>Day 3 of our Spring Launch Week</strong>, where
+ we'll be launching an exciting new feature for{" "}
+ <Link
+ href="http://ship.dub.co/partners"
+ className="font-medium text-black underline"
+ >
+ Dub Partners
+ </Link>{" "}
+ every day – for 5 days straight!
+ </Text>
+
+ <Section className="mb-8 text-center">
+ <Link
+ href="https://ship.dub.co/commission-analytics"
+ style={{ textDecoration: "none" }}
+ >
+ <Img
+ src="https://assets.dub.co/cms/commission-analytics.jpg"
+ width={560}
+ height={320}
+ alt="Commission Analytics"
+ style={{
+ display: "block",
+ maxWidth: "100%",
+ height: "auto",
+ margin: "0 auto",
+ borderRadius: "8px",
+ }}
+ />
+ </Link>
+ </Section>
+
+ <Heading className="mx-0 mb-3 mt-0 p-0 text-lg font-semibold text-black">
+ Introducing Commission Analytics
+ </Heading>
+
+ <Text className="mx-0 mb-4 mt-0 text-sm leading-6 text-neutral-600">
+ You can now see a real-time analytics dashboard of your partner
+ commissions to measure your return on ad spend (ROAS) on Dub.
+ </Text>
+ <Text className="mx-0 mb-2 mt-0 text-sm leading-6 text-neutral-600">
+ You are also able to see your:
+ </Text>
+ <Text className="mx-0 mb-1 mt-0 pl-4 text-sm leading-6 text-neutral-600">
+ • Top partners by commissions
+ </Text>
+ <Text className="mx-0 mb-1 mt-0 pl-4 text-sm leading-6 text-neutral-600">
+ • Top partner groups by commissions
+ </Text>
+ <Text className="mx-0 mb-4 mt-0 pl-4 text-sm leading-6 text-neutral-600">
+ • Top partner tags by commissions
+ </Text>
+ <Link
+ href="https://ship.dub.co/commission-analytics"
+ className="block w-full rounded-lg bg-neutral-900 py-2.5 text-center text-sm font-medium text-white no-underline"
+ style={{
+ backgroundColor: "#171717",
+ color: "#ffffff",
+ borderRadius: "8px",
+ padding: "10px 16px",
+ textDecoration: "none",
+ fontWeight: "500",
+ fontSize: "14px",
+ width: "100%",
+ boxSizing: "border-box",
+ }}
+ >
+ Learn more about Commission Analytics
+ </Link>
+
+ <Hr className="mx-0 my-6 w-full border border-neutral-200" />
+
+ <Text className="mx-0 mb-4 mt-0 text-sm leading-6 text-neutral-600">
+ That's all for Day 3! Stay tuned for the remaining days of our
+ Spring Launch Week – see you tomorrow!
+ </Text>
+ <Text className="mx-0 mb-4 mt-0 text-sm leading-6 text-neutral-400">
+ Steven from Dub.co
+ </Text>
+
+ <Section className="mx-auto max-w-[400px] text-center">
+ <Footer email={email} marketing unsubscribeUrl={unsubscribeUrl} />
+ </Section>
+ </Container>
+ </Body>
+ </Tailwind>
+ </Html>
+ );
+}