diff options
author | mehekj <mehek.jethani@gmail.com> | 2023-03-14 19:32:06 -0400 |
---|---|---|
committer | mehekj <mehek.jethani@gmail.com> | 2023-03-14 19:32:06 -0400 |
commit | 504c8046c13dfe77316e42943e48c017d67c2ad8 (patch) | |
tree | 9e4e8f3b79d9a72fece08a075dd666aac8872001 /src/client/util/DocumentManager.ts | |
parent | c68e751531f972fcf201089f26e69627cfe4fe3c (diff) | |
parent | 8fe91ed2bbb8141657830e238043af37e94a91e4 (diff) |
Merge branch 'master' into schema-mehek
Diffstat (limited to 'src/client/util/DocumentManager.ts')
-rw-r--r-- | src/client/util/DocumentManager.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/util/DocumentManager.ts b/src/client/util/DocumentManager.ts index c670d0ab8..f2c554866 100644 --- a/src/client/util/DocumentManager.ts +++ b/src/client/util/DocumentManager.ts @@ -286,7 +286,7 @@ export class DocumentManager { docView.rootDoc.layoutKey === 'layout_icon' ? await new Promise<void>(res => docView.iconify(res)) : undefined; docView.props.focus(docView.rootDoc, options); // focus the view within its container const { childDocView, viewSpec } = await iterator(docView); - if (!childDocView) return { viewSpec: viewSpec ?? docView.rootDoc, docView, contextView }; + if (!childDocView) return { viewSpec: options.anchorDoc ?? viewSpec ?? docView.rootDoc, docView, contextView }; contextView = docView; docView = childDocView; } |