BundleTransformer.Core.FileSystem.CssRelativePathResolver resolves data uri's such as url('data:...') to a relative path such as url('/some/path/data:'). Data uri's should be ignored for this processing task.
I'm not sure if it would be possible to modify the following in order to ignore data uri's:
/// <summary>
/// Regular expression for working with paths of components in CSS-code
/// </summary>
private static readonly Regex _urlStylesheetRuleRegex = new Regex(@"url\(((?<quote>'|"")(?<url>[\w \-+.:,;/?&=%~#$@()\[\]{}]+)(\k<quote>)" + @"|(?<url>[\w\-+.:,;/?&=%~#$@\[\]{}]+))\)", RegexOptions.IgnoreCase | RegexOptions.Compiled);
Otherwise it would be possible to just do an index check and ignore urls containg 'data:' at:
public string ResolveComponentsRelativePaths(string content, string path)
Thanks and great job!
I'm not sure if it would be possible to modify the following in order to ignore data uri's:
/// <summary>
/// Regular expression for working with paths of components in CSS-code
/// </summary>
private static readonly Regex _urlStylesheetRuleRegex = new Regex(@"url\(((?<quote>'|"")(?<url>[\w \-+.:,;/?&=%~#$@()\[\]{}]+)(\k<quote>)" + @"|(?<url>[\w\-+.:,;/?&=%~#$@\[\]{}]+))\)", RegexOptions.IgnoreCase | RegexOptions.Compiled);
Otherwise it would be possible to just do an index check and ignore urls containg 'data:' at:
public string ResolveComponentsRelativePaths(string content, string path)
Thanks and great job!