|
|
@ -332,7 +332,7 @@ export const useChatStore = create<ChatStore>()(
|
|
|
|
const isLastSession = get().sessions.length === 1;
|
|
|
|
const isLastSession = get().sessions.length === 1;
|
|
|
|
if (!isMobileScreen() || confirm(Locale.Home.DeleteChat)) {
|
|
|
|
if (!isMobileScreen() || confirm(Locale.Home.DeleteChat)) {
|
|
|
|
get().removeSession(index);
|
|
|
|
get().removeSession(index);
|
|
|
|
}
|
|
|
|
|
|
|
|
showToast(Locale.Home.DeleteToast, {
|
|
|
|
showToast(Locale.Home.DeleteToast, {
|
|
|
|
text: Locale.Home.Revert,
|
|
|
|
text: Locale.Home.Revert,
|
|
|
|
onClick() {
|
|
|
|
onClick() {
|
|
|
@ -344,6 +344,7 @@ export const useChatStore = create<ChatStore>()(
|
|
|
|
}));
|
|
|
|
}));
|
|
|
|
},
|
|
|
|
},
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
currentSession() {
|
|
|
|
currentSession() {
|
|
|
|