resolve warnings and type errors
This commit is contained in:
6
src/components/server/ServerCreationPopup.tsx
Normal file → Executable file
6
src/components/server/ServerCreationPopup.tsx
Normal file → Executable file
@@ -78,15 +78,15 @@ export function ServerCreationPopup({
|
||||
setEntries((prev) => [...prev, newEntry]);
|
||||
}, []);
|
||||
|
||||
const scrollToBottom = () => {
|
||||
const scrollToBottom = useCallback(() => {
|
||||
if (consoleRef.current && !isMinimized && isConsoleVisible) {
|
||||
consoleRef.current.scrollTop = consoleRef.current.scrollHeight;
|
||||
}
|
||||
};
|
||||
}, [isMinimized, isConsoleVisible]);
|
||||
|
||||
useEffect(() => {
|
||||
scrollToBottom();
|
||||
}, [entries, isMinimized, isConsoleVisible]);
|
||||
}, [entries, scrollToBottom]);
|
||||
|
||||
useEffect(() => {
|
||||
if (serverId && isOpen) {
|
||||
|
||||
Reference in New Issue
Block a user