@@ -78,29 +78,29 @@ var parserPlugin = postcss.plugin("css-loader-parser", function(options) {
78
78
} ) ;
79
79
80
80
function processNode ( item , isValue ) {
81
- switch ( item . type ) {
81
+ switch ( item . type ) {
82
82
case "value" :
83
- item . nodes . forEach ( function ( node ) {
83
+ item . nodes . forEach ( function ( node ) {
84
84
processNode ( node , true ) ;
85
85
} ) ;
86
- break ;
87
- case "nested-item" :
88
- item . nodes . forEach ( function ( node ) {
86
+ break ;
87
+ case "nested-item" :
88
+ item . nodes . forEach ( function ( node ) {
89
89
processNode ( node ) ;
90
90
} ) ;
91
- break ;
92
- case "item" :
93
- var importIndex = imports [ "$" + item . name ] ;
94
- if ( typeof importIndex === "number" ) {
95
- item . name = "___CSS_LOADER_IMPORT___" + importIndex + "___" ;
96
- }
97
- break ;
98
- case "url" :
99
- if ( ! / ^ # / . test ( item . url ) && loaderUtils . isUrlRequest ( item . url , options . root ) ) {
100
- item . stringType = "" ;
101
- delete item . innerSpacingBefore ;
102
- delete item . innerSpacingAfter ;
103
- var url ;
91
+ break ;
92
+ case "item" :
93
+ var importIndex = imports [ "$" + item . name ] ;
94
+ if ( typeof importIndex === "number" ) {
95
+ item . name = "___CSS_LOADER_IMPORT___" + importIndex + "___" ;
96
+ }
97
+ break ;
98
+ case "url" :
99
+ if ( ! / ^ # / . test ( item . url ) && loaderUtils . isUrlRequest ( item . url , options . root ) ) {
100
+ item . stringType = "" ;
101
+ delete item . innerSpacingBefore ;
102
+ delete item . innerSpacingAfter ;
103
+ var url ;
104
104
105
105
if ( isValue ) {
106
106
if ( loaderUtils . isUrlRequest ( url , options . root ) && options . mode === "global" ) {
@@ -112,14 +112,14 @@ var parserPlugin = postcss.plugin("css-loader-parser", function(options) {
112
112
url = item . url ;
113
113
}
114
114
115
- item . url = "___CSS_LOADER_URL___" + urlItems . length + "___" ;
116
- urlItems . push ( {
117
- url : url
118
- } ) ;
119
- }
120
- break ;
121
- }
122
- }
115
+ item . url = "___CSS_LOADER_URL___" + urlItems . length + "___" ;
116
+ urlItems . push ( {
117
+ url : url
118
+ } ) ;
119
+ }
120
+ break ;
121
+ }
122
+ }
123
123
124
124
css . walkDecls ( function ( decl ) {
125
125
var values = Tokenizer . parseValues ( decl . value ) ;
0 commit comments