A user account is required in order to edit this wiki, but we've had to disable public user registrations due to spam.

To request an account, ask an autoconfirmed user on Chat (such as one of these permanent autoconfirmed members).

Summary element: Difference between revisions

From WHATWG Wiki
Jump to navigation Jump to search
(note and link to Dion Almaer support)
(<tldr>)
 
(3 intermediate revisions by 3 users not shown)
Line 19: Line 19:
# '''Rename the details <code>&lt;summary&gt;</code>''' to something more specific (suggestions welcome), <em>OR</em>:
# '''Rename the details <code>&lt;summary&gt;</code>''' to something more specific (suggestions welcome), <em>OR</em>:
# '''Alternatively make the <code>&lt;summary&gt;</code> element generic.''' Make it an actual summary inside <code>&lt;article&gt;</code> or <code>&lt;body&gt;</code>, as well as inside <code>&lt;details&gt;</code>. Allow <code>&lt;summary&gt;</code> anywhere <code>&lt;header&gt;</code> is allowed (basically, make it a part of the new section related elements).
# '''Alternatively make the <code>&lt;summary&gt;</code> element generic.''' Make it an actual summary inside <code>&lt;article&gt;</code> or <code>&lt;body&gt;</code>, as well as inside <code>&lt;details&gt;</code>. Allow <code>&lt;summary&gt;</code> anywhere <code>&lt;header&gt;</code> is allowed (basically, make it a part of the new section related elements).
# '''Add a generic summary element''', <code>&lt;abstract&gt;</code> for instance.


I prefer the second solution, make the <code>&lt;summary&gt;</code> element more generic/flexible. — [[User:Tantek|Tantek]] 20:38, 3 August 2010 (UTC)
I prefer the second solution, make the <code>&lt;summary&gt;</code> element more generic/flexible. — [[User:Tantek|Tantek]] 20:38, 3 August 2010 (UTC)
Line 34: Line 35:
</div>
</div>
* +1 [http://twitter.com/dalmaer/status/20318049663 Dion Almaer:] <nowiki><figcaption></nowiki> or just reuse <nowiki><summary></nowiki> in more places. I am with @t on that one :)
* +1 [http://twitter.com/dalmaer/status/20318049663 Dion Almaer:] <nowiki><figcaption></nowiki> or just reuse <nowiki><summary></nowiki> in more places. I am with @t on that one :)
* -0 [[User:EdwardOConnor|EdwardOConnor]] - I'm OK with the status quo; barring that, I'd prefer renaming <nowiki><summary></nowiki> to more specifically describe its use in <nowiki><details></nowiki>.
* +0 [[User:Crissov|Päper]] – I like general purpose, context-aware elements, but maybe the alleged confusion is better solved by a dedicated, intuitively named element: I added a third, <code>&lt;abstract></code>, option above – <code>&lt;tldr&gt;</code> would also be a popular name for it
* ...
* ...
[[Category:Proposals]]

Latest revision as of 11:00, 22 October 2014

This article is a stub. You can help the whatwg.org wiki by expanding it.

The <summary> element is a new element in HTML5, a child of the new <details> element.

For the summary attribute, see Table Summary.

summary naming or flexibility

Currently the <summary> element is a special element specifically for use for the label inside the <details> element.

The name of the <summary> element however is too generic sounding of an element name for this special usage.

It is inevitable that people will begin using the <summary> element when they simply mean a semantic "summary", perhaps of a <section> or <article>.

I say inevitable due to the broad evidence presented by the known existing problem with the <address> element (special use - for contact information for the document, but used and often errantly taught as a generic "address" for street addresses).

Thus we should either:

  1. Rename the details <summary> to something more specific (suggestions welcome), OR:
  2. Alternatively make the <summary> element generic. Make it an actual summary inside <article> or <body>, as well as inside <details>. Allow <summary> anywhere <header> is allowed (basically, make it a part of the new section related elements).
  3. Add a generic summary element, <abstract> for instance.

I prefer the second solution, make the <summary> element more generic/flexible. — Tantek 20:38, 3 August 2010 (UTC)

summary flexibility advantages

Advantages of making the <summary> element more generic and flexible:

  • This is close to the semantic of the Atom "summary" element, and the hAtom microformat 'entry-summary' property.
  • This would allow an enhancement of the algorithm for converting HTML5 to Atom: take the first HTML5 <summary> inside an <article> being converted to an entry, and use that HTML5 <summary> as the Atom entry <summary>.


Opinions / discussion:

  • +1 Tantek - I think web authors would make good use of a new generic <summary> element.
  • Bruce Lawson: I don't think there's a need for a generic summary element. But I'd support renaming the summary attribute of details (because it doesn't really summarise). Perhaps "rubric" could replace details>summary and figure>figcaption ?
  • +1 Dion Almaer: <figcaption> or just reuse <summary> in more places. I am with @t on that one :)
  • -0 EdwardOConnor - I'm OK with the status quo; barring that, I'd prefer renaming <summary> to more specifically describe its use in <details>.
  • +0 Päper – I like general purpose, context-aware elements, but maybe the alleged confusion is better solved by a dedicated, intuitively named element: I added a third, <abstract>, option above – <tldr> would also be a popular name for it
  • ...