Skip to content

Commit

Permalink
Rename /question page with ロボットAD
Browse files Browse the repository at this point in the history
  • Loading branch information
katsuma committed May 11, 2024
1 parent 1fd602a commit a13da8f
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 4 deletions.
5 changes: 5 additions & 0 deletions src/app/layout.css
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@
border-radius: var(--border-radius);
}

.section svg {
font-size: 1.8rem;
padding-top: 0.5rem;
}

.title {
display: inline-block;
margin-bottom: 1rem;
Expand Down
10 changes: 9 additions & 1 deletion src/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import Link from 'next/link';
import Image from 'next/image';
import React from 'react';
import { FaMicrophone } from "react-icons/fa";
import { LiaRobotSolid } from "react-icons/lia";

import '@/app/layout.css'
import prisma from '@/utils/prisma';
Expand Down Expand Up @@ -94,7 +96,13 @@ export default async function Home() {
<section className='section'>
<h2 className='title'>ポッドキャストの収録・編集環境</h2>
<p className={styles.description}>マイクやオーディオインターフェースなどの収録環境や、DAWやプラグインなど編集環境についてまとめてみました。</p>
<p className='link-more'><Link href='/podcasting-guide'>ポッドキャストの収録・編集環境を見る</Link></p>
<p className='link-more'><Link href='/podcasting-guide'><FaMicrophone />ポッドキャストの収録・編集環境を見る</Link></p>
</section>

<section className='section'>
<h2 className='title'>ロボットADへの質問</h2>
<p className={styles.description}>ロボットADが番組でこれまで話したエピソードをもとに質問に答えます。ADは見習いなので、たまにポンコツな回答もしますがご容赦ください。</p>
<p className='link-more'><Link href='/question'><LiaRobotSolid />ロボットADへ質問してみる</Link></p>
</section>
</>
)
Expand Down
8 changes: 5 additions & 3 deletions src/app/question/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,21 @@ export default function Page() {

return (
<section className='section' suppressHydrationWarning={true}>
<h2 className='title'>AIディレクターへの質問</h2>
<h2 className='title'>ロボットADへの質問</h2>
<div className={styles.messages}>
{messages.map((message) => (
<div key={message.id} className={styles.message}>
{
message.role === 'user' ?
<><FiSmile /><span>あなた</span></>:
<><RiRobot2Line /><span>AIディレクター</span></>
<><RiRobot2Line /><span>ロボットAD</span></>
}
<ReactMarkdown>{message.content}</ReactMarkdown>
</div>
))}
{isLoading && !isLastMessageFromAssistant(messages) &&
<div className={styles.message}>
<RiRobot2Line /><span>AIディレクター</span>
<RiRobot2Line /><span>ロボットAD</span>
<p><Comment height={32} width={32} backgroundColor="#676767" /></p>
</div>
}
Expand All @@ -45,6 +45,8 @@ export default function Page() {
/>
<button type="submit" className={styles.button}>質問</button>
</form>

<p>※ロボットADは見習いなのでたまにポンコツな回答もしますが、ご容赦ください。</p>
</div>
</section>
);
Expand Down
1 change: 1 addition & 0 deletions src/app/sitemap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ function getStaticPaths(): MetadataRoute.Sitemap {
return [
{ url: `${BASE_URL}/`, lastModified: new Date(), changeFrequency: 'weekly' },
{ url: `${BASE_URL}/podcasting-guide`, lastModified: new Date() },
{ url: `${BASE_URL}/question`, lastModified: new Date() },
];
};

Expand Down

0 comments on commit a13da8f

Please sign in to comment.