summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-08-29 12:08:21 +0200
committerChristophe Besson <cbesson@gmail.com>2026-08-29 12:08:21 +0200
commitb8130c80035abc2b28d0b2f19347d16a40668559 (patch)
tree0cfa2d7db3b32ab8b1a580e8e294fd0b25d9eab5
parentb7733e812fadd6007976d262bd1d793572a36ba7 (diff)
downloadmeshbay-b8130c80035abc2b28d0b2f19347d16a40668559.tar.gz
fix(hub): chat kept stale messages when switching groups on the Chat tab
App components were keyed by app name only (e.g. 'chat'), so switching groups while staying on the same tab reused the component instance — loadedRef stayed true and messages state was never cleared. Now keyed by app name + groupId, forcing a clean remount on group change. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
-rw-r--r--packages/meshbay-hub/src/meshbay_hub/static/group-page.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/meshbay-hub/src/meshbay_hub/static/group-page.js b/packages/meshbay-hub/src/meshbay_hub/static/group-page.js
index dac0f45..acfcfc8 100644
--- a/packages/meshbay-hub/src/meshbay_hub/static/group-page.js
+++ b/packages/meshbay-hub/src/meshbay_hub/static/group-page.js
@@ -577,7 +577,7 @@ function GroupPage({ groupId, group, token, username, userId, userPrefs,
</div>
${apps.map(a => tab === a.key && html`
- <${a.Component} key=${a.key} ...${commonProps} />
+ <${a.Component} key=${a.key + '-' + groupId} ...${commonProps} />
`)}
${tab === 'settings' && html`