@rsbuild/core 1.0.0-alpha.2 → 1.0.0-alpha.3
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.
- package/compiled/autoprefixer/index.d.ts +95 -0
- package/compiled/autoprefixer/index.js +10217 -0
- package/compiled/autoprefixer/license +20 -0
- package/compiled/autoprefixer/package.json +1 -0
- package/compiled/browserslist/index.d.ts +201 -0
- package/compiled/browserslist/index.js +2017 -0
- package/compiled/browserslist/license +20 -0
- package/compiled/browserslist/package.json +1 -0
- package/compiled/chokidar/index.d.ts +198 -0
- package/compiled/chokidar/index.js +6692 -0
- package/compiled/chokidar/license +21 -0
- package/compiled/chokidar/package.json +1 -0
- package/compiled/gzip-size/index.d.ts +1 -0
- package/compiled/gzip-size/index.js +242 -0
- package/compiled/gzip-size/package.json +1 -0
- package/compiled/http-proxy-middleware/index.d.ts +315 -0
- package/compiled/http-proxy-middleware/index.js +7503 -0
- package/compiled/http-proxy-middleware/license +22 -0
- package/compiled/http-proxy-middleware/package.json +1 -0
- package/compiled/launch-editor-middleware/index.js +9 -9
- package/compiled/rspack-chain/index.d.ts +600 -0
- package/compiled/rspack-chain/index.js +2192 -0
- package/compiled/rspack-chain/license +373 -0
- package/compiled/rspack-chain/package.json +1 -0
- package/compiled/webpack-bundle-analyzer/index.d.ts +160 -0
- package/compiled/webpack-bundle-analyzer/index.js +14968 -0
- package/compiled/webpack-bundle-analyzer/license +20 -0
- package/compiled/webpack-bundle-analyzer/package.json +1 -0
- package/compiled/webpack-bundle-analyzer/public/viewer.js +16 -0
- package/compiled/webpack-bundle-analyzer/public/viewer.js.LICENSE.txt +10 -0
- package/compiled/webpack-merge/index.d.ts +31 -0
- package/compiled/webpack-merge/index.js +1239 -0
- package/compiled/webpack-merge/license +20 -0
- package/compiled/webpack-merge/package.json +1 -0
- package/dist/index.cjs +882 -2519
- package/dist/index.js +966 -2647
- package/dist-types/cli/commands.d.ts +1 -1
- package/dist-types/config.d.ts +1 -1
- package/dist-types/configChain.d.ts +158 -2
- package/dist-types/constants.d.ts +1 -0
- package/dist-types/createContext.d.ts +1 -2
- package/dist-types/helpers.d.ts +7 -4
- package/dist-types/index.d.ts +2 -2
- package/dist-types/initHooks.d.ts +1 -1
- package/dist-types/initPlugins.d.ts +1 -2
- package/dist-types/internal.d.ts +1 -1
- package/dist-types/loader/transformLoader.d.ts +1 -1
- package/dist-types/mergeConfig.d.ts +1 -1
- package/dist-types/pluginManager.d.ts +1 -1
- package/dist-types/plugins/css.d.ts +1 -2
- package/dist-types/plugins/html.d.ts +1 -2
- package/dist-types/plugins/minimize.d.ts +1 -2
- package/dist-types/provider/build.d.ts +1 -1
- package/dist-types/provider/createCompiler.d.ts +1 -2
- package/dist-types/provider/initConfigs.d.ts +1 -2
- package/dist-types/provider/inspectConfig.d.ts +1 -1
- package/dist-types/provider/rspackConfig.d.ts +2 -2
- package/dist-types/rspack/HtmlBasicPlugin.d.ts +1 -1
- package/dist-types/rspack/InlineChunkHtmlPlugin.d.ts +1 -1
- package/dist-types/rspack/preload/HtmlPreloadOrPrefetchPlugin.d.ts +1 -1
- package/dist-types/rspack/preload/helpers/doesChunkBelongToHtml.d.ts +1 -1
- package/dist-types/rspack/preload/helpers/extractChunks.d.ts +1 -1
- package/dist-types/server/compilerDevMiddleware.d.ts +1 -1
- package/dist-types/server/devMiddleware.d.ts +4 -1
- package/dist-types/server/devServer.d.ts +1 -2
- package/dist-types/server/environment.d.ts +1 -1
- package/dist-types/server/getDevMiddlewares.d.ts +1 -1
- package/dist-types/server/helper.d.ts +1 -2
- package/dist-types/server/httpServer.d.ts +1 -1
- package/dist-types/server/middlewares.d.ts +1 -1
- package/dist-types/server/prodServer.d.ts +1 -2
- package/dist-types/server/proxy.d.ts +3 -3
- package/dist-types/server/socketServer.d.ts +1 -1
- package/dist-types/server/watchFiles.d.ts +1 -1
- package/dist-types/types/config/dev.d.ts +85 -0
- package/dist-types/types/config/html.d.ts +107 -0
- package/dist-types/types/config/index.d.ts +134 -0
- package/dist-types/types/config/output.d.ts +301 -0
- package/dist-types/types/config/performance.d.ts +122 -0
- package/dist-types/types/config/security.d.ts +18 -0
- package/dist-types/types/config/server.d.ts +106 -0
- package/dist-types/types/config/source.d.ts +79 -0
- package/dist-types/types/config/tools.d.ts +86 -0
- package/dist-types/types/context.d.ts +38 -0
- package/dist-types/types/hooks.d.ts +125 -0
- package/dist-types/types/index.d.ts +9 -0
- package/dist-types/types/plugin.d.ts +194 -0
- package/dist-types/{types.d.ts → types/rsbuild.d.ts} +56 -33
- package/dist-types/types/rspack.d.ts +28 -0
- package/dist-types/types/stats.d.ts +17 -0
- package/dist-types/types/thirdParty.d.ts +169 -0
- package/dist-types/types/utils.d.ts +14 -0
- package/package.json +18 -3
|
@@ -0,0 +1,1239 @@
|
|
|
1
|
+
/******/ (() => { // webpackBootstrap
|
|
2
|
+
/******/ var __webpack_modules__ = ({
|
|
3
|
+
|
|
4
|
+
/***/ 248:
|
|
5
|
+
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
6
|
+
|
|
7
|
+
"use strict";
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Module dependenices
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
const clone = __nccwpck_require__(572);
|
|
15
|
+
const typeOf = __nccwpck_require__(279);
|
|
16
|
+
const isPlainObject = __nccwpck_require__(814);
|
|
17
|
+
|
|
18
|
+
function cloneDeep(val, instanceClone) {
|
|
19
|
+
switch (typeOf(val)) {
|
|
20
|
+
case 'object':
|
|
21
|
+
return cloneObjectDeep(val, instanceClone);
|
|
22
|
+
case 'array':
|
|
23
|
+
return cloneArrayDeep(val, instanceClone);
|
|
24
|
+
default: {
|
|
25
|
+
return clone(val);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function cloneObjectDeep(val, instanceClone) {
|
|
31
|
+
if (typeof instanceClone === 'function') {
|
|
32
|
+
return instanceClone(val);
|
|
33
|
+
}
|
|
34
|
+
if (instanceClone || isPlainObject(val)) {
|
|
35
|
+
const res = new val.constructor();
|
|
36
|
+
for (let key in val) {
|
|
37
|
+
res[key] = cloneDeep(val[key], instanceClone);
|
|
38
|
+
}
|
|
39
|
+
return res;
|
|
40
|
+
}
|
|
41
|
+
return val;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
function cloneArrayDeep(val, instanceClone) {
|
|
45
|
+
const res = new val.constructor(val.length);
|
|
46
|
+
for (let i = 0; i < val.length; i++) {
|
|
47
|
+
res[i] = cloneDeep(val[i], instanceClone);
|
|
48
|
+
}
|
|
49
|
+
return res;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Expose `cloneDeep`
|
|
54
|
+
*/
|
|
55
|
+
|
|
56
|
+
module.exports = cloneDeep;
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
/***/ }),
|
|
60
|
+
|
|
61
|
+
/***/ 376:
|
|
62
|
+
/***/ ((module) => {
|
|
63
|
+
|
|
64
|
+
module.exports = flatten
|
|
65
|
+
flatten.flatten = flatten
|
|
66
|
+
flatten.unflatten = unflatten
|
|
67
|
+
|
|
68
|
+
function isBuffer (obj) {
|
|
69
|
+
return obj &&
|
|
70
|
+
obj.constructor &&
|
|
71
|
+
(typeof obj.constructor.isBuffer === 'function') &&
|
|
72
|
+
obj.constructor.isBuffer(obj)
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function keyIdentity (key) {
|
|
76
|
+
return key
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
function flatten (target, opts) {
|
|
80
|
+
opts = opts || {}
|
|
81
|
+
|
|
82
|
+
const delimiter = opts.delimiter || '.'
|
|
83
|
+
const maxDepth = opts.maxDepth
|
|
84
|
+
const transformKey = opts.transformKey || keyIdentity
|
|
85
|
+
const output = {}
|
|
86
|
+
|
|
87
|
+
function step (object, prev, currentDepth) {
|
|
88
|
+
currentDepth = currentDepth || 1
|
|
89
|
+
Object.keys(object).forEach(function (key) {
|
|
90
|
+
const value = object[key]
|
|
91
|
+
const isarray = opts.safe && Array.isArray(value)
|
|
92
|
+
const type = Object.prototype.toString.call(value)
|
|
93
|
+
const isbuffer = isBuffer(value)
|
|
94
|
+
const isobject = (
|
|
95
|
+
type === '[object Object]' ||
|
|
96
|
+
type === '[object Array]'
|
|
97
|
+
)
|
|
98
|
+
|
|
99
|
+
const newKey = prev
|
|
100
|
+
? prev + delimiter + transformKey(key)
|
|
101
|
+
: transformKey(key)
|
|
102
|
+
|
|
103
|
+
if (!isarray && !isbuffer && isobject && Object.keys(value).length &&
|
|
104
|
+
(!opts.maxDepth || currentDepth < maxDepth)) {
|
|
105
|
+
return step(value, newKey, currentDepth + 1)
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
output[newKey] = value
|
|
109
|
+
})
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
step(target)
|
|
113
|
+
|
|
114
|
+
return output
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
function unflatten (target, opts) {
|
|
118
|
+
opts = opts || {}
|
|
119
|
+
|
|
120
|
+
const delimiter = opts.delimiter || '.'
|
|
121
|
+
const overwrite = opts.overwrite || false
|
|
122
|
+
const transformKey = opts.transformKey || keyIdentity
|
|
123
|
+
const result = {}
|
|
124
|
+
|
|
125
|
+
const isbuffer = isBuffer(target)
|
|
126
|
+
if (isbuffer || Object.prototype.toString.call(target) !== '[object Object]') {
|
|
127
|
+
return target
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
// safely ensure that the key is
|
|
131
|
+
// an integer.
|
|
132
|
+
function getkey (key) {
|
|
133
|
+
const parsedKey = Number(key)
|
|
134
|
+
|
|
135
|
+
return (
|
|
136
|
+
isNaN(parsedKey) ||
|
|
137
|
+
key.indexOf('.') !== -1 ||
|
|
138
|
+
opts.object
|
|
139
|
+
) ? key
|
|
140
|
+
: parsedKey
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
function addKeys (keyPrefix, recipient, target) {
|
|
144
|
+
return Object.keys(target).reduce(function (result, key) {
|
|
145
|
+
result[keyPrefix + delimiter + key] = target[key]
|
|
146
|
+
|
|
147
|
+
return result
|
|
148
|
+
}, recipient)
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
function isEmpty (val) {
|
|
152
|
+
const type = Object.prototype.toString.call(val)
|
|
153
|
+
const isArray = type === '[object Array]'
|
|
154
|
+
const isObject = type === '[object Object]'
|
|
155
|
+
|
|
156
|
+
if (!val) {
|
|
157
|
+
return true
|
|
158
|
+
} else if (isArray) {
|
|
159
|
+
return !val.length
|
|
160
|
+
} else if (isObject) {
|
|
161
|
+
return !Object.keys(val).length
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
target = Object.keys(target).reduce(function (result, key) {
|
|
166
|
+
const type = Object.prototype.toString.call(target[key])
|
|
167
|
+
const isObject = (type === '[object Object]' || type === '[object Array]')
|
|
168
|
+
if (!isObject || isEmpty(target[key])) {
|
|
169
|
+
result[key] = target[key]
|
|
170
|
+
return result
|
|
171
|
+
} else {
|
|
172
|
+
return addKeys(
|
|
173
|
+
key,
|
|
174
|
+
result,
|
|
175
|
+
flatten(target[key], opts)
|
|
176
|
+
)
|
|
177
|
+
}
|
|
178
|
+
}, {})
|
|
179
|
+
|
|
180
|
+
Object.keys(target).forEach(function (key) {
|
|
181
|
+
const split = key.split(delimiter).map(transformKey)
|
|
182
|
+
let key1 = getkey(split.shift())
|
|
183
|
+
let key2 = getkey(split[0])
|
|
184
|
+
let recipient = result
|
|
185
|
+
|
|
186
|
+
while (key2 !== undefined) {
|
|
187
|
+
if (key1 === '__proto__') {
|
|
188
|
+
return
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
const type = Object.prototype.toString.call(recipient[key1])
|
|
192
|
+
const isobject = (
|
|
193
|
+
type === '[object Object]' ||
|
|
194
|
+
type === '[object Array]'
|
|
195
|
+
)
|
|
196
|
+
|
|
197
|
+
// do not write over falsey, non-undefined values if overwrite is false
|
|
198
|
+
if (!overwrite && !isobject && typeof recipient[key1] !== 'undefined') {
|
|
199
|
+
return
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
if ((overwrite && !isobject) || (!overwrite && recipient[key1] == null)) {
|
|
203
|
+
recipient[key1] = (
|
|
204
|
+
typeof key2 === 'number' &&
|
|
205
|
+
!opts.object ? [] : {}
|
|
206
|
+
)
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
recipient = recipient[key1]
|
|
210
|
+
if (split.length > 0) {
|
|
211
|
+
key1 = getkey(split.shift())
|
|
212
|
+
key2 = getkey(split[0])
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
// unflatten again for 'messy objects'
|
|
217
|
+
recipient[key1] = unflatten(target[key], opts)
|
|
218
|
+
})
|
|
219
|
+
|
|
220
|
+
return result
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
|
|
224
|
+
/***/ }),
|
|
225
|
+
|
|
226
|
+
/***/ 814:
|
|
227
|
+
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
228
|
+
|
|
229
|
+
"use strict";
|
|
230
|
+
/*!
|
|
231
|
+
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
232
|
+
*
|
|
233
|
+
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
234
|
+
* Released under the MIT License.
|
|
235
|
+
*/
|
|
236
|
+
|
|
237
|
+
|
|
238
|
+
|
|
239
|
+
var isObject = __nccwpck_require__(949);
|
|
240
|
+
|
|
241
|
+
function isObjectObject(o) {
|
|
242
|
+
return isObject(o) === true
|
|
243
|
+
&& Object.prototype.toString.call(o) === '[object Object]';
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
module.exports = function isPlainObject(o) {
|
|
247
|
+
var ctor,prot;
|
|
248
|
+
|
|
249
|
+
if (isObjectObject(o) === false) return false;
|
|
250
|
+
|
|
251
|
+
// If has modified constructor
|
|
252
|
+
ctor = o.constructor;
|
|
253
|
+
if (typeof ctor !== 'function') return false;
|
|
254
|
+
|
|
255
|
+
// If has modified prototype
|
|
256
|
+
prot = ctor.prototype;
|
|
257
|
+
if (isObjectObject(prot) === false) return false;
|
|
258
|
+
|
|
259
|
+
// If constructor does not have an Object-specific method
|
|
260
|
+
if (prot.hasOwnProperty('isPrototypeOf') === false) {
|
|
261
|
+
return false;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
// Most likely a plain Object
|
|
265
|
+
return true;
|
|
266
|
+
};
|
|
267
|
+
|
|
268
|
+
|
|
269
|
+
/***/ }),
|
|
270
|
+
|
|
271
|
+
/***/ 949:
|
|
272
|
+
/***/ ((module) => {
|
|
273
|
+
|
|
274
|
+
"use strict";
|
|
275
|
+
/*!
|
|
276
|
+
* isobject <https://github.com/jonschlinkert/isobject>
|
|
277
|
+
*
|
|
278
|
+
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
279
|
+
* Released under the MIT License.
|
|
280
|
+
*/
|
|
281
|
+
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
module.exports = function isObject(val) {
|
|
285
|
+
return val != null && typeof val === 'object' && Array.isArray(val) === false;
|
|
286
|
+
};
|
|
287
|
+
|
|
288
|
+
|
|
289
|
+
/***/ }),
|
|
290
|
+
|
|
291
|
+
/***/ 279:
|
|
292
|
+
/***/ ((module) => {
|
|
293
|
+
|
|
294
|
+
var toString = Object.prototype.toString;
|
|
295
|
+
|
|
296
|
+
module.exports = function kindOf(val) {
|
|
297
|
+
if (val === void 0) return 'undefined';
|
|
298
|
+
if (val === null) return 'null';
|
|
299
|
+
|
|
300
|
+
var type = typeof val;
|
|
301
|
+
if (type === 'boolean') return 'boolean';
|
|
302
|
+
if (type === 'string') return 'string';
|
|
303
|
+
if (type === 'number') return 'number';
|
|
304
|
+
if (type === 'symbol') return 'symbol';
|
|
305
|
+
if (type === 'function') {
|
|
306
|
+
return isGeneratorFn(val) ? 'generatorfunction' : 'function';
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
if (isArray(val)) return 'array';
|
|
310
|
+
if (isBuffer(val)) return 'buffer';
|
|
311
|
+
if (isArguments(val)) return 'arguments';
|
|
312
|
+
if (isDate(val)) return 'date';
|
|
313
|
+
if (isError(val)) return 'error';
|
|
314
|
+
if (isRegexp(val)) return 'regexp';
|
|
315
|
+
|
|
316
|
+
switch (ctorName(val)) {
|
|
317
|
+
case 'Symbol': return 'symbol';
|
|
318
|
+
case 'Promise': return 'promise';
|
|
319
|
+
|
|
320
|
+
// Set, Map, WeakSet, WeakMap
|
|
321
|
+
case 'WeakMap': return 'weakmap';
|
|
322
|
+
case 'WeakSet': return 'weakset';
|
|
323
|
+
case 'Map': return 'map';
|
|
324
|
+
case 'Set': return 'set';
|
|
325
|
+
|
|
326
|
+
// 8-bit typed arrays
|
|
327
|
+
case 'Int8Array': return 'int8array';
|
|
328
|
+
case 'Uint8Array': return 'uint8array';
|
|
329
|
+
case 'Uint8ClampedArray': return 'uint8clampedarray';
|
|
330
|
+
|
|
331
|
+
// 16-bit typed arrays
|
|
332
|
+
case 'Int16Array': return 'int16array';
|
|
333
|
+
case 'Uint16Array': return 'uint16array';
|
|
334
|
+
|
|
335
|
+
// 32-bit typed arrays
|
|
336
|
+
case 'Int32Array': return 'int32array';
|
|
337
|
+
case 'Uint32Array': return 'uint32array';
|
|
338
|
+
case 'Float32Array': return 'float32array';
|
|
339
|
+
case 'Float64Array': return 'float64array';
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
if (isGeneratorObj(val)) {
|
|
343
|
+
return 'generator';
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
// Non-plain objects
|
|
347
|
+
type = toString.call(val);
|
|
348
|
+
switch (type) {
|
|
349
|
+
case '[object Object]': return 'object';
|
|
350
|
+
// iterators
|
|
351
|
+
case '[object Map Iterator]': return 'mapiterator';
|
|
352
|
+
case '[object Set Iterator]': return 'setiterator';
|
|
353
|
+
case '[object String Iterator]': return 'stringiterator';
|
|
354
|
+
case '[object Array Iterator]': return 'arrayiterator';
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
// other
|
|
358
|
+
return type.slice(8, -1).toLowerCase().replace(/\s/g, '');
|
|
359
|
+
};
|
|
360
|
+
|
|
361
|
+
function ctorName(val) {
|
|
362
|
+
return typeof val.constructor === 'function' ? val.constructor.name : null;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
function isArray(val) {
|
|
366
|
+
if (Array.isArray) return Array.isArray(val);
|
|
367
|
+
return val instanceof Array;
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
function isError(val) {
|
|
371
|
+
return val instanceof Error || (typeof val.message === 'string' && val.constructor && typeof val.constructor.stackTraceLimit === 'number');
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
function isDate(val) {
|
|
375
|
+
if (val instanceof Date) return true;
|
|
376
|
+
return typeof val.toDateString === 'function'
|
|
377
|
+
&& typeof val.getDate === 'function'
|
|
378
|
+
&& typeof val.setDate === 'function';
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
function isRegexp(val) {
|
|
382
|
+
if (val instanceof RegExp) return true;
|
|
383
|
+
return typeof val.flags === 'string'
|
|
384
|
+
&& typeof val.ignoreCase === 'boolean'
|
|
385
|
+
&& typeof val.multiline === 'boolean'
|
|
386
|
+
&& typeof val.global === 'boolean';
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
function isGeneratorFn(name, val) {
|
|
390
|
+
return ctorName(name) === 'GeneratorFunction';
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
function isGeneratorObj(val) {
|
|
394
|
+
return typeof val.throw === 'function'
|
|
395
|
+
&& typeof val.return === 'function'
|
|
396
|
+
&& typeof val.next === 'function';
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
function isArguments(val) {
|
|
400
|
+
try {
|
|
401
|
+
if (typeof val.length === 'number' && typeof val.callee === 'function') {
|
|
402
|
+
return true;
|
|
403
|
+
}
|
|
404
|
+
} catch (err) {
|
|
405
|
+
if (err.message.indexOf('callee') !== -1) {
|
|
406
|
+
return true;
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
return false;
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
/**
|
|
413
|
+
* If you need to support Safari 5-7 (8-10 yr-old browser),
|
|
414
|
+
* take a look at https://github.com/feross/is-buffer
|
|
415
|
+
*/
|
|
416
|
+
|
|
417
|
+
function isBuffer(val) {
|
|
418
|
+
if (val.constructor && typeof val.constructor.isBuffer === 'function') {
|
|
419
|
+
return val.constructor.isBuffer(val);
|
|
420
|
+
}
|
|
421
|
+
return false;
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
|
|
425
|
+
/***/ }),
|
|
426
|
+
|
|
427
|
+
/***/ 572:
|
|
428
|
+
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
|
|
429
|
+
|
|
430
|
+
"use strict";
|
|
431
|
+
/*!
|
|
432
|
+
* shallow-clone <https://github.com/jonschlinkert/shallow-clone>
|
|
433
|
+
*
|
|
434
|
+
* Copyright (c) 2015-present, Jon Schlinkert.
|
|
435
|
+
* Released under the MIT License.
|
|
436
|
+
*/
|
|
437
|
+
|
|
438
|
+
|
|
439
|
+
|
|
440
|
+
const valueOf = Symbol.prototype.valueOf;
|
|
441
|
+
const typeOf = __nccwpck_require__(279);
|
|
442
|
+
|
|
443
|
+
function clone(val, deep) {
|
|
444
|
+
switch (typeOf(val)) {
|
|
445
|
+
case 'array':
|
|
446
|
+
return val.slice();
|
|
447
|
+
case 'object':
|
|
448
|
+
return Object.assign({}, val);
|
|
449
|
+
case 'date':
|
|
450
|
+
return new val.constructor(Number(val));
|
|
451
|
+
case 'map':
|
|
452
|
+
return new Map(val);
|
|
453
|
+
case 'set':
|
|
454
|
+
return new Set(val);
|
|
455
|
+
case 'buffer':
|
|
456
|
+
return cloneBuffer(val);
|
|
457
|
+
case 'symbol':
|
|
458
|
+
return cloneSymbol(val);
|
|
459
|
+
case 'arraybuffer':
|
|
460
|
+
return cloneArrayBuffer(val);
|
|
461
|
+
case 'float32array':
|
|
462
|
+
case 'float64array':
|
|
463
|
+
case 'int16array':
|
|
464
|
+
case 'int32array':
|
|
465
|
+
case 'int8array':
|
|
466
|
+
case 'uint16array':
|
|
467
|
+
case 'uint32array':
|
|
468
|
+
case 'uint8clampedarray':
|
|
469
|
+
case 'uint8array':
|
|
470
|
+
return cloneTypedArray(val);
|
|
471
|
+
case 'regexp':
|
|
472
|
+
return cloneRegExp(val);
|
|
473
|
+
case 'error':
|
|
474
|
+
return Object.create(val);
|
|
475
|
+
default: {
|
|
476
|
+
return val;
|
|
477
|
+
}
|
|
478
|
+
}
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
function cloneRegExp(val) {
|
|
482
|
+
const flags = val.flags !== void 0 ? val.flags : (/\w+$/.exec(val) || void 0);
|
|
483
|
+
const re = new val.constructor(val.source, flags);
|
|
484
|
+
re.lastIndex = val.lastIndex;
|
|
485
|
+
return re;
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
function cloneArrayBuffer(val) {
|
|
489
|
+
const res = new val.constructor(val.byteLength);
|
|
490
|
+
new Uint8Array(res).set(new Uint8Array(val));
|
|
491
|
+
return res;
|
|
492
|
+
}
|
|
493
|
+
|
|
494
|
+
function cloneTypedArray(val, deep) {
|
|
495
|
+
return new val.constructor(val.buffer, val.byteOffset, val.length);
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
function cloneBuffer(val) {
|
|
499
|
+
const len = val.length;
|
|
500
|
+
const buf = Buffer.allocUnsafe ? Buffer.allocUnsafe(len) : Buffer.from(len);
|
|
501
|
+
val.copy(buf);
|
|
502
|
+
return buf;
|
|
503
|
+
}
|
|
504
|
+
|
|
505
|
+
function cloneSymbol(val) {
|
|
506
|
+
return valueOf ? Object(valueOf.call(val)) : {};
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
/**
|
|
510
|
+
* Expose `clone`
|
|
511
|
+
*/
|
|
512
|
+
|
|
513
|
+
module.exports = clone;
|
|
514
|
+
|
|
515
|
+
|
|
516
|
+
/***/ }),
|
|
517
|
+
|
|
518
|
+
/***/ 32:
|
|
519
|
+
/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
|
|
520
|
+
|
|
521
|
+
"use strict";
|
|
522
|
+
|
|
523
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
524
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
525
|
+
if (!m) return o;
|
|
526
|
+
var i = m.call(o), r, ar = [], e;
|
|
527
|
+
try {
|
|
528
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
529
|
+
}
|
|
530
|
+
catch (error) { e = { error: error }; }
|
|
531
|
+
finally {
|
|
532
|
+
try {
|
|
533
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
534
|
+
}
|
|
535
|
+
finally { if (e) throw e.error; }
|
|
536
|
+
}
|
|
537
|
+
return ar;
|
|
538
|
+
};
|
|
539
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
|
540
|
+
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
541
|
+
to[j] = from[i];
|
|
542
|
+
return to;
|
|
543
|
+
};
|
|
544
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
545
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
546
|
+
};
|
|
547
|
+
exports.__esModule = true;
|
|
548
|
+
exports.unique = exports.mergeWithRules = exports.mergeWithCustomize = exports["default"] = exports.merge = exports.CustomizeRule = exports.customizeObject = exports.customizeArray = void 0;
|
|
549
|
+
var wildcard_1 = __importDefault(__nccwpck_require__(859));
|
|
550
|
+
var merge_with_1 = __importDefault(__nccwpck_require__(344));
|
|
551
|
+
var join_arrays_1 = __importDefault(__nccwpck_require__(709));
|
|
552
|
+
var unique_1 = __importDefault(__nccwpck_require__(237));
|
|
553
|
+
exports.unique = unique_1["default"];
|
|
554
|
+
var types_1 = __nccwpck_require__(495);
|
|
555
|
+
exports.CustomizeRule = types_1.CustomizeRule;
|
|
556
|
+
var utils_1 = __nccwpck_require__(565);
|
|
557
|
+
function merge(firstConfiguration) {
|
|
558
|
+
var configurations = [];
|
|
559
|
+
for (var _i = 1; _i < arguments.length; _i++) {
|
|
560
|
+
configurations[_i - 1] = arguments[_i];
|
|
561
|
+
}
|
|
562
|
+
return mergeWithCustomize({}).apply(void 0, __spreadArray([firstConfiguration], __read(configurations)));
|
|
563
|
+
}
|
|
564
|
+
exports.merge = merge;
|
|
565
|
+
exports["default"] = merge;
|
|
566
|
+
function mergeWithCustomize(options) {
|
|
567
|
+
return function mergeWithOptions(firstConfiguration) {
|
|
568
|
+
var configurations = [];
|
|
569
|
+
for (var _i = 1; _i < arguments.length; _i++) {
|
|
570
|
+
configurations[_i - 1] = arguments[_i];
|
|
571
|
+
}
|
|
572
|
+
if (utils_1.isUndefined(firstConfiguration) || configurations.some(utils_1.isUndefined)) {
|
|
573
|
+
throw new TypeError("Merging undefined is not supported");
|
|
574
|
+
}
|
|
575
|
+
// @ts-ignore
|
|
576
|
+
if (firstConfiguration.then) {
|
|
577
|
+
throw new TypeError("Promises are not supported");
|
|
578
|
+
}
|
|
579
|
+
// No configuration at all
|
|
580
|
+
if (!firstConfiguration) {
|
|
581
|
+
return {};
|
|
582
|
+
}
|
|
583
|
+
if (configurations.length === 0) {
|
|
584
|
+
if (Array.isArray(firstConfiguration)) {
|
|
585
|
+
// Empty array
|
|
586
|
+
if (firstConfiguration.length === 0) {
|
|
587
|
+
return {};
|
|
588
|
+
}
|
|
589
|
+
if (firstConfiguration.some(utils_1.isUndefined)) {
|
|
590
|
+
throw new TypeError("Merging undefined is not supported");
|
|
591
|
+
}
|
|
592
|
+
// @ts-ignore
|
|
593
|
+
if (firstConfiguration[0].then) {
|
|
594
|
+
throw new TypeError("Promises are not supported");
|
|
595
|
+
}
|
|
596
|
+
return merge_with_1["default"](firstConfiguration, join_arrays_1["default"](options));
|
|
597
|
+
}
|
|
598
|
+
return firstConfiguration;
|
|
599
|
+
}
|
|
600
|
+
return merge_with_1["default"]([firstConfiguration].concat(configurations), join_arrays_1["default"](options));
|
|
601
|
+
};
|
|
602
|
+
}
|
|
603
|
+
exports.mergeWithCustomize = mergeWithCustomize;
|
|
604
|
+
function customizeArray(rules) {
|
|
605
|
+
return function (a, b, key) {
|
|
606
|
+
var matchedRule = Object.keys(rules).find(function (rule) { return wildcard_1["default"](rule, key); }) || "";
|
|
607
|
+
if (matchedRule) {
|
|
608
|
+
switch (rules[matchedRule]) {
|
|
609
|
+
case types_1.CustomizeRule.Prepend:
|
|
610
|
+
return __spreadArray(__spreadArray([], __read(b)), __read(a));
|
|
611
|
+
case types_1.CustomizeRule.Replace:
|
|
612
|
+
return b;
|
|
613
|
+
case types_1.CustomizeRule.Append:
|
|
614
|
+
default:
|
|
615
|
+
return __spreadArray(__spreadArray([], __read(a)), __read(b));
|
|
616
|
+
}
|
|
617
|
+
}
|
|
618
|
+
};
|
|
619
|
+
}
|
|
620
|
+
exports.customizeArray = customizeArray;
|
|
621
|
+
function mergeWithRules(rules) {
|
|
622
|
+
return mergeWithCustomize({
|
|
623
|
+
customizeArray: function (a, b, key) {
|
|
624
|
+
var currentRule = rules;
|
|
625
|
+
key.split(".").forEach(function (k) {
|
|
626
|
+
if (!currentRule) {
|
|
627
|
+
return;
|
|
628
|
+
}
|
|
629
|
+
currentRule = currentRule[k];
|
|
630
|
+
});
|
|
631
|
+
if (utils_1.isPlainObject(currentRule)) {
|
|
632
|
+
return mergeWithRule({ currentRule: currentRule, a: a, b: b });
|
|
633
|
+
}
|
|
634
|
+
if (typeof currentRule === "string") {
|
|
635
|
+
return mergeIndividualRule({ currentRule: currentRule, a: a, b: b });
|
|
636
|
+
}
|
|
637
|
+
return undefined;
|
|
638
|
+
}
|
|
639
|
+
});
|
|
640
|
+
}
|
|
641
|
+
exports.mergeWithRules = mergeWithRules;
|
|
642
|
+
var isArray = Array.isArray;
|
|
643
|
+
function mergeWithRule(_a) {
|
|
644
|
+
var currentRule = _a.currentRule, a = _a.a, b = _a.b;
|
|
645
|
+
if (!isArray(a)) {
|
|
646
|
+
return a;
|
|
647
|
+
}
|
|
648
|
+
var bAllMatches = [];
|
|
649
|
+
var ret = a.map(function (ao) {
|
|
650
|
+
if (!utils_1.isPlainObject(currentRule)) {
|
|
651
|
+
return ao;
|
|
652
|
+
}
|
|
653
|
+
var ret = {};
|
|
654
|
+
var rulesToMatch = [];
|
|
655
|
+
var operations = {};
|
|
656
|
+
Object.entries(currentRule).forEach(function (_a) {
|
|
657
|
+
var _b = __read(_a, 2), k = _b[0], v = _b[1];
|
|
658
|
+
if (v === types_1.CustomizeRule.Match) {
|
|
659
|
+
rulesToMatch.push(k);
|
|
660
|
+
}
|
|
661
|
+
else {
|
|
662
|
+
operations[k] = v;
|
|
663
|
+
}
|
|
664
|
+
});
|
|
665
|
+
var bMatches = b.filter(function (o) {
|
|
666
|
+
var matches = rulesToMatch.every(function (rule) { return utils_1.isSameCondition(ao[rule], o[rule]); });
|
|
667
|
+
if (matches) {
|
|
668
|
+
bAllMatches.push(o);
|
|
669
|
+
}
|
|
670
|
+
return matches;
|
|
671
|
+
});
|
|
672
|
+
if (!utils_1.isPlainObject(ao)) {
|
|
673
|
+
return ao;
|
|
674
|
+
}
|
|
675
|
+
Object.entries(ao).forEach(function (_a) {
|
|
676
|
+
var _b = __read(_a, 2), k = _b[0], v = _b[1];
|
|
677
|
+
var rule = currentRule;
|
|
678
|
+
switch (currentRule[k]) {
|
|
679
|
+
case types_1.CustomizeRule.Match:
|
|
680
|
+
ret[k] = v;
|
|
681
|
+
Object.entries(rule).forEach(function (_a) {
|
|
682
|
+
var _b = __read(_a, 2), k = _b[0], v = _b[1];
|
|
683
|
+
if (v === types_1.CustomizeRule.Replace && bMatches.length > 0) {
|
|
684
|
+
var val = last(bMatches)[k];
|
|
685
|
+
if (typeof val !== "undefined") {
|
|
686
|
+
ret[k] = val;
|
|
687
|
+
}
|
|
688
|
+
}
|
|
689
|
+
});
|
|
690
|
+
break;
|
|
691
|
+
case types_1.CustomizeRule.Append:
|
|
692
|
+
if (!bMatches.length) {
|
|
693
|
+
ret[k] = v;
|
|
694
|
+
break;
|
|
695
|
+
}
|
|
696
|
+
var appendValue = last(bMatches)[k];
|
|
697
|
+
if (!isArray(v) || !isArray(appendValue)) {
|
|
698
|
+
throw new TypeError("Trying to append non-arrays");
|
|
699
|
+
}
|
|
700
|
+
ret[k] = v.concat(appendValue);
|
|
701
|
+
break;
|
|
702
|
+
case types_1.CustomizeRule.Merge:
|
|
703
|
+
if (!bMatches.length) {
|
|
704
|
+
ret[k] = v;
|
|
705
|
+
break;
|
|
706
|
+
}
|
|
707
|
+
var lastValue = last(bMatches)[k];
|
|
708
|
+
if (!utils_1.isPlainObject(v) || !utils_1.isPlainObject(lastValue)) {
|
|
709
|
+
throw new TypeError("Trying to merge non-objects");
|
|
710
|
+
}
|
|
711
|
+
// deep merge
|
|
712
|
+
ret[k] = merge(v, lastValue);
|
|
713
|
+
break;
|
|
714
|
+
case types_1.CustomizeRule.Prepend:
|
|
715
|
+
if (!bMatches.length) {
|
|
716
|
+
ret[k] = v;
|
|
717
|
+
break;
|
|
718
|
+
}
|
|
719
|
+
var prependValue = last(bMatches)[k];
|
|
720
|
+
if (!isArray(v) || !isArray(prependValue)) {
|
|
721
|
+
throw new TypeError("Trying to prepend non-arrays");
|
|
722
|
+
}
|
|
723
|
+
ret[k] = prependValue.concat(v);
|
|
724
|
+
break;
|
|
725
|
+
case types_1.CustomizeRule.Replace:
|
|
726
|
+
ret[k] = bMatches.length > 0 ? last(bMatches)[k] : v;
|
|
727
|
+
break;
|
|
728
|
+
default:
|
|
729
|
+
var currentRule_1 = operations[k];
|
|
730
|
+
// Use .flat(); starting from Node 12
|
|
731
|
+
var b_1 = bMatches
|
|
732
|
+
.map(function (o) { return o[k]; })
|
|
733
|
+
.reduce(function (acc, val) {
|
|
734
|
+
return isArray(acc) && isArray(val) ? __spreadArray(__spreadArray([], __read(acc)), __read(val)) : acc;
|
|
735
|
+
}, []);
|
|
736
|
+
ret[k] = mergeWithRule({ currentRule: currentRule_1, a: v, b: b_1 });
|
|
737
|
+
break;
|
|
738
|
+
}
|
|
739
|
+
});
|
|
740
|
+
return ret;
|
|
741
|
+
});
|
|
742
|
+
return ret.concat(b.filter(function (o) { return !bAllMatches.includes(o); }));
|
|
743
|
+
}
|
|
744
|
+
function mergeIndividualRule(_a) {
|
|
745
|
+
var currentRule = _a.currentRule, a = _a.a, b = _a.b;
|
|
746
|
+
// What if there's no match?
|
|
747
|
+
switch (currentRule) {
|
|
748
|
+
case types_1.CustomizeRule.Append:
|
|
749
|
+
return a.concat(b);
|
|
750
|
+
case types_1.CustomizeRule.Prepend:
|
|
751
|
+
return b.concat(a);
|
|
752
|
+
case types_1.CustomizeRule.Replace:
|
|
753
|
+
return b;
|
|
754
|
+
}
|
|
755
|
+
return a;
|
|
756
|
+
}
|
|
757
|
+
function last(arr) {
|
|
758
|
+
return arr[arr.length - 1];
|
|
759
|
+
}
|
|
760
|
+
function customizeObject(rules) {
|
|
761
|
+
return function (a, b, key) {
|
|
762
|
+
switch (rules[key]) {
|
|
763
|
+
case types_1.CustomizeRule.Prepend:
|
|
764
|
+
return merge_with_1["default"]([b, a], join_arrays_1["default"]());
|
|
765
|
+
case types_1.CustomizeRule.Replace:
|
|
766
|
+
return b;
|
|
767
|
+
case types_1.CustomizeRule.Append:
|
|
768
|
+
return merge_with_1["default"]([a, b], join_arrays_1["default"]());
|
|
769
|
+
}
|
|
770
|
+
};
|
|
771
|
+
}
|
|
772
|
+
exports.customizeObject = customizeObject;
|
|
773
|
+
//# sourceMappingURL=index.js.map
|
|
774
|
+
|
|
775
|
+
/***/ }),
|
|
776
|
+
|
|
777
|
+
/***/ 709:
|
|
778
|
+
/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
|
|
779
|
+
|
|
780
|
+
"use strict";
|
|
781
|
+
|
|
782
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
783
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
784
|
+
if (!m) return o;
|
|
785
|
+
var i = m.call(o), r, ar = [], e;
|
|
786
|
+
try {
|
|
787
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
788
|
+
}
|
|
789
|
+
catch (error) { e = { error: error }; }
|
|
790
|
+
finally {
|
|
791
|
+
try {
|
|
792
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
793
|
+
}
|
|
794
|
+
finally { if (e) throw e.error; }
|
|
795
|
+
}
|
|
796
|
+
return ar;
|
|
797
|
+
};
|
|
798
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
|
799
|
+
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
800
|
+
to[j] = from[i];
|
|
801
|
+
return to;
|
|
802
|
+
};
|
|
803
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
804
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
805
|
+
};
|
|
806
|
+
exports.__esModule = true;
|
|
807
|
+
var clone_deep_1 = __importDefault(__nccwpck_require__(248));
|
|
808
|
+
var merge_with_1 = __importDefault(__nccwpck_require__(344));
|
|
809
|
+
var utils_1 = __nccwpck_require__(565);
|
|
810
|
+
var isArray = Array.isArray;
|
|
811
|
+
function joinArrays(_a) {
|
|
812
|
+
var _b = _a === void 0 ? {} : _a, customizeArray = _b.customizeArray, customizeObject = _b.customizeObject, key = _b.key;
|
|
813
|
+
return function _joinArrays(a, b, k) {
|
|
814
|
+
var newKey = key ? key + "." + k : k;
|
|
815
|
+
if (utils_1.isFunction(a) && utils_1.isFunction(b)) {
|
|
816
|
+
return function () {
|
|
817
|
+
var args = [];
|
|
818
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
819
|
+
args[_i] = arguments[_i];
|
|
820
|
+
}
|
|
821
|
+
return _joinArrays(a.apply(void 0, __spreadArray([], __read(args))), b.apply(void 0, __spreadArray([], __read(args))), k);
|
|
822
|
+
};
|
|
823
|
+
}
|
|
824
|
+
if (isArray(a) && isArray(b)) {
|
|
825
|
+
var customResult = customizeArray && customizeArray(a, b, newKey);
|
|
826
|
+
return customResult || __spreadArray(__spreadArray([], __read(a)), __read(b));
|
|
827
|
+
}
|
|
828
|
+
if (utils_1.isRegex(b)) {
|
|
829
|
+
return b;
|
|
830
|
+
}
|
|
831
|
+
if (utils_1.isPlainObject(a) && utils_1.isPlainObject(b)) {
|
|
832
|
+
var customResult = customizeObject && customizeObject(a, b, newKey);
|
|
833
|
+
return (customResult ||
|
|
834
|
+
merge_with_1["default"]([a, b], joinArrays({
|
|
835
|
+
customizeArray: customizeArray,
|
|
836
|
+
customizeObject: customizeObject,
|
|
837
|
+
key: newKey
|
|
838
|
+
})));
|
|
839
|
+
}
|
|
840
|
+
if (utils_1.isPlainObject(b)) {
|
|
841
|
+
return clone_deep_1["default"](b);
|
|
842
|
+
}
|
|
843
|
+
if (isArray(b)) {
|
|
844
|
+
return __spreadArray([], __read(b));
|
|
845
|
+
}
|
|
846
|
+
return b;
|
|
847
|
+
};
|
|
848
|
+
}
|
|
849
|
+
exports["default"] = joinArrays;
|
|
850
|
+
//# sourceMappingURL=join-arrays.js.map
|
|
851
|
+
|
|
852
|
+
/***/ }),
|
|
853
|
+
|
|
854
|
+
/***/ 344:
|
|
855
|
+
/***/ (function(__unused_webpack_module, exports) {
|
|
856
|
+
|
|
857
|
+
"use strict";
|
|
858
|
+
|
|
859
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
860
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
861
|
+
if (!m) return o;
|
|
862
|
+
var i = m.call(o), r, ar = [], e;
|
|
863
|
+
try {
|
|
864
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
865
|
+
}
|
|
866
|
+
catch (error) { e = { error: error }; }
|
|
867
|
+
finally {
|
|
868
|
+
try {
|
|
869
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
870
|
+
}
|
|
871
|
+
finally { if (e) throw e.error; }
|
|
872
|
+
}
|
|
873
|
+
return ar;
|
|
874
|
+
};
|
|
875
|
+
exports.__esModule = true;
|
|
876
|
+
function mergeWith(objects, customizer) {
|
|
877
|
+
var _a = __read(objects), first = _a[0], rest = _a.slice(1);
|
|
878
|
+
var ret = first;
|
|
879
|
+
rest.forEach(function (a) {
|
|
880
|
+
ret = mergeTo(ret, a, customizer);
|
|
881
|
+
});
|
|
882
|
+
return ret;
|
|
883
|
+
}
|
|
884
|
+
function mergeTo(a, b, customizer) {
|
|
885
|
+
var ret = {};
|
|
886
|
+
Object.keys(a)
|
|
887
|
+
.concat(Object.keys(b))
|
|
888
|
+
.forEach(function (k) {
|
|
889
|
+
var v = customizer(a[k], b[k], k);
|
|
890
|
+
ret[k] = typeof v === "undefined" ? a[k] : v;
|
|
891
|
+
});
|
|
892
|
+
return ret;
|
|
893
|
+
}
|
|
894
|
+
exports["default"] = mergeWith;
|
|
895
|
+
//# sourceMappingURL=merge-with.js.map
|
|
896
|
+
|
|
897
|
+
/***/ }),
|
|
898
|
+
|
|
899
|
+
/***/ 495:
|
|
900
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
901
|
+
|
|
902
|
+
"use strict";
|
|
903
|
+
|
|
904
|
+
exports.__esModule = true;
|
|
905
|
+
exports.CustomizeRule = void 0;
|
|
906
|
+
var CustomizeRule;
|
|
907
|
+
(function (CustomizeRule) {
|
|
908
|
+
CustomizeRule["Match"] = "match";
|
|
909
|
+
CustomizeRule["Merge"] = "merge";
|
|
910
|
+
CustomizeRule["Append"] = "append";
|
|
911
|
+
CustomizeRule["Prepend"] = "prepend";
|
|
912
|
+
CustomizeRule["Replace"] = "replace";
|
|
913
|
+
})(CustomizeRule = exports.CustomizeRule || (exports.CustomizeRule = {}));
|
|
914
|
+
//# sourceMappingURL=types.js.map
|
|
915
|
+
|
|
916
|
+
/***/ }),
|
|
917
|
+
|
|
918
|
+
/***/ 237:
|
|
919
|
+
/***/ (function(__unused_webpack_module, exports) {
|
|
920
|
+
|
|
921
|
+
"use strict";
|
|
922
|
+
|
|
923
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
924
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
925
|
+
if (!m) return o;
|
|
926
|
+
var i = m.call(o), r, ar = [], e;
|
|
927
|
+
try {
|
|
928
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
929
|
+
}
|
|
930
|
+
catch (error) { e = { error: error }; }
|
|
931
|
+
finally {
|
|
932
|
+
try {
|
|
933
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
934
|
+
}
|
|
935
|
+
finally { if (e) throw e.error; }
|
|
936
|
+
}
|
|
937
|
+
return ar;
|
|
938
|
+
};
|
|
939
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
|
940
|
+
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
941
|
+
to[j] = from[i];
|
|
942
|
+
return to;
|
|
943
|
+
};
|
|
944
|
+
exports.__esModule = true;
|
|
945
|
+
function mergeUnique(key, uniques, getter) {
|
|
946
|
+
var uniquesSet = new Set(uniques);
|
|
947
|
+
return function (a, b, k) {
|
|
948
|
+
return (k === key) && Array.from(__spreadArray(__spreadArray([], __read(a)), __read(b)).map(function (it) { return ({ key: getter(it), value: it }); })
|
|
949
|
+
.map(function (_a) {
|
|
950
|
+
var key = _a.key, value = _a.value;
|
|
951
|
+
return ({ key: (uniquesSet.has(key) ? key : value), value: value });
|
|
952
|
+
})
|
|
953
|
+
.reduce(function (m, _a) {
|
|
954
|
+
var key = _a.key, value = _a.value;
|
|
955
|
+
m["delete"](key); // This is required to preserve backward compatible order of elements after a merge.
|
|
956
|
+
return m.set(key, value);
|
|
957
|
+
}, new Map())
|
|
958
|
+
.values());
|
|
959
|
+
};
|
|
960
|
+
}
|
|
961
|
+
exports["default"] = mergeUnique;
|
|
962
|
+
//# sourceMappingURL=unique.js.map
|
|
963
|
+
|
|
964
|
+
/***/ }),
|
|
965
|
+
|
|
966
|
+
/***/ 565:
|
|
967
|
+
/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
|
|
968
|
+
|
|
969
|
+
"use strict";
|
|
970
|
+
|
|
971
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
972
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
973
|
+
if (!m) return o;
|
|
974
|
+
var i = m.call(o), r, ar = [], e;
|
|
975
|
+
try {
|
|
976
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
977
|
+
}
|
|
978
|
+
catch (error) { e = { error: error }; }
|
|
979
|
+
finally {
|
|
980
|
+
try {
|
|
981
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
982
|
+
}
|
|
983
|
+
finally { if (e) throw e.error; }
|
|
984
|
+
}
|
|
985
|
+
return ar;
|
|
986
|
+
};
|
|
987
|
+
exports.__esModule = true;
|
|
988
|
+
exports.isSameCondition = exports.isUndefined = exports.isPlainObject = exports.isFunction = exports.isRegex = void 0;
|
|
989
|
+
var flat_1 = __nccwpck_require__(376);
|
|
990
|
+
function isRegex(o) {
|
|
991
|
+
return o instanceof RegExp;
|
|
992
|
+
}
|
|
993
|
+
exports.isRegex = isRegex;
|
|
994
|
+
// https://stackoverflow.com/a/7356528/228885
|
|
995
|
+
function isFunction(functionToCheck) {
|
|
996
|
+
return (functionToCheck && {}.toString.call(functionToCheck) === "[object Function]");
|
|
997
|
+
}
|
|
998
|
+
exports.isFunction = isFunction;
|
|
999
|
+
function isPlainObject(a) {
|
|
1000
|
+
if (a === null || Array.isArray(a)) {
|
|
1001
|
+
return false;
|
|
1002
|
+
}
|
|
1003
|
+
return typeof a === "object";
|
|
1004
|
+
}
|
|
1005
|
+
exports.isPlainObject = isPlainObject;
|
|
1006
|
+
function isUndefined(a) {
|
|
1007
|
+
return typeof a === "undefined";
|
|
1008
|
+
}
|
|
1009
|
+
exports.isUndefined = isUndefined;
|
|
1010
|
+
/**
|
|
1011
|
+
* According to Webpack docs, a "test" should be the following:
|
|
1012
|
+
*
|
|
1013
|
+
* - A string
|
|
1014
|
+
* - A RegExp
|
|
1015
|
+
* - A function
|
|
1016
|
+
* - An array of conditions (may be nested)
|
|
1017
|
+
* - An object of conditions (may be nested)
|
|
1018
|
+
*
|
|
1019
|
+
* https://webpack.js.org/configuration/module/#condition
|
|
1020
|
+
*/
|
|
1021
|
+
function isSameCondition(a, b) {
|
|
1022
|
+
var _a, _b;
|
|
1023
|
+
if (!a || !b) {
|
|
1024
|
+
return a === b;
|
|
1025
|
+
}
|
|
1026
|
+
if (typeof a === 'string' || typeof b === 'string' ||
|
|
1027
|
+
isRegex(a) || isRegex(b) ||
|
|
1028
|
+
isFunction(a) || isFunction(b)) {
|
|
1029
|
+
return a.toString() === b.toString();
|
|
1030
|
+
}
|
|
1031
|
+
var entriesA = Object.entries(flat_1.flatten(a));
|
|
1032
|
+
var entriesB = Object.entries(flat_1.flatten(b));
|
|
1033
|
+
if (entriesA.length !== entriesB.length) {
|
|
1034
|
+
return false;
|
|
1035
|
+
}
|
|
1036
|
+
for (var i = 0; i < entriesA.length; i++) {
|
|
1037
|
+
entriesA[i][0] = entriesA[i][0].replace(/\b\d+\b/g, "[]");
|
|
1038
|
+
entriesB[i][0] = entriesB[i][0].replace(/\b\d+\b/g, "[]");
|
|
1039
|
+
}
|
|
1040
|
+
function cmp(_a, _b) {
|
|
1041
|
+
var _c = __read(_a, 2), k1 = _c[0], v1 = _c[1];
|
|
1042
|
+
var _d = __read(_b, 2), k2 = _d[0], v2 = _d[1];
|
|
1043
|
+
if (k1 < k2)
|
|
1044
|
+
return -1;
|
|
1045
|
+
if (k1 > k2)
|
|
1046
|
+
return 1;
|
|
1047
|
+
if (v1 < v2)
|
|
1048
|
+
return -1;
|
|
1049
|
+
if (v1 > v2)
|
|
1050
|
+
return 1;
|
|
1051
|
+
return 0;
|
|
1052
|
+
}
|
|
1053
|
+
;
|
|
1054
|
+
entriesA.sort(cmp);
|
|
1055
|
+
entriesB.sort(cmp);
|
|
1056
|
+
if (entriesA.length !== entriesB.length) {
|
|
1057
|
+
return false;
|
|
1058
|
+
}
|
|
1059
|
+
for (var i = 0; i < entriesA.length; i++) {
|
|
1060
|
+
if (entriesA[i][0] !== entriesB[i][0] || ((_a = entriesA[i][1]) === null || _a === void 0 ? void 0 : _a.toString()) !== ((_b = entriesB[i][1]) === null || _b === void 0 ? void 0 : _b.toString())) {
|
|
1061
|
+
return false;
|
|
1062
|
+
}
|
|
1063
|
+
}
|
|
1064
|
+
return true;
|
|
1065
|
+
}
|
|
1066
|
+
exports.isSameCondition = isSameCondition;
|
|
1067
|
+
//# sourceMappingURL=utils.js.map
|
|
1068
|
+
|
|
1069
|
+
/***/ }),
|
|
1070
|
+
|
|
1071
|
+
/***/ 859:
|
|
1072
|
+
/***/ ((module) => {
|
|
1073
|
+
|
|
1074
|
+
"use strict";
|
|
1075
|
+
/* jshint node: true */
|
|
1076
|
+
|
|
1077
|
+
|
|
1078
|
+
var REGEXP_PARTS = /(\*|\?)/g;
|
|
1079
|
+
|
|
1080
|
+
/**
|
|
1081
|
+
# wildcard
|
|
1082
|
+
|
|
1083
|
+
Very simple wildcard matching, which is designed to provide the same
|
|
1084
|
+
functionality that is found in the
|
|
1085
|
+
[eve](https://github.com/adobe-webplatform/eve) eventing library.
|
|
1086
|
+
|
|
1087
|
+
## Usage
|
|
1088
|
+
|
|
1089
|
+
It works with strings:
|
|
1090
|
+
|
|
1091
|
+
<<< examples/strings.js
|
|
1092
|
+
|
|
1093
|
+
Arrays:
|
|
1094
|
+
|
|
1095
|
+
<<< examples/arrays.js
|
|
1096
|
+
|
|
1097
|
+
Objects (matching against keys):
|
|
1098
|
+
|
|
1099
|
+
<<< examples/objects.js
|
|
1100
|
+
|
|
1101
|
+
## Alternative Implementations
|
|
1102
|
+
|
|
1103
|
+
- <https://github.com/isaacs/node-glob>
|
|
1104
|
+
|
|
1105
|
+
Great for full file-based wildcard matching.
|
|
1106
|
+
|
|
1107
|
+
- <https://github.com/sindresorhus/matcher>
|
|
1108
|
+
|
|
1109
|
+
A well cared for and loved JS wildcard matcher.
|
|
1110
|
+
**/
|
|
1111
|
+
|
|
1112
|
+
function WildcardMatcher(text, separator) {
|
|
1113
|
+
this.text = text = text || '';
|
|
1114
|
+
this.hasWild = text.indexOf('*') >= 0;
|
|
1115
|
+
this.separator = separator;
|
|
1116
|
+
this.parts = text.split(separator).map(this.classifyPart.bind(this));
|
|
1117
|
+
}
|
|
1118
|
+
|
|
1119
|
+
WildcardMatcher.prototype.match = function(input) {
|
|
1120
|
+
var matches = true;
|
|
1121
|
+
var parts = this.parts;
|
|
1122
|
+
var ii;
|
|
1123
|
+
var partsCount = parts.length;
|
|
1124
|
+
var testParts;
|
|
1125
|
+
|
|
1126
|
+
if (typeof input == 'string' || input instanceof String) {
|
|
1127
|
+
if (!this.hasWild && this.text != input) {
|
|
1128
|
+
matches = false;
|
|
1129
|
+
} else {
|
|
1130
|
+
testParts = (input || '').split(this.separator);
|
|
1131
|
+
for (ii = 0; matches && ii < partsCount; ii++) {
|
|
1132
|
+
if (parts[ii] === '*') {
|
|
1133
|
+
continue;
|
|
1134
|
+
} else if (ii < testParts.length) {
|
|
1135
|
+
matches = parts[ii] instanceof RegExp
|
|
1136
|
+
? parts[ii].test(testParts[ii])
|
|
1137
|
+
: parts[ii] === testParts[ii];
|
|
1138
|
+
} else {
|
|
1139
|
+
matches = false;
|
|
1140
|
+
}
|
|
1141
|
+
}
|
|
1142
|
+
|
|
1143
|
+
// If matches, then return the component parts
|
|
1144
|
+
matches = matches && testParts;
|
|
1145
|
+
}
|
|
1146
|
+
}
|
|
1147
|
+
else if (typeof input.splice == 'function') {
|
|
1148
|
+
matches = [];
|
|
1149
|
+
|
|
1150
|
+
for (ii = input.length; ii--; ) {
|
|
1151
|
+
if (this.match(input[ii])) {
|
|
1152
|
+
matches[matches.length] = input[ii];
|
|
1153
|
+
}
|
|
1154
|
+
}
|
|
1155
|
+
}
|
|
1156
|
+
else if (typeof input == 'object') {
|
|
1157
|
+
matches = {};
|
|
1158
|
+
|
|
1159
|
+
for (var key in input) {
|
|
1160
|
+
if (this.match(key)) {
|
|
1161
|
+
matches[key] = input[key];
|
|
1162
|
+
}
|
|
1163
|
+
}
|
|
1164
|
+
}
|
|
1165
|
+
|
|
1166
|
+
return matches;
|
|
1167
|
+
};
|
|
1168
|
+
|
|
1169
|
+
WildcardMatcher.prototype.classifyPart = function(part) {
|
|
1170
|
+
// in the event that we have been provided a part that is not just a wildcard
|
|
1171
|
+
// then turn this into a regular expression for matching purposes
|
|
1172
|
+
if (part === '*') {
|
|
1173
|
+
return part;
|
|
1174
|
+
} else if (part.indexOf('*') >= 0 || part.indexOf('?') >= 0) {
|
|
1175
|
+
return new RegExp(part.replace(REGEXP_PARTS, '\.$1'));
|
|
1176
|
+
}
|
|
1177
|
+
|
|
1178
|
+
return part;
|
|
1179
|
+
};
|
|
1180
|
+
|
|
1181
|
+
module.exports = function(text, test, separator) {
|
|
1182
|
+
var matcher = new WildcardMatcher(text, separator || /[\/\.]/);
|
|
1183
|
+
if (typeof test != 'undefined') {
|
|
1184
|
+
return matcher.match(test);
|
|
1185
|
+
}
|
|
1186
|
+
|
|
1187
|
+
return matcher;
|
|
1188
|
+
};
|
|
1189
|
+
|
|
1190
|
+
|
|
1191
|
+
/***/ })
|
|
1192
|
+
|
|
1193
|
+
/******/ });
|
|
1194
|
+
/************************************************************************/
|
|
1195
|
+
/******/ // The module cache
|
|
1196
|
+
/******/ var __webpack_module_cache__ = {};
|
|
1197
|
+
/******/
|
|
1198
|
+
/******/ // The require function
|
|
1199
|
+
/******/ function __nccwpck_require__(moduleId) {
|
|
1200
|
+
/******/ // Check if module is in cache
|
|
1201
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
|
1202
|
+
/******/ if (cachedModule !== undefined) {
|
|
1203
|
+
/******/ return cachedModule.exports;
|
|
1204
|
+
/******/ }
|
|
1205
|
+
/******/ // Create a new module (and put it into the cache)
|
|
1206
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
|
1207
|
+
/******/ // no module.id needed
|
|
1208
|
+
/******/ // no module.loaded needed
|
|
1209
|
+
/******/ exports: {}
|
|
1210
|
+
/******/ };
|
|
1211
|
+
/******/
|
|
1212
|
+
/******/ // Execute the module function
|
|
1213
|
+
/******/ var threw = true;
|
|
1214
|
+
/******/ try {
|
|
1215
|
+
/******/ __webpack_modules__[moduleId].call(module.exports, module, module.exports, __nccwpck_require__);
|
|
1216
|
+
/******/ threw = false;
|
|
1217
|
+
/******/ } finally {
|
|
1218
|
+
/******/ if(threw) delete __webpack_module_cache__[moduleId];
|
|
1219
|
+
/******/ }
|
|
1220
|
+
/******/
|
|
1221
|
+
/******/ // Return the exports of the module
|
|
1222
|
+
/******/ return module.exports;
|
|
1223
|
+
/******/ }
|
|
1224
|
+
/******/
|
|
1225
|
+
/************************************************************************/
|
|
1226
|
+
/******/ /* webpack/runtime/compat */
|
|
1227
|
+
/******/
|
|
1228
|
+
/******/ if (typeof __nccwpck_require__ !== 'undefined') __nccwpck_require__.ab = __dirname + "/";
|
|
1229
|
+
/******/
|
|
1230
|
+
/************************************************************************/
|
|
1231
|
+
/******/
|
|
1232
|
+
/******/ // startup
|
|
1233
|
+
/******/ // Load entry module and return exports
|
|
1234
|
+
/******/ // This entry module is referenced by other modules so it can't be inlined
|
|
1235
|
+
/******/ var __webpack_exports__ = __nccwpck_require__(32);
|
|
1236
|
+
/******/ module.exports = __webpack_exports__;
|
|
1237
|
+
/******/
|
|
1238
|
+
/******/ })()
|
|
1239
|
+
;
|