[feat](trx-frontend-http): disable plugin enable/disable for rx role

Disable plugin toggle buttons for rx-authenticated users:
- FT8 decode toggle
- WSPR decode toggle
- CW auto checkbox

RX users cannot enable/disable decoders, preventing unintended
configuration changes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
This commit is contained in:
2026-02-13 08:47:58 +01:00
parent 62f96a1e53
commit 4d0a9d6d90
@@ -155,6 +155,21 @@ function applyAuthRestrictions() {
if (jogWheel) jogWheel.style.opacity = "0.5";
jogButtons.forEach(btn => btn.disabled = true);
// Disable plugin enable/disable buttons
const pluginToggleBtns = [
"ft8-decode-toggle-btn",
"wspr-decode-toggle-btn",
"cw-auto"
];
pluginToggleBtns.forEach(id => {
const btn = document.getElementById(id);
if (btn && btn.tagName === "BUTTON") {
btn.disabled = true;
} else if (btn && btn.type === "checkbox") {
btn.disabled = true;
}
});
// Hide TX-specific UI but keep controls visible (disabled)
if (txLimitRow) txLimitRow.style.opacity = "0.5";
}