[whatwg] List Headers

Markus Ernst derernst at gmx.ch
Thu Feb 5 00:18:03 PST 2009


Benjamin Hawkes-Lewis schrieb:
> On 4/2/09 20:39, Garrett Smith wrote:
>>   <ol style="list-style-type: iroha">
>>     <lh>Dry:</lh>
>>       <li>1c flour</li>
>>       <li>1/4c sugar</li>
>>       <li>1tsp baking soda</li>
>>     <lh>Wet:</lh>
>>       <li>1 egg</li>
>>       <li>1/2c milk</li>
>>       <li>1tsp vanilla extract</li>
>>    </ol>
> 
> Hmm.
> 
> Does that markup solve any user problems that following traditional, 
> markup does not?
> 
>    <ol style="list-style-type: iroha">
>      <li class="list-header">Dry:
>        <ol>
>            <li>1c flour</li>
>            <li>1/4c sugar</li>
>            <li>1tsp baking soda</li>
>        </ol>
>      </li>
>      <li class="list-header">Wet:
>        <ol>
>            <li>1 egg</li>
>            <li>1/2c milk</li>
>            <li>1tsp vanilla extract</li>
>        </ol>
>      </li>
>     </ol>

A different use case in the same problem field: Often you have lists 
that are actually part of a paragraph, but cannot be correctly 
associated with the paragraph:

<p>Text before ...</p>
<p>There are lots of fruits available, e.g.:</p>
<ul>
   <li>Apples</li>
   <li>Pears</li>
</ul>
<p>More Text...</p>

More appropriate markup for this could be achieved with the LH suggestion:

<p>Text before ...</p>
<ul>
   <lh>There are lots of fruits available, e.g.:</lh>
   <li>Apples</li>
   <li>Pears</li>
</ul>
<p>More Text...</p>

Anyway I would consider it even more appropriate to allow the list 
inside a paragraph:

<p>Text before ...</p>
<p>There are lots of fruits available, e.g.:
   <ul>
     <li>Apples</li>
     <li>Pears</li>
   </ul>
</p>
<p>More Text...</p>

But I admit I have no idea what other problems this could cause.



More information about the whatwg mailing list