diff --git a/src/components/activity/ActivityNameCombobox.tsx b/src/components/activity/ActivityNameCombobox.tsx index 77d24f2..01e2eaa 100644 --- a/src/components/activity/ActivityNameCombobox.tsx +++ b/src/components/activity/ActivityNameCombobox.tsx @@ -1,6 +1,5 @@ import * as React from "react"; -import { ChevronsUpDown, Check } from "lucide-react"; -import { Button } from "@/components/ui/button"; +import { ChevronDown, Check } from "lucide-react"; import { Command, CommandEmpty, @@ -14,15 +13,25 @@ import { PopoverContent, PopoverTrigger, } from "@/components/ui/popover"; +import { selectTriggerClassName } from "@/components/ui/select"; import { cn } from "@/lib/utils"; type ActivityNameComboboxProps = { activities: any[]; value: string; onChange: (value: string) => void; + className?: string; }; -export function ActivityNameCombobox({ activities, value, onChange }: ActivityNameComboboxProps) { +/** Stays a combobox rather than a Select because the name list grows with the + * activity log and needs the search box. The trigger borrows the Select + * styling so it reads as the same control as the status and type dropdowns. */ +export function ActivityNameCombobox({ + activities, + value, + onChange, + className, +}: ActivityNameComboboxProps) { // Collect unique names from repositoryName and organizationName const names = React.useMemo(() => { const set = new Set(); @@ -34,25 +43,30 @@ export function ActivityNameCombobox({ activities, value, onChange }: ActivityNa }, [activities]); const [open, setOpen] = React.useState(false); + return ( + {/* The button stays inline: PopoverTrigger asChild clones its child to + attach the click handler and ref, which a wrapper component would + swallow unless it forwarded both. */} - + + - + @@ -66,7 +80,12 @@ export function ActivityNameCombobox({ activities, value, onChange }: ActivityNa setOpen(false); }} > - + All names {names.map((name) => ( @@ -78,7 +97,12 @@ export function ActivityNameCombobox({ activities, value, onChange }: ActivityNa setOpen(false); }} > - + {name} ))} diff --git a/src/components/organizations/Organization.tsx b/src/components/organizations/Organization.tsx index 12c15e3..ce23411 100644 --- a/src/components/organizations/Organization.tsx +++ b/src/components/organizations/Organization.tsx @@ -490,9 +490,9 @@ export function Organization() { return (
{/* Search and filters */} -
+
{/* Mobile: Search bar with filter button */} -
+
{/* Desktop: Original layout */} -
+
+
{/* Search and filters */}
{/* Mobile: Search bar with filter button */} -
+
{/* Desktop: Original layout */} -
+
0 && ( -
+
{selectedRepoIds.size} selected @@ -1430,7 +1430,7 @@ export default function Repository() { {/* Action buttons for mobile - only show when items are selected */} {selectedRepoIds.size > 0 && ( -
+
{selectedRepoIds.size} selected @@ -1552,7 +1552,6 @@ export default function Repository() { {value || emptyLabel} diff --git a/src/components/repositories/RepositoryTable.tsx b/src/components/repositories/RepositoryTable.tsx index f577157..868581a 100644 --- a/src/components/repositories/RepositoryTable.tsx +++ b/src/components/repositories/RepositoryTable.tsx @@ -65,7 +65,6 @@ export const REPOSITORY_SORT_OPTIONS = [ interface RepositoryTableProps { repositories: Repository[]; isLoading: boolean; - isLiveActive?: boolean; filter: FilterParams; setFilter: (filter: FilterParams) => void; onMirror: ({ repoId }: { repoId: string }) => Promise; @@ -108,7 +107,6 @@ function getTableSorting(sortOrder: string | undefined): SortingState { export default function RepositoryTable({ repositories, isLoading, - isLiveActive = false, filter, setFilter, onMirror, @@ -684,38 +682,35 @@ export default function RepositoryTable({ /* Sits above the table in both the loading and loaded states so the controls do not appear and disappear as data arrives. */ const filterRow = ( -
+
+ + {hasAnyFilter + ? `Showing ${visibleRepositories.length} of ${repositories.length} repositories` + : `${repositories.length} ${ + repositories.length === 1 ? "repository" : "repositories" + }`} + {hasAnyFilter && ( - <> - - Showing {visibleRepositories.length} of {repositories.length} repositories - - - + )}
-
+