Class: form

Drupal.quickedit.editors.form()

Extends

Members

$formContainer :jQuery

Tracks form container DOM element that is used while in-place editing.

Type:
Source:

formSaveAjax :Drupal.Ajax

Holds the Drupal.Ajax object.

Type:
Source:

Methods

getEditedElement() → {jQuery}

Returns the edited element.

For some single cardinality fields, it may be necessary or useful to not in-place edit (and hence decorate) the DOM element with the data-quickedit-field-id attribute (which is the field's wrapper), but a specific element within the field's wrapper. e.g. using a WYSIWYG editor on a body field should happen on the DOM element containing the text itself, not on the field wrapper.

Inherited From:
Source:
See:
Returns:

A jQuery-wrapped DOM element.

Type
jQuery

getQuickEditUISettings() → {object}

{@inheritdoc}

Overrides:
Source:
Returns:

A settings object for the quick edit UI.

Type
object

loadForm()

Loads the form for this field, displays it on top of the actual field.

Source:

remove()

{@inheritdoc}

Inherited From:
Source:

removeForm()

Removes the form for this field, detaches behaviors and event handlers.

Source:

removeValidationErrors()

Cleans up validation error messages.

Should be called when the state is changed to 'candidate' or 'saving'. In the case of the latter: the user has modified the value in the in-place editor again to attempt to save again. In the case of the latter: the invalid value was discarded.

Inherited From:
Source:

revert()

Reverts the modified value to the original, before editing started.

Inherited From:
Source:

save()

{@inheritdoc}

Overrides:
Source:

showValidationErrors()

{@inheritdoc}

Overrides:
Source:

stateChange(fieldModel, state)

{@inheritdoc}

Parameters:
Name Type Description
fieldModel object

The field model that holds the state.

state string

The state to change to.

Overrides:
Source: