[whatwg] Thoughts on HTML 5

html at nczonline.net html at nczonline.net
Thu Feb 28 13:32:00 PST 2008


Yes, I believe the <dialog/> element is supposed to be a disambiguation of the <dl/> element, which has previously been used for both conversations and definition lists. It makes sense to have separate ones since there's no way to tell what a <dl/> represents now. That being said, I still feel the tag name "dialog" is too confusing to use. Perhaps the "role" attribute would be appropriate to use on <dl/>, such as <dl role="conversation"/>?

As for my suggestion of "reldata", my intent is to use the attribute for any type of data related to the element. The "role" attribute is intended to be used (from my understanding) to designate what role the element is playing on the page. This is not an appropriate place to put extra data that isn't necessary for the rendering or understanding of the element. My thought is doing something like this:

<div id="whatever" reldata="{clicks:1,track:true}">

The data format could be whatever someone wants, plain text, structured text, JSON...whatever you need. The point is to have a common place to dump extra but related data that isn't important to the understanding of the element. I often use custom attributes for this now, but it would be nice to have an official attribute for this purpose.

-Nicholas





>html at nczonline.net wrote (with snippage):
>>     *   I understand the concept of the <dialog/> element but it's named 
>completely wrong. The point is to markup a conversation between two or more 
>parties. The problem is that the word "dialog", when in used in user 
>interfaces, refers to small windows that can be interacted with. When I first 
>read about this element, I assumed it was a way to indicate that part of the 
>page is a dialog window outside of the normal flow of the document (which I 
>thought was cool). After reading the rest, I was disappointed to find out that 
>wasn't the intent. I'd rename this element as <conversation/> or <discussion/> 
>to avoid such misunderstandings.
>
>I was confused by the name of the "dialog" element in exactly the same 
>way you were, originally thinking it was to do with pop-up dialogue 
>boxes.  The HTML 4 spec states:
>
>     Another application of DL, for example, is for marking up
>     dialogues, with each DT naming a speaker, and each DD containing
>     his or her words.
>
>... which I presume influenced the addition of this element.  If there 
>is a lot of dialogue marked up on the Web it deserves its own element, 
>if not I guess DL could be considered to stand for "dialogue list" in 
>addition to "definition list".
>
>>     *   I'd like to see a common attribute that can be used on any element 
>to indicate information related to the element. I'm tired of fighting the 
>custom attribute battle. The fact is that it's a very common need to include 
>extra data related to an element. I'd propose a "reldata" attribute (short for 
>"related data") be considered as an optional attribute on all elements. We 
>then, as developers, could use that attribute as we see fit and the document 
>would still validate (for people who care about such things).
>
>I'm not entirely sure I understand, but if you want to further define 
>the semantics of an element or make it more "specialised", another group 
>  has put forward the idea of a "role" attribute 
><http://www.w3.org/TR/2007/WD-xhtml-role-20071004/>.
>
>Regards,
>
>Dave



More information about the whatwg mailing list