feat: Allow top nav to receive keyboard focus by jhildenbiddle · Pull Request #2269 · docsifyjs/docsify

Fix #530

Summary

As described in title.

Before

  1. Visit https://docsify.js.org/
  2. Press TAB. Notice that the keyboard focus jumps to the "docsify" link under the logo, ignoring the links found under the "Translations" menu.

CleanShot 2023-10-16 at 13 43 16@2x

After

  1. Navigate to this PR's preview link (below)
  2. Press TAB. Notice that the "Translations" menu is displayed and the keyboard focus moves to the first link within menu.

CleanShot 2023-10-16 at 13 44 01@2x

Related issue, if any:

#530

What kind of change does this PR introduce?

Feature

For any code change,

  • No documentation changes required
  • No automated tests required

Does this PR introduce a breaking change?

No

Tested in the following browsers:

  • Chrome
  • Firefox
  • Safari
  • Edge