[wpt-sync] Sync PR 47615 - [Editing] Fix errors in applying undo after deleting at block boundary
Categories
(Core :: DOM: Editor, task, P4)
Tracking
()
Tracking | Status | |
---|---|---|
firefox131 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 47615 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/47615
Details from upstream follow.
Sambamurthy Bandaru <sambamurthy.bandaru@microsoft.com> wrote:
[Editing] Fix errors in applying undo after deleting at block boundary
When deleting at the boundary of two editable blocks, the second block
gets merged into the first block. Upon undo both blocks should be
restored to their previous states. Firefox and Safari do this
correctly.In Chromium, this is not happening if the second block has
non-editable nodes. The second block is restored to its previous state
but the first block is still left with non-editable nodes from the
merge.This is because -
|InsertNodeBeforeCommand| that inserts those nodes into first
block checks the editability of the first block to apply the command.
But when undoing, it checks the editablitiy of inserted node and does
not apply undo since the inserted node is non-editable.This is not consistent since the node is non-editable during insert and
undo is not modifying the node itself. The command should check the
editability of the same first block from which the inserted node is
to be removed.Bug: 355485163
Change-Id: Ia9edf952f2dc96f83bd2c1d97c7ff206b844faa9Reviewed-on: https://chromium-review.googlesource.com/5768258
WPT-Export-Revision: 857e203291e87ef1201dc282ef355ee6d83aadbe
Assignee | ||
Updated•3 months ago
|
Assignee | ||
Comment 1•3 months ago
|
||
Assignee | ||
Comment 2•3 months ago
|
||
CI Results
Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 1 tests and 69 subtests
Status Summary
Firefox
OK
: 1
PASS
: 69
Chrome
OK
: 1
PASS
: 68
FAIL
: 1
Safari
OK
: 1
PASS
: 69
Links
Comment 4•3 months ago
|
||
bugherder |
Description
•