From 13d145253a871ef47ef4344f90566eea21b994ab Mon Sep 17 00:00:00 2001 From: Christophe Besson Date: Fri, 4 Sep 2026 16:50:32 +0200 Subject: fix(client): Stop/Restart buttons and an autostart toggle on the Node page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Root cause of both reports: node:service-status's `installed` field was winAutostartInstalled() -- whether the Startup-folder launcher exists -- not whether the daemon can be managed at all. The Node page gates Stop/Restart on `installed`, so with no autostart configured (the default -- nothing installs it automatically) those buttons silently never rendered, leaving only Start. A perfectly manageable daemon looked unmanageable because a different, unrelated setting was off. installed now reflects the actual daemon binary (findNodeBinary()), same definition node:installed already used; autostart moves to its own field carrying what installed used to mean. That field also fixes the other half: there was no way to turn autostart on except the CLI. NodeServicePanel now shows a toggle-switch next to Start/Stop/Restart, wired through a new platform.node.autostart (install/remove) that mirrors the existing service.* pattern -- the preload/main.js bridge (W3) was already there, just never called from the interface. English and French strings; other locales fall back to English per the project's own stated policy (test_locales.py's own docstring). Verified: node --check on every edited file; hub/node suites green (863 pass, 0 fail — pre-existing test_locales.py encoding failures on this Windows checkout are unrelated, reproduced identically on the clean tree). Co-Authored-By: Claude Sonnet 5 --- packages/meshbay-hub/src/meshbay_hub/static/locales/en.js | 2 ++ packages/meshbay-hub/src/meshbay_hub/static/locales/fr.js | 2 ++ 2 files changed, 4 insertions(+) (limited to 'packages/meshbay-hub/src/meshbay_hub/static/locales') diff --git a/packages/meshbay-hub/src/meshbay_hub/static/locales/en.js b/packages/meshbay-hub/src/meshbay_hub/static/locales/en.js index 898f7f4..09feaf5 100644 --- a/packages/meshbay-hub/src/meshbay_hub/static/locales/en.js +++ b/packages/meshbay-hub/src/meshbay_hub/static/locales/en.js @@ -734,6 +734,8 @@ export default { 'node.service_stopping': 'Stopping…', 'node.service_restart': 'Restart', 'node.service_restarting': 'Restarting…', + 'node.autostart_label': 'Start automatically at sign-in', + 'node.autostart_updating': 'Updating…', 'node.offline': 'Node is offline', 'node.no_groups': 'No groups configured on this node.', 'node.retry': 'Retry', diff --git a/packages/meshbay-hub/src/meshbay_hub/static/locales/fr.js b/packages/meshbay-hub/src/meshbay_hub/static/locales/fr.js index 1999e7e..88e27f8 100644 --- a/packages/meshbay-hub/src/meshbay_hub/static/locales/fr.js +++ b/packages/meshbay-hub/src/meshbay_hub/static/locales/fr.js @@ -677,6 +677,8 @@ export default { 'node.service_stopping': 'Arrêt…', 'node.service_restart': 'Redémarrer', 'node.service_restarting': 'Redémarrage…', + 'node.autostart_label': 'Démarrer automatiquement à l\'ouverture de session', + 'node.autostart_updating': 'Mise à jour…', 'node.not_operator': 'Impossible de joindre votre node. Vérifiez qu\'il est en cours d\'exécution.', 'node.offline': 'Node hors ligne', 'node.retry': 'Réessayer', -- cgit v1.2.3