@speclynx/apidom-overlay 4.11.1 → 4.12.1
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/CHANGELOG.md +8 -0
- package/dist/apidom-overlay.browser.js +1344 -157
- package/dist/apidom-overlay.browser.min.js +1 -1
- package/package.json +9 -9
- package/src/apply/realms/apidom.cjs +3 -1
- package/src/apply/realms/pojo.cjs +3 -1
- package/src/apply/realms/uri.cjs +3 -1
- package/src/apply/trace/TraceBuilder.cjs +3 -1
- package/src/apply/trace/index.cjs +10 -4
- package/src/apply/trace/types.cjs +3 -1
- package/src/diff/index.cjs +28 -7
- package/src/diff/realms/apidom.cjs +3 -1
- package/src/diff/realms/pojo.cjs +3 -1
- package/src/diff/realms/uri.cjs +3 -1
- package/src/errors/OverlayError.cjs +3 -1
- package/src/index.cjs +76 -15
- package/src/validate.cjs +3 -1
|
@@ -35433,8 +35433,11 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
35433
35433
|
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(97071);
|
|
35434
35434
|
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(23321);
|
|
35435
35435
|
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(78894);
|
|
35436
|
-
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(
|
|
35437
|
-
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(
|
|
35436
|
+
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(84660);
|
|
35437
|
+
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(40094);
|
|
35438
|
+
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(4823);
|
|
35439
|
+
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(25810);
|
|
35440
|
+
/* harmony import */ var _registration_mjs__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(36663);
|
|
35438
35441
|
|
|
35439
35442
|
|
|
35440
35443
|
const isNull = value => value === null;
|
|
@@ -35494,7 +35497,7 @@ class Namespace {
|
|
|
35494
35497
|
_attributeElementArrayKeys = [];
|
|
35495
35498
|
constructor(options) {
|
|
35496
35499
|
this.Element = _registration_mjs__WEBPACK_IMPORTED_MODULE_1__["default"];
|
|
35497
|
-
this.KeyValuePair =
|
|
35500
|
+
this.KeyValuePair = _registration_mjs__WEBPACK_IMPORTED_MODULE_15__["default"];
|
|
35498
35501
|
if (!options || !options.noDefault) {
|
|
35499
35502
|
this.useDefault();
|
|
35500
35503
|
}
|
|
@@ -35523,7 +35526,7 @@ class Namespace {
|
|
|
35523
35526
|
*/
|
|
35524
35527
|
useDefault() {
|
|
35525
35528
|
// Set up classes for default elements
|
|
35526
|
-
this.register('null', _registration_mjs__WEBPACK_IMPORTED_MODULE_2__["default"]).register('string', _registration_mjs__WEBPACK_IMPORTED_MODULE_3__["default"]).register('number', _registration_mjs__WEBPACK_IMPORTED_MODULE_4__["default"]).register('boolean', _registration_mjs__WEBPACK_IMPORTED_MODULE_5__["default"]).register('array', _registration_mjs__WEBPACK_IMPORTED_MODULE_6__["default"]).register('object', _registration_mjs__WEBPACK_IMPORTED_MODULE_8__["default"]).register('member', _registration_mjs__WEBPACK_IMPORTED_MODULE_7__["default"]).register('ref', _registration_mjs__WEBPACK_IMPORTED_MODULE_10__["default"]).register('link', _registration_mjs__WEBPACK_IMPORTED_MODULE_9__["default"]).register('sourceMap', _registration_mjs__WEBPACK_IMPORTED_MODULE_11__["default"]);
|
|
35529
|
+
this.register('null', _registration_mjs__WEBPACK_IMPORTED_MODULE_2__["default"]).register('string', _registration_mjs__WEBPACK_IMPORTED_MODULE_3__["default"]).register('number', _registration_mjs__WEBPACK_IMPORTED_MODULE_4__["default"]).register('boolean', _registration_mjs__WEBPACK_IMPORTED_MODULE_5__["default"]).register('array', _registration_mjs__WEBPACK_IMPORTED_MODULE_6__["default"]).register('object', _registration_mjs__WEBPACK_IMPORTED_MODULE_8__["default"]).register('member', _registration_mjs__WEBPACK_IMPORTED_MODULE_7__["default"]).register('ref', _registration_mjs__WEBPACK_IMPORTED_MODULE_10__["default"]).register('link', _registration_mjs__WEBPACK_IMPORTED_MODULE_9__["default"]).register('sourceMap', _registration_mjs__WEBPACK_IMPORTED_MODULE_14__["default"]).register('annotation', _registration_mjs__WEBPACK_IMPORTED_MODULE_11__["default"]).register('comment', _registration_mjs__WEBPACK_IMPORTED_MODULE_12__["default"]).register('parseResult', _registration_mjs__WEBPACK_IMPORTED_MODULE_13__["default"]);
|
|
35527
35530
|
|
|
35528
35531
|
// Add instance detection functions to convert existing objects into
|
|
35529
35532
|
// the corresponding refract elements.
|
|
@@ -85740,14 +85743,28 @@ const factory = (env) => {
|
|
|
85740
85743
|
|
|
85741
85744
|
let requestContentLength;
|
|
85742
85745
|
|
|
85746
|
+
// AxiosError we raise while the request body is being streamed. Captured
|
|
85747
|
+
// by identity so the catch block can surface it directly, regardless of
|
|
85748
|
+
// how the runtime wraps the resulting fetch rejection (undici exposes it
|
|
85749
|
+
// as `err.cause`; some browsers drop the original error entirely).
|
|
85750
|
+
let pendingBodyError = null;
|
|
85751
|
+
|
|
85752
|
+
const maxBodyLengthError = () =>
|
|
85753
|
+
new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"](
|
|
85754
|
+
'Request body larger than maxBodyLength limit',
|
|
85755
|
+
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"].ERR_BAD_REQUEST,
|
|
85756
|
+
config,
|
|
85757
|
+
request
|
|
85758
|
+
);
|
|
85759
|
+
|
|
85743
85760
|
try {
|
|
85744
85761
|
// HTTP basic authentication
|
|
85745
85762
|
let auth = undefined;
|
|
85746
85763
|
const configAuth = own('auth');
|
|
85747
85764
|
|
|
85748
85765
|
if (configAuth) {
|
|
85749
|
-
const username = configAuth
|
|
85750
|
-
const password = configAuth
|
|
85766
|
+
const username = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].getSafeProp(configAuth, 'username') || '';
|
|
85767
|
+
const password = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].getSafeProp(configAuth, 'password') || '';
|
|
85751
85768
|
auth = {
|
|
85752
85769
|
username,
|
|
85753
85770
|
password
|
|
@@ -85796,53 +85813,96 @@ const factory = (env) => {
|
|
|
85796
85813
|
}
|
|
85797
85814
|
}
|
|
85798
85815
|
|
|
85799
|
-
// Enforce maxBodyLength against
|
|
85800
|
-
//
|
|
85801
|
-
//
|
|
85802
|
-
//
|
|
85816
|
+
// Enforce maxBodyLength against known-size bodies before dispatch using
|
|
85817
|
+
// the body's *actual* size — never a caller-declared Content-Length,
|
|
85818
|
+
// which could under-report to slip an oversized body past the check.
|
|
85819
|
+
// Unknown-size streams return undefined here and are counted per-chunk
|
|
85820
|
+
// below as fetch consumes them.
|
|
85803
85821
|
if (hasMaxBodyLength && method !== 'get' && method !== 'head') {
|
|
85804
|
-
const outboundLength = await
|
|
85805
|
-
if (
|
|
85806
|
-
|
|
85807
|
-
|
|
85808
|
-
|
|
85809
|
-
|
|
85810
|
-
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"](
|
|
85811
|
-
'Request body larger than maxBodyLength limit',
|
|
85812
|
-
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"].ERR_BAD_REQUEST,
|
|
85813
|
-
config,
|
|
85814
|
-
request
|
|
85815
|
-
);
|
|
85822
|
+
const outboundLength = await getBodyLength(data);
|
|
85823
|
+
if (typeof outboundLength === 'number' && isFinite(outboundLength)) {
|
|
85824
|
+
requestContentLength = outboundLength;
|
|
85825
|
+
if (outboundLength > maxBodyLength) {
|
|
85826
|
+
throw maxBodyLengthError();
|
|
85827
|
+
}
|
|
85816
85828
|
}
|
|
85817
85829
|
}
|
|
85818
85830
|
|
|
85831
|
+
// A streamed body under maxBodyLength must be counted as fetch consumes
|
|
85832
|
+
// it; its size is never trusted from a caller-declared Content-Length.
|
|
85833
|
+
const mustEnforceStreamBody =
|
|
85834
|
+
hasMaxBodyLength && (_utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].isReadableStream(data) || _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].isStream(data));
|
|
85835
|
+
|
|
85836
|
+
const trackRequestStream = (stream, onProgress, flush) =>
|
|
85837
|
+
(0,_helpers_trackStream_js__WEBPACK_IMPORTED_MODULE_4__.trackStream)(
|
|
85838
|
+
stream,
|
|
85839
|
+
DEFAULT_CHUNK_SIZE,
|
|
85840
|
+
(loadedBytes) => {
|
|
85841
|
+
if (hasMaxBodyLength && loadedBytes > maxBodyLength) {
|
|
85842
|
+
throw (pendingBodyError = maxBodyLengthError());
|
|
85843
|
+
}
|
|
85844
|
+
onProgress && onProgress(loadedBytes);
|
|
85845
|
+
},
|
|
85846
|
+
flush
|
|
85847
|
+
);
|
|
85848
|
+
|
|
85819
85849
|
if (
|
|
85820
|
-
onUploadProgress &&
|
|
85821
85850
|
supportsRequestStream &&
|
|
85822
85851
|
method !== 'get' &&
|
|
85823
85852
|
method !== 'head' &&
|
|
85824
|
-
(
|
|
85853
|
+
(onUploadProgress || mustEnforceStreamBody)
|
|
85825
85854
|
) {
|
|
85826
|
-
|
|
85827
|
-
|
|
85828
|
-
|
|
85829
|
-
|
|
85830
|
-
|
|
85855
|
+
requestContentLength =
|
|
85856
|
+
requestContentLength == null ? await resolveBodyLength(headers, data) : requestContentLength;
|
|
85857
|
+
|
|
85858
|
+
// A declared length of 0 is only trusted to skip the wrap when we are
|
|
85859
|
+
// not enforcing a stream limit (which must not rely on that header).
|
|
85860
|
+
if (requestContentLength !== 0 || mustEnforceStreamBody) {
|
|
85861
|
+
let _request = new Request(url, {
|
|
85862
|
+
method: 'POST',
|
|
85863
|
+
body: data,
|
|
85864
|
+
duplex: 'half',
|
|
85865
|
+
});
|
|
85831
85866
|
|
|
85832
|
-
|
|
85867
|
+
let contentTypeHeader;
|
|
85833
85868
|
|
|
85834
|
-
|
|
85835
|
-
|
|
85836
|
-
|
|
85869
|
+
if (_utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].isFormData(data) && (contentTypeHeader = _request.headers.get('content-type'))) {
|
|
85870
|
+
headers.setContentType(contentTypeHeader);
|
|
85871
|
+
}
|
|
85837
85872
|
|
|
85838
|
-
|
|
85839
|
-
|
|
85840
|
-
|
|
85841
|
-
|
|
85842
|
-
|
|
85873
|
+
if (_request.body) {
|
|
85874
|
+
const [onProgress, flush] =
|
|
85875
|
+
(onUploadProgress &&
|
|
85876
|
+
(0,_helpers_progressEventReducer_js__WEBPACK_IMPORTED_MODULE_6__.progressEventDecorator)(
|
|
85877
|
+
requestContentLength,
|
|
85878
|
+
(0,_helpers_progressEventReducer_js__WEBPACK_IMPORTED_MODULE_6__.progressEventReducer)((0,_helpers_progressEventReducer_js__WEBPACK_IMPORTED_MODULE_6__.asyncDecorator)(onUploadProgress))
|
|
85879
|
+
)) ||
|
|
85880
|
+
[];
|
|
85843
85881
|
|
|
85844
|
-
|
|
85882
|
+
data = trackRequestStream(_request.body, onProgress, flush);
|
|
85883
|
+
}
|
|
85845
85884
|
}
|
|
85885
|
+
} else if (
|
|
85886
|
+
mustEnforceStreamBody &&
|
|
85887
|
+
!isRequestSupported &&
|
|
85888
|
+
isReadableStreamSupported &&
|
|
85889
|
+
method !== 'get' &&
|
|
85890
|
+
method !== 'head'
|
|
85891
|
+
) {
|
|
85892
|
+
data = trackRequestStream(data);
|
|
85893
|
+
} else if (
|
|
85894
|
+
mustEnforceStreamBody &&
|
|
85895
|
+
isRequestSupported &&
|
|
85896
|
+
!supportsRequestStream &&
|
|
85897
|
+
method !== 'get' &&
|
|
85898
|
+
method !== 'head'
|
|
85899
|
+
) {
|
|
85900
|
+
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"](
|
|
85901
|
+
'Stream request bodies are not supported by the current fetch implementation',
|
|
85902
|
+
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"].ERR_NOT_SUPPORT,
|
|
85903
|
+
config,
|
|
85904
|
+
request
|
|
85905
|
+
);
|
|
85846
85906
|
}
|
|
85847
85907
|
|
|
85848
85908
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].isString(withCredentials)) {
|
|
@@ -85885,10 +85945,12 @@ const factory = (env) => {
|
|
|
85885
85945
|
? _fetch(request, fetchOptions)
|
|
85886
85946
|
: _fetch(url, resolvedOptions));
|
|
85887
85947
|
|
|
85948
|
+
const responseHeaders = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_5__["default"].from(response.headers);
|
|
85949
|
+
|
|
85888
85950
|
// Cheap pre-check: if the server honestly declares a content-length that
|
|
85889
85951
|
// already exceeds the cap, reject before we start streaming.
|
|
85890
85952
|
if (hasMaxContentLength) {
|
|
85891
|
-
const declaredLength = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].toFiniteNumber(
|
|
85953
|
+
const declaredLength = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].toFiniteNumber(responseHeaders.getContentLength());
|
|
85892
85954
|
if (declaredLength != null && declaredLength > maxContentLength) {
|
|
85893
85955
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"](
|
|
85894
85956
|
'maxContentLength size of ' + maxContentLength + ' exceeded',
|
|
@@ -85913,7 +85975,7 @@ const factory = (env) => {
|
|
|
85913
85975
|
options[prop] = response[prop];
|
|
85914
85976
|
});
|
|
85915
85977
|
|
|
85916
|
-
const responseContentLength = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].toFiniteNumber(
|
|
85978
|
+
const responseContentLength = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].toFiniteNumber(responseHeaders.getContentLength());
|
|
85917
85979
|
|
|
85918
85980
|
const [onProgress, flush] =
|
|
85919
85981
|
(onDownloadProgress &&
|
|
@@ -86008,6 +86070,23 @@ const factory = (env) => {
|
|
|
86008
86070
|
throw canceledError;
|
|
86009
86071
|
}
|
|
86010
86072
|
|
|
86073
|
+
// Surface a maxBodyLength violation we raised while the request body was
|
|
86074
|
+
// being streamed. Matching by identity (rather than reading
|
|
86075
|
+
// `err.cause.isAxiosError`) keeps the error deterministic across runtimes
|
|
86076
|
+
// and avoids both prototype-pollution reads and mis-attributing a foreign
|
|
86077
|
+
// AxiosError that merely happened to land in `err.cause`.
|
|
86078
|
+
if (pendingBodyError) {
|
|
86079
|
+
request && !pendingBodyError.request && (pendingBodyError.request = request);
|
|
86080
|
+
throw pendingBodyError;
|
|
86081
|
+
}
|
|
86082
|
+
|
|
86083
|
+
// Re-throw AxiosErrors we raised synchronously (data: URL / content-length
|
|
86084
|
+
// pre-checks, response size enforcement) without re-wrapping them.
|
|
86085
|
+
if (err instanceof _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"]) {
|
|
86086
|
+
request && !err.request && (err.request = request);
|
|
86087
|
+
throw err;
|
|
86088
|
+
}
|
|
86089
|
+
|
|
86011
86090
|
if (err && err.name === 'TypeError' && /Load failed|fetch/i.test(err.message)) {
|
|
86012
86091
|
throw Object.assign(
|
|
86013
86092
|
new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_2__["default"](
|
|
@@ -86749,6 +86828,7 @@ class Axios {
|
|
|
86749
86828
|
clarifyTimeoutError: validators.transitional(validators.boolean),
|
|
86750
86829
|
legacyInterceptorReqResOrdering: validators.transitional(validators.boolean),
|
|
86751
86830
|
advertiseZstdAcceptEncoding: validators.transitional(validators.boolean),
|
|
86831
|
+
validateStatusUndefinedResolves: validators.transitional(validators.boolean),
|
|
86752
86832
|
},
|
|
86753
86833
|
false
|
|
86754
86834
|
);
|
|
@@ -86880,7 +86960,7 @@ class Axios {
|
|
|
86880
86960
|
|
|
86881
86961
|
getUri(config) {
|
|
86882
86962
|
config = (0,_mergeConfig_js__WEBPACK_IMPORTED_MODULE_4__["default"])(this.defaults, config);
|
|
86883
|
-
const fullPath = (0,_buildFullPath_js__WEBPACK_IMPORTED_MODULE_5__["default"])(config.baseURL, config.url, config.allowAbsoluteUrls);
|
|
86963
|
+
const fullPath = (0,_buildFullPath_js__WEBPACK_IMPORTED_MODULE_5__["default"])(config.baseURL, config.url, config.allowAbsoluteUrls, config);
|
|
86884
86964
|
return (0,_helpers_buildURL_js__WEBPACK_IMPORTED_MODULE_1__["default"])(fullPath, config.params, config.paramsSerializer);
|
|
86885
86965
|
}
|
|
86886
86966
|
}
|
|
@@ -86893,7 +86973,7 @@ _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].forEach(['delete', 'get', 'hea
|
|
|
86893
86973
|
(0,_mergeConfig_js__WEBPACK_IMPORTED_MODULE_4__["default"])(config || {}, {
|
|
86894
86974
|
method,
|
|
86895
86975
|
url,
|
|
86896
|
-
data: (config
|
|
86976
|
+
data: config && _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(config, 'data') ? config.data : undefined,
|
|
86897
86977
|
})
|
|
86898
86978
|
);
|
|
86899
86979
|
};
|
|
@@ -87245,8 +87325,8 @@ class AxiosHeaders {
|
|
|
87245
87325
|
setHeaders(header, valueOrRewrite);
|
|
87246
87326
|
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
|
|
87247
87327
|
setHeaders((0,_helpers_parseHeaders_js__WEBPACK_IMPORTED_MODULE_1__["default"])(header), valueOrRewrite);
|
|
87248
|
-
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isObject(header) && _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].
|
|
87249
|
-
let obj =
|
|
87328
|
+
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isObject(header) && _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isSafeIterable(header)) {
|
|
87329
|
+
let obj = Object.create(null),
|
|
87250
87330
|
dest,
|
|
87251
87331
|
key;
|
|
87252
87332
|
for (const entry of header) {
|
|
@@ -87254,11 +87334,14 @@ class AxiosHeaders {
|
|
|
87254
87334
|
throw new TypeError('Object iterator must return a key-value pair');
|
|
87255
87335
|
}
|
|
87256
87336
|
|
|
87257
|
-
|
|
87258
|
-
|
|
87259
|
-
|
|
87260
|
-
|
|
87261
|
-
: entry[1];
|
|
87337
|
+
key = entry[0];
|
|
87338
|
+
|
|
87339
|
+
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(obj, key)) {
|
|
87340
|
+
dest = obj[key];
|
|
87341
|
+
obj[key] = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isArray(dest) ? [...dest, entry[1]] : [dest, entry[1]];
|
|
87342
|
+
} else {
|
|
87343
|
+
obj[key] = entry[1];
|
|
87344
|
+
}
|
|
87262
87345
|
}
|
|
87263
87346
|
|
|
87264
87347
|
setHeaders(obj, valueOrRewrite);
|
|
@@ -87577,12 +87660,39 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
87577
87660
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
87578
87661
|
/* harmony export */ "default": () => (/* binding */ buildFullPath)
|
|
87579
87662
|
/* harmony export */ });
|
|
87580
|
-
/* harmony import */ var
|
|
87581
|
-
/* harmony import */ var
|
|
87663
|
+
/* harmony import */ var _AxiosError_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28515);
|
|
87664
|
+
/* harmony import */ var _helpers_isAbsoluteURL_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(40623);
|
|
87665
|
+
/* harmony import */ var _helpers_combineURLs_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(48250);
|
|
87666
|
+
|
|
87667
|
+
|
|
87582
87668
|
|
|
87583
87669
|
|
|
87584
87670
|
|
|
87585
87671
|
|
|
87672
|
+
const malformedHttpProtocol = /^https?:(?!\/\/)/i;
|
|
87673
|
+
const httpProtocolControlCharacters = /[\t\n\r]/g;
|
|
87674
|
+
|
|
87675
|
+
function stripLeadingC0ControlOrSpace(url) {
|
|
87676
|
+
let i = 0;
|
|
87677
|
+
while (i < url.length && url.charCodeAt(i) <= 0x20) {
|
|
87678
|
+
i++;
|
|
87679
|
+
}
|
|
87680
|
+
return url.slice(i);
|
|
87681
|
+
}
|
|
87682
|
+
|
|
87683
|
+
function normalizeURLForProtocolCheck(url) {
|
|
87684
|
+
return stripLeadingC0ControlOrSpace(url).replace(httpProtocolControlCharacters, '');
|
|
87685
|
+
}
|
|
87686
|
+
|
|
87687
|
+
function assertValidHttpProtocolURL(url, config) {
|
|
87688
|
+
if (typeof url === 'string' && malformedHttpProtocol.test(normalizeURLForProtocolCheck(url))) {
|
|
87689
|
+
throw new _AxiosError_js__WEBPACK_IMPORTED_MODULE_0__["default"](
|
|
87690
|
+
'Invalid URL: missing "//" after protocol',
|
|
87691
|
+
_AxiosError_js__WEBPACK_IMPORTED_MODULE_0__["default"].ERR_INVALID_URL,
|
|
87692
|
+
config
|
|
87693
|
+
);
|
|
87694
|
+
}
|
|
87695
|
+
}
|
|
87586
87696
|
|
|
87587
87697
|
/**
|
|
87588
87698
|
* Creates a new URL by combining the baseURL with the requestedURL,
|
|
@@ -87594,10 +87704,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
87594
87704
|
*
|
|
87595
87705
|
* @returns {string} The combined full path
|
|
87596
87706
|
*/
|
|
87597
|
-
function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
|
|
87598
|
-
|
|
87707
|
+
function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls, config) {
|
|
87708
|
+
assertValidHttpProtocolURL(requestedURL, config);
|
|
87709
|
+
let isRelativeUrl = !(0,_helpers_isAbsoluteURL_js__WEBPACK_IMPORTED_MODULE_1__["default"])(requestedURL);
|
|
87599
87710
|
if (baseURL && (isRelativeUrl || allowAbsoluteUrls === false)) {
|
|
87600
|
-
|
|
87711
|
+
assertValidHttpProtocolURL(baseURL, config);
|
|
87712
|
+
return (0,_helpers_combineURLs_js__WEBPACK_IMPORTED_MODULE_2__["default"])(baseURL, requestedURL);
|
|
87601
87713
|
}
|
|
87602
87714
|
return requestedURL;
|
|
87603
87715
|
}
|
|
@@ -87792,6 +87904,28 @@ function mergeConfig(config1, config2) {
|
|
|
87792
87904
|
}
|
|
87793
87905
|
}
|
|
87794
87906
|
|
|
87907
|
+
function getMergedTransitionalOption(prop) {
|
|
87908
|
+
const transitional2 = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(config2, 'transitional') ? config2.transitional : undefined;
|
|
87909
|
+
|
|
87910
|
+
if (!_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isUndefined(transitional2)) {
|
|
87911
|
+
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isPlainObject(transitional2)) {
|
|
87912
|
+
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(transitional2, prop)) {
|
|
87913
|
+
return transitional2[prop];
|
|
87914
|
+
}
|
|
87915
|
+
} else {
|
|
87916
|
+
return undefined;
|
|
87917
|
+
}
|
|
87918
|
+
}
|
|
87919
|
+
|
|
87920
|
+
const transitional1 = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(config1, 'transitional') ? config1.transitional : undefined;
|
|
87921
|
+
|
|
87922
|
+
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isPlainObject(transitional1) && _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(transitional1, prop)) {
|
|
87923
|
+
return transitional1[prop];
|
|
87924
|
+
}
|
|
87925
|
+
|
|
87926
|
+
return undefined;
|
|
87927
|
+
}
|
|
87928
|
+
|
|
87795
87929
|
// eslint-disable-next-line consistent-return
|
|
87796
87930
|
function mergeDirectKeys(a, b, prop) {
|
|
87797
87931
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(config2, prop)) {
|
|
@@ -87844,6 +87978,18 @@ function mergeConfig(config1, config2) {
|
|
|
87844
87978
|
(_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isUndefined(configValue) && merge !== mergeDirectKeys) || (config[prop] = configValue);
|
|
87845
87979
|
});
|
|
87846
87980
|
|
|
87981
|
+
if (
|
|
87982
|
+
_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(config2, 'validateStatus') &&
|
|
87983
|
+
_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isUndefined(config2.validateStatus) &&
|
|
87984
|
+
getMergedTransitionalOption('validateStatusUndefinedResolves') === false
|
|
87985
|
+
) {
|
|
87986
|
+
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].hasOwnProp(config1, 'validateStatus')) {
|
|
87987
|
+
config.validateStatus = getMergedValue(undefined, config1.validateStatus);
|
|
87988
|
+
} else {
|
|
87989
|
+
delete config.validateStatus;
|
|
87990
|
+
}
|
|
87991
|
+
}
|
|
87992
|
+
|
|
87847
87993
|
return config;
|
|
87848
87994
|
}
|
|
87849
87995
|
|
|
@@ -88145,6 +88291,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
88145
88291
|
clarifyTimeoutError: false,
|
|
88146
88292
|
legacyInterceptorReqResOrdering: true,
|
|
88147
88293
|
advertiseZstdAcceptEncoding: false,
|
|
88294
|
+
validateStatusUndefinedResolves: true,
|
|
88148
88295
|
});
|
|
88149
88296
|
|
|
88150
88297
|
|
|
@@ -88158,7 +88305,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
88158
88305
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
88159
88306
|
/* harmony export */ VERSION: () => (/* binding */ VERSION)
|
|
88160
88307
|
/* harmony export */ });
|
|
88161
|
-
const VERSION = "1.
|
|
88308
|
+
const VERSION = "1.18.0";
|
|
88162
88309
|
|
|
88163
88310
|
/***/ },
|
|
88164
88311
|
|
|
@@ -88397,15 +88544,17 @@ function buildURL(url, params, options) {
|
|
|
88397
88544
|
return url;
|
|
88398
88545
|
}
|
|
88399
88546
|
|
|
88400
|
-
const _encode = (options && options.encode) || encode;
|
|
88401
|
-
|
|
88402
88547
|
const _options = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isFunction(options)
|
|
88403
88548
|
? {
|
|
88404
88549
|
serialize: options,
|
|
88405
88550
|
}
|
|
88406
88551
|
: options;
|
|
88407
88552
|
|
|
88408
|
-
|
|
88553
|
+
// Read serializer options pollution-safely: own properties and methods on a
|
|
88554
|
+
// class/template prototype are honored, but values injected onto a polluted
|
|
88555
|
+
// Object.prototype are ignored.
|
|
88556
|
+
const _encode = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].getSafeProp(_options, 'encode') || encode;
|
|
88557
|
+
const serializeFn = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].getSafeProp(_options, 'serialize');
|
|
88409
88558
|
|
|
88410
88559
|
let serializedParams;
|
|
88411
88560
|
|
|
@@ -88617,11 +88766,19 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
88617
88766
|
* Estimate decoded byte length of a data:// URL *without* allocating large buffers.
|
|
88618
88767
|
* - For base64: compute exact decoded size using length and padding;
|
|
88619
88768
|
* handle %XX at the character-count level (no string allocation).
|
|
88620
|
-
* - For non-base64:
|
|
88769
|
+
* - For non-base64: compute the exact percent-decoded UTF-8 byte length.
|
|
88621
88770
|
*
|
|
88622
88771
|
* @param {string} url
|
|
88623
88772
|
* @returns {number}
|
|
88624
88773
|
*/
|
|
88774
|
+
const isHexDigit = (charCode) =>
|
|
88775
|
+
(charCode >= 48 && charCode <= 57) ||
|
|
88776
|
+
(charCode >= 65 && charCode <= 70) ||
|
|
88777
|
+
(charCode >= 97 && charCode <= 102);
|
|
88778
|
+
|
|
88779
|
+
const isPercentEncodedByte = (str, i, len) =>
|
|
88780
|
+
i + 2 < len && isHexDigit(str.charCodeAt(i + 1)) && isHexDigit(str.charCodeAt(i + 2));
|
|
88781
|
+
|
|
88625
88782
|
function estimateDataURLDecodedBytes(url) {
|
|
88626
88783
|
if (!url || typeof url !== 'string') return 0;
|
|
88627
88784
|
if (!url.startsWith('data:')) return 0;
|
|
@@ -88641,9 +88798,7 @@ function estimateDataURLDecodedBytes(url) {
|
|
|
88641
88798
|
if (body.charCodeAt(i) === 37 /* '%' */ && i + 2 < len) {
|
|
88642
88799
|
const a = body.charCodeAt(i + 1);
|
|
88643
88800
|
const b = body.charCodeAt(i + 2);
|
|
88644
|
-
const isHex =
|
|
88645
|
-
((a >= 48 && a <= 57) || (a >= 65 && a <= 70) || (a >= 97 && a <= 102)) &&
|
|
88646
|
-
((b >= 48 && b <= 57) || (b >= 65 && b <= 70) || (b >= 97 && b <= 102));
|
|
88801
|
+
const isHex = isHexDigit(a) && isHexDigit(b);
|
|
88647
88802
|
|
|
88648
88803
|
if (isHex) {
|
|
88649
88804
|
effectiveLen -= 2;
|
|
@@ -88684,18 +88839,17 @@ function estimateDataURLDecodedBytes(url) {
|
|
|
88684
88839
|
return bytes > 0 ? bytes : 0;
|
|
88685
88840
|
}
|
|
88686
88841
|
|
|
88687
|
-
if (typeof Buffer !== 'undefined' && typeof Buffer.byteLength === 'function') {
|
|
88688
|
-
return Buffer.byteLength(body, 'utf8');
|
|
88689
|
-
}
|
|
88690
|
-
|
|
88691
88842
|
// Compute UTF-8 byte length directly from UTF-16 code units without allocating
|
|
88692
88843
|
// a byte buffer (TextEncoder.encode would defeat the DoS guard on large bodies).
|
|
88693
|
-
//
|
|
88694
|
-
//
|
|
88844
|
+
// Valid %XX triplets count as one decoded byte; this matches the bytes that
|
|
88845
|
+
// decodeURIComponent(body) would produce before Buffer re-encodes the string.
|
|
88695
88846
|
let bytes = 0;
|
|
88696
88847
|
for (let i = 0, len = body.length; i < len; i++) {
|
|
88697
88848
|
const c = body.charCodeAt(i);
|
|
88698
|
-
if (c
|
|
88849
|
+
if (c === 37 /* '%' */ && isPercentEncodedByte(body, i, len)) {
|
|
88850
|
+
bytes += 1;
|
|
88851
|
+
i += 2;
|
|
88852
|
+
} else if (c < 0x80) {
|
|
88699
88853
|
bytes += 1;
|
|
88700
88854
|
} else if (c < 0x800) {
|
|
88701
88855
|
bytes += 2;
|
|
@@ -88726,10 +88880,25 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
88726
88880
|
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
88727
88881
|
/* harmony export */ });
|
|
88728
88882
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(56398);
|
|
88883
|
+
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(28515);
|
|
88884
|
+
/* harmony import */ var _toFormData_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(36422);
|
|
88885
|
+
|
|
88886
|
+
|
|
88729
88887
|
|
|
88730
88888
|
|
|
88731
88889
|
|
|
88732
88890
|
|
|
88891
|
+
const MAX_DEPTH = _toFormData_js__WEBPACK_IMPORTED_MODULE_2__.DEFAULT_FORM_DATA_MAX_DEPTH;
|
|
88892
|
+
|
|
88893
|
+
function throwIfDepthExceeded(index) {
|
|
88894
|
+
if (index > MAX_DEPTH) {
|
|
88895
|
+
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__["default"](
|
|
88896
|
+
'FormData field is too deeply nested (' + index + ' levels). Max depth: ' + MAX_DEPTH,
|
|
88897
|
+
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__["default"].ERR_FORM_DATA_DEPTH_EXCEEDED
|
|
88898
|
+
);
|
|
88899
|
+
}
|
|
88900
|
+
}
|
|
88901
|
+
|
|
88733
88902
|
/**
|
|
88734
88903
|
* It takes a string like `foo[x][y][z]` and returns an array like `['foo', 'x', 'y', 'z']
|
|
88735
88904
|
*
|
|
@@ -88742,9 +88911,16 @@ function parsePropPath(name) {
|
|
|
88742
88911
|
// foo.x.y.z
|
|
88743
88912
|
// foo-x-y-z
|
|
88744
88913
|
// foo x y z
|
|
88745
|
-
|
|
88746
|
-
|
|
88747
|
-
|
|
88914
|
+
const path = [];
|
|
88915
|
+
const pattern = /\w+|\[(\w*)]/g;
|
|
88916
|
+
let match;
|
|
88917
|
+
|
|
88918
|
+
while ((match = pattern.exec(name)) !== null) {
|
|
88919
|
+
throwIfDepthExceeded(path.length);
|
|
88920
|
+
path.push(match[0] === '[]' ? '' : match[1] || match[0]);
|
|
88921
|
+
}
|
|
88922
|
+
|
|
88923
|
+
return path;
|
|
88748
88924
|
}
|
|
88749
88925
|
|
|
88750
88926
|
/**
|
|
@@ -88776,6 +88952,8 @@ function arrayToObject(arr) {
|
|
|
88776
88952
|
*/
|
|
88777
88953
|
function formDataToJSON(formData) {
|
|
88778
88954
|
function buildPath(path, value, target, index) {
|
|
88955
|
+
throwIfDepthExceeded(index);
|
|
88956
|
+
|
|
88779
88957
|
let name = path[index++];
|
|
88780
88958
|
|
|
88781
88959
|
if (name === '__proto__') return true;
|
|
@@ -89172,17 +89350,19 @@ function resolveConfig(config) {
|
|
|
89172
89350
|
newConfig.headers = headers = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_6__["default"].from(headers);
|
|
89173
89351
|
|
|
89174
89352
|
newConfig.url = (0,_buildURL_js__WEBPACK_IMPORTED_MODULE_7__["default"])(
|
|
89175
|
-
(0,_core_buildFullPath_js__WEBPACK_IMPORTED_MODULE_4__["default"])(baseURL, url, allowAbsoluteUrls),
|
|
89353
|
+
(0,_core_buildFullPath_js__WEBPACK_IMPORTED_MODULE_4__["default"])(baseURL, url, allowAbsoluteUrls, newConfig),
|
|
89176
89354
|
own('params'),
|
|
89177
89355
|
own('paramsSerializer')
|
|
89178
89356
|
);
|
|
89179
89357
|
|
|
89180
89358
|
// HTTP basic authentication
|
|
89181
89359
|
if (auth) {
|
|
89360
|
+
const username = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].getSafeProp(auth, 'username') || '';
|
|
89361
|
+
const password = _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].getSafeProp(auth, 'password') || '';
|
|
89362
|
+
|
|
89182
89363
|
headers.set(
|
|
89183
89364
|
'Authorization',
|
|
89184
|
-
'Basic ' +
|
|
89185
|
-
btoa((auth.username || '') + ':' + (auth.password ? encodeUTF8(auth.password) : ''))
|
|
89365
|
+
'Basic ' + btoa(username + ':' + (password ? encodeUTF8(password) : ''))
|
|
89186
89366
|
);
|
|
89187
89367
|
}
|
|
89188
89368
|
|
|
@@ -89475,6 +89655,7 @@ function throttle(fn, freq) {
|
|
|
89475
89655
|
"use strict";
|
|
89476
89656
|
__webpack_require__.r(__webpack_exports__);
|
|
89477
89657
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
89658
|
+
/* harmony export */ DEFAULT_FORM_DATA_MAX_DEPTH: () => (/* binding */ DEFAULT_FORM_DATA_MAX_DEPTH),
|
|
89478
89659
|
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
89479
89660
|
/* harmony export */ });
|
|
89480
89661
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(56398);
|
|
@@ -89487,6 +89668,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
89487
89668
|
// temporary hotfix to avoid circular references until AxiosURLSearchParams is refactored
|
|
89488
89669
|
|
|
89489
89670
|
|
|
89671
|
+
// Default nesting limit shared with the inverse transform (formDataToJSON) so
|
|
89672
|
+
// the FormData <-> JSON round-trip stays symmetric.
|
|
89673
|
+
const DEFAULT_FORM_DATA_MAX_DEPTH = 100;
|
|
89674
|
+
|
|
89490
89675
|
/**
|
|
89491
89676
|
* Determines if the given thing is a array or js object.
|
|
89492
89677
|
*
|
|
@@ -89597,8 +89782,9 @@ function toFormData(obj, formData, options) {
|
|
|
89597
89782
|
const dots = options.dots;
|
|
89598
89783
|
const indexes = options.indexes;
|
|
89599
89784
|
const _Blob = options.Blob || (typeof Blob !== 'undefined' && Blob);
|
|
89600
|
-
const maxDepth = options.maxDepth === undefined ?
|
|
89785
|
+
const maxDepth = options.maxDepth === undefined ? DEFAULT_FORM_DATA_MAX_DEPTH : options.maxDepth;
|
|
89601
89786
|
const useBlob = _Blob && _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isSpecCompliantForm(formData);
|
|
89787
|
+
const stack = [];
|
|
89602
89788
|
|
|
89603
89789
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isFunction(visitor)) {
|
|
89604
89790
|
throw new TypeError('visitor must be a function');
|
|
@@ -89626,6 +89812,38 @@ function toFormData(obj, formData, options) {
|
|
|
89626
89812
|
return value;
|
|
89627
89813
|
}
|
|
89628
89814
|
|
|
89815
|
+
function throwIfMaxDepthExceeded(depth) {
|
|
89816
|
+
if (depth > maxDepth) {
|
|
89817
|
+
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__["default"](
|
|
89818
|
+
'Object is too deeply nested (' + depth + ' levels). Max depth: ' + maxDepth,
|
|
89819
|
+
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__["default"].ERR_FORM_DATA_DEPTH_EXCEEDED
|
|
89820
|
+
);
|
|
89821
|
+
}
|
|
89822
|
+
}
|
|
89823
|
+
|
|
89824
|
+
function stringifyWithDepthLimit(value, depth) {
|
|
89825
|
+
if (maxDepth === Infinity) {
|
|
89826
|
+
return JSON.stringify(value);
|
|
89827
|
+
}
|
|
89828
|
+
|
|
89829
|
+
const ancestors = [];
|
|
89830
|
+
|
|
89831
|
+
return JSON.stringify(value, function limitDepth(_key, currentValue) {
|
|
89832
|
+
if (!_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isObject(currentValue)) {
|
|
89833
|
+
return currentValue;
|
|
89834
|
+
}
|
|
89835
|
+
|
|
89836
|
+
while (ancestors.length && ancestors[ancestors.length - 1] !== this) {
|
|
89837
|
+
ancestors.pop();
|
|
89838
|
+
}
|
|
89839
|
+
|
|
89840
|
+
ancestors.push(currentValue);
|
|
89841
|
+
throwIfMaxDepthExceeded(depth + ancestors.length - 1);
|
|
89842
|
+
|
|
89843
|
+
return currentValue;
|
|
89844
|
+
});
|
|
89845
|
+
}
|
|
89846
|
+
|
|
89629
89847
|
/**
|
|
89630
89848
|
* Default visitor.
|
|
89631
89849
|
*
|
|
@@ -89649,7 +89867,7 @@ function toFormData(obj, formData, options) {
|
|
|
89649
89867
|
// eslint-disable-next-line no-param-reassign
|
|
89650
89868
|
key = metaTokens ? key : key.slice(0, -2);
|
|
89651
89869
|
// eslint-disable-next-line no-param-reassign
|
|
89652
|
-
value =
|
|
89870
|
+
value = stringifyWithDepthLimit(value, 1);
|
|
89653
89871
|
} else if (
|
|
89654
89872
|
(_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isArray(value) && isFlatArray(value)) ||
|
|
89655
89873
|
((_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isFileList(value) || _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].endsWith(key, '[]')) && (arr = _utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].toArray(value)))
|
|
@@ -89682,8 +89900,6 @@ function toFormData(obj, formData, options) {
|
|
|
89682
89900
|
return false;
|
|
89683
89901
|
}
|
|
89684
89902
|
|
|
89685
|
-
const stack = [];
|
|
89686
|
-
|
|
89687
89903
|
const exposedHelpers = Object.assign(predicates, {
|
|
89688
89904
|
defaultVisitor,
|
|
89689
89905
|
convertValue,
|
|
@@ -89693,12 +89909,7 @@ function toFormData(obj, formData, options) {
|
|
|
89693
89909
|
function build(value, path, depth = 0) {
|
|
89694
89910
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_0__["default"].isUndefined(value)) return;
|
|
89695
89911
|
|
|
89696
|
-
|
|
89697
|
-
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__["default"](
|
|
89698
|
-
'Object is too deeply nested (' + depth + ' levels). Max depth: ' + maxDepth,
|
|
89699
|
-
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__["default"].ERR_FORM_DATA_DEPTH_EXCEEDED
|
|
89700
|
-
);
|
|
89701
|
-
}
|
|
89912
|
+
throwIfMaxDepthExceeded(depth);
|
|
89702
89913
|
|
|
89703
89914
|
if (stack.indexOf(value) !== -1) {
|
|
89704
89915
|
throw new Error('Circular reference detected in ' + path.join('.'));
|
|
@@ -90173,6 +90384,57 @@ const { toString } = Object.prototype;
|
|
|
90173
90384
|
const { getPrototypeOf } = Object;
|
|
90174
90385
|
const { iterator, toStringTag } = Symbol;
|
|
90175
90386
|
|
|
90387
|
+
/* Creating a function that will check if an object has a property. */
|
|
90388
|
+
const hasOwnProperty = (
|
|
90389
|
+
({ hasOwnProperty }) =>
|
|
90390
|
+
(obj, prop) =>
|
|
90391
|
+
hasOwnProperty.call(obj, prop)
|
|
90392
|
+
)(Object.prototype);
|
|
90393
|
+
|
|
90394
|
+
/**
|
|
90395
|
+
* Walk the prototype chain (excluding the shared Object.prototype) looking for
|
|
90396
|
+
* an own `prop`. This distinguishes genuine own/inherited members — including
|
|
90397
|
+
* class accessors and template prototypes — from members injected via
|
|
90398
|
+
* Object.prototype pollution (e.g. `Object.prototype.username = '...'`), which
|
|
90399
|
+
* live on Object.prototype itself and are therefore never matched.
|
|
90400
|
+
*
|
|
90401
|
+
* @param {*} thing The value whose chain to inspect
|
|
90402
|
+
* @param {string|symbol} prop The property key to look for
|
|
90403
|
+
*
|
|
90404
|
+
* @returns {boolean} True when `prop` is owned below Object.prototype
|
|
90405
|
+
*/
|
|
90406
|
+
const hasOwnInPrototypeChain = (thing, prop) => {
|
|
90407
|
+
let obj = thing;
|
|
90408
|
+
const seen = [];
|
|
90409
|
+
|
|
90410
|
+
while (obj != null && obj !== Object.prototype) {
|
|
90411
|
+
if (seen.indexOf(obj) !== -1) {
|
|
90412
|
+
return false;
|
|
90413
|
+
}
|
|
90414
|
+
seen.push(obj);
|
|
90415
|
+
|
|
90416
|
+
if (hasOwnProperty(obj, prop)) {
|
|
90417
|
+
return true;
|
|
90418
|
+
}
|
|
90419
|
+
obj = getPrototypeOf(obj);
|
|
90420
|
+
}
|
|
90421
|
+
return false;
|
|
90422
|
+
};
|
|
90423
|
+
|
|
90424
|
+
/**
|
|
90425
|
+
* Read `obj[prop]` only when it is safe from Object.prototype pollution. Own
|
|
90426
|
+
* properties and members inherited from a non-Object.prototype source (a class
|
|
90427
|
+
* instance or template object) are honored; a value reachable only through a
|
|
90428
|
+
* polluted Object.prototype is ignored and `undefined` is returned.
|
|
90429
|
+
*
|
|
90430
|
+
* @param {*} obj The source object
|
|
90431
|
+
* @param {string|symbol} prop The property key to read
|
|
90432
|
+
*
|
|
90433
|
+
* @returns {*} The resolved value, or undefined when unsafe/absent
|
|
90434
|
+
*/
|
|
90435
|
+
const getSafeProp = (obj, prop) =>
|
|
90436
|
+
obj != null && hasOwnInPrototypeChain(obj, prop) ? obj[prop] : undefined;
|
|
90437
|
+
|
|
90176
90438
|
const kindOf = ((cache) => (thing) => {
|
|
90177
90439
|
const str = toString.call(thing);
|
|
90178
90440
|
return cache[str] || (cache[str] = str.slice(8, -1).toLowerCase());
|
|
@@ -90298,7 +90560,7 @@ const isBoolean = (thing) => thing === true || thing === false;
|
|
|
90298
90560
|
* @returns {boolean} True if value is a plain Object, otherwise false
|
|
90299
90561
|
*/
|
|
90300
90562
|
const isPlainObject = (val) => {
|
|
90301
|
-
if (
|
|
90563
|
+
if (!isObject(val)) {
|
|
90302
90564
|
return false;
|
|
90303
90565
|
}
|
|
90304
90566
|
|
|
@@ -90306,9 +90568,12 @@ const isPlainObject = (val) => {
|
|
|
90306
90568
|
return (
|
|
90307
90569
|
(prototype === null ||
|
|
90308
90570
|
prototype === Object.prototype ||
|
|
90309
|
-
|
|
90310
|
-
|
|
90311
|
-
|
|
90571
|
+
getPrototypeOf(prototype) === null) &&
|
|
90572
|
+
// Treat any genuine (non-Object.prototype-polluted) Symbol.toStringTag or
|
|
90573
|
+
// Symbol.iterator as evidence the value is a tagged/iterable type rather
|
|
90574
|
+
// than a plain object, while ignoring keys injected onto Object.prototype.
|
|
90575
|
+
!hasOwnInPrototypeChain(val, toStringTag) &&
|
|
90576
|
+
!hasOwnInPrototypeChain(val, iterator)
|
|
90312
90577
|
);
|
|
90313
90578
|
};
|
|
90314
90579
|
|
|
@@ -90835,13 +91100,6 @@ const toCamelCase = (str) => {
|
|
|
90835
91100
|
});
|
|
90836
91101
|
};
|
|
90837
91102
|
|
|
90838
|
-
/* Creating a function that will check if an object has a property. */
|
|
90839
|
-
const hasOwnProperty = (
|
|
90840
|
-
({ hasOwnProperty }) =>
|
|
90841
|
-
(obj, prop) =>
|
|
90842
|
-
hasOwnProperty.call(obj, prop)
|
|
90843
|
-
)(Object.prototype);
|
|
90844
|
-
|
|
90845
91103
|
const { propertyIsEnumerable } = Object.prototype;
|
|
90846
91104
|
|
|
90847
91105
|
/**
|
|
@@ -91055,6 +91313,20 @@ const asap =
|
|
|
91055
91313
|
|
|
91056
91314
|
const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
|
|
91057
91315
|
|
|
91316
|
+
/**
|
|
91317
|
+
* Determine if a value is iterable via an iterator that is NOT sourced solely
|
|
91318
|
+
* from a polluted Object.prototype. Use this instead of `isIterable` whenever
|
|
91319
|
+
* the iterable comes from untrusted input (e.g. user-supplied header sources),
|
|
91320
|
+
* so `Object.prototype[Symbol.iterator] = ...` cannot turn an ordinary object
|
|
91321
|
+
* into an attacker-controlled entries iterator.
|
|
91322
|
+
*
|
|
91323
|
+
* @param {*} thing The value to test
|
|
91324
|
+
*
|
|
91325
|
+
* @returns {boolean} True if value has a non-polluted iterator
|
|
91326
|
+
*/
|
|
91327
|
+
const isSafeIterable = (thing) =>
|
|
91328
|
+
thing != null && hasOwnInPrototypeChain(thing, iterator) && isIterable(thing);
|
|
91329
|
+
|
|
91058
91330
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
|
|
91059
91331
|
isArray,
|
|
91060
91332
|
isArrayBuffer,
|
|
@@ -91099,6 +91371,8 @@ const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
|
|
|
91099
91371
|
isHTMLForm,
|
|
91100
91372
|
hasOwnProperty,
|
|
91101
91373
|
hasOwnProp: hasOwnProperty, // an alias to avoid ESLint no-prototype-builtins detection
|
|
91374
|
+
hasOwnInPrototypeChain,
|
|
91375
|
+
getSafeProp,
|
|
91102
91376
|
reduceDescriptors,
|
|
91103
91377
|
freezeMethods,
|
|
91104
91378
|
toObjectSet,
|
|
@@ -91115,6 +91389,7 @@ const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
|
|
|
91115
91389
|
setImmediate: _setImmediate,
|
|
91116
91390
|
asap,
|
|
91117
91391
|
isIterable,
|
|
91392
|
+
isSafeIterable,
|
|
91118
91393
|
});
|
|
91119
91394
|
|
|
91120
91395
|
|
|
@@ -91300,9 +91575,11 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
91300
91575
|
/* harmony import */ var _util_plugins_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(51982);
|
|
91301
91576
|
/* harmony import */ var _errors_UnmatchedBundleStrategyError_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(59135);
|
|
91302
91577
|
/* harmony import */ var _errors_BundleError_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(89693);
|
|
91303
|
-
/* harmony import */ var
|
|
91304
|
-
/* harmony import */ var
|
|
91305
|
-
/* harmony import */ var
|
|
91578
|
+
/* harmony import */ var _errors_UnresolvableReferenceError_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(34968);
|
|
91579
|
+
/* harmony import */ var _parse_index_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(85533);
|
|
91580
|
+
/* harmony import */ var _options_util_mjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(7778);
|
|
91581
|
+
/* harmony import */ var _util_url_mjs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(18917);
|
|
91582
|
+
|
|
91306
91583
|
|
|
91307
91584
|
|
|
91308
91585
|
|
|
@@ -91318,8 +91595,8 @@ const bundle = async (uri, options) => {
|
|
|
91318
91595
|
const {
|
|
91319
91596
|
refSet
|
|
91320
91597
|
} = options.bundle;
|
|
91321
|
-
const sanitizedURI =
|
|
91322
|
-
const mergedOptions = (0,
|
|
91598
|
+
const sanitizedURI = _util_url_mjs__WEBPACK_IMPORTED_MODULE_9__.sanitize(uri);
|
|
91599
|
+
const mergedOptions = (0,_options_util_mjs__WEBPACK_IMPORTED_MODULE_8__.merge)(options, {
|
|
91323
91600
|
resolve: {
|
|
91324
91601
|
baseURI: sanitizedURI
|
|
91325
91602
|
}
|
|
@@ -91333,7 +91610,7 @@ const bundle = async (uri, options) => {
|
|
|
91333
91610
|
value: parseResult
|
|
91334
91611
|
} = refSet.find((0,ramda__WEBPACK_IMPORTED_MODULE_1__["default"])(sanitizedURI, 'uri')));
|
|
91335
91612
|
} else {
|
|
91336
|
-
parseResult = await (0,
|
|
91613
|
+
parseResult = await (0,_parse_index_mjs__WEBPACK_IMPORTED_MODULE_7__["default"])(uri, mergedOptions);
|
|
91337
91614
|
}
|
|
91338
91615
|
const file = new _File_mjs__WEBPACK_IMPORTED_MODULE_2__["default"]({
|
|
91339
91616
|
uri: mergedOptions.resolve.baseURI,
|
|
@@ -91352,6 +91629,11 @@ const bundle = async (uri, options) => {
|
|
|
91352
91629
|
} = await _util_plugins_mjs__WEBPACK_IMPORTED_MODULE_3__.run('bundle', [file, mergedOptions], bundleStrategies);
|
|
91353
91630
|
return result;
|
|
91354
91631
|
} catch (error) {
|
|
91632
|
+
// pass through errors that are already part of the bundle/resolution
|
|
91633
|
+
// taxonomy rather than nesting them inside another BundleError
|
|
91634
|
+
if (error instanceof _errors_BundleError_mjs__WEBPACK_IMPORTED_MODULE_5__["default"] || error instanceof _errors_UnresolvableReferenceError_mjs__WEBPACK_IMPORTED_MODULE_6__["default"]) {
|
|
91635
|
+
throw error;
|
|
91636
|
+
}
|
|
91355
91637
|
throw new _errors_BundleError_mjs__WEBPACK_IMPORTED_MODULE_5__["default"](`Error while bundling file "${file.uri}"`, {
|
|
91356
91638
|
cause: error
|
|
91357
91639
|
});
|
|
@@ -91388,6 +91670,793 @@ class BundleStrategy {
|
|
|
91388
91670
|
|
|
91389
91671
|
/***/ },
|
|
91390
91672
|
|
|
91673
|
+
/***/ 5138
|
|
91674
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
91675
|
+
|
|
91676
|
+
"use strict";
|
|
91677
|
+
__webpack_require__.r(__webpack_exports__);
|
|
91678
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
91679
|
+
/* harmony export */ OpenAPI3_0BundleVisitor: () => (/* reexport safe */ _visitor_mjs__WEBPACK_IMPORTED_MODULE_7__["default"]),
|
|
91680
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
91681
|
+
/* harmony export */ });
|
|
91682
|
+
/* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(12111);
|
|
91683
|
+
/* harmony import */ var _speclynx_apidom_traverse__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(80796);
|
|
91684
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(43151);
|
|
91685
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(32131);
|
|
91686
|
+
/* harmony import */ var _Reference_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(82302);
|
|
91687
|
+
/* harmony import */ var _ReferenceSet_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(88526);
|
|
91688
|
+
/* harmony import */ var _BundleStrategy_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(73723);
|
|
91689
|
+
/* harmony import */ var _visitor_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(98968);
|
|
91690
|
+
|
|
91691
|
+
|
|
91692
|
+
|
|
91693
|
+
|
|
91694
|
+
|
|
91695
|
+
|
|
91696
|
+
|
|
91697
|
+
/**
|
|
91698
|
+
* @public
|
|
91699
|
+
*/
|
|
91700
|
+
/**
|
|
91701
|
+
* @public
|
|
91702
|
+
*/
|
|
91703
|
+
class OpenAPI3_0BundleStrategy extends _BundleStrategy_mjs__WEBPACK_IMPORTED_MODULE_6__["default"] {
|
|
91704
|
+
constructor(options) {
|
|
91705
|
+
super({
|
|
91706
|
+
...(options ?? {}),
|
|
91707
|
+
name: 'openapi-3-0'
|
|
91708
|
+
});
|
|
91709
|
+
}
|
|
91710
|
+
canBundle(file) {
|
|
91711
|
+
// assert by media type
|
|
91712
|
+
if (file.mediaType !== 'text/plain') {
|
|
91713
|
+
return _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_2__["default"].includes(file.mediaType);
|
|
91714
|
+
}
|
|
91715
|
+
|
|
91716
|
+
// assert by inspecting ApiDOM
|
|
91717
|
+
return (0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_3__.isOpenApi3_0Element)(file.parseResult?.result);
|
|
91718
|
+
}
|
|
91719
|
+
async bundle(file, options) {
|
|
91720
|
+
const immutableRefSet = options.bundle.refSet ?? new _ReferenceSet_mjs__WEBPACK_IMPORTED_MODULE_5__["default"]();
|
|
91721
|
+
const mutableRefSet = new _ReferenceSet_mjs__WEBPACK_IMPORTED_MODULE_5__["default"]();
|
|
91722
|
+
let refSet = immutableRefSet;
|
|
91723
|
+
let reference;
|
|
91724
|
+
|
|
91725
|
+
// determine the initial reference
|
|
91726
|
+
if (!immutableRefSet.has(file.uri)) {
|
|
91727
|
+
reference = new _Reference_mjs__WEBPACK_IMPORTED_MODULE_4__["default"]({
|
|
91728
|
+
uri: file.uri,
|
|
91729
|
+
value: file.parseResult
|
|
91730
|
+
});
|
|
91731
|
+
immutableRefSet.add(reference);
|
|
91732
|
+
} else {
|
|
91733
|
+
// pre-computed refSet was provided as configuration option
|
|
91734
|
+
reference = immutableRefSet.find(ref => ref.uri === file.uri);
|
|
91735
|
+
}
|
|
91736
|
+
|
|
91737
|
+
/**
|
|
91738
|
+
* Clone refSet due the bundling process being mutable.
|
|
91739
|
+
* We don't want to mutate the original refSet and the references.
|
|
91740
|
+
*/
|
|
91741
|
+
if (options.bundle.immutable) {
|
|
91742
|
+
immutableRefSet.refs.map(ref => new _Reference_mjs__WEBPACK_IMPORTED_MODULE_4__["default"]({
|
|
91743
|
+
...ref,
|
|
91744
|
+
value: (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_0__.cloneDeep)(ref.value)
|
|
91745
|
+
})).forEach(ref => mutableRefSet.add(ref));
|
|
91746
|
+
reference = mutableRefSet.find(ref => ref.uri === file.uri);
|
|
91747
|
+
refSet = mutableRefSet;
|
|
91748
|
+
}
|
|
91749
|
+
const visitor = new _visitor_mjs__WEBPACK_IMPORTED_MODULE_7__["default"]({
|
|
91750
|
+
reference: reference,
|
|
91751
|
+
options
|
|
91752
|
+
});
|
|
91753
|
+
await (0,_speclynx_apidom_traverse__WEBPACK_IMPORTED_MODULE_1__.traverseAsync)(refSet.rootRef.value, visitor, {
|
|
91754
|
+
mutable: true
|
|
91755
|
+
});
|
|
91756
|
+
const parseResult = reference.value;
|
|
91757
|
+
|
|
91758
|
+
/**
|
|
91759
|
+
* Release all memory if this refSet was not provided as a configuration option.
|
|
91760
|
+
* If provided as configuration option, then provider is responsible for cleanup.
|
|
91761
|
+
*/
|
|
91762
|
+
if (options.bundle.refSet === null) {
|
|
91763
|
+
immutableRefSet.clean();
|
|
91764
|
+
}
|
|
91765
|
+
mutableRefSet.clean();
|
|
91766
|
+
return parseResult;
|
|
91767
|
+
}
|
|
91768
|
+
}
|
|
91769
|
+
|
|
91770
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (OpenAPI3_0BundleStrategy);
|
|
91771
|
+
|
|
91772
|
+
/***/ },
|
|
91773
|
+
|
|
91774
|
+
/***/ 98968
|
|
91775
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
91776
|
+
|
|
91777
|
+
"use strict";
|
|
91778
|
+
__webpack_require__.r(__webpack_exports__);
|
|
91779
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
91780
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
91781
|
+
/* harmony export */ });
|
|
91782
|
+
/* harmony import */ var ramda__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6352);
|
|
91783
|
+
/* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25162);
|
|
91784
|
+
/* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(12111);
|
|
91785
|
+
/* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(97071);
|
|
91786
|
+
/* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(84660);
|
|
91787
|
+
/* harmony import */ var _speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(37205);
|
|
91788
|
+
/* harmony import */ var _speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(44673);
|
|
91789
|
+
/* harmony import */ var _speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(16280);
|
|
91790
|
+
/* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(44641);
|
|
91791
|
+
/* harmony import */ var _speclynx_apidom_traverse__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(80796);
|
|
91792
|
+
/* harmony import */ var _speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(12020);
|
|
91793
|
+
/* harmony import */ var _speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(61198);
|
|
91794
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(30609);
|
|
91795
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(64708);
|
|
91796
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(32131);
|
|
91797
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(21314);
|
|
91798
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(29881);
|
|
91799
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(23806);
|
|
91800
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(23031);
|
|
91801
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(63842);
|
|
91802
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(87455);
|
|
91803
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(55122);
|
|
91804
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(71117);
|
|
91805
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(72257);
|
|
91806
|
+
/* harmony import */ var _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(69511);
|
|
91807
|
+
/* harmony import */ var _errors_BundleError_mjs__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(89693);
|
|
91808
|
+
/* harmony import */ var _errors_UnresolvableReferenceError_mjs__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(34968);
|
|
91809
|
+
/* harmony import */ var _errors_MaximumBundleDepthError_mjs__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(55086);
|
|
91810
|
+
/* harmony import */ var _errors_MaximumResolveDepthError_mjs__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(10476);
|
|
91811
|
+
/* harmony import */ var _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(18917);
|
|
91812
|
+
/* harmony import */ var _parse_index_mjs__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(85533);
|
|
91813
|
+
/* harmony import */ var _Reference_mjs__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(82302);
|
|
91814
|
+
/* harmony import */ var _util_mjs__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(78814);
|
|
91815
|
+
|
|
91816
|
+
|
|
91817
|
+
|
|
91818
|
+
|
|
91819
|
+
|
|
91820
|
+
|
|
91821
|
+
|
|
91822
|
+
|
|
91823
|
+
|
|
91824
|
+
|
|
91825
|
+
|
|
91826
|
+
|
|
91827
|
+
|
|
91828
|
+
|
|
91829
|
+
|
|
91830
|
+
/**
|
|
91831
|
+
* Maps the `referenced-element` meta value (set during refraction) to the
|
|
91832
|
+
* Components Object field where the referenced element should be hoisted.
|
|
91833
|
+
* Field names are sourced from the Components Object fixed fields so they
|
|
91834
|
+
* cannot drift from the namespace definition.
|
|
91835
|
+
*/
|
|
91836
|
+
const cf = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_5__.fixedFields)(_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_12__["default"], {
|
|
91837
|
+
indexed: true
|
|
91838
|
+
});
|
|
91839
|
+
const componentFieldByReferencedElement = {
|
|
91840
|
+
schema: cf.schemas.name,
|
|
91841
|
+
response: cf.responses.name,
|
|
91842
|
+
parameter: cf.parameters.name,
|
|
91843
|
+
example: cf.examples.name,
|
|
91844
|
+
requestBody: cf.requestBodies.name,
|
|
91845
|
+
header: cf.headers.name,
|
|
91846
|
+
securityScheme: cf.securitySchemes.name,
|
|
91847
|
+
link: cf.links.name,
|
|
91848
|
+
callback: cf.callbacks.name
|
|
91849
|
+
};
|
|
91850
|
+
|
|
91851
|
+
/**
|
|
91852
|
+
* Maps a Components Object field to the named-content element the namespace
|
|
91853
|
+
* uses for it, so a bundle-created field matches a parsed/refracted one
|
|
91854
|
+
* (e.g. carries the `components-schemas` class) rather than being a generic
|
|
91855
|
+
* object.
|
|
91856
|
+
*/
|
|
91857
|
+
const componentFieldElementByField = {
|
|
91858
|
+
[cf.schemas.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_23__["default"],
|
|
91859
|
+
[cf.responses.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_22__["default"],
|
|
91860
|
+
[cf.parameters.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_20__["default"],
|
|
91861
|
+
[cf.examples.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_17__["default"],
|
|
91862
|
+
[cf.requestBodies.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_21__["default"],
|
|
91863
|
+
[cf.headers.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_18__["default"],
|
|
91864
|
+
[cf.securitySchemes.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_24__["default"],
|
|
91865
|
+
[cf.links.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_19__["default"],
|
|
91866
|
+
[cf.callbacks.name]: _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_16__["default"]
|
|
91867
|
+
};
|
|
91868
|
+
|
|
91869
|
+
/**
|
|
91870
|
+
* @public
|
|
91871
|
+
*/
|
|
91872
|
+
|
|
91873
|
+
/**
|
|
91874
|
+
* @public
|
|
91875
|
+
*/
|
|
91876
|
+
class OpenAPI3_0BundleVisitor {
|
|
91877
|
+
reference;
|
|
91878
|
+
options;
|
|
91879
|
+
|
|
91880
|
+
/**
|
|
91881
|
+
* The base URI (without hash) of the entry document. A reference is
|
|
91882
|
+
* considered internal when it resolves to this URI and external otherwise.
|
|
91883
|
+
* Derived from the shared refSet's root reference.
|
|
91884
|
+
*/
|
|
91885
|
+
get entryURI() {
|
|
91886
|
+
return _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.stripHash(this.reference.refSet?.rootRef?.uri ?? '');
|
|
91887
|
+
}
|
|
91888
|
+
|
|
91889
|
+
/**
|
|
91890
|
+
* The entry parse result. Derived from the shared refSet's root reference.
|
|
91891
|
+
*/
|
|
91892
|
+
get entryParseResult() {
|
|
91893
|
+
return this.reference.refSet.rootRef.value;
|
|
91894
|
+
}
|
|
91895
|
+
|
|
91896
|
+
/**
|
|
91897
|
+
* The entry document element. Hoisted external fragments are placed into its
|
|
91898
|
+
* `components` object. The `canBundle` guard guarantees it is an
|
|
91899
|
+
* OpenApi3_0Element.
|
|
91900
|
+
*/
|
|
91901
|
+
get entryResult() {
|
|
91902
|
+
return this.entryParseResult.result;
|
|
91903
|
+
}
|
|
91904
|
+
|
|
91905
|
+
/**
|
|
91906
|
+
* Shared across the entry document and every external document visitor.
|
|
91907
|
+
* Guarantees each external fragment is hoisted exactly once and gives us a
|
|
91908
|
+
* stable internal pointer to rewrite every referencing element to.
|
|
91909
|
+
*/
|
|
91910
|
+
assignments;
|
|
91911
|
+
|
|
91912
|
+
/**
|
|
91913
|
+
* Component names already reserved per Components Object field. Reserved
|
|
91914
|
+
* before recursion so collision suffixing (`Pet`, `Pet-2`, ...) accounts for
|
|
91915
|
+
* components that are still being bundled.
|
|
91916
|
+
*/
|
|
91917
|
+
reservedNames;
|
|
91918
|
+
|
|
91919
|
+
/**
|
|
91920
|
+
* Caches refracted fragments keyed by source element and target element type.
|
|
91921
|
+
* The type is part of the key because the same source can be refracted into
|
|
91922
|
+
* different semantic elements depending on the referencing context (e.g. a
|
|
91923
|
+
* generic object referenced once as a Parameter and once as a Response).
|
|
91924
|
+
*/
|
|
91925
|
+
refractCache;
|
|
91926
|
+
|
|
91927
|
+
/**
|
|
91928
|
+
* Canonical URIs of Path Item Objects currently being inlined. Path Items
|
|
91929
|
+
* are not hoisted into Components Object (no `components.pathItems` in
|
|
91930
|
+
* OpenAPI 3.0), so the `assignments` map can't break their cycles. This
|
|
91931
|
+
* stack guards against circular external Path Item references.
|
|
91932
|
+
*/
|
|
91933
|
+
inlineStack;
|
|
91934
|
+
constructor({
|
|
91935
|
+
reference,
|
|
91936
|
+
options,
|
|
91937
|
+
assignments = new Map(),
|
|
91938
|
+
reservedNames = new Map(),
|
|
91939
|
+
refractCache = new WeakMap(),
|
|
91940
|
+
inlineStack = new Set()
|
|
91941
|
+
}) {
|
|
91942
|
+
this.reference = reference;
|
|
91943
|
+
this.options = options;
|
|
91944
|
+
this.inlineStack = inlineStack;
|
|
91945
|
+
this.assignments = assignments;
|
|
91946
|
+
this.reservedNames = reservedNames;
|
|
91947
|
+
this.refractCache = refractCache;
|
|
91948
|
+
}
|
|
91949
|
+
getRefracted(source, type) {
|
|
91950
|
+
return this.refractCache.get(source)?.get(type);
|
|
91951
|
+
}
|
|
91952
|
+
setRefracted(source, type, refracted) {
|
|
91953
|
+
let byType = this.refractCache.get(source);
|
|
91954
|
+
if (byType === undefined) {
|
|
91955
|
+
byType = new Map();
|
|
91956
|
+
this.refractCache.set(source, byType);
|
|
91957
|
+
}
|
|
91958
|
+
byType.set(type, refracted);
|
|
91959
|
+
}
|
|
91960
|
+
toBaseURI(uri) {
|
|
91961
|
+
return _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.resolve(this.reference.uri, _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.sanitize(_util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.stripHash(uri)));
|
|
91962
|
+
}
|
|
91963
|
+
async toReference(uri) {
|
|
91964
|
+
// detect maximum depth of resolution
|
|
91965
|
+
if (this.reference.depth >= this.options.resolve.maxDepth) {
|
|
91966
|
+
throw new _errors_MaximumResolveDepthError_mjs__WEBPACK_IMPORTED_MODULE_28__["default"](`Maximum resolution depth of ${this.options.resolve.maxDepth} has been exceeded by file "${this.reference.uri}"`, {
|
|
91967
|
+
maxDepth: this.options.resolve.maxDepth,
|
|
91968
|
+
uri: this.reference.uri
|
|
91969
|
+
});
|
|
91970
|
+
}
|
|
91971
|
+
const baseURI = this.toBaseURI(uri);
|
|
91972
|
+
const {
|
|
91973
|
+
refSet
|
|
91974
|
+
} = this.reference;
|
|
91975
|
+
|
|
91976
|
+
// we've already processed this Reference in past
|
|
91977
|
+
if (refSet.has(baseURI)) {
|
|
91978
|
+
return refSet.find((0,ramda__WEBPACK_IMPORTED_MODULE_0__["default"])(baseURI, 'uri'));
|
|
91979
|
+
}
|
|
91980
|
+
const parseResult = await (0,_parse_index_mjs__WEBPACK_IMPORTED_MODULE_30__["default"])(_util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.unsanitize(baseURI), {
|
|
91981
|
+
...this.options,
|
|
91982
|
+
parse: {
|
|
91983
|
+
...this.options.parse,
|
|
91984
|
+
mediaType: 'text/plain'
|
|
91985
|
+
}
|
|
91986
|
+
});
|
|
91987
|
+
const reference = new _Reference_mjs__WEBPACK_IMPORTED_MODULE_31__["default"]({
|
|
91988
|
+
uri: baseURI,
|
|
91989
|
+
value: parseResult,
|
|
91990
|
+
depth: this.reference.depth + 1
|
|
91991
|
+
});
|
|
91992
|
+
refSet.add(reference);
|
|
91993
|
+
return reference;
|
|
91994
|
+
}
|
|
91995
|
+
|
|
91996
|
+
/**
|
|
91997
|
+
* Normalizes a self-file reference (e.g. `./root.json#/components/schemas/Pet`)
|
|
91998
|
+
* to a bare fragment (`#/components/schemas/Pet`) so the bundled document stays
|
|
91999
|
+
* transferable. Bare fragments are returned unchanged.
|
|
92000
|
+
*/
|
|
92001
|
+
normalizeSelfFileRef(ref) {
|
|
92002
|
+
return ref.startsWith('#') ? ref : _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.getHash(ref);
|
|
92003
|
+
}
|
|
92004
|
+
|
|
92005
|
+
/**
|
|
92006
|
+
* Handles an error according to the `bundle.continueOnError` option.
|
|
92007
|
+
*
|
|
92008
|
+
* For new errors: wraps in UnresolvableReferenceError with structured
|
|
92009
|
+
* context. For errors already wrapped by a nested visitor: prepends the
|
|
92010
|
+
* current hop to the trace.
|
|
92011
|
+
*
|
|
92012
|
+
* Inner/intermediate visitors always throw to let the trace accumulate. Only
|
|
92013
|
+
* the entry document visitor respects continueOnError (callback/swallow/throw).
|
|
92014
|
+
*/
|
|
92015
|
+
handleError(message, error, referencingElement, refFieldName, refFieldValue, visitorPath) {
|
|
92016
|
+
// a collision reported as `error` is a deliberate hard stop with no
|
|
92017
|
+
// resolution-failure analog, so pass it through unchanged. A maxDepth
|
|
92018
|
+
// breach (MaximumBundleDepthError, which also extends BundleError) is a
|
|
92019
|
+
// resolution failure and flows through below — wrapped and subject to
|
|
92020
|
+
// continueOnError, like dereferencing.
|
|
92021
|
+
if (error instanceof _errors_BundleError_mjs__WEBPACK_IMPORTED_MODULE_25__["default"] && !(error instanceof _errors_MaximumBundleDepthError_mjs__WEBPACK_IMPORTED_MODULE_27__["default"])) {
|
|
92022
|
+
throw error;
|
|
92023
|
+
}
|
|
92024
|
+
const {
|
|
92025
|
+
continueOnError
|
|
92026
|
+
} = this.options.bundle;
|
|
92027
|
+
const isEntryDocument = _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.stripHash(this.reference.refSet?.rootRef?.uri ?? '') === this.reference.uri;
|
|
92028
|
+
const uri = this.reference.uri;
|
|
92029
|
+
const type = referencingElement.element;
|
|
92030
|
+
const codeFrame = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_7__["default"])(referencingElement);
|
|
92031
|
+
const location = visitorPath.formatPath();
|
|
92032
|
+
const hop = {
|
|
92033
|
+
uri,
|
|
92034
|
+
type,
|
|
92035
|
+
refFieldName,
|
|
92036
|
+
refFieldValue,
|
|
92037
|
+
location,
|
|
92038
|
+
codeFrame
|
|
92039
|
+
};
|
|
92040
|
+
let unresolvedError;
|
|
92041
|
+
if (error instanceof _errors_UnresolvableReferenceError_mjs__WEBPACK_IMPORTED_MODULE_26__["default"]) {
|
|
92042
|
+
// @ts-ignore
|
|
92043
|
+
error.trace = [hop, ...error.trace];
|
|
92044
|
+
unresolvedError = error;
|
|
92045
|
+
} else {
|
|
92046
|
+
unresolvedError = new _errors_UnresolvableReferenceError_mjs__WEBPACK_IMPORTED_MODULE_26__["default"](message, {
|
|
92047
|
+
cause: error,
|
|
92048
|
+
type,
|
|
92049
|
+
uri,
|
|
92050
|
+
location,
|
|
92051
|
+
codeFrame,
|
|
92052
|
+
refFieldName,
|
|
92053
|
+
refFieldValue,
|
|
92054
|
+
trace: []
|
|
92055
|
+
});
|
|
92056
|
+
}
|
|
92057
|
+
if (!isEntryDocument || continueOnError === false) throw unresolvedError;
|
|
92058
|
+
if (typeof continueOnError === 'function') continueOnError(unresolvedError);
|
|
92059
|
+
}
|
|
92060
|
+
|
|
92061
|
+
/**
|
|
92062
|
+
* Lazily creates the Components Object (and the requested field within it)
|
|
92063
|
+
* on the entry document, returning the field where a fragment is hoisted.
|
|
92064
|
+
*/
|
|
92065
|
+
ensureComponentsField(field) {
|
|
92066
|
+
const entryResult = this.entryResult;
|
|
92067
|
+
let components = entryResult.components;
|
|
92068
|
+
if (!(0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isObjectElement)(components)) {
|
|
92069
|
+
components = new _speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_12__["default"]();
|
|
92070
|
+
entryResult.components = components;
|
|
92071
|
+
}
|
|
92072
|
+
let fieldElement = components.get(field);
|
|
92073
|
+
if (!(0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isObjectElement)(fieldElement)) {
|
|
92074
|
+
const FieldElement = componentFieldElementByField[field] ?? _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_3__["default"];
|
|
92075
|
+
fieldElement = new FieldElement();
|
|
92076
|
+
components.set(field, fieldElement);
|
|
92077
|
+
}
|
|
92078
|
+
return fieldElement;
|
|
92079
|
+
}
|
|
92080
|
+
|
|
92081
|
+
/**
|
|
92082
|
+
* Derives a component name from the referenced JSON Pointer's last token,
|
|
92083
|
+
* falling back to the referenced file's basename.
|
|
92084
|
+
*/
|
|
92085
|
+
basenameOf(jsonPointer, baseURI) {
|
|
92086
|
+
const tokens = (0,_speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_11__.parse)(jsonPointer).tree;
|
|
92087
|
+
let candidate = tokens.length > 0 ? tokens[tokens.length - 1] : '';
|
|
92088
|
+
if (candidate === '') {
|
|
92089
|
+
const lastSlash = baseURI.lastIndexOf('/');
|
|
92090
|
+
const lastDot = baseURI.lastIndexOf('.');
|
|
92091
|
+
const fileName = baseURI.slice(lastSlash + 1);
|
|
92092
|
+
// strip the extension only when the last dot belongs to the file name
|
|
92093
|
+
candidate = lastDot > lastSlash ? baseURI.slice(lastSlash + 1, lastDot) : fileName;
|
|
92094
|
+
}
|
|
92095
|
+
if (candidate === '') candidate = 'Schema';
|
|
92096
|
+
return candidate;
|
|
92097
|
+
}
|
|
92098
|
+
|
|
92099
|
+
/**
|
|
92100
|
+
* Computes the base component name (before collision suffixing) according to
|
|
92101
|
+
* the configured naming strategy.
|
|
92102
|
+
*/
|
|
92103
|
+
baseName(element, field, jsonPointer, baseURI) {
|
|
92104
|
+
// strategy specific options take precedence over the top-level bundle options
|
|
92105
|
+
const componentNamesStrategy = this.options.bundle.strategyOpts['openapi-3-0']?.componentNamesStrategy ?? this.options.bundle.componentNamesStrategy;
|
|
92106
|
+
if (typeof componentNamesStrategy === 'function') {
|
|
92107
|
+
const resolved = componentNamesStrategy({
|
|
92108
|
+
element,
|
|
92109
|
+
field,
|
|
92110
|
+
jsonPointer,
|
|
92111
|
+
baseURI
|
|
92112
|
+
});
|
|
92113
|
+
if (typeof resolved === 'string' && resolved !== '') {
|
|
92114
|
+
return resolved;
|
|
92115
|
+
}
|
|
92116
|
+
return this.basenameOf(jsonPointer, baseURI);
|
|
92117
|
+
}
|
|
92118
|
+
if (componentNamesStrategy === 'title') {
|
|
92119
|
+
const title = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isObjectElement)(element) ? (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(element.get('title')) : undefined;
|
|
92120
|
+
if (typeof title === 'string' && title.trim() !== '') {
|
|
92121
|
+
const name = (0,_util_mjs__WEBPACK_IMPORTED_MODULE_32__.sanitizeComponentName)((0,_util_mjs__WEBPACK_IMPORTED_MODULE_32__.toPascalCase)(title));
|
|
92122
|
+
if (name !== '') return name;
|
|
92123
|
+
}
|
|
92124
|
+
// fall back to basename when no usable title is present
|
|
92125
|
+
}
|
|
92126
|
+
return this.basenameOf(jsonPointer, baseURI);
|
|
92127
|
+
}
|
|
92128
|
+
|
|
92129
|
+
/**
|
|
92130
|
+
* Computes a collision-free component name within the target field. A name is
|
|
92131
|
+
* taken if it's already placed in components or reserved by a component that
|
|
92132
|
+
* is still being bundled (reserved before recursion).
|
|
92133
|
+
*/
|
|
92134
|
+
uniqueName(candidate, field) {
|
|
92135
|
+
const fieldElement = this.ensureComponentsField(field);
|
|
92136
|
+
const reserved = this.reservedNames.get(field) ?? new Set();
|
|
92137
|
+
return (0,_util_mjs__WEBPACK_IMPORTED_MODULE_32__.uniqueName)(candidate, name => fieldElement.hasKey(name) || reserved.has(name));
|
|
92138
|
+
}
|
|
92139
|
+
async ReferenceElement(path) {
|
|
92140
|
+
const referencingElement = path.node;
|
|
92141
|
+
const $ref = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(referencingElement.$ref);
|
|
92142
|
+
const retrievalURI = this.toBaseURI($ref);
|
|
92143
|
+
const isInternalReference = this.entryURI === retrievalURI;
|
|
92144
|
+
const isExternalReference = !isInternalReference;
|
|
92145
|
+
if (isInternalReference) {
|
|
92146
|
+
// normalize self-file references to a bare fragment so the bundled
|
|
92147
|
+
// document stays transferable; bare fragments are left untouched
|
|
92148
|
+
referencingElement.set('$ref', this.normalizeSelfFileRef($ref));
|
|
92149
|
+
path.skip();
|
|
92150
|
+
return;
|
|
92151
|
+
}
|
|
92152
|
+
|
|
92153
|
+
// honor the resolve.external switch
|
|
92154
|
+
if (!this.options.resolve.external && isExternalReference) {
|
|
92155
|
+
path.skip();
|
|
92156
|
+
return;
|
|
92157
|
+
}
|
|
92158
|
+
const $refBaseURI = _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.resolve(retrievalURI, $ref);
|
|
92159
|
+
const jsonPointer = _speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_11__.URIFragmentIdentifier.fromURIReference($refBaseURI);
|
|
92160
|
+
|
|
92161
|
+
// the target bucket depends on the referencing context, so it's part of the
|
|
92162
|
+
// identity: the same external target referenced as e.g. both a parameter and
|
|
92163
|
+
// a response must be hoisted into both components fields. The refractor sets
|
|
92164
|
+
// `referenced-element` for every Reference Object position; the `schemas`
|
|
92165
|
+
// fallback is a defensive default for the (unexpected) untagged case.
|
|
92166
|
+
const referencedElementType = referencingElement.meta.get('referenced-element');
|
|
92167
|
+
const field = componentFieldByReferencedElement[referencedElementType] ?? componentFieldByReferencedElement.schema;
|
|
92168
|
+
const canonicalKey = `${field}\t${retrievalURI}#${jsonPointer}`;
|
|
92169
|
+
|
|
92170
|
+
// already hoisted (or being hoisted) — just rewrite the pointer.
|
|
92171
|
+
//
|
|
92172
|
+
// this is also how circular references terminate: the assignment is
|
|
92173
|
+
// reserved BEFORE recursing into the fragment (see below), so a reference
|
|
92174
|
+
// that cycles back (directly or indirectly) finds its pointer already
|
|
92175
|
+
// reserved here and is rewritten without recursing. Cycles are deliberately
|
|
92176
|
+
// preserved as internal `$ref`s pointing at each other — that is valid,
|
|
92177
|
+
// serializable output; resolving the cycle (if desired) is dereferencing's
|
|
92178
|
+
// job, not bundling's.
|
|
92179
|
+
if (this.assignments.has(canonicalKey)) {
|
|
92180
|
+
referencingElement.set('$ref', this.assignments.get(canonicalKey));
|
|
92181
|
+
path.skip();
|
|
92182
|
+
return;
|
|
92183
|
+
}
|
|
92184
|
+
try {
|
|
92185
|
+
// detect maximum depth of bundling
|
|
92186
|
+
if (this.reference.depth >= this.options.bundle.maxDepth) {
|
|
92187
|
+
throw new _errors_MaximumBundleDepthError_mjs__WEBPACK_IMPORTED_MODULE_27__["default"](`Maximum bundle depth of "${this.options.bundle.maxDepth}" has been exceeded in file "${this.reference.uri}"`, {
|
|
92188
|
+
maxDepth: this.options.bundle.maxDepth,
|
|
92189
|
+
uri: this.reference.uri
|
|
92190
|
+
});
|
|
92191
|
+
}
|
|
92192
|
+
const reference = await this.toReference($ref);
|
|
92193
|
+
|
|
92194
|
+
// possibly non-semantic fragment
|
|
92195
|
+
let referencedElement = (0,_speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_10__.evaluate)(reference.value.result, jsonPointer);
|
|
92196
|
+
|
|
92197
|
+
// apply semantics to the fragment so nested references become Reference Objects
|
|
92198
|
+
if (referencedElement.element !== referencedElementType && !(0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_14__.isReferenceElement)(referencedElement)) {
|
|
92199
|
+
const cached = this.getRefracted(referencedElement, referencedElementType);
|
|
92200
|
+
if (cached !== undefined) {
|
|
92201
|
+
referencedElement = cached;
|
|
92202
|
+
} else if ((0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_15__.isReferenceLikeElement)(referencedElement)) {
|
|
92203
|
+
const sourceElement = referencedElement;
|
|
92204
|
+
referencedElement = (0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_13__.refractReference)(referencedElement);
|
|
92205
|
+
referencedElement.meta.set('referenced-element', referencedElementType);
|
|
92206
|
+
this.setRefracted(sourceElement, referencedElementType, referencedElement);
|
|
92207
|
+
} else {
|
|
92208
|
+
const sourceElement = referencedElement;
|
|
92209
|
+
referencedElement = (0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_13__["default"])(referencedElement, {
|
|
92210
|
+
element: referencedElementType
|
|
92211
|
+
});
|
|
92212
|
+
this.setRefracted(sourceElement, referencedElementType, referencedElement);
|
|
92213
|
+
}
|
|
92214
|
+
}
|
|
92215
|
+
const preferredName = this.baseName(referencedElement, field, jsonPointer, retrievalURI);
|
|
92216
|
+
const componentName = this.uniqueName(preferredName, field);
|
|
92217
|
+
const internalPointer = `#/components/${field}/${(0,_speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_11__.escape)(componentName)}`;
|
|
92218
|
+
|
|
92219
|
+
// a rename means two distinct targets resolved to the same name; each
|
|
92220
|
+
// keeps its own component (and origin), so report the rename per severity.
|
|
92221
|
+
// strategy specific options take precedence over the top-level bundle options
|
|
92222
|
+
const onComponentNameCollision = this.options.bundle.strategyOpts['openapi-3-0']?.onComponentNameCollision ?? this.options.bundle.onComponentNameCollision;
|
|
92223
|
+
if (componentName !== preferredName && onComponentNameCollision !== 'off') {
|
|
92224
|
+
const message = `Component "${preferredName}" in components/${field} is referenced with the same name but different content. Renamed to "${componentName}".`;
|
|
92225
|
+
if (onComponentNameCollision === 'error') {
|
|
92226
|
+
throw new _errors_BundleError_mjs__WEBPACK_IMPORTED_MODULE_25__["default"](message);
|
|
92227
|
+
}
|
|
92228
|
+
const annotation = new _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_4__["default"](message);
|
|
92229
|
+
annotation.classes.push('warning');
|
|
92230
|
+
annotation.code = 'bundle-component-name-collision';
|
|
92231
|
+
// append (never prepend) so the result element stays ahead of annotations
|
|
92232
|
+
this.entryParseResult.content.push(annotation);
|
|
92233
|
+
}
|
|
92234
|
+
|
|
92235
|
+
// reserve the assignment and component name before recursing so cyclic
|
|
92236
|
+
// references terminate
|
|
92237
|
+
this.assignments.set(canonicalKey, internalPointer);
|
|
92238
|
+
if (!this.reservedNames.has(field)) this.reservedNames.set(field, new Set());
|
|
92239
|
+
this.reservedNames.get(field).add(componentName);
|
|
92240
|
+
|
|
92241
|
+
// own a copy of the fragment and bundle its own external references
|
|
92242
|
+
const hoistedElement = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_2__.cloneDeep)(referencedElement);
|
|
92243
|
+
const visitor = new OpenAPI3_0BundleVisitor({
|
|
92244
|
+
reference,
|
|
92245
|
+
options: this.options,
|
|
92246
|
+
assignments: this.assignments,
|
|
92247
|
+
reservedNames: this.reservedNames,
|
|
92248
|
+
refractCache: this.refractCache,
|
|
92249
|
+
inlineStack: this.inlineStack
|
|
92250
|
+
});
|
|
92251
|
+
const bundledElement = await (0,_speclynx_apidom_traverse__WEBPACK_IMPORTED_MODULE_9__.traverseAsync)(hoistedElement, visitor, {
|
|
92252
|
+
mutable: true
|
|
92253
|
+
});
|
|
92254
|
+
|
|
92255
|
+
// annotate the hoisted fragment with info about its origin
|
|
92256
|
+
if ((0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isElement)(bundledElement)) {
|
|
92257
|
+
bundledElement.meta.set('ref-origin', reference.uri);
|
|
92258
|
+
}
|
|
92259
|
+
|
|
92260
|
+
// place the bundled fragment into the entry document's components
|
|
92261
|
+
this.ensureComponentsField(field).set(componentName, bundledElement);
|
|
92262
|
+
|
|
92263
|
+
// rewrite the referencing element to point at the hoisted fragment
|
|
92264
|
+
referencingElement.set('$ref', internalPointer);
|
|
92265
|
+
path.skip();
|
|
92266
|
+
} catch (error) {
|
|
92267
|
+
this.handleError(`Error while bundling Reference Object. Cannot resolve $ref "${$ref}": ${error.message}`, error, referencingElement, '$ref', $ref, path);
|
|
92268
|
+
path.skip();
|
|
92269
|
+
}
|
|
92270
|
+
}
|
|
92271
|
+
|
|
92272
|
+
/**
|
|
92273
|
+
* Path Item Object is not a Components Object field in OpenAPI 3.0
|
|
92274
|
+
* (unlike 3.1 which has `components.pathItems`). An external Path Item
|
|
92275
|
+
* reference therefore cannot be hoisted; it is inlined in place instead,
|
|
92276
|
+
* after bundling its own external references.
|
|
92277
|
+
*/
|
|
92278
|
+
async PathItemElement(path) {
|
|
92279
|
+
const pathItemElement = path.node;
|
|
92280
|
+
|
|
92281
|
+
// ignore Path Item Objects without a $ref field
|
|
92282
|
+
if (!(0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isStringElement)(pathItemElement.$ref)) {
|
|
92283
|
+
return;
|
|
92284
|
+
}
|
|
92285
|
+
const $ref = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(pathItemElement.$ref);
|
|
92286
|
+
const retrievalURI = this.toBaseURI($ref);
|
|
92287
|
+
const isInternalReference = this.entryURI === retrievalURI;
|
|
92288
|
+
const isExternalReference = !isInternalReference;
|
|
92289
|
+
if (isInternalReference) {
|
|
92290
|
+
// normalize self-file references to a bare fragment so the bundled
|
|
92291
|
+
// document stays transferable; bare fragments are left untouched
|
|
92292
|
+
pathItemElement.set('$ref', this.normalizeSelfFileRef($ref));
|
|
92293
|
+
return;
|
|
92294
|
+
}
|
|
92295
|
+
|
|
92296
|
+
// honor the resolve.external switch
|
|
92297
|
+
if (!this.options.resolve.external && isExternalReference) {
|
|
92298
|
+
return;
|
|
92299
|
+
}
|
|
92300
|
+
const $refBaseURI = _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.resolve(retrievalURI, $ref);
|
|
92301
|
+
const jsonPointer = _speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_11__.URIFragmentIdentifier.fromURIReference($refBaseURI);
|
|
92302
|
+
const canonicalKey = `${retrievalURI}#${jsonPointer}`;
|
|
92303
|
+
|
|
92304
|
+
// a circular external Path Item reference cannot be inlined without
|
|
92305
|
+
// recursing forever; leave the $ref in place to break the cycle
|
|
92306
|
+
if (this.inlineStack.has(canonicalKey)) {
|
|
92307
|
+
return;
|
|
92308
|
+
}
|
|
92309
|
+
try {
|
|
92310
|
+
// detect maximum depth of bundling
|
|
92311
|
+
if (this.reference.depth >= this.options.bundle.maxDepth) {
|
|
92312
|
+
throw new _errors_MaximumBundleDepthError_mjs__WEBPACK_IMPORTED_MODULE_27__["default"](`Maximum bundle depth of "${this.options.bundle.maxDepth}" has been exceeded in file "${this.reference.uri}"`, {
|
|
92313
|
+
maxDepth: this.options.bundle.maxDepth,
|
|
92314
|
+
uri: this.reference.uri
|
|
92315
|
+
});
|
|
92316
|
+
}
|
|
92317
|
+
const reference = await this.toReference($ref);
|
|
92318
|
+
let referencedElement = (0,_speclynx_apidom_json_pointer__WEBPACK_IMPORTED_MODULE_10__.evaluate)(reference.value.result, jsonPointer);
|
|
92319
|
+
|
|
92320
|
+
// apply Path Item semantics to the referenced fragment
|
|
92321
|
+
if (!(0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_14__.isPathItemElement)(referencedElement)) {
|
|
92322
|
+
const cached = this.getRefracted(referencedElement, 'pathItem');
|
|
92323
|
+
if (cached !== undefined) {
|
|
92324
|
+
referencedElement = cached;
|
|
92325
|
+
} else {
|
|
92326
|
+
const sourceElement = referencedElement;
|
|
92327
|
+
referencedElement = (0,_speclynx_apidom_ns_openapi_3_0__WEBPACK_IMPORTED_MODULE_13__.refractPathItem)(referencedElement);
|
|
92328
|
+
this.setRefracted(sourceElement, 'pathItem', referencedElement);
|
|
92329
|
+
}
|
|
92330
|
+
}
|
|
92331
|
+
|
|
92332
|
+
// own a copy and bundle the external references it contains
|
|
92333
|
+
const inlinedElement = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_2__.cloneDeep)(referencedElement);
|
|
92334
|
+
this.inlineStack.add(canonicalKey);
|
|
92335
|
+
const visitor = new OpenAPI3_0BundleVisitor({
|
|
92336
|
+
reference,
|
|
92337
|
+
options: this.options,
|
|
92338
|
+
assignments: this.assignments,
|
|
92339
|
+
reservedNames: this.reservedNames,
|
|
92340
|
+
refractCache: this.refractCache,
|
|
92341
|
+
inlineStack: this.inlineStack
|
|
92342
|
+
});
|
|
92343
|
+
let bundledElement;
|
|
92344
|
+
try {
|
|
92345
|
+
bundledElement = await (0,_speclynx_apidom_traverse__WEBPACK_IMPORTED_MODULE_9__.traverseAsync)(inlinedElement, visitor, {
|
|
92346
|
+
mutable: true
|
|
92347
|
+
});
|
|
92348
|
+
} finally {
|
|
92349
|
+
this.inlineStack.delete(canonicalKey);
|
|
92350
|
+
}
|
|
92351
|
+
|
|
92352
|
+
// merge sibling fields from the referencing Path Item over the referenced
|
|
92353
|
+
// one. The referencing `$ref` is being resolved away and is skipped; the
|
|
92354
|
+
// referenced element keeps its own `$ref` if one survived (i.e. it was
|
|
92355
|
+
// left in place to break a circular external Path Item chain).
|
|
92356
|
+
pathItemElement.forEach((_value, keyElement, item) => {
|
|
92357
|
+
const key = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(keyElement);
|
|
92358
|
+
if (key === '$ref') return;
|
|
92359
|
+
bundledElement.remove(key);
|
|
92360
|
+
bundledElement.content.push(item);
|
|
92361
|
+
});
|
|
92362
|
+
bundledElement.meta.set('ref-origin', reference.uri);
|
|
92363
|
+
path.replaceWith(bundledElement);
|
|
92364
|
+
} catch (error) {
|
|
92365
|
+
this.handleError(`Error while bundling Path Item Object. Cannot resolve $ref "${$ref}": ${error.message}`, error, pathItemElement, '$ref', $ref, path);
|
|
92366
|
+
}
|
|
92367
|
+
}
|
|
92368
|
+
|
|
92369
|
+
/**
|
|
92370
|
+
* Example Object `externalValue` points at arbitrary external content that
|
|
92371
|
+
* has no place in the Components Object. The referenced value is inlined into
|
|
92372
|
+
* the Example's `value` field.
|
|
92373
|
+
*/
|
|
92374
|
+
async ExampleElement(path) {
|
|
92375
|
+
const exampleElement = path.node;
|
|
92376
|
+
|
|
92377
|
+
// ignore Example Objects without an externalValue field
|
|
92378
|
+
if (!(0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isStringElement)(exampleElement.externalValue)) {
|
|
92379
|
+
return;
|
|
92380
|
+
}
|
|
92381
|
+
|
|
92382
|
+
// value and externalValue fields are mutually exclusive
|
|
92383
|
+
if (exampleElement.hasKey('value') && (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isStringElement)(exampleElement.externalValue)) {
|
|
92384
|
+
throw new _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_8__["default"]('ExampleElement value and externalValue fields are mutually exclusive', {
|
|
92385
|
+
value: (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(exampleElement.value),
|
|
92386
|
+
externalValue: (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(exampleElement.externalValue)
|
|
92387
|
+
});
|
|
92388
|
+
}
|
|
92389
|
+
const externalValue = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(exampleElement.externalValue);
|
|
92390
|
+
const retrievalURI = this.toBaseURI(externalValue);
|
|
92391
|
+
const isInternalReference = this.entryURI === retrievalURI;
|
|
92392
|
+
const isExternalReference = !isInternalReference;
|
|
92393
|
+
|
|
92394
|
+
// honor the resolve.external switch
|
|
92395
|
+
if (!this.options.resolve.external && isExternalReference) {
|
|
92396
|
+
return;
|
|
92397
|
+
}
|
|
92398
|
+
try {
|
|
92399
|
+
const reference = await this.toReference(externalValue);
|
|
92400
|
+
const valueElement = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_2__.cloneShallow)(reference.value.result);
|
|
92401
|
+
valueElement.meta.set('ref-origin', reference.uri);
|
|
92402
|
+
const exampleElementCopy = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_2__.cloneShallow)(exampleElement);
|
|
92403
|
+
exampleElementCopy.value = valueElement;
|
|
92404
|
+
exampleElementCopy.remove('externalValue');
|
|
92405
|
+
path.replaceWith(exampleElementCopy);
|
|
92406
|
+
} catch (error) {
|
|
92407
|
+
this.handleError(`Error while bundling Example Object. Cannot resolve externalValue "${externalValue}": ${error.message}`, error, exampleElement, 'externalValue', externalValue, path);
|
|
92408
|
+
}
|
|
92409
|
+
}
|
|
92410
|
+
|
|
92411
|
+
/**
|
|
92412
|
+
* Link Object `operationRef` points at an Operation Object, which has no
|
|
92413
|
+
* Components Object field in OpenAPI 3.0 and therefore cannot be hoisted or
|
|
92414
|
+
* inlined. To keep the link resolvable from the bundled document, an external
|
|
92415
|
+
* `operationRef` is rewritten to its absolute URI. Internal `operationRef`
|
|
92416
|
+
* values and `operationId` links are left untouched.
|
|
92417
|
+
*/
|
|
92418
|
+
async LinkElement(path) {
|
|
92419
|
+
const linkElement = path.node;
|
|
92420
|
+
|
|
92421
|
+
// operationRef and operationId fields are mutually exclusive
|
|
92422
|
+
if ((0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isStringElement)(linkElement.operationRef) && (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isStringElement)(linkElement.operationId)) {
|
|
92423
|
+
throw new _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_8__["default"]('LinkElement operationRef and operationId fields are mutually exclusive', {
|
|
92424
|
+
operationRef: (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(linkElement.operationRef),
|
|
92425
|
+
operationId: (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(linkElement.operationId)
|
|
92426
|
+
});
|
|
92427
|
+
}
|
|
92428
|
+
|
|
92429
|
+
// only external operationRef links need adjusting
|
|
92430
|
+
if (!(0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isStringElement)(linkElement.operationRef)) {
|
|
92431
|
+
return;
|
|
92432
|
+
}
|
|
92433
|
+
const operationRef = (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_6__["default"])(linkElement.operationRef);
|
|
92434
|
+
const retrievalURI = this.toBaseURI(operationRef);
|
|
92435
|
+
const isInternalReference = this.entryURI === retrievalURI;
|
|
92436
|
+
if (isInternalReference) {
|
|
92437
|
+
// normalize self-file operationRef to a bare fragment so the bundled
|
|
92438
|
+
// document stays transferable; bare fragments are left untouched
|
|
92439
|
+
linkElement.set('operationRef', this.normalizeSelfFileRef(operationRef));
|
|
92440
|
+
return;
|
|
92441
|
+
}
|
|
92442
|
+
|
|
92443
|
+
// honor the resolve.external switch
|
|
92444
|
+
if (!this.options.resolve.external) {
|
|
92445
|
+
return;
|
|
92446
|
+
}
|
|
92447
|
+
|
|
92448
|
+
// rewrite to an absolute URI so the link keeps resolving once the document
|
|
92449
|
+
// is treated as self-contained
|
|
92450
|
+
const absoluteURI = _util_url_mjs__WEBPACK_IMPORTED_MODULE_29__.resolve(this.reference.uri, operationRef);
|
|
92451
|
+
if (absoluteURI !== operationRef) {
|
|
92452
|
+
linkElement.set('operationRef', absoluteURI);
|
|
92453
|
+
}
|
|
92454
|
+
}
|
|
92455
|
+
}
|
|
92456
|
+
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (OpenAPI3_0BundleVisitor);
|
|
92457
|
+
|
|
92458
|
+
/***/ },
|
|
92459
|
+
|
|
91391
92460
|
/***/ 58091
|
|
91392
92461
|
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
91393
92462
|
|
|
@@ -91431,54 +92500,100 @@ class OpenAPI3_1BundleStrategy extends _BundleStrategy_mjs__WEBPACK_IMPORTED_MOD
|
|
|
91431
92500
|
|
|
91432
92501
|
/***/ },
|
|
91433
92502
|
|
|
92503
|
+
/***/ 78814
|
|
92504
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
92505
|
+
|
|
92506
|
+
"use strict";
|
|
92507
|
+
__webpack_require__.r(__webpack_exports__);
|
|
92508
|
+
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
92509
|
+
/* harmony export */ sanitizeComponentName: () => (/* binding */ sanitizeComponentName),
|
|
92510
|
+
/* harmony export */ toPascalCase: () => (/* binding */ toPascalCase),
|
|
92511
|
+
/* harmony export */ uniqueName: () => (/* binding */ uniqueName)
|
|
92512
|
+
/* harmony export */ });
|
|
92513
|
+
/**
|
|
92514
|
+
* Upper-cases the first letter of each whitespace-separated word and joins
|
|
92515
|
+
* them, e.g. `pet model` -> `PetModel`.
|
|
92516
|
+
*
|
|
92517
|
+
* @public
|
|
92518
|
+
*/
|
|
92519
|
+
const toPascalCase = value => value.trim().split(/\s+/).map(word => word.replace(/^[a-z]/, char => char.toUpperCase())).join('');
|
|
92520
|
+
|
|
92521
|
+
/**
|
|
92522
|
+
* Replaces characters that are invalid in a Components Object name with `-`,
|
|
92523
|
+
* then collapses repeated separators and trims leading/trailing ones.
|
|
92524
|
+
*
|
|
92525
|
+
* @public
|
|
92526
|
+
*/
|
|
92527
|
+
const sanitizeComponentName = value => value.replace(/[^a-zA-Z0-9.\-_]/g, '-').replace(/-+/g, '-').replace(/^-|-$/g, '');
|
|
92528
|
+
|
|
92529
|
+
/**
|
|
92530
|
+
* Returns a collision-free name by suffixing `-2`, `-3`, ... onto `candidate`
|
|
92531
|
+
* until `isTaken` reports it free. `isTaken` decides what counts as taken
|
|
92532
|
+
* (e.g. names already placed in or reserved for a Components Object field).
|
|
92533
|
+
*
|
|
92534
|
+
* @public
|
|
92535
|
+
*/
|
|
92536
|
+
const uniqueName = (candidate, isTaken) => {
|
|
92537
|
+
if (!isTaken(candidate)) {
|
|
92538
|
+
return candidate;
|
|
92539
|
+
}
|
|
92540
|
+
let counter = 2;
|
|
92541
|
+
while (isTaken(`${candidate}-${counter}`)) {
|
|
92542
|
+
counter += 1;
|
|
92543
|
+
}
|
|
92544
|
+
return `${candidate}-${counter}`;
|
|
92545
|
+
};
|
|
92546
|
+
|
|
92547
|
+
/***/ },
|
|
92548
|
+
|
|
91434
92549
|
/***/ 29807
|
|
91435
92550
|
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
91436
92551
|
|
|
91437
92552
|
"use strict";
|
|
91438
92553
|
__webpack_require__.r(__webpack_exports__);
|
|
91439
92554
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
91440
|
-
/* harmony export */ BundleError: () => (/* reexport safe */
|
|
91441
|
-
/* harmony export */ BundleStrategy: () => (/* reexport safe */
|
|
91442
|
-
/* harmony export */ DereferenceAncestorLineage: () => (/* reexport safe */
|
|
91443
|
-
/* harmony export */ DereferenceError: () => (/* reexport safe */
|
|
91444
|
-
/* harmony export */ DereferenceStrategy: () => (/* reexport safe */
|
|
91445
|
-
/* harmony export */ EvaluationElementIdError: () => (/* reexport safe */
|
|
91446
|
-
/* harmony export */ EvaluationJsonSchema$anchorError: () => (/* reexport safe */
|
|
91447
|
-
/* harmony export */ EvaluationJsonSchemaUriError: () => (/* reexport safe */
|
|
91448
|
-
/* harmony export */ File: () => (/* reexport safe */
|
|
91449
|
-
/* harmony export */ HTTPResolver: () => (/* reexport safe */
|
|
91450
|
-
/* harmony export */ InvalidJsonSchema$anchorError: () => (/* reexport safe */
|
|
91451
|
-
/* harmony export */ JsonSchema$anchorError: () => (/* reexport safe */
|
|
91452
|
-
/* harmony export */ JsonSchemaURIError: () => (/* reexport safe */
|
|
91453
|
-
/* harmony export */ MaximumBundleDepthError: () => (/* reexport safe */
|
|
91454
|
-
/* harmony export */ MaximumDereferenceDepthError: () => (/* reexport safe */
|
|
91455
|
-
/* harmony export */ MaximumResolveDepthError: () => (/* reexport safe */
|
|
91456
|
-
/* harmony export */ ParseError: () => (/* reexport safe */
|
|
91457
|
-
/* harmony export */ Parser: () => (/* reexport safe */
|
|
91458
|
-
/* harmony export */ ParserError: () => (/* reexport safe */
|
|
91459
|
-
/* harmony export */ PluginError: () => (/* reexport safe */
|
|
91460
|
-
/* harmony export */ Reference: () => (/* reexport safe */
|
|
91461
|
-
/* harmony export */ ReferenceSet: () => (/* reexport safe */
|
|
91462
|
-
/* harmony export */ ResolveError: () => (/* reexport safe */
|
|
91463
|
-
/* harmony export */ ResolveStrategy: () => (/* reexport safe */
|
|
91464
|
-
/* harmony export */ Resolver: () => (/* reexport safe */
|
|
91465
|
-
/* harmony export */ ResolverError: () => (/* reexport safe */
|
|
91466
|
-
/* harmony export */ UnmatchedBundleStrategyError: () => (/* reexport safe */
|
|
91467
|
-
/* harmony export */ UnmatchedDereferenceStrategyError: () => (/* reexport safe */
|
|
91468
|
-
/* harmony export */ UnmatchedParserError: () => (/* reexport safe */
|
|
91469
|
-
/* harmony export */ UnmatchedResolveStrategyError: () => (/* reexport safe */
|
|
91470
|
-
/* harmony export */ UnmatchedResolverError: () => (/* reexport safe */
|
|
91471
|
-
/* harmony export */ UnresolvableReferenceError: () => (/* reexport safe */
|
|
91472
|
-
/* harmony export */ bundle: () => (/* reexport safe */
|
|
91473
|
-
/* harmony export */ dereference: () => (/* reexport safe */
|
|
91474
|
-
/* harmony export */ dereferenceApiDOM: () => (/* reexport safe */
|
|
91475
|
-
/* harmony export */ mergeOptions: () => (/* reexport safe */
|
|
91476
|
-
/* harmony export */ options: () => (/* reexport safe */
|
|
91477
|
-
/* harmony export */ parse: () => (/* reexport safe */
|
|
91478
|
-
/* harmony export */ readFile: () => (/* reexport safe */
|
|
91479
|
-
/* harmony export */ resolve: () => (/* reexport safe */
|
|
91480
|
-
/* harmony export */ resolveApiDOM: () => (/* reexport safe */
|
|
91481
|
-
/* harmony export */ url: () => (/* reexport safe */
|
|
92555
|
+
/* harmony export */ BundleError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.BundleError),
|
|
92556
|
+
/* harmony export */ BundleStrategy: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.BundleStrategy),
|
|
92557
|
+
/* harmony export */ DereferenceAncestorLineage: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.DereferenceAncestorLineage),
|
|
92558
|
+
/* harmony export */ DereferenceError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.DereferenceError),
|
|
92559
|
+
/* harmony export */ DereferenceStrategy: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.DereferenceStrategy),
|
|
92560
|
+
/* harmony export */ EvaluationElementIdError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.EvaluationElementIdError),
|
|
92561
|
+
/* harmony export */ EvaluationJsonSchema$anchorError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.EvaluationJsonSchema$anchorError),
|
|
92562
|
+
/* harmony export */ EvaluationJsonSchemaUriError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.EvaluationJsonSchemaUriError),
|
|
92563
|
+
/* harmony export */ File: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.File),
|
|
92564
|
+
/* harmony export */ HTTPResolver: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.HTTPResolver),
|
|
92565
|
+
/* harmony export */ InvalidJsonSchema$anchorError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.InvalidJsonSchema$anchorError),
|
|
92566
|
+
/* harmony export */ JsonSchema$anchorError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.JsonSchema$anchorError),
|
|
92567
|
+
/* harmony export */ JsonSchemaURIError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.JsonSchemaURIError),
|
|
92568
|
+
/* harmony export */ MaximumBundleDepthError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.MaximumBundleDepthError),
|
|
92569
|
+
/* harmony export */ MaximumDereferenceDepthError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.MaximumDereferenceDepthError),
|
|
92570
|
+
/* harmony export */ MaximumResolveDepthError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.MaximumResolveDepthError),
|
|
92571
|
+
/* harmony export */ ParseError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.ParseError),
|
|
92572
|
+
/* harmony export */ Parser: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.Parser),
|
|
92573
|
+
/* harmony export */ ParserError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.ParserError),
|
|
92574
|
+
/* harmony export */ PluginError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.PluginError),
|
|
92575
|
+
/* harmony export */ Reference: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.Reference),
|
|
92576
|
+
/* harmony export */ ReferenceSet: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.ReferenceSet),
|
|
92577
|
+
/* harmony export */ ResolveError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.ResolveError),
|
|
92578
|
+
/* harmony export */ ResolveStrategy: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.ResolveStrategy),
|
|
92579
|
+
/* harmony export */ Resolver: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.Resolver),
|
|
92580
|
+
/* harmony export */ ResolverError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.ResolverError),
|
|
92581
|
+
/* harmony export */ UnmatchedBundleStrategyError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.UnmatchedBundleStrategyError),
|
|
92582
|
+
/* harmony export */ UnmatchedDereferenceStrategyError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.UnmatchedDereferenceStrategyError),
|
|
92583
|
+
/* harmony export */ UnmatchedParserError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.UnmatchedParserError),
|
|
92584
|
+
/* harmony export */ UnmatchedResolveStrategyError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.UnmatchedResolveStrategyError),
|
|
92585
|
+
/* harmony export */ UnmatchedResolverError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.UnmatchedResolverError),
|
|
92586
|
+
/* harmony export */ UnresolvableReferenceError: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.UnresolvableReferenceError),
|
|
92587
|
+
/* harmony export */ bundle: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.bundle),
|
|
92588
|
+
/* harmony export */ dereference: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.dereference),
|
|
92589
|
+
/* harmony export */ dereferenceApiDOM: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.dereferenceApiDOM),
|
|
92590
|
+
/* harmony export */ mergeOptions: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.mergeOptions),
|
|
92591
|
+
/* harmony export */ options: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.options),
|
|
92592
|
+
/* harmony export */ parse: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.parse),
|
|
92593
|
+
/* harmony export */ readFile: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.readFile),
|
|
92594
|
+
/* harmony export */ resolve: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.resolve),
|
|
92595
|
+
/* harmony export */ resolveApiDOM: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.resolveApiDOM),
|
|
92596
|
+
/* harmony export */ url: () => (/* reexport safe */ _index_mjs__WEBPACK_IMPORTED_MODULE_35__.url)
|
|
91482
92597
|
/* harmony export */ });
|
|
91483
92598
|
/* harmony import */ var _resolve_resolvers_file_index_node_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(79948);
|
|
91484
92599
|
/* harmony import */ var _resolve_resolvers_http_axios_index_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(352);
|
|
@@ -91512,9 +92627,11 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
91512
92627
|
/* harmony import */ var _dereference_strategies_asyncapi_2_index_mjs__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(35070);
|
|
91513
92628
|
/* harmony import */ var _dereference_strategies_arazzo_1_index_mjs__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(880);
|
|
91514
92629
|
/* harmony import */ var _dereference_strategies_overlay_1_index_mjs__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(67689);
|
|
91515
|
-
/* harmony import */ var
|
|
91516
|
-
/* harmony import */ var
|
|
91517
|
-
/* harmony import */ var _index_mjs__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(
|
|
92630
|
+
/* harmony import */ var _bundle_strategies_openapi_3_0_index_mjs__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(5138);
|
|
92631
|
+
/* harmony import */ var _bundle_strategies_openapi_3_1_index_mjs__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(58091);
|
|
92632
|
+
/* harmony import */ var _index_mjs__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(30306);
|
|
92633
|
+
/* harmony import */ var _index_mjs__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(37013);
|
|
92634
|
+
|
|
91518
92635
|
|
|
91519
92636
|
|
|
91520
92637
|
|
|
@@ -91549,7 +92666,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
91549
92666
|
|
|
91550
92667
|
|
|
91551
92668
|
|
|
91552
|
-
|
|
92669
|
+
_index_mjs__WEBPACK_IMPORTED_MODULE_34__["default"].parse.parsers = [new _parse_parsers_openapi_json_2_index_mjs__WEBPACK_IMPORTED_MODULE_9__["default"]({
|
|
91553
92670
|
allowEmpty: true,
|
|
91554
92671
|
sourceMap: false
|
|
91555
92672
|
}), new _parse_parsers_openapi_yaml_2_index_mjs__WEBPACK_IMPORTED_MODULE_10__["default"]({
|
|
@@ -91597,14 +92714,14 @@ _index_mjs__WEBPACK_IMPORTED_MODULE_33__["default"].parse.parsers = [new _parse_
|
|
|
91597
92714
|
}), new _parse_parsers_binary_index_node_mjs__WEBPACK_IMPORTED_MODULE_24__["default"]({
|
|
91598
92715
|
allowEmpty: true
|
|
91599
92716
|
})];
|
|
91600
|
-
|
|
92717
|
+
_index_mjs__WEBPACK_IMPORTED_MODULE_34__["default"].resolve.resolvers = [new _resolve_resolvers_file_index_node_mjs__WEBPACK_IMPORTED_MODULE_0__["default"](), new _resolve_resolvers_http_axios_index_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]({
|
|
91601
92718
|
timeout: 5000,
|
|
91602
92719
|
redirects: 5,
|
|
91603
92720
|
withCredentials: false
|
|
91604
92721
|
})];
|
|
91605
|
-
|
|
91606
|
-
|
|
91607
|
-
|
|
92722
|
+
_index_mjs__WEBPACK_IMPORTED_MODULE_34__["default"].resolve.strategies = [new _resolve_strategies_openapi_2_index_mjs__WEBPACK_IMPORTED_MODULE_2__["default"](), new _resolve_strategies_openapi_3_0_index_mjs__WEBPACK_IMPORTED_MODULE_3__["default"](), new _resolve_strategies_openapi_3_1_index_mjs__WEBPACK_IMPORTED_MODULE_4__["default"](), new _resolve_strategies_asyncapi_2_index_mjs__WEBPACK_IMPORTED_MODULE_5__["default"](), new _resolve_strategies_arazzo_1_index_mjs__WEBPACK_IMPORTED_MODULE_6__["default"](), new _resolve_strategies_overlay_1_index_mjs__WEBPACK_IMPORTED_MODULE_7__["default"](), new _resolve_strategies_apidom_index_mjs__WEBPACK_IMPORTED_MODULE_8__["default"]()];
|
|
92723
|
+
_index_mjs__WEBPACK_IMPORTED_MODULE_34__["default"].dereference.strategies = [new _dereference_strategies_openapi_2_index_mjs__WEBPACK_IMPORTED_MODULE_26__["default"](), new _dereference_strategies_openapi_3_0_index_mjs__WEBPACK_IMPORTED_MODULE_27__["default"](), new _dereference_strategies_openapi_3_1_index_mjs__WEBPACK_IMPORTED_MODULE_28__["default"](), new _dereference_strategies_asyncapi_2_index_mjs__WEBPACK_IMPORTED_MODULE_29__["default"](), new _dereference_strategies_arazzo_1_index_mjs__WEBPACK_IMPORTED_MODULE_30__["default"](), new _dereference_strategies_overlay_1_index_mjs__WEBPACK_IMPORTED_MODULE_31__["default"](), new _dereference_strategies_apidom_index_mjs__WEBPACK_IMPORTED_MODULE_25__["default"]()];
|
|
92724
|
+
_index_mjs__WEBPACK_IMPORTED_MODULE_34__["default"].bundle.strategies = [new _bundle_strategies_openapi_3_0_index_mjs__WEBPACK_IMPORTED_MODULE_32__["default"](), new _bundle_strategies_openapi_3_1_index_mjs__WEBPACK_IMPORTED_MODULE_33__["default"]()];
|
|
91608
92725
|
|
|
91609
92726
|
|
|
91610
92727
|
/***/ },
|
|
@@ -96955,7 +98072,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
96955
98072
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
96956
98073
|
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
96957
98074
|
/* harmony export */ });
|
|
96958
|
-
/* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
|
|
98075
|
+
/* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(44641);
|
|
96959
98076
|
|
|
96960
98077
|
|
|
96961
98078
|
/**
|
|
@@ -97353,12 +98470,15 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
97353
98470
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
97354
98471
|
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
97355
98472
|
/* harmony export */ });
|
|
97356
|
-
/* harmony import */ var
|
|
98473
|
+
/* harmony import */ var _ResolveError_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(65079);
|
|
97357
98474
|
|
|
97358
98475
|
/**
|
|
98476
|
+
* Thrown when a reference cannot be resolved. Resolution is shared by the
|
|
98477
|
+
* dereference and bundle components, so this error lives under `ResolveError`.
|
|
98478
|
+
*
|
|
97359
98479
|
* @public
|
|
97360
98480
|
*/
|
|
97361
|
-
class UnresolvableReferenceError extends
|
|
98481
|
+
class UnresolvableReferenceError extends _ResolveError_mjs__WEBPACK_IMPORTED_MODULE_0__["default"] {}
|
|
97362
98482
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (UnresolvableReferenceError);
|
|
97363
98483
|
|
|
97364
98484
|
/***/ },
|
|
@@ -97569,6 +98689,24 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
97569
98689
|
/* harmony import */ var ramda__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(57457);
|
|
97570
98690
|
|
|
97571
98691
|
|
|
98692
|
+
/**
|
|
98693
|
+
* @public
|
|
98694
|
+
*/
|
|
98695
|
+
|
|
98696
|
+
/**
|
|
98697
|
+
* @public
|
|
98698
|
+
*/
|
|
98699
|
+
|
|
98700
|
+
/**
|
|
98701
|
+
* @public
|
|
98702
|
+
*/
|
|
98703
|
+
|
|
98704
|
+
/**
|
|
98705
|
+
* Context passed to a custom component-name resolver.
|
|
98706
|
+
*
|
|
98707
|
+
* @public
|
|
98708
|
+
*/
|
|
98709
|
+
|
|
97572
98710
|
/**
|
|
97573
98711
|
* @public
|
|
97574
98712
|
*/
|
|
@@ -97736,6 +98874,13 @@ const defaultOptions = {
|
|
|
97736
98874
|
* your own implementation, or remove any bundle strategy by removing it from the list.
|
|
97737
98875
|
*/
|
|
97738
98876
|
strategies: [],
|
|
98877
|
+
/**
|
|
98878
|
+
* Determines strategy specific options. The key is the name of the strategy
|
|
98879
|
+
* (e.g. `openapi-3-0`) and the value is an object of options specific to
|
|
98880
|
+
* that strategy. Strategy specific options take precedence over the
|
|
98881
|
+
* top-level bundle options.
|
|
98882
|
+
*/
|
|
98883
|
+
strategyOpts: {},
|
|
97739
98884
|
/**
|
|
97740
98885
|
* This option accepts an instance of pre-computed ReferenceSet.
|
|
97741
98886
|
* If provided it will speed up the bundling significantly as the external
|
|
@@ -97754,7 +98899,49 @@ const defaultOptions = {
|
|
|
97754
98899
|
* The bundling should throw MaximumBundleDepthError if bundling depth
|
|
97755
98900
|
* is exceeded by this option.
|
|
97756
98901
|
*/
|
|
97757
|
-
maxDepth: +Infinity
|
|
98902
|
+
maxDepth: +Infinity,
|
|
98903
|
+
/**
|
|
98904
|
+
* Determines whether the bundling process will be immutable.
|
|
98905
|
+
* By default, the bundling process is immutable, which means that the original
|
|
98906
|
+
* ApiDOM (and any pre-computed refSet) is not mutated and a deep clone is bundled.
|
|
98907
|
+
*
|
|
98908
|
+
* true - the bundling process is immutable (deep cloning of ApiDOM is involved)
|
|
98909
|
+
* false - the bundling process is mutable (no deep cloning, faster, mutates input)
|
|
98910
|
+
*/
|
|
98911
|
+
immutable: true,
|
|
98912
|
+
/**
|
|
98913
|
+
* Determines how hoisted components are named.
|
|
98914
|
+
*
|
|
98915
|
+
* `basename` (default) - derive the name from the referenced JSON Pointer
|
|
98916
|
+
* (its last token), falling back to the referenced file's basename.
|
|
98917
|
+
* `title` - derive Schema Object names from their `title` field, falling
|
|
98918
|
+
* back to `basename` when no usable title is present.
|
|
98919
|
+
* A custom resolver function - receives the referenced element and reference
|
|
98920
|
+
* context and returns the base name; collision suffixing is still applied.
|
|
98921
|
+
*/
|
|
98922
|
+
componentNamesStrategy: 'basename',
|
|
98923
|
+
/**
|
|
98924
|
+
* Determines how a component rename forced by a name collision with
|
|
98925
|
+
* different content is reported.
|
|
98926
|
+
*
|
|
98927
|
+
* `warn` (default) - append a warning annotation to the parse result.
|
|
98928
|
+
* `off` - rename silently.
|
|
98929
|
+
* `error` - throw a BundleError instead of renaming.
|
|
98930
|
+
*/
|
|
98931
|
+
onComponentNameCollision: 'warn',
|
|
98932
|
+
/**
|
|
98933
|
+
* Determines how the bundling process behaves when a reference cannot be
|
|
98934
|
+
* resolved.
|
|
98935
|
+
*
|
|
98936
|
+
* Unlike dereferencing, a swallowed reference is left in place — so the
|
|
98937
|
+
* bundled document may still contain unresolved external references.
|
|
98938
|
+
*
|
|
98939
|
+
* false - fail fast, throw on first error (default)
|
|
98940
|
+
* true - skip unresolvable references silently, continue bundling
|
|
98941
|
+
* (error) => void - callback invoked for each error; if the callback
|
|
98942
|
+
* itself throws, bundling stops with that error
|
|
98943
|
+
*/
|
|
98944
|
+
continueOnError: false
|
|
97758
98945
|
}
|
|
97759
98946
|
};
|
|
97760
98947
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (defaultOptions);
|