"use client"; import { Button } from "@suphark/ui/components/shared/button/button"; import { SwitcherChevron } from "@suphark/ui/components/shared/switcher-chevron"; import { useUiText } from "@suphark/ui/components/shared/ui-text"; import { Command, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, } from "@suphark/ui/components/ui/command"; import { Popover, PopoverContent, PopoverTrigger } from "@suphark/ui/components/ui/popover"; import { commandContainsFilter } from "@suphark/ui/lib/command-filter"; import { cn } from "@suphark/ui/lib/utils"; import { Check } from "lucide-react"; import * as React from "react"; interface ComboboxProps { options: { label: string; value: string }[]; value: string; onSelect: (value: string) => void; placeholder?: string; searchPlaceholder?: string; emptyText?: string; /** แสดงเมื่อค้นไม่พบ — ชื่อเดียวกับ `emptyText` (ให้ตรงกับ SimpleTable/DataList/NotificationCenter) */ empty?: React.ReactNode; ariaLabel?: string; /** * id / aria-labelledby ของปุ่ม — มี (เช่น FormControl ส่ง id ให้ `