@swagger-api/apidom-json-pointer-relative 0.76.0 → 0.76.2
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 +10 -0
- package/cjs/compile.cjs +1 -1
- package/cjs/errors/CompilationRelativeJsonPointerError.cjs +1 -1
- package/cjs/errors/EvaluationRelativeJsonPointerError.cjs +1 -1
- package/cjs/errors/InvalidRelativeJsonPointerError.cjs +1 -1
- package/cjs/evaluate.cjs +1 -1
- package/cjs/index.cjs +3 -4
- package/cjs/parse.cjs +1 -1
- package/cjs/types.cjs +3 -1
- package/dist/apidom-json-pointer-relative.browser.js +19814 -21089
- package/dist/apidom-json-pointer-relative.browser.min.js +1 -1
- package/es/{compile.js → compile.mjs} +1 -1
- package/es/errors/{CompilationRelativeJsonPointerError.js → CompilationRelativeJsonPointerError.mjs} +1 -6
- package/es/errors/{EvaluationRelativeJsonPointerError.js → EvaluationRelativeJsonPointerError.mjs} +1 -9
- package/es/errors/{InvalidRelativeJsonPointerError.js → InvalidRelativeJsonPointerError.mjs} +1 -3
- package/es/{evaluate.js → evaluate.mjs} +2 -2
- package/es/{index.js → index.mjs} +7 -7
- package/es/{parse.js → parse.mjs} +1 -1
- package/package.json +8 -8
- /package/es/errors/{RelativeJsonPointerError.js → RelativeJsonPointerError.mjs} +0 -0
- /package/es/{types.js → types.mjs} +0 -0
package/es/errors/{EvaluationRelativeJsonPointerError.js → EvaluationRelativeJsonPointerError.mjs}
RENAMED
|
@@ -1,16 +1,8 @@
|
|
|
1
|
-
import _defineProperty from "@babel/runtime-corejs3/helpers/esm/defineProperty";
|
|
2
1
|
import { hasElementSourceMap, toValue } from '@swagger-api/apidom-core';
|
|
3
|
-
import RelativeJsonPointerError from "./RelativeJsonPointerError.
|
|
2
|
+
import RelativeJsonPointerError from "./RelativeJsonPointerError.mjs";
|
|
4
3
|
class EvaluationRelativeJsonPointerError extends RelativeJsonPointerError {
|
|
5
4
|
constructor(message, structuredOptions) {
|
|
6
5
|
super(message, structuredOptions);
|
|
7
|
-
_defineProperty(this, "relativePointer", void 0);
|
|
8
|
-
_defineProperty(this, "currentElement", void 0);
|
|
9
|
-
_defineProperty(this, "currentElementSourceMap", void 0);
|
|
10
|
-
_defineProperty(this, "rootElement", void 0);
|
|
11
|
-
_defineProperty(this, "rootElementSourceMap", void 0);
|
|
12
|
-
_defineProperty(this, "cursorElement", void 0);
|
|
13
|
-
_defineProperty(this, "cursorElementSourceMap", void 0);
|
|
14
6
|
if (typeof structuredOptions !== 'undefined') {
|
|
15
7
|
this.relativePointer = structuredOptions.relativePointer;
|
|
16
8
|
this.currentElement = structuredOptions.currentElement.element;
|
package/es/errors/{InvalidRelativeJsonPointerError.js → InvalidRelativeJsonPointerError.mjs}
RENAMED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import RelativeJsonPointerError from "./RelativeJsonPointerError.js";
|
|
1
|
+
import RelativeJsonPointerError from "./RelativeJsonPointerError.mjs";
|
|
3
2
|
export default class InvalidRelativeJsonPointerError extends RelativeJsonPointerError {
|
|
4
3
|
constructor(message, structuredOptions) {
|
|
5
4
|
super(message, structuredOptions);
|
|
6
|
-
_defineProperty(this, "relativePointer", void 0);
|
|
7
5
|
if (typeof structuredOptions !== 'undefined') {
|
|
8
6
|
this.relativePointer = structuredOptions.relativePointer;
|
|
9
7
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { visit, BREAK, isElement, isMemberElement, isArrayElement, NumberElement } from '@swagger-api/apidom-core';
|
|
2
2
|
import { compile as compileJsonPointer, evaluate as evaluateJsonPointer } from '@swagger-api/apidom-json-pointer';
|
|
3
3
|
import { last } from 'ramda';
|
|
4
|
-
import EvaluationRelativeJsonPointerError from "./errors/EvaluationRelativeJsonPointerError.
|
|
5
|
-
import parse from "./parse.
|
|
4
|
+
import EvaluationRelativeJsonPointerError from "./errors/EvaluationRelativeJsonPointerError.mjs";
|
|
5
|
+
import parse from "./parse.mjs";
|
|
6
6
|
// evaluates Relative JSON Pointer against ApiDOM fragment
|
|
7
7
|
const evaluate = (relativePointer, currentElement, rootElement) => {
|
|
8
8
|
let ancestorLineage = [];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { default as RelativeJsonPointerError } from "./errors/RelativeJsonPointerError.
|
|
2
|
-
export { default as InvalidRelativeJsonPointerError } from "./errors/InvalidRelativeJsonPointerError.
|
|
3
|
-
export { default as EvaluationRelativeJsonPointerError } from "./errors/EvaluationRelativeJsonPointerError.
|
|
4
|
-
export { default as CompilationRelativeJsonPointerError } from "./errors/CompilationRelativeJsonPointerError.
|
|
5
|
-
export { default as parse, isRelativeJsonPointer } from "./parse.
|
|
6
|
-
export { default as compile } from "./compile.
|
|
7
|
-
export { default as evaluate } from "./evaluate.
|
|
1
|
+
export { default as RelativeJsonPointerError } from "./errors/RelativeJsonPointerError.mjs";
|
|
2
|
+
export { default as InvalidRelativeJsonPointerError } from "./errors/InvalidRelativeJsonPointerError.mjs";
|
|
3
|
+
export { default as EvaluationRelativeJsonPointerError } from "./errors/EvaluationRelativeJsonPointerError.mjs";
|
|
4
|
+
export { default as CompilationRelativeJsonPointerError } from "./errors/CompilationRelativeJsonPointerError.mjs";
|
|
5
|
+
export { default as parse, isRelativeJsonPointer } from "./parse.mjs";
|
|
6
|
+
export { default as compile } from "./compile.mjs";
|
|
7
|
+
export { default as evaluate } from "./evaluate.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { parse as parseJsonPointer } from '@swagger-api/apidom-json-pointer';
|
|
2
|
-
import InvalidRelativeJsonPointerError from "./errors/InvalidRelativeJsonPointerError.
|
|
2
|
+
import InvalidRelativeJsonPointerError from "./errors/InvalidRelativeJsonPointerError.mjs";
|
|
3
3
|
const nonNegativeIntegerPrefixRegExp = '(?<nonNegativeIntegerPrefix>[1-9]\\d*|0)';
|
|
4
4
|
const indexManipulationRegExp = '(?<indexManipulation>[+-][1-9]\\d*|0)';
|
|
5
5
|
const hashCharacterRegExp = '(?<hashCharacter>#)';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@swagger-api/apidom-json-pointer-relative",
|
|
3
|
-
"version": "0.76.
|
|
3
|
+
"version": "0.76.2",
|
|
4
4
|
"description": "Evaluate Relative JSON Pointer expressions against ApiDOM.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public",
|
|
@@ -12,15 +12,15 @@
|
|
|
12
12
|
"main": "./cjs/index.cjs",
|
|
13
13
|
"exports": {
|
|
14
14
|
"types": "./types/dist.d.ts",
|
|
15
|
-
"import": "./es/index.
|
|
15
|
+
"import": "./es/index.mjs",
|
|
16
16
|
"require": "./cjs/index.cjs"
|
|
17
17
|
},
|
|
18
18
|
"types": "./types/dist.d.ts",
|
|
19
19
|
"scripts": {
|
|
20
20
|
"build": "npm run clean && run-p --max-parallel ${CPU_CORES:-2} typescript:declaration build:es build:cjs build:umd:browser",
|
|
21
|
-
"build:es": "cross-env BABEL_ENV=es babel src --out-dir es --extensions '.ts' --root-mode 'upward'",
|
|
21
|
+
"build:es": "cross-env BABEL_ENV=es babel src --out-dir es --extensions '.ts' --out-file-extension '.mjs' --root-mode 'upward'",
|
|
22
22
|
"build:cjs": "cross-env BABEL_ENV=cjs babel src --out-dir cjs --extensions '.ts' --out-file-extension '.cjs' --root-mode 'upward'",
|
|
23
|
-
"build:umd:browser": "cross-env BABEL_ENV=browser
|
|
23
|
+
"build:umd:browser": "cross-env BABEL_ENV=browser webpack --config config/webpack/browser.config.js --progress",
|
|
24
24
|
"lint": "eslint ./",
|
|
25
25
|
"lint:fix": "eslint ./ --fix",
|
|
26
26
|
"clean": "rimraf ./es ./cjs ./dist ./types",
|
|
@@ -38,9 +38,9 @@
|
|
|
38
38
|
"license": "Apache-2.0",
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"@babel/runtime-corejs3": "^7.20.7",
|
|
41
|
-
"@swagger-api/apidom-core": "^0.76.
|
|
42
|
-
"@swagger-api/apidom-error": "^0.76.
|
|
43
|
-
"@swagger-api/apidom-json-pointer": "^0.76.
|
|
41
|
+
"@swagger-api/apidom-core": "^0.76.2",
|
|
42
|
+
"@swagger-api/apidom-error": "^0.76.2",
|
|
43
|
+
"@swagger-api/apidom-json-pointer": "^0.76.2",
|
|
44
44
|
"@types/ramda": "~0.29.3",
|
|
45
45
|
"ramda": "~0.29.0",
|
|
46
46
|
"ramda-adjunct": "^4.0.0"
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"README.md",
|
|
56
56
|
"CHANGELOG.md"
|
|
57
57
|
],
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "8c6c02f813a663cfaf0ac0963f2b4fd25b8dffe8"
|
|
59
59
|
}
|
|
File without changes
|
|
File without changes
|