W3C home > Mailing lists > Public > public-respimg@w3.org > September 2012

Re: @type attribute on <source> elements

From: Andy Davies <dajdavies@gmail.com>
Date: Mon, 10 Sep 2012 09:18:48 +0100
Message-ID: <CABbusALobwoi4MLQ_awqU5vmXeJvtofpOgn-UsYvp0qEkDmbhw@mail.gmail.com>
To: "Nathanael D. Jones" <nathanael.jones@gmail.com>
Cc: "public-respimg@w3.org" <public-respimg@w3.org>
On 6 September 2012 22:21, Nathanael D. Jones <nathanael.jones@gmail.com> wrote:
> I'm starting a new thread about the @type attribute, as requested by Adrian
> Roselli.
>
> I believe it is critical that we REQUIRE browsers to SKIP source elements
> which have an unrecognized (or unsupported) mime-type value in the @type
> attribute.
>
> Otherwise, we will not be able to introduce to formats and simplify
> <picture> in the future.
>
> @type should be an OPTIONAL attribute, not required, but if present,
> browsers should handle it in a specific way. Widely supported formats like
> jpeg, png, and gif do not need a type="" attribute, but webp and future
> formats do.
>
> This will allow us to introduce new image formats in a backwards-compatible
> manner.
>

I'm still wondering how relevant type really is...

Yes it make sense when the element has a src but once srcset is used
doesn't it open up a can of worms as the images in a srcset may not
all be the same mimetype, for example, what should the type be for the
following element?

<img src="img.png" srcset="srcset="image.jpg 1x, image-x2.webp, #000" />

I can think of several possibilities but do any of them make sense?

Cheers

Andy
Received on Monday, 10 September 2012 08:19:23 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 10 September 2012 08:19:24 GMT