symfony / symfony-docs

The Symfony documentation
https://symfony.com/doc
Other
2.17k stars 5.12k forks source link

[Website] Add common keyboard shortcut to access quick search #16168

Closed tigitz closed 1 year ago

tigitz commented 2 years ago

Hello,

Ctrl + k or Ctrl + / are becoming popular keyboard shortcuts to quickly access documentation search and it's awesome for DX.

Examples:

Given how the actual search bar is placed (in the page"s top-right corner, disappearing as soon as 36px are scrolled which happens frequently while reading the doc), I think it could be a move forward in DX to implement this shortcut until the search bar is placed closer to the actual doc reading area to improve reachability.

Edit: I just learn that Symfony Docs already have a shift shift shortcut. My suggestion still stands for the following reasons.

alexmerlin commented 2 years ago

Actually, there already is a keyboard shortcut for this: try pressing Shift twice (like double click).

tigitz commented 2 years ago

Ha! Interesting, thanks for the tip, I guess the issue could be transformed to considering adding Ctrl + K or Ctrl + / as a shortcut too so that it also supports the unwritten standard of documentation quick search shortcut.

Also the simple fact that I learned it here means shortcut, if presents, are lacking discoverability. Most popular documentation website put the shortcut combination next to the search bar to help that and I feel Symfony docs could too.

carsonbot commented 1 year ago

Thank you for this issue. There has not been a lot of activity here for a while. Has this been resolved?

tigitz commented 1 year ago

Issue is still relevant, symfony docs is still an outlier when it comes to keyboard shortcuts in a open-source doc portal and doesn't provide any visual help to at least inform its visitors from its specifities.

Making navigation and discoverability a little bit harder than it could IMO.

javiereguiluz commented 1 year ago

Closing as fixed because the search box is now activated with 3 different shortcuts: