From 0f1c5058234b635d3ed047324c1f1ca1aeb236f3 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Tue, 8 Jul 2025 16:22:11 +0300 Subject: [PATCH] fix(tab): editor not focused after switching tabs --- apps/client/src/widgets/type_widgets/type_widget.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/apps/client/src/widgets/type_widgets/type_widget.ts b/apps/client/src/widgets/type_widgets/type_widget.ts index 3a437e1092..9cd8a64abd 100644 --- a/apps/client/src/widgets/type_widgets/type_widget.ts +++ b/apps/client/src/widgets/type_widgets/type_widget.ts @@ -71,6 +71,15 @@ export default abstract class TypeWidget extends NoteContextAwareWidget { } } + activeNoteChangedEvent() { + if (!this.isActiveNoteContext()) { + return; + } + + // Restore focus to the editor when switching tabs. + this.focus(); + } + /** * {@inheritdoc} *