"use client"; import { BellIcon, GlobeIcon, HomeIcon, RowsIcon, UploadIcon } from "@radix-ui/react-icons" import Link from "next/link" import { FormEvent, JSX, SVGProps, useEffect, useState } from "react" import { Avatar, AvatarFallback, AvatarImage } from "./ui/avatar" import { useRouter, usePathname } from 'next/navigation' import { SearchIcon, Upload } from "lucide-react"; import { Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerTitle, DrawerTrigger, } from "@/components/ui/drawer" import { Button } from "./ui/button"; import { Textarea } from "./ui/textarea"; import { useNostr } from "nostr-react"; export default function BottomBar() { const router = useRouter(); const [pubkey, setPubkey] = useState(null); const pathname = usePathname(); useEffect(() => { if (typeof window !== 'undefined') { setPubkey(window.localStorage.getItem('pubkey') ?? null); } }, []); if (typeof window === 'undefined') return null; const isActive = (path: string, currentPath: string) => currentPath === path ? 'text-purple-500' : ''; return ( ) }