{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "navbar-14",
  "title": "Team navbar",
  "description": "A team switcher, centred icon links and a primary action to write a post.",
  "dependencies": [
    "motion"
  ],
  "registryDependencies": [
    "https://ui.ndekocode.dev/r/animated-size.json",
    "https://ui.ndekocode.dev/r/avatar.json",
    "https://ui.ndekocode.dev/r/button.json",
    "https://ui.ndekocode.dev/r/company-mark.json",
    "https://ui.ndekocode.dev/r/dropdown-menu.json",
    "https://ui.ndekocode.dev/r/icons.json",
    "https://ui.ndekocode.dev/r/navigation-menu.json",
    "https://ui.ndekocode.dev/r/popover.json",
    "https://ui.ndekocode.dev/r/recipes.json",
    "https://ui.ndekocode.dev/r/theme.json",
    "https://ui.ndekocode.dev/r/tooltip.json",
    "https://ui.ndekocode.dev/r/use-prefers-reduced-motion.json",
    "https://ui.ndekocode.dev/r/utils.json"
  ],
  "files": [
    {
      "path": "registry/ndeko/components/navbar/navbar-14.tsx",
      "content": "'use client';\n\nimport {\n  MobileNav,\n  MobileNavLinks,\n} from '@/registry/ndeko/components/navbar/_parts/mobile-nav';\nimport {\n  NavLinks,\n  type NavLinkItem,\n} from '@/registry/ndeko/components/navbar/_parts/nav-links';\nimport { NotificationMenu } from '@/registry/ndeko/components/navbar/_parts/notification-menu';\nimport { TeamSwitcher } from '@/registry/ndeko/components/navbar/_parts/team-switcher';\nimport { useActiveLink } from '@/registry/ndeko/components/navbar/_parts/use-active-link';\nimport { UserMenu } from '@/registry/ndeko/components/navbar/_parts/user-menu';\nimport {\n  CompassIcon,\n  FeatherIcon,\n  HouseIcon,\n  PlusIcon,\n  SearchIcon,\n} from '@/registry/ndeko/lib/icons';\nimport { Button } from '@/registry/ndeko/ui/button';\n\nconst TEAMS = ['Acme Inc.', 'Lumen Labs', 'Junon'];\n\nconst LINKS: NavLinkItem[] = [\n  { href: '#', label: 'Dashboard', icon: HouseIcon },\n  { href: '#', label: 'Explore', icon: CompassIcon },\n  { href: '#', label: 'Write', icon: FeatherIcon },\n  { href: '#', label: 'Search', icon: SearchIcon },\n];\n\nexport default function Navbar14() {\n  const { activeLabel, navigate } = useActiveLink();\n\n  return (\n    <header className='hairline-b border-border px-4 md:px-6'>\n      <div className='flex h-16 items-center justify-between gap-2 sm:gap-4'>\n        <div className='flex flex-1 items-center gap-2'>\n          <MobileNav className='w-48'>\n            <MobileNavLinks\n              links={LINKS}\n              activeLabel={activeLabel}\n              onNavigate={navigate}\n              showsIcons\n            />\n          </MobileNav>\n          <TeamSwitcher teams={TEAMS} defaultTeam={TEAMS[0]} />\n        </div>\n        <NavLinks\n          links={LINKS}\n          activeLabel={activeLabel}\n          onNavigate={navigate}\n          display='icon'\n          className='max-md:hidden'\n        />\n        <div className='flex flex-1 items-center justify-end gap-2 sm:gap-4'>\n          <Button className='max-sm:aspect-square max-sm:px-0'>\n            <PlusIcon className='opacity-60' />\n            <span className='max-sm:sr-only'>Post</span>\n          </Button>\n          <NotificationMenu />\n          <UserMenu />\n        </div>\n      </div>\n    </header>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/navbar/navbar-14.tsx"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/mobile-nav.tsx",
      "content": "'use client';\n\nimport { createContext, useContext, useState } from 'react';\n\nimport {\n  isPlaceholderHref,\n  NavLinkIcon,\n  type NavLinkItem,\n} from '@/registry/ndeko/components/navbar/_parts/nav-links';\nimport {\n  MENU_ITEM,\n  MENU_LABEL,\n  MENU_SEPARATOR,\n} from '@/registry/ndeko/lib/recipes';\nimport { cn } from '@/registry/ndeko/lib/utils';\nimport { Button } from '@/registry/ndeko/ui/button';\nimport {\n  Popover,\n  PopoverContent,\n  PopoverTrigger,\n} from '@/registry/ndeko/ui/popover';\n\nconst CloseMenuContext = createContext<() => void>(() => undefined);\n\nconst BAR =\n  'origin-center transition-[translate,rotate] duration-300 ease-(--ease-out-strong)';\n\nconst LINK_ROW = cn(\n  MENU_ITEM,\n  'text-muted-foreground cursor-pointer transition-colors duration-150',\n  'hover:bg-foreground/5 hover:text-foreground focus-visible:bg-foreground/5 focus-visible:text-foreground',\n  'data-active:bg-foreground/[0.06] data-active:text-foreground dark:data-active:bg-foreground/10'\n);\n\nfunction menuLabelOf(isOpen: boolean) {\n  if (isOpen) {\n    return 'Close menu';\n  }\n  return 'Open menu';\n}\n\nfunction ariaCurrentOf(isActive: boolean) {\n  if (isActive) {\n    return 'page' as const;\n  }\n  return undefined;\n}\n\nfunction MenuToggleIcon() {\n  return (\n    <svg\n      viewBox='0 0 24 24'\n      fill='none'\n      stroke='currentColor'\n      strokeWidth='1.75'\n      strokeLinecap='round'\n      strokeLinejoin='round'\n      aria-hidden='true'\n      className='pointer-events-none size-4'\n    >\n      <path\n        d='M4 12H20'\n        className={cn(\n          BAR,\n          '-translate-y-[7px] group-aria-expanded/button:translate-y-0 group-aria-expanded/button:rotate-[315deg]'\n        )}\n      />\n      <path\n        d='M4 12H20'\n        className={cn(BAR, 'group-aria-expanded/button:rotate-45')}\n      />\n      <path\n        d='M4 12H20'\n        className={cn(\n          BAR,\n          'translate-y-[7px] group-aria-expanded/button:translate-y-0 group-aria-expanded/button:rotate-[135deg]'\n        )}\n      />\n    </svg>\n  );\n}\n\ntype MobileNavProps = {\n  children: React.ReactNode;\n  className?: string;\n};\n\nfunction MobileNav({ children, className }: MobileNavProps) {\n  const [isOpen, setIsOpen] = useState(false);\n\n  function changeOpen(open: boolean) {\n    setIsOpen(open);\n  }\n\n  function closeMenu() {\n    setIsOpen(false);\n  }\n\n  return (\n    <Popover open={isOpen} onOpenChange={changeOpen}>\n      <PopoverTrigger\n        render={\n          <Button\n            variant='ghost'\n            size='icon'\n            aria-label={menuLabelOf(isOpen)}\n            className='md:hidden'\n          />\n        }\n      >\n        <MenuToggleIcon />\n      </PopoverTrigger>\n      <PopoverContent\n        align='start'\n        className={cn('w-44 p-1 md:hidden', className)}\n      >\n        <nav aria-label='Main'>\n          <CloseMenuContext.Provider value={closeMenu}>\n            {children}\n          </CloseMenuContext.Provider>\n        </nav>\n      </PopoverContent>\n    </Popover>\n  );\n}\n\ntype MobileNavLinkProps = {\n  href: string;\n  isActive?: boolean;\n  onClick?: () => void;\n  className?: string;\n  children: React.ReactNode;\n};\n\nfunction MobileNavLink({\n  href,\n  isActive = false,\n  onClick,\n  className,\n  children,\n}: MobileNavLinkProps) {\n  const closeMenu = useContext(CloseMenuContext);\n\n  function follow(event: React.MouseEvent<HTMLAnchorElement>) {\n    if (isPlaceholderHref(href)) {\n      event.preventDefault();\n    }\n    onClick?.();\n    closeMenu();\n  }\n\n  return (\n    <a\n      href={href}\n      aria-current={ariaCurrentOf(isActive)}\n      data-active={isActive || undefined}\n      onClick={follow}\n      className={cn(LINK_ROW, className)}\n    >\n      {children}\n    </a>\n  );\n}\n\ntype MobileNavLinksProps = {\n  links: NavLinkItem[];\n  activeLabel?: string;\n  onNavigate?: (label: string) => void;\n  showsIcons?: boolean;\n};\n\nfunction MobileNavLinks({\n  links,\n  activeLabel,\n  onNavigate,\n  showsIcons = false,\n}: MobileNavLinksProps) {\n  return (\n    <ul className='flex flex-col'>\n      {links.map((link) => (\n        <li key={link.label}>\n          <MobileNavLink\n            href={link.href}\n            isActive={link.label === activeLabel}\n            onClick={() => onNavigate?.(link.label)}\n          >\n            {showsIcons && <NavLinkIcon icon={link.icon} />}\n            {link.label}\n          </MobileNavLink>\n        </li>\n      ))}\n    </ul>\n  );\n}\n\nfunction MobileNavHeading({ children }: { children: React.ReactNode }) {\n  return <div className={MENU_LABEL}>{children}</div>;\n}\n\nfunction MobileNavSeparator() {\n  return (\n    <div\n      role='separator'\n      aria-orientation='horizontal'\n      className={MENU_SEPARATOR}\n    />\n  );\n}\n\nexport {\n  MobileNav,\n  MobileNavHeading,\n  MobileNavLink,\n  MobileNavLinks,\n  MobileNavSeparator,\n};\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/mobile-nav.tsx"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/morphing-label.tsx",
      "content": "'use client';\n\nimport {\n  AnimatePresence,\n  motion,\n  type Transition,\n  type Variants,\n} from 'motion/react';\n\nimport { usePrefersReducedMotion } from '@/registry/ndeko/hooks/use-prefers-reduced-motion';\nimport { cn } from '@/registry/ndeko/lib/utils';\nimport { AnimatedSize } from '@/registry/ndeko/ui/animated-size';\n\nconst SWAP_TRANSITION: Transition = { duration: 0.15, ease: [0.2, 0, 0, 1] };\nconst EXIT_TRANSITION: Transition = { duration: 0.1, ease: [0.2, 0, 0, 1] };\n\nconst LABEL_VARIANTS: Variants = {\n  enter: { opacity: 0, filter: 'blur(2px)' },\n  visible: { opacity: 1, filter: 'blur(0px)' },\n  exit: { opacity: 0, filter: 'blur(2px)', transition: EXIT_TRANSITION },\n};\n\nconst FADE_VARIANTS: Variants = {\n  enter: { opacity: 0 },\n  visible: { opacity: 1 },\n  exit: { opacity: 0, transition: EXIT_TRANSITION },\n};\n\nfunction labelVariantsOf(shouldReduceMotion: boolean | null) {\n  if (shouldReduceMotion) {\n    return FADE_VARIANTS;\n  }\n  return LABEL_VARIANTS;\n}\n\ntype MorphingLabelProps = {\n  value: string;\n  className?: string;\n  children: React.ReactNode;\n};\n\nfunction MorphingLabel({ value, className, children }: MorphingLabelProps) {\n  const shouldReduceMotion = usePrefersReducedMotion();\n  const labelVariants = labelVariantsOf(shouldReduceMotion);\n\n  return (\n    <AnimatedSize as='span' axis='width' contentClassName='relative flex'>\n      <AnimatePresence mode='popLayout' initial={false}>\n        <motion.span\n          key={value}\n          className={cn('flex whitespace-nowrap', className)}\n          variants={labelVariants}\n          initial='enter'\n          animate='visible'\n          exit='exit'\n          transition={SWAP_TRANSITION}\n        >\n          {children}\n        </motion.span>\n      </AnimatePresence>\n    </AnimatedSize>\n  );\n}\n\nexport { MorphingLabel };\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/morphing-label.tsx"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/nav-links.tsx",
      "content": "'use client';\n\nimport { LayoutGroup, motion, type Transition } from 'motion/react';\nimport { useId } from 'react';\n\nimport { usePrefersReducedMotion } from '@/registry/ndeko/hooks/use-prefers-reduced-motion';\nimport type { Icon } from '@/registry/ndeko/lib/icons';\nimport { cn } from '@/registry/ndeko/lib/utils';\nimport {\n  NavigationMenu,\n  NavigationMenuItem,\n  NavigationMenuLink,\n  NavigationMenuList,\n} from '@/registry/ndeko/ui/navigation-menu';\nimport {\n  TOOLTIP_GLIDE_CLOSE_DELAY,\n  Tooltip,\n  TooltipContent,\n  type TooltipHandle,\n  TooltipProvider,\n  TooltipTrigger,\n  useTooltipHandle,\n} from '@/registry/ndeko/ui/tooltip';\n\ntype NavLinkItem = { label: string; href: string; icon?: Icon };\n\ntype NavIndicator = 'pill' | 'underline';\n\ntype NavLinkDisplay = 'label' | 'icon-label' | 'icon';\n\nconst SLIDE_TRANSITION: Transition = {\n  type: 'spring',\n  bounce: 0,\n  duration: 0.3,\n};\nconst INSTANT_TRANSITION: Transition = { duration: 0 };\n\nconst LINK_BASE =\n  'relative flex-row items-center gap-2 py-0 font-medium text-muted-foreground hover:bg-transparent hover:text-foreground data-active:bg-transparent data-active:text-foreground';\n\nconst LINK_SHAPE: Record<NavIndicator, string> = {\n  pill: 'h-8 rounded-md px-3',\n  underline: 'h-full rounded-sm px-0.5',\n};\n\nconst ICON_ONLY_SHAPE = 'size-8 justify-center px-0';\n\nconst LIST_CLASS: Record<NavIndicator, string> = {\n  pill: 'gap-1',\n  underline: 'h-full gap-6',\n};\n\nconst ITEM_CLASS: Record<NavIndicator, string> = {\n  pill: '',\n  underline: 'h-full',\n};\n\nconst INDICATOR_CLASS: Record<NavIndicator, string> = {\n  pill: 'absolute inset-0 rounded-md bg-foreground/[0.06] dark:bg-foreground/10',\n  underline: 'absolute inset-x-0 bottom-0 h-0.5 rounded-full bg-primary',\n};\n\nfunction slideTransitionOf(shouldReduceMotion: boolean | null) {\n  if (shouldReduceMotion) {\n    return INSTANT_TRANSITION;\n  }\n  return SLIDE_TRANSITION;\n}\n\nfunction isPlaceholderHref(href: string) {\n  return href === '#';\n}\n\nfunction NavLinkIcon({ icon: LinkIcon }: { icon?: Icon }) {\n  if (!LinkIcon) {\n    return null;\n  }\n  return <LinkIcon className='size-4' />;\n}\n\ntype NavLinksItemProps = {\n  link: NavLinkItem;\n  isActive: boolean;\n  indicator: NavIndicator;\n  display: NavLinkDisplay;\n  transition: Transition;\n  linkHint: TooltipHandle<string>;\n  onFollow: (\n    event: React.MouseEvent<HTMLAnchorElement>,\n    link: NavLinkItem\n  ) => void;\n};\n\nfunction NavLinksItem({\n  link,\n  isActive,\n  indicator,\n  display,\n  transition,\n  linkHint,\n  onFollow,\n}: NavLinksItemProps) {\n  const isIconOnly = display === 'icon';\n  const showsIcon = display !== 'label';\n  const linkClassName = cn(\n    LINK_BASE,\n    LINK_SHAPE[indicator],\n    isIconOnly && ICON_ONLY_SHAPE\n  );\n\n  function follow(event: React.MouseEvent<HTMLAnchorElement>) {\n    onFollow(event, link);\n  }\n\n  const content = (\n    <>\n      {isActive && (\n        <motion.span\n          layoutId='active-link-indicator'\n          transition={transition}\n          className={INDICATOR_CLASS[indicator]}\n        />\n      )}\n      <span className='relative flex items-center gap-2'>\n        {showsIcon && <NavLinkIcon icon={link.icon} />}\n        {isIconOnly && <span className='sr-only'>{link.label}</span>}\n        {!isIconOnly && link.label}\n      </span>\n    </>\n  );\n\n  if (isIconOnly) {\n    return (\n      <NavigationMenuItem className={ITEM_CLASS[indicator]}>\n        <TooltipTrigger\n          handle={linkHint}\n          payload={link.label}\n          closeDelay={TOOLTIP_GLIDE_CLOSE_DELAY}\n          render={\n            <NavigationMenuLink\n              href={link.href}\n              active={isActive}\n              onClick={follow}\n              className={linkClassName}\n            />\n          }\n        >\n          {content}\n        </TooltipTrigger>\n      </NavigationMenuItem>\n    );\n  }\n\n  return (\n    <NavigationMenuItem className={ITEM_CLASS[indicator]}>\n      <NavigationMenuLink\n        href={link.href}\n        active={isActive}\n        onClick={follow}\n        className={linkClassName}\n      >\n        {content}\n      </NavigationMenuLink>\n    </NavigationMenuItem>\n  );\n}\n\ntype NavLinksProps = {\n  links: NavLinkItem[];\n  activeLabel?: string;\n  onNavigate: (label: string) => void;\n  indicator?: NavIndicator;\n  display?: NavLinkDisplay;\n  className?: string;\n};\n\nfunction NavLinks({\n  links,\n  activeLabel,\n  onNavigate,\n  indicator = 'pill',\n  display = 'label',\n  className,\n}: NavLinksProps) {\n  const groupId = useId();\n  const shouldReduceMotion = usePrefersReducedMotion();\n  const transition = slideTransitionOf(shouldReduceMotion);\n  const isUnderline = indicator === 'underline';\n  const isIconOnly = display === 'icon';\n  const linkHint = useTooltipHandle<string>();\n\n  function followLink(\n    event: React.MouseEvent<HTMLAnchorElement>,\n    link: NavLinkItem\n  ) {\n    if (isPlaceholderHref(link.href)) {\n      event.preventDefault();\n    }\n    onNavigate(link.label);\n  }\n\n  return (\n    <LayoutGroup id={groupId}>\n      <TooltipProvider>\n        <NavigationMenu\n          aria-label='Main'\n          className={cn(isUnderline && 'h-full', className)}\n        >\n          <NavigationMenuList className={LIST_CLASS[indicator]}>\n            {links.map((link) => (\n              <NavLinksItem\n                key={link.label}\n                link={link}\n                isActive={link.label === activeLabel}\n                indicator={indicator}\n                display={display}\n                transition={transition}\n                linkHint={linkHint}\n                onFollow={followLink}\n              />\n            ))}\n          </NavigationMenuList>\n        </NavigationMenu>\n        {isIconOnly && (\n          <Tooltip handle={linkHint}>\n            {({ payload }) => (\n              <TooltipContent glide side='bottom'>\n                {payload}\n              </TooltipContent>\n            )}\n          </Tooltip>\n        )}\n      </TooltipProvider>\n    </LayoutGroup>\n  );\n}\n\nexport {\n  NavLinkIcon,\n  NavLinks,\n  isPlaceholderHref,\n  type NavIndicator,\n  type NavLinkDisplay,\n  type NavLinkItem,\n};\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/nav-links.tsx"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/notification-menu.tsx",
      "content": "'use client';\n\nimport {\n  AnimatePresence,\n  motion,\n  type Transition,\n  type Variants,\n} from 'motion/react';\nimport { useState } from 'react';\n\nimport { usePrefersReducedMotion } from '@/registry/ndeko/hooks/use-prefers-reduced-motion';\nimport { BellIcon } from '@/registry/ndeko/lib/icons';\nimport { Button } from '@/registry/ndeko/ui/button';\nimport {\n  Popover,\n  PopoverContent,\n  PopoverTitle,\n  PopoverTrigger,\n} from '@/registry/ndeko/ui/popover';\n\ntype Notification = {\n  id: number;\n  user: string;\n  action: string;\n  target: string;\n  timestamp: string;\n  isUnread: boolean;\n};\n\nconst INITIAL_NOTIFICATIONS: Notification[] = [\n  {\n    id: 1,\n    user: 'Chris Tompson',\n    action: 'requested review on',\n    target: 'PR #42: Feature implementation',\n    timestamp: '15 minutes ago',\n    isUnread: true,\n  },\n  {\n    id: 2,\n    user: 'Emma Davis',\n    action: 'shared',\n    target: 'New component library',\n    timestamp: '45 minutes ago',\n    isUnread: true,\n  },\n  {\n    id: 3,\n    user: 'James Wilson',\n    action: 'assigned you to',\n    target: 'API integration task',\n    timestamp: '4 hours ago',\n    isUnread: false,\n  },\n  {\n    id: 4,\n    user: 'Alex Morgan',\n    action: 'replied to your comment in',\n    target: 'Authentication flow',\n    timestamp: '12 hours ago',\n    isUnread: false,\n  },\n  {\n    id: 5,\n    user: 'Sarah Chen',\n    action: 'commented on',\n    target: 'Dashboard redesign',\n    timestamp: '2 days ago',\n    isUnread: false,\n  },\n  {\n    id: 6,\n    user: 'Noah Patel',\n    action: 'mentioned you in',\n    target: 'Launch page open graph image',\n    timestamp: '2 weeks ago',\n    isUnread: false,\n  },\n];\n\nconst SWAP_TRANSITION: Transition = { duration: 0.15, ease: [0.2, 0, 0, 1] };\nconst EXIT_TRANSITION: Transition = { duration: 0.1, ease: [0.2, 0, 0, 1] };\n\nconst POP_VARIANTS: Variants = {\n  enter: { opacity: 0, scale: 0.6, filter: 'blur(2px)' },\n  visible: { opacity: 1, scale: 1, filter: 'blur(0px)' },\n  exit: {\n    opacity: 0,\n    scale: 0.6,\n    filter: 'blur(2px)',\n    transition: EXIT_TRANSITION,\n  },\n};\n\nconst FADE_VARIANTS: Variants = {\n  enter: { opacity: 0 },\n  visible: { opacity: 1 },\n  exit: { opacity: 0, transition: EXIT_TRANSITION },\n};\n\nfunction popVariantsOf(shouldReduceMotion: boolean | null) {\n  if (shouldReduceMotion) {\n    return FADE_VARIANTS;\n  }\n  return POP_VARIANTS;\n}\n\nfunction notificationsLabelOf(unreadCount: number) {\n  if (unreadCount === 0) {\n    return 'Open notifications';\n  }\n  if (unreadCount === 1) {\n    return 'Open notifications, 1 unread';\n  }\n  return `Open notifications, ${unreadCount} unread`;\n}\n\nfunction markAsRead(notification: Notification) {\n  return { ...notification, isUnread: false };\n}\n\nfunction NotificationMenu() {\n  const [notifications, setNotifications] = useState(INITIAL_NOTIFICATIONS);\n  const shouldReduceMotion = usePrefersReducedMotion();\n  const popVariants = popVariantsOf(shouldReduceMotion);\n  const unreadCount = notifications.filter(\n    (notification) => notification.isUnread\n  ).length;\n  const hasUnread = unreadCount > 0;\n\n  function markAllAsRead() {\n    setNotifications((current) => current.map(markAsRead));\n  }\n\n  function markOneAsRead(id: number) {\n    setNotifications((current) =>\n      current.map((notification) => {\n        if (notification.id !== id) {\n          return notification;\n        }\n        return markAsRead(notification);\n      })\n    );\n  }\n\n  return (\n    <Popover>\n      <PopoverTrigger\n        render={\n          <Button\n            variant='ghost'\n            size='icon'\n            aria-label={notificationsLabelOf(unreadCount)}\n            className='text-muted-foreground'\n          />\n        }\n      >\n        <BellIcon />\n        <AnimatePresence initial={false}>\n          {hasUnread && (\n            <motion.span\n              key='unread-dot'\n              aria-hidden='true'\n              className='bg-primary absolute top-1.5 right-1.5 size-1.5 rounded-full'\n              variants={popVariants}\n              initial='enter'\n              animate='visible'\n              exit='exit'\n              transition={SWAP_TRANSITION}\n            />\n          )}\n        </AnimatePresence>\n      </PopoverTrigger>\n      <PopoverContent align='end' className='w-80 p-1'>\n        <div className='flex items-baseline justify-between gap-4 px-3 py-2'>\n          <PopoverTitle>Notifications</PopoverTitle>\n          <Button\n            variant='link'\n            size='sm'\n            onClick={markAllAsRead}\n            disabled={!hasUnread}\n            focusableWhenDisabled\n            className='h-auto p-0 text-xs'\n          >\n            Mark all as read\n          </Button>\n        </div>\n        <ul className='flex flex-col'>\n          {notifications.map((notification) => (\n            <li\n              key={notification.id}\n              className='has-focus-visible:bg-foreground/5 hover:bg-foreground/5 relative flex items-start gap-3 rounded-md px-3 py-2 transition-colors duration-150'\n            >\n              <div className='flex min-w-0 flex-1 flex-col gap-1'>\n                <button\n                  type='button'\n                  onClick={() => markOneAsRead(notification.id)}\n                  className='text-muted-foreground text-left outline-none after:absolute after:inset-0'\n                >\n                  <span className='text-foreground font-medium'>\n                    {notification.user}\n                  </span>{' '}\n                  {notification.action}{' '}\n                  <span className='text-foreground font-medium'>\n                    {notification.target}\n                  </span>\n                  .\n                </button>\n                <span className='text-muted-foreground text-xs'>\n                  {notification.timestamp}\n                </span>\n              </div>\n              <span className='flex size-1.5 shrink-0 self-center'>\n                <AnimatePresence initial={false}>\n                  {notification.isUnread && (\n                    <motion.span\n                      key='unread'\n                      className='bg-primary size-1.5 rounded-full'\n                      variants={popVariants}\n                      initial='enter'\n                      animate='visible'\n                      exit='exit'\n                      transition={SWAP_TRANSITION}\n                    >\n                      <span className='sr-only'>Unread</span>\n                    </motion.span>\n                  )}\n                </AnimatePresence>\n              </span>\n            </li>\n          ))}\n        </ul>\n      </PopoverContent>\n    </Popover>\n  );\n}\n\nexport { NotificationMenu };\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/notification-menu.tsx"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/team-switcher.tsx",
      "content": "'use client';\n\nimport { useState } from 'react';\n\nimport { MorphingLabel } from '@/registry/ndeko/components/navbar/_parts/morphing-label';\nimport { ChevronsUpDownIcon } from '@/registry/ndeko/lib/icons';\nimport { Button } from '@/registry/ndeko/ui/button';\nimport { CompanyMark } from '@/registry/ndeko/ui/company-mark';\nimport {\n  DropdownMenu,\n  DropdownMenuContent,\n  DropdownMenuRadioGroup,\n  DropdownMenuRadioItem,\n  DropdownMenuTrigger,\n} from '@/registry/ndeko/ui/dropdown-menu';\n\nfunction TeamMark({ team }: { team: string }) {\n  return <CompanyMark seed={team} className='size-6 rounded-md' />;\n}\n\ntype TeamSwitcherProps = {\n  teams: string[];\n  defaultTeam: string;\n};\n\nfunction TeamSwitcher({ teams, defaultTeam }: TeamSwitcherProps) {\n  const [selectedTeam, setSelectedTeam] = useState(defaultTeam);\n\n  function selectTeam(team: string) {\n    setSelectedTeam(team);\n  }\n\n  return (\n    <DropdownMenu>\n      <DropdownMenuTrigger\n        render={<Button variant='ghost' className='gap-2 px-1.5' />}\n      >\n        <TeamMark team={selectedTeam} />\n        <MorphingLabel value={selectedTeam}>{selectedTeam}</MorphingLabel>\n        <ChevronsUpDownIcon className='text-muted-foreground size-3.5' />\n      </DropdownMenuTrigger>\n      <DropdownMenuContent>\n        <DropdownMenuRadioGroup value={selectedTeam} onValueChange={selectTeam}>\n          {teams.map((team) => (\n            <DropdownMenuRadioItem key={team} value={team} closeOnClick>\n              <TeamMark team={team} />\n              {team}\n            </DropdownMenuRadioItem>\n          ))}\n        </DropdownMenuRadioGroup>\n      </DropdownMenuContent>\n    </DropdownMenu>\n  );\n}\n\nexport { TeamSwitcher };\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/team-switcher.tsx"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/use-active-link.ts",
      "content": "import { useState } from 'react';\n\nfunction useActiveLink(initialLabel?: string) {\n  const [activeLabel, setActiveLabel] = useState(initialLabel);\n\n  function navigate(label: string) {\n    setActiveLabel(label);\n  }\n\n  return { activeLabel, navigate };\n}\n\nexport { useActiveLink };\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/use-active-link.ts"
    },
    {
      "path": "registry/ndeko/components/navbar/_parts/user-menu.tsx",
      "content": "import {\n  BoltIcon,\n  BookOpenIcon,\n  Layers2Icon,\n  LogOutIcon,\n  PinIcon,\n  UserPenIcon,\n} from '@/registry/ndeko/lib/icons';\nimport { Avatar } from '@/registry/ndeko/ui/avatar';\nimport { Button } from '@/registry/ndeko/ui/button';\nimport {\n  DropdownMenu,\n  DropdownMenuContent,\n  DropdownMenuGroup,\n  DropdownMenuItem,\n  DropdownMenuLabel,\n  DropdownMenuSeparator,\n  DropdownMenuTrigger,\n} from '@/registry/ndeko/ui/dropdown-menu';\n\nfunction UserMenu() {\n  return (\n    <DropdownMenu>\n      <DropdownMenuTrigger\n        render={\n          <Button\n            variant='ghost'\n            size='icon'\n            aria-label='Open account menu'\n            className='rounded-full hover:bg-transparent'\n          />\n        }\n      >\n        <Avatar seed='Keith Kennedy' />\n      </DropdownMenuTrigger>\n      <DropdownMenuContent align='end' className='max-w-64'>\n        <DropdownMenuLabel className='flex min-w-0 flex-col gap-0.5'>\n          <span className='text-foreground truncate text-[13px]'>\n            Keith Kennedy\n          </span>\n          <span className='truncate font-normal'>\n            keith.kennedy@example.com\n          </span>\n        </DropdownMenuLabel>\n        <DropdownMenuSeparator />\n        <DropdownMenuGroup>\n          <DropdownMenuItem>\n            <BoltIcon />\n            Preferences\n          </DropdownMenuItem>\n          <DropdownMenuItem>\n            <Layers2Icon />\n            Workspaces\n          </DropdownMenuItem>\n          <DropdownMenuItem>\n            <BookOpenIcon />\n            Documentation\n          </DropdownMenuItem>\n        </DropdownMenuGroup>\n        <DropdownMenuSeparator />\n        <DropdownMenuGroup>\n          <DropdownMenuItem>\n            <PinIcon />\n            Pinned items\n          </DropdownMenuItem>\n          <DropdownMenuItem>\n            <UserPenIcon />\n            Edit profile\n          </DropdownMenuItem>\n        </DropdownMenuGroup>\n        <DropdownMenuSeparator />\n        <DropdownMenuItem>\n          <LogOutIcon />\n          Log out\n        </DropdownMenuItem>\n      </DropdownMenuContent>\n    </DropdownMenu>\n  );\n}\n\nexport { UserMenu };\n",
      "type": "registry:component",
      "target": "components/navbar/_parts/user-menu.tsx"
    }
  ],
  "categories": [
    "components",
    "navbar"
  ],
  "type": "registry:component"
}