Procházet zdrojové kódy

Group attributes enabling in TableCellPropertiesEditing.init().

Maciej Gołaszewski před 5 roky
rodič
revize
698bc36a94

+ 2 - 3
packages/ckeditor5-table/src/tablecellpropertiesediting.js

@@ -61,9 +61,6 @@ export default class TableCellPropertiesEditing extends Plugin {
 		const viewDoc = editor.editing.view.document;
 
 		viewDoc.addStyleProcessorRules( addBorderRules );
-		viewDoc.addStyleProcessorRules( addPaddingRules );
-		viewDoc.addStyleProcessorRules( addBackgroundRules );
-
 		enableBorderProperties( schema, conversion );
 		editor.commands.add( 'tableCellBorderStyle', new TableCellBorderStyleCommand( editor ) );
 		editor.commands.add( 'tableCellBorderColor', new TableCellBorderColorCommand( editor ) );
@@ -78,9 +75,11 @@ export default class TableCellPropertiesEditing extends Plugin {
 		enableProperty( schema, conversion, 'height', 'height' );
 		editor.commands.add( 'tableCellHeight', new TableCellHeightCommand( editor ) );
 
+		viewDoc.addStyleProcessorRules( addPaddingRules );
 		enableProperty( schema, conversion, 'padding', 'padding' );
 		editor.commands.add( 'tableCellPadding', new TableCellPaddingCommand( editor ) );
 
+		viewDoc.addStyleProcessorRules( addBackgroundRules );
 		enableProperty( schema, conversion, 'backgroundColor', 'background-color' );
 		editor.commands.add( 'tableCellBackgroundColor', new TableCellBackgroundColorCommand( editor ) );