Conversation
|
@Reinmar This PR implements the two main plugins:
From that I've implemented 16 commands: For table properties:
For table cell properties:
Please validate if the names are OK (especially if the attribute name is OK ie Most of the commands code is done in base commands which at least in MVP do the same: get a table or cells from selection and apply or remove attribute. If command operates on top/right/bottom/left value object it will set As a simplification (which also works) I've made that command sets one string value in the model instead of |
oleq
left a comment
There was a problem hiding this comment.
LGTM. I pushed documentation fixes straight to the branch because otherwise, GH shows me Unicorns when submitting.
|
@oleq done. Please note that I've added small addition to the docs in the engine so this PR is needed also: ckeditor/ckeditor5-engine#1816. |
Edges are more like contours around the box (containing or not containing the padding, border, etc.) and the box has always 4 sides (top, left, bottom, right).
Suggested merge commit message (convention)
Feature: Introduce table properites conversion. Closes ckeditor/ckeditor5#6048.
PR constallation
Build on ckeditor5/i3287 branch:
Edit:
the build fails because watchdog detectsit is fixed by making StyleConverter a non-enumerable property.StylesConverteras "connected" https://github.com/ckeditor/ckeditor5-watchdog/blob/73844f37f90ea0bf0e0a756752c62b1ce86e334b/src/watchdog.js#L452 because of theStylesConvertersingleton...This PR requires changes:
engine: I/3287: Styles normalization (part of table styles) ckeditor5-engine#1807 (comes with own constellation of changes)ui: I/3287: Temporary PR - add "UI" type of list dropdown ckeditor5-ui#528 (might be reverted as UI is not a part of MVP)Description
This is a draft PR to start review process of this behemoth change. This PR will need at least two reviewers and probably more then 2 passes.
At this stage I'd like to review the general idea behind table styles:
Conversion (
*- means any value but can be constrained byStylesnormalizer):TablePropertieshandles:borderWidth=*,borderColor=*,borderStyle=*(<table style="boder-top:1px solid blue;...">):backgroundColor=*(<table style="background-color:some-color">)width=*/heigh=*(<table style="width:xx">)alignment=left|right|center(<table style="margin-left:0,margin-right:auto">- as in MDN, upcasts also<table aling="left|right|center">).TableCellPropertieshandles:borderWidth=*,borderColor=*,borderStyle=*(<td style="boder-top:1px solid blue;...">)backgroundColor=*(<td style="background-color:some-color">)padding=*(<td style="padding:2em">)verticalAlignment=*(<td style="vertical-align:top">) - should be fixed tohorizontalAlignment=left|fight|center|justify(<td style="text-align:left|right|center"justify">)TableColumnRowPropertieshandles:heigth=*(<td style="height:*">)width=*(<td style="widith:*">)