docs(sponsors): padding

This commit is contained in:
Stan Girard 2023-07-01 18:47:05 +02:00
parent b73493067b
commit 3df2613caf

View File

@ -34,10 +34,10 @@ export const ChatProvider = ({
(item) => item.message_id === streamedChat.message_id (item) => item.message_id === streamedChat.message_id
) )
? prevHistory.map((item: ChatHistory) => ? prevHistory.map((item: ChatHistory) =>
item.message_id === streamedChat.message_id item.message_id === streamedChat.message_id
? { ...item, assistant: item.assistant + streamedChat.assistant } ? { ...item, assistant: item.assistant + streamedChat.assistant }
: item : item
) )
: [...prevHistory, streamedChat]; : [...prevHistory, streamedChat];
console.log("updated history", updatedHistory); console.log("updated history", updatedHistory);
@ -52,10 +52,10 @@ export const ChatProvider = ({
(item) => item.message_id === chat.message_id (item) => item.message_id === chat.message_id
) )
? prevHistory.map((item: ChatHistory) => ? prevHistory.map((item: ChatHistory) =>
item.message_id === chat.message_id item.message_id === chat.message_id
? { ...item, assistant: chat.assistant } ? { ...item, assistant: chat.assistant }
: item : item
) )
: [...prevHistory, chat]; : [...prevHistory, chat];
return updatedHistory; return updatedHistory;