- 
                Notifications
    You must be signed in to change notification settings 
- Fork 193
Add CSS page breaking feature #331
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 15 commits
66f17bb
              d2e8c67
              39ebdf7
              1c1c832
              4b1fbdb
              35f915c
              8cb3e6b
              3e3ddf0
              551696a
              8573b81
              1e62555
              42af290
              d084bf7
              59c47a4
              d63c8dd
              69b6e19
              433fc4f
              7add9a9
              537261b
              7196cd5
              File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| # Generated from: column-breaks.yml | ||
| # Do not edit this file by hand. Edit the source file instead! | ||
|  | ||
| name: Column breaks | ||
| description: The `break-after`, `break-before`, `break-inside` CSS properties control where columns start or end. | ||
| spec: https://drafts.csswg.org/css-break-3/#breaking-controls | ||
| caniuse: css-page-break | ||
| status: | ||
| baseline: false | ||
| support: | ||
| chrome: "102" | ||
| chrome_android: "102" | ||
| edge: "102" | ||
| compat_features: | ||
| - css.properties.break-after.multicol_context | ||
| - css.properties.break-after.multicol_context.avoid | ||
| - css.properties.break-after.multicol_context.avoid-column | ||
| - css.properties.break-after.multicol_context.column | ||
| - css.properties.break-before.multicol_context | ||
| - css.properties.break-before.multicol_context.avoid | ||
| - css.properties.break-before.multicol_context.avoid-column | ||
| - css.properties.break-before.multicol_context.column | ||
| - css.properties.break-inside.multicol_context | ||
| - css.properties.break-inside.multicol_context.avoid-column | 
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| name: Column breaks | ||
| description: The `break-after`, `break-before`, `break-inside` CSS properties control where columns start or end. | ||
| spec: https://drafts.csswg.org/css-break-3/#breaking-controls | ||
| caniuse: css-page-break | ||
|         
                  ddbeck marked this conversation as resolved.
              Outdated
          
            Show resolved
            Hide resolved | ||
| compat_features: | ||
| - css.properties.break-after.multicol_context | ||
| - css.properties.break-after.multicol_context.avoid | ||
| - css.properties.break-after.multicol_context.avoid-column | ||
| - css.properties.break-after.multicol_context.column | ||
| - css.properties.break-before.multicol_context | ||
| - css.properties.break-before.multicol_context.avoid | ||
| - css.properties.break-before.multicol_context.avoid-column | ||
| - css.properties.break-before.multicol_context.column | ||
| - css.properties.break-inside.multicol_context | ||
| - css.properties.break-inside.multicol_context.avoid-column | ||
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| # Generated from: page-breaks.yml | ||
| # Do not edit this file by hand. Edit the source file instead! | ||
|  | ||
| name: Page breaks | ||
| description: The `break-after`, `break-before`, `break-inside` CSS properties (along with `page-break-` aliases) control where pages start and end. Also known as pagination or page breaking. | ||
| spec: https://drafts.csswg.org/css-break-3/#breaking-controls | ||
| caniuse: css-page-break | ||
| There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. https://caniuse.com/css-page-break says partial support across the board, except good old Presto of course. Can you add a comment about the difference and if there's anything we need TODO? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, this. Caniuse says everything is partially implemented. Some of this is just out-of-date (e.g., lack of support for  But because nothing is shown as being fully supported on caniuse except Presto, we can't be sure what Alexis meant by fully-supported. I've filed Fyrd/caniuse#7045. The good news here is that I believe we still ought to show a positive status. If caniuse says partially supported, it's still equally partially implemented across all browsers. They seem to have the same set of limitations. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 
 I spoke too soon. 😞 Alexis tested this again and showed that the avoid value is not consistently supported by browsers. I submitted mdn/browser-compat-data#22987 to update the BCD and changed the list of compat keys here to match caniuse. This makes me think that the multicolumn breaks might also be broken, but I couldn't actually find bugs to that effect, so I'm letting that stuff stand. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh my, things are rarely simple. I've reviewed and merged that PR. | ||
| status: | ||
| baseline: high | ||
| baseline_low_date: 2019-01-29 | ||
| baseline_high_date: 2021-07-29 | ||
| support: | ||
| chrome: "50" | ||
| chrome_android: "50" | ||
| edge: "12" | ||
| firefox: "65" | ||
| firefox_android: "65" | ||
| safari: "10" | ||
| safari_ios: "10" | ||
| compat_features: | ||
| - css.properties.break-after | ||
| - css.properties.break-after.paged_context | ||
| - css.properties.break-after.paged_context.page | ||
| - css.properties.break-before | ||
| - css.properties.break-before.paged_context | ||
| - css.properties.break-before.paged_context.page | ||
| - css.properties.break-inside | ||
| - css.properties.break-inside.paged_context | ||
| # `page-break-` are now legacy shorthands | ||
| # https://drafts.csswg.org/css-break/#page-break-properties | ||
| - css.properties.page-break-after | ||
| - css.properties.page-break-before | ||
| - css.properties.page-break-inside | ||
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| name: Page breaks | ||
| description: The `break-after`, `break-before`, `break-inside` CSS properties (along with `page-break-` aliases) control where pages start and end. Also known as pagination or page breaking. | ||
|          | ||
| spec: https://drafts.csswg.org/css-break-3/#breaking-controls | ||
| caniuse: css-page-break | ||
| compat_features: | ||
| - css.properties.break-after | ||
| - css.properties.break-after.paged_context | ||
| - css.properties.break-after.paged_context.page | ||
| - css.properties.break-before | ||
| - css.properties.break-before.paged_context | ||
| - css.properties.break-before.paged_context.page | ||
| - css.properties.break-inside | ||
| - css.properties.break-inside.paged_context | ||
| # `page-break-` are now legacy shorthands | ||
| # https://drafts.csswg.org/css-break/#page-break-properties | ||
| - css.properties.page-break-after | ||
| - css.properties.page-break-before | ||
| - css.properties.page-break-inside | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since
break-afterappears in the other description too, can you say something about the context this feature refers to? It's structurally similar togapin grid and flex contexts, but I don't think we have good wording to copy from.I think the context can be described as the use of
columnsorcolumn-count.