Skip to content

Commit 6d214a4

Browse files
authored
IBX-9733: Fix custom class for tables not show in subsequent edits (#270)
1 parent 3d6ab04 commit 6d214a4

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

src/bundle/Resources/public/js/CKEditor/core/base-ckeditor.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import Strikethrough from '@ckeditor/ckeditor5-basic-styles/src/strikethrough';
3131
import BlockQuote from '@ckeditor/ckeditor5-block-quote/src/blockquote';
3232
import SpecialCharactersEssentials from '@ckeditor/ckeditor5-special-characters/src/specialcharactersessentials';
3333
import ContextualBalloon from '@ckeditor/ckeditor5-ui/src/panel/balloon/contextualballoon';
34+
import IbexaTable from '../table/table';
3435

3536
const VIEWPORT_TOP_OFFSET = 102;
3637
const VIEWPORT_TOP_OFFSET_DISTRACTION_FREE_MODE = 0;
@@ -189,6 +190,7 @@ const VIEWPORT_TOP_OFFSET_DISTRACTION_FREE_MODE = 0;
189190
IbexaRemoveElement,
190191
IbexaBlockAlignment,
191192
IbexaUploadImage,
193+
IbexaTable,
192194
...extraPlugins,
193195
],
194196
toolbar: {
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
2+
3+
import { addPredefinedClassToConfig } from '../custom-attributes/helpers/config-helper';
4+
5+
class IbexaTable extends Plugin {
6+
constructor(props) {
7+
super(props);
8+
9+
addPredefinedClassToConfig('table', 'table');
10+
}
11+
}
12+
13+
export default IbexaTable;

0 commit comments

Comments
 (0)