[feat](trx-wefax): show decoder state transitions in frontend
Emit WefaxProgress events with a state label on each decoder state transition (APT Start, Phasing, Receiving) so the frontend can display the current decoder phase instead of just "listening for packets". Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Stan Grams <sjg@haxx.space>
This commit is contained in:
@@ -249,6 +249,15 @@ function addWefaxImage(msg) {
|
||||
|
||||
// ── SSE event handlers (public API) ─────────────────────────────────
|
||||
window.onServerWefaxProgress = function (msg) {
|
||||
// State-only update (no image data): show decoder state in status.
|
||||
if (msg.state && !msg.line_data) {
|
||||
if (wefaxDom.status) {
|
||||
wefaxDom.status.textContent = msg.state;
|
||||
wefaxDom.status.style.color = 'var(--text-accent)';
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (msg.line_count <= 1 || !wefaxLiveCtx) {
|
||||
resetLiveCanvas(msg.pixels_per_line || 1809);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user