AlignmentConfig (alignment)
@ckeditor/ckeditor5-alignment/src/alignment
The configuration of the alignment feature.
Filtering
Properties
-
options : Array.<(String | AlignmentFormat)>
Available alignment options.
The available options are:
'left'
,'right'
,'center'
and'justify'
. Other values are ignored.Note: It is recommended to always use
'left'
or'right'
as these are default values which the user should normally be able to choose depending on the language of the editor content.By default the alignment is set inline using the
text-align
CSS property. To further customize the alignment, you can provide names of classes for each alignment option using theclassName
property.Note: Once you define the
className
property for one option, you need to specify it for all other options.See the demo of custom alignment options.
Every day, we work hard to keep our documentation complete. Have you spotted an outdated information? Is something missing? Please report it via our issue tracker.