mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-02-13 21:14:24 +01:00
feat: gen title by sperate api call
feat: fix: rename of convo should based on real request.
This commit is contained in:
parent
8773878be2
commit
9f8e9cb091
8 changed files with 65 additions and 28 deletions
|
|
@ -11,7 +11,7 @@ import { incrementPage, setConvos } from '~/store/convoSlice';
|
|||
export default function Nav({ navVisible, setNavVisible }) {
|
||||
const dispatch = useDispatch();
|
||||
const [isHovering, setIsHovering] = useState(false);
|
||||
const { conversationId, convos, pageNumber } = useSelector((state) => state.convo);
|
||||
const { conversationId, convos, pageNumber, refreshConvoHint } = useSelector((state) => state.convo);
|
||||
const onSuccess = (data) => {
|
||||
dispatch(setConvos(data));
|
||||
};
|
||||
|
|
@ -20,6 +20,7 @@ export default function Nav({ navVisible, setNavVisible }) {
|
|||
`/api/convos?pageNumber=${pageNumber}`,
|
||||
onSuccess
|
||||
);
|
||||
|
||||
const containerRef = useRef(null);
|
||||
const scrollPositionRef = useRef(null);
|
||||
|
||||
|
|
@ -35,7 +36,7 @@ export default function Nav({ navVisible, setNavVisible }) {
|
|||
}
|
||||
};
|
||||
|
||||
useDidMountEffect(() => mutate(), [conversationId]);
|
||||
useDidMountEffect(() => mutate(), [conversationId, refreshConvoHint]);
|
||||
|
||||
useEffect(() => {
|
||||
const container = containerRef.current;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue