-
Notifications
You must be signed in to change notification settings - Fork 177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[focusgroup] How does focusgroup interplay with autofocus? #1013
Comments
Yes, that's my expectation as well, given how the popover focusing steps are written. (If there's an autofocus delegate under the popover node, it pulls focus to it.) Because focus now lands inside of a vertical (block-orientation) focusgroup, the up/down arrow keys will work to move the focus around within that focusgroup.
In this scenario, I don't think there's any change (no difference). If you adjusted the markup slightly so that the As an aside: by having the |
I'm not sure if I understand this correctly. Would a child <div focusgroup> <!-- Parent -->
<div focusgroup> <!-- implicit focusgroup=none? -->
<button>Am I a candidate, if yes, for which group?</button>
<div focusgroup></div> <!-- what happens here? -->
</div>
</div> |
Note, the following is not currently written in the explainer, but is planned for inclusion. @gfellerph my expectation is that whenever a
So in your example: <div focusgroup> <!-- Parent -->
<div focusgroup> <!-- implicit focusgroup=none? -->
<button>Am I a candidate, if yes, for which group?</button>
<div focusgroup></div> <!-- what happens here? -->
</div>
</div>
The reason for having a focusgroup declaration automatically opt-out the element from any ancestor focusgroups is to avoid the situation where an element might belong to more than one focusgroup at a time. If such a thing were possible it seems like it opens up a whole lot more complexity (similar to what |
Regarding any planned interaction with If we did want to tweak Anyone else have a good use case or creative way to use |
I'm not sure if this is a case that can happen, but consider:
If such a use case is possible, then it would be reasonable to assume that the autofocus code might have an integration with focusgroup's memory such that the autofocus element's selection process would give preference to the focusgroup's memory element. |
In #989 we discussed a scenario for orthogonal focus groups; say you have something like:
Supposedly, opening the popover menu would land focus on the button, and then the vertical group would focus? What happens in light of the resolutions in #989 where the element with
focusgroup
is part of the group?Perhaps also interesting, what if we change from
invoketarget
tointeresttarget
?The text was updated successfully, but these errors were encountered: