fix: preserve log message order when replaying history on connect
Send history messages newest-first from the server, tagged with history=True so the client appends rather than prepends them, avoiding reverse-chronological display on initial load. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -540,7 +540,7 @@
|
||||
if (msg.service) html += '<span class="log-service">' + msg.service + '</span>';
|
||||
html += '<span class="log-msg">' + msg.message + '</span>';
|
||||
html += '</div>';
|
||||
msgs.insertAdjacentHTML("afterbegin", html);
|
||||
msgs.insertAdjacentHTML(state.history ? "beforeend" : "afterbegin", html);
|
||||
applyLogFilters();
|
||||
}
|
||||
cnt++;
|
||||
|
||||
Reference in New Issue
Block a user