mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-01-16 07:25:31 +01:00
front and backend logic for model switching
This commit is contained in:
parent
a5afd5c48f
commit
c00a2c902b
9 changed files with 58 additions and 39 deletions
|
|
@ -1,7 +1,7 @@
|
|||
import React, { useEffect, useState, useRef } from 'react';
|
||||
import Message from './Message';
|
||||
import ScrollToBottom from './ScrollToBottom';
|
||||
import { CSSTransition } from 'react-transition-group';
|
||||
import ScrollToBottom from './ScrollToBottom';
|
||||
import Message from './Message';
|
||||
|
||||
const Messages = ({ messages }) => {
|
||||
const [showScrollButton, setShowScrollButton] = useState(false);
|
||||
|
|
@ -13,7 +13,7 @@ const Messages = ({ messages }) => {
|
|||
const scrollable = scrollableRef.current;
|
||||
const hasScrollbar = scrollable.scrollHeight > scrollable.clientHeight;
|
||||
setShowScrollButton(hasScrollbar);
|
||||
}, 850);
|
||||
}, 650);
|
||||
|
||||
return () => {
|
||||
clearTimeout(timeoutId);
|
||||
|
|
@ -69,7 +69,7 @@ const Messages = ({ messages }) => {
|
|||
))}
|
||||
<CSSTransition
|
||||
in={showScrollButton}
|
||||
timeout={650}
|
||||
timeout={400}
|
||||
classNames="scroll-down"
|
||||
unmountOnExit={false}
|
||||
appear
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue