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

Re: New responsive images proposal

From: Brendan Long <self@brendanlong.com>
Date: Fri, 27 Sep 2013 13:42:41 -0600
Message-ID: <5245DFB1.9040701@brendanlong.com>
To: Robin Berjon <robin@w3.org>
CC: "HTML WG (public-html@w3.org)" <public-html@w3.org>
Sorry if this is a stupid question, but the use of media queries in the
src attribute brings up an interesting question: Why don't we just let
the src attribute be specified by CSS?

<img alt="A cat" src="default-cat.jpeg" class="cat" />

img.cat {
    @media (max-width: 600px) {
        src: "smaller-cat.jpeg";
    }
    @media (max-width: 400px) {
        src: "even-smaller-cat.jpeg";
    }
}

On 09/27/2013 03:31 AM, Robin Berjon wrote:
> Hi,
>
> Tab published this:
>
>     http://tabatkins.github.io/specs/respimg/Overview.html
>
> As a responsive images proposal, it certainly has a number of
> interesting properties. It address the use cases well while catering
> to fallback and without excessively crazy syntax.
>



Received on Friday, 27 September 2013 19:43:12 UTC

This archive was generated by hypermail 2.4.0 : Saturday, 9 October 2021 18:46:05 UTC