mirror of
https://github.com/ItzCrazyKns/Perplexica.git
synced 2025-06-19 16:28:42 +00:00
Compare commits
2 Commits
060c68a900
...
64d2a467b0
Author | SHA1 | Date | |
---|---|---|---|
64d2a467b0 | |||
9a2c4fe3b6 |
@ -48,11 +48,17 @@ const Chat = ({
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
const scroll = () => {
|
||||
messageEnd.current?.scrollIntoView({ behavior: 'smooth' });
|
||||
};
|
||||
|
||||
if (messages.length === 1) {
|
||||
document.title = `${messages[0].content.substring(0, 30)} - Perplexica`;
|
||||
}
|
||||
|
||||
if (messages[messages.length - 1]?.role == 'user') {
|
||||
scroll();
|
||||
}
|
||||
}, [messages]);
|
||||
|
||||
return (
|
||||
|
Reference in New Issue
Block a user