[feat](trx-frontend-http): wire HF APRS toggle button and bookmark decoder

- Add "Enable HF APRS" toggle button to the HF APRS tab (same style as
  FT8/WSPR); button is disabled during TX like other decoder toggles
- app.js: sync button text/colour from SSE state updates
- hf-aprs.js: connect button click to /toggle_hf_aprs_decode
- bookmarks.js: add "HF APRS" checkbox to Add/Edit Bookmark decoder
  section; bmReadDecoders/bmWriteDecoders handle "hf-aprs" key; bmApply
  toggles the decoder to match bookmark preference on recall

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Stan Grams <sjg@haxx.space>
This commit is contained in:
2026-03-08 20:43:55 +01:00
parent ac586418fc
commit 26fbd37b6d
4 changed files with 20 additions and 0 deletions
@@ -222,6 +222,7 @@ function applyAuthRestrictions() {
"vdes-clear-btn",
"ft8-decode-toggle-btn",
"wspr-decode-toggle-btn",
"hf-aprs-decode-toggle-btn",
"cw-auto",
"aprs-clear-btn",
"ft8-clear-btn",
@@ -2476,6 +2477,13 @@ function render(update) {
wsprToggleBtn.style.borderColor = wsprOn ? "#00d17f" : "";
wsprToggleBtn.style.color = wsprOn ? "#00d17f" : "";
}
const hfAprsToggleBtn = document.getElementById("hf-aprs-decode-toggle-btn");
if (hfAprsToggleBtn) {
const hfAprsOn = !!update.hf_aprs_decode_enabled;
hfAprsToggleBtn.textContent = hfAprsOn ? "Disable HF APRS" : "Enable HF APRS";
hfAprsToggleBtn.style.borderColor = hfAprsOn ? "#00d17f" : "";
hfAprsToggleBtn.style.color = hfAprsOn ? "#00d17f" : "";
}
const cwAutoEl = document.getElementById("cw-auto");
const cwWpmEl = document.getElementById("cw-wpm");
const cwToneEl = document.getElementById("cw-tone");