From 228786e2f5082b9e51acd21cc68948c73926242f Mon Sep 17 00:00:00 2001 From: Jos Poortvliet Date: Sun, 23 Aug 2026 16:11:55 +0200 Subject: [PATCH 1/2] fix(comments): recreate Vue app when re-mounting Activity sidebar comment editor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The comment editor Vue app instance was kept in a closure variable and reused across Activity tab mount/unmount cycles. unmount() destroyed the app via app.unmount() but never reset the variable, so the next mount() skipped creating a new app and called mount() on an already- destroyed instance — a silent no-op. This made the comment field disappear after leaving and returning to the Activity tab, only recoverable via a full page reload. Reset `app` to undefined after unmounting so the editor is recreated on the next mount. Fixes #63487 Assisted-by: Claude:claude-sonnet-5 Signed-off-by: Jos Poortvliet --- apps/comments/src/comments-activity-tab.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/comments/src/comments-activity-tab.ts b/apps/comments/src/comments-activity-tab.ts index b738242cf574c..88c62447fd026 100644 --- a/apps/comments/src/comments-activity-tab.ts +++ b/apps/comments/src/comments-activity-tab.ts @@ -38,6 +38,7 @@ export function registerCommentsPlugins() { unmount: () => { // destroy previous instance if available app?.unmount() + app = undefined }, }) From 75631a669e7a6c34daf1b6c803812eb685926198 Mon Sep 17 00:00:00 2001 From: Jos Poortvliet Date: Tue, 1 Sep 2026 10:08:43 +0200 Subject: [PATCH 2/2] Update apps/comments/src/comments-activity-tab.ts Co-authored-by: Josh Signed-off-by: Jos Poortvliet --- apps/comments/src/comments-activity-tab.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/comments/src/comments-activity-tab.ts b/apps/comments/src/comments-activity-tab.ts index 88c62447fd026..44ec58972c0d9 100644 --- a/apps/comments/src/comments-activity-tab.ts +++ b/apps/comments/src/comments-activity-tab.ts @@ -15,7 +15,7 @@ import { getComments } from './services/GetComments.ts' * Register the comments plugins for the Activity sidebar */ export function registerCommentsPlugins() { - let app: App + let app: App | undefined window.OCA.Activity.registerSidebarAction({ mount: async (el: HTMLElement, { node, reload }: { node: INode, reload: () => void }) => {