@blogmcp/sdk 0.3.2 → 0.6.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/dist/core/client-types.d.ts +7 -1
- package/dist/core/client.d.ts +25 -1
- package/dist/core/client.js +38 -34
- package/dist/core/consultation-adapter.d.ts +90 -0
- package/dist/core/consultation-adapter.js +200 -0
- package/dist/core/consultations.d.ts +108 -0
- package/dist/core/consultations.js +95 -0
- package/dist/core/errors.d.ts +52 -0
- package/dist/core/errors.js +73 -0
- package/dist/core/index.d.ts +7 -1
- package/dist/core/index.js +80 -64
- package/dist/core/queries.d.ts +16 -1
- package/dist/core/queries.js +198 -61
- package/dist/core/review/format.d.ts +30 -0
- package/dist/core/review/format.js +78 -0
- package/dist/core/review/index.d.ts +6 -0
- package/dist/core/review/index.js +9 -0
- package/dist/core/review/types.d.ts +176 -0
- package/dist/core/review/types.js +9 -0
- package/dist/core/server-only.d.ts +12 -0
- package/dist/core/server-only.js +11 -0
- package/dist/core/types.d.ts +295 -0
- package/dist/packages/mdx-render-vue/dist/composables/useGallery.js +12 -11
- package/dist/packages/mdx-render-vue/dist/composables/useTripMap.js +16 -16
- package/dist/packages/mdx-render-vue/dist/edit/TripMapEdit.vue.js +1 -1
- package/dist/packages/mdx-render-vue/dist/registry.js +21 -22
- package/dist/packages/mdx-render-vue/dist/render/alert/Alert.vue2.js +1 -1
- package/dist/packages/mdx-render-vue/dist/render/badge/Badge.vue2.js +1 -1
- package/dist/packages/mdx-render-vue/dist/render/button/Button.vue2.js +1 -1
- package/dist/packages/mdx-render-vue/dist/render/callout/CalloutDefault.vue.js +1 -1
- package/dist/packages/mdx-render-vue/dist/render/callout/CalloutMinimal.vue.js +1 -1
- package/dist/packages/mdx-render-vue/dist/render/tripmap/TripMapDefault.vue.js +2 -2
- package/dist/packages/tripmap-core/dist/attribution.js +121 -6
- package/dist/packages/tripmap-core/dist/css.js +68 -16
- package/dist/packages/tripmap-core/dist/detail.js +10 -9
- package/dist/packages/tripmap-core/dist/engine.js +285 -247
- package/dist/packages/tripmap-core/dist/export.js +48 -46
- package/dist/packages/tripmap-core/dist/filmstrip.js +30 -17
- package/dist/packages/tripmap-core/dist/framing.js +30 -30
- package/dist/packages/tripmap-core/dist/generated/maplibre-worker.bundle.js +1 -1
- package/dist/packages/tripmap-core/dist/heading.js +8 -0
- package/dist/packages/tripmap-core/dist/href.js +18 -0
- package/dist/packages/tripmap-core/dist/index.js +32 -24
- package/dist/packages/tripmap-core/dist/lightbox.js +31 -29
- package/dist/packages/tripmap-core/dist/line.js +6 -6
- package/dist/packages/tripmap-core/dist/markers.js +47 -43
- package/dist/packages/tripmap-core/dist/nodes.js +56 -43
- package/dist/packages/tripmap-core/dist/playback.js +17 -17
- package/dist/packages/tripmap-core/dist/preload.js +14 -14
- package/dist/packages/tripmap-core/dist/theme.js +21 -21
- package/dist/{node_modules → packages/tripmap-core/node_modules}/maplibre-gl/dist/maplibre-gl.js +1890 -1720
- package/dist/{node_modules → packages/tripmap-core/node_modules}/pmtiles/dist/esm/index.js +1 -1
- package/dist/react/KbMdxContent.js +7 -8
- package/dist/vue/components/KbMdxContent.vue2.js +6 -7
- package/package.json +8 -3
- package/src/core/client-types.ts +13 -2
- package/src/core/client.ts +40 -5
- package/src/core/consultation-adapter.ts +408 -0
- package/src/core/consultations.ts +224 -0
- package/src/core/errors.ts +145 -0
- package/src/core/index.ts +68 -0
- package/src/core/queries.ts +167 -3
- package/src/core/review/format.ts +138 -0
- package/src/core/review/index.ts +22 -0
- package/src/core/review/types.ts +168 -0
- package/src/core/server-only.ts +20 -0
- package/src/core/types.ts +337 -0
- package/dist/_virtual/constants.js +0 -4
- package/dist/_virtual/index.js +0 -2
- package/dist/_virtual/index2.js +0 -4
- package/dist/_virtual/index3.js +0 -2
- package/dist/_virtual/re.js +0 -4
- package/dist/node_modules/@braintree/sanitize-url/dist/constants.js +0 -8
- package/dist/node_modules/@braintree/sanitize-url/dist/index.js +0 -60
- package/dist/node_modules/dompurify/dist/purify.es.js +0 -662
- package/dist/node_modules/semver/classes/comparator.js +0 -56
- package/dist/node_modules/semver/classes/range.js +0 -148
- package/dist/node_modules/semver/classes/semver.js +0 -169
- package/dist/node_modules/semver/functions/clean.js +0 -14
- package/dist/node_modules/semver/functions/cmp.js +0 -39
- package/dist/node_modules/semver/functions/coerce.js +0 -33
- package/dist/node_modules/semver/functions/compare-build.js +0 -14
- package/dist/node_modules/semver/functions/compare-loose.js +0 -11
- package/dist/node_modules/semver/functions/compare.js +0 -11
- package/dist/node_modules/semver/functions/diff.js +0 -24
- package/dist/node_modules/semver/functions/eq.js +0 -11
- package/dist/node_modules/semver/functions/gt.js +0 -11
- package/dist/node_modules/semver/functions/gte.js +0 -11
- package/dist/node_modules/semver/functions/inc.js +0 -21
- package/dist/node_modules/semver/functions/lt.js +0 -11
- package/dist/node_modules/semver/functions/lte.js +0 -11
- package/dist/node_modules/semver/functions/major.js +0 -11
- package/dist/node_modules/semver/functions/minor.js +0 -11
- package/dist/node_modules/semver/functions/neq.js +0 -11
- package/dist/node_modules/semver/functions/parse.js +0 -21
- package/dist/node_modules/semver/functions/patch.js +0 -11
- package/dist/node_modules/semver/functions/prerelease.js +0 -14
- package/dist/node_modules/semver/functions/rcompare.js +0 -11
- package/dist/node_modules/semver/functions/rsort.js +0 -11
- package/dist/node_modules/semver/functions/satisfies.js +0 -18
- package/dist/node_modules/semver/functions/sort.js +0 -11
- package/dist/node_modules/semver/functions/valid.js +0 -14
- package/dist/node_modules/semver/index.js +0 -97
- package/dist/node_modules/semver/internal/constants.js +0 -28
- package/dist/node_modules/semver/internal/debug.js +0 -8
- package/dist/node_modules/semver/internal/identifiers.js +0 -18
- package/dist/node_modules/semver/internal/lrucache.js +0 -32
- package/dist/node_modules/semver/internal/parse-options.js +0 -10
- package/dist/node_modules/semver/internal/re.js +0 -32
- package/dist/node_modules/semver/ranges/gtr.js +0 -11
- package/dist/node_modules/semver/ranges/intersects.js +0 -11
- package/dist/node_modules/semver/ranges/ltr.js +0 -11
- package/dist/node_modules/semver/ranges/max-satisfying.js +0 -22
- package/dist/node_modules/semver/ranges/min-satisfying.js +0 -22
- package/dist/node_modules/semver/ranges/min-version.js +0 -42
- package/dist/node_modules/semver/ranges/outside.js +0 -44
- package/dist/node_modules/semver/ranges/simplify.js +0 -24
- package/dist/node_modules/semver/ranges/subset.js +0 -94
- package/dist/node_modules/semver/ranges/to-comparators.js +0 -11
- package/dist/node_modules/semver/ranges/valid.js +0 -17
- package/dist/packages/mdx-schema/dist/composables/useMdxParsing.js +0 -389
- package/dist/packages/mdx-schema/dist/metadata/index.js +0 -526
- package/dist/packages/mdx-schema/dist/prepareProps.js +0 -46
- package/dist/packages/mdx-schema/dist/styles/index.js +0 -141
- package/dist/packages/mdx-schema/dist/tripmap.js +0 -88
- package/dist/packages/mdx-schema/dist/types/index.js +0 -26
- package/dist/packages/sanitize/dist/html.js +0 -89
- /package/dist/{node_modules → packages/tripmap-core/node_modules}/maplibre-gl/dist/maplibre-gl-shared.js +0 -0
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { __require as q } from "../internal/parse-options.js";
|
|
2
|
-
import { __require as p } from "../internal/re.js";
|
|
3
|
-
import { __require as _ } from "../functions/cmp.js";
|
|
4
|
-
import { __require as d } from "../internal/debug.js";
|
|
5
|
-
import { __require as W } from "./semver.js";
|
|
6
|
-
import { __require as R } from "./range.js";
|
|
7
|
-
var o, m;
|
|
8
|
-
function S() {
|
|
9
|
-
if (m) return o;
|
|
10
|
-
m = 1;
|
|
11
|
-
const t = /* @__PURE__ */ Symbol("SemVer ANY");
|
|
12
|
-
class i {
|
|
13
|
-
static get ANY() {
|
|
14
|
-
return t;
|
|
15
|
-
}
|
|
16
|
-
constructor(r, e) {
|
|
17
|
-
if (e = h(e), r instanceof i) {
|
|
18
|
-
if (r.loose === !!e.loose)
|
|
19
|
-
return r;
|
|
20
|
-
r = r.value;
|
|
21
|
-
}
|
|
22
|
-
r = r.trim().split(/\s+/).join(" "), u("comparator", r, e), this.options = e, this.loose = !!e.loose, this.parse(r), this.semver === t ? this.value = "" : this.value = this.operator + this.semver.version, u("comp", this);
|
|
23
|
-
}
|
|
24
|
-
parse(r) {
|
|
25
|
-
const e = this.options.loose ? n[l.COMPARATORLOOSE] : n[l.COMPARATOR], s = r.match(e);
|
|
26
|
-
if (!s)
|
|
27
|
-
throw new TypeError(`Invalid comparator: ${r}`);
|
|
28
|
-
this.operator = s[1] !== void 0 ? s[1] : "", this.operator === "=" && (this.operator = ""), s[2] ? this.semver = new f(s[2], this.options.loose) : this.semver = t;
|
|
29
|
-
}
|
|
30
|
-
toString() {
|
|
31
|
-
return this.value;
|
|
32
|
-
}
|
|
33
|
-
test(r) {
|
|
34
|
-
if (u("Comparator.test", r, this.options.loose), this.semver === t || r === t)
|
|
35
|
-
return !0;
|
|
36
|
-
if (typeof r == "string")
|
|
37
|
-
try {
|
|
38
|
-
r = new f(r, this.options);
|
|
39
|
-
} catch {
|
|
40
|
-
return !1;
|
|
41
|
-
}
|
|
42
|
-
return a(r, this.operator, this.semver, this.options);
|
|
43
|
-
}
|
|
44
|
-
intersects(r, e) {
|
|
45
|
-
if (!(r instanceof i))
|
|
46
|
-
throw new TypeError("a Comparator is required");
|
|
47
|
-
return this.operator === "" ? this.value === "" ? !0 : new v(r.value, e).test(this.value) : r.operator === "" ? r.value === "" ? !0 : new v(this.value, e).test(r.semver) : (e = h(e), e.includePrerelease && (this.value === "<0.0.0-0" || r.value === "<0.0.0-0") || !e.includePrerelease && (this.value.startsWith("<0.0.0") || r.value.startsWith("<0.0.0")) ? !1 : !!(this.operator.startsWith(">") && r.operator.startsWith(">") || this.operator.startsWith("<") && r.operator.startsWith("<") || this.semver.version === r.semver.version && this.operator.includes("=") && r.operator.includes("=") || a(this.semver, "<", r.semver, e) && this.operator.startsWith(">") && r.operator.startsWith("<") || a(this.semver, ">", r.semver, e) && this.operator.startsWith("<") && r.operator.startsWith(">")));
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
o = i;
|
|
51
|
-
const h = q(), { safeRe: n, t: l } = p(), a = _(), u = d(), f = W(), v = R();
|
|
52
|
-
return o;
|
|
53
|
-
}
|
|
54
|
-
export {
|
|
55
|
-
S as __require
|
|
56
|
-
};
|
|
@@ -1,148 +0,0 @@
|
|
|
1
|
-
import { __require as F } from "../internal/lrucache.js";
|
|
2
|
-
import { __require as V } from "../internal/parse-options.js";
|
|
3
|
-
import { __require as B } from "./comparator.js";
|
|
4
|
-
import { __require as K } from "../internal/debug.js";
|
|
5
|
-
import { __require as J } from "./semver.js";
|
|
6
|
-
import { __require as Q } from "../internal/re.js";
|
|
7
|
-
import { __require as W } from "../internal/constants.js";
|
|
8
|
-
var A, L;
|
|
9
|
-
function le() {
|
|
10
|
-
if (L) return A;
|
|
11
|
-
L = 1;
|
|
12
|
-
const w = /\s+/g;
|
|
13
|
-
class E {
|
|
14
|
-
constructor(e, i) {
|
|
15
|
-
if (i = _(i), e instanceof E)
|
|
16
|
-
return e.loose === !!i.loose && e.includePrerelease === !!i.includePrerelease ? e : new E(e.raw, i);
|
|
17
|
-
if (e instanceof p)
|
|
18
|
-
return this.raw = e.value, this.set = [[e]], this.formatted = void 0, this;
|
|
19
|
-
if (this.options = i, this.loose = !!i.loose, this.includePrerelease = !!i.includePrerelease, this.raw = e.trim().replace(w, " "), this.set = this.raw.split("||").map((t) => this.parseRange(t.trim())).filter((t) => t.length), !this.set.length)
|
|
20
|
-
throw new TypeError(`Invalid SemVer Range: ${this.raw}`);
|
|
21
|
-
if (this.set.length > 1) {
|
|
22
|
-
const t = this.set[0];
|
|
23
|
-
if (this.set = this.set.filter((l) => !S(l[0])), this.set.length === 0)
|
|
24
|
-
this.set = [t];
|
|
25
|
-
else if (this.set.length > 1) {
|
|
26
|
-
for (const l of this.set)
|
|
27
|
-
if (l.length === 1 && x(l[0])) {
|
|
28
|
-
this.set = [l];
|
|
29
|
-
break;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
this.formatted = void 0;
|
|
34
|
-
}
|
|
35
|
-
get range() {
|
|
36
|
-
if (this.formatted === void 0) {
|
|
37
|
-
this.formatted = "";
|
|
38
|
-
for (let e = 0; e < this.set.length; e++) {
|
|
39
|
-
e > 0 && (this.formatted += "||");
|
|
40
|
-
const i = this.set[e];
|
|
41
|
-
for (let t = 0; t < i.length; t++)
|
|
42
|
-
t > 0 && (this.formatted += " "), this.formatted += i[t].toString().trim();
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
return this.formatted;
|
|
46
|
-
}
|
|
47
|
-
format() {
|
|
48
|
-
return this.range;
|
|
49
|
-
}
|
|
50
|
-
toString() {
|
|
51
|
-
return this.range;
|
|
52
|
-
}
|
|
53
|
-
parseRange(e) {
|
|
54
|
-
const t = ((this.options.includePrerelease && I) | (this.options.loose && N)) + ":" + e, l = O.get(t);
|
|
55
|
-
if (l)
|
|
56
|
-
return l;
|
|
57
|
-
const s = this.options.loose, n = s ? h[o.HYPHENRANGELOOSE] : h[o.HYPHENRANGE];
|
|
58
|
-
e = e.replace(n, k(this.options.includePrerelease)), f("hyphen replace", e), e = e.replace(h[o.COMPARATORTRIM], y), f("comparator trim", e), e = e.replace(h[o.TILDETRIM], G), f("tilde trim", e), e = e.replace(h[o.CARETTRIM], v), f("caret trim", e);
|
|
59
|
-
let $ = e.split(" ").map((u) => m(u, this.options)).join(" ").split(/\s+/).map((u) => Y(u, this.options));
|
|
60
|
-
s && ($ = $.filter((u) => (f("loose invalid filter", u, this.options), !!u.match(h[o.COMPARATORLOOSE])))), f("range list", $);
|
|
61
|
-
const a = /* @__PURE__ */ new Map(), c = $.map((u) => new p(u, this.options));
|
|
62
|
-
for (const u of c) {
|
|
63
|
-
if (S(u))
|
|
64
|
-
return [u];
|
|
65
|
-
a.set(u.value, u);
|
|
66
|
-
}
|
|
67
|
-
a.size > 1 && a.has("") && a.delete("");
|
|
68
|
-
const R = [...a.values()];
|
|
69
|
-
return O.set(t, R), R;
|
|
70
|
-
}
|
|
71
|
-
intersects(e, i) {
|
|
72
|
-
if (!(e instanceof E))
|
|
73
|
-
throw new TypeError("a Range is required");
|
|
74
|
-
return this.set.some((t) => q(t, i) && e.set.some((l) => q(l, i) && t.every((s) => l.every((n) => s.intersects(n, i)))));
|
|
75
|
-
}
|
|
76
|
-
// if ANY of the sets match ALL of its comparators, then pass
|
|
77
|
-
test(e) {
|
|
78
|
-
if (!e)
|
|
79
|
-
return !1;
|
|
80
|
-
if (typeof e == "string")
|
|
81
|
-
try {
|
|
82
|
-
e = new P(e, this.options);
|
|
83
|
-
} catch {
|
|
84
|
-
return !1;
|
|
85
|
-
}
|
|
86
|
-
for (let i = 0; i < this.set.length; i++)
|
|
87
|
-
if (z(this.set[i], e, this.options))
|
|
88
|
-
return !0;
|
|
89
|
-
return !1;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
A = E;
|
|
93
|
-
const C = F(), O = new C(), _ = V(), p = B(), f = K(), P = J(), {
|
|
94
|
-
safeRe: h,
|
|
95
|
-
t: o,
|
|
96
|
-
comparatorTrimReplace: y,
|
|
97
|
-
tildeTrimReplace: G,
|
|
98
|
-
caretTrimReplace: v
|
|
99
|
-
} = Q(), { FLAG_INCLUDE_PRERELEASE: I, FLAG_LOOSE: N } = W(), S = (r) => r.value === "<0.0.0-0", x = (r) => r.value === "", q = (r, e) => {
|
|
100
|
-
let i = !0;
|
|
101
|
-
const t = r.slice();
|
|
102
|
-
let l = t.pop();
|
|
103
|
-
for (; i && t.length; )
|
|
104
|
-
i = t.every((s) => l.intersects(s, e)), l = t.pop();
|
|
105
|
-
return i;
|
|
106
|
-
}, m = (r, e) => (r = r.replace(h[o.BUILD], ""), f("comp", r, e), r = j(r, e), f("caret", r), r = X(r, e), f("tildes", r), r = b(r, e), f("xrange", r), r = U(r, e), f("stars", r), r), d = (r) => !r || r.toLowerCase() === "x" || r === "*", X = (r, e) => r.trim().split(/\s+/).map((i) => g(i, e)).join(" "), g = (r, e) => {
|
|
107
|
-
const i = e.loose ? h[o.TILDELOOSE] : h[o.TILDE];
|
|
108
|
-
return r.replace(i, (t, l, s, n, $) => {
|
|
109
|
-
f("tilde", r, t, l, s, n, $);
|
|
110
|
-
let a;
|
|
111
|
-
return d(l) ? a = "" : d(s) ? a = `>=${l}.0.0 <${+l + 1}.0.0-0` : d(n) ? a = `>=${l}.${s}.0 <${l}.${+s + 1}.0-0` : $ ? (f("replaceTilde pr", $), a = `>=${l}.${s}.${n}-${$} <${l}.${+s + 1}.0-0`) : a = `>=${l}.${s}.${n} <${l}.${+s + 1}.0-0`, f("tilde return", a), a;
|
|
112
|
-
});
|
|
113
|
-
}, j = (r, e) => r.trim().split(/\s+/).map((i) => D(i, e)).join(" "), D = (r, e) => {
|
|
114
|
-
f("caret", r, e);
|
|
115
|
-
const i = e.loose ? h[o.CARETLOOSE] : h[o.CARET], t = e.includePrerelease ? "-0" : "";
|
|
116
|
-
return r.replace(i, (l, s, n, $, a) => {
|
|
117
|
-
f("caret", r, l, s, n, $, a);
|
|
118
|
-
let c;
|
|
119
|
-
return d(s) ? c = "" : d(n) ? c = `>=${s}.0.0${t} <${+s + 1}.0.0-0` : d($) ? s === "0" ? c = `>=${s}.${n}.0${t} <${s}.${+n + 1}.0-0` : c = `>=${s}.${n}.0${t} <${+s + 1}.0.0-0` : a ? (f("replaceCaret pr", a), s === "0" ? n === "0" ? c = `>=${s}.${n}.${$}-${a} <${s}.${n}.${+$ + 1}-0` : c = `>=${s}.${n}.${$}-${a} <${s}.${+n + 1}.0-0` : c = `>=${s}.${n}.${$}-${a} <${+s + 1}.0.0-0`) : (f("no pr"), s === "0" ? n === "0" ? c = `>=${s}.${n}.${$}${t} <${s}.${n}.${+$ + 1}-0` : c = `>=${s}.${n}.${$}${t} <${s}.${+n + 1}.0-0` : c = `>=${s}.${n}.${$} <${+s + 1}.0.0-0`), f("caret return", c), c;
|
|
120
|
-
});
|
|
121
|
-
}, b = (r, e) => (f("replaceXRanges", r, e), r.split(/\s+/).map((i) => H(i, e)).join(" ")), H = (r, e) => {
|
|
122
|
-
r = r.trim();
|
|
123
|
-
const i = e.loose ? h[o.XRANGELOOSE] : h[o.XRANGE];
|
|
124
|
-
return r.replace(i, (t, l, s, n, $, a) => {
|
|
125
|
-
f("xRange", r, t, l, s, n, $, a);
|
|
126
|
-
const c = d(s), R = c || d(n), u = R || d($), T = u;
|
|
127
|
-
return l === "=" && T && (l = ""), a = e.includePrerelease ? "-0" : "", c ? l === ">" || l === "<" ? t = "<0.0.0-0" : t = "*" : l && T ? (R && (n = 0), $ = 0, l === ">" ? (l = ">=", R ? (s = +s + 1, n = 0, $ = 0) : (n = +n + 1, $ = 0)) : l === "<=" && (l = "<", R ? s = +s + 1 : n = +n + 1), l === "<" && (a = "-0"), t = `${l + s}.${n}.${$}${a}`) : R ? t = `>=${s}.0.0${a} <${+s + 1}.0.0-0` : u && (t = `>=${s}.${n}.0${a} <${s}.${+n + 1}.0-0`), f("xRange return", t), t;
|
|
128
|
-
});
|
|
129
|
-
}, U = (r, e) => (f("replaceStars", r, e), r.trim().replace(h[o.STAR], "")), Y = (r, e) => (f("replaceGTE0", r, e), r.trim().replace(h[e.includePrerelease ? o.GTE0PRE : o.GTE0], "")), k = (r) => (e, i, t, l, s, n, $, a, c, R, u, T) => (d(t) ? i = "" : d(l) ? i = `>=${t}.0.0${r ? "-0" : ""}` : d(s) ? i = `>=${t}.${l}.0${r ? "-0" : ""}` : n ? i = `>=${i}` : i = `>=${i}${r ? "-0" : ""}`, d(c) ? a = "" : d(R) ? a = `<${+c + 1}.0.0-0` : d(u) ? a = `<${c}.${+R + 1}.0-0` : T ? a = `<=${c}.${R}.${u}-${T}` : r ? a = `<${c}.${R}.${+u + 1}-0` : a = `<=${a}`, `${i} ${a}`.trim()), z = (r, e, i) => {
|
|
130
|
-
for (let t = 0; t < r.length; t++)
|
|
131
|
-
if (!r[t].test(e))
|
|
132
|
-
return !1;
|
|
133
|
-
if (e.prerelease.length && !i.includePrerelease) {
|
|
134
|
-
for (let t = 0; t < r.length; t++)
|
|
135
|
-
if (f(r[t].semver), r[t].semver !== p.ANY && r[t].semver.prerelease.length > 0) {
|
|
136
|
-
const l = r[t].semver;
|
|
137
|
-
if (l.major === e.major && l.minor === e.minor && l.patch === e.patch)
|
|
138
|
-
return !0;
|
|
139
|
-
}
|
|
140
|
-
return !1;
|
|
141
|
-
}
|
|
142
|
-
return !0;
|
|
143
|
-
};
|
|
144
|
-
return A;
|
|
145
|
-
}
|
|
146
|
-
export {
|
|
147
|
-
le as __require
|
|
148
|
-
};
|
|
@@ -1,169 +0,0 @@
|
|
|
1
|
-
import { __require as w } from "../internal/debug.js";
|
|
2
|
-
import { __require as g } from "../internal/constants.js";
|
|
3
|
-
import { __require as E } from "../internal/re.js";
|
|
4
|
-
import { __require as b } from "../internal/parse-options.js";
|
|
5
|
-
import { __require as d } from "../internal/identifiers.js";
|
|
6
|
-
var c, f;
|
|
7
|
-
function k() {
|
|
8
|
-
if (f) return c;
|
|
9
|
-
f = 1;
|
|
10
|
-
const a = w(), { MAX_LENGTH: u, MAX_SAFE_INTEGER: h } = g(), { safeRe: l, t: o } = E(), m = b(), { compareIdentifiers: p } = d();
|
|
11
|
-
class n {
|
|
12
|
-
constructor(e, r) {
|
|
13
|
-
if (r = m(r), e instanceof n) {
|
|
14
|
-
if (e.loose === !!r.loose && e.includePrerelease === !!r.includePrerelease)
|
|
15
|
-
return e;
|
|
16
|
-
e = e.version;
|
|
17
|
-
} else if (typeof e != "string")
|
|
18
|
-
throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);
|
|
19
|
-
if (e.length > u)
|
|
20
|
-
throw new TypeError(
|
|
21
|
-
`version is longer than ${u} characters`
|
|
22
|
-
);
|
|
23
|
-
a("SemVer", e, r), this.options = r, this.loose = !!r.loose, this.includePrerelease = !!r.includePrerelease;
|
|
24
|
-
const s = e.trim().match(r.loose ? l[o.LOOSE] : l[o.FULL]);
|
|
25
|
-
if (!s)
|
|
26
|
-
throw new TypeError(`Invalid Version: ${e}`);
|
|
27
|
-
if (this.raw = e, this.major = +s[1], this.minor = +s[2], this.patch = +s[3], this.major > h || this.major < 0)
|
|
28
|
-
throw new TypeError("Invalid major version");
|
|
29
|
-
if (this.minor > h || this.minor < 0)
|
|
30
|
-
throw new TypeError("Invalid minor version");
|
|
31
|
-
if (this.patch > h || this.patch < 0)
|
|
32
|
-
throw new TypeError("Invalid patch version");
|
|
33
|
-
s[4] ? this.prerelease = s[4].split(".").map((t) => {
|
|
34
|
-
if (/^[0-9]+$/.test(t)) {
|
|
35
|
-
const i = +t;
|
|
36
|
-
if (i >= 0 && i < h)
|
|
37
|
-
return i;
|
|
38
|
-
}
|
|
39
|
-
return t;
|
|
40
|
-
}) : this.prerelease = [], this.build = s[5] ? s[5].split(".") : [], this.format();
|
|
41
|
-
}
|
|
42
|
-
format() {
|
|
43
|
-
return this.version = `${this.major}.${this.minor}.${this.patch}`, this.prerelease.length && (this.version += `-${this.prerelease.join(".")}`), this.version;
|
|
44
|
-
}
|
|
45
|
-
toString() {
|
|
46
|
-
return this.version;
|
|
47
|
-
}
|
|
48
|
-
compare(e) {
|
|
49
|
-
if (a("SemVer.compare", this.version, this.options, e), !(e instanceof n)) {
|
|
50
|
-
if (typeof e == "string" && e === this.version)
|
|
51
|
-
return 0;
|
|
52
|
-
e = new n(e, this.options);
|
|
53
|
-
}
|
|
54
|
-
return e.version === this.version ? 0 : this.compareMain(e) || this.comparePre(e);
|
|
55
|
-
}
|
|
56
|
-
compareMain(e) {
|
|
57
|
-
return e instanceof n || (e = new n(e, this.options)), this.major < e.major ? -1 : this.major > e.major ? 1 : this.minor < e.minor ? -1 : this.minor > e.minor ? 1 : this.patch < e.patch ? -1 : this.patch > e.patch ? 1 : 0;
|
|
58
|
-
}
|
|
59
|
-
comparePre(e) {
|
|
60
|
-
if (e instanceof n || (e = new n(e, this.options)), this.prerelease.length && !e.prerelease.length)
|
|
61
|
-
return -1;
|
|
62
|
-
if (!this.prerelease.length && e.prerelease.length)
|
|
63
|
-
return 1;
|
|
64
|
-
if (!this.prerelease.length && !e.prerelease.length)
|
|
65
|
-
return 0;
|
|
66
|
-
let r = 0;
|
|
67
|
-
do {
|
|
68
|
-
const s = this.prerelease[r], t = e.prerelease[r];
|
|
69
|
-
if (a("prerelease compare", r, s, t), s === void 0 && t === void 0)
|
|
70
|
-
return 0;
|
|
71
|
-
if (t === void 0)
|
|
72
|
-
return 1;
|
|
73
|
-
if (s === void 0)
|
|
74
|
-
return -1;
|
|
75
|
-
if (s === t)
|
|
76
|
-
continue;
|
|
77
|
-
return p(s, t);
|
|
78
|
-
} while (++r);
|
|
79
|
-
}
|
|
80
|
-
compareBuild(e) {
|
|
81
|
-
e instanceof n || (e = new n(e, this.options));
|
|
82
|
-
let r = 0;
|
|
83
|
-
do {
|
|
84
|
-
const s = this.build[r], t = e.build[r];
|
|
85
|
-
if (a("build compare", r, s, t), s === void 0 && t === void 0)
|
|
86
|
-
return 0;
|
|
87
|
-
if (t === void 0)
|
|
88
|
-
return 1;
|
|
89
|
-
if (s === void 0)
|
|
90
|
-
return -1;
|
|
91
|
-
if (s === t)
|
|
92
|
-
continue;
|
|
93
|
-
return p(s, t);
|
|
94
|
-
} while (++r);
|
|
95
|
-
}
|
|
96
|
-
// preminor will bump the version up to the next minor release, and immediately
|
|
97
|
-
// down to pre-release. premajor and prepatch work the same way.
|
|
98
|
-
inc(e, r, s) {
|
|
99
|
-
if (e.startsWith("pre")) {
|
|
100
|
-
if (!r && s === !1)
|
|
101
|
-
throw new Error("invalid increment argument: identifier is empty");
|
|
102
|
-
if (r) {
|
|
103
|
-
const t = `-${r}`.match(this.options.loose ? l[o.PRERELEASELOOSE] : l[o.PRERELEASE]);
|
|
104
|
-
if (!t || t[1] !== r)
|
|
105
|
-
throw new Error(`invalid identifier: ${r}`);
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
switch (e) {
|
|
109
|
-
case "premajor":
|
|
110
|
-
this.prerelease.length = 0, this.patch = 0, this.minor = 0, this.major++, this.inc("pre", r, s);
|
|
111
|
-
break;
|
|
112
|
-
case "preminor":
|
|
113
|
-
this.prerelease.length = 0, this.patch = 0, this.minor++, this.inc("pre", r, s);
|
|
114
|
-
break;
|
|
115
|
-
case "prepatch":
|
|
116
|
-
this.prerelease.length = 0, this.inc("patch", r, s), this.inc("pre", r, s);
|
|
117
|
-
break;
|
|
118
|
-
// If the input is a non-prerelease version, this acts the same as
|
|
119
|
-
// prepatch.
|
|
120
|
-
case "prerelease":
|
|
121
|
-
this.prerelease.length === 0 && this.inc("patch", r, s), this.inc("pre", r, s);
|
|
122
|
-
break;
|
|
123
|
-
case "release":
|
|
124
|
-
if (this.prerelease.length === 0)
|
|
125
|
-
throw new Error(`version ${this.raw} is not a prerelease`);
|
|
126
|
-
this.prerelease.length = 0;
|
|
127
|
-
break;
|
|
128
|
-
case "major":
|
|
129
|
-
(this.minor !== 0 || this.patch !== 0 || this.prerelease.length === 0) && this.major++, this.minor = 0, this.patch = 0, this.prerelease = [];
|
|
130
|
-
break;
|
|
131
|
-
case "minor":
|
|
132
|
-
(this.patch !== 0 || this.prerelease.length === 0) && this.minor++, this.patch = 0, this.prerelease = [];
|
|
133
|
-
break;
|
|
134
|
-
case "patch":
|
|
135
|
-
this.prerelease.length === 0 && this.patch++, this.prerelease = [];
|
|
136
|
-
break;
|
|
137
|
-
// This probably shouldn't be used publicly.
|
|
138
|
-
// 1.0.0 'pre' would become 1.0.0-0 which is the wrong direction.
|
|
139
|
-
case "pre": {
|
|
140
|
-
const t = Number(s) ? 1 : 0;
|
|
141
|
-
if (this.prerelease.length === 0)
|
|
142
|
-
this.prerelease = [t];
|
|
143
|
-
else {
|
|
144
|
-
let i = this.prerelease.length;
|
|
145
|
-
for (; --i >= 0; )
|
|
146
|
-
typeof this.prerelease[i] == "number" && (this.prerelease[i]++, i = -2);
|
|
147
|
-
if (i === -1) {
|
|
148
|
-
if (r === this.prerelease.join(".") && s === !1)
|
|
149
|
-
throw new Error("invalid increment argument: identifier already exists");
|
|
150
|
-
this.prerelease.push(t);
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
if (r) {
|
|
154
|
-
let i = [r, t];
|
|
155
|
-
s === !1 && (i = [r]), p(this.prerelease[0], r) === 0 ? isNaN(this.prerelease[1]) && (this.prerelease = i) : this.prerelease = i;
|
|
156
|
-
}
|
|
157
|
-
break;
|
|
158
|
-
}
|
|
159
|
-
default:
|
|
160
|
-
throw new Error(`invalid increment argument: ${e}`);
|
|
161
|
-
}
|
|
162
|
-
return this.raw = this.format(), this.build.length && (this.raw += `+${this.build.join(".")}`), this;
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
return c = n, c;
|
|
166
|
-
}
|
|
167
|
-
export {
|
|
168
|
-
k as __require
|
|
169
|
-
};
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { __require as t } from "./parse.js";
|
|
2
|
-
var r, n;
|
|
3
|
-
function l() {
|
|
4
|
-
if (n) return r;
|
|
5
|
-
n = 1;
|
|
6
|
-
const a = t();
|
|
7
|
-
return r = (i, s) => {
|
|
8
|
-
const e = a(i.trim().replace(/^[=v]+/, ""), s);
|
|
9
|
-
return e ? e.version : null;
|
|
10
|
-
}, r;
|
|
11
|
-
}
|
|
12
|
-
export {
|
|
13
|
-
l as __require
|
|
14
|
-
};
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { __require as p } from "./eq.js";
|
|
2
|
-
import { __require as _ } from "./neq.js";
|
|
3
|
-
import { __require as a } from "./gt.js";
|
|
4
|
-
import { __require as v } from "./gte.js";
|
|
5
|
-
import { __require as y } from "./lt.js";
|
|
6
|
-
import { __require as j } from "./lte.js";
|
|
7
|
-
var i, c;
|
|
8
|
-
function L() {
|
|
9
|
-
if (c) return i;
|
|
10
|
-
c = 1;
|
|
11
|
-
const n = p(), o = _(), s = a(), q = v(), f = y(), m = j();
|
|
12
|
-
return i = (r, u, e, t) => {
|
|
13
|
-
switch (u) {
|
|
14
|
-
case "===":
|
|
15
|
-
return typeof r == "object" && (r = r.version), typeof e == "object" && (e = e.version), r === e;
|
|
16
|
-
case "!==":
|
|
17
|
-
return typeof r == "object" && (r = r.version), typeof e == "object" && (e = e.version), r !== e;
|
|
18
|
-
case "":
|
|
19
|
-
case "=":
|
|
20
|
-
case "==":
|
|
21
|
-
return n(r, e, t);
|
|
22
|
-
case "!=":
|
|
23
|
-
return o(r, e, t);
|
|
24
|
-
case ">":
|
|
25
|
-
return s(r, e, t);
|
|
26
|
-
case ">=":
|
|
27
|
-
return q(r, e, t);
|
|
28
|
-
case "<":
|
|
29
|
-
return f(r, e, t);
|
|
30
|
-
case "<=":
|
|
31
|
-
return m(r, e, t);
|
|
32
|
-
default:
|
|
33
|
-
throw new TypeError(`Invalid operator: ${u}`);
|
|
34
|
-
}
|
|
35
|
-
}, i;
|
|
36
|
-
}
|
|
37
|
-
export {
|
|
38
|
-
L as __require
|
|
39
|
-
};
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { __require as C } from "../classes/semver.js";
|
|
2
|
-
import { __require as g } from "./parse.js";
|
|
3
|
-
import { __require as q } from "../internal/re.js";
|
|
4
|
-
var a, i;
|
|
5
|
-
function L() {
|
|
6
|
-
if (i) return a;
|
|
7
|
-
i = 1;
|
|
8
|
-
const f = C(), m = g(), { safeRe: c, t: n } = q();
|
|
9
|
-
return a = (r, t) => {
|
|
10
|
-
if (r instanceof f)
|
|
11
|
-
return r;
|
|
12
|
-
if (typeof r == "number" && (r = String(r)), typeof r != "string")
|
|
13
|
-
return null;
|
|
14
|
-
t = t || {};
|
|
15
|
-
let e = null;
|
|
16
|
-
if (!t.rtl)
|
|
17
|
-
e = r.match(t.includePrerelease ? c[n.COERCEFULL] : c[n.COERCE]);
|
|
18
|
-
else {
|
|
19
|
-
const u = t.includePrerelease ? c[n.COERCERTLFULL] : c[n.COERCERTL];
|
|
20
|
-
let l;
|
|
21
|
-
for (; (l = u.exec(r)) && (!e || e.index + e[0].length !== r.length); )
|
|
22
|
-
(!e || l.index + l[0].length !== e.index + e[0].length) && (e = l), u.lastIndex = l.index + l[1].length + l[2].length;
|
|
23
|
-
u.lastIndex = -1;
|
|
24
|
-
}
|
|
25
|
-
if (e === null)
|
|
26
|
-
return null;
|
|
27
|
-
const s = e[2], d = e[3] || "0", h = e[4] || "0", R = t.includePrerelease && e[5] ? `-${e[5]}` : "", x = t.includePrerelease && e[6] ? `+${e[6]}` : "";
|
|
28
|
-
return m(`${s}.${d}.${h}${R}${x}`, t);
|
|
29
|
-
}, a;
|
|
30
|
-
}
|
|
31
|
-
export {
|
|
32
|
-
L as __require
|
|
33
|
-
};
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { __require as c } from "../classes/semver.js";
|
|
2
|
-
var r, n;
|
|
3
|
-
function s() {
|
|
4
|
-
if (n) return r;
|
|
5
|
-
n = 1;
|
|
6
|
-
const e = c();
|
|
7
|
-
return r = (a, m, i) => {
|
|
8
|
-
const o = new e(a, i), u = new e(m, i);
|
|
9
|
-
return o.compare(u) || o.compareBuild(u);
|
|
10
|
-
}, r;
|
|
11
|
-
}
|
|
12
|
-
export {
|
|
13
|
-
s as __require
|
|
14
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { __require as h } from "./parse.js";
|
|
2
|
-
var o, u;
|
|
3
|
-
function v() {
|
|
4
|
-
if (u) return o;
|
|
5
|
-
u = 1;
|
|
6
|
-
const t = h();
|
|
7
|
-
return o = (p, m) => {
|
|
8
|
-
const r = t(p, null, !0), e = t(m, null, !0), a = r.compare(e);
|
|
9
|
-
if (a === 0)
|
|
10
|
-
return null;
|
|
11
|
-
const s = a > 0, f = s ? r : e, n = s ? e : r, c = !!f.prerelease.length;
|
|
12
|
-
if (!!n.prerelease.length && !c) {
|
|
13
|
-
if (!n.patch && !n.minor)
|
|
14
|
-
return "major";
|
|
15
|
-
if (n.compareMain(f) === 0)
|
|
16
|
-
return n.minor && !n.patch ? "minor" : "patch";
|
|
17
|
-
}
|
|
18
|
-
const i = c ? "pre" : "";
|
|
19
|
-
return r.major !== e.major ? i + "major" : r.minor !== e.minor ? i + "minor" : r.patch !== e.patch ? i + "patch" : "prerelease";
|
|
20
|
-
}, o;
|
|
21
|
-
}
|
|
22
|
-
export {
|
|
23
|
-
v as __require
|
|
24
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { __require as _ } from "../classes/semver.js";
|
|
2
|
-
var c, a;
|
|
3
|
-
function s() {
|
|
4
|
-
if (a) return c;
|
|
5
|
-
a = 1;
|
|
6
|
-
const u = _();
|
|
7
|
-
return c = (e, q, r, n, t) => {
|
|
8
|
-
typeof r == "string" && (t = n, n = r, r = void 0);
|
|
9
|
-
try {
|
|
10
|
-
return new u(
|
|
11
|
-
e instanceof u ? e.version : e,
|
|
12
|
-
r
|
|
13
|
-
).inc(q, n, t).version;
|
|
14
|
-
} catch {
|
|
15
|
-
return null;
|
|
16
|
-
}
|
|
17
|
-
}, c;
|
|
18
|
-
}
|
|
19
|
-
export {
|
|
20
|
-
s as __require
|
|
21
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { __require as i } from "../classes/semver.js";
|
|
2
|
-
var e, a;
|
|
3
|
-
function o() {
|
|
4
|
-
if (a) return e;
|
|
5
|
-
a = 1;
|
|
6
|
-
const t = i();
|
|
7
|
-
return e = (r, u, n = !1) => {
|
|
8
|
-
if (r instanceof t)
|
|
9
|
-
return r;
|
|
10
|
-
try {
|
|
11
|
-
return new t(r, u);
|
|
12
|
-
} catch (s) {
|
|
13
|
-
if (!n)
|
|
14
|
-
return null;
|
|
15
|
-
throw s;
|
|
16
|
-
}
|
|
17
|
-
}, e;
|
|
18
|
-
}
|
|
19
|
-
export {
|
|
20
|
-
o as __require
|
|
21
|
-
};
|