Skip to content

Commit f4a6ad7

Browse files
committed
fix: preserve default AI chat history behavior (#1181)
1 parent d9e120c commit f4a6ad7

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

‎frontend/src/components/article/ArticleChatPanel.vue‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ const boundArticle = ref<Article>({ ...props.article });
7676
const boundArticleContent = ref(props.articleContent);
7777
const rebindSession = ref(false);
7878
const articleMismatch = computed(() => props.article.id !== boundArticle.value.id);
79-
const saveHistory = computed(() => props.settings.ai_chat_save_history);
79+
const saveHistory = computed(() => props.settings.ai_chat_save_history !== false);
8080
8181
watch(
8282
() => props.articleContent,
@@ -800,7 +800,11 @@ const currentSessionTitle = computed(() => {
800800
<button
801801
class="p-1 hover:bg-bg-primary rounded"
802802
:title="editingSessionId === session.id ? t('common.cancel') : t('common.edit')"
803-
@click.stop="editingSessionId === session.id ? cancelEditSession() : startEditSession(session, $event)"
803+
@click.stop="
804+
editingSessionId === session.id
805+
? cancelEditSession()
806+
: startEditSession(session, $event)
807+
"
804808
>
805809
<PhX v-if="editingSessionId === session.id" :size="14" />
806810
<PhPencil v-else :size="14" />

0 commit comments

Comments
 (0)