/**
 * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
 * For licensing, see LICENSE.md or http://ckeditor.com/license
 */

CKEDITOR.editorConfig = function (config) {
    config.toolbar = 'MyTool';
    config.toolbar_MyTool =
            [
                ['Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord'],
                ['Undo', 'Redo', '-', 'Find', 'Replace', '-', 'SelectAll', 'RemoveFormat'],
                ['Bold', 'Italic', 'Underline', 'Strike', '-', 'Subscript', 'Superscript','CopyFormatting','Blockquote'],
                ['NumberedList', 'BulletedList', 'Indent', 'Outdent', 'CreateDiv'],
                ['TextColor', 'BGColor'],
                ['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock'],
                ['Link', 'Unlink', 'cmslinkarticle', 'cmslinkpage'],
                ['cmsstaticcontainer'],
                ['Image', 'Flash', 'Table', 'HorizontalRule', 'SpecialChar', 'Youtube', 'Html5video' ],
                ['Styles', 'Format', 'Font', 'FontSize', 'lineheight', 'ShowBlocks', 'Source', 'Maximize'],
                [
                    'jsplus_bootstrap_show_blocks', 'jsplus_bootstrap_templates', 'jsplus_bootstrap_block_conf', 'jsplus_bootstrap_col_move_left', 'jsplus_bootstrap_col_move_right', 'jsplus_bootstrap_delete_col',
                    'jsplus_bootstrap_delete_row', 'jsplus_bootstrap_row_move_down', 'jsplus_bootstrap_row_move_up'
                ],
                ['BootstrapCollapse', 'BootstrapTab'],
                [
                    'jsplus_bootstrap_alert', 'jsplus_bootstrap_icons', 'jsplus_bootstrap_button', 'jsplus_bootstrap_badge', 'jsplus_bootstrap_label'
                ],
                [
                    'jsplus_bootstrap_table_new', 'jsplus_bootstrap_table_conf', 'jsplus_bootstrap_table_row_conf', 'jsplus_bootstrap_table_col_conf', 'jsplus_bootstrap_table_cell_conf', 'jsplus_bootstrap_table_row_move_up',
                    'jsplus_bootstrap_table_row_move_down', 'jsplus_bootstrap_table_col_move_left', 'jsplus_bootstrap_table_col_move_right', 'jsplus_bootstrap_table_add_row_up', 'jsplus_bootstrap_table_add_row_down',
                    'jsplus_bootstrap_table_add_col_left', 'jsplus_bootstrap_table_add_col_right', 'jsplus_bootstrap_table_add_cell_left', 'jsplus_bootstrap_table_add_cell_right', 'jsplus_bootstrap_table_delete_col',
                    'jsplus_bootstrap_table_delete_row', 'jsplus_bootstrap_table_delete_cell', 'jsplus_bootstrap_table_merge_cells', 'jsplus_bootstrap_table_merge_cell_right', 'jsplus_bootstrap_table_merge_cell_down',
                    'jsplus_bootstrap_table_split_cell_hor', 'jsplus_bootstrap_table_split_cell_vert'
                ],
                ['jsplus_bootstrap_advanced_blocks']
            ];

    config.toolbar = 'MyToolbar';
    config.toolbar_MyToolbar =
            [
                ['Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord'],
                ['Undo', 'Redo', '-', 'Find', 'Replace', '-', 'SelectAll', 'RemoveFormat'],
                ['Bold', 'Italic', 'Underline', 'Strike', '-', 'Subscript', 'Superscript','CopyFormatting','Blockquote'],
                ['NumberedList', 'BulletedList', 'Indent', 'Outdent', 'CreateDiv'],
                ['TextColor', 'BGColor'],
                ['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock'],
                ['Link', 'Unlink', 'cmslinkarticle', 'cmslinkpage'],
                ['cmsstaticcontainer'],
                ['Image', 'Flash', 'Table', 'HorizontalRule', 'SpecialChar', 'Youtube', 'Html5video' ],
                ['Styles', 'Format', 'Font', 'FontSize', 'lineheight', 'ShowBlocks', 'Source', 'Maximize'],
                [
                    'jsplus_bootstrap_show_blocks', 'jsplus_bootstrap_templates', 'jsplus_bootstrap_block_conf', 'jsplus_bootstrap_col_move_left', 'jsplus_bootstrap_col_move_right', 'jsplus_bootstrap_delete_col',
                    'jsplus_bootstrap_delete_row', 'jsplus_bootstrap_row_move_down', 'jsplus_bootstrap_row_move_up'
                ],
                ['BootstrapCollapse', 'BootstrapTab'],
                [
                    'jsplus_bootstrap_alert', 'jsplus_bootstrap_icons', 'jsplus_bootstrap_button', 'jsplus_bootstrap_badge', 'jsplus_bootstrap_label'
                ],
                [
                    'jsplus_bootstrap_table_new', 'jsplus_bootstrap_table_conf', 'jsplus_bootstrap_table_row_conf', 'jsplus_bootstrap_table_col_conf', 'jsplus_bootstrap_table_cell_conf', 'jsplus_bootstrap_table_row_move_up',
                    'jsplus_bootstrap_table_row_move_down', 'jsplus_bootstrap_table_col_move_left', 'jsplus_bootstrap_table_col_move_right', 'jsplus_bootstrap_table_add_row_up', 'jsplus_bootstrap_table_add_row_down',
                    'jsplus_bootstrap_table_add_col_left', 'jsplus_bootstrap_table_add_col_right', 'jsplus_bootstrap_table_add_cell_left', 'jsplus_bootstrap_table_add_cell_right', 'jsplus_bootstrap_table_delete_col',
                    'jsplus_bootstrap_table_delete_row', 'jsplus_bootstrap_table_delete_cell', 'jsplus_bootstrap_table_merge_cells', 'jsplus_bootstrap_table_merge_cell_right', 'jsplus_bootstrap_table_merge_cell_down',
                    'jsplus_bootstrap_table_split_cell_hor', 'jsplus_bootstrap_table_split_cell_vert'
                ],
                ['jsplus_bootstrap_advanced_blocks']
            ];
    config.toolbar = 'Basic';
    config.toolbar_Basic =
            [
                ['Bold', 'Italic', 'Underline', 'Strike', '-', 'NumberedList', 'BulletedList'],
                ['Link', 'Unlink', 'ckawesome', 'Image'],
                ['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock', '-', 'TextColor', 'BGColor'],
                ['Source', 'Maximize']
            ];
    config.defaultLanguage = 'pl';
    config.extraPlugins = 'blockquote,lineheight,showblocks,indent,justify,font,tableresize,find,texttransform,colorbutton,youtube,cmslinkarticle,cmslinkpage,cmsstaticcontainer,colordialog,googlemaps,ckawesome,'
            + 'jsplus_bootstrap_include,'
            + 'jsplus_bootstrap_block_conf,jsplus_bootstrap_col_move_left,jsplus_bootstrap_col_move_right,jsplus_bootstrap_delete_col,jsplus_bootstrap_delete_row,'
            + 'jsplus_bootstrap_row_move_down,jsplus_bootstrap_row_move_up,jsplus_bootstrap_show_blocks,'
            + 'jsplus_bootstrap_templates,jsplus_bootstrap_table_new,jsplus_bootstrap_button,jsplus_bootstrap_icons,jsplus_bootstrap_badge,jsplus_bootstrap_label,'
            + 'jsplus_bootstrap_breadcrumbs,jsplus_bootstrap_alert,'
            + 'jsplus_bootstrap_table_conf,jsplus_bootstrap_table_row_conf,jsplus_bootstrap_table_col_conf,jsplus_bootstrap_table_cell_conf,jsplus_bootstrap_table_row_move_up,'
            + 'jsplus_bootstrap_table_row_move_down,jsplus_bootstrap_table_col_move_left,jsplus_bootstrap_table_col_move_right,jsplus_bootstrap_table_add_row_up,jsplus_bootstrap_table_add_row_down,'
            + 'jsplus_bootstrap_table_add_col_left,jsplus_bootstrap_table_add_col_right,jsplus_bootstrap_table_add_cell_left,jsplus_bootstrap_table_add_cell_right,jsplus_bootstrap_table_delete_col,'
            + 'jsplus_bootstrap_table_delete_row,jsplus_bootstrap_table_delete_cell,jsplus_bootstrap_table_merge_cells,jsplus_bootstrap_table_merge_cell_right,jsplus_bootstrap_table_merge_cell_down,'
            + 'jsplus_bootstrap_table_split_cell_hor,jsplus_bootstrap_table_split_cell_vert,bootstrapCollapse,bootstrapTab,ckawesome,copyformatting,codemirror,html5video,widget,widgetselection,clipboard,lineutils';

    config.fullPage                             = false;
    config.disableNativeSpellChecker            = false;
    config.bootstrapCollapse_managePopupContent = true;
    config.bootstrapTab_managePopupContent      = true;
    config.mj_variables_allow_html              = true;
    config.copyFormatting_allowedContexts       = true;

    config.jsplus_bootstrap_version = 4;

    config.filebrowserBrowseUrl = '/libraries/filemanager-9.14.1/dialog.php?type=2&editor=ckeditor&akey=c3cb2537d25c0efc9e573d059d79c3b8';
    config.filebrowserImageBrowseUrl = '/libraries/filemanager-9.14.1/dialog.php?type=1&editor=ckeditor&akey=c3cb2537d25c0efc9e573d059d79c3b8';
    config.filebrowserUploadUrl = '/libraries/filemanager-9.14.1/dialog.php?type=2&editor=ckeditor&akey=c3cb2537d25c0efc9e573d059d79c3b8';
    config.contentsCss = '/admin/css/ckeditor.css';

    config.allowedContent = true;
    config.extraAllowedContent = 'img(*)[*]{*};blockquote';
    config.line_height = "10px;12px;14px;16px;18px;20px;22px;24px;26px;28px;30px;32px;34px;36px;38px;40px;42px;";
};