integr8ly / tutorial-web-app

Solution Explorer provides the front door into the Integreatly initiative. It hosts the various Solution Patterns, as well as providing a dashboard of installed applications/products/services.
Apache License 2.0
36 stars 54 forks source link

fix(dropdown): fix autofocus on dropdowns #486

Closed AdamJ closed 5 years ago

AdamJ commented 5 years ago

Motivation

With the last PatternFly Core update (5d988eedd5678654416f4550ddaffbdf8d8f92ad), autoFocus was automatically applied to all dropdown menus for accessibility purposes. This causes issues visually, and created an awkward experience with our dropdown menus.

What

Remove autoFocus from the dropdown menus.

Why

autoFocus was automatically applied by the default dropdown properties provided by PatternFly React.

How

Update dependency to a minimum of 3.67.1 (actually updated to 3.73.0) and add autoFocus={false} to the <Dropdown> Prop.

Verification Steps

  1. Run yarn install && yarn build && yarn start:dev
  2. Click on the Help dropdown and verify that no menu item is automatically highlighted/focused on.
  3. Click on the User dropdown and verify that no menu item is automatically highlighted/focused on.

Checklist:

Progress