The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
added confetti :confetti_ball: , made gradients subtler, added shadow to divs
Steven Teyaef8a5fb2a6a
diff --git a/components/home/background.module.css b/components/home/background.module.cssindex 64ea49093f..1df99404d3 100644--- a/components/home/background.module.css+++ b/components/home/background.module.css@@ -9,7 +9,7 @@}.main:before {- background: radial-gradient(circle, rgba(2, 0, 36, 0) 0, #f9f9f9 100%);+ background: radial-gradient(circle, rgba(2, 0, 36, 0) 0, #fafafa 100%);position: absolute;content: "";z-index: 2;@@ -26,7 +26,7 @@width: 100%;height: 100%;top: 0;- opacity: 0.5;+ opacity: 0.4;filter: invert(1);}@@ -52,5 +52,5 @@height: 100%;filter: blur(100px) saturate(150%);top: 80px;- opacity: 0.2;+ opacity: 0.15;}diff --git a/components/home/demo.tsx b/components/home/demo.tsxindex 77eaae0e7c..9a6b711d70 100644--- a/components/home/demo.tsx+++ b/components/home/demo.tsx@@ -48,7 +48,7 @@ const Demo = () => {}><div className="relative flex items-center">- <div className="shadow-sm bg-white border focus:border-black block w-full p-2 text-sm text-gray-400 border-gray-200 rounded-md pl-3 pr-12">+ <div className="shadow-lg bg-white border focus:border-black block w-full p-2 text-sm text-gray-400 border-gray-200 rounded-md pl-3 pr-12">Shorten your link</div><div className="cursor-not-allowed absolute inset-y-0 right-0 w-10 flex justify-center items-center my-1.5 mr-1.5 border border-gray-200 rounded text-sm font-sans font-medium text-gray-400">@@ -66,7 +66,7 @@ const Demo = () => {setUrl((e.target as HTMLInputElement).value);}}required- className="peer shadow-sm focus:outline-none focus:ring-0 bg-white border focus:border-black block w-full p-2 text-sm border-gray-200 rounded-md pl-3 pr-12"+ className="peer shadow-lg focus:outline-none focus:ring-0 bg-white border focus:border-black block w-full p-2 text-sm border-gray-200 rounded-md pl-3 pr-12"/><buttontype="submit"@@ -116,7 +116,7 @@ const Demo = () => {))}<motion.livariants={FRAMER_MOTION_LIST_ITEM_VARIANTS}- className="border border-gray-200 bg-white p-3 rounded-md text-gray-500 text-sm"+ className="border border-gray-200 bg-white shadow-lg p-3 rounded-md text-gray-500 text-sm">Note: Public links will be automatically-deleted after 30 minutes.{" "}<adiff --git a/components/home/features.tsx b/components/home/features.tsxindex f159ac73a2..c9a73bbc2a 100644--- a/components/home/features.tsx+++ b/components/home/features.tsx@@ -60,7 +60,7 @@ const Features = ({ stars }: { stars: number }) => {alt="Built-in analytics"width={1120}height={919}- className="w-full max-w-[700px]"+ className="w-full max-w-[700px] shadow-lg"/></div>@@ -71,7 +71,7 @@ const Features = ({ stars }: { stars: number }) => {alt="Custom domains"width={1084}height={646}- className="w-full max-w-[635px] rounded-2xl border border-gray-200"+ className="w-full max-w-[635px] rounded-2xl border border-gray-200 shadow-lg"/><div className="flex flex-col space-y-5 my-10 lg:my-0"><div className="flex items-center justify-center w-20 h-20 rounded-full bg-gradient-to-r from-purple-600 to-pink-600">@@ -123,13 +123,13 @@ const Features = ({ stars }: { stars: number }) => {alt="Custom domains"width={1084}height={646}- className="w-full max-w-[700px] rounded-2xl border border-gray-200"+ className="w-full max-w-[700px] rounded-2xl border border-gray-200 shadow-lg"/></div>{/* Open Source */}<div className="flex lg:space-x-16 flex-col lg:flex-row items-center my-20">- <div className="flex items-center justify-center rounded-2xl w-full max-w-[700px] bg-gray-900 h-96">+ <div className="flex items-center justify-center rounded-2xl w-full max-w-[700px] bg-gray-900 h-96 shadow-lg"><div className="flex items-center"><ahref="https://github.com/steven-tey/dub"diff --git a/components/home/hero.tsx b/components/home/hero.tsxindex b16c15cdd4..a7ee9b7758 100644--- a/components/home/hero.tsx+++ b/components/home/hero.tsx@@ -30,12 +30,12 @@ const Hero = () => {<div className="mt-10 flex space-x-4 max-w-fit mx-auto"><Link href="https://app.dub.sh/register">- <a className="py-2 px-5 bg-black hover:bg-white rounded-full border border-black text-sm text-white hover:text-black transition-all">+ <a className="py-2 px-5 bg-black hover:bg-white shadow-lg rounded-full border border-black text-sm text-white hover:text-black transition-all">Start For Free</a></Link><a- className="flex justify-center items-center space-x-2 py-2 px-5 bg-white rounded-full border border-gray-300 hover:border-gray-800 transition-all"+ className="flex justify-center items-center space-x-2 py-2 px-5 bg-white shadow-lg rounded-full border border-gray-300 hover:border-gray-800 transition-all"href="https://dub.sh/github"target="_blank"rel="noreferrer"diff --git a/components/home/link-card.tsx b/components/home/link-card.tsxindex 9ecde1f3dc..174fb8e1c2 100644--- a/components/home/link-card.tsx+++ b/components/home/link-card.tsx@@ -121,7 +121,7 @@ export default function LinkCard({onDrag={() => setVelocity(x.getVelocity())}onDragEnd={() => flyAway(500)}whileTap={{ scale: 1.05 }}- className="cursor-grab active:cursor-grabbing flex items-center space-x-3 border border-gray-200 hover:border-black bg-white p-3 max-w-md rounded-md transition-[border-color]"+ className="cursor-grab active:cursor-grabbing flex items-center space-x-3 border border-gray-200 hover:border-black shadow-lg bg-white p-3 max-w-md rounded-md transition-[border-color]"><BlurImagesrc={`https://www.google.com/s2/favicons?sz=64&domain_url=${apexDomain}`}diff --git a/components/home/placeholder-card.tsx b/components/home/placeholder-card.tsxindex c4310ade0b..747cedf7d4 100644--- a/components/home/placeholder-card.tsx+++ b/components/home/placeholder-card.tsx@@ -5,7 +5,7 @@ export default function PlaceholderCard() {return (<motion.livariants={FRAMER_MOTION_LIST_ITEM_VARIANTS}- className="flex items-center border border-gray-200 bg-white p-3 rounded-md"+ className="flex items-center border border-gray-200 bg-white shadow-lg p-3 rounded-md"><div className="w-10 h-10 rounded-full mr-2 bg-gray-200" /><div>diff --git a/components/home/pricing.tsx b/components/home/pricing.tsxindex 7b077fe6e2..0cbb409255 100644--- a/components/home/pricing.tsx+++ b/components/home/pricing.tsx@@ -1,5 +1,6 @@import Link from "next/link";-import { useState } from "react";+import { useMemo, useState } from "react";+import Confetti from "react-dom-confetti";import {CheckCircleFill,QuestionCircle,@@ -7,6 +8,7 @@ import {} from "@/components/shared/icons";import MaxWidthWrapper from "@/components/shared/max-width-wrapper";import Slider from "@/components/shared/slider";+import Switch from "@/components/shared/switch";import Tooltip, { OGImageProxy } from "@/components/shared/tooltip";import { PRO_TIERS } from "@/lib/stripe/constants";import { nFormatter } from "@/lib/utils";@@ -88,6 +90,11 @@ const pricingItems = [const Pricing = () => {const [tier, setTier] = useState(0);+ const [annualBilling, setAnnualBilling] = useState(true);+ const period = useMemo(+ () => (annualBilling ? "yearly" : "monthly"),+ [annualBilling],+ );return (<MaxWidthWrapper className="mt-20 mb-40 text-center">@@ -103,6 +110,25 @@ const Pricing = () => {Start for free, no credit card required. Upgrade anytime.</p></div>++ <div className="relative flex space-x-2 items-center max-w-fit mx-auto mb-14">+ <p className="text-gray-600">Billed Monthly</p>+ <Confetti+ active={period === "yearly"}+ config={{ elementCount: 200, spread: 90 }}+ />+ <Switch+ fn={setAnnualBilling}+ trackDimensions="h-6 w-12"+ thumbDimensions="h-5 w-5"+ thumbTranslate="translate-x-6"+ />+ <p className="text-gray-600">Billed Annually</p>+ <span className="absolute -top-2 -right-36 rounded-full bg-purple-200 text-purple-700 text-sm px-3 py-1">+ 🎁 2 months FREE+ </span>+ </div>+<div className="grid grid-cols-1 lg:grid-cols-3 gap-10">{pricingItems.map(({ plan, tagline, clicksLimit, features, cta, ctaLink }) => (@@ -112,7 +138,7 @@ const Pricing = () => {plan === "Pro"? "border-2 border-blue-600 shadow-blue-200": "border border-gray-200"- } shadow-md`}+ } shadow-lg`}>{plan === "Pro" && (<div className="absolute -top-5 left-0 right-0 mx-auto bg-gradient-to-r from-blue-600 to-cyan-600 text-white text-sm font-medium w-32 px-3 py-2 rounded-full">@@ -133,12 +159,19 @@ const Pricing = () => {<p className="text-6xl font-display font-semibold">${plan === "Pro"- ? PRO_TIERS[tier].price.monthly.amount+ ? period === "yearly"+ ? nFormatter(+ PRO_TIERS[tier].price.yearly.amount / 12,+ 1,+ )+ : PRO_TIERS[tier].price.monthly.amount: 0}</p></div>)}- <p className="text-gray-500">Monthly</p>+ <p className="text-gray-500">+ per month{period === "yearly" ? ", billed yearly" : ""}+ </p></div><div className="border-t border-b border-gray-200 flex items-center justify-center h-20 bg-gray-50">{plan === "Pro" ? (