Namespace: textWidgets

wp. textWidgets

Classes

TextWidgetControl

Members


<static> component.widgetControls :Object:.<string:, wp.textWidgets.TextWidgetControl:>

Mapping of widget ID to instances of TextWidgetControl subclasses.
Type:
Source:

Methods


<static> component.handleWidgetAdded(event, widgetContainer)

Handle widget being added or initialized for the first time at the widget-added event.
Parameters:
Name Type Description
event jQuery.Event Event.
widgetContainer jQuery Widget container element.
Source:
Returns:
Type
void

<static> component.handleWidgetUpdated(event, widgetContainer)

Sync widget instance data sanitized from server back onto widget model. This gets called via the 'widget-updated' event when saving a widget from the widgets admin screen and also via the 'widget-synced' event when making a change to a widget in the customizer.
Parameters:
Name Type Description
event jQuery.Event Event.
widgetContainer jQuery Widget container element.
Source:
Returns:
Type
void

<static> component.init()

Initialize functionality. This function exists to prevent the JS file from having to boot itself. When WordPress enqueues this script, it should have an inline script attached which calls wp.textWidgets.init().
Source:
Returns:
Type
void

<static> component.setupAccessibleMode()

Setup widget in accessibility mode.
Source:
Returns:
Type
void