Skip to content

Commit 4fc2ff1

Browse files
authored
Merge pull request #157 from starlight-dari/main
feat: 챗봇 멘트 다르게 설정
2 parents 4ed09b3 + 58ab08a commit 4fc2ff1

3 files changed

Lines changed: 26 additions & 11 deletions

File tree

src/components/chatbot/chatbotAlive.tsx

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,18 @@ const aliveQuestions = [
2020
];
2121

2222
const ChatbotModalAlive = ({ onClose }: { onClose: () => void }) => {
23-
return <ChatbotModalTemplate questions={aliveQuestions} onClose={onClose} />;
23+
const introMessage = `💬 안녕하세요! 별빛다리 AI챗봇입니다. 반려 친구가 지금 함께하고 있다니 정말 다행이에요.
24+
건강하고 행복한 시간을 오래도록 이어가실 수 있도록
25+
🐶 펫 보험 정보와
26+
🐾 노령견/노묘를 위한 전문 관리 정보를 안내해드릴게요.
27+
궁금한 주제를 선택해주세요!`;
28+
return (
29+
<ChatbotModalTemplate
30+
questions={aliveQuestions}
31+
onClose={onClose}
32+
introMessage={introMessage}
33+
/>
34+
);
2435
};
2536

2637
export default ChatbotModalAlive;

src/components/chatbot/chatbotNotAlive.tsx

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,18 @@ const notAliveQuestions = [
1717
];
1818

1919
const ChatbotModalNotAlive = ({ onClose }: { onClose: () => void }) => {
20+
const introMessage = `💬 안녕하세요! 별빛다리 AI챗봇입니다.
21+
먼저 소중한 반려 친구의 이별에 깊은 위로를 전합니다.
22+
지금은 많이 힘드실 수 있지만, 저희가 함께하겠습니다.
23+
🕊 장례식장 정보와
24+
💛 펫로스 증후군 극복 프로그램을 안내해드릴게요.
25+
도움이 필요한 항목을 선택해주세요. 언제나 곁에 있겠습니다.`;
2026
return (
21-
<ChatbotModalTemplate questions={notAliveQuestions} onClose={onClose} />
27+
<ChatbotModalTemplate
28+
questions={notAliveQuestions}
29+
onClose={onClose}
30+
introMessage={introMessage}
31+
/>
2232
);
2333
};
2434

src/components/chatbot/chatbotTemplate.tsx

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,11 @@ interface QuestionData {
1515
const ChatbotModalTemplate = ({
1616
questions,
1717
onClose,
18+
introMessage,
1819
}: {
1920
questions: QuestionData[];
2021
onClose: () => void;
22+
introMessage: string;
2123
}) => {
2224
const server_url = process.env.NEXT_PUBLIC_SERVER_URL;
2325
const [question, setQuestion] = useState<string>("");
@@ -130,15 +132,7 @@ const ChatbotModalTemplate = ({
130132
<ChatWindow ref={chatWindowRef}>
131133
{category === null && (
132134
<>
133-
<IntroText>
134-
안녕하세요! 별빛다리 AI챗봇입니다.
135-
<br />
136-
장례식장, 펫로스증후군 극복 프로그램, 펫 보험, 노령견/노묘 전문
137-
정보에 대해 무엇이든 물어보세요. 최선을 다해 답변해드릴게요.
138-
<br />
139-
<br />
140-
카테고리를 선택해주세요.
141-
</IntroText>
135+
<IntroText>{introMessage}</IntroText>
142136
{questions.map((q) => (
143137
<CategoryButton
144138
key={q.id}

0 commit comments

Comments
 (0)