W3C home > Mailing lists > Public > www-style@w3.org > June 2013

Re: media query definitions

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Fri, 21 Jun 2013 14:00:35 -0700
Message-ID: <CAAWBYDBYB1983p8yYn5k3vbkcQu3GVa89_-wnYAo3L4pQfxM1Q@mail.gmail.com>
To: Behrang Saeedzadeh <behrangsa@gmail.com>
Cc: W3C CSS Mailing List <www-style@w3.org>
On Fri, Jun 21, 2013 at 7:58 AM, Behrang Saeedzadeh <behrangsa@gmail.com> wrote:
> It would be nice, if there was a way to define a media query, and use it in
> multiple @media blocks:
>
> @media-def #my-media only screen and (max-width: 480px), only screen and
> (max-device-width: 480px), etc.;
>
> @media(#my-media) {
>  /* css rules */
> }
>
> The syntax can of course be totally different.
>
> This would eliminate some duplication where there are multiple media query
> blocks in various CSS files that target the same device, etc.
>
> What do you guys think?

Yup, this was very recently discussed favorably.  We want to add some
way to make an author-extensible Media Query.

~TJ
Received on Friday, 21 June 2013 21:01:23 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:12 UTC