WebAIM - Web Accessibility In Mind

E-mail List Archives

Thread: Tables with irregular headers

for

Number of posts in this thread: 7 (In chronological order)

From: Vaibhav Saraf
Date: Thu, Apr 15 2021 11:38AM
Subject: Tables with irregular headers
No previous message | Next message →

Hi Group,

I was referring Example 1 for irregular headers on below tutorial:
https://www.w3.org/WAI/tutorials/tables/irregular/

In the first row, I can hear "Mars Produced" and "Venus Produced"
respectively instead of just "Mars" and "Venus" (I used NVDA and JAWS 2020).

The "Produced" thing is coming from the header in the following row.
Similar thing is there in Example 2 as well.

I am looking for a way to get rid of the second header's announcement and
looking to scope the header to a specific number of rows or columns. As
this thing is supposed to be done for a large number of tables I am
reluctant in using 'header' attribute and want to get it done in a more
generic way.

Is there any better example which gets rid of the second header
announcement wherever it is not needed?

Thanks,
Vaibhav

From: glen walker
Date: Thu, Apr 15 2021 11:59AM
Subject: Re: Tables with irregular headers
← Previous message | Next message →

It's working exactly correct. Both "Mars" and "Produced" are headers for
the column so I would expect to hear both.

I'm not sure I follow your example where you'd want "Produced" (or whatever
column header for your scenario) only announced some of the time.
Visually, that would be a very funky table where a column header only
applied to certain rows. Would you indicate that association visually
somehow?

From: Vaibhav Saraf
Date: Thu, Apr 15 2021 12:12PM
Subject: Re: Tables with irregular headers
← Previous message | Next message →

Hi Glen,

For row 1, Mars is the main heading and Produced and Sold are sub-sections
of it (which are in row 2). When I am in row 1 I would prefer to hear
'Mars' only and not 'Mars Produced'.

For the data cells it's fine.

I actually want to build a table which has sub-rows in them. Take an
instance I have FSA and corresponding geographic unit's name.

So my two column headers would be: 'FSA' and 'geographic unit'. I can have
further sub-rows dividing the table alphabetically. In such a case I am
getting the headers + sub-row headers getting announced everywhere in the
table.

Cannot find a very close example to it, but this W3's example is somewhat
closer.

Thanks,
Vaibhav




On Thu, 15 Apr 2021 at 23:29, glen walker < = EMAIL ADDRESS REMOVED = > wrote:

> It's working exactly correct. Both "Mars" and "Produced" are headers for
> the column so I would expect to hear both.
>
> I'm not sure I follow your example where you'd want "Produced" (or whatever
> column header for your scenario) only announced some of the time.
> Visually, that would be a very funky table where a column header only
> applied to certain rows. Would you indicate that association visually
> somehow?
> > > > >

From: glen walker
Date: Thu, Apr 15 2021 12:26PM
Subject: Re: Tables with irregular headers
← Previous message | Next message →

When navigating across row 1, I can sort of see your point.

With NVDA, it only says "Mars" and then "Venus", so it's only announcing
just that header.
With JAWS, it says "Produced Mars" and "Produced Venus"

I can (sort of) understand why JAWS is doing that. "Mars" is a cell in the
table (a header cell but a cell nonetheless) so JAWS is trying to announce
any headers that go with that (header) cell, which is "Produced". Sort
of.

Both "Produced" and "Sold" are header cells so why did JAWS only decide to
announce "Produced" when navigating to the "Mars" cell and not "Sold"? I
can't answer that. Perhaps it's a JAWS-ism.

But I think that might be beside the point. In your real world case, are
you trying to control what the screen reader says when you navigate the
header cells? I'm not sure you should do that. You said "I would prefer
to hear..." but are you a typical screen reader user? You have to be
careful when you start thinking about how *you* would want things announced
as opposed to what your *users* expect to be announced.

From: Jonathan Avila
Date: Thu, Apr 15 2021 12:50PM
Subject: Re: Tables with irregular headers
← Previous message | Next message →

From recollection JAWS announces changes in header cells that span multiple columns but won't repeat something that is spanned if it has not changed - perhaps that is the reason.

Jonathan

From: Vaibhav Saraf
Date: Thu, Apr 15 2021 1:08PM
Subject: Re: Tables with irregular headers
← Previous message | Next message →

Hi Glen,

For me I am able to hear 'Mars Produced' for NVDA as well. Certainly it is
because of browser/NVDA versions, I would be interesting in knowing yours.

Yes, I am a native screen reader user. Not trying to control what the
screen reader should speak for a particular row.

I am more trying to make a header work only for a given set of rows instead
of all. for the FSA example I shared if the sub-row headers are going to be
announced this way then surely one would hear all A-Z alphabets before
actually hearing the cell content.

Forgive me if I am confusing you but it's a little hard to put the whole
thing in words.

Thanks,
Vaibhav





On Fri, 16 Apr 2021 at 00:20, Jonathan Avila < = EMAIL ADDRESS REMOVED = >
wrote:

> From recollection JAWS announces changes in header cells that span
> multiple columns but won't repeat something that is spanned if it has not
> changed - perhaps that is the reason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