Closed
Description
The Run-In Layout says
- If a run-in sequence is immediately followed by a block box [...], it is inserted as direct children of the block box [...]. This step recurses if possible [...].
- Otherwise, an anonymous block box is generated around the run-in sequence and all immediately following inline-level content [...].
My understanding is that if I have
<div style="display: list-item; list-style: inside">
<span style="display: run-in">Run-in</span>
</div>
then the condition from step 2 does not hold, and thus the "otherwise" from step 3 wraps the run-in inside a block box. So the run-in and the ::marker
appear at different lines.
But I'm not sure about this:
<span style="display: run-in">Run-in</span>
<div style="display: list-item; list-style: inside"></div>
The condition from step 2 does hold, and thus the run-in is inserted inside the div after its ::marker
, and recursion is attempted. But the condition does no longer hold. Then, does step 3 run or not, i.e. does the "otherwise" refer to the outermost or to the innermost condition in the recursion? If step 3 runs it would be like in the previous example, if it does not the run-in and the ::marker
will appear at the same line.