W3C home > Mailing lists > Public > public-respimg@w3.org > November 2013

Re: srcN - Alternative to picture and srcset

From: Anselm Hannemann <info@anselm-hannemann.com>
Date: Sun, 3 Nov 2013 21:03:09 +0100
Cc: Yoav Weiss <yoav@yoav.ws>, Attiks <attiks@gmail.com>, Mathew Marquis <mat@matmarquis.com>, François REMY <francois.remy.dev@outlook.com>, "Tab Atkins Jr." <jackalmage@gmail.com>, "Podjarny, Guy" <gpodjarn@akamai.com>, Aaron Gustafson <aaron@easy-designs.net>, Marcos Caceres <marcos@marcosc.com>, Robin Berjon <robin@w3.org>, Shane Hudson <shane@shanehudson.net>, "public-respimg@w3.org" <public-respimg@w3.org>
Message-Id: <A446ECCA-B9FC-4104-9A59-9B594C8CE734@anselm-hannemann.com>
To: David Newton <david@davidnewton.ca>
On 03.11.2013, at 20:54, David Newton <david@davidnewton.ca> wrote:

> That assumes JS is available, which may not be true. The solution should ideally work without JS, since src-n will work without JS.

I agree here. Either we should encourage to remove maps completely from img element or find a proper solution working without JS.


> What about just letting usemap take a list of IDs in the same order as src-n?
> 
> <img usemap=“#map1, #map” src-1=“(max-width: 400px) img1.png” src-2=“(max-width: 1000px) img2.png” alt=“whatever” />

This is not possible for the very same reason we couldn’t extend the src-attribute. We would need to create a new attribute usemap-n="".
I find this an ugly solution. Still, not supporting usemaps attribute when a src-n attribute exists is also ugly.

Can someone find out if it would be possible to drop this attribute at all? There are enough better solutions like working with SVG for such maps.
I also think we should ensure every img attribute is somehow supported by src-N. Otherwise it’s not a good webstandard-solution. Partial support doesn’t sound bullet-proof which a webstandard spec should be IMO.

-Anselm
> 
> 
> On Nov 3, 2013, at 2:28 PM, Yoav Weiss <yoav@yoav.ws> wrote:
> 
>> For everything other than art direction, you can set the area in percentages, so it should work.
>> 
>> For art direction, we could say that usemap always applies to the current source, and for the rare case of an art directed image map, use JS to adapt the map to the source.
>> 
>> On Nov 3, 2013 8:19 PM, "Attiks" <attiks@gmail.com> wrote:
>> It isn't only a problem in the art direction case, in the other cases the dimensions are changing as well, so the map has to be resized accordingly. You're right that it isn't a problem for the "retina" (DPR) use cases.
>> 
>> 
>> On Sun, Nov 3, 2013 at 8:03 PM, Aaron Gustafson <aaron@easy-designs.net> wrote:
>> On Sun, Nov 3, 2013 at 1:48 PM, Podjarny, Guy <gpodjarn@akamai.com> wrote:
>> I didn't think this through fully yet, but isn't this only a problem if we change the contents of the picture (e.g. Art direction) as opposed to reducing quality or pixel density?
>> 
>> 
>> Correct. It’s only an issue if you have multiple layouts.
>> 
>> 
>> If so, we could just declare that srcN doesn't support multiple usemap options, meaning you can only (successfully) use it if you're limiting your use of srcN to viewport and DPR switching.
>> Makes sense?
>> 
>> 
>> Completely. I would be in favor of this restriction as the alternative makes me cringe.
>> 
>> Cheers,
>> 
>> Aaron
>> 
>> ----
>> Aaron Gustafson
>> Founder & Technical Lead
>> Easy Designs, LLC
>> @aarongustafson
>> 
> 


Received on Sunday, 3 November 2013 20:03:34 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:06:10 UTC