feat: update project structure for Vite and React Router, remove deprecated sources, and enhance Docker deployment

This commit is contained in:
HouYunFei
2026-07-05 11:38:42 +08:00
parent 443afab7bd
commit cebc3dc5c2
16 changed files with 60 additions and 50 deletions
+6 -4
View File
@@ -377,8 +377,9 @@ function consumeResponseStreamText(state: ResponseStreamState, text: string, onD
for (;;) {
const match = state.buffer.match(/\r?\n\r?\n/);
if (!match) break;
consumeResponseStreamBlock(state.buffer.slice(0, match.index), state, onDelta);
state.buffer = state.buffer.slice(match.index + match[0].length);
const index = match.index ?? 0;
consumeResponseStreamBlock(state.buffer.slice(0, index), state, onDelta);
state.buffer = state.buffer.slice(index + match[0].length);
}
if (flush && state.buffer.trim()) {
consumeResponseStreamBlock(state.buffer, state, onDelta);
@@ -525,8 +526,9 @@ function consumeGeminiStreamText(state: GeminiStreamState, text: string, onDelta
for (;;) {
const match = state.buffer.match(/\r?\n\r?\n/);
if (!match) break;
consumeGeminiStreamBlock(state.buffer.slice(0, match.index), state, onDelta);
state.buffer = state.buffer.slice(match.index + match[0].length);
const index = match.index ?? 0;
consumeGeminiStreamBlock(state.buffer.slice(0, index), state, onDelta);
state.buffer = state.buffer.slice(index + match[0].length);
}
if (flush && state.buffer.trim()) {
consumeGeminiStreamBlock(state.buffer, state, onDelta);