Class: Constructor

wp.mediaWidgets~ Constructor


new Constructor()

Source:

Methods


fetch()

Fetch media.
Source:
Returns:
Type
void

renderFail()

Handle render failure. Overrides the {EmbedLink#renderFail()} method to prevent showing the "Link Text" field. The element is getting display:none in the stylesheet, but the underlying method uses uses {jQuery.fn.show()} which adds an inline style. This avoids the need for !important.
Source:
Returns:
Type
void

setAddToWidgetButtonDisabled(disabled)

Set the disabled state on the Add to Widget button.
Parameters:
Name Type Description
disabled boolean Disabled.
Source:
Returns:
Type
void

setErrorNotice(notice)

Set or clear an error notice.
Parameters:
Name Type Description
notice string Notice.
Source:
Returns:
Type
void

updateoEmbed()

Update oEmbed.
Since:
  • 4.9.0
Source:
Returns:
Type
void