diff --git a/pages/search/[id].vue b/pages/search/[id].vue index 1ec51bf421fa1ae3c8c30bfe16cee1b0b3ee3204..6dfafff23022afcd129bf6b971843422635508af 100644 --- a/pages/search/[id].vue +++ b/pages/search/[id].vue @@ -74,9 +74,8 @@ function handleUpdateQuery(query) { // 是否停止自动滚动到底部 const isAutoToBottom = ref(true) watch(() => { - // console.log(`directions.top:`, directions.top) if (directions.top) { - isAutoToBottom.value = true + isAutoToBottom.value = false } }) const scrollToView = () => { @@ -143,9 +142,9 @@ const handleFormFetchData = (fetchData) => { if (Object.keys(message).length === 0) return const { meta, choices } = message const index = editIndex.value - if (isAutoToBottom.value) { + nextTick(() => { scrollToView() - } + }) // 处理报错信息 if (!meta) { handleStopGenerate()