import { ChevronDownIcon, GitBranchIcon } from "lucide-react"; import { Suspense, type ReactNode } from "react"; import type { RepositoryContextPickerProps } from "./repository-picker"; import { REPOSITORY_PANEL_CLASS } from "./repository-picker-layout"; import { ComposerMenuRowsSkeleton, lazyComposerPanel } from "../../ui/composer-menu"; import { Button } from "../../ui/button"; import { DropdownMenu, DropdownMenuContent, DropdownMenuTrigger } from "../../ui/dropdown-menu"; import { repoCountLabel } from "../lib/format"; import { cn } from "../lib/utils"; type FollowUpRepositoryPickerProps = RepositoryContextPickerProps; const LazyFollowUpRepositoryMenuBody = lazyComposerPanel(() => import("./follow-up-repository-menu-body").then((module) => module.FollowUpRepositoryMenuBody), ); function selectedCount(props: FollowUpRepositoryPickerProps): number { return ( props.selectedRepoIds.size + (props.selectedPersonalGitHubRepoIds?.size ?? 0) + props.manualRepos.filter( (repository) => repository.attached !== false && repository.url.trim().length > 0, ).length ); } export function FollowUpRepositoryMenuBody( props: FollowUpRepositoryPickerProps & { leading?: ReactNode | undefined }, ) { return ( {props.leading} } > ); } export function FollowUpRepositoryPicker(props: FollowUpRepositoryPickerProps) { const count = selectedCount(props); return ( ); }