feat(logs): refresh on reconnect and section activation

This commit is contained in:
hkfires
2025-11-21 10:59:21 +08:00
parent 323485445d
commit 608be95020
4 changed files with 40 additions and 11 deletions

5
app.js
View File

@@ -67,6 +67,7 @@ class CLIProxyManager {
// 状态更新定时器
this.statusUpdateTimer = null;
this.lastConnectionStatusEmitted = null;
// 日志自动刷新定时器
this.logsRefreshTimer = null;
@@ -150,6 +151,9 @@ class CLIProxyManager {
this.initializeTheme();
this.registerSettingsListeners();
this.registerUsageListeners();
if (typeof this.registerLogsListeners === 'function') {
this.registerLogsListeners();
}
if (typeof this.registerConfigEditorListeners === 'function') {
this.registerConfigEditorListeners();
}
@@ -164,7 +168,6 @@ class CLIProxyManager {
this.updateLoginConnectionInfo();
// 检查主机名,如果不是 localhost 或 127.0.0.1,则隐藏 OAuth 登录框
this.checkHostAndHideOAuth();
if (typeof this.registerAuthFilesListeners === 'function') {
this.registerAuthFilesListeners();
}