#9063 closed Bug (fixed)
Font styling lost on sub-lists when the indent on the parent list is decreased
Reported by: | Teresa Monahan | Owned by: | Garry Yao |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.6.4 |
Component: | Core : Lists | Version: | 3.6.4 |
Keywords: | IBM | Cc: | Damian, Satya Minnekanti |
Description
To reproduce:
- Copy the following into the Source view of the editor:
<ul style="font-size: 10px;"> <li>Level 1 - size 10 <ul style="font-size: 24px;"> <li>Level 2 - size 24</li> </ul> </li> <li>Level 1 - size 10</li> </ul>
- Switch to wysiwyg mode and select the entire editor contents.
- Select 'Decrease Indent' on the toolbar. The margin of both lists will be decreased and the level 1 list will no longer be a list.
Expected result: The level 2 list should remain a list and should keep its font styling.
Actual result: The level 2 list remains as a list but its font styling is lost.
The markup after the 'Decrease Indent' action looks like:
<p> Level 1 - size 10</p> <ul> <li>Level 2 - size 24</li> </ul> <p> Level 1 - size 10</p>
It should be:
<p> Level 1 - size 10</p> <ul style="font-size: 24px;"> <li>Level 2 - size 24</li> </ul> <p> Level 1 - size 10</p>
Attachments (2)
Change History (12)
Changed 12 years ago by
Attachment: | 9063.patch added |
---|
comment:1 Changed 12 years ago by
Owner: | set to Garry Yao |
---|---|
Status: | new → review |
comment:2 Changed 12 years ago by
Component: | General → Core : Lists |
---|
comment:3 Changed 12 years ago by
Status: | review → review_failed |
---|
This test fails after patch: http://ckeditor.t/tt/8997/1.html
comment:4 Changed 12 years ago by
Milestone: | → CKEditor 3.6.4 |
---|
Changed 12 years ago by
Attachment: | 9063_2.patch added |
---|
comment:5 Changed 12 years ago by
Status: | review_failed → review |
---|
comment:6 Changed 12 years ago by
Status: | review → review_passed |
---|
comment:7 follow-up: 8 Changed 12 years ago by
Resolution: | → fixed |
---|---|
Status: | review_passed → closed |
Fixed with [7522].
comment:8 Changed 12 years ago by
Replying to garry.yao:
Fixed with [7522].
The supplied fix results in the following HTML after the 'Decrease Indent' action:
<p style="font-size: 10px;"> Level 1 - size 10</p> <ul style="font-size: 24px;"> <li>Level 2 - size 24</li> </ul> <p style="font-size: 10px;"> Level 1 - size 10</p>
The problem with this is that the font-size is not reflected in the toolbar for the paragraph elements. Even if the user does change the font size on the paragraph text, the original font-size will still remain on the P element:
<p style="font-size: 10px;"> <span style="font-size:14px;">Level 1 - size 10</span></p>
Can this font-size be moved into a span tag for the paragraph contents instead when the list is outdented, so that the font-size is reflected on the toolbar? i.e.
<p> <span style="font-size:10px;">Level 1 - size 10</span></p> <ul style="font-size: 24px;"> <li>Level 2 - size 24</li> </ul> <p> <span style="font-size:10px;">Level 1 - size 10</span></p>
If this is too complex a change right now, would it be possible to only keep the font-size style for UL and OL elements? i.e.
<p> Level 1 - size 10</p> <ul style="font-size: 24px;"> <li>Level 2 - size 24</li> </ul> <p> Level 1 - size 10</p>
comment:9 Changed 12 years ago by
@tmonahan I have moved your comment to new ticket #9076.
Let's consider this one as fixed and continue in that other ticket.
http://ckeditor.t/tt/9063/1.html