@umijs/bundler-webpack 4.6.51 → 4.6.52

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { ProcessOptions } from './postcss'
1
+ import { CssSyntaxError, ProcessOptions } from './postcss'
2
2
  import PreviousMap from './previous-map'
3
3
 
4
4
  export interface FilePosition {
@@ -147,4 +147,39 @@ export default class Input {
147
147
  * @param offset Source offset.
148
148
  */
149
149
  fromOffset(offset: number): { line: number; col: number } | null
150
+
151
+ /**
152
+ * Returns `CssSyntaxError` with information about the error and its position.
153
+ */
154
+ error(
155
+ message: string,
156
+ line: number,
157
+ column: number,
158
+ opts?: { plugin?: CssSyntaxError['plugin'] }
159
+ ): CssSyntaxError
160
+ error(
161
+ message: string,
162
+ offset: number,
163
+ opts?: { plugin?: CssSyntaxError['plugin'] }
164
+ ): CssSyntaxError
165
+ error(
166
+ message: string,
167
+ start:
168
+ | {
169
+ offset: number
170
+ }
171
+ | {
172
+ line: number
173
+ column: number
174
+ },
175
+ end:
176
+ | {
177
+ offset: number
178
+ }
179
+ | {
180
+ line: number
181
+ column: number
182
+ },
183
+ opts?: { plugin?: CssSyntaxError['plugin'] }
184
+ ): CssSyntaxError
150
185
  }