https://bugzilla.wikimedia.org/show_bug.cgi?id=46933
Krinkle <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|ResourceLoader should |ResourceLoader should |support nesting @media |support using @media in |mediaqueries inside files |files that media set in the | |module --- Comment #1 from Krinkle <[email protected]> --- If you want to avoid having to create a file to use a different @media, simply don't specify 'media' in the module definition and use them both inside the css file: -- module { styles: [ foo.css ] } -- css @media ... { } @media .. { } That works fine. Supporting it inside a module that has 'styles: { "foo.css" => "screen" }' is not possible because: We doesn't use the media attribute on the <link> or <style> element because we concatenate stylesheets (in load.php requests that are only=styles[1]). As a result, the @media in your css file is a second level @media. Though we don't strip that out, it would fail in any browser that doesn't support css3-mediaqueries. However, as said, it isn't not-supported so if css3-only is acceptable, you can do so already. The only way around it is to strip those sections out and wrap the individual subsections outside the user @media, and then modify the rules of the user @media. That'd get quite hacky, but its possible. Is it worth that? [1] we also concatenate them in <style> for IE, but that's another story which could be avoided if we hack something in js. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
