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 left panel empty state

Tim Wilsonf32a594f76a4
diff --git a/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/messages/page-client.tsx b/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/messages/page-client.tsx
index 62c5b230e3..6a99099474 100644
--- a/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/messages/page-client.tsx
+++ b/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/messages/page-client.tsx
@@ -2,9 +2,11 @@
import { NavButton } from "@/ui/layout/page-content/nav-button";
import { ToggleSidePanelButton } from "@/ui/messages/toggle-side-panel-button";
-import { ChevronLeft } from "@dub/ui/icons";
+import { Button } from "@dub/ui";
+import { ChevronLeft, Msgs } from "@dub/ui/icons";
import { cn } from "@dub/utils";
import { CSSProperties, useState } from "react";
+import { toast } from "sonner";
export function ProgramMessagesPageClient() {
const [currentPanel, setCurrentPanel] = useState<0 | 1 | 2>(0);
@@ -22,7 +24,7 @@ export function ProgramMessagesPageClient() {
}
>
{/* Left panel - Partner/messages list */}
- <div className="@[960px]/page:w-[280px] @[1080px]/page:w-[340px] w-full overflow-hidden">
+ <div className="@[960px]/page:w-[280px] @[1080px]/page:w-[340px] flex w-full flex-col overflow-hidden">
<div className="border-border-subtle flex h-12 items-center justify-between gap-4 border-b px-4 sm:h-16 sm:px-6">
<div className="flex min-w-0 items-center gap-4">
<NavButton />
@@ -33,7 +35,31 @@ export function ProgramMessagesPageClient() {
</div>
</div>
</div>
- <div onClick={() => setCurrentPanel(1)}>[side panel content]</div>
+ <div className="grow">
+ <div className="flex size-full flex-col items-center justify-center px-4">
+ {/* TODO: Remove onClick (it's there for testing) */}
+ <Msgs
+ className="size-10 text-black"
+ onClick={() => setCurrentPanel(1)}
+ />
+ <div className="mt-6 max-w-64 text-center">
+ <span className="text-content-emphasis text-base font-semibold">
+ You don't have any messages
+ </span>
+ <p className="text-content-subtle text-sm font-medium">
+ When you receive a new message, it will appear here. You can
+ also start a conversation at any time.
+ </p>
+ </div>
+
+ <Button
+ variant="primary"
+ className="mt-6 h-8 w-fit rounded-lg"
+ text="Compose message"
+ onClick={() => toast.info("WIP")}
+ />
+ </div>
+ </div>
</div>
{/* Middle panel - Messages */}