ckeditor5.schema.yml
Same filename in other branches
File
-
core/
modules/ ckeditor5/ config/ schema/ ckeditor5.schema.yml
View source
- # Schema for the configuration files of the CKEditor 5 module.
-
- editor.settings.ckeditor5:
- type: mapping
- label: 'CKEditor 5 settings'
- mapping:
- toolbar:
- type: mapping
- label: 'Toolbar configuration'
- mapping:
- items:
- type: sequence
- label: 'Items'
- sequence:
- type: ckeditor5.toolbar_item
- label: 'Button'
- constraints:
- # Each active CKEditor 5 toolbar item whose plugin has conditions must have those conditions met.
- CKEditor5ToolbarItemConditionsMet: []
- plugins:
- type: sequence
- label: 'Plugins'
- sequence:
- type: ckeditor5.plugin.[%key]
- constraints:
- # Each enabled CKEditor 5 plugin that implements \Drupal\ckeditor5\Plugin\CKEditor5PluginConfigurableInterface
- # must exist in here.
- CKEditor5EnabledConfigurablePlugins: []
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\Language
- ckeditor5.plugin.ckeditor5_language:
- type: mapping
- label: 'Language'
- mapping:
- language_list:
- type: string
- label: 'Language list ID'
- constraints:
- # Configuring this does not make sense without the corresponding button.
- CKEditor5ToolbarItemDependencyConstraint:
- toolbarItem: textPartLanguage
- # Only two possible values are accepted.
- Choice:
- - un
- - all
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\Heading
- ckeditor5.plugin.ckeditor5_heading:
- type: mapping
- label: Headings
- mapping:
- enabled_headings:
- type: sequence
- label: 'Enabled Headings'
- constraints:
- NotBlank:
- message: "Enable at least one heading, otherwise disable the Heading plugin."
- sequence:
- type: string
- label: 'Heading type'
- constraints:
- Choice:
- callback: \Drupal\ckeditor5\Plugin\CKEditor5Plugin\Heading::validChoices
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\ImageResize
- ckeditor5.plugin.ckeditor5_imageResize:
- type: mapping
- label: Image Resize
- mapping:
- allow_resize:
- type: boolean
- label: 'Allow resize'
- constraints:
- NotNull: []
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\SourceEditing
- ckeditor5.plugin.ckeditor5_sourceEditing:
- type: mapping
- label: Source Editing
- mapping:
- allowed_tags:
- type: sequence
- label: 'Allowed Tags'
- sequence:
- type: ckeditor5.element
- label: 'Allowed Tag'
- constraints:
- SourceEditingRedundantTags: []
- SourceEditingPreventSelfXssConstraint: []
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\Alignment
- ckeditor5.plugin.ckeditor5_alignment:
- type: mapping
- label: Alignments
- mapping:
- enabled_alignments:
- type: sequence
- label: 'Enabled Alignments'
- constraints:
- NotBlank:
- message: "Enable at least one alignment, otherwise disable the Alignment button."
- sequence:
- type: string
- label: 'Alignment type'
- constraints:
- Choice:
- - left
- - center
- - right
- - justify
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\ListPlugin
- ckeditor5.plugin.ckeditor5_list:
- type: mapping
- label: List
- mapping:
- reversed:
- type: boolean
- label: 'Allow reverse list'
- constraints:
- NotNull: []
- startIndex:
- type: boolean
- label: 'Allow start index'
- constraints:
- NotNull: []
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\Media
- ckeditor5.plugin.media_media:
- type: mapping
- label: Media
- mapping:
- allow_view_mode_override:
- type: boolean
- label: 'Allow view mode override'
- constraints:
- NotNull: []
-
- # Plugin \Drupal\ckeditor5\Plugin\CKEditor5Plugin\Style
- ckeditor5.plugin.ckeditor5_style:
- type: mapping
- label: Style
- mapping:
- styles:
- type: sequence
- label: 'Styles'
- constraints:
- NotBlank:
- message: "Enable at least one style, otherwise disable the Style plugin."
- UniqueLabelInList:
- labelKey: label
- sequence:
- type: mapping
- label: 'Style'
- mapping:
- label:
- type: label
- label: 'Style label'
- element:
- type: ckeditor5.element
- constraints:
- # Validate that this contains exactly 1 attribute (class) and >=1 class attr value.
- CKEditor5Element:
- requiredAttributes:
- -
- attributeName: class
- minAttributeValueCount: 1
- StyleSensibleElement: []
- label: 'Style tag + classes'
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.