Commits vergleichen

...

2 Commits

Autor SHA1 Nachricht Datum
Claude Dev
7de1f0b66c Revert "Fortschrittsbalken: stetiger Creep statt fixer Sprünge"
This reverts commit ff7322e143.
2026-03-13 23:16:38 +01:00
Claude Dev
9931cc2ed3 Revert "Fortschrittsbalken: globaler Creep statt Phasen-Deckel"
This reverts commit 6ce24e80bb.
2026-03-13 23:16:38 +01:00

Datei anzeigen

@@ -228,8 +228,6 @@ const UI = {
_progressStartTime: null,
_progressTimer: null,
_progressCreepTimer: null,
_progressCurrentPercent: 0,
/**
* Fortschrittsanzeige einblenden und Status setzen.
@@ -281,21 +279,11 @@ const UI = {
else if (i + 1 === step.active) el.classList.add('active');
});
// Phasen-Mindestprozent (Floors) — kein Deckel, Balken kriecht global weiter
const floors = {
queued: 2, researching: 12, deep_researching: 12,
analyzing: 35, factchecking: 65, cancelling: 0,
};
const floor = floors[status] ?? 2;
const fill = document.getElementById('progress-fill');
const percent = step.active === 0 ? 5 : Math.round((step.active / 3) * 100);
if (fill) {
// Mindestens auf Phasen-Floor springen, nie rückwärts
this._progressCurrentPercent = Math.max(this._progressCurrentPercent, floor);
fill.style.width = this._progressCurrentPercent + '%';
this._startProgressCreep();
fill.style.width = percent + '%';
}
const percent = Math.round(this._progressCurrentPercent);
// ARIA-Werte auf der Progressbar aktualisieren
bar.setAttribute('aria-valuenow', String(percent));
@@ -326,33 +314,6 @@ const UI = {
}, 1000);
},
/**
* Creep-Animation: Balken kriecht global asymptotisch Richtung 95%.
* Kein Phasen-Deckel — Phasenwechsel geben nur Boosts über die Floors.
*/
_startProgressCreep() {
if (this._progressCreepTimer) return;
this._progressCreepTimer = setInterval(() => {
const remaining = 95 - this._progressCurrentPercent;
if (remaining <= 0.1) return;
this._progressCurrentPercent += remaining * 0.005;
const fill = document.getElementById('progress-fill');
if (fill) fill.style.width = this._progressCurrentPercent + '%';
const bar = document.getElementById('progress-bar');
if (bar) bar.setAttribute('aria-valuenow', String(Math.round(this._progressCurrentPercent)));
}, 500);
},
/**
* Creep-Animation stoppen.
*/
_stopProgressCreep() {
if (this._progressCreepTimer) {
clearInterval(this._progressCreepTimer);
this._progressCreepTimer = null;
}
},
/**
* Abschluss-Animation: Grüner Balken mit Summary-Text.
*/
@@ -360,10 +321,8 @@ const UI = {
const bar = document.getElementById('progress-bar');
if (!bar) return;
// Timer und Creep stoppen
// Timer stoppen
this._stopProgressTimer();
this._stopProgressCreep();
this._progressCurrentPercent = 100;
// Alle Steps auf done
['step-researching', 'step-analyzing', 'step-factchecking'].forEach(id => {
@@ -410,9 +369,8 @@ const UI = {
if (!bar) return;
bar.style.display = 'block';
// Timer und Creep stoppen
// Timer stoppen
this._stopProgressTimer();
this._stopProgressCreep();
// Error-Klasse
bar.classList.remove('progress-bar--complete');
@@ -458,8 +416,6 @@ const UI = {
bar.classList.remove('progress-bar--complete', 'progress-bar--error');
}
this._stopProgressTimer();
this._stopProgressCreep();
this._progressCurrentPercent = 0;
},
/**