Change:
Issue Type: <bBug</bSteps to Reproduce: a notebook. In my case, I have a Jupyter notebook (.ipynb). any of the "" or "" or "" or "". happens! These navigation commands work just fine in all other views/panels that I regularly use. VS Code version: Code 1.66.2 (Universal) (, 2022-04-11T07:49:20.994Z) OS version: Darwin arm64 21.4.0 Restricted Mode: No <details<summarySystem Info</summary </detailsExtensions disabled <!-- generated by issue reporter --
this sounds like a real bug to me, the issue is that notebooks do not seem to be rooted below the editor part in the DOM: ! That asks for trouble because we have lots of checks in code to figure out if the editor area has DOM focus or not, e.g.: What is the rationale? I checked with custom editors, and they manage to put the into the DOM hierarchy of the editor part. //cc
We render the notebook out of the grid view as it contains a webview, which can not be re-parented when users drag editors between groups. I basically followed what Custom Editor does did we change this recently? I wonder if it's already safe to do so.
Can confirm that I am also experiencing this. In the meantime, I've found that this kind of works for moving left and right: But there is no or , and this fails when attempting to move to panels. Looking forward to a fix, or if anyone has a workaround.
fyi we no longer use but only , so maybe that changed.
<img width="1918" alt="image" src="https://user-"I found that we are not putting custom editor webviews in the editor grid either.
oh ok, turns out we seem to have logic to still make that work via a special code, looks like notebooks should adopt it as well: And the relevant method using it:
Yes to my knowledge iframes still cannot be reparented. All webviews are rendered as top level elements with absolute positioning to work around this Let me know if you have any questions about using . It should help fix this issue as I believe I've already fixed a similar issue for webviews
This feels like a useful workaround. Concerning moving up and down, you can use the and actions ().
works great, it would be great if you can help review
This seems to be working for me now in insiders but feel free to speak up if it's not doing what you expect
Yep, this seems to be fixed in the insiders build. Looking forward to seeing it merged into stable! Thanks everyone!

Discussion:
import { DisposableStore, MutableDisposable } from 'vs/base/common/lifecycle'; import { extname, isEqual } from 'vs/base/common/resources'; import { URI } from 'vs/base/common/uri'; <ins> import { generateUuid } from 'vs/base/common/uuid'; </ins> import { ITextResourceConfigurationService } from 'vs/editor/common/services/textResourceConfiguration'; import { localize } from 'vs/nls'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey';

protected createEditor(parent: HTMLElement): void { this._rootElement = DOM.append(parent, DOM.$('.notebook-editor')); <ins> this._rootElement.id = `notebook-editor-element-${generateUuid()}`; </ins> } getDomNode() {

} this._widget = <IBorrowValue<NotebookEditorWidget>>this._instantiationService.invokeFunction(this._notebookWidgetService.retrieveWidget, group, input); <ins> if (this._rootElement && this._widget.value!.getDomNode()) { this._rootElement.setAttribute('aria-flowto', this._widget.value!.getDomNode().id || ''); DOM.setParentFlowTo(this._widget.value!.getDomNode(), this._rootElement); } </ins> this._widgetDisposableStore.add(this._widget.value!.onDidChangeModel(() => this._onDidChangeModel.fire())); this._widgetDisposableStore.add(this._widget.value!.onDidChangeActiveCell(() => this._onDidChangeSelection.fire({ reason: EditorPaneSelectionChangeReason.USER })));