What is @ckeditor/ckeditor5-special-characters?
@ckeditor/ckeditor5-special-characters is a plugin for CKEditor 5 that allows users to insert special characters into their content. This can be particularly useful for adding symbols, mathematical characters, and other non-standard text elements that are not easily accessible from a standard keyboard.
Inserting Special Characters
This feature allows users to insert special characters into their content. The code sample demonstrates how to add the SpecialCharacters plugin to a CKEditor 5 instance and include it in the toolbar.
ClassicEditor.create(document.querySelector('#editor'), { extraPlugins: [SpecialCharacters], toolbar: ['specialCharacters'] })
Customizing Special Characters
This feature allows users to customize the special characters available in the editor. The code sample shows how to define a custom category of special characters (in this case, arrows) and include it in the editor configuration.
ClassicEditor.create(document.querySelector('#editor'), { extraPlugins: [SpecialCharacters], toolbar: ['specialCharacters'], specialCharacters: { categories: [ { name: 'Arrows', characters: [ '→', '←', '↑', '↓' ] } ] } })