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 side panel with testimonial and customer logos to auth layout (#3390)

Marcus Farrell7ecb7e3ab7f9
diff --git a/apps/web/app/(ee)/partners.dub.co/(auth-login-register)/program-logos.tsx b/apps/web/app/(ee)/partners.dub.co/(auth-login-register)/program-logos.tsx
index 3bd2b7ca55..9d058c8916 100644
--- a/apps/web/app/(ee)/partners.dub.co/(auth-login-register)/program-logos.tsx
+++ b/apps/web/app/(ee)/partners.dub.co/(auth-login-register)/program-logos.tsx
@@ -65,7 +65,7 @@ export function ProgramLogos() {
key={idx}
className={cn(
"relative flex items-center gap-5",
- "motion-safe:animate-infinite-scroll [--scroll:-100%] motion-safe:[animation-duration:20s]",
+ "motion-safe:animate-infinite-scroll [--scroll:-100%] motion-safe:[animation-duration:30s]",
row % 2 === 0 &&
"motion-safe:[animation-direction:reverse]",
)}
diff --git a/apps/web/app/app.dub.co/(auth)/customer-logos.tsx b/apps/web/app/app.dub.co/(auth)/customer-logos.tsx
new file mode 100644
index 0000000000..4d2a53221b
--- /dev/null
+++ b/apps/web/app/app.dub.co/(auth)/customer-logos.tsx
@@ -0,0 +1,47 @@
+"use client";
+
+import { cn } from "@dub/utils";
+
+const CUSTOMER_LOGOS: { name: string; src: string; className?: string }[] = [
+ {
+ name: "Framer",
+ src: "https://assets.dub.co/companies/framer.svg",
+ className: "h-6",
+ },
+ {
+ name: "Granola",
+ src: "https://assets.dub.co/companies/granola.svg",
+ className: "h-6",
+ },
+ { name: "Buffer", src: "https://assets.dub.co/companies/buffer.svg" },
+ {
+ name: "Copper",
+ src: "https://assets.dub.co/companies/copper.svg",
+ className: "h-4",
+ },
+ {
+ name: "Perplexity",
+ src: "https://assets.dub.co/companies/perplexity.svg",
+ className: "h-5",
+ },
+ { name: "Wispr Flow", src: "https://assets.dub.co/companies/flow.svg" },
+];
+
+export function CustomerLogos() {
+ return (
+ <div className="relative z-10 mx-auto flex max-w-md flex-wrap items-center justify-center gap-x-14 gap-y-8 px-8 pb-12 pt-6 lg:px-10">
+ {CUSTOMER_LOGOS.map((logo, index) => (
+ <img
+ key={logo.name}
+ src={logo.src}
+ alt={logo.name}
+ className={cn(
+ "animate-fade-in-blur h-5 w-auto opacity-0 [animation-fill-mode:forwards]",
+ logo.className,
+ )}
+ style={{ animationDelay: `${500 + index * 120}ms` }}
+ />
+ ))}
+ </div>
+ );
+}
diff --git a/apps/web/app/app.dub.co/(auth)/layout.tsx b/apps/web/app/app.dub.co/(auth)/layout.tsx
index 96fe6df87b..a03a32d37b 100644
--- a/apps/web/app/app.dub.co/(auth)/layout.tsx
+++ b/apps/web/app/app.dub.co/(auth)/layout.tsx
@@ -2,58 +2,68 @@ import Toolbar from "@/ui/layout/toolbar/toolbar";
import { Grid, Wordmark } from "@dub/ui";
import { cn } from "@dub/utils";
import { ReactNode } from "react";
+import { SidePanel } from "./side-panel";
export default function AuthLayout({ children }: { children: ReactNode }) {
return (
<>
<Toolbar />
- <div className="absolute inset-0 isolate overflow-hidden bg-white">
- {/* Grid */}
- <div
- className={cn(
- "absolute inset-y-0 left-1/2 w-[1200px] -translate-x-1/2",
- "[mask-composite:intersect] [mask-image:linear-gradient(black,transparent_320px),linear-gradient(90deg,transparent,black_5%,black_95%,transparent)]",
- )}
- >
- <Grid
- cellSize={60}
- patternOffset={[0.75, 0]}
- className="text-neutral-200"
- />
- </div>
+ <div className="relative grid h-screen grid-cols-1 min-[900px]:grid-cols-[minmax(0,1fr)_440px] lg:grid-cols-[minmax(0,1fr)_595px]">
+ {/* Left: Main auth content */}
+ <div className="relative">
+ <div className="absolute inset-0 isolate overflow-hidden bg-white">
+ {/* Grid */}
+ <div
+ className={cn(
+ "absolute inset-y-0 left-1/2 w-[1200px] -translate-x-1/2",
+ "[mask-composite:intersect] [mask-image:linear-gradient(black,transparent_320px),linear-gradient(90deg,transparent,black_5%,black_95%,transparent)]",
+ )}
+ >
+ <Grid
+ cellSize={60}
+ patternOffset={[0.75, 0]}
+ className="text-neutral-200"
+ />
+ </div>
- {/* Gradient */}
- {[...Array(2)].map((_, idx) => (
- <div
- key={idx}
- className={cn(
- "absolute left-1/2 top-6 size-[80px] -translate-x-1/2 -translate-y-1/2 scale-x-[1.6]",
- idx === 0 ? "mix-blend-overlay" : "opacity-10",
- )}
- >
- {[...Array(idx === 0 ? 2 : 1)].map((_, idx) => (
+ {/* Gradient */}
+ {[...Array(2)].map((_, idx) => (
<div
key={idx}
className={cn(
- "absolute -inset-16 mix-blend-overlay blur-[50px] saturate-[2]",
- "bg-[conic-gradient(from_90deg,#F00_5deg,#EAB308_63deg,#5CFF80_115deg,#1E00FF_170deg,#855AFC_220deg,#3A8BFD_286deg,#F00_360deg)]",
+ "absolute left-1/2 top-6 size-[80px] -translate-x-1/2 -translate-y-1/2 scale-x-[1.6]",
+ idx === 0 ? "mix-blend-overlay" : "opacity-10",
)}
- />
+ >
+ {[...Array(idx === 0 ? 2 : 1)].map((_, idx) => (
+ <div
+ key={idx}
+ className={cn(
+ "absolute -inset-16 mix-blend-overlay blur-[50px] saturate-[2]",
+ "bg-[conic-gradient(from_90deg,#F00_5deg,#EAB308_63deg,#5CFF80_115deg,#1E00FF_170deg,#855AFC_220deg,#3A8BFD_286deg,#F00_360deg)]",
+ )}
+ />
+ ))}
+ </div>
))}
</div>
- ))}
- </div>
- <div className="relative flex min-h-screen w-full justify-center">
- <a
- href="https://dub.co"
- target="_blank"
- className="absolute left-1/2 top-4 z-10 -translate-x-1/2"
- >
- <Wordmark className="h-8" />
- </a>
- {children}
+ <div className="relative flex min-h-screen w-full justify-center">
+ <a
+ href="https://dub.co"
+ target="_blank"
+ rel="noopener noreferrer"
+ className="absolute left-1/2 top-4 z-10 -translate-x-1/2"
+ >
+ <Wordmark className="h-8" />
+ </a>
+ {children}
+ </div>
+ </div>
+
+ {/* Right: Side panel - hidden on mobile */}
+ <SidePanel />
</div>
</>
);
diff --git a/apps/web/app/app.dub.co/(auth)/side-panel.tsx b/apps/web/app/app.dub.co/(auth)/side-panel.tsx
new file mode 100644
index 0000000000..6c037ff35f
--- /dev/null
+++ b/apps/web/app/app.dub.co/(auth)/side-panel.tsx
@@ -0,0 +1,64 @@
+import { cn } from "@dub/utils";
+import Link from "next/link";
+import { CustomerLogos } from "./customer-logos";
+
+export function SidePanel() {
+ return (
+ <div className="relative hidden h-full flex-col justify-between overflow-hidden border-l border-black/5 bg-neutral-50 min-[900px]:flex">
+ {/* Gradient at bottom */}
+ {[...Array(2)].map((_, idx) => (
+ <div
+ key={idx}
+ className={cn(
+ "absolute bottom-0 left-1/2 size-[80px] -translate-x-1/2 translate-y-1/2 scale-x-[1.6]",
+ idx === 0 ? "mix-blend-overlay" : "opacity-15",
+ )}
+ >
+ {[...Array(idx === 0 ? 2 : 1)].map((_, innerIdx) => (
+ <div
+ key={innerIdx}
+ className={cn(
+ "absolute -inset-16 mix-blend-overlay blur-[50px] saturate-[2]",
+ "bg-[conic-gradient(from_90deg,#F00_5deg,#EAB308_63deg,#5CFF80_115deg,#1E00FF_170deg,#855AFC_220deg,#3A8BFD_286deg,#F00_360deg)]",
+ )}
+ />
+ ))}
+ </div>
+ ))}
+
+ {/* Testimonial section - vertically centered */}
+ <div className="relative flex grow items-center justify-center p-8 lg:p-14">
+ <div className="flex flex-col gap-6">
+ <div className="relative overflow-hidden rounded-xl border border-neutral-900/10">
+ <img
+ src="https://assets.dub.co/cms/framer-thumbnail.png"
+ alt="Framer team"
+ className="aspect-[16/12] w-full object-cover"
+ />
+ <div className="pointer-events-none absolute inset-x-0 top-0 h-24 bg-gradient-to-b from-neutral-900 to-transparent opacity-30" />
+ <img
+ src="https://assets.dub.co/companies/framer.svg"
+ alt="Framer"
+ className="absolute left-6 top-6 h-8 w-auto brightness-0 invert"
+ />
+ </div>
+
+ <p className="text-content-default max-w-[370px] text-pretty text-xl font-medium">
+ Learn how Framer manages $500K+ in monthly affiliate payouts with
+ Dub
+ </p>
+
+ <Link
+ href="https://dub.co/customers/framer"
+ target="_blank"
+ className="text-content-emphasis flex h-8 w-fit items-center rounded-lg bg-black/5 px-3 text-sm font-medium transition-[transform,background-color] duration-75 hover:bg-black/10 active:scale-[0.98]"
+ >
+ Read more
+ </Link>
+ </div>
+ </div>
+
+ <CustomerLogos />
+ </div>
+ );
+}
diff --git a/packages/tailwind-config/tailwind.config.ts b/packages/tailwind-config/tailwind.config.ts
index 47b078b64a..c9072a8c46 100644
--- a/packages/tailwind-config/tailwind.config.ts
+++ b/packages/tailwind-config/tailwind.config.ts
@@ -47,6 +47,7 @@ const config: Config = {
// Modal
"scale-in": "scale-in 0.2s cubic-bezier(0.16, 1, 0.3, 1)",
"fade-in": "fade-in 0.2s ease-out forwards",
+ "fade-in-blur": "fade-in-blur 0.5s ease-out forwards",
"scale-in-fade": "scale-in-fade 0.2s ease-out forwards",
// Popover, Tooltip
"slide-up-fade": "slide-up-fade 0.4s cubic-bezier(0.16, 1, 0.3, 1)",
@@ -86,6 +87,11 @@ const config: Config = {
"0%": { opacity: "0" },
"100%": { opacity: "1" },
},
+ "fade-in-blur": {
+ "0%": { opacity: "0", filter: "blur(4px)" },
+ "50%": { opacity: "0.5", filter: "blur(0px)" },
+ "100%": { opacity: "1", filter: "blur(0px)" },
+ },
"scale-in-fade": {
"0%": { transform: "scale(0.95)", opacity: "0" },
"100%": { transform: "scale(1)", opacity: "1" },