diff --git a/images/content-venn.svg b/images/content-venn.svg index 80f41171f0b..e7f40370e6d 100644 --- a/images/content-venn.svg +++ b/images/content-venn.svg @@ -69,7 +69,7 @@
  • keygen
  • label
  • link*
  • -
  • main
  • +
  • main*
  • map
  • mark
  • math
  • diff --git a/source b/source index 11bfdd18b4d..d47094ff5cc 100644 --- a/source +++ b/source @@ -10697,7 +10697,7 @@ console.assert(image.height === 200);
  • kbd
  • label
  • link (if it is allowed in the body)
  • -
  • main
  • +
  • main (if it is a hierarchically correct main element)
  • map
  • mark
  • MathML math
  • @@ -15172,7 +15172,7 @@ interface HTMLBodyElement : HTMLElement {};
    Uses HTMLBodyElement.
    -

    The body element represents the main content of the document.

    +

    The body element represents the contents of the document.

    In conforming documents, there is only one body element. The document.body IDL attribute provides scripts with easy access to @@ -15552,7 +15552,7 @@ interface HTMLBodyElement : HTMLElement {};

    Contexts in which this element can be used:
    Where flow content is expected.
    Content model:
    -
    Flow content, but with no main element descendants.
    +
    Flow content.
    Content attributes:
    Global attributes
    DOM interface:
    @@ -15729,7 +15729,7 @@ interface HTMLBodyElement : HTMLElement {};
    Contexts in which this element can be used:
    Where flow content is expected.
    Content model:
    -
    Flow content, but with no main element descendants.
    +
    Flow content.
    Content attributes:
    Global attributes
    DOM interface:
    @@ -16118,7 +16118,8 @@ Space is not the only void
    Contexts in which this element can be used:
    Where flow content is expected.
    Content model:
    -
    Flow content, but with no header, footer, or main element descendants.
    +
    Flow content, but with no header or footer element + descendants.
    Content attributes:
    Global attributes
    DOM interface:
    @@ -16204,7 +16205,8 @@ Space is not the only void
    Contexts in which this element can be used:
    Where flow content is expected.
    Content model:
    -
    Flow content, but with no header, footer, or main element descendants.
    +
    Flow content, but with no header or footer element + descendants.
    Content attributes:
    Global attributes
    DOM interface:
    @@ -18962,9 +18964,9 @@ first matching case):</p>
    Contexts in which this element can be used:
    Where flow content is expected.
    Content model:
    -
    Either: One figcaption element followed by flow content.
    -
    Or: Flow content followed by one figcaption element.
    -
    Or: Flow content.
    +
    Either: one figcaption element followed by flow content.
    +
    Or: flow content followed by one figcaption element.
    +
    Or: flow content.
    Content attributes:
    Global attributes
    DOM interface:
    @@ -19184,7 +19186,8 @@ included with Exhibit B.
    Flow content.
    Palpable content.
    Contexts in which this element can be used:
    -
    Where flow content is expected.
    +
    Where flow content is expected, but only if it is a hierarchically correct + main element.
    Content model:
    Flow content.
    Content attributes:
    @@ -19193,15 +19196,17 @@ included with Exhibit B.
    Uses HTMLElement.
    -

    The main element can be used as a container for the dominant contents of the - document. It represents its children.

    +

    The main element represents the dominant contents of the + document.

    -

    The main element is distinct from the section and - article elements in that the main element does not contribute to the - document outline.

    +

    A document must not have more than one main element that does not have the hidden attribute specified.

    -

    While there is no restriction as to the number of main elements in a - document, web developers are encouraged to stick to a single element.

    +

    A hierarchically correct main element is one whose ancestor elements + are limited to html, body, div, form without + an accessible name, and autonomous custom elements. Each main element must be a + hierarchically correct main element.

    @@ -19243,6 +19248,35 @@ included with Exhibit B. </footer> </html> +

    In the following example, multiple main elements are used and script is used to + make navigation work without a server roundtrip and to set the hidden attribute on those that are not current: + +

    <!doctype html>
    +<html lang=en-CA>
    +<meta charset=utf-8>
    +<title> … </title>
    +<link rel=stylesheet href=spa.css>
    +<script src=spa.js async></script>
    +<nav>
    + <a href=/>Home</a>
    + <a href=/about>About</a>
    + <a href=/contact>Contact</a>
    +</nav>
    +<main>
    + <h1>Home</h1>
    + …
    +</main>
    +<main hidden>
    + <h1>About</h1>
    + …
    +</main>
    +<main hidden>
    + <h1>Contact</h1>
    + …
    +</main>
    +<footer>Made with ❤️ by <a href=https://example.com/>Example 👻</a>.</footer>
    +
    @@ -19258,7 +19292,7 @@ included with Exhibit B.
    As a child of a dl element.
    Content model:
    If the element is a child of a dl element: one or more dt elements followed by one or more dd elements, optionally intermixed with script-supporting elements.
    -
    If the element is not a child of a dl element: Flow content.
    +
    If the element is not a child of a dl element: flow content.
    Content attributes:
    Global attributes
    DOM interface:
    @@ -116469,10 +116503,10 @@ interface External { main - Container for the dominant contents of another element + Container for the dominant contents of the document flow; palpable - flow + flow* flow globals HTMLElement @@ -117355,7 +117389,6 @@ interface External { ins; kbd; label; - main; map; mark; MathML math; @@ -117398,6 +117431,7 @@ interface External { area (if it is a descendant of a map element); link (if it is allowed in the body); + main (if it is a hierarchically correct main element); meta (if the itemprop attribute is present) @@ -120634,6 +120668,7 @@ INSERT INTERFACES HERE Alfred Agrell, Ali Juma, Alice Boxhall, + Alice Wonder, Allan Clements, Allen Wirfs-Brock, Alex Komoroske,