From 2ebe9d992e4d52eb4b98ef270c5a31f6726ea0e9 Mon Sep 17 00:00:00 2001 From: Domenic Denicola Date: Mon, 4 Apr 2016 16:07:52 -0400 Subject: [PATCH] Add element definition and content categories for custom tags Fixes #454. --- assets/styles/respec-complement.css | 6 +++++ spec/custom/index.html | 42 +++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) diff --git a/assets/styles/respec-complement.css b/assets/styles/respec-complement.css index 5bc00001..35df57c0 100644 --- a/assets/styles/respec-complement.css +++ b/assets/styles/respec-complement.css @@ -88,3 +88,9 @@ body.dfnEnabled dfn { cursor: pointer; } padding-top: 0; padding-bottom: 0; } + +/* + * From https://resources.whatwg.org/standard.css + */ +.element { background: #EEFFEE; color: black; margin: 0 0 1em -0.15em; padding: 0 1em 0.25em 1em; } +.element:not(:hover) > dt > :link, .element:not(:hover) > dt > :visited { color: inherit; text-decoration: none; } diff --git a/spec/custom/index.html b/spec/custom/index.html index e5161620..363d0e6c 100644 --- a/spec/custom/index.html +++ b/spec/custom/index.html @@ -421,6 +421,32 @@

Core concepts

After a custom element is created, changing the value of the is attribute does not change the element's behavior.

+

Custom tags have the following element definition:

+ + +
+
Categories:
+
Flow content.
+
Phrasing content.
+
Palpable content.
+ +
Contexts in which custom elements can be used:
+
Where phrasing content is expected.
+ +
Content model:
+
Transparent.
+ +
Tag omission in text/html:
+
Neither tag is omissible.
+ +
Content attributes:
+
Global attributes +
Any attributes relevant to the element's functioning, as defined by the author
+ +
DOM interface:
+
Supplied by the author (inherits from HTMLElement).
+
+

A custom tag does not have any special meaning: it represents its children. A type extension inherits the semantics of the element that it extends.

A valid custom element name is a sequence of characters name that meets all of the following requirements:

@@ -947,6 +973,22 @@

HTML+: Parsing XHTML documents

+
+

HTML+: Content Model Updates

+ +

HTML has several sections that need to be updated when introducing a new element, or in this case class of elements. Those are:

+ + + +
+

DOM+: Elements