Skip to content

Commit

Permalink
Fixed media query regex to anticipate optional whitespace between med…
Browse files Browse the repository at this point in the history
…ia keyword and query (Fixes katiefenn#19)
  • Loading branch information
Katie Fenn committed Jun 8, 2014
1 parent 9b7db45 commit 18bead7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/CssMediaQuery.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ function CssMediaQuery(raw) {
}

CssMediaQuery.prototype.getQueries = function () {
var pattern = /@media (.+?)\s?{/,
var pattern = /@media\w*(.+?)\s?{/,
queries = pattern.exec(this.raw)[1];

return queries.split(/ or |,/g).map(trimQuery);
Expand Down

0 comments on commit 18bead7

Please sign in to comment.