mirror of
https://github.com/openclaw/openclaw.git
synced 2026-03-12 07:20:45 +00:00
fix: address review feedback — retryDelay uses effectiveForce, default overrides param, @state() on chatNewMessagesBelow
This commit is contained in:
@@ -11,7 +11,7 @@ function createScrollHost(overrides: {
|
||||
scrollTop?: number;
|
||||
clientHeight?: number;
|
||||
overflowY?: string;
|
||||
}) {
|
||||
} = {}) {
|
||||
const {
|
||||
scrollHeight = 2000,
|
||||
scrollTop = 1500,
|
||||
|
||||
@@ -64,7 +64,7 @@ export function scheduleChatScroll(host: ScrollHost, force = false) {
|
||||
target.scrollTop = target.scrollHeight;
|
||||
host.chatUserNearBottom = true;
|
||||
host.chatNewMessagesBelow = false;
|
||||
const retryDelay = force ? 150 : 120;
|
||||
const retryDelay = effectiveForce ? 150 : 120;
|
||||
host.chatScrollTimeout = window.setTimeout(() => {
|
||||
host.chatScrollTimeout = null;
|
||||
const latest = pickScrollTarget();
|
||||
|
||||
@@ -252,7 +252,7 @@ export class OpenClawApp extends LitElement {
|
||||
private chatScrollTimeout: number | null = null;
|
||||
private chatHasAutoScrolled = false;
|
||||
private chatUserNearBottom = true;
|
||||
chatNewMessagesBelow = false;
|
||||
@state() chatNewMessagesBelow = false;
|
||||
private nodesPollInterval: number | null = null;
|
||||
private logsPollInterval: number | null = null;
|
||||
private debugPollInterval: number | null = null;
|
||||
|
||||
Reference in New Issue
Block a user