File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 135
135
// Force ENTER_BR for blockless editable.
136
136
this . enterMode = enterMode = ( editor . blockless ? CKEDITOR . ENTER_BR : editor . config . enterMode ) ;
137
137
138
- this . allow ( 'br ' + ( enterMode == CKEDITOR . ENTER_P ? 'p' : enterMode == CKEDITOR . ENTER_DIV ? 'div' : '' ) , 'default' , 1 ) ;
138
+ var defaultRules = [ 'br' ] ,
139
+ shiftEnterMode = editor . blockless ? CKEDITOR . ENTER_BR : editor . config . shiftEnterMode ;
140
+
141
+ if ( enterMode == CKEDITOR . ENTER_P || shiftEnterMode == CKEDITOR . ENTER_P )
142
+ defaultRules . push ( 'p' ) ;
143
+ if ( enterMode == CKEDITOR . ENTER_DIV || shiftEnterMode == CKEDITOR . ENTER_DIV )
144
+ defaultRules . push ( 'div' ) ;
145
+
146
+ this . allow ( defaultRules . join ( ' ' ) , 'default' , 1 ) ;
139
147
this . allow ( allowedContent , 'config' , 1 ) ;
140
148
this . allow ( editor . config . extraAllowedContent , 'extra' , 1 ) ;
141
149
You can’t perform that action at this time.
0 commit comments