Module: alfresco/forms/controls/TinyMCE

alfresco/forms/controls/TinyMCE

This a form control that wraps the TinyMCE editor.
Author:
  • Dave Draper
License:
Source:

Members

autoResize :boolean

This indicates whether or not the TinyMCE editor should automatically resize to consume the available space.
Type:
  • boolean
Since:
  • 1.0.47
Default Value:
  • false
Source:

widgetsForEditor :object[]

This is the default model for creating the editor to be displayed. It provides a way in which the default editor can be extended and used within the standard form control. The main reason for wanting to use a customized version of the default TinyMCE editor is to provide custom callbacks for plugins.
Type:
  • object[]
Since:
  • 1.0.66
Source:

Methods

alfDisabled(status)

Overrides the inherited function to make the TinyMCE editor disabled.
Parameters:
Name Type Description
status boolean Indicates the current status
Source:

createFormControl()

Builds the configured editor model.
Source:

getWidgetConfig()

Returns the configuration to use for the widget.
Source:

onEditorValueChange()

This is the aspect handler hitched in the setupChangeEvents function and retrieves the current value of the TinyMCE editor and calls the onValueChangeEvent function with it.
Source:

placeWidget()

TinyMCE requires that the editor DOM element is in the document rather than in a fragment so we delay initialising the editor until it is placed into the document.
Source:

setupChangeEvents()

Overrides to prevent any action from occurring. Editor value change handlers are passed in the configuration of the TinyMCE editor creation.
Source:

textContentRequired(validationConfig)

This is a custom validator for this specific form control. It is necessary in order to support the ability to check for the TinyMCE editor being empty as text (rather than as HTML).
Parameters:
Name Type Description
validationConfig object The configuration for this validator
Since:
  • 1.0.70
Source: