Expand all

mw.echo.ui.ActionMenuPopupWidget

Extends

Constructor

new mw.echo.ui.ActionMenuPopupWidget([config]) #

Action menu popup widget for echo items.

We don't currently have anything that properly answers the complete design for our popup menus in OOUI, so this widget serves two purposes:

  1. The MenuSelectWidget is intended to deliver a menu that relates directly to its anchor, so its sizing is dictated by whatever anchors it. This is not what we require, so we have to override the 'click' event to reset the width of the menu.
  2. It abstracts the behavior of the item menus for easier management in the item widget itself (which is fairly large)

Parameters:

Name Type Attributes Description
config Object optional

Configuration object

Source:
Action menu popup widget for echo items.

Methods

decideToggle() #

Decide whether the menu should be visible, based on whether it is empty or not.

Source:

Decide whether the menu should be visible, based on whether it is empty or not.

getMenu() → {OO.ui.MenuSelectWidget} #

Get the widget's action menu

Source:

Returns:

Menu

Type
OO.ui.MenuSelectWidget
Get the widget's action menu

onAction()private #

Handle the button action being triggered.

Source:
Handle the button action being triggered.