Sfoglia il codice sorgente

Added the ShiftEnter plugin.

Piotrek Koszuliński 7 anni fa
parent
commit
10387cddd7

+ 3 - 1
packages/ckeditor5-essentials/src/essentials.js

@@ -11,6 +11,7 @@ import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
 
 import Clipboard from '@ckeditor/ckeditor5-clipboard/src/clipboard';
 import Enter from '@ckeditor/ckeditor5-enter/src/enter';
+import ShiftEnter from '@ckeditor/ckeditor5-enter/src/shiftenter';
 import Typing from '@ckeditor/ckeditor5-typing/src/typing';
 import Undo from '@ckeditor/ckeditor5-undo/src/undo';
 
@@ -22,6 +23,7 @@ import Undo from '@ckeditor/ckeditor5-undo/src/undo';
  *
  * * {@link module:clipboard/clipboard~Clipboard},
  * * {@link module:enter/enter~Enter},
+ * * {@link module:enter/shiftenter~ShiftEnter},
  * * {@link module:typing/typing~Typing},
  * * {@link module:undo/undo~Undo}.
  *
@@ -35,7 +37,7 @@ export default class Essentials extends Plugin {
 	 * @inheritDoc
 	 */
 	static get requires() {
-		return [ Clipboard, Enter, Typing, Undo ];
+		return [ Clipboard, Enter, ShiftEnter, Typing, Undo ];
 	}
 
 	/**

+ 2 - 0
packages/ckeditor5-essentials/tests/essentials.js

@@ -10,6 +10,7 @@ import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictest
 
 import Clipboard from '@ckeditor/ckeditor5-clipboard/src/clipboard';
 import Enter from '@ckeditor/ckeditor5-enter/src/enter';
+import ShiftEnter from '@ckeditor/ckeditor5-enter/src/shiftenter';
 import Typing from '@ckeditor/ckeditor5-typing/src/typing';
 import Undo from '@ckeditor/ckeditor5-undo/src/undo';
 
@@ -39,6 +40,7 @@ describe( 'Essentials preset', () => {
 	it( 'should load all its dependencies', () => {
 		expect( editor.plugins.get( Clipboard ) ).to.be.instanceOf( Clipboard );
 		expect( editor.plugins.get( Enter ) ).to.be.instanceOf( Enter );
+		expect( editor.plugins.get( ShiftEnter ) ).to.be.instanceOf( ShiftEnter );
 		expect( editor.plugins.get( Typing ) ).to.be.instanceOf( Typing );
 		expect( editor.plugins.get( Undo ) ).to.be.instanceOf( Undo );
 	} );