[whatwg] Menus, fallback, and backwards compatibility: ideas wanted
Anne van Kesteren
fora at annevankesteren.nl
Sat Dec 3 04:21:39 PST 2005
Quoting Matthew Raymond <mattraymond at earthlink.net>:
> Without fallback, this would be the following:
>
> | <menulabel for="foo">Menu Label</menulabel>
> |
> | <cmd id="foo">
> | <option>Item 1
> | <option>Item 2
> | <option>Item 3
> | </cmd>
Too much markup imho. Especially for the one with fallback.
> As you can see, <menu> uses the |list| attribute from Web Forms 2.0
> to load data from a <datalist>. Since <menulabel> is associated with a
> <menu> element, there's no change in its semantics. With the exception
> of the <button> element, the use of <datalist> is pretty much how it is
> used in WF2.
Even more markup...
> We're running into too many possible sources for adding labels. If
> you include this we have:
>
> * A child <option>.
> * The first <option> in the child <select>.
> * A child text node.
> * A child <label> node.
> * A child <button>.
Not sure what you mean. My suggestion was to take the first Node from the
NodeList when calling getElementsByTagNameNS method with the parameters
"http://www.w3.org/1999/xhtml" and "option" from the <cmd> element and give
that element "semantic meaning". (Which is essentially what is done
today so it
is quite backwards compatible.)
--
Anne van Kesteren
<http://annevankesteren.nl/>
More information about the whatwg
mailing list