Skip to content

Commit

Permalink
[Editing] Fix content loss during list indent operation
Browse files Browse the repository at this point in the history
While indenting list items, the start_of_paragraph_to_move was not
enclosing all list item children causing content loss. This change
addresses the issue by updating start_of_paragraph_to_move to before
list item's first child.

Spec: https://w3c.github.io/editing/docs/execCommand/#toggling-lists
Bug: 41115285
Change-Id: I211dc63f6408a384055bff7c570289e474c694c1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6217110
Commit-Queue: Tanu Jain <[email protected]>
Reviewed-by: Siye Liu <[email protected]>
Reviewed-by: Kent Tamura <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1417971}
  • Loading branch information
Tanu Jain authored and chromium-wpt-export-bot committed Feb 10, 2025
1 parent 339c547 commit 476d51e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion editing/data/indent.js
Original file line number Diff line number Diff line change
Expand Up @@ -689,7 +689,7 @@ var browserTests = [
{"indent":[false,false,"",false,false,""]}],
["<ol><li>foo<ol><li>bar</ol>[baz]</ol>",
[["indent",""]],
"<ol><li>foo</li><ol><li>bar</li><li>[baz]</li></ol></ol>",
"<ol><ol><li>foo<ol><li>bar</li></ol>[baz]</li></ol></ol>",
[true],
{"indent":[false,false,"",false,false,""]}],
["<ol><li>[foo<ol><li>bar]</ol>baz</ol>",
Expand Down

0 comments on commit 476d51e

Please sign in to comment.