"use client" import { CHROME_EXTENSION_URL } from "@repo/lib/constants" import type { IntegrationParamValue } from "@/lib/search-params" import { cn } from "@lib/utils" import { dmSansClassName } from "@/lib/fonts" import { Button } from "@ui/components/button" import NovaOrb from "./nova-orb" import { ChromeIcon } from "@/components/integration-icons" import { ArrowRight, Link2, FileText, Zap } from "lucide-react" interface NovaEmptyStateProps { onAddMemory: (tab: "note" | "link") => void onOpenIntegrations: (integration?: IntegrationParamValue) => void isAllSpaces: boolean spaceName?: string onSwitchToAllSpaces?: () => void } const cardClass = cn( "bg-[#14161A] rounded-xl p-4 border border-[rgba(82,89,102,0.2)]", "hover:border-[#3374FF]/50 hover:bg-[#1B1F24]", "transition-colors cursor-pointer text-left flex flex-col gap-2", ) export function NovaEmptyState({ onAddMemory, onOpenIntegrations, isAllSpaces, spaceName, onSwitchToAllSpaces, }: NovaEmptyStateProps) { const handleInstallChrome = () => { window.open(CHROME_EXTENSION_URL, "_blank", "noopener,noreferrer") } const showSingleSpaceEmpty = !isAllSpaces && onSwitchToAllSpaces return (
{isAllSpaces ? ( <>

Help Nova get to know you

Add your first memory to get started.

) : showSingleSpaceEmpty ? ( <>

{spaceName ? ( <> "{spaceName}" {" "} is empty ) : ( "This space is empty" )}

Your memories may be in another space.

) : ( <>

This space is empty

{spaceName ? ( <> Add memories to{" "} "{spaceName}" {" "} to get started. ) : ( "Add memories to this space to get started." )}

)}
) }