Discrepancy in hoisting text attributes to elements (to selection attributes)
📝 Provide a description of the improvement
https://github.com/user-attachments/assets/df8e9305-9519-4d9d-9c4e-34c95c17add8
Typing over:
<p><b>foo</b></p>
<p>[]</p>
<p><b>foo</b></p>
will behave differently depending on how this content was generated.
If it was generated by applying bold to the first paragraph and then using Enter key to create two more, the second one, even when empty, will preserve this attribute in a form of selection:bold on paragraph.
However, if bold is applied to 3 paragraphs <p>foo</p><p></p><p>foo</p> then the second one won't be styled.
📃 Other details
- Browser: …
- OS: …
- CKEditor version: …
- Installed CKEditor plugins: …
If you'd like to see this improvement implemented, add a 👍 reaction to this post.
Related to https://github.com/ckeditor/ckeditor5/issues/12379.
Related to https://github.com/ckeditor/ckeditor5/issues/10517.
Another one that would need to be fixed: https://github.com/ckeditor/ckeditor5/issues/17152.