CINXE.COM
CSS Fragmentation Module Level 4
<!doctype html><html lang="en"> <head> <meta content="text/html; charset=utf-8" http-equiv="Content-Type"> <meta content="width=device-width, initial-scale=1, shrink-to-fit=no" name="viewport"> <title>CSS Fragmentation Module Level 4</title> <meta content="ED" name="w3c-status"> <link href="https://www.w3.org/StyleSheets/TR/2021/W3C-ED" rel="stylesheet"> <link href="https://www.w3.org/2008/site/images/favicon.ico" rel="icon"> <meta content="Bikeshed version 449443d, updated Fri Jun 24 16:40:12 2022 -0700" name="generator"> <link href="https://www.w3.org/TR/css-break-4/" rel="canonical"> <link href="https://drafts.csswg.org/csslogo.ico" rel="icon"> <style>/* style-autolinks */ .css.css, .property.property, .descriptor.descriptor { color: var(--a-normal-text); font-size: inherit; font-family: inherit; } .css::before, .property::before, .descriptor::before { content: "‘"; } .css::after, .property::after, .descriptor::after { content: "’"; } .property, .descriptor { /* Don't wrap property and descriptor names */ white-space: nowrap; } .type { /* CSS value <type> */ font-style: italic; } pre .property::before, pre .property::after { content: ""; } [data-link-type="property"]::before, [data-link-type="propdesc"]::before, [data-link-type="descriptor"]::before, [data-link-type="value"]::before, [data-link-type="function"]::before, [data-link-type="at-rule"]::before, [data-link-type="selector"]::before, [data-link-type="maybe"]::before { content: "‘"; } [data-link-type="property"]::after, [data-link-type="propdesc"]::after, [data-link-type="descriptor"]::after, [data-link-type="value"]::after, [data-link-type="function"]::after, [data-link-type="at-rule"]::after, [data-link-type="selector"]::after, [data-link-type="maybe"]::after { content: "’"; } [data-link-type].production::before, [data-link-type].production::after, .prod [data-link-type]::before, .prod [data-link-type]::after { content: ""; } [data-link-type=element], [data-link-type=element-attr] { font-family: Menlo, Consolas, "DejaVu Sans Mono", monospace; font-size: .9em; } [data-link-type=element]::before { content: "<" } [data-link-type=element]::after { content: ">" } [data-link-type=biblio] { white-space: pre; }</style> <style>/* style-colors */ /* Any --*-text not paired with a --*-bg is assumed to have a transparent bg */ :root { color-scheme: light dark; --text: black; --bg: white; --unofficial-watermark: url(https://www.w3.org/StyleSheets/TR/2016/logos/UD-watermark); --logo-bg: #1a5e9a; --logo-active-bg: #c00; --logo-text: white; --tocnav-normal-text: #707070; --tocnav-normal-bg: var(--bg); --tocnav-hover-text: var(--tocnav-normal-text); --tocnav-hover-bg: #f8f8f8; --tocnav-active-text: #c00; --tocnav-active-bg: var(--tocnav-normal-bg); --tocsidebar-text: var(--text); --tocsidebar-bg: #f7f8f9; --tocsidebar-shadow: rgba(0,0,0,.1); --tocsidebar-heading-text: hsla(203,20%,40%,.7); --toclink-text: var(--text); --toclink-underline: #3980b5; --toclink-visited-text: var(--toclink-text); --toclink-visited-underline: #054572; --heading-text: #005a9c; --hr-text: var(--text); --algo-border: #def; --del-text: red; --del-bg: transparent; --ins-text: #080; --ins-bg: transparent; --a-normal-text: #034575; --a-normal-underline: #bbb; --a-visited-text: var(--a-normal-text); --a-visited-underline: #707070; --a-hover-bg: rgba(75%, 75%, 75%, .25); --a-active-text: #c00; --a-active-underline: #c00; --blockquote-border: silver; --blockquote-bg: transparent; --blockquote-text: currentcolor; --issue-border: #e05252; --issue-bg: #fbe9e9; --issue-text: var(--text); --issueheading-text: #831616; --example-border: #e0cb52; --example-bg: #fcfaee; --example-text: var(--text); --exampleheading-text: #574b0f; --note-border: #52e052; --note-bg: #e9fbe9; --note-text: var(--text); --noteheading-text: hsl(120, 70%, 30%); --notesummary-underline: silver; --assertion-border: #aaa; --assertion-bg: #eee; --assertion-text: black; --advisement-border: orange; --advisement-bg: #fec; --advisement-text: var(--text); --advisementheading-text: #b35f00; --warning-border: red; --warning-bg: hsla(40,100%,50%,0.95); --warning-text: var(--text); --amendment-border: #330099; --amendment-bg: #F5F0FF; --amendment-text: var(--text); --amendmentheading-text: #220066; --def-border: #8ccbf2; --def-bg: #def; --def-text: var(--text); --defrow-border: #bbd7e9; --datacell-border: silver; --indexinfo-text: #707070; --indextable-hover-text: black; --indextable-hover-bg: #f7f8f9; --outdatedspec-bg: rgba(0, 0, 0, .5); --outdatedspec-text: black; --outdated-bg: maroon; --outdated-text: white; --outdated-shadow: red; --editedrec-bg: darkorange; }</style> <style>/* style-counters */ body { counter-reset: example figure issue; } .issue { counter-increment: issue; } .issue:not(.no-marker)::before { content: "Issue " counter(issue); } .example { counter-increment: example; } .example:not(.no-marker)::before { content: "Example " counter(example); } .invalid.example:not(.no-marker)::before, .illegal.example:not(.no-marker)::before { content: "Invalid Example" counter(example); } figcaption { counter-increment: figure; } figcaption:not(.no-marker)::before { content: "Figure " counter(figure) " "; }</style> <style>/* style-dfn-panel */ :root { --dfnpanel-bg: #ddd; --dfnpanel-text: var(--text); } .dfn-panel { position: absolute; z-index: 35; height: auto; width: -webkit-fit-content; width: fit-content; max-width: 300px; max-height: 500px; overflow: auto; padding: 0.5em 0.75em; font: small Helvetica Neue, sans-serif, Droid Sans Fallback; background: var(--dfnpanel-bg); color: var(--dfnpanel-text); border: outset 0.2em; } .dfn-panel:not(.on) { display: none; } .dfn-panel * { margin: 0; padding: 0; text-indent: 0; } .dfn-panel > b { display: block; } .dfn-panel a { color: var(--dfnpanel-text); } .dfn-panel a:not(:hover) { text-decoration: none !important; border-bottom: none !important; } .dfn-panel > b + b { margin-top: 0.25em; } .dfn-panel ul { padding: 0; } .dfn-panel li { list-style: inside; } .dfn-panel.activated { display: inline-block; position: fixed; left: .5em; bottom: 2em; margin: 0 auto; max-width: calc(100vw - 1.5em - .4em - .5em); max-height: 30vh; } .dfn-paneled { cursor: pointer; } </style> <style>/* style-issues */ a[href].issue-return { float: right; float: inline-end; color: var(--issueheading-text); font-weight: bold; text-decoration: none; } </style> <style>/* style-md-lists */ /* This is a weird hack for me not yet following the commonmark spec regarding paragraph and lists. */ [data-md] > :first-child { margin-top: 0; } [data-md] > :last-child { margin-bottom: 0; }</style> <style>/* style-mdn-anno */ @media (max-width: 767px) { .mdn-anno { opacity: .1 } } .mdn-anno { font: 1em sans-serif; padding: 0.3em; position: absolute; z-index: 8; right: 0.3em; background: #EEE; color: black; box-shadow: 0 0 3px #999; overflow: hidden; border-collapse: initial; border-spacing: initial; min-width: 9em; max-width: min-content; white-space: nowrap; word-wrap: normal; hyphens: none} .mdn-anno:not(.wrapped) { opacity: 1} .mdn-anno:hover { z-index: 9 } .mdn-anno.wrapped { min-width: 0 } .mdn-anno.wrapped > :not(button) { display: none; } .mdn-anno > .mdn-anno-btn { cursor: pointer; border: none; color: #000; background: transparent; margin: -8px; float: right; padding: 10px 8px 8px 8px; outline: none; } .mdn-anno > .mdn-anno-btn > .less-than-two-engines-flag { color: red; padding-right: 2px; } .mdn-anno > .mdn-anno-btn > .all-engines-flag { color: green; padding-right: 2px; } .mdn-anno > .mdn-anno-btn > span { color: #fff; background-color: #000; font-weight: normal; font-family: zillaslab, Palatino, "Palatino Linotype", serif; padding: 2px 3px 0px 3px; line-height: 1.3em; vertical-align: top; } .mdn-anno > .feature { margin-top: 20px; } .mdn-anno > .feature:not(:first-of-type) { border-top: 1px solid #999; margin-top: 6px; padding-top: 2px; } .mdn-anno > .feature > .less-than-two-engines-text { color: red } .mdn-anno > .feature > .all-engines-text { color: green } .mdn-anno > .feature > p { font-size: .75em; margin-top: 6px; margin-bottom: 0; } .mdn-anno > .feature > p + p { margin-top: 3px; } .mdn-anno > .feature > .support { display: block; font-size: 0.6em; margin: 0; padding: 0; margin-top: 2px } .mdn-anno > .feature > .support + div { padding-top: 0.5em; } .mdn-anno > .feature > .support > hr { display: block; border: none; border-top: 1px dotted #999; padding: 3px 0px 0px 0px; margin: 2px 3px 0px 3px; } .mdn-anno > .feature > .support > hr::before { content: ""; } .mdn-anno > .feature > .support > span { padding: 0.2em 0; display: block; display: table; } .mdn-anno > .feature > .support > span.no { color: #CCCCCC; filter: grayscale(100%); } .mdn-anno > .feature > .support > span.no::before { opacity: 0.5; } .mdn-anno > .feature > .support > span:first-of-type { padding-top: 0.5em; } .mdn-anno > .feature > .support > span > span { padding: 0 0.5em; display: table-cell; } .mdn-anno > .feature > .support > span > span:first-child { width: 100%; } .mdn-anno > .feature > .support > span > span:last-child { width: 100%; white-space: pre; padding: 0; } .mdn-anno > .feature > .support > span::before { content: ' '; display: table-cell; min-width: 1.5em; height: 1.5em; background: no-repeat center center; background-size: contain; text-align: right; font-size: 0.75em; font-weight: bold; } .mdn-anno > .feature > .support > .chrome_android::before { background-image: url(https://resources.whatwg.org/browser-logos/chrome.svg); } .mdn-anno > .feature > .support > .firefox_android::before { background-image: url(https://resources.whatwg.org/browser-logos/firefox.png); } .mdn-anno > .feature > .support > .chrome::before { background-image: url(https://resources.whatwg.org/browser-logos/chrome.svg); } .mdn-anno > .feature > .support > .edge_blink::before { background-image: url(https://resources.whatwg.org/browser-logos/edge.svg); } .mdn-anno > .feature > .support > .edge::before { background-image: url(https://resources.whatwg.org/browser-logos/edge_legacy.svg); } .mdn-anno > .feature > .support > .firefox::before { background-image: url(https://resources.whatwg.org/browser-logos/firefox.png); } .mdn-anno > .feature > .support > .ie::before { background-image: url(https://resources.whatwg.org/browser-logos/ie.png); } .mdn-anno > .feature > .support > .safari_ios::before { background-image: url(https://resources.whatwg.org/browser-logos/safari-ios.svg); } .mdn-anno > .feature > .support > .nodejs::before { background-image: url(https://nodejs.org/static/images/favicons/favicon.ico); } .mdn-anno > .feature > .support > .opera_android::before { background-image: url(https://resources.whatwg.org/browser-logos/opera.svg); } .mdn-anno > .feature > .support > .opera::before { background-image: url(https://resources.whatwg.org/browser-logos/opera.svg); } .mdn-anno > .feature > .support > .safari::before { background-image: url(https://resources.whatwg.org/browser-logos/safari.png); } .mdn-anno > .feature > .support > .samsunginternet_android::before { background-image: url(https://resources.whatwg.org/browser-logos/samsung.svg); } .mdn-anno > .feature > .support > .webview_android::before { background-image: url(https://resources.whatwg.org/browser-logos/android-webview.png); } .name-slug-mismatch { color: red } .caniuse-status:hover { z-index: 9; } /* dt, li, .issue, .note, and .example are "position: relative", so to put annotation at right margin, must move to right of containing block */ .h-entry:not(.status-LS) dt > .mdn-anno, .h-entry:not(.status-LS) li > .mdn-anno, .h-entry:not(.status-LS) .issue > .mdn-anno, .h-entry:not(.status-LS) .note > .mdn-anno, .h-entry:not(.status-LS) .example > .mdn-anno { right: -6.7em; } .h-entry p + .mdn-anno { margin-top: 0; } h2 + .mdn-anno.after { margin: -48px 0 0 0; } h3 + .mdn-anno.after { margin: -46px 0 0 0; } h4 + .mdn-anno.after { margin: -42px 0 0 0; } h5 + .mdn-anno.after { margin: -40px 0 0 0; } h6 + .mdn-anno.after { margin: -40px 0 0 0; } </style> <style>/* style-selflinks */ :root { --selflink-text: white; --selflink-bg: gray; --selflink-hover-text: black; } .heading, .issue, .note, .example, li, dt { position: relative; } a.self-link { position: absolute; top: 0; left: calc(-1 * (3.5rem - 26px)); width: calc(3.5rem - 26px); height: 2em; text-align: center; border: none; transition: opacity .2s; opacity: .5; } a.self-link:hover { opacity: 1; } .heading > a.self-link { font-size: 83%; } li > a.self-link { left: calc(-1 * (3.5rem - 26px) - 2em); } dfn > a.self-link { top: auto; left: auto; opacity: 0; width: 1.5em; height: 1.5em; background: var(--selflink-bg); color: var(--selflink-text); font-style: normal; transition: opacity .2s, background-color .2s, color .2s; } dfn:hover > a.self-link { opacity: 1; } dfn > a.self-link:hover { color: var(--selflink-hover-text); } a.self-link::before { content: "¶"; } .heading > a.self-link::before { content: "§"; } dfn > a.self-link::before { content: "#"; } </style> <style>/* style-wpt */ :root { --wpt-border: hsl(0, 0%, 60%); --wpt-bg: hsl(0, 0%, 95%); --wpt-text: var(--text); --wptheading-text: hsl(0, 0%, 30%); } @media (prefers-color-scheme: dark) { :root { --wpt-border: hsl(0, 0%, 30%); --wpt-bg: var(--borderedblock-bg); --wpt-text: var(--text); --wptheading-text: hsl(0, 0%, 60%); } } .wpt-tests-block { list-style: none; border-left: .5em solid var(--wpt-border); background: var(--wpt-bg); color: var(--wpt-text); margin: 1em auto; padding: .5em; } .wpt-tests-block summary { color: var(--wptheading-text); font-weight: normal; text-transform: uppercase; } .wpt-tests-block summary::marker{ color: var(--wpt-border); } .wpt-tests-block summary:hover::marker{ color: var(--wpt-text); } /* The only content of a wpt test block in its closed state is the <summary>, which contains the word TESTS, and that is absolutely positioned. In that closed state, wpt test blocks are styled to have a top margin whose height is exactly equal to the height of the absolutely positioned <summary>, and no other background/padding/margin/border. The wpt test block elements will therefore allow the maring of the previous/next block elements to collapse through them; if this combined margin would be larger than its own top margin, it stays as is, and therefore the pre-existing vertical rhythm of the document is undisturbed. If that combined margin would be smaller, it is grown to that size. This means that the wpt test block ensures that there's always enough vertical space to insert the summary, without adding more than is needed. */ .wpt-tests-block:not([open]){ padding: 0; border: none; background: none; font-size: 0.75em; line-height: 1; position: relative; margin: 1em 0 0; } .wpt-tests-block:not([open]) summary { position: absolute; right: 0; bottom: 0; } /* It is possible that both the last child of a block element and the block element itself would be annotated with a <wpt> block each. If the block element has a padding or a border, that's fine, but otherwise the bottom margin of the block and of its last child would collapse and both <wpt> elements would overlap, being both placed there. To avoid that, add 1px of padding to the <wpt> element annotating the last child to prevent the bottom margin of the block and of its last child from collapsing (and as much negative margin, as wel only want to prevent margin collapsing, but are not trying to actually take more space). */ .wpt-tests-block:not([open]):last-child { padding-bottom: 1px; margin-bottom: -1px; } /* Exception to the previous rule: don't do that in non-last list items, because it's not necessary, and would therefore consume more space than strictly needed. Lists must have list items as children, not <wpt> elements, so a <wpt> element cannot be a sibling of a list item, and the collision that the previous rule avoids cannot happen. */ li:not(:last-child) > .wpt-tests-block:not([open]):last-child, dd:not(:last-child) > .wpt-tests-block:not([open]):last-child { padding-bottom: 0; margin-bottom: 0; } .wpt-tests-block:not([open]):not(:hover){ opacity: 0.5; } .wpt-tests-list { list-style: none; display: grid; margin: 0; padding: 0; grid-template-columns: 1fr max-content auto auto; grid-column-gap: .5em; } .wpt-tests-block hr:last-child { display: none; } .wpt-test { display: contents; } .wpt-test > a { text-decoration: underline; border: none; } .wpt-test > .wpt-name { grid-column: 1; } .wpt-test > .wpt-results { grid-column: 2; } .wpt-test > .wpt-live { grid-column: 3; } .wpt-test > .wpt-source { grid-column: 4; } .wpt-test > .wpt-results { display: flex; gap: .1em; } .wpt-test .wpt-result { display: inline-block; height: 1em; width: 1em; border-radius: 50%; position: relative; } </style> <style>/* style-darkmode */ @media (prefers-color-scheme: dark) { :root { --text: #ddd; --bg: black; --unofficial-watermark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400'%3E%3Cg fill='%23100808' transform='translate(200 200) rotate(-45) translate(-200 -200)' stroke='%23100808' stroke-width='3'%3E%3Ctext x='50%25' y='220' style='font: bold 70px sans-serif; text-anchor: middle; letter-spacing: 6px;'%3EUNOFFICIAL%3C/text%3E%3Ctext x='50%25' y='305' style='font: bold 70px sans-serif; text-anchor: middle; letter-spacing: 6px;'%3EDRAFT%3C/text%3E%3C/g%3E%3C/svg%3E"); --logo-bg: #1a5e9a; --logo-active-bg: #c00; --logo-text: white; --tocnav-normal-text: #999; --tocnav-normal-bg: var(--bg); --tocnav-hover-text: var(--tocnav-normal-text); --tocnav-hover-bg: #080808; --tocnav-active-text: #f44; --tocnav-active-bg: var(--tocnav-normal-bg); --tocsidebar-text: var(--text); --tocsidebar-bg: #080808; --tocsidebar-shadow: rgba(255,255,255,.1); --tocsidebar-heading-text: hsla(203,20%,40%,.7); --toclink-text: var(--text); --toclink-underline: #6af; --toclink-visited-text: var(--toclink-text); --toclink-visited-underline: #054572; --heading-text: #8af; --hr-text: var(--text); --algo-border: #456; --del-text: #f44; --del-bg: transparent; --ins-text: #4a4; --ins-bg: transparent; --a-normal-text: #6af; --a-normal-underline: #555; --a-visited-text: var(--a-normal-text); --a-visited-underline: var(--a-normal-underline); --a-hover-bg: rgba(25%, 25%, 25%, .2); --a-active-text: #f44; --a-active-underline: var(--a-active-text); --borderedblock-bg: rgba(255, 255, 255, .05); --blockquote-border: silver; --blockquote-bg: var(--borderedblock-bg); --blockquote-text: currentcolor; --issue-border: #e05252; --issue-bg: var(--borderedblock-bg); --issue-text: var(--text); --issueheading-text: hsl(0deg, 70%, 70%); --example-border: hsl(50deg, 90%, 60%); --example-bg: var(--borderedblock-bg); --example-text: var(--text); --exampleheading-text: hsl(50deg, 70%, 70%); --note-border: hsl(120deg, 100%, 35%); --note-bg: var(--borderedblock-bg); --note-text: var(--text); --noteheading-text: hsl(120, 70%, 70%); --notesummary-underline: silver; --assertion-border: #444; --assertion-bg: var(--borderedblock-bg); --assertion-text: var(--text); --advisement-border: orange; --advisement-bg: #222218; --advisement-text: var(--text); --advisementheading-text: #f84; --warning-border: red; --warning-bg: hsla(40,100%,20%,0.95); --warning-text: var(--text); --amendment-border: #330099; --amendment-bg: #080010; --amendment-text: var(--text); --amendmentheading-text: #cc00ff; --def-border: #8ccbf2; --def-bg: #080818; --def-text: var(--text); --defrow-border: #136; --datacell-border: silver; --indexinfo-text: #aaa; --indextable-hover-text: var(--text); --indextable-hover-bg: #181818; --outdatedspec-bg: rgba(255, 255, 255, .5); --outdatedspec-text: black; --outdated-bg: maroon; --outdated-text: white; --outdated-shadow: red; --editedrec-bg: darkorange; } /* In case a transparent-bg image doesn't expect to be on a dark bg, which is quite common in practice... */ img { background: white; } } @media (prefers-color-scheme: dark) { :root { --selflink-text: black; --selflink-bg: silver; --selflink-hover-text: white; } } @media (prefers-color-scheme: dark) { :root { --dfnpanel-bg: #222; --dfnpanel-text: var(--text); } }</style> <style type='text/css'><!-- a#generator { width: 32px; height: 32px; display: block; position: fixed; right: 0; top: 0; border-bottom-left-radius: 5px; background: #f4f4f4; box-shadow: 2px 0px 3px #444; background-image: linear-gradient(to bottom, #eee, #fff 15%, #ededed 80%, #e0e0e0); } a#generator:focus { outline: none;} a#generator svg { position: absolute; right: 3px; top: 3px; } @keyframes fill { 0%, 100% { fill: blue; } 16% { fill: purple; } 33% { fill: hsl(0, 100%, 60%); } 50% { fill: orange; } 67% { fill: gold; } 83% { fill: hsl(120, 100%, 25%); } } @keyframes stroke { 0%, 100% { stroke: blue; } 16% { stroke: purple; } 33% { stroke: hsl(0, 100%, 60%); } 50% { stroke: orange; } 67% { stroke: gold; } 83% { stroke: hsl(120, 100%, 25%); } } a#generator.fatal [fill=blue], a#generator.error [fill=blue], .previous [fill=blue] { fill: #d00; } a#generator.fatal [stroke=blue], a#generator.error [stroke=blue], .previous [stroke=blue] { stroke: #d00; } a#generator.warning [fill=blue] { fill: #0df; } a#generator.warning [stroke=blue] { stroke: #0df; } a#generator.link-error [fill=blue] { fill: #cc0; } a#generator.link-error [stroke=blue] { stroke: #cc0; } a#generator.success [fill=blue] { fill: #0b0; } a#generator.success [stroke=blue] { stroke: #0b0; } a#generator [fill=blue], [stroke=blue] { animation: n 5s infinite linear; transition: fill 1s, stroke 1s; } a#generator.pending [stroke=blue] { animation-name: stroke; } a#generator.pending [fill=blue] { animation-name: fill; } a#generator.generating [stroke=blue] { animation-name: stroke; } a#generator.generating [fill=blue] { animation-name: fill; } --></style><body class="h-entry"> <div class="head"> <p data-fill-with="logo"><a class="logo" href="https://www.w3.org/"> <img alt="W3C" height="48" src="https://www.w3.org/StyleSheets/TR/2021/logos/W3C" width="72"> </a> </p> <h1>CSS Fragmentation Module Level 4 <br> <small>Breaking the Web, one fragment at a time</small></h1> <p id="w3c-state"><a href="https://www.w3.org/standards/types#ED">Editor’s Draft</a>, <time class="dt-updated" datetime="2022-06-22">22 June 2022</time></p> <details open> <summary>More details about this document</summary> <div data-fill-with="spec-metadata"> <dl> <dt>This version: <dd><a class="u-url" href="https://drafts.csswg.org/css-break-4/">https://drafts.csswg.org/css-break-4/</a> <dt>Latest published version: <dd><a href="https://www.w3.org/TR/css-break-4/">https://www.w3.org/TR/css-break-4/</a> <dt>Feedback: <dd><a href="https://github.com/w3c/csswg-drafts/labels/css-break-4">CSSWG Issues Repository</a> <dd><a href="#issues-index">Inline In Spec</a> <dt class="editor">Editors: <dd class="editor p-author h-card vcard" data-editor-id="49885"><a class="p-name fn u-email email" href="mailto:ratan@microsoft.com">Rossen Atanassov</a> (<span class="p-org org">Microsoft</span>) <dd class="editor p-author h-card vcard" data-editor-id="35400"><a class="p-name fn u-url url" href="http://fantasai.inkedblade.net/contact">Elika J. Etemad / fantasai</a> (<span class="p-org org">Invited Expert</span>) <dt>Suggest an Edit for this Spec: <dd><a href="https://github.com/w3c/csswg-drafts/blob/main/css-break-4/Overview.bs">GitHub Editor</a> </dl> </div> </details> <div data-fill-with="warning"></div> <p class="copyright" data-fill-with="copyright"><a href="https://www.w3.org/Consortium/Legal/ipr-notice#Copyright">Copyright</a> © 2022 <a href="https://www.w3.org/"><abbr title="World Wide Web Consortium">W3C</abbr></a><sup>®</sup> (<a href="https://www.csail.mit.edu/"><abbr title="Massachusetts Institute of Technology">MIT</abbr></a>, <a href="https://www.ercim.eu/"><abbr title="European Research Consortium for Informatics and Mathematics">ERCIM</abbr></a>, <a href="https://www.keio.ac.jp/">Keio</a>, <a href="https://ev.buaa.edu.cn/">Beihang</a>). W3C <a href="https://www.w3.org/Consortium/Legal/ipr-notice#Legal_Disclaimer">liability</a>, <a href="https://www.w3.org/Consortium/Legal/ipr-notice#W3C_Trademarks">trademark</a> and <a href="https://www.w3.org/Consortium/Legal/2015/copyright-software-and-document" rel="license">permissive document license</a> rules apply. </p> <hr title="Separator for header"> </div> <div class="p-summary" data-fill-with="abstract"> <h2 class="no-num no-toc no-ref heading settled" id="abstract"><span class="content">Abstract</span></h2> <p>This module describes the fragmentation model that partitions a flow into pages, columns, or regions. It builds on the Page model module and introduces and defines the fragmentation model. It adds functionality for pagination, breaking variable fragment size and orientation, widows and orphans.</p> <a href="https://www.w3.org/TR/CSS/">CSS</a> is a language for describing the rendering of structured documents (such as HTML and XML) on screen, on paper, etc. </div> <h2 class="no-num no-toc no-ref heading settled" id="sotd"><span class="content">Status of this document</span></h2> <div data-fill-with="status"> <p> This is a public copy of the editors’ draft. It is provided for discussion only and may change at any moment. Its publication here does not imply endorsement of its contents by W3C. Don’t cite this document other than as work in progress. </p> <p>Please send feedback by <a href="https://github.com/w3c/csswg-drafts/issues">filing issues in GitHub</a> (preferred), including the spec code “css-break” in the title, like this: “[css-break] <i>…summary of comment…</i>”. All issues and comments are <a href="https://lists.w3.org/Archives/Public/public-css-archive/">archived</a>. Alternately, feedback can be sent to the (<a href="https://lists.w3.org/Archives/Public/www-style/">archived</a>) public mailing list <a href="mailto:www-style@w3.org?Subject=%5Bcss-break%5D%20PUT%20SUBJECT%20HERE">www-style@w3.org</a>. </p> <p>This document is governed by the <a href="https://www.w3.org/2021/Process-20211102/" id="w3c_process_revision">2 November 2021 W3C Process Document</a>. </p> <p></p> </div> <div data-fill-with="at-risk"> <p>The following features are at-risk, and may be dropped during the CR period: </p> <ul> <li>the <a class="css" data-link-type="maybe" href="#valdef-break-before-all" id="ref-for-valdef-break-before-all">all</a> value of <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before">break-before</a>/<a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after">break-after</a> </ul> <p>“At-risk” is a W3C Process term-of-art, and does not necessarily imply that the feature is in danger of being dropped or delayed. It means that the WG believes the feature may have difficulty being interoperably implemented in a timely manner, and marking it as such allows the WG to drop the feature if necessary when transitioning to the Proposed Rec stage, without having to publish a new Candidate Rec without the feature first.</p> </div> <nav data-fill-with="table-of-contents" id="toc"> <h2 class="no-num no-toc no-ref" id="contents">Table of Contents</h2> <ol class="toc" role="directory"> <li> <a href="#intro"><span class="secno">1</span> <span class="content"> Introduction</span></a> <ol class="toc"> <li><a href="#placement"><span class="secno">1.1</span> <span class="content"> Module Interactions</span></a> <li><a href="#values"><span class="secno">1.2</span> <span class="content"> Value Definitions</span></a> </ol> <li> <a href="#fragmentation-model"><span class="secno">2</span> <span class="content"> Fragmentation Model and Terminology</span></a> <ol class="toc"> <li><a href="#parallel-flows"><span class="secno">2.1</span> <span class="content"> Parallel Fragmentation Flows</span></a> <li><a href="#nested-flows"><span class="secno">2.2</span> <span class="content"> Nested Fragmentation Flows</span></a> </ol> <li> <a href="#breaking-controls"><span class="secno">3</span> <span class="content"> Controlling Breaks</span></a> <ol class="toc"> <li> <a href="#break-between"><span class="secno">3.1</span> <span class="content"> Breaks Between Boxes: the <span class="property">break-before</span> and <span class="property">break-after</span> properties</span></a> <ol class="toc"> <li><a href="#generic-break-values"><span class="secno"></span> <span class="content"> Generic Break Values</span></a> <li><a href="#page-break-values"><span class="secno"></span> <span class="content"> Page Break Values</span></a> <li><a href="#column-break-values"><span class="secno"></span> <span class="content"> Column Break Values</span></a> <li><a href="#region-break-values"><span class="secno"></span> <span class="content"> Region Break Values</span></a> <li><a href="#break-propagation"><span class="secno">3.1.1</span> <span class="content"> Child→Parent Break Propagation</span></a> </ol> <li><a href="#break-within"><span class="secno">3.2</span> <span class="content"> Breaks Within Boxes: the <span class="property">break-inside</span> property</span></a> <li><a href="#widows-orphans"><span class="secno">3.3</span> <span class="content"> Breaks Between Lines: <span class="property">orphans</span>, <span class="property">widows</span></span></a> <li><a href="#page-break-properties"><span class="secno">3.4</span> <span class="content"> Page Break Aliases: the <span class="property">page-break-before</span>, <span class="property">page-break-after</span>, and <span class="property">page-break-inside</span> properties</span></a> </ol> <li> <a href="#breaking-rules"><span class="secno">4</span> <span class="content"> Rules for Breaking</span></a> <ol class="toc"> <li><a href="#possible-breaks"><span class="secno">4.1</span> <span class="content"> Possible Break Points</span></a> <li><a href="#break-types"><span class="secno">4.2</span> <span class="content"> Types of Breaks</span></a> <li><a href="#forced-breaks"><span class="secno">4.3</span> <span class="content"> Forced Breaks</span></a> <li><a href="#unforced-breaks"><span class="secno">4.4</span> <span class="content"> Unforced Breaks</span></a> <li><a href="#best-breaks"><span class="secno">4.5</span> <span class="content"> Optimizing Unforced Breaks</span></a> </ol> <li> <a href="#breaking-boxes"><span class="secno">5</span> <span class="content"> Box Model for Breaking</span></a> <ol class="toc"> <li><a href="#varying-size-boxes"><span class="secno">5.1</span> <span class="content"> Breaking into Varying-size Fragmentainers</span></a> <li><a href="#break-margins"><span class="secno">5.2</span> <span class="content"> Adjoining Margins at Breaks: the <span class="property">margin-break</span> property</span></a> <li><a href="#box-splitting"><span class="secno">5.3</span> <span class="content"> Splitting Boxes</span></a> <li> <a href="#break-decoration"><span class="secno">5.4</span> <span class="content"> Fragmented Borders and Backgrounds: the <span class="property">box-decoration-break</span> property</span></a> <ol class="toc"> <li><a href="#joining-boxes"><span class="secno">5.4.1</span> <span class="content"> Joining Boxes for <span class="css">slice</span></span></a> </ol> <li><a href="#transforms"><span class="secno">5.5</span> <span class="content"> Transforms, Positioning, and Pagination</span></a> </ol> <li><a href="#priv-sec"><span class="secno"></span> <span class="content"> Privacy and Security Considerations</span></a> <li> <a href="#changes"><span class="secno"></span> <span class="content"> Changes</span></a> <ol class="toc"> <li><a href="#changes-level-4"><span class="secno"></span> <span class="content"> Changes Since Level 3</span></a> </ol> <li><a href="#acknowledgments"><span class="secno"></span> <span class="content"> Acknowledgments</span></a> <li> <a href="#w3c-conformance"><span class="secno"></span> <span class="content"> Conformance</span></a> <ol class="toc"> <li><a href="#w3c-conventions"><span class="secno"></span> <span class="content"> Document conventions</span></a> <li><a href="#w3c-conformance-classes"><span class="secno"></span> <span class="content"> Conformance classes</span></a> <li> <a href="#w3c-partial"><span class="secno"></span> <span class="content"> Partial implementations</span></a> <ol class="toc"> <li><a href="#w3c-conform-future-proofing"><span class="secno"></span> <span class="content"> Implementations of Unstable and Proprietary Features</span></a> </ol> <li><a href="#w3c-testing"><span class="secno"></span> <span class="content"> Non-experimental implementations</span></a> </ol> <li> <a href="#index"><span class="secno"></span> <span class="content">Index</span></a> <ol class="toc"> <li><a href="#index-defined-here"><span class="secno"></span> <span class="content">Terms defined by this specification</span></a> <li><a href="#index-defined-elsewhere"><span class="secno"></span> <span class="content">Terms defined by reference</span></a> </ol> <li> <a href="#references"><span class="secno"></span> <span class="content">References</span></a> <ol class="toc"> <li><a href="#normative"><span class="secno"></span> <span class="content">Normative References</span></a> <li><a href="#informative"><span class="secno"></span> <span class="content">Informative References</span></a> </ol> <li><a href="#property-index"><span class="secno"></span> <span class="content">Property Index</span></a> <li><a href="#issues-index"><span class="secno"></span> <span class="content">Issues Index</span></a> </ol> </nav> <main> <h2 class="heading settled" data-level="1" id="intro"><span class="secno">1. </span><span class="content"> Introduction</span><a class="self-link" href="#intro"></a></h2> <div class="non-normative"> <em>This section is not normative.</em> <p>In <a data-link-type="dfn" href="https://drafts.csswg.org/mediaqueries-5/#paged-media" id="ref-for-paged-media">paged media</a> (e.g., paper, transparencies, photo album pages, pages displayed on computer screens as printed output simulations), as opposed to <a data-link-type="dfn" href="https://drafts.csswg.org/mediaqueries-5/#continuous-media" id="ref-for-continuous-media">continuous media</a>, the content of the document is split into one or more discrete display surfaces. In order to avoid awkward breaks (such as halfway through a line of text), the layout engine must be able to shift around content that would fall across the page break. This process is called <dfn data-dfn-type="dfn" data-export id="pagination">pagination<a class="self-link" href="#pagination"></a></dfn>.</p> <p>In CSS, in addition to <a data-link-type="dfn" href="https://drafts.csswg.org/mediaqueries-5/#paged-media" id="ref-for-paged-media①">paged media</a>, certain layout features such as <a href="https://www.w3.org/TR/css3-regions/">regions</a> <a data-link-type="biblio" href="#biblio-css3-regions">[CSS3-REGIONS]</a> and <a href="https://www.w3.org/TR/css-multicol-1/">multi-column layout</a> <a data-link-type="biblio" href="#biblio-css-multicol-1">[CSS-MULTICOL-1]</a> create a similarly fragmented environment. The generic term for breaking content across containers is <a data-link-type="dfn" href="#fragmentation" id="ref-for-fragmentation">fragmentation</a>. This module explains how content breaks across <a data-link-type="dfn" href="#fragmentation-container" id="ref-for-fragmentation-container">fragmentation containers</a> (<a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer">fragmentainers</a>) such as pages and columns and how such breaks can be <a href="https://www.w3.org/TR/css-break-3/#breaking-controls">controlled by the author</a>.</p> <p>This specification is identical to <a href="https://www.w3.org/TR/css-break-3/">CSS Fragmentation Level 3</a> except for the addition of the <a class="property css" data-link-type="property" href="#propdef-margin-break" id="ref-for-propdef-margin-break">margin-break</a> property and the <a class="css" data-link-type="maybe" href="#valdef-break-before-always" id="ref-for-valdef-break-before-always">always</a> and <a class="css" data-link-type="maybe" href="#valdef-break-before-all" id="ref-for-valdef-break-before-all①">all</a> values of the <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before①">break-before</a> and <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after①">break-after</a> properties.</p> </div> <h3 class="heading settled" data-level="1.1" id="placement"><span class="secno">1.1. </span><span class="content"> Module Interactions</span><a class="self-link" href="#placement"></a></h3> <p>This module replaces and extends the pagination controls defined in <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a> <a href="https://www.w3.org/TR/CSS2/page.html#page-breaks">section 13.3</a> and in <a data-link-type="biblio" href="#biblio-css-page-3">[CSS-PAGE-3]</a>.</p> <h3 class="heading settled" data-level="1.2" id="values"><span class="secno">1.2. </span><span class="content"> Value Definitions</span><a class="self-link" href="#values"></a></h3> <p>This specification follows the <a href="https://www.w3.org/TR/CSS2/about.html#property-defs">CSS property definition conventions</a> from <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a> using the <a href="https://www.w3.org/TR/css-values-3/#value-defs">value definition syntax</a> from <a data-link-type="biblio" href="#biblio-css-values-3">[CSS-VALUES-3]</a>. Value types not defined in this specification are defined in CSS Values & Units <span>[CSS-VALUES-3]</span>. Combination with other CSS modules may expand the definitions of these value types.</p> <p>In addition to the property-specific values listed in their definitions, all properties defined in this specification also accept the <a data-link-type="dfn" href="https://drafts.csswg.org/css-values-4/#css-wide-keywords" id="ref-for-css-wide-keywords">CSS-wide keywords</a> as their property value. For readability they have not been repeated explicitly.</p> <h2 class="heading settled" data-level="2" id="fragmentation-model"><span class="secno">2. </span><span class="content"> Fragmentation Model and Terminology</span><a class="self-link" href="#fragmentation-model"></a></h2> <dl> <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmentation-container">fragmentation container</dfn> (<dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmentainer">fragmentainer</dfn>) <dd> A box—<wbr>such as a page box, column box, or region—<wbr>that contains a portion (or all) of a <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow">fragmented flow</a>. Fragmentainers can be pre-defined, or generated as needed. When breakable content would overflow a fragmentainer in the block dimension, it breaks into the next container in its <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context">fragmentation context</a> instead. <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmentation-context">fragmentation context</dfn> <dd> An ordered series of <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①">fragmentainers</a>, such as created by a <a href="https://www.w3.org/TR/css-multicol-1/">multi-column container</a>, a chain of <a href="https://www.w3.org/TR/css3-regions">CSS regions</a>, or a <a data-link-type="dfn" href="https://drafts.csswg.org/mediaqueries-5/#paged-media" id="ref-for-paged-media②">paged media</a> display. A given fragmentation context can only have one block flow direction across all its <span id="ref-for-fragmentainer②">fragmentainers</span>. (Descendants of the <a data-link-type="dfn" href="#fragmentation-root" id="ref-for-fragmentation-root">fragmentation root</a> may have other block flow directions, but fragmentation proceeds according to the block flow direction applied to the <span id="ref-for-fragmentation-root①">fragmentation root</span>.) <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmented-flow">fragmented flow</dfn> <dd> Content that is being laid out in a <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context①">fragmentation context</a>. The <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow①">fragmented flow</a> consists of the content of a (possibly anonymous) box called the <dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmentation-root">fragmentation root</dfn>. <dt><dfn data-dfn-type="dfn" data-export id="fragmentation-direction">fragmentation direction<a class="self-link" href="#fragmentation-direction"></a></dfn> <dd> The block flow direction of the <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context②">fragmentation context</a>, i.e. the direction in which content is fragmented. (In this level of CSS, content only fragments in one dimension.) <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmentation">fragmentation</dfn> <dd> The process of splitting a content flow across the <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer③">fragmentainers</a> that form a <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context③">fragmentation context</a>. <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="box-fragment">box fragment</dfn> or <dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragment">fragment</dfn> <dd> The portion of a box that belongs to exactly one <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer④">fragmentainer</a>. A box in continuous flow always consists of only one fragment. A box in a fragmented flow consists of one or more fragments. Each fragment has its own share of the box’s border, padding, and margin, and therefore has its own <a data-link-type="dfn" href="https://drafts.csswg.org/css-box-4/#padding-area" id="ref-for-padding-area">padding area</a>, <a data-link-type="dfn" href="https://drafts.csswg.org/css-box-4/#border-area" id="ref-for-border-area">border area</a>, and <a data-link-type="dfn" href="https://drafts.csswg.org/css-box-4/#margin-area" id="ref-for-margin-area">margin area</a>. (See <a class="property css" data-link-type="property" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break">box-decoration-break</a>, which controls how these are affected by fragmentation.) <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="remaining-fragmentainer-extent">remaining fragmentainer extent</dfn> <dd> The remaining <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-axis" id="ref-for-block-axis">block-axis</a> space in the <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer⑤">fragmentainer</a> available to a given element, i.e. between the end of preceding content in <span id="ref-for-fragmentainer⑥">fragmentainer</span> and the edge of the <span id="ref-for-fragmentainer⑦">fragmentainer</span>. </dl> <p>Each <dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="fragmentation-break">fragmentation break</dfn> (hereafter, <dfn data-dfn-type="dfn" data-noexport id="break">break<a class="self-link" href="#break"></a></dfn>) ends layout of the fragmented box in the current <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer⑧">fragmentainer</a> and causes the remaining content to be laid out in the next <span id="ref-for-fragmentainer⑨">fragmentainer</span>, in some cases causing a new <span id="ref-for-fragmentainer①⓪">fragmentainer</span> to be generated to hold the deferred content.</p> <p class="note" role="note"><span>Note:</span> Breaking inline content into lines is another form of fragmentation, and similarly creates box fragments when it breaks <a href="https://www.w3.org/TR/CSS2/visuren.html#inline-boxes">inline boxes</a> across <a href="https://www.w3.org/TR/CSS2/visuren.html#line-box">line boxes</a>. However, inline breaking is not covered here; see <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a>/<a data-link-type="biblio" href="#biblio-css-text-3">[CSS-TEXT-3]</a>.</p> <p class="note" role="note"><span>Note:</span>A box can be broken into multiple <a data-link-type="dfn" href="#fragment" id="ref-for-fragment">fragments</a> also due to bidi reordering of text (see <a href="https://www.w3.org/TR/css-writing-modes-3/#bidi-algo">Applying the Bidirectional Reordering Algorithm</a> in <a href="https://www.w3.org/TR/css-writing-modes-3/#text-direction">CSS Writing Modes</a>) or higher-level <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#display-type" id="ref-for-display-type">display type</a> box splitting, e.g. <a href="https://www.w3.org/TR/CSS2/visuren.html#img-anon-block">block-in-inline splitting</a> (see <a href="https://www.w3.org/TR/CSS2/visuren.html#box-gen">CSS2§9.2</a>) or <a href="https://www.w3.org/TR/css-multicol-1/#spanning-columns">column-spanner-in-block</a> splitting (see <a href="https://www.w3.org/TR/css-multicol-1/#spanning-columns">CSS Multi-column Layout</a>). The division into <a data-link-type="dfn" href="#box-fragment" id="ref-for-box-fragment">box fragments</a> in these cases does not depend on layout (sizing/positioning of content).</p> <h3 class="heading settled" data-level="2.1" id="parallel-flows"><span class="secno">2.1. </span><span class="content"> Parallel Fragmentation Flows</span><a class="self-link" href="#parallel-flows"></a></h3> <p>When multiple <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#formatting-context" id="ref-for-formatting-context">formatting contexts</a> are laid out parallel to each other, fragmentation is performed independently in each <span id="ref-for-formatting-context①">formatting context</span>. For example, if an element is floated, then a forced break inside the float will not affect the content outside the float (except insofar as it may increase the height of the float). UAs <em>may</em> (but are not required to) adjust the placement of <a data-link-type="dfn" href="#unforced-break" id="ref-for-unforced-break">unforced breaks</a> in parallel <span id="ref-for-formatting-context②">formatting contexts</span> to visually balance such side-by-side content, but <em>must not</em> do so to match a <a data-link-type="dfn" href="#forced-break" id="ref-for-forced-break">forced break</a>.</p> <p>The following are examples of parallel flows whose contents will fragment independently:</p> <ul> <li>The contents of a float vs. the content wrapping outside the float. <li>The contents of a float vs. the contents of an adjacent float. <li>The contents of each table cell in a single table row. <li>The contents of each grid item in a single grid row. <li>The contents of each flex item in a flex layout row. <li>The contents of absolutely-positioned elements that cover the same range of their containing block’s fragmentation context. </ul> <p>Content overflowing the content edge of a fixed-size box is considered parallel to the content after the fixed-size box and follows the normal fragmentation rules. Although overflowing content doesn’t affect the size of the <a data-link-type="dfn" href="#fragmentation-root" id="ref-for-fragmentation-root②">fragmentation root</a> box, it does increase the length of the <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow②">fragmented flow</a>, spilling into or generating additional <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①①">fragmentainers</a> as necessary.</p> <h3 class="heading settled" data-level="2.2" id="nested-flows"><span class="secno">2.2. </span><span class="content"> Nested Fragmentation Flows</span><a class="self-link" href="#nested-flows"></a></h3> <p>Breaking a <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①②">fragmentainer</a> <var>F</var> effectively splits the <span id="ref-for-fragmentainer①③">fragmentainer</span> into two <span id="ref-for-fragmentainer①④">fragmentainers</span> (<var>F<sub>1</sub></var> and <var>F<sub>2</sub></var>). The only difference is that, with regards to the content of <span id="ref-for-fragmentainer①⑤">fragmentainer</span> <var>F</var>, the type of break between the two pieces <var>F<sub>1</sub></var> and <var>F<sub>2</sub></var> is the <a href="#break-types">type of break</a> created by the <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context④">fragmentation context</a> that split <var>F</var>, not the type of break normally created by <var>F</var>’s own <span id="ref-for-fragmentation-context⑤">fragmentation context</span>.</p> <div class="example" id="example-77c2ce76"><a class="self-link" href="#example-77c2ce76"></a> For example, if a region box is broken at a page boundary, then the content of the region will be affected by a page break at that point (but not by a region break). </div> <div class="note" role="note"> Note that when a multi-column container breaks across pages, it generates a new row of columns on the next page for the rest of its content, so that a page break within a multi-column container is always both a page break and a column break. </div> <h2 class="heading settled" data-level="3" id="breaking-controls"><span class="secno">3. </span><span class="content"> Controlling Breaks</span><a class="self-link" href="#breaking-controls"></a></h2> <p>The following sections explain how breaks are controlled in a <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow③">fragmented flow</a>. A page/column/region break opportunity between two boxes is under the influence of the containing block’s <a class="property css" data-link-type="property" href="#propdef-break-inside" id="ref-for-propdef-break-inside">break-inside</a> property, the <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after②">break-after</a> property of the preceding element, and the <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before②">break-before</a> property of the following element. A page/column/region break opportunity between line boxes is under the influence of the containing block’s <span class="property" id="ref-for-propdef-break-inside①">break-inside</span>, <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows">widows</a>, and <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans">orphans</a> properties. A fragmentation break can be allowed, forced, or discouraged depending on the values of these properties. A forced break overrides any break restrictions acting at that break point. In the case of forced page breaks, the author can also specify on which page (<a href="https://www.w3.org/TR/css-page-3/#left-right-first">left or right</a>) the subsequent content should resume.</p> <p>See the section on <a href="#breaking-rules">rules for breaking</a> for the exact rules on how these properties affect fragmentation.</p> <h3 class="heading settled" data-level="3.1" id="break-between"><span class="secno">3.1. </span><span class="content"> Breaks Between Boxes: the <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before③">break-before</a> and <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after③">break-after</a> properties</span><a class="self-link" href="#break-between"></a></h3> <div class="mdn-anno wrapped after"> <button class="mdn-anno-btn"><b class="less-than-two-engines-flag" title="This feature is in less than two current engines.">⚠</b><span>MDN</span></button> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/break-after" title="The break-after CSS property sets how page, column, or region breaks should behave after a generated box. If there is no generated box, the property is ignored.">break-after</a></p> <p class="less-than-two-engines-text">In only one current engine.</p> <div class="support"> <span class="firefox no"><span>Firefox</span><span>None</span></span><span class="safari no"><span>Safari</span><span>None</span></span><span class="chrome yes"><span>Chrome</span><span>50+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>37+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>10+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android yes"><span>Opera Mobile</span><span>37+</span></span> </div> </div> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/break-after" title="The break-after CSS property sets how page, column, or region breaks should behave after a generated box. If there is no generated box, the property is ignored.">break-after</a></p> <p class="all-engines-text">In all current engines.</p> <div class="support"> <span class="firefox yes"><span>Firefox</span><span>65+</span></span><span class="safari yes"><span>Safari</span><span>10+</span></span><span class="chrome yes"><span>Chrome</span><span>50+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>37+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>10+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android yes"><span>Opera Mobile</span><span>37+</span></span> </div> </div> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/break-before" title="The break-before CSS property sets how page, column, or region breaks should behave before a generated box. If there is no generated box, the property is ignored.">break-before</a></p> <p class="less-than-two-engines-text">In only one current engine.</p> <div class="support"> <span class="firefox no"><span>Firefox</span><span>None</span></span><span class="safari no"><span>Safari</span><span>None</span></span><span class="chrome yes"><span>Chrome</span><span>50+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>37+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>10+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android yes"><span>Opera Mobile</span><span>37+</span></span> </div> </div> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/break-before" title="The break-before CSS property sets how page, column, or region breaks should behave before a generated box. If there is no generated box, the property is ignored.">break-before</a></p> <p class="all-engines-text">In all current engines.</p> <div class="support"> <span class="firefox yes"><span>Firefox</span><span>65+</span></span><span class="safari yes"><span>Safari</span><span>10+</span></span><span class="chrome yes"><span>Chrome</span><span>50+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>37+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>10+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android yes"><span>Opera Mobile</span><span>37+</span></span> </div> </div> </div> <table class="def propdef" data-link-for-hint="break-before"> <tbody> <tr> <th>Name: <td><dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-break-before">break-before</dfn>, <dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-break-after">break-after</dfn> <tr class="value"> <th><a href="https://www.w3.org/TR/css-values/#value-defs">Value:</a> <td class="prod">auto <a data-link-type="grammar" href="https://drafts.csswg.org/css-values-4/#comb-one" id="ref-for-comb-one">|</a> avoid <span id="ref-for-comb-one①">|</span> always <span id="ref-for-comb-one②">|</span> all <span id="ref-for-comb-one③">|</span> avoid-page <span id="ref-for-comb-one④">|</span> page <span id="ref-for-comb-one⑤">|</span> left <span id="ref-for-comb-one⑥">|</span> right <span id="ref-for-comb-one⑦">|</span> recto <span id="ref-for-comb-one⑧">|</span> verso <span id="ref-for-comb-one⑨">|</span> avoid-column <span id="ref-for-comb-one①⓪">|</span> column <span id="ref-for-comb-one①①">|</span> avoid-region <span id="ref-for-comb-one①②">|</span> region <tr> <th><a href="https://www.w3.org/TR/css-cascade/#initial-values">Initial:</a> <td>auto <tr> <th><a href="https://www.w3.org/TR/css-cascade/#applies-to">Applies to:</a> <td>block-level boxes, grid items, flex items, table row groups, table rows (but see prose) <tr> <th><a href="https://www.w3.org/TR/css-cascade/#inherited-property">Inherited:</a> <td>no <tr> <th><a href="https://www.w3.org/TR/css-values/#percentages">Percentages:</a> <td>n/a <tr> <th><a href="https://www.w3.org/TR/css-cascade/#computed">Computed value:</a> <td>specified keyword <tr> <th><a href="https://www.w3.org/TR/cssom/#serializing-css-values">Canonical order:</a> <td>per grammar <tr> <th><a href="https://www.w3.org/TR/web-animations/#animation-type">Animation type:</a> <td>discrete </table> <p>These properties specify page/column/region break behavior before/after the generated box. The <dfn class="dfn-paneled" data-dfn-type="dfn" data-noexport id="forced-break-values">forced break values</dfn> <a class="css" data-link-type="maybe" href="#valdef-break-before-always" id="ref-for-valdef-break-before-always①">always</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-all" id="ref-for-valdef-break-before-all②">all</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-left" id="ref-for-valdef-break-before-left">left</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-right" id="ref-for-valdef-break-before-right">right</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-recto" id="ref-for-valdef-break-before-recto">recto</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-verso" id="ref-for-valdef-break-before-verso">verso</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-page" id="ref-for-valdef-break-before-page">page</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-column" id="ref-for-valdef-break-before-column">column</a> and <a class="css" data-link-type="maybe" href="#valdef-break-before-region" id="ref-for-valdef-break-before-region">region</a> create a <a href="#forced-breaks">forced break</a> in the flow while the <dfn class="dfn-paneled" data-dfn-type="dfn" data-noexport id="avoid-break-values">avoid break values</dfn> <a class="css" data-link-type="maybe" href="#valdef-break-before-avoid" id="ref-for-valdef-break-before-avoid">avoid</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-avoid-page" id="ref-for-valdef-break-before-avoid-page">avoid-page</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-avoid-column" id="ref-for-valdef-break-before-avoid-column">avoid-column</a> and <a class="css" data-link-type="maybe" href="#valdef-break-before-avoid-region" id="ref-for-valdef-break-before-avoid-region">avoid-region</a> indicate that content should be kept together.</p> <p>Values for <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before④">break-before</a> and <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after④">break-after</a> are defined in the sub-sections below. User agents must apply these properties to boxes in the normal flow of the <a data-link-type="dfn" href="#fragmentation-root" id="ref-for-fragmentation-root③">fragmentation root</a>. User agents should also apply these properties to floated boxes whose containing block is in the normal flow of the root fragmented element. User agents may also apply these properties to other boxes. User agents must not apply these properties to absolutely-positioned boxes.</p> <h4 class="no-num heading settled" id="generic-break-values"><span class="content"> Generic Break Values</span><a class="self-link" href="#generic-break-values"></a></h4> <p>These values have an effect regardless of the type of fragmented context containing the flow.</p> <dl> <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-auto">auto</dfn> <dd> Neither force nor forbid a break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-avoid">avoid</dfn> <dd> Avoid a break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-always">always</dfn> <dd> Always force a break before/after the <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#principal-box" id="ref-for-principal-box">principal box</a>. The type of this break is that of the immediately-containing <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context⑥">fragmentation context</a>. For example, in a <a data-link-type="dfn" href="https://drafts.csswg.org/css-multicol-1/#multi-column-container" id="ref-for-multi-column-container">multi-column container</a> forces a <a data-link-type="dfn" href="#column-break" id="ref-for-column-break">column break</a>; in <a data-link-type="dfn" href="https://drafts.csswg.org/mediaqueries-5/#paged-media" id="ref-for-paged-media③">paged media</a> not inside a <span id="ref-for-multi-column-container①">multi-column container</span>, forces a <a data-link-type="dfn" href="#page-break" id="ref-for-page-break">page break</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-all">all</dfn> <dd> Always force a break before/after the <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#principal-box" id="ref-for-principal-box①">principal box</a>. This value breaks through all containing <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context⑦">fragmentation contexts</a>. For example, inside a <a data-link-type="dfn" href="https://drafts.csswg.org/css-multicol-1/#multi-column-container" id="ref-for-multi-column-container②">multi-column container</a> in a <a data-link-type="dfn">region</a> in a <span id="ref-for-multi-column-container③">multi-column container</span> in <a data-link-type="dfn" href="https://drafts.csswg.org/mediaqueries-5/#paged-media" id="ref-for-paged-media④">paged media</a>, it forces simultaneously a <a data-link-type="dfn" href="#column-break" id="ref-for-column-break①">column break</a> in the inner <span id="ref-for-multi-column-container④">multi-column container</span>, a <a data-link-type="dfn" href="#region-break" id="ref-for-region-break">region break</a>, a <span id="ref-for-column-break②">column break</span> in the outer <span id="ref-for-multi-column-container⑤">multi-column container</span>, and a <a data-link-type="dfn" href="#page-break" id="ref-for-page-break①">page break</a>. <p class="issue" id="issue-9e81b4a6"><a class="self-link" href="#issue-9e81b4a6"></a> It’s unclear if this value is needed.</p> </dl> <h4 class="no-num heading settled" id="page-break-values"><span class="content"> Page Break Values</span><a class="self-link" href="#page-break-values"></a></h4> <p>These values only have an effect in paginated contexts; if the flow is not paginated, they have no effect.</p> <dl> <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-avoid-page">avoid-page</dfn> <dd> Avoid a page break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-page">page</dfn> <dd> Always force a page break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-left">left</dfn> <dd> Force one or two page breaks before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a> so that the next page is formatted as a left page. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-right">right</dfn> <dd> Force one or two page breaks before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a> so that the next page is formatted as a right page. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-recto">recto</dfn> <dd> Force one or two page breaks before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a> so that the next page is formatted as either a left page or a right page, whichever is second (according to the <a data-link-type="dfn" href="https://drafts.csswg.org/css-page-3/#page-progression" id="ref-for-page-progression">page progression</a>) in a page spread. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-verso">verso</dfn> <dd> Force one or two page breaks before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a> so that the next page is formatted as either a left page or a right page, whichever is first (according to the <a data-link-type="dfn" href="https://drafts.csswg.org/css-page-3/#page-progression" id="ref-for-page-progression①">page progression</a>) in a page spread. </dl> <h4 class="no-num heading settled" id="column-break-values"><span class="content"> Column Break Values</span><a class="self-link" href="#column-break-values"></a></h4> <p>These values only have an effect in multi-column contexts; if the flow is not within a multi-column context, they have no effect.</p> <dl> <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-avoid-column">avoid-column</dfn> <dd> Avoid a column break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-column">column</dfn> <dd> Always force a column break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. </dl> <h4 class="no-num heading settled" id="region-break-values"><span class="content"> Region Break Values</span><a class="self-link" href="#region-break-values"></a></h4> <p>These values only have an effect in multi-region contexts; if the flow is not linked across multiple regions, these values have no effect.</p> <dl> <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-avoid-region">avoid-region</dfn> <dd> Avoid a region break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. <dt><dfn class="dfn-paneled css" data-dfn-for="break-before,break-after" data-dfn-type="value" data-export id="valdef-break-before-region">region</dfn> <dd> Always force a region break before/after the <a href="https://www.w3.org/TR/CSS2/visuren.html#block-boxes">principal box</a>. </dl> <h4 class="heading settled" data-level="3.1.1" id="break-propagation"><span class="secno">3.1.1. </span><span class="content"> Child→Parent Break Propagation</span><a class="self-link" href="#break-propagation"></a></h4> <p>Since breaks are only allowed between siblings, not between a box and its container (see <a href="#possible-breaks">Possible Break Points</a>), break values applied to children at the start/end of a parent are <dfn class="dfn-paneled" data-dfn-type="dfn" data-lt="propagate|propagation" data-noexport id="propagate">propagated</dfn> to the parent, where they can take effect.</p> <p>Specifically—<wbr>except in layout modes which define more specific rules to account for reordering and parallel layout (e.g. in <a href="http://www.w3.org/TR/css-flexbox-1/#pagination">flex layout</a> <a data-link-type="biblio" href="#biblio-css-flexbox-1">[CSS-FLEXBOX-1]</a> or <a href="http://www.w3.org/TR/css-grid-1/#pagination">grid layout</a> <a data-link-type="biblio" href="#biblio-css-grid-1">[CSS-GRID-1]</a>)—<wbr>a <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before⑤">break-before</a> value on a first <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#in-flow" id="ref-for-in-flow">in-flow</a> child box is <a data-link-type="dfn" href="#propagate" id="ref-for-propagate">propagated</a> to its container. Likewise a <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after⑤">break-after</a> value on a last <span id="ref-for-in-flow①">in-flow</span> child box is <span id="ref-for-propagate①">propagated</span> to its container. (Conflicting values <a href="#forced-breaks">combine</a> as defined below.) This propagation stops before it breaks through the nearest matching fragmentation context.</p> <p>Break <a data-link-type="dfn" href="#propagate" id="ref-for-propagate②">propagation</a> does not affect <a data-link-type="dfn" href="https://drafts.csswg.org/css-cascade-5/#computed-value" id="ref-for-computed-value">computed values</a>; it is part of interpreting the elements’ computed values for layout.</p> <h3 class="heading settled" data-level="3.2" id="break-within"><span class="secno">3.2. </span><span class="content"> Breaks Within Boxes: the <a class="property css" data-link-type="property" href="#propdef-break-inside" id="ref-for-propdef-break-inside②">break-inside</a> property</span><a class="self-link" href="#break-within"></a></h3> <div class="mdn-anno wrapped after"> <button class="mdn-anno-btn"><b class="all-engines-flag" title="This feature is in all current engines.">✔</b><span>MDN</span></button> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/break-inside" title="The break-inside CSS property sets how page, column, or region breaks should behave inside a generated box. If there is no generated box, the property is ignored.">break-inside</a></p> <p class="all-engines-text">In all current engines.</p> <div class="support"> <span class="firefox yes"><span>Firefox</span><span>65+</span></span><span class="safari yes"><span>Safari</span><span>10+</span></span><span class="chrome yes"><span>Chrome</span><span>50+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>37+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>10+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android yes"><span>Opera Mobile</span><span>37+</span></span> </div> </div> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/break-inside" title="The break-inside CSS property sets how page, column, or region breaks should behave inside a generated box. If there is no generated box, the property is ignored.">break-inside</a></p> <p class="all-engines-text">In all current engines.</p> <div class="support"> <span class="firefox yes"><span>Firefox</span><span>65+</span></span><span class="safari yes"><span>Safari</span><span>10+</span></span><span class="chrome yes"><span>Chrome</span><span>50+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>37+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>10+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android yes"><span>Opera Mobile</span><span>37+</span></span> </div> </div> </div> <table class="def propdef" data-link-for-hint="break-inside"> <tbody> <tr> <th>Name: <td><dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-break-inside">break-inside</dfn> <tr class="value"> <th><a href="https://www.w3.org/TR/css-values/#value-defs">Value:</a> <td class="prod">auto <a data-link-type="grammar" href="https://drafts.csswg.org/css-values-4/#comb-one" id="ref-for-comb-one①③">|</a> avoid <span id="ref-for-comb-one①④">|</span> avoid-page <span id="ref-for-comb-one①⑤">|</span> avoid-column <span id="ref-for-comb-one①⑥">|</span> avoid-region <tr> <th><a href="https://www.w3.org/TR/css-cascade/#initial-values">Initial:</a> <td>auto <tr> <th><a href="https://www.w3.org/TR/css-cascade/#applies-to">Applies to:</a> <td>all elements except inline-level boxes, internal ruby boxes, table column boxes, table column group boxes, absolutely-positioned boxes <tr> <th><a href="https://www.w3.org/TR/css-cascade/#inherited-property">Inherited:</a> <td>no <tr> <th><a href="https://www.w3.org/TR/css-values/#percentages">Percentages:</a> <td>n/a <tr> <th><a href="https://www.w3.org/TR/css-cascade/#computed">Computed value:</a> <td>specified keyword <tr> <th><a href="https://www.w3.org/TR/cssom/#serializing-css-values">Canonical order:</a> <td>per grammar <tr> <th><a href="https://www.w3.org/TR/web-animations/#animation-type">Animation type:</a> <td>discrete </table> <p>This property specifies page/column/region break behavior within the element’s principal box. Values have the following meanings:</p> <dl> <dt><dfn class="dfn-paneled css" data-dfn-for="break-inside,page-break-inside" data-dfn-type="value" data-export id="valdef-break-inside-auto">auto</dfn> <dd> Impose no additional breaking constraints within the box. <dt><dfn class="dfn-paneled css" data-dfn-for="break-inside,page-break-inside" data-dfn-type="value" data-export id="valdef-break-inside-avoid">avoid</dfn> <dd> Avoid breaks within the box. <dt><dfn class="css" data-dfn-for="break-inside,page-break-inside" data-dfn-type="value" data-export id="valdef-break-inside-avoid-page">avoid-page<a class="self-link" href="#valdef-break-inside-avoid-page"></a></dfn> <dd> Avoid a page break within the box. <dt><dfn class="css" data-dfn-for="break-inside,page-break-inside" data-dfn-type="value" data-export id="valdef-break-inside-avoid-column">avoid-column<a class="self-link" href="#valdef-break-inside-avoid-column"></a></dfn> <dd> Avoid a column break within the box. <dt><dfn class="css" data-dfn-for="break-inside,page-break-inside" data-dfn-type="value" data-export id="valdef-break-inside-avoid-region">avoid-region<a class="self-link" href="#valdef-break-inside-avoid-region"></a></dfn> <dd> Avoid a region break within the box. </dl> <h3 class="heading settled" data-level="3.3" id="widows-orphans"><span class="secno">3.3. </span><span class="content"> Breaks Between Lines: <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans①">orphans</a>, <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows①">widows</a></span><a class="self-link" href="#widows-orphans"></a></h3> <div class="mdn-anno wrapped after"> <button class="mdn-anno-btn"><span>MDN</span></button> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/orphans" title="The orphans CSS property sets the minimum number of lines in a block container that must be shown at the bottom of a page, region, or column.">orphans</a></p> <div class="support"> <span class="firefox no"><span>Firefox</span><span>None</span></span><span class="safari yes"><span>Safari</span><span>1.3+</span></span><span class="chrome yes"><span>Chrome</span><span>25+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>9.2+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>8+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android no"><span>Opera Mobile</span><span>?</span></span> </div> </div> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/widows" title="The widows CSS property sets the minimum number of lines in a block container that must be shown at the top of a page, region, or column.">widows</a></p> <div class="support"> <span class="firefox no"><span>Firefox</span><span>None</span></span><span class="safari yes"><span>Safari</span><span>1.3+</span></span><span class="chrome yes"><span>Chrome</span><span>25+</span></span> <hr> <span class="opera yes"><span>Opera</span><span>9.2+</span></span><span class="edge_blink yes"><span>Edge</span><span>79+</span></span> <hr> <span class="edge yes"><span>Edge (Legacy)</span><span>12+</span></span><span class="ie yes"><span>IE</span><span>8+</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>?</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>?</span></span><span class="webview_android no"><span>Android WebView</span><span>?</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android no"><span>Opera Mobile</span><span>?</span></span> </div> </div> </div> <table class="def propdef" data-link-for-hint="orphans"> <tbody> <tr> <th>Name: <td><dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-orphans">orphans</dfn>, <dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-widows">widows</dfn> <tr class="value"> <th><a href="https://www.w3.org/TR/css-values/#value-defs">Value:</a> <td class="prod"><a class="production css" data-link-type="type" href="https://drafts.csswg.org/css-values-4/#integer-value" id="ref-for-integer-value"><integer [0,∞]></a> <tr> <th><a href="https://www.w3.org/TR/css-cascade/#initial-values">Initial:</a> <td>2 <tr> <th><a href="https://www.w3.org/TR/css-cascade/#applies-to">Applies to:</a> <td><a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#block-container" id="ref-for-block-container">block containers</a> that establish an <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#inline-formatting-context" id="ref-for-inline-formatting-context">inline formatting context</a> <tr> <th><a href="https://www.w3.org/TR/css-cascade/#inherited-property">Inherited:</a> <td>yes <tr> <th><a href="https://www.w3.org/TR/css-values/#percentages">Percentages:</a> <td>n/a <tr> <th><a href="https://www.w3.org/TR/css-cascade/#computed">Computed value:</a> <td>specified integer <tr> <th><a href="https://www.w3.org/TR/cssom/#serializing-css-values">Canonical order:</a> <td>per grammar <tr> <th><a href="https://www.w3.org/TR/web-animations/#animation-type">Animation type:</a> <td>by computed value type </table> <p>The <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans②">orphans</a> property specifies the minimum number of line boxes in a block container that must be left in a <a data-link-type="dfn" href="#fragment" id="ref-for-fragment①">fragment</a> <em>before</em> a fragmentation break. The <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows②">widows</a> property specifies the minimum number of line boxes of a block container that must be left in a <span id="ref-for-fragment②">fragment</span> <em>after</em> a break. Examples of how they are used to control fragmentation breaks are given <a href="#widows-orphans-example">below</a>.</p> <p>Only positive integers are allowed as values of <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans③">orphans</a> and <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows③">widows</a>. Negative values and zero are invalid and must cause the declaration to be <a href="https://www.w3.org/TR/CSS2/conform.html#ignore">ignored</a>.</p> <p>If a block contains fewer lines than the value of <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows④">widows</a> or <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans④">orphans</a>, the rule simply becomes that all lines in the block must be kept together.</p> <h3 class="heading settled" data-level="3.4" id="page-break-properties"><span class="secno">3.4. </span><span class="content"> Page Break Aliases: the <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css2/#propdef-page-break-before" id="ref-for-propdef-page-break-before">page-break-before</a>, <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css2/#propdef-page-break-after" id="ref-for-propdef-page-break-after">page-break-after</a>, and <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css2/#propdef-page-break-inside" id="ref-for-propdef-page-break-inside">page-break-inside</a> properties</span><a class="self-link" href="#page-break-properties"></a></h3> <p>For compatibility with <a href="https://www.w3.org/TR/CSS2/page.html">CSS Level 2</a>, UAs that conform to <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a> must alias the <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css2/#propdef-page-break-before" id="ref-for-propdef-page-break-before①">page-break-before</a>, <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css2/#propdef-page-break-after" id="ref-for-propdef-page-break-after①">page-break-after</a>, and <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css2/#propdef-page-break-inside" id="ref-for-propdef-page-break-inside①">page-break-inside</a> properties to <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before⑥">break-before</a>, <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after⑥">break-after</a>, and <a class="property css" data-link-type="property" href="#propdef-break-inside" id="ref-for-propdef-break-inside③">break-inside</a> by treating the <a class="property css" data-link-type="property">page-break-*</a> properties as <a data-link-type="dfn" href="https://drafts.csswg.org/css-cascade-5/#legacy-shorthand" id="ref-for-legacy-shorthand">legacy shorthands</a> for the <span class="property">break-*</span> properties with the following value mappings:</p> <table class="data"> <thead> <tr> <th>Shorthand (<a class="property css" data-link-type="property">page-break-*</a>) Values <th>Longhand (<a class="property css" data-link-type="property">break-*</a>) Values <tbody> <tr> <td><span class="css">auto | left | right | avoid</span> <td><span class="css">auto | left | right | avoid</span> <tr> <td><span class="css">always</span> <td><span class="css">page</span> </table> <h2 class="heading settled" data-level="4" id="breaking-rules"><span class="secno">4. </span><span class="content"> Rules for Breaking</span><a class="self-link" href="#breaking-rules"></a></h2> <p>A <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow④">fragmented flow</a> may be broken across <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①⑥">fragmentainers</a> at a number of <a href="#possible-breaks">possible break points</a>. In the case of <a href="#forced-breaks">forced breaks</a>, the UA is required to break the flow at that point. In the case of <a href="#unforced-breaks">unforced breaks</a>, the UA has to choose among the possible breaks that are allowed.</p> <p>To guarantee progress, fragmentainers are assumed to have a minimum <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-size" id="ref-for-block-size">block size</a> of 1px regardless of their used size.</p> <h3 class="heading settled" data-level="4.1" id="possible-breaks"><span class="secno">4.1. </span><span class="content"> Possible Break Points</span><a class="self-link" href="#possible-breaks"></a></h3> <p>Fragmentation splits boxes in the block flow dimension. In block-and-inline flow, breaks may occur at the following places:</p> <dl> <dt id="btw-blocks"><a class="self-link" href="#btw-blocks"></a>Class A <dd> Between sibling boxes of the following types: <dl> <dt>Block-parallel Fragmentation <dd> When the block flow direction of the siblings' containing block is parallel to that of the fragmentation context: <a href="https://www.w3.org/TR/2011/REC-CSS2-20110607/visuren.html#positioning-scheme">in-flow</a> block-level boxes, a float and an immediately-adjacent in-flow or floated box, table row group boxes, table row boxes, multi-column column row boxes. <dt>Block-perpendicular Fragmentation <dd> When the block flow direction of the siblings' containing block is perpendicular to that of the fragmentation context: table column group boxes, table column boxes, multi-column column boxes. </dl> <dt id="btw-lines"><a class="self-link" href="#btw-lines"></a>Class B <dd> Between line boxes inside a block container box. <dt id="end-block"><a class="self-link" href="#end-block"></a>Class C <dd> Between the content edge of a block container box and the outer edges of its child content (margin edges of block-level children or line box edges for inline-level children) <em>if</em> there is a (non-zero) gap between them. </dl> <p class="note" role="note"><span>Note:</span> There is no inherent prioritization among these classes of break points. However, individual break points may be prioritized or de-prioritized by using the <a href="#breaking-controls">breaking controls</a>.</p> <p class="note" role="note"><span>Note:</span> Other layout models may add breakpoints to the above classes. For example, <a data-link-type="biblio" href="#biblio-css-flexbox-1">[CSS-FLEXBOX-1]</a> adds certain points within a flex formatting context to classes A and C.</p> <p>Some content is not fragmentable, for example many types of <a href="https://www.w3.org/TR/CSS2/conform.html#replaced-element">replaced elements</a> <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a> (such as images or video), scrollable elements, or a single line of text content. Such content is considered <dfn class="dfn-paneled" data-dfn-type="dfn" data-noexport id="monolithic">monolithic</dfn>: it contains no possible break points. Any forced breaks within such boxes therefore cannot split the box, and must therefore also be ignored by the box’s own fragmentation context.</p> <p>In addition to any content which is not generally fragmentable, UAs may consider as <a data-link-type="dfn" href="#monolithic" id="ref-for-monolithic">monolithic</a> any elements with <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-overflow-3/#propdef-overflow" id="ref-for-propdef-overflow">overflow</a> set to <a class="css" data-link-type="maybe" href="https://drafts.csswg.org/css-overflow-3/#valdef-overflow-auto" id="ref-for-valdef-overflow-auto">auto</a> or <a class="css" data-link-type="maybe" href="https://drafts.csswg.org/css-overflow-3/#valdef-overflow-scroll" id="ref-for-valdef-overflow-scroll">scroll</a> and any elements with <span class="css" id="ref-for-propdef-overflow①">overflow: hidden</span> and a non-<a class="css" data-link-type="maybe" href="https://drafts.csswg.org/css-sizing-3/#valdef-width-auto" id="ref-for-valdef-width-auto">auto</a> <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#logical-height" id="ref-for-logical-height">logical height</a> (and no specified maximum logical height).</p> <p>Since line boxes contain no possible break points, <a class="css" data-link-type="maybe" href="https://drafts.csswg.org/css-display-3/#valdef-display-inline-block" id="ref-for-valdef-display-inline-block">inline-block</a> and <a class="css" data-link-type="maybe" href="https://drafts.csswg.org/css-display-3/#valdef-display-inline-table" id="ref-for-valdef-display-inline-table">inline-table</a> boxes (and other inline-level <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#display-type" id="ref-for-display-type①">display types</a> that establish an <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#independent-formatting-context" id="ref-for-independent-formatting-context">independent formatting context</a>) may also be considered <a data-link-type="dfn" href="#monolithic" id="ref-for-monolithic①">monolithic</a>: that is, in the cases where a single line box is too large to fit within its fragmentainer even by itself and the UA chooses to split the line box, it may fragment such boxes or it may treat them as monolithic.</p> <h3 class="heading settled" data-level="4.2" id="break-types"><span class="secno">4.2. </span><span class="content"> Types of Breaks</span><a class="self-link" href="#break-types"></a></h3> <p>There are different types of breaks in CSS, defined based on the type of fragmentainers they span:</p> <dl> <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="page-break">page break</dfn> <dd> A break between two <a href="https://www.w3.org/TR/css-page-3/#page-box">page boxes</a>. <a data-link-type="biblio" href="#biblio-css-page-3">[CSS-PAGE-3]</a> <dt><dfn data-dfn-type="dfn" data-export id="spread-break">spread break<a class="self-link" href="#spread-break"></a></dfn> <dd> A break between two page boxes that are not associated with <a href="https://www.w3.org/TR/css-page-3/#facing-pages">facing pages</a>. A spread break is always also a page break. <a data-link-type="biblio" href="#biblio-css-page-3">[CSS-PAGE-3]</a> <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="column-break">column break</dfn> <dd> A break between two <a href="https://www.w3.org/TR/css-multicol-1/#column-box">column boxes</a>. Note that if the column boxes are on different pages, then the break is also a <a data-link-type="dfn" href="#page-break" id="ref-for-page-break②">page break</a>. Similarly, if the column boxes are in different regions, then the break is also a <a data-link-type="dfn" href="#region-break" id="ref-for-region-break①">region break</a>. <a data-link-type="biblio" href="#biblio-css-multicol-1">[CSS-MULTICOL-1]</a> <dt><dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="region-break">region break</dfn> <dd> A break between two <a href="https://www.w3.org/TR/css3-regions/#regions">regions</a>. Note that if the region boxes are on different pages, then the break is also a <a data-link-type="dfn" href="#page-break" id="ref-for-page-break③">page break</a>. <a data-link-type="biblio" href="#biblio-css3-regions">[CSS3-REGIONS]</a> </dl> <p class="note" role="note"><span>Note:</span> A fifth type of break is the <a data-link-type="dfn" href="https://drafts.csswg.org/css-text-4/#line-break" id="ref-for-line-break">line break</a>, which is a break between two <a href="https://www.w3.org/TR/CSS2/visuren.html#line-box">line boxes</a>. These are not covered in this specification; see <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a> <a data-link-type="biblio" href="#biblio-css-text-3">[CSS-TEXT-3]</a>.</p> <h3 class="heading settled" data-level="4.3" id="forced-breaks"><span class="secno">4.3. </span><span class="content"> Forced Breaks</span><a class="self-link" href="#forced-breaks"></a></h3> <p>A <dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="forced-break">forced break</dfn> is one explicitly indicated by the style sheet author. A <a data-link-type="dfn" href="#forced-break" id="ref-for-forced-break①">forced break</a> occurs at a <a href="#btw-blocks">class A break point</a> if, among the <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after⑦">break-after</a> properties specified on or <a data-link-type="dfn" href="#propagate" id="ref-for-propagate③">propagated</a> to the earlier sibling box and the <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before⑦">break-before</a> properties specified on or <span id="ref-for-propagate④">propagated</span> to the later sibling box there is at least one with a <a data-link-type="dfn" href="#forced-break-values" id="ref-for-forced-break-values">forced break value</a>. (Thus a <span id="ref-for-forced-break-values①">forced break value</span> effectively overrides any <a data-link-type="dfn" href="#avoid-break-values" id="ref-for-avoid-break-values">avoid break value</a> that also applies at that break point.)</p> <p>When multiple <a data-link-type="dfn" href="#forced-break-values" id="ref-for-forced-break-values②">forced break values</a> apply to a single break point, they combine such that all types of break are honored. When <a class="css" data-link-type="maybe" href="#valdef-break-before-left" id="ref-for-valdef-break-before-left①">left</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-right" id="ref-for-valdef-break-before-right①">right</a>, <a class="css" data-link-type="maybe" href="#valdef-break-before-recto" id="ref-for-valdef-break-before-recto①">recto</a>, and/or <a class="css" data-link-type="maybe" href="#valdef-break-before-verso" id="ref-for-valdef-break-before-verso①">verso</a> are combined, the value specified on the latest element in the flow wins.</p> <p class="note" role="note"><span>Note:</span> A forced page break must also occur at a <a href="#btw-blocks">class A break point</a> if the last line box above this margin and the first one below it do not have the same value for <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-page-3/#propdef-page" id="ref-for-propdef-page">page</a>. See <a data-link-type="biblio" href="#biblio-css-page-3">[CSS-PAGE-3]</a>.</p> <p>When a forced break occurs, it forces ensuing content into the next fragmentainer of the type associated with the break, breaking through as many fragmentation contexts as necessary until the specified break types are all satisfied. If the forced break is not contained within a matching type of fragmentation context, then the forced break has no effect.</p> <h3 class="heading settled" data-level="4.4" id="unforced-breaks"><span class="secno">4.4. </span><span class="content"> Unforced Breaks</span><a class="self-link" href="#unforced-breaks"></a></h3> <p>While <a href="#breaking-controls">breaking controls</a> can force breaks, they can also discourage them. An <dfn class="dfn-paneled" data-dfn-type="dfn" data-export id="unforced-break">unforced break</dfn> is one that is inserted automatically by the UA in order to prevent content from overflowing the <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①⑦">fragmentainer</a>. The following rules control whether unforced breaking at a <a href="#possible-breaks">possible break point</a> is allowed:</p> <dl> <dt>Rule 1 <dd> A <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow⑤">fragmented flow</a> may break at a <a href="#btw-blocks">class A break point</a> only if all the <a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after⑧">break-after</a> and <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before⑧">break-before</a> values applicable to this break point allow it, which is when at least one of them forces a break or when none of them forbid it (<a class="css" data-link-type="maybe" href="#valdef-break-before-avoid" id="ref-for-valdef-break-before-avoid①">avoid</a> or <a class="css" data-link-type="maybe" href="#valdef-break-before-avoid-page" id="ref-for-valdef-break-before-avoid-page①">avoid-page</a>/<a class="css" data-link-type="maybe" href="#valdef-break-before-avoid-column" id="ref-for-valdef-break-before-avoid-column①">avoid-column</a>/<a class="css" data-link-type="maybe" href="#valdef-break-before-avoid-region" id="ref-for-valdef-break-before-avoid-region①">avoid-region</a>, depending on the <a href="#break-types">break type</a>). <dt>Rule 2 <dd> However, if all of them are <a class="css" data-link-type="maybe" href="#valdef-break-before-auto" id="ref-for-valdef-break-before-auto">auto</a> and a common ancestor of all the elements has a <a class="property css" data-link-type="property" href="#propdef-break-inside" id="ref-for-propdef-break-inside④">break-inside</a> value of <a class="css" data-link-type="maybe" href="#valdef-break-inside-avoid" id="ref-for-valdef-break-inside-avoid">avoid</a>, then breaking here is not allowed. <dt>Rule 3 <dd> Breaking at a <a href="#btw-lines">class B break point</a> is allowed only if the number of line boxes between the break and the start of the enclosing block box is the value of <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans⑤">orphans</a> or more, and the number of line boxes between the break and the end of the box is the value of <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows⑤">widows</a> or more. <dt>Rule 4 <dd> Additionally, breaking at <a href="#btw-blocks">class B</a> or <a href="#end-block">class C</a> break points is allowed only if the <a class="property css" data-link-type="property" href="#propdef-break-inside" id="ref-for-propdef-break-inside⑤">break-inside</a> property of all ancestors is <a class="css" data-link-type="maybe" href="#valdef-break-inside-auto" id="ref-for-valdef-break-inside-auto">auto</a>. </dl> <p>If the above doesn’t provide enough break points to keep content from overflowing the <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①⑧">fragmentainer</a>, then rule 3 is dropped to provide more break points.</p> <p>If that still does not lead to sufficient break points, then rules 1, 2 and 4 are dropped in order to find additional breakpoints. In this case the UA may use the <span class="css">avoid</span>s that are in effect at those points to weigh the appropriateness of the new breakpoints; however, this specification does not suggest a precise algorithm.</p> <p>If even that does not lead to sufficient break points, <a href="#valdef-box-decoration-break-clone" id="ref-for-valdef-box-decoration-break-clone">cloned margins/border/padding</a> at on the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-end" id="ref-for-block-end">block-end</a> side are truncated; and if more room is still needed, <a href="#valdef-box-decoration-break-clone" id="ref-for-valdef-box-decoration-break-clone①">cloned margins/border/padding</a> are truncated at the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-start" id="ref-for-block-start">block-start</a> side as well.</p> <p>Finally, if there are no possible break points below the top of the fragmentainer, and not all the content fits, the UA may break anywhere in order to avoid losing content off the edge of the fragmentainer. <span id="monolithic-breaking"> In such cases, the UA may also fragment the contents of <a data-link-type="dfn" href="#monolithic" id="ref-for-monolithic②">monolithic</a> elements by slicing the element’s graphical representation. However, the UA must not break at the top of the page, i.e. it must place at least some content on each fragmentainer, so that each fragmentainer has a non-zero amount of content, in order to guarantee progress through the content.</span></p> <h3 class="heading settled" data-level="4.5" id="best-breaks"><span class="secno">4.5. </span><span class="content"> Optimizing Unforced Breaks</span><a class="self-link" href="#best-breaks"></a></h3> <p>While CSS requires that a <a data-link-type="dfn" href="#fragmented-flow" id="ref-for-fragmented-flow⑥">fragmented flow</a> must break at allowed break points in order to avoid overflowing the fragmentainers in its fragmentation context, it does not define whether content breaks at a particular <a href="#unforced-breaks">allowed break</a>. However, it is recommended that user agents observe the following guidelines (while recognizing that they are sometimes contradictory):</p> <ul> <li>Break as few times as possible. <li>Make all fragmentainers that don’t end with a forced break appear to be equally filled with content. <li>Avoid breaking inside a replaced element. </ul> <div class="example" id="widows-orphans-example"> <a class="self-link" href="#widows-orphans-example"></a> <p>Suppose, for example, that the style sheet contains <span class="css">orphans : 4</span>, <span class="css">widows : 2</span>, and there is space for 20 lines (line boxes) available at the bottom of the current page, and the next block in normal flow is considered for placement:</p> <ul> <li> If the block contains 20 line boxes or fewer, it should be placed on the current page. <li> If the block contains 21 or 22 line boxes, the second fragment of the paragraph must not violate the <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows⑥">widows</a> constraint, and so the second fragment must contain at least two line boxes; likewise the first fragment must contain at least four line boxes. <li> If the block contains 23 line boxes or more, the first fragment should contain 20 lines and the second fragment the remaining lines. But if any fragment of the block is placed on the current page, that fragment must contain at least four line boxes and the second fragment at least two line boxes. </ul> <p>Now suppose that <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans⑥">orphans</a> is <span class="css">10</span>, <a class="property css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows⑦">widows</a> is <span class="css">20</span>, and there are 8 lines available at the bottom of the current page:</p> <ul> <li> If the block contains 8 lines or fewer, it should be placed on the current page. <li> If the block contains 9 lines or more, it must NOT be split (that would violate the <a class="property css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans⑦">orphans</a> constraint), so it must move as a block to the next page. </ul> </div> <p>Additionally, CSS imposes one requirement: a zero-sized <a data-link-type="dfn" href="#box-fragment" id="ref-for-box-fragment①">box fragment</a>, since it does not take up space, must appear on the earlier side of a <a data-link-type="dfn" href="#fragmentation-break" id="ref-for-fragmentation-break">fragmentation break</a> if it is able to fit within the <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer①⑨">fragmentainer</a>.</p> <p class="note" role="note"><span>Note:</span> A zero-sized <a data-link-type="dfn" href="#box-fragment" id="ref-for-box-fragment②">box fragment</a> will be pushed to the next <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer②⓪">fragmentainer</a> if it is placed immediately after content that itself overflows the <span id="ref-for-fragmentainer②①">fragmentainer</span>.</p> <h2 class="heading settled" data-level="5" id="breaking-boxes"><span class="secno">5. </span><span class="content"> Box Model for Breaking</span><a class="self-link" href="#breaking-boxes"></a></h2> <p class="note" role="note"><span>Note:</span> The sizing terminology used in this section is defined in <a data-link-type="biblio" href="#biblio-css-sizing-3">[CSS-SIZING-3]</a>.</p> <h3 class="heading settled" data-level="5.1" id="varying-size-boxes"><span class="secno">5.1. </span><span class="content"> Breaking into Varying-size Fragmentainers</span><a class="self-link" href="#varying-size-boxes"></a></h3> <p>When a flow is fragmented into varying-size fragmentainers, the following rules are observed for adapting layout:</p> <ul> <li> Layout is performed per-fragmentainer, with each fragmentainer continuing progress from the breakpoint on the previous, but recalculating sizes and positions using its own size as if the entire element were fragmented across fragmentainers of this size. Progress is measured in percentages (not absolute lengths) of used/remaining fragmentainer size and in amount of used/remaining content. However, when laying out <a data-link-type="dfn" href="#monolithic" id="ref-for-monolithic③">monolithic</a> elements, the UA may instead maintain a consistent <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#inline-size" id="ref-for-inline-size">inline size</a> and resolved <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-size" id="ref-for-block-size①">block size</a> across fragmentainers. <li> Intrinsic sizes are calculated and maintained across the entire element. Where an initial containing block size is needed to resolve an intrinsic size, assume the size of the first fragmentainer defining a fragmentation context. <li> Fragments of boxes that began on a previous fragmentainer must obey placement rules with the additional constraint that fragments must not be positioned above the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-start" id="ref-for-block-start①">block-start</a> edge of the fragmentainer. If this results in a box’s continuation fragment shifting away from the <span id="ref-for-block-start②">block-start</span> edge of the fragmentainer, then <a class="css" data-link-type="propdesc" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break①">box-decoration-break: clone</a>, if specified, wraps the fragment with the box’s margin in addition to its padding and border. <div class="figure"> <img alt="Illustration: Breaking in varying-size fragmentainers" src="images/Varying-Size-Fragmentainers.svg" style="width: 75%"> <p class="caption"> Illustration of breaking in varying-size fragmentainers. </p> </div> </ul> <p class="note" role="note"><span>Note:</span> Since document order of elements doesn’t change during fragmentation, fragments are processed following the same rules that apply to continuous media. In particular, the order of floats is preserved across all fragments and follows the same rules as defined in CSS 2.1 9.5.</p> <p>Below are listed (informatively) some implications of these rules:</p> <ul> <li> Boxes (including tables) fulfilling layout constraints at their <a data-link-type="dfn" href="https://drafts.csswg.org/css-sizing-3/#stretch-fit-size" id="ref-for-stretch-fit-size">stretch-fit</a> or percentage-based size may change <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#inline-size" id="ref-for-inline-size①">inline size</a> across pages. <li> Boxes (including tables) fulfilling layout constraints at their <a data-link-type="dfn" href="https://drafts.csswg.org/css-sizing-3/#min-content" id="ref-for-min-content">min-content</a>, <a data-link-type="dfn" href="https://drafts.csswg.org/css-sizing-3/#max-content" id="ref-for-max-content">max-content</a>, or absolute-length size will maintain their <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#inline-size" id="ref-for-inline-size②">inline size</a> across pages. <li> A block-level continuation fragment may be placed below the top of the page if, e.g. it establishes a block formatting context and is placed beside a float and both it and the float continue onto a narrower page that is too narrow to hold both of them side-by-side. <li> An element adjacent to a preceding float on one page may wind up above the float’s continuation on the next page if, e.g. that float is pushed down because it no longer fits side-by-side with an earlier float that also continues onto this narrower page. <li> A left float may appear on a page <em>before</em> the remaining fragments of a preceding right float if that right float does not fit on the earlier page. However another right float will be forced down until the preceding right float’s remaining fragment can be placed. </ul> <div class="example" id="example-fbdd0b64"> <a class="self-link" href="#example-fbdd0b64"></a> Here is an example that shows the use of percentage-based progress: Suppose we have an absolutely-positioned element that is positioned <a class="css" data-link-type="propdesc" href="https://drafts.csswg.org/css-position-3/#propdef-top" id="ref-for-propdef-top">top: calc(150% + 30px)</a> and has <a class="css" data-link-type="propdesc" href="https://drafts.csswg.org/css-sizing-3/#propdef-height" id="ref-for-propdef-height">height: calc(100% - 10px)</a>. If it is placed into a paginated context with a first page height of 400px, a second page of 200px, and a third page of 600px, its layout progresses as follows: <ul> <li> First, the top position is resolved against the height of the first page. This results in 630px. Since the first page has a height of only 400px, layout moves to the second page, recording progress of 400/630 = 63.49% with 36.51% left to go. <li> Now on the second page, the top position is again resolved, this time against the height of the second page. This results in 330px. The remaining 36.51% of progress thus resolves to 120.5px, placing the top edge of the element 120.5px down the second page. <li> Now the height is resolved against the second page; it resolves to 190px. Since there are only 79.5px left on the page, layout moves to the third page, recording progress of 79.5/190 = 41.84%, with 58.16% left to go. <li> On the third page, the height resolves to 590px. The remaining 58.16% of progress thus resolves to 343.1px, which fits on this page and completes the element. </ul> </div> <h3 class="heading settled" data-level="5.2" id="break-margins"><span class="secno">5.2. </span><span class="content"> Adjoining Margins at Breaks: the <a class="property css" data-link-type="property" href="#propdef-margin-break" id="ref-for-propdef-margin-break①">margin-break</a> property</span><a class="self-link" href="#break-margins"></a></h3> <table class="def propdef" data-link-for-hint="margin-break"> <tbody> <tr> <th>Name: <td><dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-margin-break">margin-break</dfn> <tr class="value"> <th><a href="https://www.w3.org/TR/css-values/#value-defs">Value:</a> <td class="prod">auto <a data-link-type="grammar" href="https://drafts.csswg.org/css-values-4/#comb-one" id="ref-for-comb-one①⑦">|</a> keep <span id="ref-for-comb-one①⑧">|</span> discard <tr> <th><a href="https://www.w3.org/TR/css-cascade/#initial-values">Initial:</a> <td>auto <tr> <th><a href="https://www.w3.org/TR/css-cascade/#applies-to">Applies to:</a> <td><a href="https://www.w3.org/TR/css-pseudo/#generated-content" title="Includes ::before and ::after pseudo-elements.">all elements</a> <tr> <th><a href="https://www.w3.org/TR/css-cascade/#inherited-property">Inherited:</a> <td>no <tr> <th><a href="https://www.w3.org/TR/css-values/#percentages">Percentages:</a> <td>n/a <tr> <th><a href="https://www.w3.org/TR/css-cascade/#computed">Computed value:</a> <td>specified keyword <tr> <th><a href="https://www.w3.org/TR/cssom/#serializing-css-values">Canonical order:</a> <td>per grammar <tr> <th><a href="https://www.w3.org/TR/web-animations/#animation-type">Animation type:</a> <td>discrete </table> <p>Controls whether the box’s <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-axis" id="ref-for-block-axis①">block-axis</a> <a data-link-type="dfn" href="https://drafts.csswg.org/css-box-4/#margin" id="ref-for-margin">margins</a> are discarded or kept at a <a data-link-type="dfn" href="#fragmentation-break" id="ref-for-fragmentation-break①">fragmentation break</a>. Values have the following meanings:</p> <dl> <dt><dfn class="css" data-dfn-for="margin-break" data-dfn-type="value" data-export id="valdef-margin-break-auto">auto<a class="self-link" href="#valdef-margin-break-auto"></a></dfn> <dd> When an <em>unforced</em> break occurs before or after the box, any margins adjoining the break truncate to the <a data-link-type="dfn" href="#remaining-fragmentainer-extent" id="ref-for-remaining-fragmentainer-extent">remaining fragmentainer extent</a> before the break, and are truncated to zero after the break. When a <em>forced break</em> occurs there, adjoining margins before the break are truncated, but margins after the break are preserved. <a href="https://www.w3.org/TR/css-break-4/#valdef-box-decoration-break-clone">Cloned margins</a> are always truncated to zero. <p class="note" role="note"><span>Note:</span> When margins collapse (see <a href="https://www.w3.org/TR/CSS2/box.html#collapsing-margins">CSS2§8.3.1</a>), the margins of multiple boxes can be adjoining the break.</p> <dt><dfn class="dfn-paneled css" data-dfn-for="margin-break" data-dfn-type="value" data-export id="valdef-margin-break-keep">keep</dfn> <dd> Margins adjoining a <a data-link-type="dfn" href="#fragmentation-break" id="ref-for-fragmentation-break②">fragmentation break</a> are not truncated. <dt><dfn class="css" data-dfn-for="margin-break" data-dfn-type="value" data-export id="valdef-margin-break-discard">discard<a class="self-link" href="#valdef-margin-break-discard"></a></dfn> <dd> Margins adjoining a <a data-link-type="dfn" href="#fragmentation-break" id="ref-for-fragmentation-break③">fragmentation break</a> are always truncated, including at the start and end of a <a data-link-type="dfn" href="#fragmentation-context" id="ref-for-fragmentation-context⑧">fragmentation context</a>. </dl> <p class="note" role="note"><span>Note:</span> See also the <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-box-4/#propdef-margin-trim" id="ref-for-propdef-margin-trim">margin-trim</a> property, which applies to the <a data-link-type="dfn" href="#fragmentation-container" id="ref-for-fragmentation-container①">fragmentation container</a> (page/column/etc.)</p> <p class="issue" id="issue-c8907d92"><a class="self-link" href="#issue-c8907d92"></a> <a href="https://www.antennahouse.com/product/ahf66/ahf-focss6.html">Antenna House also allows a second <span class="css">keep</span> keyword</a>, which preserves the margin after the break; it is otherwise discarded. Do we want to include this feature? Also, if only one <a class="css" data-link-type="maybe" href="#valdef-margin-break-keep" id="ref-for-valdef-margin-break-keep">keep</a> is specified, does it apply only to the before margin or both sides? See <a href="https://github.com/w3c/csswg-drafts/issues/3254">discussion</a>.</p> <div class="example" id="example-a4281f24"> <a class="self-link" href="#example-a4281f24"></a> Consider the following <a data-link-type="dfn" href="https://drafts.csswg.org/css-multicol-1/#multi-column-layout" id="ref-for-multi-column-layout">multi-column layout</a> example: <pre><style> article { columns: 16ch; border: solid silver; } h3 { break-before: always; } </style> <article> Here we can compare the effects of <code>margin-break</code>, before and after forced and unforced breaks. This paragraph starts after an unforced break. <h3>This heading is given a forced break before.</h3> </article> </pre> <p>Here are illustrations of how it might render with each <a class="property css" data-link-type="property" href="#propdef-margin-break" id="ref-for-propdef-margin-break②">margin-break</a> value:</p> <figure> <img alt="Here the top margin is kept on the first paragraph and the heading (which starts after a forced break) but not after the second paragraph (which starts after an unforced break). The bottom margins are all discarded at the bottom of each column." src="images/margin-break-auto.png"> <figcaption><a class="css" data-link-type="propdesc" href="#propdef-margin-break" id="ref-for-propdef-margin-break③">margin-break: auto</a> (initial value)</figcaption> </figure> <figure> <img alt="Here the top margins occurring at the top of each column and the bottom margins occurring at the bottom of each column are all truncated to zero." src="images/margin-break-discard.png"> <figcaption><a class="css" data-link-type="propdesc" href="#propdef-margin-break" id="ref-for-propdef-margin-break④">margin-break: discard</a></figcaption> </figure> <figure> <img alt="Here the top margins occurring at the top of each column are all kept; however the bottom margins are still truncated." src="images/margin-break-keep-discard.png"> <figcaption><a class="css" data-link-type="propdesc" href="#propdef-margin-break" id="ref-for-propdef-margin-break⑤">margin-break: keep discard</a></figcaption> </figure> <figure> <img alt="Here the top margins occurring at the top of each column as well as the bottom margins occurring at the bottom of each column are all kept; this increases the height of the auto-height container to accommodate the bottom margins." src="images/margin-break-keep-keep.png"> <figcaption><a class="css" data-link-type="propdesc" href="#propdef-margin-break" id="ref-for-propdef-margin-break⑥">margin-break: keep keep</a></figcaption> </figure> </div> <h3 class="heading settled" data-level="5.3" id="box-splitting"><span class="secno">5.3. </span><span class="content"> Splitting Boxes</span><a class="self-link" href="#box-splitting"></a></h3> <p>When a box breaks, its content box extends to fill any <a data-link-type="dfn" href="#remaining-fragmentainer-extent" id="ref-for-remaining-fragmentainer-extent①">remaining fragmentainer extent</a> (leaving room for any margins/borders/padding applied by <a class="css" data-link-type="propdesc" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break②">box-decoration-break: clone</a>) before the content resumes on the next <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer②②">fragmentainer</a>. (A <a data-link-type="dfn" href="#fragmentation-break" id="ref-for-fragmentation-break④">fragmentation break</a> that pushes content to the next <span id="ref-for-fragmentainer②③">fragmentainer</span> effectively increases the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-size" id="ref-for-block-size②">block size</a> of a box’s contents.)</p> <p class="note" role="note"><span>Note:</span> The extra <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-size" id="ref-for-block-size③">block size</a> contributed by fragmenting the box (i.e. the distance from the break point to the edge of the <a data-link-type="dfn" href="#fragmentainer" id="ref-for-fragmentainer②④">fragmentainer</a>) contributes progress towards any specified limits on the box’s <span id="ref-for-block-size④">block size</span>.</p> <div class="figure"> <img alt="Illustration: Filling remaining fragmentainer extent" src="images/Remaining-Fragmentainer-Extent.svg" style="width: 80%"> <p class="caption"> Illustration of filling the <a data-link-type="dfn" href="#remaining-fragmentainer-extent" id="ref-for-remaining-fragmentainer-extent②">remaining fragmentainer extent</a>. </p> </div> <h3 class="heading settled" data-level="5.4" id="break-decoration"><span class="secno">5.4. </span><span class="content"> Fragmented Borders and Backgrounds: the <a class="property css" data-link-type="property" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break③">box-decoration-break</a> property</span><a class="self-link" href="#break-decoration"></a></h3> <div class="mdn-anno wrapped after"> <button class="mdn-anno-btn"><b class="less-than-two-engines-flag" title="This feature is in less than two current engines.">⚠</b><span>MDN</span></button> <div class="feature"> <p><a href="https://developer.mozilla.org/en-US/docs/Web/CSS/box-decoration-break" title="The box-decoration-break CSS property specifies how an element's fragments should be rendered when broken across multiple lines, columns, or pages.">box-decoration-break</a></p> <p class="less-than-two-engines-text">In only one current engine.</p> <div class="support"> <span class="firefox yes"><span>Firefox</span><span>32+</span></span><span class="safari no"><span>Safari</span><span>None</span></span><span class="chrome no"><span>Chrome</span><span>None</span></span> <hr> <span class="opera no"><span>Opera</span><span>?</span></span><span class="edge_blink no"><span>Edge</span><span>None</span></span> <hr> <span class="edge no"><span>Edge (Legacy)</span><span>?</span></span><span class="ie no"><span>IE</span><span>None</span></span> <hr> <span class="firefox_android no"><span>Firefox for Android</span><span>?</span></span><span class="safari_ios no"><span>iOS Safari</span><span>None</span></span><span class="chrome_android no"><span>Chrome for Android</span><span>None</span></span><span class="webview_android no"><span>Android WebView</span><span>None</span></span><span class="samsunginternet_android no"><span>Samsung Internet</span><span>?</span></span><span class="opera_android no"><span>Opera Mobile</span><span>?</span></span> </div> </div> </div> <table class="def propdef" data-link-for-hint="box-decoration-break"> <tbody> <tr> <th>Name: <td><dfn class="dfn-paneled css" data-dfn-type="property" data-export id="propdef-box-decoration-break">box-decoration-break</dfn> <tr class="value"> <th><a href="https://www.w3.org/TR/css-values/#value-defs">Value:</a> <td class="prod">slice <a data-link-type="grammar" href="https://drafts.csswg.org/css-values-4/#comb-one" id="ref-for-comb-one①⑨">|</a> clone <tr> <th><a href="https://www.w3.org/TR/css-cascade/#initial-values">Initial:</a> <td>slice <tr> <th><a href="https://www.w3.org/TR/css-cascade/#applies-to">Applies to:</a> <td><a href="https://www.w3.org/TR/css-pseudo/#generated-content" title="Includes ::before and ::after pseudo-elements.">all elements</a> <tr> <th><a href="https://www.w3.org/TR/css-cascade/#inherited-property">Inherited:</a> <td>no <tr> <th><a href="https://www.w3.org/TR/css-values/#percentages">Percentages:</a> <td>n/a <tr> <th><a href="https://www.w3.org/TR/css-cascade/#computed">Computed value:</a> <td>specified keyword <tr> <th><a href="https://www.w3.org/TR/cssom/#serializing-css-values">Canonical order:</a> <td>per grammar <tr> <th><a href="https://www.w3.org/TR/web-animations/#animation-type">Animation type:</a> <td>discrete </table> <p>When a break (page/column/region/line) splits a box, the <a class="property css" data-link-type="property" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break④">box-decoration-break</a> property controls</p> <ul> <li> whether the box’s margins, borders, padding, and other decorations wrap the broken edges of the box fragments <li> how the <a data-link-type="dfn">background positioning area</a> <a data-link-type="biblio" href="#biblio-css-backgrounds-3">[CSS-BACKGROUNDS-3]</a> (and <a data-link-type="dfn" href="https://drafts.fxtf.org/css-masking-1/#mask-positioning-area" id="ref-for-mask-positioning-area">mask positioning area</a> <a data-link-type="biblio" href="#biblio-css-masking-1">[CSS-MASKING-1]</a>, shape <a data-link-type="dfn" href="https://drafts.csswg.org/css-shapes-1/#basic-shape-reference-box" id="ref-for-basic-shape-reference-box">reference box</a> <a data-link-type="biblio" href="#biblio-css-shapes-1">[CSS-SHAPES-1]</a>, etc.) is derived from or duplicated across the box fragments and how the element’s background is drawn within them. </ul> <p>Values have the following meanings:</p> <dl> <dt><dfn class="dfn-paneled css" data-dfn-for="box-decoration-break" data-dfn-type="value" data-export id="valdef-box-decoration-break-clone">clone</dfn> <dd> Each box fragment is independently wrapped with the border, padding, and margin. The <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-radius" id="ref-for-propdef-border-radius">border-radius</a> and <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-image" id="ref-for-propdef-border-image">border-image</a> and <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-backgrounds-3/#propdef-box-shadow" id="ref-for-propdef-box-shadow">box-shadow</a>, if any, are applied to each fragment independently. The background is drawn independently in each fragment of the element. A no-repeat background image will thus be rendered once in each fragment of the element. <p class="note" role="note"><span>Note:</span> Cloned margins are <a href="#break-margins">truncated</a> on block-level boxes.</p> <dt><dfn class="dfn-paneled css" data-dfn-for="box-decoration-break" data-dfn-type="value" data-export id="valdef-box-decoration-break-slice">slice</dfn> <dd> The effect is as though the element were rendered with no breaks present, and then sliced by the breaks afterward: no border and no padding are inserted at a break; no box-shadow is drawn at a broken edge; and backgrounds, <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-radius" id="ref-for-propdef-border-radius①">border-radius</a>, and the <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-image" id="ref-for-propdef-border-image①">border-image</a> are applied to the geometry of the whole box as if it were unbroken. </dl> <div class="figure"> <img alt="Illustration: (1) a single box cut in two in between two lines of text by a page break and (2) two boxes, one before and one after the page break, both with a border all around and their own background image" src="images/box-break.png"> <p class="caption">Two possibilities for <a class="property css" data-link-type="property" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break⑤">box-decoration-break</a>: on the left, the value <a class="css" data-link-type="maybe" href="#valdef-box-decoration-break-slice" id="ref-for-valdef-box-decoration-break-slice">slice</a>, on the right the value <a class="css" data-link-type="maybe" href="#valdef-box-decoration-break-clone" id="ref-for-valdef-box-decoration-break-clone②">clone</a>. </p> </div> <p>UAs should also apply <a class="property css" data-link-type="property" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break⑥">box-decoration-break</a> to control rendering at bidi-imposed breaks—<wbr>i.e. when bidi reordering causes an inline to split into non-contiguous fragments—<wbr>and/or at display-type–imposed breaks—<wbr>i.e. when a higher-level <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#display-type" id="ref-for-display-type②">display type</a> (such as a <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#block-level-box" id="ref-for-block-level-box">block-level box</a> / <a href="https://www.w3.org/TR/css-multicol-1/#spanning-columns">column spanner</a>) splits an incompatible ancestor (such as an <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#inline-box" id="ref-for-inline-box">inline box</a> / <a data-link-type="dfn" href="https://drafts.csswg.org/css-display-3/#block-container" id="ref-for-block-container①">block container</a>). Otherwise such breaks must be handled as <a class="css" data-link-type="maybe" href="#valdef-box-decoration-break-slice" id="ref-for-valdef-box-decoration-break-slice①">slice</a>. See <a href="https://www.w3.org/TR/css-writing-modes-3/#bidi-algo">Applying the Bidirectional Reordering Algorithm</a> in <a href="https://www.w3.org/TR/css-writing-modes-3/#text-direction">CSS Writing Modes</a>, <a href="https://www.w3.org/TR/CSS2/visuren.html#box-gen">CSS2§9.2 Block-level elements and block boxes</a>, and <a href="https://www.w3.org/TR/css-multicol-1/#spanning-columns">CSS Multi-column Layout §6 Spanning Columns</a>.</p> <p class="note" role="note"><span>Note:</span> For inline elements, which side of a fragment is considered the broken edge is determined by the parent element’s inline progression direction. For example, if an inline element whose parent has <a class="css" data-link-type="propdesc" href="https://drafts.csswg.org/css-writing-modes-3/#propdef-direction" id="ref-for-propdef-direction">direction: rtl</a> breaks across two lines, the <em>left</em> edge of the fragment on the first line will be the broken edge. (Note in particular that neither the element’s own <span class="property" id="ref-for-propdef-direction①">direction</span> nor its containing block’s <span class="property" id="ref-for-propdef-direction②">direction</span> is used.) See <a data-link-type="biblio" href="#biblio-css-writing-modes-3">[CSS-WRITING-MODES-3]</a>.</p> <h4 class="heading settled" data-level="5.4.1" id="joining-boxes"><span class="secno">5.4.1. </span><span class="content"> Joining Boxes for <a class="css" data-link-type="maybe" href="#valdef-box-decoration-break-slice" id="ref-for-valdef-box-decoration-break-slice②">slice</a></span><a class="self-link" href="#joining-boxes"></a></h4> <p>For <a class="css" data-link-type="propdesc" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break⑦">box-decoration-break: slice</a>, backgrounds (and <a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-image" id="ref-for-propdef-border-image②">border-image</a>) are drawn as if applied to a composite box consisting of all of the box’s fragments reassembled in visual order. This theoretical assembly occurs after the element has been laid out (including any justification, bidi reordering, page breaks, etc.). To assemble the composite box...</p> <dl> <dt>For boxes broken across lines <dd> First, fragments on the same line are connected in visual order. Then, fragments on subsequent lines are ordered according to the element’s <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#inline-base-direction" id="ref-for-inline-base-direction">inline base direction</a> and aligned on the element’s dominant baseline. For example, in a left-to-right containing block (<a class="property css" data-link-type="property" href="https://drafts.csswg.org/css-writing-modes-3/#propdef-direction" id="ref-for-propdef-direction③">direction</a> is <a class="css" data-link-type="maybe" href="https://drafts.csswg.org/css-writing-modes-4/#valdef-direction-ltr" id="ref-for-valdef-direction-ltr">ltr</a>), the first fragment is the leftmost fragment on the first line and fragments from subsequent lines are put to the right of it. In a right-to-left containing block, the first fragment is the rightmost on the first line and subsequent fragments are put to the left of it. <dt>For boxes broken across columns <dd> Fragments are connected as if the column boxes were glued together in the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-flow-direction" id="ref-for-block-flow-direction">block flow direction</a> of the multi-column container. <dt>For boxes broken across pages <dd> Fragments are connected as if page content areas were glued together in the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-flow-direction" id="ref-for-block-flow-direction①">block flow direction</a> of the root element. <dt>For boxes broken across regions <dd> Fragments are connected as if region content areas were glued together in the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-flow-direction" id="ref-for-block-flow-direction②">block flow direction</a> of the <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#principal-writing-mode" id="ref-for-principal-writing-mode">principal writing mode</a> of the <a data-link-type="dfn" href="https://drafts.csswg.org/css-regions-1/#region-chain" id="ref-for-region-chain">region chain</a>. </dl> <p>If the box fragments have different widths (heights, if the fragments are joined horizontally), then each piece draws its portion of the background assuming that the whole element has the same width (height) as this piece. However, if the used height (width) of an image is derived from the width (height) of the box, then it is calculated using the widest fragment’s width and maintained as a fixed size. This ensures that right-aligned images stay aligned to the right edge, left-aligned images stay aligned to the left edge, centered images stay centered, and stretched images cover the background area as intended while preserving continuity across fragments.</p> <h3 class="heading settled" data-level="5.5" id="transforms"><span class="secno">5.5. </span><span class="content"> Transforms, Positioning, and Pagination</span><a class="self-link" href="#transforms"></a></h3> <p>Fragmentation interacts with layout, and thus occurs <em>before</em> relative positioning <a data-link-type="biblio" href="#biblio-css2">[CSS2]</a>, transforms <a data-link-type="biblio" href="#biblio-css-transforms-1">[CSS-TRANSFORMS-1]</a>, and any other graphical effects. Such effects are applied per fragment: for example, rotation applied to a fragmented box will calculate a rotation origin for each fragment and independently rotate that fragment around its origin. (The origin of an overflow-only fragment is determined as if that content were overflowing an empty box with zero margins/borders/padding at the start of the fragmentainer.) However, in order to reduce dataloss when printing, the separation and transfer of page boxes <em>should</em> occur last; thus a transformed fragment that spans pages <em>should</em> be sliced at the page breaks and print in its entirety rather than being clipped by its originating page.</p> <div class="figure"> <img alt="Illustration: Transformed overflow fragmentation" src="images/fragmented-transforms.png"> <p class="caption">A fixed-height box spanning 2.5 pages with overflow content spanning to a total of 4 pages. The transform origin of each fragment is the center of its border box; the fragment without a border box assumes a zero-height box at the start of the overflow. </p> </div> <p>Absolute positioning affects layout and thus interacts with fragmentation. Both the coordinate system and absolutely-positioned boxes belonging to a containing block will fragment across fragmentainers in the same fragmentation flow as the containing block.</p> <p>UAs are not required to correctly position boxes that span a <a data-link-type="dfn" href="#fragmentation-break" id="ref-for-fragmentation-break⑤">fragmentation break</a> and whose <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-4/#block-start" id="ref-for-block-start③">block-start</a> edge position depends on where the box’s content fragments.</p> <p>UAs with memory constraints that prevent them from manipulating an entire document in memory are not required to correctly position absolutely-positioned elements that end up on a previously-rendered page.</p> <h2 class="no-num heading settled" id="priv-sec"><span class="content"> Privacy and Security Considerations</span><a class="self-link" href="#priv-sec"></a></h2> <p>This specification introduces no new privacy or security considerations over CSS in general.</p> <h2 class="no-num heading settled" id="changes"><span class="content"> Changes</span><a class="self-link" href="#changes"></a></h2> <h3 class="no-num heading settled" id="changes-level-4"><span class="content"> Changes Since Level 3</span><a class="self-link" href="#changes-level-4"></a></h3> <p>The following features have been added since <a href="https://www.w3.org/TR/css-break-3/">CSS Fragmentation Level 3</a>:</p> <ul> <li>The <a class="property css" data-link-type="property" href="#propdef-margin-break" id="ref-for-propdef-margin-break⑦">margin-break</a> property. <li>The <a class="css" data-link-type="maybe" href="#valdef-break-before-always" id="ref-for-valdef-break-before-always②">always</a> and <a class="css" data-link-type="maybe" href="#valdef-break-before-all" id="ref-for-valdef-break-before-all③">all</a> values of <a class="property css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before⑨">break-before</a>/<a class="property css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after⑨">break-after</a>. </ul> <h2 class="no-num heading settled" id="acknowledgments"><span class="content"> Acknowledgments</span><a class="self-link" href="#acknowledgments"></a></h2> <p>The editors would like to thank Murakami Shinyu specifically for his contributions to CSS Fragmentation Level 4, and to <a href="https://www.w3.org/TR/css-break-3/#acknowledgments">all the contributors to Level 3</a>, which constitutes the bulk of this specification.</p> </main> <h2 class="no-ref no-num heading settled" id="w3c-conformance"><span class="content"> Conformance</span><a class="self-link" href="#w3c-conformance"></a></h2> <h3 class="no-ref heading settled" id="w3c-conventions"><span class="content"> Document conventions</span><a class="self-link" href="#w3c-conventions"></a></h3> <p>Conformance requirements are expressed with a combination of descriptive assertions and RFC 2119 terminology. The key words “MUST”, “MUST NOT”, “REQUIRED”, “SHALL”, “SHALL NOT”, “SHOULD”, “SHOULD NOT”, “RECOMMENDED”, “MAY”, and “OPTIONAL” in the normative parts of this document are to be interpreted as described in RFC 2119. However, for readability, these words do not appear in all uppercase letters in this specification. </p> <p>All of the text of this specification is normative except sections explicitly marked as non-normative, examples, and notes. <a data-link-type="biblio" href="#biblio-rfc2119">[RFC2119]</a></p> <p>Examples in this specification are introduced with the words “for example” or are set apart from the normative text with <code>class="example"</code>, like this: </p> <div class="example" id="w3c-example"> <a class="self-link" href="#w3c-example"></a> <p>This is an example of an informative example.</p> </div> <p>Informative notes begin with the word “Note” and are set apart from the normative text with <code>class="note"</code>, like this: </p> <p class="note" role="note">Note, this is an informative note.</p> <p>Advisements are normative sections styled to evoke special attention and are set apart from other normative text with <code><strong class="advisement"></code>, like this: <strong class="advisement"> UAs MUST provide an accessible alternative. </strong></p> <details class="wpt-tests-block" dir="ltr" lang="en" open> <summary>Tests</summary> <p>Tests relating to the content of this specification may be documented in “Tests” blocks like this one. Any such block is non-normative.</p> <ul class="wpt-tests-list"></ul> <hr> </details> <h3 class="no-ref heading settled" id="w3c-conformance-classes"><span class="content"> Conformance classes</span><a class="self-link" href="#w3c-conformance-classes"></a></h3> <p>Conformance to this specification is defined for three conformance classes: </p> <dl> <dt>style sheet <dd>A <a href="http://www.w3.org/TR/CSS21/conform.html#style-sheet">CSS style sheet</a>. <dt>renderer <dd>A <a href="http://www.w3.org/TR/CSS21/conform.html#user-agent">UA</a> that interprets the semantics of a style sheet and renders documents that use them. <dt>authoring tool <dd>A <a href="http://www.w3.org/TR/CSS21/conform.html#user-agent">UA</a> that writes a style sheet. </dl> <p>A style sheet is conformant to this specification if all of its statements that use syntax defined in this module are valid according to the generic CSS grammar and the individual grammars of each feature defined in this module. </p> <p>A renderer is conformant to this specification if, in addition to interpreting the style sheet as defined by the appropriate specifications, it supports all the features defined by this specification by parsing them correctly and rendering the document accordingly. However, the inability of a UA to correctly render a document due to limitations of the device does not make the UA non-conformant. (For example, a UA is not required to render color on a monochrome monitor.) </p> <p>An authoring tool is conformant to this specification if it writes style sheets that are syntactically correct according to the generic CSS grammar and the individual grammars of each feature in this module, and meet all other conformance requirements of style sheets as described in this module. </p> <h3 class="no-ref heading settled" id="w3c-partial"><span class="content"> Partial implementations</span><a class="self-link" href="#w3c-partial"></a></h3> <p>So that authors can exploit the forward-compatible parsing rules to assign fallback values, CSS renderers <strong>must</strong> treat as invalid (and <a href="http://www.w3.org/TR/CSS21/conform.html#ignore">ignore as appropriate</a>) any at-rules, properties, property values, keywords, and other syntactic constructs for which they have no usable level of support. In particular, user agents <strong>must not</strong> selectively ignore unsupported component values and honor supported values in a single multi-value property declaration: if any value is considered invalid (as unsupported values must be), CSS requires that the entire declaration be ignored.</p> <h4 class="heading settled" id="w3c-conform-future-proofing"><span class="content"> Implementations of Unstable and Proprietary Features</span><a class="self-link" href="#w3c-conform-future-proofing"></a></h4> <p>To avoid clashes with future stable CSS features, the CSSWG recommends <a href="http://www.w3.org/TR/CSS/#future-proofing">following best practices</a> for the implementation of <a href="http://www.w3.org/TR/CSS/#unstable">unstable</a> features and <a href="http://www.w3.org/TR/CSS/#proprietary-extension">proprietary extensions</a> to CSS. </p> <h3 class="no-ref heading settled" id="w3c-testing"><span class="content"> Non-experimental implementations</span><a class="self-link" href="#w3c-testing"></a></h3> <p>Once a specification reaches the Candidate Recommendation stage, non-experimental implementations are possible, and implementors should release an unprefixed implementation of any CR-level feature they can demonstrate to be correctly implemented according to spec. </p> <p>To establish and maintain the interoperability of CSS across implementations, the CSS Working Group requests that non-experimental CSS renderers submit an implementation report (and, if necessary, the testcases used for that implementation report) to the W3C before releasing an unprefixed implementation of any CSS features. Testcases submitted to W3C are subject to review and correction by the CSS Working Group. </p> <p>Further information on submitting testcases and implementation reports can be found from on the CSS Working Group’s website at <a href="http://www.w3.org/Style/CSS/Test/">http://www.w3.org/Style/CSS/Test/</a>. Questions should be directed to the <a href="http://lists.w3.org/Archives/Public/public-css-testsuite">public-css-testsuite@w3.org</a> mailing list.</p> <script src="https://www.w3.org/scripts/TR/2021/fixup.js"></script> <h2 class="no-num no-ref heading settled" id="index"><span class="content">Index</span><a class="self-link" href="#index"></a></h2> <h3 class="no-num no-ref heading settled" id="index-defined-here"><span class="content">Terms defined by this specification</span><a class="self-link" href="#index-defined-here"></a></h3> <ul class="index"> <li><a href="#valdef-break-before-all">all</a><span>, in § 3.1</span> <li><a href="#valdef-break-before-always">always</a><span>, in § 3.1</span> <li> auto <ul> <li><a href="#valdef-break-before-auto">value for break-before, break-after</a><span>, in § 3.1</span> <li><a href="#valdef-break-inside-auto">value for break-inside, page-break-inside</a><span>, in § 3.2</span> <li><a href="#valdef-margin-break-auto">value for margin-break</a><span>, in § 5.2</span> </ul> <li> avoid <ul> <li><a href="#valdef-break-before-avoid">value for break-before, break-after</a><span>, in § 3.1</span> <li><a href="#valdef-break-inside-avoid">value for break-inside, page-break-inside</a><span>, in § 3.2</span> </ul> <li><a href="#avoid-break-values">avoid break values</a><span>, in § 3.1</span> <li> avoid-column <ul> <li><a href="#valdef-break-before-avoid-column">value for break-before, break-after</a><span>, in § 3.1</span> <li><a href="#valdef-break-inside-avoid-column">value for break-inside, page-break-inside</a><span>, in § 3.2</span> </ul> <li> avoid-page <ul> <li><a href="#valdef-break-before-avoid-page">value for break-before, break-after</a><span>, in § 3.1</span> <li><a href="#valdef-break-inside-avoid-page">value for break-inside, page-break-inside</a><span>, in § 3.2</span> </ul> <li> avoid-region <ul> <li><a href="#valdef-break-before-avoid-region">value for break-before, break-after</a><span>, in § 3.1</span> <li><a href="#valdef-break-inside-avoid-region">value for break-inside, page-break-inside</a><span>, in § 3.2</span> </ul> <li><a href="#propdef-box-decoration-break">box-decoration-break</a><span>, in § 5.4</span> <li><a href="#box-fragment">box fragment</a><span>, in § 2</span> <li><a href="#break">break</a><span>, in § 2</span> <li><a href="#propdef-break-after">break-after</a><span>, in § 3.1</span> <li><a href="#propdef-break-before">break-before</a><span>, in § 3.1</span> <li><a href="#propdef-break-inside">break-inside</a><span>, in § 3.2</span> <li><a href="#valdef-box-decoration-break-clone">clone</a><span>, in § 5.4</span> <li><a href="#valdef-break-before-column">column</a><span>, in § 3.1</span> <li><a href="#column-break">column break</a><span>, in § 4.2</span> <li><a href="#valdef-margin-break-discard">discard</a><span>, in § 5.2</span> <li><a href="#forced-break">forced break</a><span>, in § 4.3</span> <li><a href="#forced-break-values">forced break values</a><span>, in § 3.1</span> <li><a href="#fragment">fragment</a><span>, in § 2</span> <li><a href="#fragmentainer">fragmentainer</a><span>, in § 2</span> <li><a href="#fragmentation">fragmentation</a><span>, in § 2</span> <li><a href="#fragmentation-break">fragmentation break</a><span>, in § 2</span> <li><a href="#fragmentation-container">fragmentation container</a><span>, in § 2</span> <li><a href="#fragmentation-context">fragmentation context</a><span>, in § 2</span> <li><a href="#fragmentation-direction">fragmentation direction</a><span>, in § 2</span> <li><a href="#fragmentation-root">fragmentation root</a><span>, in § 2</span> <li><a href="#fragmented-flow">fragmented flow</a><span>, in § 2</span> <li><a href="#valdef-margin-break-keep">keep</a><span>, in § 5.2</span> <li><a href="#valdef-break-before-left">left</a><span>, in § 3.1</span> <li><a href="#propdef-margin-break">margin-break</a><span>, in § 5.2</span> <li><a href="#monolithic">monolithic</a><span>, in § 4.1</span> <li><a href="#propdef-orphans">orphans</a><span>, in § 3.3</span> <li><a href="#valdef-break-before-page">page</a><span>, in § 3.1</span> <li><a href="#page-break">page break</a><span>, in § 4.2</span> <li><a href="#pagination">pagination</a><span>, in § 1</span> <li><a href="#propagate">propagate</a><span>, in § 3.1.1</span> <li><a href="#propagate">propagation</a><span>, in § 3.1.1</span> <li><a href="#valdef-break-before-recto">recto</a><span>, in § 3.1</span> <li><a href="#valdef-break-before-region">region</a><span>, in § 3.1</span> <li><a href="#region-break">region break</a><span>, in § 4.2</span> <li><a href="#remaining-fragmentainer-extent">remaining fragmentainer extent</a><span>, in § 2</span> <li><a href="#valdef-break-before-right">right</a><span>, in § 3.1</span> <li><a href="#valdef-box-decoration-break-slice">slice</a><span>, in § 5.4</span> <li><a href="#spread-break">spread break</a><span>, in § 4.2</span> <li><a href="#unforced-break">unforced break</a><span>, in § 4.4</span> <li><a href="#valdef-break-before-verso">verso</a><span>, in § 3.1</span> <li><a href="#propdef-widows">widows</a><span>, in § 3.3</span> </ul> <aside class="dfn-panel" data-for="term-for-propdef-border-image"> <a href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-image">https://drafts.csswg.org/css-backgrounds-3/#propdef-border-image</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-border-image">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> <a href="#ref-for-propdef-border-image①">(2)</a> <li><a href="#ref-for-propdef-border-image②">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-border-radius"> <a href="https://drafts.csswg.org/css-backgrounds-3/#propdef-border-radius">https://drafts.csswg.org/css-backgrounds-3/#propdef-border-radius</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-border-radius">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> <a href="#ref-for-propdef-border-radius①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-box-shadow"> <a href="https://drafts.csswg.org/css-backgrounds-3/#propdef-box-shadow">https://drafts.csswg.org/css-backgrounds-3/#propdef-box-shadow</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-box-shadow">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-border-area"> <a href="https://drafts.csswg.org/css-box-4/#border-area">https://drafts.csswg.org/css-box-4/#border-area</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-border-area">2. Fragmentation Model and Terminology</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-margin"> <a href="https://drafts.csswg.org/css-box-4/#margin">https://drafts.csswg.org/css-box-4/#margin</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-margin">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-margin-area"> <a href="https://drafts.csswg.org/css-box-4/#margin-area">https://drafts.csswg.org/css-box-4/#margin-area</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-margin-area">2. Fragmentation Model and Terminology</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-margin-trim"> <a href="https://drafts.csswg.org/css-box-4/#propdef-margin-trim">https://drafts.csswg.org/css-box-4/#propdef-margin-trim</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-margin-trim">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-padding-area"> <a href="https://drafts.csswg.org/css-box-4/#padding-area">https://drafts.csswg.org/css-box-4/#padding-area</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-padding-area">2. Fragmentation Model and Terminology</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-computed-value"> <a href="https://drafts.csswg.org/css-cascade-5/#computed-value">https://drafts.csswg.org/css-cascade-5/#computed-value</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-computed-value">3.1.1. Child→Parent Break Propagation</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-legacy-shorthand"> <a href="https://drafts.csswg.org/css-cascade-5/#legacy-shorthand">https://drafts.csswg.org/css-cascade-5/#legacy-shorthand</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-legacy-shorthand">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-container"> <a href="https://drafts.csswg.org/css-display-3/#block-container">https://drafts.csswg.org/css-display-3/#block-container</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-container">3.3. Breaks Between Lines: orphans, widows</a> <li><a href="#ref-for-block-container①">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-level-box"> <a href="https://drafts.csswg.org/css-display-3/#block-level-box">https://drafts.csswg.org/css-display-3/#block-level-box</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-level-box">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-display-type"> <a href="https://drafts.csswg.org/css-display-3/#display-type">https://drafts.csswg.org/css-display-3/#display-type</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-display-type">2. Fragmentation Model and Terminology</a> <li><a href="#ref-for-display-type①">4.1. Possible Break Points</a> <li><a href="#ref-for-display-type②">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-formatting-context"> <a href="https://drafts.csswg.org/css-display-3/#formatting-context">https://drafts.csswg.org/css-display-3/#formatting-context</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-formatting-context">2.1. Parallel Fragmentation Flows</a> <a href="#ref-for-formatting-context①">(2)</a> <a href="#ref-for-formatting-context②">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-in-flow"> <a href="https://drafts.csswg.org/css-display-3/#in-flow">https://drafts.csswg.org/css-display-3/#in-flow</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-in-flow">3.1.1. Child→Parent Break Propagation</a> <a href="#ref-for-in-flow①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-independent-formatting-context"> <a href="https://drafts.csswg.org/css-display-3/#independent-formatting-context">https://drafts.csswg.org/css-display-3/#independent-formatting-context</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-independent-formatting-context">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-inline-box"> <a href="https://drafts.csswg.org/css-display-3/#inline-box">https://drafts.csswg.org/css-display-3/#inline-box</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-inline-box">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-inline-formatting-context"> <a href="https://drafts.csswg.org/css-display-3/#inline-formatting-context">https://drafts.csswg.org/css-display-3/#inline-formatting-context</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-inline-formatting-context">3.3. Breaks Between Lines: orphans, widows</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-valdef-display-inline-block"> <a href="https://drafts.csswg.org/css-display-3/#valdef-display-inline-block">https://drafts.csswg.org/css-display-3/#valdef-display-inline-block</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-display-inline-block">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-valdef-display-inline-table"> <a href="https://drafts.csswg.org/css-display-3/#valdef-display-inline-table">https://drafts.csswg.org/css-display-3/#valdef-display-inline-table</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-display-inline-table">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-principal-box"> <a href="https://drafts.csswg.org/css-display-3/#principal-box">https://drafts.csswg.org/css-display-3/#principal-box</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-principal-box"> Generic Break Values</a> <a href="#ref-for-principal-box①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-mask-positioning-area"> <a href="https://drafts.fxtf.org/css-masking-1/#mask-positioning-area">https://drafts.fxtf.org/css-masking-1/#mask-positioning-area</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-mask-positioning-area">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-multi-column-container"> <a href="https://drafts.csswg.org/css-multicol-1/#multi-column-container">https://drafts.csswg.org/css-multicol-1/#multi-column-container</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-multi-column-container"> Generic Break Values</a> <a href="#ref-for-multi-column-container①">(2)</a> <a href="#ref-for-multi-column-container②">(3)</a> <a href="#ref-for-multi-column-container③">(4)</a> <a href="#ref-for-multi-column-container④">(5)</a> <a href="#ref-for-multi-column-container⑤">(6)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-multi-column-layout"> <a href="https://drafts.csswg.org/css-multicol-1/#multi-column-layout">https://drafts.csswg.org/css-multicol-1/#multi-column-layout</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-multi-column-layout">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-valdef-overflow-auto"> <a href="https://drafts.csswg.org/css-overflow-3/#valdef-overflow-auto">https://drafts.csswg.org/css-overflow-3/#valdef-overflow-auto</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-overflow-auto">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-overflow"> <a href="https://drafts.csswg.org/css-overflow-3/#propdef-overflow">https://drafts.csswg.org/css-overflow-3/#propdef-overflow</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-overflow">4.1. Possible Break Points</a> <a href="#ref-for-propdef-overflow①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-valdef-overflow-scroll"> <a href="https://drafts.csswg.org/css-overflow-3/#valdef-overflow-scroll">https://drafts.csswg.org/css-overflow-3/#valdef-overflow-scroll</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-overflow-scroll">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-page"> <a href="https://drafts.csswg.org/css-page-3/#propdef-page">https://drafts.csswg.org/css-page-3/#propdef-page</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-page">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-page-progression"> <a href="https://drafts.csswg.org/css-page-3/#page-progression">https://drafts.csswg.org/css-page-3/#page-progression</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-page-progression"> Page Break Values</a> <a href="#ref-for-page-progression①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-top"> <a href="https://drafts.csswg.org/css-position-3/#propdef-top">https://drafts.csswg.org/css-position-3/#propdef-top</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-top">5.1. Breaking into Varying-size Fragmentainers</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-basic-shape-reference-box"> <a href="https://drafts.csswg.org/css-shapes-1/#basic-shape-reference-box">https://drafts.csswg.org/css-shapes-1/#basic-shape-reference-box</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-basic-shape-reference-box">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-valdef-width-auto"> <a href="https://drafts.csswg.org/css-sizing-3/#valdef-width-auto">https://drafts.csswg.org/css-sizing-3/#valdef-width-auto</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-width-auto">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-height"> <a href="https://drafts.csswg.org/css-sizing-3/#propdef-height">https://drafts.csswg.org/css-sizing-3/#propdef-height</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-height">5.1. Breaking into Varying-size Fragmentainers</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-max-content"> <a href="https://drafts.csswg.org/css-sizing-3/#max-content">https://drafts.csswg.org/css-sizing-3/#max-content</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-max-content">5.1. Breaking into Varying-size Fragmentainers</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-min-content"> <a href="https://drafts.csswg.org/css-sizing-3/#min-content">https://drafts.csswg.org/css-sizing-3/#min-content</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-min-content">5.1. Breaking into Varying-size Fragmentainers</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-stretch-fit-size"> <a href="https://drafts.csswg.org/css-sizing-3/#stretch-fit-size">https://drafts.csswg.org/css-sizing-3/#stretch-fit-size</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-stretch-fit-size">5.1. Breaking into Varying-size Fragmentainers</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-line-break"> <a href="https://drafts.csswg.org/css-text-4/#line-break">https://drafts.csswg.org/css-text-4/#line-break</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-line-break">4.2. Types of Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-integer-value"> <a href="https://drafts.csswg.org/css-values-4/#integer-value">https://drafts.csswg.org/css-values-4/#integer-value</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-integer-value">3.3. Breaks Between Lines: orphans, widows</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-css-wide-keywords"> <a href="https://drafts.csswg.org/css-values-4/#css-wide-keywords">https://drafts.csswg.org/css-values-4/#css-wide-keywords</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-css-wide-keywords">1.2. Value Definitions</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-comb-one"> <a href="https://drafts.csswg.org/css-values-4/#comb-one">https://drafts.csswg.org/css-values-4/#comb-one</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-comb-one">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <a href="#ref-for-comb-one①">(2)</a> <a href="#ref-for-comb-one②">(3)</a> <a href="#ref-for-comb-one③">(4)</a> <a href="#ref-for-comb-one④">(5)</a> <a href="#ref-for-comb-one⑤">(6)</a> <a href="#ref-for-comb-one⑥">(7)</a> <a href="#ref-for-comb-one⑦">(8)</a> <a href="#ref-for-comb-one⑧">(9)</a> <a href="#ref-for-comb-one⑨">(10)</a> <a href="#ref-for-comb-one①⓪">(11)</a> <a href="#ref-for-comb-one①①">(12)</a> <a href="#ref-for-comb-one①②">(13)</a> <li><a href="#ref-for-comb-one①③">3.2. Breaks Within Boxes: the break-inside property</a> <a href="#ref-for-comb-one①④">(2)</a> <a href="#ref-for-comb-one①⑤">(3)</a> <a href="#ref-for-comb-one①⑥">(4)</a> <li><a href="#ref-for-comb-one①⑦">5.2. Adjoining Margins at Breaks: the margin-break property</a> <a href="#ref-for-comb-one①⑧">(2)</a> <li><a href="#ref-for-comb-one①⑨">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-direction"> <a href="https://drafts.csswg.org/css-writing-modes-3/#propdef-direction">https://drafts.csswg.org/css-writing-modes-3/#propdef-direction</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-direction">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> <a href="#ref-for-propdef-direction①">(2)</a> <a href="#ref-for-propdef-direction②">(3)</a> <li><a href="#ref-for-propdef-direction③">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-flow-direction"> <a href="https://drafts.csswg.org/css-writing-modes-4/#block-flow-direction">https://drafts.csswg.org/css-writing-modes-4/#block-flow-direction</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-flow-direction">5.4.1. Joining Boxes for slice</a> <a href="#ref-for-block-flow-direction①">(2)</a> <a href="#ref-for-block-flow-direction②">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-size"> <a href="https://drafts.csswg.org/css-writing-modes-4/#block-size">https://drafts.csswg.org/css-writing-modes-4/#block-size</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-size">4. Rules for Breaking</a> <li><a href="#ref-for-block-size①">5.1. Breaking into Varying-size Fragmentainers</a> <li><a href="#ref-for-block-size②">5.3. Splitting Boxes</a> <a href="#ref-for-block-size③">(2)</a> <a href="#ref-for-block-size④">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-axis"> <a href="https://drafts.csswg.org/css-writing-modes-4/#block-axis">https://drafts.csswg.org/css-writing-modes-4/#block-axis</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-axis">2. Fragmentation Model and Terminology</a> <li><a href="#ref-for-block-axis①">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-end"> <a href="https://drafts.csswg.org/css-writing-modes-4/#block-end">https://drafts.csswg.org/css-writing-modes-4/#block-end</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-end">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-block-start"> <a href="https://drafts.csswg.org/css-writing-modes-4/#block-start">https://drafts.csswg.org/css-writing-modes-4/#block-start</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-block-start">4.4. Unforced Breaks</a> <li><a href="#ref-for-block-start①">5.1. Breaking into Varying-size Fragmentainers</a> <a href="#ref-for-block-start②">(2)</a> <li><a href="#ref-for-block-start③">5.5. Transforms, Positioning, and Pagination</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-inline-base-direction"> <a href="https://drafts.csswg.org/css-writing-modes-4/#inline-base-direction">https://drafts.csswg.org/css-writing-modes-4/#inline-base-direction</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-inline-base-direction">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-inline-size"> <a href="https://drafts.csswg.org/css-writing-modes-4/#inline-size">https://drafts.csswg.org/css-writing-modes-4/#inline-size</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-inline-size">5.1. Breaking into Varying-size Fragmentainers</a> <a href="#ref-for-inline-size①">(2)</a> <a href="#ref-for-inline-size②">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-logical-height"> <a href="https://drafts.csswg.org/css-writing-modes-4/#logical-height">https://drafts.csswg.org/css-writing-modes-4/#logical-height</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-logical-height">4.1. Possible Break Points</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-valdef-direction-ltr"> <a href="https://drafts.csswg.org/css-writing-modes-4/#valdef-direction-ltr">https://drafts.csswg.org/css-writing-modes-4/#valdef-direction-ltr</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-direction-ltr">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-principal-writing-mode"> <a href="https://drafts.csswg.org/css-writing-modes-4/#principal-writing-mode">https://drafts.csswg.org/css-writing-modes-4/#principal-writing-mode</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-principal-writing-mode">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-page-break-after"> <a href="https://drafts.csswg.org/css2/#propdef-page-break-after">https://drafts.csswg.org/css2/#propdef-page-break-after</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-page-break-after">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> <a href="#ref-for-propdef-page-break-after①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-page-break-before"> <a href="https://drafts.csswg.org/css2/#propdef-page-break-before">https://drafts.csswg.org/css2/#propdef-page-break-before</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-page-break-before">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> <a href="#ref-for-propdef-page-break-before①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-propdef-page-break-inside"> <a href="https://drafts.csswg.org/css2/#propdef-page-break-inside">https://drafts.csswg.org/css2/#propdef-page-break-inside</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-page-break-inside">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> <a href="#ref-for-propdef-page-break-inside①">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-region-chain"> <a href="https://drafts.csswg.org/css-regions-1/#region-chain">https://drafts.csswg.org/css-regions-1/#region-chain</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-region-chain">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-continuous-media"> <a href="https://drafts.csswg.org/mediaqueries-5/#continuous-media">https://drafts.csswg.org/mediaqueries-5/#continuous-media</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-continuous-media">1. Introduction</a> </ul> </aside> <aside class="dfn-panel" data-for="term-for-paged-media"> <a href="https://drafts.csswg.org/mediaqueries-5/#paged-media">https://drafts.csswg.org/mediaqueries-5/#paged-media</a><b>Referenced in:</b> <ul> <li><a href="#ref-for-paged-media">1. Introduction</a> <a href="#ref-for-paged-media①">(2)</a> <li><a href="#ref-for-paged-media②">2. Fragmentation Model and Terminology</a> <li><a href="#ref-for-paged-media③"> Generic Break Values</a> <a href="#ref-for-paged-media④">(2)</a> </ul> </aside> <h3 class="no-num no-ref heading settled" id="index-defined-elsewhere"><span class="content">Terms defined by reference</span><a class="self-link" href="#index-defined-elsewhere"></a></h3> <ul class="index"> <li> <a data-link-type="biblio">[CSS-BACKGROUNDS-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-propdef-border-image">border-image</span> <li><span class="dfn-paneled" id="term-for-propdef-border-radius">border-radius</span> <li><span class="dfn-paneled" id="term-for-propdef-box-shadow">box-shadow</span> </ul> <li> <a data-link-type="biblio">[css-box-4]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-border-area">border area</span> <li><span class="dfn-paneled" id="term-for-margin">margin</span> <li><span class="dfn-paneled" id="term-for-margin-area">margin area</span> <li><span class="dfn-paneled" id="term-for-propdef-margin-trim">margin-trim</span> <li><span class="dfn-paneled" id="term-for-padding-area">padding area</span> </ul> <li> <a data-link-type="biblio">[css-cascade-5]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-computed-value">computed value</span> <li><span class="dfn-paneled" id="term-for-legacy-shorthand">legacy shorthand</span> </ul> <li> <a data-link-type="biblio">[css-display-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-block-container">block container</span> <li><span class="dfn-paneled" id="term-for-block-level-box">block-level box</span> <li><span class="dfn-paneled" id="term-for-display-type">display type</span> <li><span class="dfn-paneled" id="term-for-formatting-context">formatting context</span> <li><span class="dfn-paneled" id="term-for-in-flow">in-flow</span> <li><span class="dfn-paneled" id="term-for-independent-formatting-context">independent formatting context</span> <li><span class="dfn-paneled" id="term-for-inline-box">inline box</span> <li><span class="dfn-paneled" id="term-for-inline-formatting-context">inline formatting context</span> <li><span class="dfn-paneled" id="term-for-valdef-display-inline-block">inline-block</span> <li><span class="dfn-paneled" id="term-for-valdef-display-inline-table">inline-table</span> <li><span class="dfn-paneled" id="term-for-principal-box">principal box</span> </ul> <li> <a data-link-type="biblio">[CSS-MASKING-1]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-mask-positioning-area">mask positioning area</span> </ul> <li> <a data-link-type="biblio">[CSS-MULTICOL-1]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-multi-column-container">multi-column container</span> <li><span class="dfn-paneled" id="term-for-multi-column-layout">multi-column layout</span> </ul> <li> <a data-link-type="biblio">[css-overflow-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-valdef-overflow-auto">auto</span> <li><span class="dfn-paneled" id="term-for-propdef-overflow">overflow</span> <li><span class="dfn-paneled" id="term-for-valdef-overflow-scroll">scroll</span> </ul> <li> <a data-link-type="biblio">[CSS-PAGE-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-propdef-page">page</span> <li><span class="dfn-paneled" id="term-for-page-progression">page progression</span> </ul> <li> <a data-link-type="biblio">[css-position-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-propdef-top">top</span> </ul> <li> <a data-link-type="biblio">[CSS-SHAPES-1]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-basic-shape-reference-box">reference box</span> </ul> <li> <a data-link-type="biblio">[CSS-SIZING-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-valdef-width-auto">auto</span> <li><span class="dfn-paneled" id="term-for-propdef-height">height</span> <li><span class="dfn-paneled" id="term-for-max-content">max-content size</span> <li><span class="dfn-paneled" id="term-for-min-content">min-content size</span> <li><span class="dfn-paneled" id="term-for-stretch-fit-size">stretch-fit size</span> </ul> <li> <a data-link-type="biblio">[css-text-4]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-line-break">line break</span> </ul> <li> <a data-link-type="biblio">[css-values-4]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-integer-value"><integer></span> <li><span class="dfn-paneled" id="term-for-css-wide-keywords">css-wide keywords</span> <li><span class="dfn-paneled" id="term-for-comb-one">|</span> </ul> <li> <a data-link-type="biblio">[css-writing-modes-3]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-propdef-direction">direction</span> </ul> <li> <a data-link-type="biblio">[css-writing-modes-4]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-block-flow-direction">block flow direction</span> <li><span class="dfn-paneled" id="term-for-block-size">block size</span> <li><span class="dfn-paneled" id="term-for-block-axis">block-axis</span> <li><span class="dfn-paneled" id="term-for-block-end">block-end</span> <li><span class="dfn-paneled" id="term-for-block-start">block-start</span> <li><span class="dfn-paneled" id="term-for-inline-base-direction">inline base direction</span> <li><span class="dfn-paneled" id="term-for-inline-size">inline size</span> <li><span class="dfn-paneled" id="term-for-logical-height">logical height</span> <li><span class="dfn-paneled" id="term-for-valdef-direction-ltr">ltr</span> <li><span class="dfn-paneled" id="term-for-principal-writing-mode">principal writing mode</span> </ul> <li> <a data-link-type="biblio">[CSS2]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-propdef-page-break-after">page-break-after</span> <li><span class="dfn-paneled" id="term-for-propdef-page-break-before">page-break-before</span> <li><span class="dfn-paneled" id="term-for-propdef-page-break-inside">page-break-inside</span> </ul> <li> <a data-link-type="biblio">[CSS3-REGIONS]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-region-chain">region chain</span> </ul> <li> <a data-link-type="biblio">[mediaqueries-5]</a> defines the following terms: <ul> <li><span class="dfn-paneled" id="term-for-continuous-media">continuous media</span> <li><span class="dfn-paneled" id="term-for-paged-media">paged media</span> </ul> </ul> <h2 class="no-num no-ref heading settled" id="references"><span class="content">References</span><a class="self-link" href="#references"></a></h2> <h3 class="no-num no-ref heading settled" id="normative"><span class="content">Normative References</span><a class="self-link" href="#normative"></a></h3> <dl> <dt id="biblio-css-backgrounds-3">[CSS-BACKGROUNDS-3] <dd>Bert Bos; Elika Etemad; Brad Kemper. <a href="https://www.w3.org/TR/css-backgrounds-3/"><cite>CSS Backgrounds and Borders Module Level 3</cite></a>. 26 July 2021. CR. URL: <a href="https://www.w3.org/TR/css-backgrounds-3/">https://www.w3.org/TR/css-backgrounds-3/</a> <dt id="biblio-css-box-4">[CSS-BOX-4] <dd>Elika Etemad. <a href="https://www.w3.org/TR/css-box-4/"><cite>CSS Box Model Module Level 4</cite></a>. 21 April 2020. WD. URL: <a href="https://www.w3.org/TR/css-box-4/">https://www.w3.org/TR/css-box-4/</a> <dt id="biblio-css-cascade-5">[CSS-CASCADE-5] <dd>Elika Etemad; Miriam Suzanne; Tab Atkins Jr.. <a href="https://www.w3.org/TR/css-cascade-5/"><cite>CSS Cascading and Inheritance Level 5</cite></a>. 13 January 2022. CR. URL: <a href="https://www.w3.org/TR/css-cascade-5/">https://www.w3.org/TR/css-cascade-5/</a> <dt id="biblio-css-display-3">[CSS-DISPLAY-3] <dd>Tab Atkins Jr.; Elika Etemad. <a href="https://www.w3.org/TR/css-display-3/"><cite>CSS Display Module Level 3</cite></a>. 3 September 2021. CR. URL: <a href="https://www.w3.org/TR/css-display-3/">https://www.w3.org/TR/css-display-3/</a> <dt id="biblio-css-masking-1">[CSS-MASKING-1] <dd>Dirk Schulze; Brian Birtles; Tab Atkins Jr.. <a href="https://www.w3.org/TR/css-masking-1/"><cite>CSS Masking Module Level 1</cite></a>. 5 August 2021. CR. URL: <a href="https://www.w3.org/TR/css-masking-1/">https://www.w3.org/TR/css-masking-1/</a> <dt id="biblio-css-multicol-1">[CSS-MULTICOL-1] <dd>Florian Rivoal; Rachel Andrew. <a href="https://www.w3.org/TR/css-multicol-1/"><cite>CSS Multi-column Layout Module Level 1</cite></a>. 12 October 2021. CR. URL: <a href="https://www.w3.org/TR/css-multicol-1/">https://www.w3.org/TR/css-multicol-1/</a> <dt id="biblio-css-overflow-3">[CSS-OVERFLOW-3] <dd>David Baron; Elika Etemad; Florian Rivoal. <a href="https://www.w3.org/TR/css-overflow-3/"><cite>CSS Overflow Module Level 3</cite></a>. 23 December 2021. WD. URL: <a href="https://www.w3.org/TR/css-overflow-3/">https://www.w3.org/TR/css-overflow-3/</a> <dt id="biblio-css-page-3">[CSS-PAGE-3] <dd>Elika Etemad; Simon Sapin. <a href="https://www.w3.org/TR/css-page-3/"><cite>CSS Paged Media Module Level 3</cite></a>. 18 October 2018. WD. URL: <a href="https://www.w3.org/TR/css-page-3/">https://www.w3.org/TR/css-page-3/</a> <dt id="biblio-css-shapes-1">[CSS-SHAPES-1] <dd>Vincent Hardy; Rossen Atanassov; Alan Stearns. <a href="https://www.w3.org/TR/css-shapes-1/"><cite>CSS Shapes Module Level 1</cite></a>. 20 March 2014. CR. URL: <a href="https://www.w3.org/TR/css-shapes-1/">https://www.w3.org/TR/css-shapes-1/</a> <dt id="biblio-css-sizing-3">[CSS-SIZING-3] <dd>Tab Atkins Jr.; Elika Etemad. <a href="https://www.w3.org/TR/css-sizing-3/"><cite>CSS Box Sizing Module Level 3</cite></a>. 17 December 2021. WD. URL: <a href="https://www.w3.org/TR/css-sizing-3/">https://www.w3.org/TR/css-sizing-3/</a> <dt id="biblio-css-transforms-1">[CSS-TRANSFORMS-1] <dd>Simon Fraser; et al. <a href="https://www.w3.org/TR/css-transforms-1/"><cite>CSS Transforms Module Level 1</cite></a>. 14 February 2019. CR. URL: <a href="https://www.w3.org/TR/css-transforms-1/">https://www.w3.org/TR/css-transforms-1/</a> <dt id="biblio-css-values-3">[CSS-VALUES-3] <dd>Tab Atkins Jr.; Elika Etemad. <a href="https://www.w3.org/TR/css-values-3/"><cite>CSS Values and Units Module Level 3</cite></a>. 6 June 2019. CR. URL: <a href="https://www.w3.org/TR/css-values-3/">https://www.w3.org/TR/css-values-3/</a> <dt id="biblio-css-values-4">[CSS-VALUES-4] <dd>Tab Atkins Jr.; Elika Etemad. <a href="https://www.w3.org/TR/css-values-4/"><cite>CSS Values and Units Module Level 4</cite></a>. 16 December 2021. WD. URL: <a href="https://www.w3.org/TR/css-values-4/">https://www.w3.org/TR/css-values-4/</a> <dt id="biblio-css-writing-modes-3">[CSS-WRITING-MODES-3] <dd>CSS Writing Modes Module Level 3 URL: <a href="https://www.w3.org/TR/css-writing-modes-3/">https://www.w3.org/TR/css-writing-modes-3/</a> <dt id="biblio-css-writing-modes-4">[CSS-WRITING-MODES-4] <dd>Elika Etemad; Koji Ishii. <a href="https://www.w3.org/TR/css-writing-modes-4/"><cite>CSS Writing Modes Level 4</cite></a>. 30 July 2019. CR. URL: <a href="https://www.w3.org/TR/css-writing-modes-4/">https://www.w3.org/TR/css-writing-modes-4/</a> <dt id="biblio-css2">[CSS2] <dd>Bert Bos; et al. <a href="https://www.w3.org/TR/CSS21/"><cite>Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification</cite></a>. 7 June 2011. REC. URL: <a href="https://www.w3.org/TR/CSS21/">https://www.w3.org/TR/CSS21/</a> <dt id="biblio-css3-regions">[CSS3-REGIONS] <dd>Rossen Atanassov; Alan Stearns. <a href="https://www.w3.org/TR/css-regions-1/"><cite>CSS Regions Module Level 1</cite></a>. 9 October 2014. WD. URL: <a href="https://www.w3.org/TR/css-regions-1/">https://www.w3.org/TR/css-regions-1/</a> <dt id="biblio-mediaqueries-5">[MEDIAQUERIES-5] <dd>Dean Jackson; et al. <a href="https://www.w3.org/TR/mediaqueries-5/"><cite>Media Queries Level 5</cite></a>. 18 December 2021. WD. URL: <a href="https://www.w3.org/TR/mediaqueries-5/">https://www.w3.org/TR/mediaqueries-5/</a> <dt id="biblio-rfc2119">[RFC2119] <dd>S. Bradner. <a href="https://datatracker.ietf.org/doc/html/rfc2119"><cite>Key words for use in RFCs to Indicate Requirement Levels</cite></a>. March 1997. Best Current Practice. URL: <a href="https://datatracker.ietf.org/doc/html/rfc2119">https://datatracker.ietf.org/doc/html/rfc2119</a> </dl> <h3 class="no-num no-ref heading settled" id="informative"><span class="content">Informative References</span><a class="self-link" href="#informative"></a></h3> <dl> <dt id="biblio-css-flexbox-1">[CSS-FLEXBOX-1] <dd>Tab Atkins Jr.; et al. <a href="https://www.w3.org/TR/css-flexbox-1/"><cite>CSS Flexible Box Layout Module Level 1</cite></a>. 19 November 2018. CR. URL: <a href="https://www.w3.org/TR/css-flexbox-1/">https://www.w3.org/TR/css-flexbox-1/</a> <dt id="biblio-css-grid-1">[CSS-GRID-1] <dd>Tab Atkins Jr.; et al. <a href="https://www.w3.org/TR/css-grid-1/"><cite>CSS Grid Layout Module Level 1</cite></a>. 18 December 2020. CR. URL: <a href="https://www.w3.org/TR/css-grid-1/">https://www.w3.org/TR/css-grid-1/</a> <dt id="biblio-css-position-3">[CSS-POSITION-3] <dd>Elika Etemad; Tab Atkins Jr.. <a href="https://www.w3.org/TR/css-position-3/"><cite>CSS Positioned Layout Module Level 3</cite></a>. 16 December 2021. WD. URL: <a href="https://www.w3.org/TR/css-position-3/">https://www.w3.org/TR/css-position-3/</a> <dt id="biblio-css-text-3">[CSS-TEXT-3] <dd>Elika Etemad; Koji Ishii; Florian Rivoal. <a href="https://www.w3.org/TR/css-text-3/"><cite>CSS Text Module Level 3</cite></a>. 5 May 2022. CR. URL: <a href="https://www.w3.org/TR/css-text-3/">https://www.w3.org/TR/css-text-3/</a> <dt id="biblio-css-text-4">[CSS-TEXT-4] <dd>Elika Etemad; et al. <a href="https://www.w3.org/TR/css-text-4/"><cite>CSS Text Module Level 4</cite></a>. 5 May 2022. WD. URL: <a href="https://www.w3.org/TR/css-text-4/">https://www.w3.org/TR/css-text-4/</a> </dl> <h2 class="no-num no-ref heading settled" id="property-index"><span class="content">Property Index</span><a class="self-link" href="#property-index"></a></h2> <div class="big-element-wrapper"> <table class="index"> <thead> <tr> <th scope="col">Name <th scope="col">Value <th scope="col">Initial <th scope="col">Applies to <th scope="col">Inh. <th scope="col">%ages <th scope="col">Animation type <th scope="col">Canonical order <th scope="col">Computed value <tbody> <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-box-decoration-break" id="ref-for-propdef-box-decoration-break⑧">box-decoration-break</a> <td>slice | clone <td>slice <td>all elements <td>no <td>n/a <td>discrete <td>per grammar <td>specified keyword <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-break-after" id="ref-for-propdef-break-after①⓪">break-after</a> <td>auto | avoid | always | all | avoid-page | page | left | right | recto | verso | avoid-column | column | avoid-region | region <td>auto <td>block-level boxes, grid items, flex items, table row groups, table rows (but see prose) <td>no <td>n/a <td>discrete <td>per grammar <td>specified keyword <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-break-before" id="ref-for-propdef-break-before①⓪">break-before</a> <td>auto | avoid | always | all | avoid-page | page | left | right | recto | verso | avoid-column | column | avoid-region | region <td>auto <td>block-level boxes, grid items, flex items, table row groups, table rows (but see prose) <td>no <td>n/a <td>discrete <td>per grammar <td>specified keyword <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-break-inside" id="ref-for-propdef-break-inside⑥">break-inside</a> <td>auto | avoid | avoid-page | avoid-column | avoid-region <td>auto <td>all elements except inline-level boxes, internal ruby boxes, table column boxes, table column group boxes, absolutely-positioned boxes <td>no <td>n/a <td>discrete <td>per grammar <td>specified keyword <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-margin-break" id="ref-for-propdef-margin-break⑧">margin-break</a> <td>auto | keep | discard <td>auto <td>all elements <td>no <td>n/a <td>discrete <td>per grammar <td>specified keyword <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-orphans" id="ref-for-propdef-orphans⑧">orphans</a> <td><integer [0,∞]> <td>2 <td>block containers that establish an inline formatting context <td>yes <td>n/a <td>by computed value type <td>per grammar <td>specified integer <tr> <th scope="row"><a class="css" data-link-type="property" href="#propdef-widows" id="ref-for-propdef-widows⑧">widows</a> <td><integer [0,∞]> <td>2 <td>block containers that establish an inline formatting context <td>yes <td>n/a <td>by computed value type <td>per grammar <td>specified integer </table> </div> <h2 class="no-num no-ref heading settled" id="issues-index"><span class="content">Issues Index</span><a class="self-link" href="#issues-index"></a></h2> <div style="counter-reset:issue"> <div class="issue"> It’s unclear if this value is needed. <a class="issue-return" href="#issue-9e81b4a6" title="Jump to section">↵</a></div> <div class="issue"> <a href="https://www.antennahouse.com/product/ahf66/ahf-focss6.html">Antenna House also allows a second <span class="css">keep</span> keyword</a>, which preserves the margin after the break; it is otherwise discarded. Do we want to include this feature? Also, if only one <a class="css" data-link-type="maybe" href="#valdef-margin-break-keep">keep</a> is specified, does it apply only to the before margin or both sides? See <a href="https://github.com/w3c/csswg-drafts/issues/3254">discussion</a>. <a class="issue-return" href="#issue-c8907d92" title="Jump to section">↵</a></div> </div> <aside class="dfn-panel" data-for="fragmentation-container"> <b><a href="#fragmentation-container">#fragmentation-container</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmentation-container">1. Introduction</a> <li><a href="#ref-for-fragmentation-container①">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="fragmentainer"> <b><a href="#fragmentainer">#fragmentainer</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmentainer">1. Introduction</a> <li><a href="#ref-for-fragmentainer①">2. Fragmentation Model and Terminology</a> <a href="#ref-for-fragmentainer②">(2)</a> <a href="#ref-for-fragmentainer③">(3)</a> <a href="#ref-for-fragmentainer④">(4)</a> <a href="#ref-for-fragmentainer⑤">(5)</a> <a href="#ref-for-fragmentainer⑥">(6)</a> <a href="#ref-for-fragmentainer⑦">(7)</a> <a href="#ref-for-fragmentainer⑧">(8)</a> <a href="#ref-for-fragmentainer⑨">(9)</a> <a href="#ref-for-fragmentainer①⓪">(10)</a> <li><a href="#ref-for-fragmentainer①①">2.1. Parallel Fragmentation Flows</a> <li><a href="#ref-for-fragmentainer①②">2.2. Nested Fragmentation Flows</a> <a href="#ref-for-fragmentainer①③">(2)</a> <a href="#ref-for-fragmentainer①④">(3)</a> <a href="#ref-for-fragmentainer①⑤">(4)</a> <li><a href="#ref-for-fragmentainer①⑥">4. Rules for Breaking</a> <li><a href="#ref-for-fragmentainer①⑦">4.4. Unforced Breaks</a> <a href="#ref-for-fragmentainer①⑧">(2)</a> <li><a href="#ref-for-fragmentainer①⑨">4.5. Optimizing Unforced Breaks</a> <a href="#ref-for-fragmentainer②⓪">(2)</a> <a href="#ref-for-fragmentainer②①">(3)</a> <li><a href="#ref-for-fragmentainer②②">5.3. Splitting Boxes</a> <a href="#ref-for-fragmentainer②③">(2)</a> <a href="#ref-for-fragmentainer②④">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="fragmentation-context"> <b><a href="#fragmentation-context">#fragmentation-context</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmentation-context">2. Fragmentation Model and Terminology</a> <a href="#ref-for-fragmentation-context①">(2)</a> <a href="#ref-for-fragmentation-context②">(3)</a> <a href="#ref-for-fragmentation-context③">(4)</a> <li><a href="#ref-for-fragmentation-context④">2.2. Nested Fragmentation Flows</a> <a href="#ref-for-fragmentation-context⑤">(2)</a> <li><a href="#ref-for-fragmentation-context⑥"> Generic Break Values</a> <a href="#ref-for-fragmentation-context⑦">(2)</a> <li><a href="#ref-for-fragmentation-context⑧">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="fragmented-flow"> <b><a href="#fragmented-flow">#fragmented-flow</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmented-flow">2. Fragmentation Model and Terminology</a> <a href="#ref-for-fragmented-flow①">(2)</a> <li><a href="#ref-for-fragmented-flow②">2.1. Parallel Fragmentation Flows</a> <li><a href="#ref-for-fragmented-flow③">3. Controlling Breaks</a> <li><a href="#ref-for-fragmented-flow④">4. Rules for Breaking</a> <li><a href="#ref-for-fragmented-flow⑤">4.4. Unforced Breaks</a> <li><a href="#ref-for-fragmented-flow⑥">4.5. Optimizing Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="fragmentation-root"> <b><a href="#fragmentation-root">#fragmentation-root</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmentation-root">2. Fragmentation Model and Terminology</a> <a href="#ref-for-fragmentation-root①">(2)</a> <li><a href="#ref-for-fragmentation-root②">2.1. Parallel Fragmentation Flows</a> <li><a href="#ref-for-fragmentation-root③">3.1. Breaks Between Boxes: the break-before and break-after properties</a> </ul> </aside> <aside class="dfn-panel" data-for="fragmentation"> <b><a href="#fragmentation">#fragmentation</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmentation">1. Introduction</a> </ul> </aside> <aside class="dfn-panel" data-for="box-fragment"> <b><a href="#box-fragment">#box-fragment</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-box-fragment">2. Fragmentation Model and Terminology</a> <li><a href="#ref-for-box-fragment①">4.5. Optimizing Unforced Breaks</a> <a href="#ref-for-box-fragment②">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="fragment"> <b><a href="#fragment">#fragment</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragment">2. Fragmentation Model and Terminology</a> <li><a href="#ref-for-fragment①">3.3. Breaks Between Lines: orphans, widows</a> <a href="#ref-for-fragment②">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="remaining-fragmentainer-extent"> <b><a href="#remaining-fragmentainer-extent">#remaining-fragmentainer-extent</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-remaining-fragmentainer-extent">5.2. Adjoining Margins at Breaks: the margin-break property</a> <li><a href="#ref-for-remaining-fragmentainer-extent①">5.3. Splitting Boxes</a> <a href="#ref-for-remaining-fragmentainer-extent②">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="fragmentation-break"> <b><a href="#fragmentation-break">#fragmentation-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-fragmentation-break">4.5. Optimizing Unforced Breaks</a> <li><a href="#ref-for-fragmentation-break①">5.2. Adjoining Margins at Breaks: the margin-break property</a> <a href="#ref-for-fragmentation-break②">(2)</a> <a href="#ref-for-fragmentation-break③">(3)</a> <li><a href="#ref-for-fragmentation-break④">5.3. Splitting Boxes</a> <li><a href="#ref-for-fragmentation-break⑤">5.5. Transforms, Positioning, and Pagination</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-break-before"> <b><a href="#propdef-break-before">#propdef-break-before</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-break-before①">1. Introduction</a> <li><a href="#ref-for-propdef-break-before②">3. Controlling Breaks</a> <li><a href="#ref-for-propdef-break-before③">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <a href="#ref-for-propdef-break-before④">(2)</a> <li><a href="#ref-for-propdef-break-before⑤">3.1.1. Child→Parent Break Propagation</a> <li><a href="#ref-for-propdef-break-before⑥">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> <li><a href="#ref-for-propdef-break-before⑦">4.3. Forced Breaks</a> <li><a href="#ref-for-propdef-break-before⑧">4.4. Unforced Breaks</a> <li><a href="#ref-for-propdef-break-before⑨"> Changes Since Level 3</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-break-after"> <b><a href="#propdef-break-after">#propdef-break-after</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-break-after①">1. Introduction</a> <li><a href="#ref-for-propdef-break-after②">3. Controlling Breaks</a> <li><a href="#ref-for-propdef-break-after③">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <a href="#ref-for-propdef-break-after④">(2)</a> <li><a href="#ref-for-propdef-break-after⑤">3.1.1. Child→Parent Break Propagation</a> <li><a href="#ref-for-propdef-break-after⑥">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> <li><a href="#ref-for-propdef-break-after⑦">4.3. Forced Breaks</a> <li><a href="#ref-for-propdef-break-after⑧">4.4. Unforced Breaks</a> <li><a href="#ref-for-propdef-break-after⑨"> Changes Since Level 3</a> </ul> </aside> <aside class="dfn-panel" data-for="forced-break-values"> <b><a href="#forced-break-values">#forced-break-values</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-forced-break-values">4.3. Forced Breaks</a> <a href="#ref-for-forced-break-values①">(2)</a> <a href="#ref-for-forced-break-values②">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="avoid-break-values"> <b><a href="#avoid-break-values">#avoid-break-values</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-avoid-break-values">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-auto"> <b><a href="#valdef-break-before-auto">#valdef-break-before-auto</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-auto">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-avoid"> <b><a href="#valdef-break-before-avoid">#valdef-break-before-avoid</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-avoid">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-avoid①">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-always"> <b><a href="#valdef-break-before-always">#valdef-break-before-always</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-always">1. Introduction</a> <li><a href="#ref-for-valdef-break-before-always①">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-always②"> Changes Since Level 3</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-all"> <b><a href="#valdef-break-before-all">#valdef-break-before-all</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-all①">1. Introduction</a> <li><a href="#ref-for-valdef-break-before-all②">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-all③"> Changes Since Level 3</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-avoid-page"> <b><a href="#valdef-break-before-avoid-page">#valdef-break-before-avoid-page</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-avoid-page">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-avoid-page①">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-page"> <b><a href="#valdef-break-before-page">#valdef-break-before-page</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-page">3.1. Breaks Between Boxes: the break-before and break-after properties</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-left"> <b><a href="#valdef-break-before-left">#valdef-break-before-left</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-left">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-left①">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-right"> <b><a href="#valdef-break-before-right">#valdef-break-before-right</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-right">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-right①">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-recto"> <b><a href="#valdef-break-before-recto">#valdef-break-before-recto</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-recto">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-recto①">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-verso"> <b><a href="#valdef-break-before-verso">#valdef-break-before-verso</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-verso">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-verso①">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-avoid-column"> <b><a href="#valdef-break-before-avoid-column">#valdef-break-before-avoid-column</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-avoid-column">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-avoid-column①">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-column"> <b><a href="#valdef-break-before-column">#valdef-break-before-column</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-column">3.1. Breaks Between Boxes: the break-before and break-after properties</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-avoid-region"> <b><a href="#valdef-break-before-avoid-region">#valdef-break-before-avoid-region</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-avoid-region">3.1. Breaks Between Boxes: the break-before and break-after properties</a> <li><a href="#ref-for-valdef-break-before-avoid-region①">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-before-region"> <b><a href="#valdef-break-before-region">#valdef-break-before-region</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-before-region">3.1. Breaks Between Boxes: the break-before and break-after properties</a> </ul> </aside> <aside class="dfn-panel" data-for="propagate"> <b><a href="#propagate">#propagate</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propagate">3.1.1. Child→Parent Break Propagation</a> <a href="#ref-for-propagate①">(2)</a> <a href="#ref-for-propagate②">(3)</a> <li><a href="#ref-for-propagate③">4.3. Forced Breaks</a> <a href="#ref-for-propagate④">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-break-inside"> <b><a href="#propdef-break-inside">#propdef-break-inside</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-break-inside">3. Controlling Breaks</a> <a href="#ref-for-propdef-break-inside①">(2)</a> <li><a href="#ref-for-propdef-break-inside②">3.2. Breaks Within Boxes: the break-inside property</a> <li><a href="#ref-for-propdef-break-inside③">3.4. Page Break Aliases: the page-break-before, page-break-after, and page-break-inside properties</a> <li><a href="#ref-for-propdef-break-inside④">4.4. Unforced Breaks</a> <a href="#ref-for-propdef-break-inside⑤">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-inside-auto"> <b><a href="#valdef-break-inside-auto">#valdef-break-inside-auto</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-inside-auto">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-break-inside-avoid"> <b><a href="#valdef-break-inside-avoid">#valdef-break-inside-avoid</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-break-inside-avoid">4.4. Unforced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-orphans"> <b><a href="#propdef-orphans">#propdef-orphans</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-orphans">3. Controlling Breaks</a> <li><a href="#ref-for-propdef-orphans①">3.3. Breaks Between Lines: orphans, widows</a> <a href="#ref-for-propdef-orphans②">(2)</a> <a href="#ref-for-propdef-orphans③">(3)</a> <a href="#ref-for-propdef-orphans④">(4)</a> <li><a href="#ref-for-propdef-orphans⑤">4.4. Unforced Breaks</a> <li><a href="#ref-for-propdef-orphans⑥">4.5. Optimizing Unforced Breaks</a> <a href="#ref-for-propdef-orphans⑦">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-widows"> <b><a href="#propdef-widows">#propdef-widows</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-widows">3. Controlling Breaks</a> <li><a href="#ref-for-propdef-widows①">3.3. Breaks Between Lines: orphans, widows</a> <a href="#ref-for-propdef-widows②">(2)</a> <a href="#ref-for-propdef-widows③">(3)</a> <a href="#ref-for-propdef-widows④">(4)</a> <li><a href="#ref-for-propdef-widows⑤">4.4. Unforced Breaks</a> <li><a href="#ref-for-propdef-widows⑥">4.5. Optimizing Unforced Breaks</a> <a href="#ref-for-propdef-widows⑦">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="monolithic"> <b><a href="#monolithic">#monolithic</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-monolithic">4.1. Possible Break Points</a> <a href="#ref-for-monolithic①">(2)</a> <li><a href="#ref-for-monolithic②">4.4. Unforced Breaks</a> <li><a href="#ref-for-monolithic③">5.1. Breaking into Varying-size Fragmentainers</a> </ul> </aside> <aside class="dfn-panel" data-for="page-break"> <b><a href="#page-break">#page-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-page-break"> Generic Break Values</a> <a href="#ref-for-page-break①">(2)</a> <li><a href="#ref-for-page-break②">4.2. Types of Breaks</a> <a href="#ref-for-page-break③">(2)</a> </ul> </aside> <aside class="dfn-panel" data-for="column-break"> <b><a href="#column-break">#column-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-column-break"> Generic Break Values</a> <a href="#ref-for-column-break①">(2)</a> <a href="#ref-for-column-break②">(3)</a> </ul> </aside> <aside class="dfn-panel" data-for="region-break"> <b><a href="#region-break">#region-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-region-break"> Generic Break Values</a> <li><a href="#ref-for-region-break①">4.2. Types of Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="forced-break"> <b><a href="#forced-break">#forced-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-forced-break">2.1. Parallel Fragmentation Flows</a> <li><a href="#ref-for-forced-break①">4.3. Forced Breaks</a> </ul> </aside> <aside class="dfn-panel" data-for="unforced-break"> <b><a href="#unforced-break">#unforced-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-unforced-break">2.1. Parallel Fragmentation Flows</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-margin-break"> <b><a href="#propdef-margin-break">#propdef-margin-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-margin-break">1. Introduction</a> <li><a href="#ref-for-propdef-margin-break①">5.2. Adjoining Margins at Breaks: the margin-break property</a> <a href="#ref-for-propdef-margin-break②">(2)</a> <a href="#ref-for-propdef-margin-break③">(3)</a> <a href="#ref-for-propdef-margin-break④">(4)</a> <a href="#ref-for-propdef-margin-break⑤">(5)</a> <a href="#ref-for-propdef-margin-break⑥">(6)</a> <li><a href="#ref-for-propdef-margin-break⑦"> Changes Since Level 3</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-margin-break-keep"> <b><a href="#valdef-margin-break-keep">#valdef-margin-break-keep</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-margin-break-keep">5.2. Adjoining Margins at Breaks: the margin-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="propdef-box-decoration-break"> <b><a href="#propdef-box-decoration-break">#propdef-box-decoration-break</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-propdef-box-decoration-break">2. Fragmentation Model and Terminology</a> <li><a href="#ref-for-propdef-box-decoration-break①">5.1. Breaking into Varying-size Fragmentainers</a> <li><a href="#ref-for-propdef-box-decoration-break②">5.3. Splitting Boxes</a> <li><a href="#ref-for-propdef-box-decoration-break③">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> <a href="#ref-for-propdef-box-decoration-break④">(2)</a> <a href="#ref-for-propdef-box-decoration-break⑤">(3)</a> <a href="#ref-for-propdef-box-decoration-break⑥">(4)</a> <li><a href="#ref-for-propdef-box-decoration-break⑦">5.4.1. Joining Boxes for slice</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-box-decoration-break-clone"> <b><a href="#valdef-box-decoration-break-clone">#valdef-box-decoration-break-clone</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-box-decoration-break-clone">4.4. Unforced Breaks</a> <a href="#ref-for-valdef-box-decoration-break-clone">(2)</a> <li><a href="#ref-for-valdef-box-decoration-break-clone">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> </ul> </aside> <aside class="dfn-panel" data-for="valdef-box-decoration-break-slice"> <b><a href="#valdef-box-decoration-break-slice">#valdef-box-decoration-break-slice</a></b><b>Referenced in:</b> <ul> <li><a href="#ref-for-valdef-box-decoration-break-slice">5.4. Fragmented Borders and Backgrounds: the box-decoration-break property</a> <a href="#ref-for-valdef-box-decoration-break-slice①">(2)</a> <li><a href="#ref-for-valdef-box-decoration-break-slice②">5.4.1. Joining Boxes for slice</a> </ul> </aside> <script>/* script-dfn-panel */ document.body.addEventListener("click", function(e) { var queryAll = function(sel) { return [].slice.call(document.querySelectorAll(sel)); } // Find the dfn element or panel, if any, that was clicked on. var el = e.target; var target; var hitALink = false; while(el.parentElement) { if(el.tagName == "A") { // Clicking on a link in a <dfn> shouldn't summon the panel hitALink = true; } if(el.classList.contains("dfn-paneled")) { target = "dfn"; break; } if(el.classList.contains("dfn-panel")) { target = "dfn-panel"; break; } el = el.parentElement; } if(target != "dfn-panel") { // Turn off any currently "on" or "activated" panels. queryAll(".dfn-panel.on, .dfn-panel.activated").forEach(function(el){ el.classList.remove("on"); el.classList.remove("activated"); }); } if(target == "dfn" && !hitALink) { // open the panel var dfnPanel = document.querySelector(".dfn-panel[data-for='" + el.id + "']"); if(dfnPanel) { dfnPanel.classList.add("on"); var rect = el.getBoundingClientRect(); dfnPanel.style.left = window.scrollX + rect.right + 5 + "px"; dfnPanel.style.top = window.scrollY + rect.top + "px"; var panelRect = dfnPanel.getBoundingClientRect(); var panelWidth = panelRect.right - panelRect.left; if(panelRect.right > document.body.scrollWidth && (rect.left - (panelWidth + 5)) > 0) { // Reposition, because the panel is overflowing dfnPanel.style.left = window.scrollX + rect.left - (panelWidth + 5) + "px"; } } else { console.log("Couldn't find .dfn-panel[data-for='" + el.id + "']"); } } else if(target == "dfn-panel") { // Switch it to "activated" state, which pins it. el.classList.add("activated"); el.style.left = null; el.style.top = null; } }); </script> <script>/* script-mdn-anno */ document.body.addEventListener("click", (e) => { if(e.target.closest(".mdn-anno-btn")) { e.target.closest(".mdn-anno").classList.toggle("wrapped"); } }); </script><a class='link-error' href='/date/2022-06-29T01:09:58/bikeshed/css-break-4/' id='generator' title='Bikeshed Link Errors'><svg height='24' viewbox='0 0 100 100' width='24'><g stroke="blue" stroke-width="6" fill="none"><path fill="blue" stroke="none" d="M 5 95 L 5 35 L 50 10 L 50 95"/><path d="M 1 37 L 54 8"/><path fill="blue" stroke="none" d="M 1 40 v -6 l 60 -32 v 6 z" /><circle cx="75" cy="79" r="15" /><circle fill="blue" stroke="none" cx="75" cy="79" r="4" /><path d="M 75 79 L 65 49 L 55 49" /><path d="M 67 55 L 48 69" /></g></svg></a>