ReadonlycontainerOptionalonIf overwritten, allows to implement custom action behavior. Per default, the internal handler will still be
executed. To prevent execution of the default action handler, call preventDefault();
OptionalonIf overwritten, allows to implement custom navigation behavior. Per default, the internal handler will still be
executed. To prevent execution of the default navigation handler, call preventDefault();
Disable navigation group
Call blur on active element, set as undefined, and track it as element before disable.
Enable navigation group
Sets active element to either element that was active before disable, or first element of tracked elements. If it is settings panel, it will always focus first element in the list.
Returns the active HTMLElement.
Handles an action event.
The action of the event
Handles a navigation event.
The direction of the navigation event
true if navigation was successful, false otherwise
Dispose of navigation group
Used as part of spatial navigation. Groups together different components to which you can navigate to, in a single navigation group.
Responsible for finding elements in direction on navigation and for tracking active element inside the group. Triggers blur and focus on element when active element is changed, as well as click on element on
Action.SELECT. Will callhideUi()on passed in container ifAction.BACKis called.To have more control over grouping related elements together, you can use
FocusableContainer.Example 1:
new RootNavigationGroup(uiContainer, playbackToggleOverlay, seekBar, bottomControlBar, titleBar)In this example all components which are passed to the
RootNavigationGroupwill be navigable on a 'flat' hierarchy. Elements form within the bottomControlBar and the titleBar will be resolved lazily and it's possible to navigate from/to every element.Example 2:
new RootNavigationGroup( uiContainer, playbackToggleOverlay, seekBar, new FocusableContainer(bottomControlBar, playbackToggleButton), new FocusableContainer(titleBar) )In this example the bottomControlBar and the titleBar are considered as a group of elements. Their components will still be resolved lazily, but the navigation will target the whole container instead of the individual components. In addition, a primary component can be set for each
FocusableContainer, which will be component that receives focus first when the container is focused.