Update tree.js

in windows system,path sep is '\',the old regexp is not match it. I whrite a
new regexp and fix it;
This commit is contained in:
Ethan Lai
2013-03-04 16:51:28 +08:00
committed by Luke Page
parent da7de8f518
commit f9b68f8f74

View File

@@ -24,7 +24,7 @@ tree.debugInfo.asComment = function(ctx) {
tree.debugInfo.asMediaQuery = function(ctx) {
return '@media -sass-debug-info{filename{font-family:' +
('file://' + ctx.debugInfo.fileName).replace(/[\/:.]/g, '\\$&') +
('file://' + ctx.debugInfo.fileName).replace(/([.:/\\])/g, function(a){if(a=='\\') a = '\/'; return '\\' + a}) +
'}line{font-family:\\00003' + ctx.debugInfo.lineNumber + '}}\n';
};