@idetik/core 0.4.0 → 0.4.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/index.d.ts +0 -1
- package/dist/index.js +168 -173
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +1 -1
- package/dist/index.umd.cjs.map +1 -1
- package/dist/types/src/idetik.d.ts +0 -1
- package/dist/types/src/idetik.d.ts.map +1 -1
- package/dist/types/src/utilities/pixel_size_observer.d.ts +2 -3
- package/dist/types/src/utilities/pixel_size_observer.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1037,19 +1037,19 @@ function AA() {
|
|
|
1037
1037
|
return T != Float32Array && (g[1] = 0, g[2] = 0, g[3] = 0, g[4] = 0, g[6] = 0, g[7] = 0, g[8] = 0, g[9] = 0, g[11] = 0, g[12] = 0, g[13] = 0, g[14] = 0), g[0] = 1, g[5] = 1, g[10] = 1, g[15] = 1, g;
|
|
1038
1038
|
}
|
|
1039
1039
|
function ig(g, A) {
|
|
1040
|
-
var I = A[0], B = A[1], Q = A[2], C = A[3], E = A[4], i = A[5], o = A[6], a = A[7], D = A[8], h = A[9], y = A[10], t = A[11], F = A[12], r = A[13], S = A[14],
|
|
1041
|
-
return m ? (m = 1 / m, g[0] = (i *
|
|
1040
|
+
var I = A[0], B = A[1], Q = A[2], C = A[3], E = A[4], i = A[5], o = A[6], a = A[7], D = A[8], h = A[9], y = A[10], t = A[11], F = A[12], r = A[13], S = A[14], n = A[15], c = I * i - B * E, N = I * o - Q * E, M = I * a - C * E, Y = B * o - Q * i, J = B * a - C * i, W = Q * a - C * o, v = D * r - h * F, Z = D * S - y * F, P = D * n - t * F, O = h * S - y * r, nA = h * n - t * r, eA = y * n - t * S, m = c * eA - N * nA + M * O + Y * P - J * Z + W * v;
|
|
1041
|
+
return m ? (m = 1 / m, g[0] = (i * eA - o * nA + a * O) * m, g[1] = (Q * nA - B * eA - C * O) * m, g[2] = (r * W - S * J + n * Y) * m, g[3] = (y * J - h * W - t * Y) * m, g[4] = (o * P - E * eA - a * Z) * m, g[5] = (I * eA - Q * P + C * Z) * m, g[6] = (S * M - F * W - n * N) * m, g[7] = (D * W - y * M + t * N) * m, g[8] = (E * nA - i * P + a * v) * m, g[9] = (B * P - I * nA - C * v) * m, g[10] = (F * J - r * M + n * c) * m, g[11] = (h * M - D * J - t * c) * m, g[12] = (i * Z - E * O - o * v) * m, g[13] = (I * O - B * Z + Q * v) * m, g[14] = (r * N - F * Y - S * c) * m, g[15] = (D * Y - h * N + y * c) * m, g) : null;
|
|
1042
1042
|
}
|
|
1043
|
-
function
|
|
1044
|
-
var B = A[0], Q = A[1], C = A[2], E = A[3], i = A[4], o = A[5], a = A[6], D = A[7], h = A[8], y = A[9], t = A[10], F = A[11], r = A[12], S = A[13],
|
|
1045
|
-
return g[0] = N * B + M * i + Y * h + J * r, g[1] = N * Q + M * o + Y * y + J * S, g[2] = N * C + M * a + Y * t + J *
|
|
1043
|
+
function eI(g, A, I) {
|
|
1044
|
+
var B = A[0], Q = A[1], C = A[2], E = A[3], i = A[4], o = A[5], a = A[6], D = A[7], h = A[8], y = A[9], t = A[10], F = A[11], r = A[12], S = A[13], n = A[14], c = A[15], N = I[0], M = I[1], Y = I[2], J = I[3];
|
|
1045
|
+
return g[0] = N * B + M * i + Y * h + J * r, g[1] = N * Q + M * o + Y * y + J * S, g[2] = N * C + M * a + Y * t + J * n, g[3] = N * E + M * D + Y * F + J * c, N = I[4], M = I[5], Y = I[6], J = I[7], g[4] = N * B + M * i + Y * h + J * r, g[5] = N * Q + M * o + Y * y + J * S, g[6] = N * C + M * a + Y * t + J * n, g[7] = N * E + M * D + Y * F + J * c, N = I[8], M = I[9], Y = I[10], J = I[11], g[8] = N * B + M * i + Y * h + J * r, g[9] = N * Q + M * o + Y * y + J * S, g[10] = N * C + M * a + Y * t + J * n, g[11] = N * E + M * D + Y * F + J * c, N = I[12], M = I[13], Y = I[14], J = I[15], g[12] = N * B + M * i + Y * h + J * r, g[13] = N * Q + M * o + Y * y + J * S, g[14] = N * C + M * a + Y * t + J * n, g[15] = N * E + M * D + Y * F + J * c, g;
|
|
1046
1046
|
}
|
|
1047
1047
|
function DQ(g, A) {
|
|
1048
1048
|
return g[0] = A[0], g[1] = 0, g[2] = 0, g[3] = 0, g[4] = 0, g[5] = A[1], g[6] = 0, g[7] = 0, g[8] = 0, g[9] = 0, g[10] = A[2], g[11] = 0, g[12] = 0, g[13] = 0, g[14] = 0, g[15] = 1, g;
|
|
1049
1049
|
}
|
|
1050
1050
|
function sQ(g, A, I, B) {
|
|
1051
|
-
var Q = A[0], C = A[1], E = A[2], i = A[3], o = Q + Q, a = C + C, D = E + E, h = Q * o, y = Q * a, t = Q * D, F = C * a, r = C * D, S = E * D,
|
|
1052
|
-
return g[0] = (1 - (F + S)) * M, g[1] = (y + N) * M, g[2] = (t - c) * M, g[3] = 0, g[4] = (y - N) * Y, g[5] = (1 - (h + S)) * Y, g[6] = (r +
|
|
1051
|
+
var Q = A[0], C = A[1], E = A[2], i = A[3], o = Q + Q, a = C + C, D = E + E, h = Q * o, y = Q * a, t = Q * D, F = C * a, r = C * D, S = E * D, n = i * o, c = i * a, N = i * D, M = B[0], Y = B[1], J = B[2];
|
|
1052
|
+
return g[0] = (1 - (F + S)) * M, g[1] = (y + N) * M, g[2] = (t - c) * M, g[3] = 0, g[4] = (y - N) * Y, g[5] = (1 - (h + S)) * Y, g[6] = (r + n) * Y, g[7] = 0, g[8] = (t + c) * J, g[9] = (r - n) * J, g[10] = (1 - (h + F)) * J, g[11] = 0, g[12] = I[0], g[13] = I[1], g[14] = I[2], g[15] = 1, g;
|
|
1053
1053
|
}
|
|
1054
1054
|
function hQ(g, A, I, B, Q) {
|
|
1055
1055
|
var C = 1 / Math.tan(A / 2), E;
|
|
@@ -1061,7 +1061,7 @@ function tQ(g, A, I, B, Q, C, E) {
|
|
|
1061
1061
|
return g[0] = -2 * i, g[1] = 0, g[2] = 0, g[3] = 0, g[4] = 0, g[5] = -2 * o, g[6] = 0, g[7] = 0, g[8] = 0, g[9] = 0, g[10] = 2 * a, g[11] = 0, g[12] = (A + I) * i, g[13] = (Q + B) * o, g[14] = (E + C) * a, g[15] = 1, g;
|
|
1062
1062
|
}
|
|
1063
1063
|
var GQ = tQ;
|
|
1064
|
-
function
|
|
1064
|
+
function nQ(g, A, I, B) {
|
|
1065
1065
|
var Q = A[0], C = A[1], E = A[2], i = B[0], o = B[1], a = B[2], D = Q - I[0], h = C - I[1], y = E - I[2], t = D * D + h * h + y * y;
|
|
1066
1066
|
t > 0 && (t = 1 / Math.sqrt(t), D *= t, h *= t, y *= t);
|
|
1067
1067
|
var F = o * y - a * h, r = a * D - i * y, S = i * h - o * D;
|
|
@@ -1092,7 +1092,7 @@ function LA(g, A, I, B) {
|
|
|
1092
1092
|
function tB(g, A, I) {
|
|
1093
1093
|
return g[0] = A[0] + I[0], g[1] = A[1] + I[1], g[2] = A[2] + I[2], g;
|
|
1094
1094
|
}
|
|
1095
|
-
function
|
|
1095
|
+
function eQ(g, A, I) {
|
|
1096
1096
|
return g[0] = A[0] - I[0], g[1] = A[1] - I[1], g[2] = A[2] - I[2], g;
|
|
1097
1097
|
}
|
|
1098
1098
|
function wQ(g, A, I) {
|
|
@@ -1112,7 +1112,7 @@ function FQ(g, A) {
|
|
|
1112
1112
|
var I = A[0], B = A[1], Q = A[2], C = I * I + B * B + Q * Q;
|
|
1113
1113
|
return C > 0 && (C = 1 / Math.sqrt(C)), g[0] = A[0] * C, g[1] = A[1] * C, g[2] = A[2] * C, g;
|
|
1114
1114
|
}
|
|
1115
|
-
function
|
|
1115
|
+
function nB(g, A) {
|
|
1116
1116
|
return g[0] * A[0] + g[1] * A[1] + g[2] * A[2];
|
|
1117
1117
|
}
|
|
1118
1118
|
function TI(g, A, I) {
|
|
@@ -1131,7 +1131,7 @@ function SQ(g, A) {
|
|
|
1131
1131
|
var I = g[0], B = g[1], Q = g[2], C = A[0], E = A[1], i = A[2];
|
|
1132
1132
|
return Math.abs(I - C) <= rA * Math.max(1, Math.abs(I), Math.abs(C)) && Math.abs(B - E) <= rA * Math.max(1, Math.abs(B), Math.abs(E)) && Math.abs(Q - i) <= rA * Math.max(1, Math.abs(Q), Math.abs(i));
|
|
1133
1133
|
}
|
|
1134
|
-
var VI =
|
|
1134
|
+
var VI = eQ, RQ = yB;
|
|
1135
1135
|
(function() {
|
|
1136
1136
|
var g = p();
|
|
1137
1137
|
return function(A, I, B, Q, C, E) {
|
|
@@ -1193,7 +1193,7 @@ function WI(g, A, I, B) {
|
|
|
1193
1193
|
var Q = A[0], C = A[1], E = A[2], i = A[3], o = I[0], a = I[1], D = I[2], h = I[3], y, t, F, r, S;
|
|
1194
1194
|
return t = Q * o + C * a + E * D + i * h, t < 0 && (t = -t, o = -o, a = -a, D = -D, h = -h), 1 - t > rA ? (y = Math.acos(t), F = Math.sin(y), r = Math.sin((1 - B) * y) / F, S = Math.sin(B * y) / F) : (r = 1 - B, S = B), g[0] = r * Q + S * o, g[1] = r * C + S * a, g[2] = r * E + S * D, g[3] = r * i + S * h, g;
|
|
1195
1195
|
}
|
|
1196
|
-
function
|
|
1196
|
+
function eB(g, A) {
|
|
1197
1197
|
var I = A[0] + A[4] + A[8], B;
|
|
1198
1198
|
if (I > 0)
|
|
1199
1199
|
B = Math.sqrt(I + 1), g[3] = 0.5 * B, B = 0.5 / B, g[0] = (A[5] - A[7]) * B, g[1] = (A[6] - A[2]) * B, g[2] = (A[1] - A[3]) * B;
|
|
@@ -1209,7 +1209,7 @@ var YQ = NQ, MQ = cQ, og = kQ;
|
|
|
1209
1209
|
(function() {
|
|
1210
1210
|
var g = p(), A = q(1, 0, 0), I = q(0, 1, 0);
|
|
1211
1211
|
return function(B, Q, C) {
|
|
1212
|
-
var E =
|
|
1212
|
+
var E = nB(Q, C);
|
|
1213
1213
|
return E < -0.999999 ? (TI(g, A, Q), RQ(g) < 1e-6 && TI(g, I, Q), FQ(g, g), LQ(B, g, Math.PI), B) : E > 0.999999 ? (B[0] = 0, B[1] = 0, B[2] = 0, B[3] = 1, B) : (TI(g, Q, C), B[0] = g[0], B[1] = g[1], B[2] = g[2], B[3] = 1 + E, og(B, B));
|
|
1214
1214
|
};
|
|
1215
1215
|
})();
|
|
@@ -1222,7 +1222,7 @@ var YQ = NQ, MQ = cQ, og = kQ;
|
|
|
1222
1222
|
(function() {
|
|
1223
1223
|
var g = hB();
|
|
1224
1224
|
return function(A, I, B, Q) {
|
|
1225
|
-
return g[0] = B[0], g[3] = B[1], g[6] = B[2], g[1] = Q[0], g[4] = Q[1], g[7] = Q[2], g[2] = -I[0], g[5] = -I[1], g[8] = -I[2], og(A,
|
|
1225
|
+
return g[0] = B[0], g[3] = B[1], g[6] = B[2], g[1] = Q[0], g[4] = Q[1], g[7] = Q[2], g[2] = -I[0], g[5] = -I[1], g[8] = -I[2], og(A, eB(A, g));
|
|
1226
1226
|
};
|
|
1227
1227
|
})();
|
|
1228
1228
|
function wB() {
|
|
@@ -1875,11 +1875,11 @@ class uQ extends OB {
|
|
|
1875
1875
|
}
|
|
1876
1876
|
}
|
|
1877
1877
|
drawGeometry(A, I, B, Q, C) {
|
|
1878
|
-
const E =
|
|
1878
|
+
const E = eI(
|
|
1879
1879
|
AA(),
|
|
1880
1880
|
C.viewMatrix,
|
|
1881
1881
|
I.transform.matrix
|
|
1882
|
-
), i =
|
|
1882
|
+
), i = eI(
|
|
1883
1883
|
AA(),
|
|
1884
1884
|
mQ,
|
|
1885
1885
|
C.projectionMatrix
|
|
@@ -2023,8 +2023,8 @@ class bQ {
|
|
|
2023
2023
|
for (let E = 0; E < this.dimensions_.numLods; ++E) {
|
|
2024
2024
|
const i = this.dimensions_.x.lods[E], o = this.dimensions_.y.lods[E], a = this.dimensions_.z?.lods[E], D = i.chunkSize, h = o.chunkSize, y = a?.chunkSize ?? 1, t = Math.ceil(i.size / D), F = Math.ceil(o.size / h), r = Math.ceil((a?.size ?? 1) / y);
|
|
2025
2025
|
for (let S = 0; S < B; ++S)
|
|
2026
|
-
for (let
|
|
2027
|
-
const c = i.translation +
|
|
2026
|
+
for (let n = 0; n < t; ++n) {
|
|
2027
|
+
const c = i.translation + n * i.chunkSize * i.scale;
|
|
2028
2028
|
for (let N = 0; N < F; ++N) {
|
|
2029
2029
|
const M = o.translation + N * o.chunkSize * o.scale;
|
|
2030
2030
|
for (let Y = 0; Y < r; ++Y) {
|
|
@@ -2037,13 +2037,13 @@ class bQ {
|
|
|
2037
2037
|
priority: null,
|
|
2038
2038
|
orderKey: null,
|
|
2039
2039
|
shape: {
|
|
2040
|
-
x: Math.min(D, i.size -
|
|
2040
|
+
x: Math.min(D, i.size - n * D),
|
|
2041
2041
|
y: Math.min(h, o.size - N * h),
|
|
2042
2042
|
z: Math.min(y, (a?.size ?? 1) - Y * y),
|
|
2043
2043
|
c: 1
|
|
2044
2044
|
},
|
|
2045
2045
|
rowAlignmentBytes: 1,
|
|
2046
|
-
chunkIndex: { x:
|
|
2046
|
+
chunkIndex: { x: n, y: N, z: Y, c: S, t: Q },
|
|
2047
2047
|
scale: {
|
|
2048
2048
|
x: i.scale,
|
|
2049
2049
|
y: o.scale,
|
|
@@ -2477,11 +2477,11 @@ var ZA = function(g = 1) {
|
|
|
2477
2477
|
ZA.Panel = function(g, A, I, B) {
|
|
2478
2478
|
var Q = 1 / 0, C = 0, E = Math.round, i = E(window.devicePixelRatio || 1), o = E(80 * i * B), a = E(48 * i * B), D = E(3 * i * B), h = E(2 * i * B), y = E(3 * i * B), t = E(15 * i * B), F = E(74 * i * B), r = E(30 * i * B), S = document.createElement("canvas");
|
|
2479
2479
|
S.width = o, S.height = a, S.style.cssText = `width:${E(B * 80)}px;height:${E(B * 48)}px`;
|
|
2480
|
-
var
|
|
2481
|
-
return
|
|
2480
|
+
var n = S.getContext("2d");
|
|
2481
|
+
return n.font = "bold " + E(9 * i * B) + "px Helvetica,Arial,sans-serif", n.textBaseline = "top", n.fillStyle = I, n.fillRect(0, 0, o, a), n.fillStyle = A, n.fillText(g, D, h), n.fillRect(y, t, F, r), n.fillStyle = I, n.globalAlpha = 0.9, n.fillRect(y, t, F, r), {
|
|
2482
2482
|
dom: S,
|
|
2483
2483
|
update: function(c, N) {
|
|
2484
|
-
Q = Math.min(Q, c), C = Math.max(C, c),
|
|
2484
|
+
Q = Math.min(Q, c), C = Math.max(C, c), n.fillStyle = I, n.globalAlpha = 1, n.fillRect(0, 0, o, t), n.fillStyle = A, n.fillText(E(c) + " " + g + " (" + E(Q) + "-" + E(C) + ")", D, h), n.drawImage(S, y + i, t, F - i, r, y, t, F - i, r), n.fillRect(y + F - i, t, i, r), n.fillStyle = I, n.globalAlpha = 0.9, n.fillRect(y + F - i, t, i, E((1 - c / N) * r));
|
|
2485
2485
|
}
|
|
2486
2486
|
};
|
|
2487
2487
|
};
|
|
@@ -2711,9 +2711,9 @@ class IC {
|
|
|
2711
2711
|
resizeObserver_;
|
|
2712
2712
|
mediaQuery_;
|
|
2713
2713
|
onMediaQueryChange_;
|
|
2714
|
-
|
|
2715
|
-
constructor(A = []) {
|
|
2716
|
-
this.elements_ = A;
|
|
2714
|
+
onChange_;
|
|
2715
|
+
constructor(A = [], I) {
|
|
2716
|
+
this.elements_ = A, this.onChange_ = I;
|
|
2717
2717
|
}
|
|
2718
2718
|
connect() {
|
|
2719
2719
|
if (this.resizeObserver_) {
|
|
@@ -2724,21 +2724,17 @@ class IC {
|
|
|
2724
2724
|
return;
|
|
2725
2725
|
}
|
|
2726
2726
|
this.resizeObserver_ = new ResizeObserver(() => {
|
|
2727
|
-
this.
|
|
2727
|
+
this.onChange_();
|
|
2728
2728
|
});
|
|
2729
2729
|
for (const A of this.elements_)
|
|
2730
2730
|
this.resizeObserver_.observe(A);
|
|
2731
2731
|
this.startDevicePixelRatioObserver();
|
|
2732
2732
|
}
|
|
2733
|
-
getAndResetChanged() {
|
|
2734
|
-
const A = this.changed_;
|
|
2735
|
-
return this.changed_ = !1, A;
|
|
2736
|
-
}
|
|
2737
2733
|
startDevicePixelRatioObserver() {
|
|
2738
2734
|
this.mediaQuery_ = matchMedia(
|
|
2739
2735
|
`(resolution: ${window.devicePixelRatio}dppx)`
|
|
2740
2736
|
), this.onMediaQueryChange_ = () => {
|
|
2741
|
-
this.
|
|
2737
|
+
this.onChange_(), this.startDevicePixelRatioObserver();
|
|
2742
2738
|
}, this.mediaQuery_.addEventListener("change", this.onMediaQueryChange_, {
|
|
2743
2739
|
once: !0
|
|
2744
2740
|
});
|
|
@@ -2825,7 +2821,11 @@ class Do {
|
|
|
2825
2821
|
const I = [this.canvas];
|
|
2826
2822
|
for (const B of this.viewports_)
|
|
2827
2823
|
B.element !== this.canvas && I.push(B.element);
|
|
2828
|
-
this.sizeObserver_ = new IC(I)
|
|
2824
|
+
this.sizeObserver_ = new IC(I, () => {
|
|
2825
|
+
this.renderer_.updateSize();
|
|
2826
|
+
for (const B of this.viewports_)
|
|
2827
|
+
B.updateSize(), this.renderer_.render(B);
|
|
2828
|
+
});
|
|
2829
2829
|
}
|
|
2830
2830
|
get renderedObjects() {
|
|
2831
2831
|
return this.renderer_.renderedObjects;
|
|
@@ -2855,7 +2855,7 @@ class Do {
|
|
|
2855
2855
|
return this;
|
|
2856
2856
|
}
|
|
2857
2857
|
animate(A) {
|
|
2858
|
-
this.stats_ && this.stats_.begin()
|
|
2858
|
+
this.stats_ && this.stats_.begin();
|
|
2859
2859
|
for (const I of this.viewports_)
|
|
2860
2860
|
this.renderer_.render(I);
|
|
2861
2861
|
this.chunkManager_.update();
|
|
@@ -2875,11 +2875,6 @@ class Do {
|
|
|
2875
2875
|
cancelAnimationFrame(this.lastAnimationId_), this.lastAnimationId_ = void 0;
|
|
2876
2876
|
}
|
|
2877
2877
|
}
|
|
2878
|
-
updateSize() {
|
|
2879
|
-
this.renderer_.updateSize();
|
|
2880
|
-
for (const A of this.viewports_)
|
|
2881
|
-
A.updateSize();
|
|
2882
|
-
}
|
|
2883
2878
|
}
|
|
2884
2879
|
class gC extends pA {
|
|
2885
2880
|
constructor(A) {
|
|
@@ -2939,8 +2934,8 @@ class QC {
|
|
|
2939
2934
|
}
|
|
2940
2935
|
targetTo(A) {
|
|
2941
2936
|
SQ(this.translation_, A) && (A = IA(A), A[2] += rA);
|
|
2942
|
-
const I =
|
|
2943
|
-
|
|
2937
|
+
const I = nQ(AA(), this.translation_, A, BC), B = aQ(hB(), I);
|
|
2938
|
+
eB(this.rotation_, B), og(this.rotation_, this.rotation_), this.dirty_ = !0;
|
|
2944
2939
|
}
|
|
2945
2940
|
get scale() {
|
|
2946
2941
|
return IA(this.scale_);
|
|
@@ -3029,7 +3024,7 @@ class JA {
|
|
|
3029
3024
|
this.normal = IA(A), this.signedDistance = I;
|
|
3030
3025
|
}
|
|
3031
3026
|
signedDistanceToPoint(A) {
|
|
3032
|
-
return
|
|
3027
|
+
return nB(this.normal, A) + this.signedDistance;
|
|
3033
3028
|
}
|
|
3034
3029
|
normalize() {
|
|
3035
3030
|
const A = yB(this.normal);
|
|
@@ -3108,7 +3103,7 @@ class rB extends mA {
|
|
|
3108
3103
|
}
|
|
3109
3104
|
get frustum() {
|
|
3110
3105
|
return new CC(
|
|
3111
|
-
|
|
3106
|
+
eI(AA(), this.projectionMatrix, this.viewMatrix)
|
|
3112
3107
|
);
|
|
3113
3108
|
}
|
|
3114
3109
|
pan(A) {
|
|
@@ -3167,7 +3162,7 @@ class so extends rB {
|
|
|
3167
3162
|
}
|
|
3168
3163
|
getWorldViewRect() {
|
|
3169
3164
|
let A = vI(-1, -1, 0, 1), I = vI(1, 1, 0, 1);
|
|
3170
|
-
const B =
|
|
3165
|
+
const B = eI(
|
|
3171
3166
|
AA(),
|
|
3172
3167
|
this.projectionMatrix,
|
|
3173
3168
|
this.viewMatrix
|
|
@@ -3517,7 +3512,7 @@ function oC(g) {
|
|
|
3517
3512
|
const [I, B] = A(0), [Q, C] = A(1), [E, i] = A(2);
|
|
3518
3513
|
return { xMin: I, xMax: B, yMin: Q, yMax: C, zMin: E, zMax: i };
|
|
3519
3514
|
}
|
|
3520
|
-
class
|
|
3515
|
+
class no extends GA {
|
|
3521
3516
|
type = "TracksLayer";
|
|
3522
3517
|
tracks_ = [];
|
|
3523
3518
|
constructor(A = []) {
|
|
@@ -3604,14 +3599,14 @@ class RB extends pA {
|
|
|
3604
3599
|
for (let t = 0; t < D; ++t) {
|
|
3605
3600
|
const F = t * y;
|
|
3606
3601
|
for (let r = 0; r < a; ++r) {
|
|
3607
|
-
const S = r * h,
|
|
3602
|
+
const S = r * h, n = r / i, c = t / o, N = [S, F, 0], M = [0, 0, 1], Y = [n, c];
|
|
3608
3603
|
C.push(...N, ...M, ...Y);
|
|
3609
3604
|
}
|
|
3610
3605
|
}
|
|
3611
3606
|
for (let t = 0; t < o; ++t)
|
|
3612
3607
|
for (let F = 0; F < i; ++F) {
|
|
3613
|
-
const r = F + a * t, S = F + a * (t + 1),
|
|
3614
|
-
E.push(r, S, c), E.push(S,
|
|
3608
|
+
const r = F + a * t, S = F + a * (t + 1), n = F + 1 + a * (t + 1), c = F + 1 + a * t;
|
|
3609
|
+
E.push(r, S, c), E.push(S, n, c);
|
|
3615
3610
|
}
|
|
3616
3611
|
this.vertexData_ = new Float32Array(C), this.indexData_ = new Uint32Array(E), this.addAttribute({
|
|
3617
3612
|
type: "position",
|
|
@@ -3767,7 +3762,7 @@ function tC(g) {
|
|
|
3767
3762
|
if (g.type === "Texture2D")
|
|
3768
3763
|
return GC(g.dataType);
|
|
3769
3764
|
if (g.type === "Texture2DArray")
|
|
3770
|
-
return
|
|
3765
|
+
return nC(g.dataType);
|
|
3771
3766
|
throw new Error(`Unsupported image texture type: ${g.type}`);
|
|
3772
3767
|
}
|
|
3773
3768
|
function GC(g) {
|
|
@@ -3784,7 +3779,7 @@ function GC(g) {
|
|
|
3784
3779
|
return "floatScalarImage";
|
|
3785
3780
|
}
|
|
3786
3781
|
}
|
|
3787
|
-
function
|
|
3782
|
+
function nC(g) {
|
|
3788
3783
|
switch (g) {
|
|
3789
3784
|
case "byte":
|
|
3790
3785
|
case "int":
|
|
@@ -3872,7 +3867,7 @@ function hg(g, A, I, B, Q = 3) {
|
|
|
3872
3867
|
return A;
|
|
3873
3868
|
}
|
|
3874
3869
|
}
|
|
3875
|
-
class
|
|
3870
|
+
class eC {
|
|
3876
3871
|
bins_ = /* @__PURE__ */ new Map();
|
|
3877
3872
|
acquire(A) {
|
|
3878
3873
|
const B = this.bins_.get(A)?.pop();
|
|
@@ -3893,7 +3888,7 @@ class NB extends GA {
|
|
|
3893
3888
|
sliceCoords_;
|
|
3894
3889
|
onPickValue_;
|
|
3895
3890
|
visibleChunks_ = /* @__PURE__ */ new Map();
|
|
3896
|
-
pool_ = new
|
|
3891
|
+
pool_ = new eC();
|
|
3897
3892
|
initialChannelProps_;
|
|
3898
3893
|
channelChangeCallbacks_ = [];
|
|
3899
3894
|
policy_;
|
|
@@ -4173,15 +4168,15 @@ class wC extends pA {
|
|
|
4173
4168
|
});
|
|
4174
4169
|
}
|
|
4175
4170
|
buildFace(A, I, B, Q, C, E, i, o, a, D, h, y, t) {
|
|
4176
|
-
const F = E / a, r = i / D, S = E / 2,
|
|
4171
|
+
const F = E / a, r = i / D, S = E / 2, n = i / 2, c = o / 2 * h, N = a + 1, M = D + 1, Y = y.length / 8;
|
|
4177
4172
|
for (let J = 0; J < M; J++) {
|
|
4178
|
-
const W = -
|
|
4173
|
+
const W = -n + J * r;
|
|
4179
4174
|
for (let v = 0; v < N; v++) {
|
|
4180
4175
|
const Z = -S + v * F, P = { x: 0, y: 0, z: 0 };
|
|
4181
4176
|
P[A] = Z * Q, P[I] = W * C, P[B] = c;
|
|
4182
4177
|
const O = { x: 0, y: 0, z: 0 };
|
|
4183
4178
|
O[B] = h;
|
|
4184
|
-
const
|
|
4179
|
+
const nA = v / a, eA = 1 - J / D;
|
|
4185
4180
|
y.push(
|
|
4186
4181
|
P.x,
|
|
4187
4182
|
P.y,
|
|
@@ -4189,8 +4184,8 @@ class wC extends pA {
|
|
|
4189
4184
|
O.x,
|
|
4190
4185
|
O.y,
|
|
4191
4186
|
O.z,
|
|
4192
|
-
|
|
4193
|
-
|
|
4187
|
+
nA,
|
|
4188
|
+
eA
|
|
4194
4189
|
);
|
|
4195
4190
|
}
|
|
4196
4191
|
}
|
|
@@ -4223,7 +4218,7 @@ function rC(g) {
|
|
|
4223
4218
|
return "floatVolume";
|
|
4224
4219
|
}
|
|
4225
4220
|
}
|
|
4226
|
-
class
|
|
4221
|
+
class eo extends GA {
|
|
4227
4222
|
type = "VolumeLayer";
|
|
4228
4223
|
constructor() {
|
|
4229
4224
|
super();
|
|
@@ -4875,7 +4870,7 @@ class cB {
|
|
|
4875
4870
|
yield this.get(A);
|
|
4876
4871
|
}
|
|
4877
4872
|
}
|
|
4878
|
-
class
|
|
4873
|
+
class ng {
|
|
4879
4874
|
_data;
|
|
4880
4875
|
chars;
|
|
4881
4876
|
#A;
|
|
@@ -5009,7 +5004,7 @@ function UB(g) {
|
|
|
5009
5004
|
let A = g.match(MC);
|
|
5010
5005
|
if (A) {
|
|
5011
5006
|
let [, B, Q] = A;
|
|
5012
|
-
return (B === "U" ? aI :
|
|
5007
|
+
return (B === "U" ? aI : ng).bind(null, Number(Q));
|
|
5013
5008
|
}
|
|
5014
5009
|
let I = YC[g];
|
|
5015
5010
|
if (!I)
|
|
@@ -5163,10 +5158,10 @@ class KI {
|
|
|
5163
5158
|
};
|
|
5164
5159
|
}
|
|
5165
5160
|
}
|
|
5166
|
-
class
|
|
5161
|
+
class eg {
|
|
5167
5162
|
kind = "bytes_to_bytes";
|
|
5168
5163
|
static fromConfig() {
|
|
5169
|
-
return new
|
|
5164
|
+
return new eg();
|
|
5170
5165
|
}
|
|
5171
5166
|
encode(A) {
|
|
5172
5167
|
throw new Error("Not implemented");
|
|
@@ -5245,7 +5240,7 @@ class wg {
|
|
|
5245
5240
|
}
|
|
5246
5241
|
}
|
|
5247
5242
|
function jg(g) {
|
|
5248
|
-
return g instanceof cB || g instanceof
|
|
5243
|
+
return g instanceof cB || g instanceof ng || g instanceof aI ? new Proxy(g, {
|
|
5249
5244
|
get(I, B) {
|
|
5250
5245
|
return I.get(Number(B));
|
|
5251
5246
|
},
|
|
@@ -5256,7 +5251,7 @@ function jg(g) {
|
|
|
5256
5251
|
}
|
|
5257
5252
|
function bC(g, A) {
|
|
5258
5253
|
let I;
|
|
5259
|
-
return g.data instanceof
|
|
5254
|
+
return g.data instanceof ng || g.data instanceof aI ? I = new g.constructor(
|
|
5260
5255
|
// @ts-expect-error
|
|
5261
5256
|
g.data.length,
|
|
5262
5257
|
g.data.chars
|
|
@@ -5327,7 +5322,7 @@ class rg {
|
|
|
5327
5322
|
}
|
|
5328
5323
|
}
|
|
5329
5324
|
function OC() {
|
|
5330
|
-
return (/* @__PURE__ */ new Map()).set("blosc", () => import("./blosc-BOWv2fO7.js").then((g) => g.default)).set("gzip", () => import("./gzip-DchmmbTG.js").then((g) => g.default)).set("lz4", () => import("./lz4-DUlZKApi.js").then((g) => g.default)).set("zlib", () => import("./zlib-Din1wO0I.js").then((g) => g.default)).set("zstd", () => import("./zstd-DnzmycJs.js").then((g) => g.default)).set("transpose", () => Fg).set("bytes", () => KI).set("crc32c", () =>
|
|
5325
|
+
return (/* @__PURE__ */ new Map()).set("blosc", () => import("./blosc-BOWv2fO7.js").then((g) => g.default)).set("gzip", () => import("./gzip-DchmmbTG.js").then((g) => g.default)).set("lz4", () => import("./lz4-DUlZKApi.js").then((g) => g.default)).set("zlib", () => import("./zlib-Din1wO0I.js").then((g) => g.default)).set("zstd", () => import("./zstd-DnzmycJs.js").then((g) => g.default)).set("transpose", () => Fg).set("bytes", () => KI).set("crc32c", () => eg).set("vlen-utf8", () => rg).set("json2", () => wg).set("bitround", () => Gg);
|
|
5331
5326
|
}
|
|
5332
5327
|
const VC = OC();
|
|
5333
5328
|
function Ag(g) {
|
|
@@ -5404,11 +5399,11 @@ function XC(g, A, I, B) {
|
|
|
5404
5399
|
}
|
|
5405
5400
|
if (h === null)
|
|
5406
5401
|
return;
|
|
5407
|
-
let { data: y, shape: t, stride: F } = h, r = o.map((c, N) => c % t[N]).reduce((c, N, M) => c + N * F[M], 0), S = y[r],
|
|
5408
|
-
if (!(S === _g &&
|
|
5402
|
+
let { data: y, shape: t, stride: F } = h, r = o.map((c, N) => c % t[N]).reduce((c, N, M) => c + N * F[M], 0), S = y[r], n = y[r + 1];
|
|
5403
|
+
if (!(S === _g && n === _g))
|
|
5409
5404
|
return Q(D, {
|
|
5410
5405
|
offset: Number(S),
|
|
5411
|
-
length: Number(
|
|
5406
|
+
length: Number(n)
|
|
5412
5407
|
});
|
|
5413
5408
|
};
|
|
5414
5409
|
}
|
|
@@ -5780,7 +5775,7 @@ function GE(g, A) {
|
|
|
5780
5775
|
let I = [];
|
|
5781
5776
|
return g === null ? I = A.map((B) => SI(null)) : Array.isArray(g) && (I = g.map((B) => B ?? SI(null))), hE(I, A), I;
|
|
5782
5777
|
}
|
|
5783
|
-
class
|
|
5778
|
+
class nE {
|
|
5784
5779
|
dim_indexers;
|
|
5785
5780
|
shape;
|
|
5786
5781
|
constructor({ selection: A, shape: I, chunk_shape: B }) {
|
|
@@ -5798,11 +5793,11 @@ class eE {
|
|
|
5798
5793
|
}
|
|
5799
5794
|
}
|
|
5800
5795
|
}
|
|
5801
|
-
function
|
|
5796
|
+
function eE(g, A) {
|
|
5802
5797
|
return "get" in g ? g.get(A) : g[A];
|
|
5803
5798
|
}
|
|
5804
5799
|
async function wE(g, A, I, B) {
|
|
5805
|
-
let Q = jC(g), C = new
|
|
5800
|
+
let Q = jC(g), C = new nE({
|
|
5806
5801
|
selection: A,
|
|
5807
5802
|
shape: g.shape,
|
|
5808
5803
|
chunk_shape: g.chunks
|
|
@@ -5812,7 +5807,7 @@ async function wE(g, A, I, B) {
|
|
|
5812
5807
|
let { data: D, shape: h, stride: y } = await g.getChunk(o, I.opts), t = B.prepare(D, h, y);
|
|
5813
5808
|
B.set_from_chunk(E, t, a);
|
|
5814
5809
|
});
|
|
5815
|
-
return await i.onIdle(), C.shape.length === 0 ?
|
|
5810
|
+
return await i.onIdle(), C.shape.length === 0 ? eE(E.data, 0) : E;
|
|
5816
5811
|
}
|
|
5817
5812
|
function Ng(g, A = 0, I) {
|
|
5818
5813
|
let B = I ?? g.length - A;
|
|
@@ -5907,8 +5902,8 @@ function tI(g, A, I, B) {
|
|
|
5907
5902
|
}
|
|
5908
5903
|
if (Q.to === null) {
|
|
5909
5904
|
if (C.length === 0) {
|
|
5910
|
-
let
|
|
5911
|
-
g.data.set(A.data.subarray(
|
|
5905
|
+
let n = Q.from * I;
|
|
5906
|
+
g.data.set(A.data.subarray(n, n + I), 0);
|
|
5912
5907
|
return;
|
|
5913
5908
|
}
|
|
5914
5909
|
tI(g, {
|
|
@@ -5920,22 +5915,22 @@ function tI(g, A, I, B) {
|
|
|
5920
5915
|
const [D, h, y] = Q.to, [t, F, r] = Q.from, S = JB(D, h, y);
|
|
5921
5916
|
if (C.length === 0) {
|
|
5922
5917
|
if (y === 1 && r === 1 && E === 1 && o === 1) {
|
|
5923
|
-
let
|
|
5924
|
-
g.data.set(A.data.subarray(
|
|
5918
|
+
let n = t * I, c = S * I;
|
|
5919
|
+
g.data.set(A.data.subarray(n, n + c), D * I);
|
|
5925
5920
|
return;
|
|
5926
5921
|
}
|
|
5927
|
-
for (let
|
|
5928
|
-
let c = o * (t + r *
|
|
5929
|
-
g.data.set(A.data.subarray(c, c + I), E * (D + y *
|
|
5922
|
+
for (let n = 0; n < S; n++) {
|
|
5923
|
+
let c = o * (t + r * n) * I;
|
|
5924
|
+
g.data.set(A.data.subarray(c, c + I), E * (D + y * n) * I);
|
|
5930
5925
|
}
|
|
5931
5926
|
return;
|
|
5932
5927
|
}
|
|
5933
|
-
for (let
|
|
5928
|
+
for (let n = 0; n < S; n++)
|
|
5934
5929
|
tI({
|
|
5935
|
-
data: g.data.subarray(E * (D +
|
|
5930
|
+
data: g.data.subarray(E * (D + n * y) * I),
|
|
5936
5931
|
stride: i
|
|
5937
5932
|
}, {
|
|
5938
|
-
data: A.data.subarray(o * (t +
|
|
5933
|
+
data: A.data.subarray(o * (t + n * r) * I),
|
|
5939
5934
|
stride: a
|
|
5940
5935
|
}, I, C);
|
|
5941
5936
|
}
|
|
@@ -6040,12 +6035,12 @@ class Ug extends uA {
|
|
|
6040
6035
|
x-amz-content-sha256:UNSIGNED-PAYLOAD
|
|
6041
6036
|
x-amz-date:${o}
|
|
6042
6037
|
` + (C ? `x-amz-security-token:${C}
|
|
6043
|
-
` : ""), r = C ? "host;x-amz-content-sha256;x-amz-date;x-amz-security-token" : "host;x-amz-content-sha256;x-amz-date", S = "UNSIGNED-PAYLOAD",
|
|
6038
|
+
` : ""), r = C ? "host;x-amz-content-sha256;x-amz-date;x-amz-security-token" : "host;x-amz-content-sha256;x-amz-date", S = "UNSIGNED-PAYLOAD", n = `${I}
|
|
6044
6039
|
${y}
|
|
6045
6040
|
${t}
|
|
6046
6041
|
${F}
|
|
6047
6042
|
${r}
|
|
6048
|
-
${S}`, c = "AWS4-HMAC-SHA256", N = `${a}/${E}/${i}/aws4_request`, M = await this.sha256(
|
|
6043
|
+
${S}`, c = "AWS4-HMAC-SHA256", N = `${a}/${E}/${i}/aws4_request`, M = await this.sha256(n), Y = `${c}
|
|
6049
6044
|
${o}
|
|
6050
6045
|
${N}
|
|
6051
6046
|
${M}`, J = await this.getSignatureKey(
|
|
@@ -10134,7 +10129,7 @@ class mE {
|
|
|
10134
10129
|
throw new Error(
|
|
10135
10130
|
"Invalid row alignment value. Possible values are 1, 2, 4, or 8"
|
|
10136
10131
|
);
|
|
10137
|
-
const a = (
|
|
10132
|
+
const a = (n, c) => typeof n == "number" ? n * c.scale + c.translation : n.start === null ? c.translation : n.start * c.scale + c.translation, D = this.dimensions_.x.lods[I], h = Q[this.dimensions_.x.index], y = a(h, D), t = Q[this.dimensions_.y.index], F = this.dimensions_.y.lods[I], r = a(t, F);
|
|
10138
10133
|
return {
|
|
10139
10134
|
state: "loaded",
|
|
10140
10135
|
lod: I,
|
|
@@ -10186,11 +10181,11 @@ function uE(g, A) {
|
|
|
10186
10181
|
const I = g.axes.map((h) => h.name), B = g.axes.length, Q = EB(I, "x"), C = EB(I, "y"), E = (h, y) => {
|
|
10187
10182
|
const t = [];
|
|
10188
10183
|
for (let F = 0; F < g.datasets.length; F++) {
|
|
10189
|
-
const r = g.datasets[F], S = A[F],
|
|
10184
|
+
const r = g.datasets[F], S = A[F], n = r.coordinateTransformations[0].scale, c = r.coordinateTransformations.length === 2 ? r.coordinateTransformations[1].translation : new Array(B).fill(0);
|
|
10190
10185
|
t.push({
|
|
10191
10186
|
size: S.shape[y],
|
|
10192
10187
|
chunkSize: S.chunks[y],
|
|
10193
|
-
scale:
|
|
10188
|
+
scale: n[y],
|
|
10194
10189
|
translation: c[y]
|
|
10195
10190
|
});
|
|
10196
10191
|
}
|
|
@@ -10483,7 +10478,7 @@ const cI = (g) => {
|
|
|
10483
10478
|
message: i
|
|
10484
10479
|
};
|
|
10485
10480
|
}, xE = [];
|
|
10486
|
-
function
|
|
10481
|
+
function e(g, A) {
|
|
10487
10482
|
const I = NI(), B = cI({
|
|
10488
10483
|
issueData: A,
|
|
10489
10484
|
data: g.data,
|
|
@@ -10848,7 +10843,7 @@ class $ extends K {
|
|
|
10848
10843
|
_parse(A) {
|
|
10849
10844
|
if (this._def.coerce && (A.data = String(A.data)), this._getType(A) !== w.string) {
|
|
10850
10845
|
const C = this._getOrReturnCtx(A);
|
|
10851
|
-
return
|
|
10846
|
+
return e(C, {
|
|
10852
10847
|
code: G.invalid_type,
|
|
10853
10848
|
expected: w.string,
|
|
10854
10849
|
received: C.parsedType
|
|
@@ -10858,7 +10853,7 @@ class $ extends K {
|
|
|
10858
10853
|
let Q;
|
|
10859
10854
|
for (const C of this._def.checks)
|
|
10860
10855
|
if (C.kind === "min")
|
|
10861
|
-
A.data.length < C.value && (Q = this._getOrReturnCtx(A, Q),
|
|
10856
|
+
A.data.length < C.value && (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10862
10857
|
code: G.too_small,
|
|
10863
10858
|
minimum: C.value,
|
|
10864
10859
|
type: "string",
|
|
@@ -10867,7 +10862,7 @@ class $ extends K {
|
|
|
10867
10862
|
message: C.message
|
|
10868
10863
|
}), B.dirty());
|
|
10869
10864
|
else if (C.kind === "max")
|
|
10870
|
-
A.data.length > C.value && (Q = this._getOrReturnCtx(A, Q),
|
|
10865
|
+
A.data.length > C.value && (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10871
10866
|
code: G.too_big,
|
|
10872
10867
|
maximum: C.value,
|
|
10873
10868
|
type: "string",
|
|
@@ -10877,14 +10872,14 @@ class $ extends K {
|
|
|
10877
10872
|
}), B.dirty());
|
|
10878
10873
|
else if (C.kind === "length") {
|
|
10879
10874
|
const E = A.data.length > C.value, i = A.data.length < C.value;
|
|
10880
|
-
(E || i) && (Q = this._getOrReturnCtx(A, Q), E ?
|
|
10875
|
+
(E || i) && (Q = this._getOrReturnCtx(A, Q), E ? e(Q, {
|
|
10881
10876
|
code: G.too_big,
|
|
10882
10877
|
maximum: C.value,
|
|
10883
10878
|
type: "string",
|
|
10884
10879
|
inclusive: !0,
|
|
10885
10880
|
exact: !0,
|
|
10886
10881
|
message: C.message
|
|
10887
|
-
}) : i &&
|
|
10882
|
+
}) : i && e(Q, {
|
|
10888
10883
|
code: G.too_small,
|
|
10889
10884
|
minimum: C.value,
|
|
10890
10885
|
type: "string",
|
|
@@ -10893,43 +10888,43 @@ class $ extends K {
|
|
|
10893
10888
|
message: C.message
|
|
10894
10889
|
}), B.dirty());
|
|
10895
10890
|
} else if (C.kind === "email")
|
|
10896
|
-
jE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10891
|
+
jE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10897
10892
|
validation: "email",
|
|
10898
10893
|
code: G.invalid_string,
|
|
10899
10894
|
message: C.message
|
|
10900
10895
|
}), B.dirty());
|
|
10901
10896
|
else if (C.kind === "emoji")
|
|
10902
|
-
OI || (OI = new RegExp(zE, "u")), OI.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10897
|
+
OI || (OI = new RegExp(zE, "u")), OI.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10903
10898
|
validation: "emoji",
|
|
10904
10899
|
code: G.invalid_string,
|
|
10905
10900
|
message: C.message
|
|
10906
10901
|
}), B.dirty());
|
|
10907
10902
|
else if (C.kind === "uuid")
|
|
10908
|
-
OE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10903
|
+
OE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10909
10904
|
validation: "uuid",
|
|
10910
10905
|
code: G.invalid_string,
|
|
10911
10906
|
message: C.message
|
|
10912
10907
|
}), B.dirty());
|
|
10913
10908
|
else if (C.kind === "nanoid")
|
|
10914
|
-
VE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10909
|
+
VE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10915
10910
|
validation: "nanoid",
|
|
10916
10911
|
code: G.invalid_string,
|
|
10917
10912
|
message: C.message
|
|
10918
10913
|
}), B.dirty());
|
|
10919
10914
|
else if (C.kind === "cuid")
|
|
10920
|
-
bE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10915
|
+
bE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10921
10916
|
validation: "cuid",
|
|
10922
10917
|
code: G.invalid_string,
|
|
10923
10918
|
message: C.message
|
|
10924
10919
|
}), B.dirty());
|
|
10925
10920
|
else if (C.kind === "cuid2")
|
|
10926
|
-
ZE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10921
|
+
ZE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10927
10922
|
validation: "cuid2",
|
|
10928
10923
|
code: G.invalid_string,
|
|
10929
10924
|
message: C.message
|
|
10930
10925
|
}), B.dirty());
|
|
10931
10926
|
else if (C.kind === "ulid")
|
|
10932
|
-
PE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10927
|
+
PE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10933
10928
|
validation: "ulid",
|
|
10934
10929
|
code: G.invalid_string,
|
|
10935
10930
|
message: C.message
|
|
@@ -10938,61 +10933,61 @@ class $ extends K {
|
|
|
10938
10933
|
try {
|
|
10939
10934
|
new URL(A.data);
|
|
10940
10935
|
} catch {
|
|
10941
|
-
Q = this._getOrReturnCtx(A, Q),
|
|
10936
|
+
Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10942
10937
|
validation: "url",
|
|
10943
10938
|
code: G.invalid_string,
|
|
10944
10939
|
message: C.message
|
|
10945
10940
|
}), B.dirty();
|
|
10946
10941
|
}
|
|
10947
|
-
else C.kind === "regex" ? (C.regex.lastIndex = 0, C.regex.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10942
|
+
else C.kind === "regex" ? (C.regex.lastIndex = 0, C.regex.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10948
10943
|
validation: "regex",
|
|
10949
10944
|
code: G.invalid_string,
|
|
10950
10945
|
message: C.message
|
|
10951
|
-
}), B.dirty())) : C.kind === "trim" ? A.data = A.data.trim() : C.kind === "includes" ? A.data.includes(C.value, C.position) || (Q = this._getOrReturnCtx(A, Q),
|
|
10946
|
+
}), B.dirty())) : C.kind === "trim" ? A.data = A.data.trim() : C.kind === "includes" ? A.data.includes(C.value, C.position) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10952
10947
|
code: G.invalid_string,
|
|
10953
10948
|
validation: { includes: C.value, position: C.position },
|
|
10954
10949
|
message: C.message
|
|
10955
|
-
}), B.dirty()) : C.kind === "toLowerCase" ? A.data = A.data.toLowerCase() : C.kind === "toUpperCase" ? A.data = A.data.toUpperCase() : C.kind === "startsWith" ? A.data.startsWith(C.value) || (Q = this._getOrReturnCtx(A, Q),
|
|
10950
|
+
}), B.dirty()) : C.kind === "toLowerCase" ? A.data = A.data.toLowerCase() : C.kind === "toUpperCase" ? A.data = A.data.toUpperCase() : C.kind === "startsWith" ? A.data.startsWith(C.value) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10956
10951
|
code: G.invalid_string,
|
|
10957
10952
|
validation: { startsWith: C.value },
|
|
10958
10953
|
message: C.message
|
|
10959
|
-
}), B.dirty()) : C.kind === "endsWith" ? A.data.endsWith(C.value) || (Q = this._getOrReturnCtx(A, Q),
|
|
10954
|
+
}), B.dirty()) : C.kind === "endsWith" ? A.data.endsWith(C.value) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10960
10955
|
code: G.invalid_string,
|
|
10961
10956
|
validation: { endsWith: C.value },
|
|
10962
10957
|
message: C.message
|
|
10963
|
-
}), B.dirty()) : C.kind === "datetime" ? mB(C).test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10958
|
+
}), B.dirty()) : C.kind === "datetime" ? mB(C).test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10964
10959
|
code: G.invalid_string,
|
|
10965
10960
|
validation: "datetime",
|
|
10966
10961
|
message: C.message
|
|
10967
|
-
}), B.dirty()) : C.kind === "date" ? Qi.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10962
|
+
}), B.dirty()) : C.kind === "date" ? Qi.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10968
10963
|
code: G.invalid_string,
|
|
10969
10964
|
validation: "date",
|
|
10970
10965
|
message: C.message
|
|
10971
|
-
}), B.dirty()) : C.kind === "time" ? Ci(C).test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10966
|
+
}), B.dirty()) : C.kind === "time" ? Ci(C).test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10972
10967
|
code: G.invalid_string,
|
|
10973
10968
|
validation: "time",
|
|
10974
10969
|
message: C.message
|
|
10975
|
-
}), B.dirty()) : C.kind === "duration" ? XE.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10970
|
+
}), B.dirty()) : C.kind === "duration" ? XE.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10976
10971
|
validation: "duration",
|
|
10977
10972
|
code: G.invalid_string,
|
|
10978
10973
|
message: C.message
|
|
10979
|
-
}), B.dirty()) : C.kind === "ip" ? Ei(A.data, C.version) || (Q = this._getOrReturnCtx(A, Q),
|
|
10974
|
+
}), B.dirty()) : C.kind === "ip" ? Ei(A.data, C.version) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10980
10975
|
validation: "ip",
|
|
10981
10976
|
code: G.invalid_string,
|
|
10982
10977
|
message: C.message
|
|
10983
|
-
}), B.dirty()) : C.kind === "jwt" ? ii(A.data, C.alg) || (Q = this._getOrReturnCtx(A, Q),
|
|
10978
|
+
}), B.dirty()) : C.kind === "jwt" ? ii(A.data, C.alg) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10984
10979
|
validation: "jwt",
|
|
10985
10980
|
code: G.invalid_string,
|
|
10986
10981
|
message: C.message
|
|
10987
|
-
}), B.dirty()) : C.kind === "cidr" ? oi(A.data, C.version) || (Q = this._getOrReturnCtx(A, Q),
|
|
10982
|
+
}), B.dirty()) : C.kind === "cidr" ? oi(A.data, C.version) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10988
10983
|
validation: "cidr",
|
|
10989
10984
|
code: G.invalid_string,
|
|
10990
10985
|
message: C.message
|
|
10991
|
-
}), B.dirty()) : C.kind === "base64" ? gi.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10986
|
+
}), B.dirty()) : C.kind === "base64" ? gi.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10992
10987
|
validation: "base64",
|
|
10993
10988
|
code: G.invalid_string,
|
|
10994
10989
|
message: C.message
|
|
10995
|
-
}), B.dirty()) : C.kind === "base64url" ? Bi.test(A.data) || (Q = this._getOrReturnCtx(A, Q),
|
|
10990
|
+
}), B.dirty()) : C.kind === "base64url" ? Bi.test(A.data) || (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
10996
10991
|
validation: "base64url",
|
|
10997
10992
|
code: G.invalid_string,
|
|
10998
10993
|
message: C.message
|
|
@@ -11242,7 +11237,7 @@ class sA extends K {
|
|
|
11242
11237
|
_parse(A) {
|
|
11243
11238
|
if (this._def.coerce && (A.data = Number(A.data)), this._getType(A) !== w.number) {
|
|
11244
11239
|
const C = this._getOrReturnCtx(A);
|
|
11245
|
-
return
|
|
11240
|
+
return e(C, {
|
|
11246
11241
|
code: G.invalid_type,
|
|
11247
11242
|
expected: w.number,
|
|
11248
11243
|
received: C.parsedType
|
|
@@ -11251,30 +11246,30 @@ class sA extends K {
|
|
|
11251
11246
|
let B;
|
|
11252
11247
|
const Q = new b();
|
|
11253
11248
|
for (const C of this._def.checks)
|
|
11254
|
-
C.kind === "int" ? H.isInteger(A.data) || (B = this._getOrReturnCtx(A, B),
|
|
11249
|
+
C.kind === "int" ? H.isInteger(A.data) || (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11255
11250
|
code: G.invalid_type,
|
|
11256
11251
|
expected: "integer",
|
|
11257
11252
|
received: "float",
|
|
11258
11253
|
message: C.message
|
|
11259
|
-
}), Q.dirty()) : C.kind === "min" ? (C.inclusive ? A.data < C.value : A.data <= C.value) && (B = this._getOrReturnCtx(A, B),
|
|
11254
|
+
}), Q.dirty()) : C.kind === "min" ? (C.inclusive ? A.data < C.value : A.data <= C.value) && (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11260
11255
|
code: G.too_small,
|
|
11261
11256
|
minimum: C.value,
|
|
11262
11257
|
type: "number",
|
|
11263
11258
|
inclusive: C.inclusive,
|
|
11264
11259
|
exact: !1,
|
|
11265
11260
|
message: C.message
|
|
11266
|
-
}), Q.dirty()) : C.kind === "max" ? (C.inclusive ? A.data > C.value : A.data >= C.value) && (B = this._getOrReturnCtx(A, B),
|
|
11261
|
+
}), Q.dirty()) : C.kind === "max" ? (C.inclusive ? A.data > C.value : A.data >= C.value) && (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11267
11262
|
code: G.too_big,
|
|
11268
11263
|
maximum: C.value,
|
|
11269
11264
|
type: "number",
|
|
11270
11265
|
inclusive: C.inclusive,
|
|
11271
11266
|
exact: !1,
|
|
11272
11267
|
message: C.message
|
|
11273
|
-
}), Q.dirty()) : C.kind === "multipleOf" ? ai(A.data, C.value) !== 0 && (B = this._getOrReturnCtx(A, B),
|
|
11268
|
+
}), Q.dirty()) : C.kind === "multipleOf" ? ai(A.data, C.value) !== 0 && (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11274
11269
|
code: G.not_multiple_of,
|
|
11275
11270
|
multipleOf: C.value,
|
|
11276
11271
|
message: C.message
|
|
11277
|
-
}), Q.dirty()) : C.kind === "finite" ? Number.isFinite(A.data) || (B = this._getOrReturnCtx(A, B),
|
|
11272
|
+
}), Q.dirty()) : C.kind === "finite" ? Number.isFinite(A.data) || (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11278
11273
|
code: G.not_finite,
|
|
11279
11274
|
message: C.message
|
|
11280
11275
|
}), Q.dirty()) : H.assertNever(C);
|
|
@@ -11423,19 +11418,19 @@ class hA extends K {
|
|
|
11423
11418
|
let B;
|
|
11424
11419
|
const Q = new b();
|
|
11425
11420
|
for (const C of this._def.checks)
|
|
11426
|
-
C.kind === "min" ? (C.inclusive ? A.data < C.value : A.data <= C.value) && (B = this._getOrReturnCtx(A, B),
|
|
11421
|
+
C.kind === "min" ? (C.inclusive ? A.data < C.value : A.data <= C.value) && (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11427
11422
|
code: G.too_small,
|
|
11428
11423
|
type: "bigint",
|
|
11429
11424
|
minimum: C.value,
|
|
11430
11425
|
inclusive: C.inclusive,
|
|
11431
11426
|
message: C.message
|
|
11432
|
-
}), Q.dirty()) : C.kind === "max" ? (C.inclusive ? A.data > C.value : A.data >= C.value) && (B = this._getOrReturnCtx(A, B),
|
|
11427
|
+
}), Q.dirty()) : C.kind === "max" ? (C.inclusive ? A.data > C.value : A.data >= C.value) && (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11433
11428
|
code: G.too_big,
|
|
11434
11429
|
type: "bigint",
|
|
11435
11430
|
maximum: C.value,
|
|
11436
11431
|
inclusive: C.inclusive,
|
|
11437
11432
|
message: C.message
|
|
11438
|
-
}), Q.dirty()) : C.kind === "multipleOf" ? A.data % C.value !== BigInt(0) && (B = this._getOrReturnCtx(A, B),
|
|
11433
|
+
}), Q.dirty()) : C.kind === "multipleOf" ? A.data % C.value !== BigInt(0) && (B = this._getOrReturnCtx(A, B), e(B, {
|
|
11439
11434
|
code: G.not_multiple_of,
|
|
11440
11435
|
multipleOf: C.value,
|
|
11441
11436
|
message: C.message
|
|
@@ -11444,7 +11439,7 @@ class hA extends K {
|
|
|
11444
11439
|
}
|
|
11445
11440
|
_getInvalidInput(A) {
|
|
11446
11441
|
const I = this._getOrReturnCtx(A);
|
|
11447
|
-
return
|
|
11442
|
+
return e(I, {
|
|
11448
11443
|
code: G.invalid_type,
|
|
11449
11444
|
expected: w.bigint,
|
|
11450
11445
|
received: I.parsedType
|
|
@@ -11547,7 +11542,7 @@ class XA extends K {
|
|
|
11547
11542
|
_parse(A) {
|
|
11548
11543
|
if (this._def.coerce && (A.data = !!A.data), this._getType(A) !== w.boolean) {
|
|
11549
11544
|
const B = this._getOrReturnCtx(A);
|
|
11550
|
-
return
|
|
11545
|
+
return e(B, {
|
|
11551
11546
|
code: G.invalid_type,
|
|
11552
11547
|
expected: w.boolean,
|
|
11553
11548
|
received: B.parsedType
|
|
@@ -11565,7 +11560,7 @@ class UA extends K {
|
|
|
11565
11560
|
_parse(A) {
|
|
11566
11561
|
if (this._def.coerce && (A.data = new Date(A.data)), this._getType(A) !== w.date) {
|
|
11567
11562
|
const C = this._getOrReturnCtx(A);
|
|
11568
|
-
return
|
|
11563
|
+
return e(C, {
|
|
11569
11564
|
code: G.invalid_type,
|
|
11570
11565
|
expected: w.date,
|
|
11571
11566
|
received: C.parsedType
|
|
@@ -11573,21 +11568,21 @@ class UA extends K {
|
|
|
11573
11568
|
}
|
|
11574
11569
|
if (isNaN(A.data.getTime())) {
|
|
11575
11570
|
const C = this._getOrReturnCtx(A);
|
|
11576
|
-
return
|
|
11571
|
+
return e(C, {
|
|
11577
11572
|
code: G.invalid_date
|
|
11578
11573
|
}), L;
|
|
11579
11574
|
}
|
|
11580
11575
|
const B = new b();
|
|
11581
11576
|
let Q;
|
|
11582
11577
|
for (const C of this._def.checks)
|
|
11583
|
-
C.kind === "min" ? A.data.getTime() < C.value && (Q = this._getOrReturnCtx(A, Q),
|
|
11578
|
+
C.kind === "min" ? A.data.getTime() < C.value && (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
11584
11579
|
code: G.too_small,
|
|
11585
11580
|
message: C.message,
|
|
11586
11581
|
inclusive: !0,
|
|
11587
11582
|
exact: !1,
|
|
11588
11583
|
minimum: C.value,
|
|
11589
11584
|
type: "date"
|
|
11590
|
-
}), B.dirty()) : C.kind === "max" ? A.data.getTime() > C.value && (Q = this._getOrReturnCtx(A, Q),
|
|
11585
|
+
}), B.dirty()) : C.kind === "max" ? A.data.getTime() > C.value && (Q = this._getOrReturnCtx(A, Q), e(Q, {
|
|
11591
11586
|
code: G.too_big,
|
|
11592
11587
|
message: C.message,
|
|
11593
11588
|
inclusive: !0,
|
|
@@ -11643,7 +11638,7 @@ class kI extends K {
|
|
|
11643
11638
|
_parse(A) {
|
|
11644
11639
|
if (this._getType(A) !== w.symbol) {
|
|
11645
11640
|
const B = this._getOrReturnCtx(A);
|
|
11646
|
-
return
|
|
11641
|
+
return e(B, {
|
|
11647
11642
|
code: G.invalid_type,
|
|
11648
11643
|
expected: w.symbol,
|
|
11649
11644
|
received: B.parsedType
|
|
@@ -11660,7 +11655,7 @@ class jA extends K {
|
|
|
11660
11655
|
_parse(A) {
|
|
11661
11656
|
if (this._getType(A) !== w.undefined) {
|
|
11662
11657
|
const B = this._getOrReturnCtx(A);
|
|
11663
|
-
return
|
|
11658
|
+
return e(B, {
|
|
11664
11659
|
code: G.invalid_type,
|
|
11665
11660
|
expected: w.undefined,
|
|
11666
11661
|
received: B.parsedType
|
|
@@ -11677,7 +11672,7 @@ class zA extends K {
|
|
|
11677
11672
|
_parse(A) {
|
|
11678
11673
|
if (this._getType(A) !== w.null) {
|
|
11679
11674
|
const B = this._getOrReturnCtx(A);
|
|
11680
|
-
return
|
|
11675
|
+
return e(B, {
|
|
11681
11676
|
code: G.invalid_type,
|
|
11682
11677
|
expected: w.null,
|
|
11683
11678
|
received: B.parsedType
|
|
@@ -11717,7 +11712,7 @@ SA.create = (g) => new SA({
|
|
|
11717
11712
|
class DA extends K {
|
|
11718
11713
|
_parse(A) {
|
|
11719
11714
|
const I = this._getOrReturnCtx(A);
|
|
11720
|
-
return
|
|
11715
|
+
return e(I, {
|
|
11721
11716
|
code: G.invalid_type,
|
|
11722
11717
|
expected: w.never,
|
|
11723
11718
|
received: I.parsedType
|
|
@@ -11732,7 +11727,7 @@ class LI extends K {
|
|
|
11732
11727
|
_parse(A) {
|
|
11733
11728
|
if (this._getType(A) !== w.undefined) {
|
|
11734
11729
|
const B = this._getOrReturnCtx(A);
|
|
11735
|
-
return
|
|
11730
|
+
return e(B, {
|
|
11736
11731
|
code: G.invalid_type,
|
|
11737
11732
|
expected: w.void,
|
|
11738
11733
|
received: B.parsedType
|
|
@@ -11749,14 +11744,14 @@ class BA extends K {
|
|
|
11749
11744
|
_parse(A) {
|
|
11750
11745
|
const { ctx: I, status: B } = this._processInputParams(A), Q = this._def;
|
|
11751
11746
|
if (I.parsedType !== w.array)
|
|
11752
|
-
return
|
|
11747
|
+
return e(I, {
|
|
11753
11748
|
code: G.invalid_type,
|
|
11754
11749
|
expected: w.array,
|
|
11755
11750
|
received: I.parsedType
|
|
11756
11751
|
}), L;
|
|
11757
11752
|
if (Q.exactLength !== null) {
|
|
11758
11753
|
const E = I.data.length > Q.exactLength.value, i = I.data.length < Q.exactLength.value;
|
|
11759
|
-
(E || i) && (
|
|
11754
|
+
(E || i) && (e(I, {
|
|
11760
11755
|
code: E ? G.too_big : G.too_small,
|
|
11761
11756
|
minimum: i ? Q.exactLength.value : void 0,
|
|
11762
11757
|
maximum: E ? Q.exactLength.value : void 0,
|
|
@@ -11766,14 +11761,14 @@ class BA extends K {
|
|
|
11766
11761
|
message: Q.exactLength.message
|
|
11767
11762
|
}), B.dirty());
|
|
11768
11763
|
}
|
|
11769
|
-
if (Q.minLength !== null && I.data.length < Q.minLength.value && (
|
|
11764
|
+
if (Q.minLength !== null && I.data.length < Q.minLength.value && (e(I, {
|
|
11770
11765
|
code: G.too_small,
|
|
11771
11766
|
minimum: Q.minLength.value,
|
|
11772
11767
|
type: "array",
|
|
11773
11768
|
inclusive: !0,
|
|
11774
11769
|
exact: !1,
|
|
11775
11770
|
message: Q.minLength.message
|
|
11776
|
-
}), B.dirty()), Q.maxLength !== null && I.data.length > Q.maxLength.value && (
|
|
11771
|
+
}), B.dirty()), Q.maxLength !== null && I.data.length > Q.maxLength.value && (e(I, {
|
|
11777
11772
|
code: G.too_big,
|
|
11778
11773
|
maximum: Q.maxLength.value,
|
|
11779
11774
|
type: "array",
|
|
@@ -11847,7 +11842,7 @@ class f extends K {
|
|
|
11847
11842
|
_parse(A) {
|
|
11848
11843
|
if (this._getType(A) !== w.object) {
|
|
11849
11844
|
const a = this._getOrReturnCtx(A);
|
|
11850
|
-
return
|
|
11845
|
+
return e(a, {
|
|
11851
11846
|
code: G.invalid_type,
|
|
11852
11847
|
expected: w.object,
|
|
11853
11848
|
received: a.parsedType
|
|
@@ -11875,7 +11870,7 @@ class f extends K {
|
|
|
11875
11870
|
value: { status: "valid", value: Q.data[D] }
|
|
11876
11871
|
});
|
|
11877
11872
|
else if (a === "strict")
|
|
11878
|
-
i.length > 0 && (
|
|
11873
|
+
i.length > 0 && (e(Q, {
|
|
11879
11874
|
code: G.unrecognized_keys,
|
|
11880
11875
|
keys: i
|
|
11881
11876
|
}), B.dirty());
|
|
@@ -12132,7 +12127,7 @@ class _A extends K {
|
|
|
12132
12127
|
if (i.result.status === "dirty")
|
|
12133
12128
|
return I.common.issues.push(...i.ctx.common.issues), i.result;
|
|
12134
12129
|
const E = C.map((i) => new j(i.ctx.common.issues));
|
|
12135
|
-
return
|
|
12130
|
+
return e(I, {
|
|
12136
12131
|
code: G.invalid_union,
|
|
12137
12132
|
unionErrors: E
|
|
12138
12133
|
}), L;
|
|
@@ -12179,7 +12174,7 @@ class _A extends K {
|
|
|
12179
12174
|
if (C)
|
|
12180
12175
|
return I.common.issues.push(...C.ctx.common.issues), C.result;
|
|
12181
12176
|
const i = E.map((o) => new j(o));
|
|
12182
|
-
return
|
|
12177
|
+
return e(I, {
|
|
12183
12178
|
code: G.invalid_union,
|
|
12184
12179
|
unionErrors: i
|
|
12185
12180
|
}), L;
|
|
@@ -12199,7 +12194,7 @@ class qI extends K {
|
|
|
12199
12194
|
_parse(A) {
|
|
12200
12195
|
const { ctx: I } = this._processInputParams(A);
|
|
12201
12196
|
if (I.parsedType !== w.object)
|
|
12202
|
-
return
|
|
12197
|
+
return e(I, {
|
|
12203
12198
|
code: G.invalid_type,
|
|
12204
12199
|
expected: w.object,
|
|
12205
12200
|
received: I.parsedType
|
|
@@ -12213,7 +12208,7 @@ class qI extends K {
|
|
|
12213
12208
|
data: I.data,
|
|
12214
12209
|
path: I.path,
|
|
12215
12210
|
parent: I
|
|
12216
|
-
}) : (
|
|
12211
|
+
}) : (e(I, {
|
|
12217
12212
|
code: G.invalid_union_discriminator,
|
|
12218
12213
|
options: Array.from(this.optionsMap.keys()),
|
|
12219
12214
|
path: [B]
|
|
@@ -12289,7 +12284,7 @@ class $A extends K {
|
|
|
12289
12284
|
if (Bg(C) || Bg(E))
|
|
12290
12285
|
return L;
|
|
12291
12286
|
const i = Cg(C.value, E.value);
|
|
12292
|
-
return i.valid ? ((Qg(C) || Qg(E)) && I.dirty(), { status: I.value, value: i.data }) : (
|
|
12287
|
+
return i.valid ? ((Qg(C) || Qg(E)) && I.dirty(), { status: I.value, value: i.data }) : (e(B, {
|
|
12293
12288
|
code: G.invalid_intersection_types
|
|
12294
12289
|
}), L);
|
|
12295
12290
|
};
|
|
@@ -12325,20 +12320,20 @@ class iA extends K {
|
|
|
12325
12320
|
_parse(A) {
|
|
12326
12321
|
const { status: I, ctx: B } = this._processInputParams(A);
|
|
12327
12322
|
if (B.parsedType !== w.array)
|
|
12328
|
-
return
|
|
12323
|
+
return e(B, {
|
|
12329
12324
|
code: G.invalid_type,
|
|
12330
12325
|
expected: w.array,
|
|
12331
12326
|
received: B.parsedType
|
|
12332
12327
|
}), L;
|
|
12333
12328
|
if (B.data.length < this._def.items.length)
|
|
12334
|
-
return
|
|
12329
|
+
return e(B, {
|
|
12335
12330
|
code: G.too_small,
|
|
12336
12331
|
minimum: this._def.items.length,
|
|
12337
12332
|
inclusive: !0,
|
|
12338
12333
|
exact: !1,
|
|
12339
12334
|
type: "array"
|
|
12340
12335
|
}), L;
|
|
12341
|
-
!this._def.rest && B.data.length > this._def.items.length && (
|
|
12336
|
+
!this._def.rest && B.data.length > this._def.items.length && (e(B, {
|
|
12342
12337
|
code: G.too_big,
|
|
12343
12338
|
maximum: this._def.items.length,
|
|
12344
12339
|
inclusive: !0,
|
|
@@ -12381,7 +12376,7 @@ class AI extends K {
|
|
|
12381
12376
|
_parse(A) {
|
|
12382
12377
|
const { status: I, ctx: B } = this._processInputParams(A);
|
|
12383
12378
|
if (B.parsedType !== w.object)
|
|
12384
|
-
return
|
|
12379
|
+
return e(B, {
|
|
12385
12380
|
code: G.invalid_type,
|
|
12386
12381
|
expected: w.object,
|
|
12387
12382
|
received: B.parsedType
|
|
@@ -12422,7 +12417,7 @@ class JI extends K {
|
|
|
12422
12417
|
_parse(A) {
|
|
12423
12418
|
const { status: I, ctx: B } = this._processInputParams(A);
|
|
12424
12419
|
if (B.parsedType !== w.map)
|
|
12425
|
-
return
|
|
12420
|
+
return e(B, {
|
|
12426
12421
|
code: G.invalid_type,
|
|
12427
12422
|
expected: w.map,
|
|
12428
12423
|
received: B.parsedType
|
|
@@ -12464,20 +12459,20 @@ class kA extends K {
|
|
|
12464
12459
|
_parse(A) {
|
|
12465
12460
|
const { status: I, ctx: B } = this._processInputParams(A);
|
|
12466
12461
|
if (B.parsedType !== w.set)
|
|
12467
|
-
return
|
|
12462
|
+
return e(B, {
|
|
12468
12463
|
code: G.invalid_type,
|
|
12469
12464
|
expected: w.set,
|
|
12470
12465
|
received: B.parsedType
|
|
12471
12466
|
}), L;
|
|
12472
12467
|
const Q = this._def;
|
|
12473
|
-
Q.minSize !== null && B.data.size < Q.minSize.value && (
|
|
12468
|
+
Q.minSize !== null && B.data.size < Q.minSize.value && (e(B, {
|
|
12474
12469
|
code: G.too_small,
|
|
12475
12470
|
minimum: Q.minSize.value,
|
|
12476
12471
|
type: "set",
|
|
12477
12472
|
inclusive: !0,
|
|
12478
12473
|
exact: !1,
|
|
12479
12474
|
message: Q.minSize.message
|
|
12480
|
-
}), I.dirty()), Q.maxSize !== null && B.data.size > Q.maxSize.value && (
|
|
12475
|
+
}), I.dirty()), Q.maxSize !== null && B.data.size > Q.maxSize.value && (e(B, {
|
|
12481
12476
|
code: G.too_big,
|
|
12482
12477
|
maximum: Q.maxSize.value,
|
|
12483
12478
|
type: "set",
|
|
@@ -12531,7 +12526,7 @@ class dA extends K {
|
|
|
12531
12526
|
_parse(A) {
|
|
12532
12527
|
const { ctx: I } = this._processInputParams(A);
|
|
12533
12528
|
if (I.parsedType !== w.function)
|
|
12534
|
-
return
|
|
12529
|
+
return e(I, {
|
|
12535
12530
|
code: G.invalid_type,
|
|
12536
12531
|
expected: w.function,
|
|
12537
12532
|
received: I.parsedType
|
|
@@ -12643,7 +12638,7 @@ class gI extends K {
|
|
|
12643
12638
|
_parse(A) {
|
|
12644
12639
|
if (A.data !== this._def.value) {
|
|
12645
12640
|
const I = this._getOrReturnCtx(A);
|
|
12646
|
-
return
|
|
12641
|
+
return e(I, {
|
|
12647
12642
|
received: I.data,
|
|
12648
12643
|
code: G.invalid_literal,
|
|
12649
12644
|
expected: this._def.value
|
|
@@ -12674,7 +12669,7 @@ class yA extends K {
|
|
|
12674
12669
|
_parse(A) {
|
|
12675
12670
|
if (typeof A.data != "string") {
|
|
12676
12671
|
const I = this._getOrReturnCtx(A), B = this._def.values;
|
|
12677
|
-
return
|
|
12672
|
+
return e(I, {
|
|
12678
12673
|
expected: H.joinValues(B),
|
|
12679
12674
|
received: I.parsedType,
|
|
12680
12675
|
code: G.invalid_type
|
|
@@ -12682,7 +12677,7 @@ class yA extends K {
|
|
|
12682
12677
|
}
|
|
12683
12678
|
if (UI(this, WA) || lB(this, WA, new Set(this._def.values)), !UI(this, WA).has(A.data)) {
|
|
12684
12679
|
const I = this._getOrReturnCtx(A), B = this._def.values;
|
|
12685
|
-
return
|
|
12680
|
+
return e(I, {
|
|
12686
12681
|
received: I.data,
|
|
12687
12682
|
code: G.invalid_enum_value,
|
|
12688
12683
|
options: B
|
|
@@ -12734,7 +12729,7 @@ class BI extends K {
|
|
|
12734
12729
|
const I = H.getValidEnumValues(this._def.values), B = this._getOrReturnCtx(A);
|
|
12735
12730
|
if (B.parsedType !== w.string && B.parsedType !== w.number) {
|
|
12736
12731
|
const Q = H.objectValues(I);
|
|
12737
|
-
return
|
|
12732
|
+
return e(B, {
|
|
12738
12733
|
expected: H.joinValues(Q),
|
|
12739
12734
|
received: B.parsedType,
|
|
12740
12735
|
code: G.invalid_type
|
|
@@ -12742,7 +12737,7 @@ class BI extends K {
|
|
|
12742
12737
|
}
|
|
12743
12738
|
if (UI(this, xA) || lB(this, xA, new Set(H.getValidEnumValues(this._def.values))), !UI(this, xA).has(A.data)) {
|
|
12744
12739
|
const Q = H.objectValues(I);
|
|
12745
|
-
return
|
|
12740
|
+
return e(B, {
|
|
12746
12741
|
received: B.data,
|
|
12747
12742
|
code: G.invalid_enum_value,
|
|
12748
12743
|
options: Q
|
|
@@ -12767,7 +12762,7 @@ class lA extends K {
|
|
|
12767
12762
|
_parse(A) {
|
|
12768
12763
|
const { ctx: I } = this._processInputParams(A);
|
|
12769
12764
|
if (I.parsedType !== w.promise && I.common.async === !1)
|
|
12770
|
-
return
|
|
12765
|
+
return e(I, {
|
|
12771
12766
|
code: G.invalid_type,
|
|
12772
12767
|
expected: w.promise,
|
|
12773
12768
|
received: I.parsedType
|
|
@@ -12794,7 +12789,7 @@ class QA extends K {
|
|
|
12794
12789
|
_parse(A) {
|
|
12795
12790
|
const { status: I, ctx: B } = this._processInputParams(A), Q = this._def.effect || null, C = {
|
|
12796
12791
|
addIssue: (E) => {
|
|
12797
|
-
|
|
12792
|
+
e(B, E), E.fatal ? I.abort() : I.dirty();
|
|
12798
12793
|
},
|
|
12799
12794
|
get path() {
|
|
12800
12795
|
return B.path;
|
|
@@ -12966,7 +12961,7 @@ class YI extends K {
|
|
|
12966
12961
|
_parse(A) {
|
|
12967
12962
|
if (this._getType(A) !== w.nan) {
|
|
12968
12963
|
const B = this._getOrReturnCtx(A);
|
|
12969
|
-
return
|
|
12964
|
+
return e(B, {
|
|
12970
12965
|
code: G.invalid_type,
|
|
12971
12966
|
expected: w.nan,
|
|
12972
12967
|
received: B.parsedType
|
|
@@ -13078,7 +13073,7 @@ var k;
|
|
|
13078
13073
|
})(k || (k = {}));
|
|
13079
13074
|
const hi = (g, A = {
|
|
13080
13075
|
message: `Input not instance of ${g.name}`
|
|
13081
|
-
}) => TB((I) => I instanceof g, A), WB = $.create, xB = sA.create, yi = YI.create, ti = hA.create, bB = XA.create, Gi = UA.create,
|
|
13076
|
+
}) => TB((I) => I instanceof g, A), WB = $.create, xB = sA.create, yi = YI.create, ti = hA.create, bB = XA.create, Gi = UA.create, ni = kI.create, ei = jA.create, wi = zA.create, Fi = qA.create, ri = SA.create, Si = DA.create, Ri = LI.create, Ni = BA.create, ci = f.create, Ui = f.strictCreate, ki = _A.create, Li = qI.create, Ji = $A.create, Yi = iA.create, Mi = AI.create, di = JI.create, Ki = kA.create, Hi = dA.create, qi = II.create, li = gI.create, fi = yA.create, pi = BI.create, mi = lA.create, DB = QA.create, ui = CA.create, Ti = tA.create, Wi = QA.createWithPreprocess, xi = hI.create, bi = () => WB().optional(), Zi = () => xB().optional(), Pi = () => bB().optional(), Oi = {
|
|
13082
13077
|
string: (g) => $.create({ ...g, coerce: !0 }),
|
|
13083
13078
|
number: (g) => sA.create({ ...g, coerce: !0 }),
|
|
13084
13079
|
boolean: (g) => XA.create({
|
|
@@ -13095,7 +13090,7 @@ var s = /* @__PURE__ */ Object.freeze({
|
|
|
13095
13090
|
getErrorMap: NI,
|
|
13096
13091
|
makeIssue: cI,
|
|
13097
13092
|
EMPTY_PATH: xE,
|
|
13098
|
-
addIssueToContext:
|
|
13093
|
+
addIssueToContext: e,
|
|
13099
13094
|
ParseStatus: b,
|
|
13100
13095
|
INVALID: L,
|
|
13101
13096
|
DIRTY: MA,
|
|
@@ -13192,10 +13187,10 @@ var s = /* @__PURE__ */ Object.freeze({
|
|
|
13192
13187
|
set: Ki,
|
|
13193
13188
|
strictObject: Ui,
|
|
13194
13189
|
string: WB,
|
|
13195
|
-
symbol:
|
|
13190
|
+
symbol: ni,
|
|
13196
13191
|
transformer: DB,
|
|
13197
13192
|
tuple: Yi,
|
|
13198
|
-
undefined:
|
|
13193
|
+
undefined: ei,
|
|
13199
13194
|
union: ki,
|
|
13200
13195
|
unknown: ri,
|
|
13201
13196
|
void: Ri,
|
|
@@ -13749,7 +13744,7 @@ function Jg(g) {
|
|
|
13749
13744
|
${JSON.stringify(g)}`);
|
|
13750
13745
|
}
|
|
13751
13746
|
}
|
|
13752
|
-
class
|
|
13747
|
+
class nI {
|
|
13753
13748
|
location;
|
|
13754
13749
|
version;
|
|
13755
13750
|
constructor(A) {
|
|
@@ -13789,7 +13784,7 @@ class eI {
|
|
|
13789
13784
|
*/
|
|
13790
13785
|
static fromHttp(A) {
|
|
13791
13786
|
const I = new uA(A.url);
|
|
13792
|
-
return new
|
|
13787
|
+
return new nI({
|
|
13793
13788
|
location: new X(I),
|
|
13794
13789
|
version: A.version
|
|
13795
13790
|
});
|
|
@@ -13806,7 +13801,7 @@ class eI {
|
|
|
13806
13801
|
*/
|
|
13807
13802
|
static fromS3(A) {
|
|
13808
13803
|
const I = new Ug(A);
|
|
13809
|
-
return new
|
|
13804
|
+
return new nI({
|
|
13810
13805
|
location: new X(I),
|
|
13811
13806
|
version: A.version
|
|
13812
13807
|
});
|
|
@@ -13822,7 +13817,7 @@ class eI {
|
|
|
13822
13817
|
*/
|
|
13823
13818
|
static fromFileSystem(A) {
|
|
13824
13819
|
const I = new cg(A.directory);
|
|
13825
|
-
return new
|
|
13820
|
+
return new nI({
|
|
13826
13821
|
location: new X(I, A.path),
|
|
13827
13822
|
version: A.version
|
|
13828
13823
|
});
|
|
@@ -13993,7 +13988,7 @@ export {
|
|
|
13993
13988
|
Fo as LabelImageLayer,
|
|
13994
13989
|
GA as Layer,
|
|
13995
13990
|
vQ as LayerManager,
|
|
13996
|
-
|
|
13991
|
+
nI as OmeZarrImageSource,
|
|
13997
13992
|
so as OrthographicCamera,
|
|
13998
13993
|
yo as PanZoomControls,
|
|
13999
13994
|
ho as PerspectiveCamera,
|
|
@@ -14003,9 +13998,9 @@ export {
|
|
|
14003
13998
|
Yo as Spherical,
|
|
14004
13999
|
iI as Texture2DArray,
|
|
14005
14000
|
yg as Texture3D,
|
|
14006
|
-
|
|
14001
|
+
no as TracksLayer,
|
|
14007
14002
|
_Q as Viewport,
|
|
14008
|
-
|
|
14003
|
+
eo as VolumeLayer,
|
|
14009
14004
|
uQ as WebGLRenderer,
|
|
14010
14005
|
ko as createExplorationPolicy,
|
|
14011
14006
|
Yg as createImageSourcePolicy,
|