File tree Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ class JsonEditorPluginsAsset extends AssetBundle
2121 public $ js = [
2222 'editors/filefly.js ' ,
2323 'editors/ckeditor.js ' ,
24+ 'editors/ckplugins/divarea.js ' ,
2425 ];
2526
2627 public $ depends = [
@@ -29,4 +30,4 @@ class JsonEditorPluginsAsset extends AssetBundle
2930 JqueryAsset::class
3031 ];
3132
32- }
33+ }
Original file line number Diff line number Diff line change 1+ CKEDITOR . plugins . add ( "divarea" , {
2+ afterInit : function ( a ) {
3+ a . addMode ( "wysiwyg" , function ( c ) {
4+ var b = CKEDITOR . dom . element . createFromHtml ( '\x3cdiv class\x3d"cke_wysiwyg_div cke_reset cke_enable_context_menu" hidefocus\x3d"true"\x3e\x3c/div\x3e' ) ;
5+ a . ui . space ( "contents" ) . append ( b ) ;
6+ b = a . editable ( b ) ;
7+ b . detach = CKEDITOR . tools . override ( b . detach , function ( a ) {
8+ return function ( ) {
9+ a . apply ( this , arguments ) ;
10+ this . remove ( )
11+ }
12+ } ) ;
13+ a . setData ( a . getData ( 1 ) , c ) ;
14+ a . fire ( "contentDom" )
15+ } )
16+ }
17+ } ) ;
You can’t perform that action at this time.
0 commit comments