LinkDecoratorManualDefinition (link)
@ckeditor/ckeditor5-link/src/link
Describes a manual link decorator. This decorator type is represented in the link feature's user interface as a switch that the user can use to control the presence of a predefined set of attributes.
For instance, to allow the users to manually control the presence of the target="_blank"
and
rel="noopener noreferrer"
attributes on specific links, the decorator could look as follows:
{
mode: 'manual',
label: 'Open in a new tab',
defaultValue: true,
attributes: {
target: '_blank',
rel: 'noopener noreferrer'
}
}
Filtering
Properties
-
attributes : Object | undefined
module:link/link~LinkDecoratorManualDefinition#attributes
Key-value pairs used as link attributes added to the output during the downcasting. Attributes should follow the
ElementDefinition
syntax. -
classes : String | Array.<String> | undefined
module:link/link~LinkDecoratorManualDefinition#classes
Class names used as link classes added to the output during the downcasting. Classes should follow the
ElementDefinition
syntax. -
defaultValue : Boolean | undefined
module:link/link~LinkDecoratorManualDefinition#defaultValue
Controls whether the decorator is "on" by default.
-
label : String
module:link/link~LinkDecoratorManualDefinition#label
The label of the UI button that the user can use to control the presence of link attributes.
-
mode : 'manual'
module:link/link~LinkDecoratorManualDefinition#mode
Link decorator type. It is
'manual'
for all manual decorators. -
styles : Object | undefined
module:link/link~LinkDecoratorManualDefinition#styles
Key-value pairs used as link styles added to the output during the downcasting. Styles should follow the
ElementDefinition
syntax.
Every day, we work hard to keep our documentation complete. Have you spotted outdated information? Is something missing? Please report it via our issue tracker.