Skip to content

Commit f26f782

Browse files
committed
fix(challenges): improve input design
1 parent 8ebc44c commit f26f782

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

app/(app)/challenges/[id]/_components/ai-assistant.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -303,14 +303,14 @@ export function AIAssistant({ questionId }: AIAssistantProps) {
303303
onSubmit={handleSubmit}
304304
className="border-t bg-background p-4"
305305
>
306-
<div className="flex gap-2">
306+
<div className="flex items-center gap-2">
307307
<input
308308
type="text"
309309
value={input}
310310
onChange={(e) => setInput(e.target.value)}
311311
placeholder="輸入你的問題……"
312312
className={`
313-
flex-1 rounded-lg border bg-background px-4 py-2 text-sm
313+
flex-1 rounded-lg border bg-background px-4 py-1 text-sm
314314
transition-colors
315315
placeholder:text-muted-foreground
316316
focus:ring-2 focus:ring-ring focus:outline-hidden
@@ -323,9 +323,9 @@ export function AIAssistant({ questionId }: AIAssistantProps) {
323323
size="icon"
324324
disabled={!input.trim() || isLoading}
325325
>
326-
{isLoading ? <Loader2 className="h-4 w-4 animate-spin" /> : (
326+
{isLoading ? <Loader2 className="size-4 animate-spin" /> : (
327327
<Send
328-
className={`h-4 w-4`}
328+
className={`size-4`}
329329
/>
330330
)}
331331
<span className="sr-only">送出訊息</span>

0 commit comments

Comments
 (0)