Skip to content

[css-page-3] - looking for clarification of interaction of differing "page" properties and "break-after: avoid-page" for chapterhead pages #10716

Open
@RobMayer

Description

@RobMayer

I'm looking for clarification on how these two properties interact. I think there may be a gap in functionality when it comes to page layout design.

for example, suppose I have this html and css

<main>
    <h2>Chapter Title</h2>
    <p>Enough content to fill 2.5 pages</p>
</main>
@page typical {
    ...whatever
}
@page chapterhead {
    ...whatever
}
main {
    page: typical;
}
h2 {
    page: chapterhead;
    break-before: page;
    break-after: avoid-page;
}

should this:

  • result in 4 pages [chapterhead, typical, typical, typical] where <h2> exists on its own page
  • result in 3 pages [chapterhead, typical, typical] where the first page is the <h2> and whatever amount of the <p> will fit on the rest of the "chapterhead" page and then run into the "typical" pages?
  • result in 5 pages: [typical, chapterhead, typical, typical, typical] where the first page is blank because Main starts on "typical" but the h2 forces a break with "chapterhead" and the <p> flows back into typical because its the first non-auto in the hierarchy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Closed as Question AnsweredUsed when the issue is more of a question than a problem, and it's been answered.css-page-3Current Work

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions