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

RE: srcN - Alternative to picture and srcset

From: François REMY <francois.remy.dev@outlook.com>
Date: Fri, 27 Sep 2013 18:59:21 +0200
Message-ID: <DUB120-W4184B21DA48A685890D404A5290@phx.gbl>
To: Tab Atkins Jr. <jackalmage@gmail.com>, Shane Hudson <shane@shanehudson.net>
CC: Marcos Caceres <marcos@marcosc.com>, "public-respimg@w3.org" <public-respimg@w3.org>, Robin Berjon <robin@w3.org>
>> Maybe it is an option to separate all of them into one src using for example
>> a ";"
> I'm already using a semicolon and a comma; I think another level of
> separator would get really confusing. ^_^

Except if you choose a separator whose meaning is well-known. Since we're facing a choice, I think we could use the || operator to separate the options.

#    <img srcset="(max-width: 480px) image.mobile.jpg || all image.desktop.jpg" />

We could even allow the use of braces to improve readability. Though I'm not sure it improves readability. That being said, a semi-colon is not a so bad option either, combined with a double-dot:

#    <img srcset="(max-width: 480px): image.mobile.jpg;  all: image.desktop.jpg" />

Not saying this is the way to go, but I don't like the srcN part of the proposal either. It's not really script friendly either because you can't read or update them all at the same time. 		 	   		  
Received on Friday, 27 September 2013 16:59:48 UTC

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