Skip to content

[css-position] Define that containing block for fixed positioning is generated by the padding area #3097

@Loirooriol

Description

@Loirooriol

https://drafts.csswg.org/css-position-3/#def-cb just says

If the element has position: fixed, the containing block is established by the viewport in the case of continuous media or the page area in the case of paged media.

However, the containing block can also be generated by an ancestor element e.g. with transform: scale(1).

In this case, the spec needs to define which area of the element (border area, padding area, content area) is used for generating the containing block.

Firefox, Chromium and WebKit(*) use the padding area, just like with absolute positioning. The spec should define this.

(*) WebKit uses the padding area for rendering, but the border area for getComputedStyle, https://bugs.webkit.org/show_bug.cgi?id=189518

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions