Rework the reframing logic for `<details>` elements
Categories
(Core :: Layout, task, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox70 | --- | fixed |
People
(Reporter: TYLin, Assigned: TYLin)
References
Details
Attachments
(1 file, 1 obsolete file)
Currently, when inserting a range of nodes into <details>
, we treat <details>
frames as if they have multiple insertion points. We then issue several single inserting commands, and insert the range of nodes one by one. However, what we do in inserting one node is merely reframing the <details>
element. Also, the assertion that checks <details>
should accept only single insertion cause bug 1547391 for multicol <details>
with column-span:all
children.
I think we can move the reframing logic for <details>
into nsCSSFrameConstructor::WipeContainingBlock()
, and do reframing if the range of nodes to be inserted contains <summary>
; or do something smarter that checks the <summary>
is going to be the main summary before do reframing.
Comment 1•5 years ago
|
||
Bug 1308080 would also make all this special logic unnecessary.
Assignee | ||
Comment 2•5 years ago
|
||
(In reply to Emilio Cobos Álvarez (:emilio) from comment #1)
Bug 1308080 would also make all this special logic unnecessary.
Right, bug 1308080 can make all this special logic go away. However, before we decide to take the patch, it still better to improve the special reframing logic to fix bug 1547391, and to reframe <details>
only if a main <summary>
is inserted.
Comment hidden (obsolete) |
Comment hidden (obsolete) |
Updated•5 years ago
|
Assignee | ||
Comment 5•5 years ago
|
||
Re comment 0:
do reframing if the range of nodes to be inserted contains <summary>; or do something smarter that checks the <summary> is going to be the main summary before do reframing.
I realize it doesn't work if we only do reframing if the nodes to be inserted containing <summary>
, because if we insert nodes without any <summary>
at the place before <summary>
, the summary frame won't be the first child ...
Anyway, I'll just move the logic to reframe <details>
into WipeContainingBlock
without introducing behavior changes.
Updated•5 years ago
|
Assignee | ||
Comment 6•5 years ago
|
||
David, review ping for this bug and bug 1547391. Thanks.
Comment 8•5 years ago
|
||
bugherder |
Description
•