#16810 closed Bug (fixed)
Missing table vertical align when pasted from Word
Reported by: | Marek Lewandowski | Owned by: | Marek Lewandowski |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 4.7.0 |
Component: | Plugin : Paste from Word | Version: | 4.6.0 |
Keywords: | Cc: |
Description
Steps to reproduce
- Open attached
Table_vertical_alignment.docx
document in Word. - Copy it's content.
- Paste into a full featured editor.
Expected result
Table cells keeps it's different alignments.
Actual result
Alignments are stripped.
Attachments (3)
Change History (14)
comment:1 Changed 8 years ago by
Status: | new → confirmed |
---|
comment:2 Changed 8 years ago by
Owner: | set to Marek Lewandowski |
---|---|
Status: | confirmed → review |
Changed 8 years ago by
Attachment: | Screenshot from 2017-01-20 17-36-21.png added |
---|
Changed 8 years ago by
Attachment: | Screenshot from 2017-01-20 17-36-41.png added |
---|
comment:3 Changed 8 years ago by
Status: | review → review_failed |
---|
The attribute is preserved and present in the resulting content, but there's one problem:
In the paste from Word dialog the vertical align is clearly visible - that's expected.
In the editable though it is not. Switching to source or inspecting the HTML reveals, that the attribute is indeed present, but apparently it's overridden by something(perhaps some CSS rules).
EDIT: attached screenshots.
Changed 8 years ago by
Attachment: | Table_vertical_alignment.docx added |
---|
comment:4 Changed 8 years ago by
Status: | review_failed → review |
---|
The issue here was that ACF was stripping it, as tabletools were registering only style=vertical-align
ACF rule, without any transformations for it.
Solution here was to add support for converting table valign
to the format that tabletools uses.
It make sense to check integration with "Cell properties" dialog.
Unfortunately there's another issue, that PFW doesn't preserve table/cell height - thus one can't really see the alignment. This will be extracted into a separate ticket (#16812).
Repushed to t/16810.
comment:5 Changed 8 years ago by
Status: | review → review_passed |
---|
Taking into account that the table/cell height is a separate issue LGTM.
Although I see that the build isn't passing. Checking this now.
comment:6 Changed 8 years ago by
Status: | review_passed → review_failed |
---|
There are failing unit tests in the PFW suite.
comment:7 Changed 8 years ago by
Status: | review_failed → review |
---|
It was broken with git:a25120c43cbf5d2aee7051d8697f368dccae7234 fixtures were prepared for valign
attribute, while transformation would convert it into a CSS style.
Actually it make sense to apply the transformation only if CSS property is allowed (otherwise it might be lost, even though td[valign]
was allowed). Updated tests to work with valign
in branch:t/16810.
comment:8 Changed 8 years ago by
Status: | review → review_passed |
---|
I have some doubts about this solution, but since there are tests that specifically test this feature it doesn't matter.
LGTM.
comment:9 Changed 8 years ago by
Resolution: | → fixed |
---|---|
Status: | review_passed → closed |
Fixed with git:85631f3f3670488c325c1c87fae7cd0928ef930e.
comment:10 Changed 8 years ago by
Component: | General → Plugin : Paste from Word |
---|
comment:11 Changed 8 years ago by
Summary: | Missing vertical align when pasted from Word → Missing table vertical align when pasted from Word |
---|
Pushed to branch:t/16810