Inconsistency in down-casting the UIElements #8959
Labels
package:engine
squad:core
Issue to be handled by the Core team.
type:improvement
This issue reports a possible enhancement of an existing feature.
Milestone
📝 Provide a description of the improvement
I was checking why putting an
UIElement
inside some text formatted as a code is moving following part of that text and I realized that it's because we split allAttributeElement
s while inserting any element into the view (this is causing the content movement because a<code>
element has the padding so it has 2 additional paddings inside after split):ckeditor5/packages/ckeditor5-engine/src/view/downcastwriter.js
Lines 691 to 692 in f9ff247
On the other hand, if we already have an
UIElement
and we wrap some content with anAttributeElement
then we allow aUIElement
to be wrapped with it (alsoEmptyElement
andRawElement
are allowed):ckeditor5/packages/ckeditor5-engine/src/view/downcastwriter.js
Lines 1171 to 1176 in f9ff247
If you'd like to see this improvement implemented, add a 👍 reaction to this post.
The text was updated successfully, but these errors were encountered: