From b65d9516f95b3a91d4dcab47e69c31e8c9226ac4 Mon Sep 17 00:00:00 2001 From: Andrew Duthie Date: Wed, 7 Mar 2018 10:59:32 -0500 Subject: [PATCH] Inserter: Preserve autofocus behavior of inserter Even on click, which no longer shifts focus as of 621631ca --- editor/components/inserter/menu.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/editor/components/inserter/menu.js b/editor/components/inserter/menu.js index 7aced3089cb83..669cad3c2eefc 100644 --- a/editor/components/inserter/menu.js +++ b/editor/components/inserter/menu.js @@ -270,6 +270,11 @@ export class InserterMenu extends Component { const { selectedItem } = this.state; const isSearching = this.state.filterValue; + // Disable reason: The inserter menu is a modal display, not one which + // is always visible, and one which already incurs this behavior of + // autoFocus via Popover's focusOnMount. + + /* eslint-disable jsx-a11y/no-autofocus */ return ( { ! isSearching && ); + /* eslint-enable jsx-a11y/no-autofocus */ } }