@@ -145,25 +145,25 @@ export class BlockFactory {
145
145
} )
146
146
147
147
// Run through PostCSS.
148
- . then ( async ( preprocessResult ) : Promise < [ ProcessedFile , postcss . Result ] > => {
148
+ . then ( async ( preprocessResult ) : Promise < [ ProcessedFile , postcss . Root ] > => {
149
149
debug ( `Generating PostCSS AST for "${ filename } "` ) ;
150
150
let sourceMap = sourceMapFromProcessedFile ( preprocessResult ) ;
151
151
let content = preprocessResult . content ;
152
152
if ( sourceMap ) {
153
153
content = annotateCssContentWithSourceMap ( content , sourceMap ) ;
154
154
}
155
- let result = await this . postcssImpl ( ) . process ( content , { from : filename } ) ;
156
- return [ preprocessResult , result ] ;
155
+ let root = await this . postcssImpl . parse ( content , { from : filename } ) ;
156
+ return [ preprocessResult , root ] ;
157
157
} )
158
158
159
- . then ( ( [ preprocessedResult , result ] ) => {
159
+ . then ( ( [ preprocessedResult , root ] ) => {
160
160
debug ( `Parsing Block object for "${ filename } "` ) ;
161
161
// Skip parsing if we can.
162
162
if ( this . blocks [ file . identifier ] ) { return this . blocks [ file . identifier ] ; }
163
163
let source : ParsedSource = {
164
164
identifier : file . identifier ,
165
165
defaultName : file . defaultName ,
166
- parseResult : result ,
166
+ parseResult : root ,
167
167
originalSource : file . contents ,
168
168
originalSyntax : file . syntax ,
169
169
dependencies : preprocessedResult . dependencies || [ ] ,
0 commit comments