Opened 6 years ago
Closed 6 years ago
#44775 closed defect (bug) (fixed)
Twenty Seventeen: Ordered List's "start" attribute doesn't work inside Post/Page Editor
Reported by: | mmaumio | Owned by: | laurelfulford |
---|---|---|---|
Milestone: | 5.0.2 | Priority: | normal |
Severity: | normal | Version: | 4.9.8 |
Component: | Bundled Theme | Keywords: | has-patch has-screenshots fixed-5.0 |
Focuses: | Cc: |
Description
Ordered list with a start attribute like this "<ol start="8"></ol>" doesn't show the list from the number specified on the editor.
It works great in the front end though.
So, the visual appearances of ol with start attribute in front-end and back-end are different.
Also, the numbers are bold in the editor whereas they are regular on the front end.
Isn't it the purpose of the Visual Editor to keep them visually similar at both ends?
Please, amend me if I'm wrong.
I have attached some screenshots along with a patch.
Attachments (5)
Change History (16)
#1
@
6 years ago
- Summary changed from Ordered List "start" attribute doesn't work inside Post/Page Editor in TwentySeventeen Theme to Ordered List's "start" attribute doesn't work inside Post/Page Editor in TwentySeventeen Theme
#2
@
6 years ago
- Summary changed from Ordered List's "start" attribute doesn't work inside Post/Page Editor in TwentySeventeen Theme to Twenty Seventeen: Ordered List's "start" attribute doesn't work inside Post/Page Editor
#3
@
6 years ago
- Keywords needs-refresh added; needs-testing 2nd-opinion removed
- Milestone changed from Awaiting Review to 5.0.1
Thank you for reporting this issue, @mmaumio, and for your patch!
The bold numbered styles were originally going to be in Twenty Seventeen, but they ended up causing some issues (like breaking the start
attribute) and were removed from the front end. It looks like they were missed in the editor styles, though.
I've tested your patch, and the fix looks good! The start attribute is actually followed now, and lists are styled to look like they do on the front-end.
One thing I do notice is that there's still a bit of CSS left in the editor-style.css related to the old list styles -- specifically:
ol { counter-reset: item; }
and
.rtl ol { counter-reset: item; }
Neither of these styles is actually causing an issue, but they're also no longer needed. Are you able to refresh your patch with those styles removed as well?
Just let me know if you have any questions at all about the above!
@
6 years ago
Thank you for your insights @laurelfulford I've made the amendment and uploaded the new patch.
#4
@
6 years ago
- Keywords needs-refresh removed
- Owner set to laurelfulford
- Status changed from new to reviewing
Thanks for updating the patch, @mmaumio!
#7
@
6 years ago
- Keywords commit added
- Status changed from reviewing to accepted
Thanks @mmaumio! olstartfixamend.diff looks good to me!
I'm going to mark this as commit in hopes it can get in with the 5.0.2 changes - otherwise, it should be able to be added to 5.1.
Also, I belatedly realized that #40137 is an earlier ticket that duplicates part of the same issue: the numbers in the editor were not correct.
I've closed that ticket in favour of this one since it's ready to go, but @edpittol should also get props in this commit for the work done in #40137 (thanks @edpittol!).
This is how it looked before the patch