Skip to content

Commit 81e866a

Browse files
committed
Added nbsp; example
1 parent 9745cad commit 81e866a

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

docs/content_management/rich_text/extend_online_editor.md

+12
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
cd ..
12
---
23
description: Add custom tags, styles and data attributes to enrich the functionality of the Online Editor. Change Online Editor configuration.
34
---
@@ -464,3 +465,14 @@ ibexa.addConfig('richText.CKEditor.extraConfig', { specialCharacters: { order: [
464465
```
465466

466467
![CKEditor Special characters: Arrows category on top of the character filter](ckeditor-special-characters_arrows-on-top.png)
468+
469+
You can also use custom functions to modify the plugin configuration. The following example adds the non-breaking space character to the [Special characters plugin](#add-ckeditor-plugins):
470+
```js
471+
function SpecialCharactersNbsp( editor ) {
472+
editor.plugins.get( 'SpecialCharacters' ).addItems( 'Text', [
473+
{ title: 'Non-Breaking Space', character: '\u00a0' }
474+
] );
475+
} );
476+
}
477+
ibexa.addConfig('richText.CKEditor.extraPlugins', [ SpecialCharacters, SpecialCharactersEssentials, SpecialCharactersNbsp ], true);
478+
```

0 commit comments

Comments
 (0)