mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
### What problem does this PR solve? feat: add OperateDropdown feat: send debug message #918 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -64,7 +64,7 @@ export const useSetFlow = () => {
|
||||
);
|
||||
queryClient.invalidateQueries({ queryKey: ['fetchFlowList'] });
|
||||
}
|
||||
return data?.retcode;
|
||||
return data;
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
@ -206,14 +206,14 @@ export const useSendMessageWithSse = (
|
||||
|
||||
//#region chat hooks
|
||||
|
||||
export const useScrollToBottom = (id?: string) => {
|
||||
export const useScrollToBottom = (messages?: unknown) => {
|
||||
const ref = useRef<HTMLDivElement>(null);
|
||||
|
||||
const scrollToBottom = useCallback(() => {
|
||||
if (id) {
|
||||
if (messages) {
|
||||
ref.current?.scrollIntoView({ behavior: 'instant' });
|
||||
}
|
||||
}, [id]);
|
||||
}, [messages]); // If the message changes, scroll to the bottom
|
||||
|
||||
useEffect(() => {
|
||||
scrollToBottom();
|
||||
|
||||
Reference in New Issue
Block a user