Re: hgroup: a possible alternative

2011/1/20 Lars Gunther <gunther@keryx.se>

> 2011-01-13 13:43, Benoit Piette skrev:
>
>  What about this :
>>
>> <section>
>> <hgroup>
>> <h1>Search</h1>
>> <h2>By City</h2>
>> </hgroup>
>>    ... instructions and search form...
>> </section>
>>
>> <section>
>> <hgroup>
>> <h1>Search</h1>
>> <h2>By Zip Code</h2>
>> </hgroup>
>>     ... instructions and search form...
>> </section>
>>
>>
> Totally confusing. This repetition idea is completely different from the
> current proposal and any alternative proposal. The outline would look like
> this:
>
> - Search
> - Search
> - Search
>
> i.e. You have hidden the part that is actually telling users what's unique
> about each point.
>
>
>
That was my point. It is an error (or is it really ?) that can be made and
that has an impact on accessibility.  To make that kind of errors not
validate (and more easy to spot), you have to allow only one hx per hgroup.
Though it is weird to call something hgroup when only one hx is allowed...
In the current situation, if you put a second hx in hgroup, that hx is no
longer an hx. If you really want to put a second hx that should be in the
outline, then hgroup is not the solution. Something like this is the correct
markup if you want to style Search and By City in a box, but with a
different font :

<section>
  <h1>Search <span>By City</span></h1>
 ....
</section>

Looks like the use case for hgroup, but isn't.... Changing the semantics of
an element depending on it's position is confusing.

-Benoit Piette

Received on Friday, 21 January 2011 12:33:21 UTC