fix : use thai text

This commit is contained in:
2026-09-25 17:27:33 +07:00 Unverified
parent 0a9a60ea0b
commit eedaa02724
+19 -11
View File
@@ -37,6 +37,14 @@ import {
import { cn } from "@/lib/utils";
type Team = PublicGuide["teams"][number];
const teamSearchTargetLabels: Record<TeamSearchTarget, string> = {
all: "ทั้งหมด",
team: "ชื่อทีม",
character: "ตัวละคร",
weapon: "อาวุธ",
artifact: "อาร์ติแฟกต์",
};
type TeamArtifact = {
key: string;
name: string;
@@ -420,6 +428,16 @@ export function TeamSearch({ groups }: { groups: PublicGuide["teamGroups"] }) {
) : null}
{activeGroup?.note ? <p className="whitespace-pre-wrap text-muted-foreground">{activeGroup.note}</p> : null}
<div className="flex min-w-0 items-center gap-2">
<div className="relative min-w-0 flex-1">
<SearchIcon aria-hidden="true" className="pointer-events-none absolute top-1/2 left-3 size-4 -translate-y-1/2 text-muted-foreground" />
<Input
aria-label="ค้นหาทีม ตัวละคร อาวุธ หรืออาร์ติแฟกต์"
className="pl-9"
placeholder="ค้นหาทีม ตัวละคร อาวุธ หรืออาร์ติแฟกต์"
value={query}
onValueChange={setQuery}
/>
</div>
<Select value={searchTarget} onValueChange={(value) => {
if (value) setSearchTarget(value as TeamSearchTarget);
}}>
@@ -427,7 +445,7 @@ export function TeamSearch({ groups }: { groups: PublicGuide["teamGroups"] }) {
aria-label="เลือกประเภทข้อมูลที่ต้องการค้นหา"
className="w-32 shrink-0"
>
<SelectValue />
<SelectValue>{teamSearchTargetLabels[searchTarget]}</SelectValue>
</SelectTrigger>
<SelectContent>
<SelectGroup>
@@ -439,16 +457,6 @@ export function TeamSearch({ groups }: { groups: PublicGuide["teamGroups"] }) {
</SelectGroup>
</SelectContent>
</Select>
<div className="relative min-w-0 flex-1">
<SearchIcon aria-hidden="true" className="pointer-events-none absolute top-1/2 left-3 size-4 -translate-y-1/2 text-muted-foreground" />
<Input
aria-label="ค้นหาทีม ตัวละคร อาวุธ หรืออาร์ติแฟกต์"
className="pl-9"
placeholder="ค้นหาทีม ตัวละคร อาวุธ หรืออาร์ติแฟกต์"
value={query}
onValueChange={setQuery}
/>
</div>
</div>
<div className="flex items-center gap-2">
<ToggleGroup