-
Notifications
You must be signed in to change notification settings - Fork 27.4k
docs (index) there should be no autofocus when docs are read #2737
Conversation
The search box should not receive autofocus when browsing the docs as the primary purpose of the docs it to convey information, not search.
@eddiemonge - not sure I agree here. Certainly in the API pages, I always want to search for an item. Even in the guide, I usually don't know exactly where I want to browse to and type something in to get me there. Having focus on the search box speeds this up dramatically. What is the downside of this input having focus? |
you lose keyboard navigation on the page. Space and arrow keys dont work to navigate without pressing esc or clicking somewhere to remove the input boxes focus. On the index page its not so much a problem but lets say I land on http://docs.angularjs.org/api/ng.directive:ngChecked. Clearly I want to read whats on that page and the focus shouldnt be on searching for something else first. The focus should be on that pages content. |
didnt mean to close. github has weird tab navigation |
Another place is http://docs.angularjs.org/tutorial/ |
any more decisions on this? |
I tend to agree with @eddiemonge
I guess it is my timid +1 for merging this (unless I'm missing some other navigation patterns that initial focus makes easy / possible) |
I'm ok with removing the focus and using |
@matsko can you please look into dropping autofocus from the search bar in the docs app? thnx! |
I would love for us to kill the focused directive. I'm looking at the implementation and it's super-lame. we however need to communicate the current focus state to ngClass somehow. |
@IgorMinar there is a PR for read-only blur / focus: #2979 (it still needs work as it doesn't have tests / doc updates). |
I'll make two commits. One to remove the autofocus and another to play with the ng-focus/ng-blur + ng-class directives on the input. |
I also think the accesskey feature isn't helping here. Certain browsers/OSs have different shortcut combinations and I highly doubt most users will use them. We can keep it there to retain any compatibility, but perhaps we could add a global |
Here's commit 1: #3227 |
The search box should not receive autofocus when browsing the docs as the primary purpose of the docs it to convey information, not search.