summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-08-28 10:27:33 +0200
committerChristophe Besson <cbesson@gmail.com>2026-08-28 10:27:33 +0200
commit7deaf64678eb755e317d326b9941cc10a4996325 (patch)
treeb2a5198d8c3cc33a9fbd02f691828ec20bb2e56c
parentefb1e77d80c03b14699884c40f3b5b17814e831b (diff)
parent9349a957b5b14d08bb6d13e2f127621f5b0ccf12 (diff)
downloadmeshbay-7deaf64678eb755e317d326b9941cc10a4996325.tar.gz
Merge branch 'fix/node-remove-group-when-hub-orphan'
-rw-r--r--packages/meshbay-hub/src/meshbay_hub/static/app.js17
1 files changed, 12 insertions, 5 deletions
diff --git a/packages/meshbay-hub/src/meshbay_hub/static/app.js b/packages/meshbay-hub/src/meshbay_hub/static/app.js
index 9a0787b..703bd47 100644
--- a/packages/meshbay-hub/src/meshbay_hub/static/app.js
+++ b/packages/meshbay-hub/src/meshbay_hub/static/app.js
@@ -2868,11 +2868,18 @@ function NodePage({ token, username, userId, groups }) {
`}
</div>
- <div class="node-section">
- <button class="btn btn-small btn-danger" disabled=${busy}
- onClick=${() => detachGroup(g.name)}>
- ${t('node.detach_group')}</button>
- </div>
+ ${/* Only for a group the hub no longer knows: "Remove group" here
+ just drops it from this node's config. While the group still
+ exists on the hub that would strand it with no host — deleting
+ it is the group Settings tab's job, which detaches and deletes
+ together. */''}
+ ${stale && html`
+ <div class="node-section">
+ <button class="btn btn-small btn-danger" disabled=${busy}
+ onClick=${() => detachGroup(g.name)}>
+ ${t('node.detach_group')}</button>
+ </div>
+ `}
</div>
`;
});