Editor
class Editor extends PluginBase implements InPlaceEditorInterface (View source)
Defines the formatted text in-place editor.
Constants
| DERIVATIVE_SEPARATOR |
A string which is used to separate base plugin IDs from the derivative ID. |
Properties
| protected string | $pluginId | The plugin_id. |
from PluginBase |
| protected array | $pluginDefinition | The plugin implementation definition. |
from PluginBase |
| protected array | $configuration | Configuration information passed into the plugin. |
from PluginBase |
Methods
Constructs a \Drupal\Component\Plugin\PluginBase object.
Checks whether this in-place editor is compatible with a given field.
Generates metadata that is needed specifically for this editor.
Returns whether the text format has transformation filters.
Returns the attachments for this editor.
Details
__construct(array $configuration, string $plugin_id, mixed $plugin_definition)
Constructs a \Drupal\Component\Plugin\PluginBase object.
string
getPluginId()
Gets the plugin_id of the plugin instance.
string
getBaseId()
Gets the base_plugin_id of the plugin instance.
string|null
getDerivativeId()
Gets the derivative_id of the plugin instance.
array
getPluginDefinition()
Gets the definition of the plugin implementation.
bool
isConfigurable()
Determines if the plugin is configurable.
bool
isCompatible(FieldItemListInterface $items)
Checks whether this in-place editor is compatible with a given field.
array
getMetadata(FieldItemListInterface $items)
Generates metadata that is needed specifically for this editor.
Will only be called by \Drupal\quickedit\MetadataGeneratorInterface::generate() when the passed in field & item values will use this editor.
protected bool
textFormatHasTransformationFilters(int $format_id)
Returns whether the text format has transformation filters.
array
getAttachments()
Returns the attachments for this editor.