springuser2014 / wro4j

Automatically exported from code.google.com/p/wro4j
0 stars 0 forks source link

CssImportPreProcessor uses a too restrictive PATTERN for finding imports #149

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

The pattern currently in use is too restrictive as it does not support the 
format: @import "xyz.css", which is valid. Typically, jquery.ui for example, 
uses such form :-)

  /** The url pattern */
  private static final Pattern PATTERN = Pattern.compile("@import\\s*url\\(\\s*?" + "[\"']?([^\"']*?)[\"']?"
    // any sequence of characters, except an unescaped ')'
    + "\\s*?\\);?", // Any number of whitespaces, then ')'
    Pattern.CASE_INSENSITIVE); // works with 'URL('

Version used: 1.3.1
See http://www.w3.org/TR/CSS2/cascade.html#at-import

Original issue reported on code.google.com by abde.sa...@gmail.com on 23 Nov 2010 at 6:17

GoogleCodeExporter commented 9 years ago
Thanks for reporting this.

Original comment by alex.obj...@gmail.com on 25 Nov 2010 at 3:59

GoogleCodeExporter commented 9 years ago

Original comment by alex.obj...@gmail.com on 25 Nov 2010 at 3:59

GoogleCodeExporter commented 9 years ago

Original comment by alex.obj...@gmail.com on 25 Nov 2010 at 11:12