This commit is contained in:
Hamed
2026-08-03 12:25:44 +04:00
parent ee456ff4bb
commit 61e29cc149
4 changed files with 114 additions and 98 deletions
+2
View File
@@ -38,6 +38,8 @@ export default function ChatWidget() {
// import axios from 'axios';
// const { data } = await axios.post('/api/chat', { message: text });
// setMessages((prev) => [...prev, { from: 'bot', text: data.reply }]);
// api() <===> todo : use this func to fetch ...
// -----------------------------------------------------------------
setTimeout(() => {
setMessages((prev) => [...prev, { from: 'bot', text: t.chat.fallbackReply }]);