@speclynx/apidom-parser-adapter-openapi-json-3-0 2.2.3 → 2.3.0

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 CHANGED
@@ -3,6 +3,12 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [2.3.0](https://github.com/speclynx/apidom/compare/v2.2.3...v2.3.0) (2026-01-27)
7
+
8
+ ### Features
9
+
10
+ - support strict parsing mode through out the packages ([#46](https://github.com/speclynx/apidom/issues/46)) ([e6b47d9](https://github.com/speclynx/apidom/commit/e6b47d9cfdede7103cada67362b316fd8e5b787f)), closes [#23](https://github.com/speclynx/apidom/issues/23)
11
+
6
12
  ## [2.2.3](https://github.com/speclynx/apidom/compare/v2.2.2...v2.2.3) (2026-01-26)
7
13
 
8
14
  **Note:** Version bump only for package @speclynx/apidom-parser-adapter-openapi-json-3-0
@@ -23274,7 +23274,7 @@ __webpack_require__.r(__webpack_exports__);
23274
23274
  /* harmony export */ syntacticAnalysis: () => (/* reexport safe */ _tree_sitter_index_mjs__WEBPACK_IMPORTED_MODULE_5__["default"])
23275
23275
  /* harmony export */ });
23276
23276
  /* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5156);
23277
- /* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6126);
23277
+ /* harmony import */ var _speclynx_apidom_error__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(746);
23278
23278
  /* harmony import */ var _native_index_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8600);
23279
23279
  /* harmony import */ var _tree_sitter_index_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4885);
23280
23280
  /* harmony import */ var _tree_sitter_index_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9305);
@@ -23319,10 +23319,6 @@ const detect = async (source, {
23319
23319
  * @public
23320
23320
  */
23321
23321
 
23322
- /**
23323
- * @public
23324
- */
23325
-
23326
23322
  /**
23327
23323
  * @public
23328
23324
  */
@@ -31631,6 +31627,9 @@ __webpack_require__.r(__webpack_exports__);
31631
31627
  * @public
31632
31628
  */
31633
31629
  const detect = async source => {
31630
+ if (source.trim().length === 0) {
31631
+ return false;
31632
+ }
31634
31633
  try {
31635
31634
  JSON.parse(source);
31636
31635
  return true;
@@ -31643,9 +31642,12 @@ const detect = async source => {
31643
31642
  * @public
31644
31643
  */
31645
31644
  const parse = async source => {
31645
+ const parseResult = new _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__["default"]();
31646
+ if (source.trim().length === 0) {
31647
+ return parseResult;
31648
+ }
31646
31649
  const pojo = JSON.parse(source);
31647
31650
  const element = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_0__.refract)(pojo);
31648
- const parseResult = new _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__["default"]();
31649
31651
  element.classes.push('result');
31650
31652
  parseResult.push(element);
31651
31653
  return parseResult;
@@ -35183,7 +35185,11 @@ const detectionRegExp = /"openapi"\s*:\s*"(?<version_json>3\.0\.(?:[1-9]\d*|0))"
35183
35185
  /**
35184
35186
  * @public
35185
35187
  */
35186
- const detect = async source => detectionRegExp.test(source) && (await (0,_speclynx_apidom_parser_adapter_json__WEBPACK_IMPORTED_MODULE_4__.detect)(source));
35188
+ const detect = async (source, options = {}) => detectionRegExp.test(source) && (await (0,_speclynx_apidom_parser_adapter_json__WEBPACK_IMPORTED_MODULE_4__.detect)(source, options));
35189
+
35190
+ /**
35191
+ * @public
35192
+ */
35187
35193
 
35188
35194
  /**
35189
35195
  * @public