fix(search): address code review feedback on colors, race conditions, and utilities

This commit is contained in:
yiling
2026-05-25 15:33:56 +08:00
parent 1a4721e769
commit 73cd87a261
5 changed files with 77 additions and 109 deletions
+6 -7
View File
@@ -1,13 +1,13 @@
import type { SearchSort } from '@/dtos/search'
import { type FieldInfo as MetadataFieldInfo } from '@/dtos/metadata'
import type { SearchSort } from '@/dtos/search'
import { Button } from '@/ui/components/ui/button'
import { Popover, PopoverContent, PopoverTrigger } from '@/ui/components/ui/popover'
import {
Select,
SelectContent,
SelectItem,
SelectTrigger,
SelectValue,
Select,
SelectContent,
SelectItem,
SelectTrigger,
SelectValue,
} from '@/ui/components/ui/select'
import { ArrowDownWideNarrow } from 'lucide-react'
@@ -79,7 +79,6 @@ export function SortControl({ fields, sort, onSortChange, disabled }: SortContro
className="h-8"
disabled={disabled}
>
<ArrowDownWideNarrow className="h-4 w-4 mr-1" />
{sort ? `Sorted by ${currentField.label}` : 'Sort by'}
</Button>
</PopoverTrigger>