[whatwg] Conformance checking of missing alternative content for images
bhawkeslewis at googlemail.com
Sun Aug 26 06:46:56 PDT 2012
On Wed, Aug 22, 2012 at 1:43 AM, Ian Hickson <ian at hixie.ch> wrote:
> On Sat, 4 Aug 2012, Benjamin Hawkes-Lewis wrote:
>> Would it be possible to combine this with the linter complaining about
>> all controls (links, buttons, form fields) have markup that yield a
>> non-empty "accessible name" without invoking repair techniques such as
>> reading filenames without img @src attributes?
>> I realise the author requirements in the HTML spec seem to have
>> gradually become very forgiving here, not really sure why.
> I'm not sure I understand the suggestion here. Can you elaborate?
See also our old discussion at:
>> It would help catch the not uncommon antipattern where the "content" of
>> a link or button is provided only by a background image.
>> <a href="somewhere"></a>
>> <a href="somewhere-else"></a>
>> <button class="delete"></button>
> This is should-level non-conforming and has no reason to be conforming, as
> far as I can tell ("elements whose content model allows any flow content
> or phrasing content SHOULD have at least one child node that is palpable
> content and that does not have the hidden attribute specified").
> The only reason it's not entirely non-conforming ("must" rather than
> "should") is that there are some edge cases where it makes sense, e.g.
> when you have an empty paragraph that you're going to fill in later.
> But maybe we should tighten this up again, e.g. for interactive content?
I cannot imagine a good reason to include an unnamed control, so yes.
Note that this would need to take into account that fields might be
labelled by a <label> or a table header cell.
More information about the whatwg