Skip to content

Commit 33776e4

Browse files
committed
fix design
1 parent 1ef4d5e commit 33776e4

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

components/Chat.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,22 +38,22 @@ const InputMessage = ({
3838
}}
3939
/>
4040
<Button
41-
className='flex-none ml-2'
41+
className='flex-none ml-1'
4242
onClick={() => {
4343
toggleSpeechRecognition();
4444
}}
4545
>
46-
{isListening ? "音声認識停止" : "音声認識開始"}
46+
{isListening ? "Voice Off" : "Voice On"}
4747
</Button>
4848
<Button
4949
type='submit'
50-
className='flex-none ml-4'
50+
className='flex-none ml-1'
5151
onClick={() => {
5252
sendMessage(input);
5353
setInput("");
5454
}}
5555
>
56-
Say
56+
Send
5757
</Button>
5858
</div>
5959
);
@@ -178,9 +178,9 @@ export function Chat() {
178178
{loading && <LoadingChatLine />}
179179

180180
{messages.length < 2 && (
181-
<span className='flex flex-grow clear-both mx-auto text-gray-600'>
181+
<div className='m-4 text-gray-600'>
182182
Type a message to start the conversation
183-
</span>
183+
</div>
184184
)}
185185
<InputMessage
186186
input={input}

components/ChatLine.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,8 @@ export function ChatLine({ role = "assistant", content }: ChatGPTMessage) {
7070
<div className='px-4 py-5 mb-1 bg-white rounded-lg shadow-lg ring-1 ring-zinc-100 sm:px-6'>
7171
<div className='space-x-3'>
7272
<div className='gap-4'>
73-
<p className='text-gray-900 font-large text-xxl'>
74-
<a href='#' className='hover:underline'>
75-
{role == "assistant" ? "AI" : "You"}
76-
</a>
73+
<p className='font-semibold text-gray-900 font-large text-xxl'>
74+
{role == "assistant" ? "AI" : "You"}
7775
</p>
7876
<div
7977
className={clsx(

pages/index.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
1-
import { Layout, Page, Text } from "@vercel/examples-ui";
1+
import { Layout, Page } from "@vercel/examples-ui";
22
import { Chat } from "../components/Chat";
33

44
function Home() {
55
return (
66
<Page className='flex flex-col gap-12'>
77
<section className='flex flex-col gap-3'>
8-
<Text variant='h2'>AI Chat:</Text>
8+
<h1 className='block pl-1 text-sm font-semibold tracking-tight'>
9+
AI Chat:
10+
</h1>
911
<div className=''>
1012
<Chat />
1113
</div>

0 commit comments

Comments
 (0)