mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-08-30 15:01:31 +00:00
feat: chat page stroboscopic bugfix
This commit is contained in:
parent
471689ba20
commit
0747835067
@ -72,15 +72,15 @@ const ChatCompletion: React.FC = () => {
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
scrollableRef.current?.scrollTo(0, scrollableRef.current?.scrollHeight);
|
scrollableRef.current?.scrollTo(0, scrollableRef.current?.scrollHeight);
|
||||||
}, 50);
|
}, 50);
|
||||||
}, [history]);
|
}, [history, history[history.length - 1].context]]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='flex flex-col w-5/6 mx-auto' ref={scrollableRef}>
|
<div className='flex flex-col w-5/6 mx-auto' ref={scrollableRef}>
|
||||||
{!!showMessages.length &&
|
{!!showMessages.length &&
|
||||||
showMessages.map(content => {
|
showMessages.map((content, index) => {
|
||||||
return (
|
return (
|
||||||
<ChatContent
|
<ChatContent
|
||||||
key={content.key}
|
key={index}
|
||||||
content={content}
|
content={content}
|
||||||
onLinkClick={() => {
|
onLinkClick={() => {
|
||||||
setJsonModalOpen(true);
|
setJsonModalOpen(true);
|
||||||
|
Loading…
Reference in New Issue
Block a user