Browse Source

修复一下滚动

hxl
hongxilin 2 months ago
parent
commit
67d2d3cee7
  1. 7
      src/views/homePage.vue

7
src/views/homePage.vue

@ -224,11 +224,13 @@ watch(
watch(
activeTab,
async () => {
// console.log('activeTab', activeTab.value)
console.log('activeTab变化了', activeTab.value)
if (activeTab.value === 'AIchat') {
isScrolling.value = false; //
setTimeout(() => {
throttledSmoothScrollToBottom();
}, 100)
}
// setTimeout(throttledSmoothScrollToBottom, 100);
},
{ deep: true, immediate: true }
@ -436,8 +438,11 @@ onMounted(async () => {
!isPhone &&
localStorage.setItem('localToken', decodeURIComponent(String(getQueryVariable('token'))))
setHeight(document.getElementById("testId")); //
//
await chatStore.getUserCount();
//
throttledSmoothScrollToBottom();
//
throttledHeightListener();
//

Loading…
Cancel
Save