feat: 添加了滚动的标识方法

This commit is contained in:
zoujing 2025-08-27 20:34:16 +08:00
parent 0e51fdcd69
commit a366e259da

View File

@ -20,6 +20,8 @@
scroll-y
:scroll-with-animation="true"
class="area-msg-list"
@scroll="handleScroll"
@scrolltolower="handleScrollToLower"
>
<!-- welcome栏 -->
<ChatTopWelcome
@ -172,6 +174,9 @@ const isKeyboardShow = ref(false);
///
const scrollTop = ref(99999);
//
const isUserScrolling = ref(false);
///
const chatMsgList = ref([]);
///
@ -235,13 +240,21 @@ const handleKeyboardHide = () => {
holdKeyboard.value = false;
};
//
const handleScroll = (e) => {
//
};
//
const handleScrollToLower = () => {};
// -
const scrollToBottom = () => {
nextTick(() => {
scrollTop.value = 99999;
//
setTimeout(() => {
scrollTop.value = scrollTop.value + 1;
scrollTop.value = scrollTop.value + Math.random();
}, 10);
});
};
@ -526,14 +539,8 @@ const initTypewriterManager = () => {
typewriterManager.setCallbacks({
//
onCharacterTyped: (displayedContent) => {
//
nextTick(() => {
scrollTop.value = 99999;
//
setTimeout(() => {
scrollTop.value = 99999 + Math.random();
}, 20);
});
//
scrollToBottom();
},
//
onContentUpdate: (content) => {