CKEditor5PluginDefinition
final class CKEditor5PluginDefinition extends PluginDefinition implements PluginDefinitionInterface (View source)
Provides an implementation of a CKEditor 5 plugin definition.
Traits
Provides a trait for checking configuration schema.
Properties
| protected string | $id | The plugin ID. |
from PluginDefinition |
| protected string | $class | A fully qualified class name. |
from PluginDefinition |
| protected string | $provider | The plugin provider. |
from PluginDefinition |
| protected Element | $schema | The config schema wrapper object for the configuration object under test. |
from SchemaCheckTrait |
| protected string | $configName | The configuration object name under test. |
from SchemaCheckTrait |
Methods
Sets the class.
Gets the class.
Checks the TypedConfigManager has a valid schema for the configuration.
CKEditor5PluginDefinition constructor.
Gets an array representation of this CKEditor 5 plugin definition.
Whether this plugin is configurable by the user.
Gets the human-readable name of the CKEditor plugin.
Gets the list of conditions to enable this plugin.
Whether this plugin has conditions.
Gets the list of toolbar items this plugin provides.
Whether this plugin has toolbar items.
Gets the asset library this plugin needs to be loaded.
Whether this plugin has an asset library to load.
Gets the asset library this plugin needs to be loaded on the admin UI.
Whether this plugin has an asset library to load on the admin UI.
Gets the list of elements and attributes this plugin allows to create/edit.
Whether this plugin allows creating/editing elements and attributes.
Gets the list of CKEditor 5 plugin classes this plugin needs to load.
Whether this plugin loads CKEditor 5 plugin classes.
Gets keyed array of additional values for the CKEditor5 constructor config.
Whether this plugin has additional values for the CKEditor5 constructor.
Details
string
id()
Gets the unique identifier of the plugin.
PluginDefinitionInterface
setClass(string $class)
Sets the class.
string
getClass()
Gets the class.
string
getProvider()
Gets the plugin provider.
The provider is the name of the module that provides the plugin, or "core', or "component".
array|bool
checkConfigSchema(TypedConfigManagerInterface $typed_config, string $config_name, array $config_data)
Checks the TypedConfigManager has a valid schema for the configuration.
protected array
checkValue(string $key, mixed $value)
Helper method to check data type.
__construct(array $definition)
CKEditor5PluginDefinition constructor.
array
toArray()
Gets an array representation of this CKEditor 5 plugin definition.
bool
isConfigurable()
Whether this plugin is configurable by the user.
TranslatableMarkup
label()
Gets the human-readable name of the CKEditor plugin.
array
getConditions()
Gets the list of conditions to enable this plugin.
bool
hasConditions()
Whether this plugin has conditions.
array
getToolbarItems()
Gets the list of toolbar items this plugin provides.
bool
hasToolbarItems()
Whether this plugin has toolbar items.
string
getLibrary()
Gets the asset library this plugin needs to be loaded.
bool
hasLibrary()
Whether this plugin has an asset library to load.
string
getAdminLibrary()
Gets the asset library this plugin needs to be loaded on the admin UI.
bool
hasAdminLibrary()
Whether this plugin has an asset library to load on the admin UI.
string[]|false
getElements()
Gets the list of elements and attributes this plugin allows to create/edit.
bool
hasElements()
Whether this plugin allows creating/editing elements and attributes.
array
getCKEditor5Plugins()
Gets the list of CKEditor 5 plugin classes this plugin needs to load.
bool
hasCKEditor5Plugins()
Whether this plugin loads CKEditor 5 plugin classes.
array
getCKEditor5Config()
Gets keyed array of additional values for the CKEditor5 constructor config.
bool
hasCKEditor5Config()
Whether this plugin has additional values for the CKEditor5 constructor.