-
Notifications
You must be signed in to change notification settings - Fork 665
HTMLEditor: Fix nested numbered list counter resetting (T1320286) #32582
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 26_1
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -24,6 +24,14 @@ $transparent-border: 1px solid transparent; | |||||
| @return list-#{$counter}; | ||||||
| } | ||||||
|
|
||||||
| @function add-counter-set($counter, $start: 1) { | ||||||
| @if $counter > $start { | ||||||
| @return add-counter-set($counter - 1, $start) + " " + list-#{$counter} + " 0"; | ||||||
| } | ||||||
|
|
||||||
| @return list-#{$counter} + " 0"; | ||||||
| } | ||||||
|
|
||||||
| @mixin if-less-then-max-indent($value) { | ||||||
| @if $value < $max-indent { | ||||||
| li.ql-indent-#{$value} { | ||||||
|
|
@@ -196,7 +204,11 @@ $transparent-border: 1px solid transparent; | |||||
| padding: 2px 5px; | ||||||
| } | ||||||
|
|
||||||
| ol, | ||||||
| ol { | ||||||
| padding-inline-start: 1.5em; | ||||||
| counter-reset: add-counter-reset($max-indent); | ||||||
| } | ||||||
|
|
||||||
| ul { | ||||||
| padding-inline-start: 1.5em; | ||||||
| } | ||||||
|
|
@@ -240,14 +252,17 @@ $transparent-border: 1px solid transparent; | |||||
| } | ||||||
|
|
||||||
| li[data-list="ordered"] { | ||||||
| counter-reset: add-counter-reset($max-indent); | ||||||
| counter-increment: list-0; | ||||||
|
|
||||||
| &::before { | ||||||
| content: counter(list-0, list.nth($list-style, 1)) ". "; | ||||||
| } | ||||||
| } | ||||||
|
|
||||||
| li[data-list="ordered"]:not([class*="ql-indent"]) { | ||||||
| counter-set: add-counter-set($max-indent); | ||||||
|
||||||
| counter-set: add-counter-set($max-indent); | |
| counter-reset: add-counter-set($max-indent); |
Uh oh!
There was an error while loading. Please reload this page.