fix: new chat don't jump chat in dontShowMask

This commit is contained in:
李秋炯
2023-04-29 13:45:12 +08:00
parent b0cd8579f1
commit 1afd181833

View File

@@ -91,8 +91,7 @@ export function SideBar(props: { className?: string }) {
return ( return (
<div <div
className={`${styles.sidebar} ${props.className} ${ className={`${styles.sidebar} ${props.className} ${shouldNarrow && styles["narrow-sidebar"]
shouldNarrow && styles["narrow-sidebar"]
}`} }`}
> >
<div className={styles["sidebar-header"]}> <div className={styles["sidebar-header"]}>
@@ -159,6 +158,7 @@ export function SideBar(props: { className?: string }) {
onClick={() => { onClick={() => {
if (config.dontShowMaskSplashScreen) { if (config.dontShowMaskSplashScreen) {
chatStore.newSession(); chatStore.newSession();
navigate(Path.Chat);
} else { } else {
navigate(Path.NewChat); navigate(Path.NewChat);
} }