focus terminal on escape of the help menu (#173964)

fix #173909
This commit is contained in:
Megan Rogge 2023-02-09 10:53:58 -06:00 committed by GitHub
parent 49055d2286
commit a338e70218
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2698,6 +2698,7 @@ class AccessibilityHelpWidget extends Widget implements ITerminalWidget {
this._register(dom.addStandardDisposableListener(this._contentDomNode.domNode, 'keydown', (e) => {
if (e.keyCode === KeyCode.Escape) {
this.hide();
instance.focus();
}
}));
this._register(instance.onDidFocus(() => this.hide()));