Fix: Chat scrollt nach Font-Loading nochmal nach unten

scrollDown() wartet jetzt auf document.fonts.ready und scrollt erneut.
chat-page.js wartet nach loadHistory() zusätzlich per requestAnimationFrame
auf den Repaint nach Font-Swap.
This commit is contained in:
Meleki committed 2026-02-28 15:54:47 +01:00
1 parent 3cb468f4e8
commit 76341dc42b
14 files changed
+349 -121

No files matched your search

+16
View File
@@ -0,0 +1,16 @@
using System.Collections.Concurrent;
namespace Gott.Services;
public class StreamingTracker
{
private readonly ConcurrentDictionary<string, string> _streaming = new ConcurrentDictionary<string, string>();
public void Start(string sessionId, string chainId) => _streaming[sessionId] = chainId;
public void Stop(string sessionId) => _streaming.TryRemove(sessionId, out _);
public bool IsStreaming(string sessionId) => _streaming.ContainsKey(sessionId);
public string GetChainId(string sessionId) => _streaming.TryGetValue(sessionId, out var chainId) ? chainId : null;
}