Controls the popover region element.
See template: core/popover_region
- Source:
- Since:
- 3.2
- Copyright:
- 2015 Ryan Wyllie
- 2015 Ryan Wyllie
- License:
- http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
Methods
(inner) closeMenu()
Hide the popover.
Note: This triggers the menuClosed event.
(inner) contentItemHasFocus() → {bool}
Check if a content item has focus.
Returns:
- Type
- bool
(inner) focusContentItem(item)
Focus the given content item or the first focusable element within the content item.
Parameters:
Name | Type | Description |
---|---|---|
item |
object | The content item jQuery element |
(inner) focusFirstContentItem()
Set focus on the first content item in the list.
(inner) focusLastContentItem()
Set focus on the last content item in the list.
(inner) focusMenuToggle()
Sets the focus on the menu toggle.
(inner) focusNextContentItem()
Set focus on the content item after the item that currently has focus in the list.
(inner) focusPreviousContentItem()
Set focus on the content item preceding the item that currently has focus in the list.
(inner) getContent() → {jQuery}
Return the content element.
Returns:
object
- Type
- jQuery
(inner) getContentContainer() → {jQuery}
Return the container element for the content element.
Returns:
object
- Type
- jQuery
(inner) getContentItemWithFocus() → {jQuery}
Return the currently focused content item.
Returns:
object
- Type
- jQuery
(inner) isMenuOpen() → {bool}
Checks if the popover is displayed.
Returns:
- Type
- bool
(inner) openMenu()
Show the popover.
Note: This triggers the menuOpened event.
(inner) registerBaseEventListeners()
Register the minimal amount of listeners for the popover to function.
(inner) registerListNavigationEventListeners()
Set up the event listeners for keyboard navigating a list of content items.
(inner) startLoading()
Set the loading state on this popover.
Note: This triggers the startLoading event.
(inner) stopLoading()
Undo the loading state on this popover.
Note: This triggers the stopLoading event.
(inner) toggleMenu()
Toggle the visibility of the popover.
(inner) updateButtonAriaLabel()
Set the appropriate aria label on the popover toggle.