View on GitHub

Openui5-CKEditor

CKEditor wrapped in a UI5 control

Download this project as a .zip file Download this project as a tar.gz file

Default usage - full toolbar

jQuery.sap.registerModulePath('openui5','/location/openui5');
jQuery.sap.require("openui5.ckeditor");
var oEditor1 = new openui5.CKEditor({ value: '{/txt}' });

Basic toolbar with dimensions and colour

var oEditor2 = new openui5.CKEditor({
    value: '{/txt}',
    width: "400px",
    height: "150px",
    toolbar: 'Basic',
    uiColor: '#0090ff'
});

Inline editor with default toolbar

var oEditor3 = new openui5.CKEditor({
    value: '{/txt}',
    inline: true
 });

Custom Toolbar

openui5.CKEditorToolbar.myToolbar = [
    ['Source'],
    ['Cut', 'Copy', 'Paste', 'PasteText'],
    ['Undo', 'Redo'],
    '/', //new line
    ['Bold', 'Italic', 'Underline'],
    ['BulletedList', 'NumberedList', 'Blockquote']
];

var oEditor4 = new openui5.CKEditor({
    value: '{/txt}',
    toolbar: 'myToolbar'
});