Skip to content

[css-multicol] how does absolute positioning work in a containing block that was split by a column-span? #1894

@dbaron

Description

@dbaron

I'm filing this based on a discussion I just had with @neerjapancholi. It is related to #1072.

It's not clear to me from the spec how absolute positioning works when the containing block for absolutely positioned elements is split by a column-span.

In particular, if you have markup like:

<div style="column-count: 3">
  <div style="position: relative">
    ... position A ...
    <h2 style="column-span: all">... position B...</h2>
    ... position C ...
  </div>
</div>

then it should be clear what the absolute containing block is for elements at position A, at position B, or at position C. (Consider use of both top and bottom.)

I haven't tested what current implementations do.

One possibility is that they act as though the div with style position:relative was split into three parts, and elements at positions A, B, and C position relative to the appropriate part. Another is that behavior happens at positions A and C, but elements at position B fall back to the next absolute containing block outside of the outermost div.

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions