@hortiview/modulebase 1.1.2-alpha.870da389.1 → 1.1.2-alpha.a87fc893.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/ModuleCore-DRMqZO8r.js → ModuleCore-C4Z4zObE.js} +3030 -3110
- package/{dist/api-COabZnyn.js → api-CikhPcJj.js} +10 -10
- package/{dist/chunk-EVOBXE3Y-B43QN6RE.js → chunk-KS7C4IRE-CT7Z8Xx_.js} +3866 -3585
- package/components/ModuleBase.js +30 -0
- package/{dist/components → components}/ModuleCore.js +2 -3
- package/{dist/constants.js → constants.js} +8 -8
- package/{dist/hooks → hooks}/useCustom.js +9 -9
- package/{dist/hooks → hooks}/useCustomMutation.js +6 -6
- package/{dist/hooks → hooks}/useEntity.js +5 -5
- package/hooks/useOffline.js +57 -0
- package/{dist/hooks → hooks}/useOption.js +6 -6
- package/{dist/hooks → hooks}/useSignalRMessages.js +1 -1
- package/{dist/hooks → hooks}/useStores.js +1 -1
- package/{dist/isTypedArray-SkhznY1k.js → isTypedArray-T1_r8YHg.js} +33 -33
- package/{dist/lib → lib}/components/ModuleBase.d.ts +1 -1
- package/{dist/lib → lib}/components/ModuleCore.d.ts +1 -2
- package/{dist/lib → lib}/hooks/useCustom.d.ts +1 -1
- package/{dist/lib → lib}/hooks/useCustomMutation.d.ts +1 -1
- package/{dist/lib → lib}/hooks/useOffline.d.ts +5 -5
- package/lib/provider/SignalR/SignalRModuleContext.d.ts +4 -0
- package/lib/provider/SignalR/SignalRProvider.d.ts +9 -0
- package/lib/types/BaseProps.d.ts +98 -0
- package/lib/utils/IndexedDbService.d.ts +6 -0
- package/main.js +228 -0
- package/{dist/module-router.js → module-router.js} +813 -847
- package/{dist/omit-DYPaIq41.js → omit-CiJPWayj.js} +66 -66
- package/package.json +22 -56
- package/provider/SignalR/SignalRModuleContext.js +6205 -0
- package/provider/SignalR/SignalRProvider.js +35 -0
- package/{dist/stores → stores}/BasePropsStore.js +1 -0
- package/{dist/stores → stores}/EnvironmentStore.js +5 -5
- package/{dist/types → types}/Entities.js +5 -5
- package/{dist/useCustomMutation-9VUQ7NbQ.js → useCustomMutation-BX8lKAYe.js} +10 -10
- package/{dist/useQuery-DUDyh33-.js → useQuery-URJEw3ly.js} +128 -126
- package/utils/IndexedDbService.js +43 -0
- package/{dist/utils → utils}/api.js +1 -1
- package/{dist/utils → utils}/baseFetches.js +1 -1
- package/README.md +0 -9
- package/dist/components/ModuleBase.js +0 -21
- package/dist/hooks/useOffline.js +0 -57
- package/dist/lib/provider/SignalR/SignalRProvider.d.ts +0 -13
- package/dist/lib/types/BaseProps.d.ts +0 -48
- package/dist/lib/utils/IndexedDbService.d.ts +0 -33
- package/dist/main.js +0 -228
- package/dist/provider/SignalR/SignalRProvider.js +0 -5979
- package/dist/utils/IndexedDbService.js +0 -43
- package/{dist/IsRestoringProvider-SzKJZczp.js → IsRestoringProvider-SzKJZczp.js} +0 -0
- package/{dist/_commonjsHelpers-ByX85dGu.js → _commonjsHelpers-ByX85dGu.js} +0 -0
- package/{dist/assets → assets}/ModuleCore.css +0 -0
- package/{dist/enum → enum}/ActionStorage.js +0 -0
- package/{dist/hooks → hooks}/useBreadcrumbTranslation.js +0 -0
- package/{dist/lib → lib}/constants.d.ts +8 -8
- /package/{dist/lib → lib}/enum/ActionStorage.d.ts +0 -0
- /package/{dist/lib → lib}/hooks/useBreadcrumbTranslation.d.ts +0 -0
- /package/{dist/lib → lib}/hooks/useEntity.d.ts +0 -0
- /package/{dist/lib → lib}/hooks/useOption.d.ts +0 -0
- /package/{dist/lib → lib}/hooks/useSignalRMessages.d.ts +0 -0
- /package/{dist/lib → lib}/hooks/useStores.d.ts +0 -0
- /package/{dist/lib → lib}/main.d.ts +0 -0
- /package/{dist/lib → lib}/module-router.d.ts +0 -0
- /package/{dist/lib → lib}/provider/SignalR/signalR.d.ts +0 -0
- /package/{dist/lib → lib}/stores/BasePropsStore.d.ts +0 -0
- /package/{dist/lib → lib}/stores/EnvironmentStore.d.ts +0 -0
- /package/{dist/lib → lib}/types/ActionStorage.d.ts +0 -0
- /package/{dist/lib → lib}/types/AppInsights.d.ts +0 -0
- /package/{dist/lib → lib}/types/CommonOptions.d.ts +0 -0
- /package/{dist/lib → lib}/types/Entities.d.ts +0 -0
- /package/{dist/lib → lib}/types/Environment.d.ts +0 -0
- /package/{dist/lib → lib}/types/EnvironmentVariable.d.ts +0 -0
- /package/{dist/lib → lib}/types/ModuleApi.d.ts +0 -0
- /package/{dist/lib → lib}/types/Requests.d.ts +0 -0
- /package/{dist/lib → lib}/types/ServiceBus.d.ts +0 -0
- /package/{dist/lib → lib}/types/SystemMessage.d.ts +0 -0
- /package/{dist/lib → lib}/utils/api.d.ts +0 -0
- /package/{dist/lib → lib}/utils/baseFetches.d.ts +0 -0
- /package/{dist/lib → lib}/utils/fetches.d.ts +0 -0
- /package/{dist/lib → lib}/utils/helper.d.ts +0 -0
- /package/{dist/provider → provider}/SignalR/signalR.js +0 -0
- /package/{dist/react-c9FSfB30.js → react-c9FSfB30.js} +0 -0
- /package/{dist/types → types}/ActionStorage.js +0 -0
- /package/{dist/types → types}/AppInsights.js +0 -0
- /package/{dist/types → types}/BaseProps.js +0 -0
- /package/{dist/types → types}/CommonOptions.js +0 -0
- /package/{dist/types → types}/Environment.js +0 -0
- /package/{dist/types → types}/EnvironmentVariable.js +0 -0
- /package/{dist/types → types}/ModuleApi.js +0 -0
- /package/{dist/types → types}/Requests.js +0 -0
- /package/{dist/types → types}/ServiceBus.js +0 -0
- /package/{dist/types → types}/SystemMessage.js +0 -0
- /package/{dist/utils → utils}/fetches.js +0 -0
- /package/{dist/utils → utils}/helper.js +0 -0
- /package/{dist/vite-env.d.js → vite-env.d.js} +0 -0
|
@@ -1,201 +1,201 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
3
|
-
import { useBasePropsStore as
|
|
4
|
-
import {
|
|
5
|
-
import { A as Er, B as Cr, F as br, H as
|
|
6
|
-
var
|
|
7
|
-
function
|
|
8
|
-
if (ue) return
|
|
9
|
-
ue = 1, Object.defineProperty(
|
|
1
|
+
import * as _ from "react";
|
|
2
|
+
import D, { useCallback as je } from "react";
|
|
3
|
+
import { useBasePropsStore as ze } from "./stores/BasePropsStore.js";
|
|
4
|
+
import { aW as qe, a0 as ee, ae as Ce, r as te, v as We, n as be, aX as Ve, aQ as Xe, aj as Je, j as K, aY as Qe, a8 as Ke, R as Ge, aZ as L, a_ as Ye, a$ as xe, b0 as oe, b1 as ie, b2 as G, ah as N, b3 as ke, b4 as Ze, b5 as et, a4 as tt, a5 as rt, a3 as at, O as nt, U as st, x as M, am as ot, ao as it, al as lt, b6 as z, E as q, b7 as ut, b8 as le, b9 as dt, ba as re, bb as ct, bc as ft, bd as _e, be as I, bf as ht, bg as pt, bh as mt } from "./chunk-KS7C4IRE-CT7Z8Xx_.js";
|
|
5
|
+
import { A as Er, B as Cr, F as br, H as xr, I as kr, a as _r, b as Ar, L as Dr, d as Tr, M as Hr, e as Fr, N as Pr, f as Ur, g as Lr, P as Ir, h as Nr, i as Or, k as Br, S as Mr, l as $r, m as jr, o as zr, D as qr, p as Wr, q as Vr, s as Xr, t as Jr, w as Qr, V as Kr, W as Gr, y as Yr, z as Zr, C as ea, G as ta, J as ra, K as aa, Q as na, T as sa, X as oa, Y as ia, Z as la, _ as ua, $ as da, a1 as ca, a2 as fa, c as ha, a6 as pa, a7 as ma, a9 as ya, aa as wa, ab as ga, ac as Ra, ad as va, af as Sa, ag as Ea, ai as Ca, ak as ba, an as xa, ap as ka, aq as _a, ar as Aa, as as Da, at as Ta, au as Ha, av as Fa, aw as Pa, ax as Ua, ay as La, az as Ia, aA as Na, aB as Oa, aC as Ba, aD as Ma, aE as $a, aF as ja, aG as za, aH as qa, aI as Wa, aJ as Va, aK as Xa, aL as Ja, aM as Qa, aN as Ka, aO as Ga, aP as Ya, aR as Za, aS as en, aT as tn, aU as rn, aV as an } from "./chunk-KS7C4IRE-CT7Z8Xx_.js";
|
|
6
|
+
var P = {}, ue;
|
|
7
|
+
function yt() {
|
|
8
|
+
if (ue) return P;
|
|
9
|
+
ue = 1, Object.defineProperty(P, "__esModule", { value: !0 }), P.parseCookie = u, P.parse = u, P.stringifyCookie = s, P.stringifySetCookie = i, P.serialize = i, P.parseSetCookie = l, P.stringifySetCookie = i, P.serialize = i;
|
|
10
10
|
const e = /^[\u0021-\u003A\u003C\u003E-\u007E]+$/, t = /^[\u0021-\u003A\u003C-\u007E]*$/, r = /^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i, a = /^[\u0020-\u003A\u003D-\u007E]*$/, n = /^-?\d+$/, o = Object.prototype.toString, c = /* @__PURE__ */ (() => {
|
|
11
|
-
const
|
|
11
|
+
const d = function() {
|
|
12
12
|
};
|
|
13
|
-
return
|
|
13
|
+
return d.prototype = /* @__PURE__ */ Object.create(null), d;
|
|
14
14
|
})();
|
|
15
|
-
function u(
|
|
16
|
-
const m = new c(),
|
|
17
|
-
if (
|
|
15
|
+
function u(d, w) {
|
|
16
|
+
const m = new c(), f = d.length;
|
|
17
|
+
if (f < 2)
|
|
18
18
|
return m;
|
|
19
|
-
const
|
|
19
|
+
const E = w?.decode || y;
|
|
20
20
|
let C = 0;
|
|
21
21
|
do {
|
|
22
|
-
const
|
|
23
|
-
if (
|
|
22
|
+
const v = h(d, C, f);
|
|
23
|
+
if (v === -1)
|
|
24
24
|
break;
|
|
25
|
-
const
|
|
26
|
-
if (
|
|
27
|
-
C =
|
|
25
|
+
const S = p(d, C, f);
|
|
26
|
+
if (v > S) {
|
|
27
|
+
C = d.lastIndexOf(";", v - 1) + 1;
|
|
28
28
|
continue;
|
|
29
29
|
}
|
|
30
|
-
const
|
|
31
|
-
m[
|
|
32
|
-
} while (C <
|
|
30
|
+
const A = g(d, C, v);
|
|
31
|
+
m[A] === void 0 && (m[A] = E(g(d, v + 1, S))), C = S + 1;
|
|
32
|
+
} while (C < f);
|
|
33
33
|
return m;
|
|
34
34
|
}
|
|
35
|
-
function s(
|
|
36
|
-
const m =
|
|
37
|
-
for (const
|
|
38
|
-
const C =
|
|
35
|
+
function s(d, w) {
|
|
36
|
+
const m = w?.encode || encodeURIComponent, f = [];
|
|
37
|
+
for (const E of Object.keys(d)) {
|
|
38
|
+
const C = d[E];
|
|
39
39
|
if (C === void 0)
|
|
40
40
|
continue;
|
|
41
|
-
if (!e.test(
|
|
42
|
-
throw new TypeError(`cookie name is invalid: ${
|
|
43
|
-
const
|
|
44
|
-
if (!t.test(
|
|
41
|
+
if (!e.test(E))
|
|
42
|
+
throw new TypeError(`cookie name is invalid: ${E}`);
|
|
43
|
+
const v = m(C);
|
|
44
|
+
if (!t.test(v))
|
|
45
45
|
throw new TypeError(`cookie val is invalid: ${C}`);
|
|
46
|
-
|
|
46
|
+
f.push(`${E}=${v}`);
|
|
47
47
|
}
|
|
48
|
-
return
|
|
48
|
+
return f.join("; ");
|
|
49
49
|
}
|
|
50
|
-
function i(
|
|
51
|
-
const
|
|
52
|
-
if (!e.test(
|
|
53
|
-
throw new TypeError(`argument name is invalid: ${
|
|
54
|
-
const
|
|
55
|
-
if (!t.test(
|
|
56
|
-
throw new TypeError(`argument val is invalid: ${
|
|
57
|
-
let
|
|
58
|
-
if (
|
|
59
|
-
if (!Number.isInteger(
|
|
60
|
-
throw new TypeError(`option maxAge is invalid: ${
|
|
61
|
-
|
|
50
|
+
function i(d, w, m) {
|
|
51
|
+
const f = typeof d == "object" ? d : { ...m, name: d, value: String(w) }, C = (typeof w == "object" ? w : m)?.encode || encodeURIComponent;
|
|
52
|
+
if (!e.test(f.name))
|
|
53
|
+
throw new TypeError(`argument name is invalid: ${f.name}`);
|
|
54
|
+
const v = f.value ? C(f.value) : "";
|
|
55
|
+
if (!t.test(v))
|
|
56
|
+
throw new TypeError(`argument val is invalid: ${f.value}`);
|
|
57
|
+
let S = f.name + "=" + v;
|
|
58
|
+
if (f.maxAge !== void 0) {
|
|
59
|
+
if (!Number.isInteger(f.maxAge))
|
|
60
|
+
throw new TypeError(`option maxAge is invalid: ${f.maxAge}`);
|
|
61
|
+
S += "; Max-Age=" + f.maxAge;
|
|
62
62
|
}
|
|
63
|
-
if (
|
|
64
|
-
if (!r.test(
|
|
65
|
-
throw new TypeError(`option domain is invalid: ${
|
|
66
|
-
|
|
63
|
+
if (f.domain) {
|
|
64
|
+
if (!r.test(f.domain))
|
|
65
|
+
throw new TypeError(`option domain is invalid: ${f.domain}`);
|
|
66
|
+
S += "; Domain=" + f.domain;
|
|
67
67
|
}
|
|
68
|
-
if (
|
|
69
|
-
if (!a.test(
|
|
70
|
-
throw new TypeError(`option path is invalid: ${
|
|
71
|
-
|
|
68
|
+
if (f.path) {
|
|
69
|
+
if (!a.test(f.path))
|
|
70
|
+
throw new TypeError(`option path is invalid: ${f.path}`);
|
|
71
|
+
S += "; Path=" + f.path;
|
|
72
72
|
}
|
|
73
|
-
if (
|
|
74
|
-
if (!R(
|
|
75
|
-
throw new TypeError(`option expires is invalid: ${
|
|
76
|
-
|
|
73
|
+
if (f.expires) {
|
|
74
|
+
if (!R(f.expires) || !Number.isFinite(f.expires.valueOf()))
|
|
75
|
+
throw new TypeError(`option expires is invalid: ${f.expires}`);
|
|
76
|
+
S += "; Expires=" + f.expires.toUTCString();
|
|
77
77
|
}
|
|
78
|
-
if (
|
|
79
|
-
switch (typeof
|
|
78
|
+
if (f.httpOnly && (S += "; HttpOnly"), f.secure && (S += "; Secure"), f.partitioned && (S += "; Partitioned"), f.priority)
|
|
79
|
+
switch (typeof f.priority == "string" ? f.priority.toLowerCase() : void 0) {
|
|
80
80
|
case "low":
|
|
81
|
-
|
|
81
|
+
S += "; Priority=Low";
|
|
82
82
|
break;
|
|
83
83
|
case "medium":
|
|
84
|
-
|
|
84
|
+
S += "; Priority=Medium";
|
|
85
85
|
break;
|
|
86
86
|
case "high":
|
|
87
|
-
|
|
87
|
+
S += "; Priority=High";
|
|
88
88
|
break;
|
|
89
89
|
default:
|
|
90
|
-
throw new TypeError(`option priority is invalid: ${
|
|
90
|
+
throw new TypeError(`option priority is invalid: ${f.priority}`);
|
|
91
91
|
}
|
|
92
|
-
if (
|
|
93
|
-
switch (typeof
|
|
92
|
+
if (f.sameSite)
|
|
93
|
+
switch (typeof f.sameSite == "string" ? f.sameSite.toLowerCase() : f.sameSite) {
|
|
94
94
|
case !0:
|
|
95
95
|
case "strict":
|
|
96
|
-
|
|
96
|
+
S += "; SameSite=Strict";
|
|
97
97
|
break;
|
|
98
98
|
case "lax":
|
|
99
|
-
|
|
99
|
+
S += "; SameSite=Lax";
|
|
100
100
|
break;
|
|
101
101
|
case "none":
|
|
102
|
-
|
|
102
|
+
S += "; SameSite=None";
|
|
103
103
|
break;
|
|
104
104
|
default:
|
|
105
|
-
throw new TypeError(`option sameSite is invalid: ${
|
|
105
|
+
throw new TypeError(`option sameSite is invalid: ${f.sameSite}`);
|
|
106
106
|
}
|
|
107
|
-
return
|
|
107
|
+
return S;
|
|
108
108
|
}
|
|
109
|
-
function l(
|
|
110
|
-
const m =
|
|
111
|
-
name:
|
|
112
|
-
value: m(
|
|
109
|
+
function l(d, w) {
|
|
110
|
+
const m = w?.decode || y, f = d.length, E = p(d, 0, f), C = h(d, 0, E), v = C === -1 ? { name: "", value: m(g(d, 0, E)) } : {
|
|
111
|
+
name: g(d, 0, C),
|
|
112
|
+
value: m(g(d, C + 1, E))
|
|
113
113
|
};
|
|
114
|
-
let
|
|
115
|
-
for (;
|
|
116
|
-
const
|
|
117
|
-
switch (
|
|
114
|
+
let S = E + 1;
|
|
115
|
+
for (; S < f; ) {
|
|
116
|
+
const A = p(d, S, f), H = h(d, S, A), b = H === -1 ? g(d, S, A) : g(d, S, H), x = H === -1 ? void 0 : g(d, H + 1, A);
|
|
117
|
+
switch (b.toLowerCase()) {
|
|
118
118
|
case "httponly":
|
|
119
|
-
|
|
119
|
+
v.httpOnly = !0;
|
|
120
120
|
break;
|
|
121
121
|
case "secure":
|
|
122
|
-
|
|
122
|
+
v.secure = !0;
|
|
123
123
|
break;
|
|
124
124
|
case "partitioned":
|
|
125
|
-
|
|
125
|
+
v.partitioned = !0;
|
|
126
126
|
break;
|
|
127
127
|
case "domain":
|
|
128
|
-
|
|
128
|
+
v.domain = x;
|
|
129
129
|
break;
|
|
130
130
|
case "path":
|
|
131
|
-
|
|
131
|
+
v.path = x;
|
|
132
132
|
break;
|
|
133
133
|
case "max-age":
|
|
134
|
-
|
|
134
|
+
x && n.test(x) && (v.maxAge = Number(x));
|
|
135
135
|
break;
|
|
136
136
|
case "expires":
|
|
137
|
-
if (!
|
|
137
|
+
if (!x)
|
|
138
138
|
break;
|
|
139
|
-
const
|
|
140
|
-
Number.isFinite(
|
|
139
|
+
const k = new Date(x);
|
|
140
|
+
Number.isFinite(k.valueOf()) && (v.expires = k);
|
|
141
141
|
break;
|
|
142
142
|
case "priority":
|
|
143
|
-
if (!
|
|
143
|
+
if (!x)
|
|
144
144
|
break;
|
|
145
|
-
const T =
|
|
146
|
-
(T === "low" || T === "medium" || T === "high") && (
|
|
145
|
+
const T = x.toLowerCase();
|
|
146
|
+
(T === "low" || T === "medium" || T === "high") && (v.priority = T);
|
|
147
147
|
break;
|
|
148
148
|
case "samesite":
|
|
149
|
-
if (!
|
|
149
|
+
if (!x)
|
|
150
150
|
break;
|
|
151
|
-
const
|
|
152
|
-
(
|
|
151
|
+
const F = x.toLowerCase();
|
|
152
|
+
(F === "lax" || F === "strict" || F === "none") && (v.sameSite = F);
|
|
153
153
|
break;
|
|
154
154
|
}
|
|
155
|
-
|
|
155
|
+
S = A + 1;
|
|
156
156
|
}
|
|
157
|
-
return
|
|
157
|
+
return v;
|
|
158
158
|
}
|
|
159
|
-
function
|
|
160
|
-
const
|
|
161
|
-
return
|
|
159
|
+
function p(d, w, m) {
|
|
160
|
+
const f = d.indexOf(";", w);
|
|
161
|
+
return f === -1 ? m : f;
|
|
162
162
|
}
|
|
163
|
-
function
|
|
164
|
-
const
|
|
165
|
-
return
|
|
163
|
+
function h(d, w, m) {
|
|
164
|
+
const f = d.indexOf("=", w);
|
|
165
|
+
return f < m ? f : -1;
|
|
166
166
|
}
|
|
167
|
-
function
|
|
168
|
-
let
|
|
167
|
+
function g(d, w, m) {
|
|
168
|
+
let f = w, E = m;
|
|
169
169
|
do {
|
|
170
|
-
const C =
|
|
170
|
+
const C = d.charCodeAt(f);
|
|
171
171
|
if (C !== 32 && C !== 9)
|
|
172
172
|
break;
|
|
173
|
-
} while (++
|
|
174
|
-
for (;
|
|
175
|
-
const C =
|
|
173
|
+
} while (++f < E);
|
|
174
|
+
for (; E > f; ) {
|
|
175
|
+
const C = d.charCodeAt(E - 1);
|
|
176
176
|
if (C !== 32 && C !== 9)
|
|
177
177
|
break;
|
|
178
|
-
|
|
178
|
+
E--;
|
|
179
179
|
}
|
|
180
|
-
return
|
|
180
|
+
return d.slice(f, E);
|
|
181
181
|
}
|
|
182
|
-
function y(
|
|
183
|
-
if (
|
|
184
|
-
return
|
|
182
|
+
function y(d) {
|
|
183
|
+
if (d.indexOf("%") === -1)
|
|
184
|
+
return d;
|
|
185
185
|
try {
|
|
186
|
-
return decodeURIComponent(
|
|
186
|
+
return decodeURIComponent(d);
|
|
187
187
|
} catch {
|
|
188
|
-
return
|
|
188
|
+
return d;
|
|
189
189
|
}
|
|
190
190
|
}
|
|
191
|
-
function R(
|
|
192
|
-
return o.call(
|
|
191
|
+
function R(d) {
|
|
192
|
+
return o.call(d) === "[object Date]";
|
|
193
193
|
}
|
|
194
|
-
return
|
|
194
|
+
return P;
|
|
195
195
|
}
|
|
196
|
-
var de = /* @__PURE__ */
|
|
197
|
-
function
|
|
198
|
-
if (ce) return
|
|
196
|
+
var de = /* @__PURE__ */ yt(), O = { exports: {} }, ce;
|
|
197
|
+
function wt() {
|
|
198
|
+
if (ce) return O.exports;
|
|
199
199
|
ce = 1;
|
|
200
200
|
var e = {
|
|
201
201
|
decodeValues: !0,
|
|
@@ -212,34 +212,34 @@ function yt() {
|
|
|
212
212
|
return typeof s == "string" && !!s.trim();
|
|
213
213
|
}
|
|
214
214
|
function n(s, i) {
|
|
215
|
-
var l = s.split(";").filter(a),
|
|
216
|
-
if (i = i ? Object.assign({}, e, i) : e, t(
|
|
215
|
+
var l = s.split(";").filter(a), p = l.shift(), h = o(p), g = h.name, y = h.value;
|
|
216
|
+
if (i = i ? Object.assign({}, e, i) : e, t(g))
|
|
217
217
|
return null;
|
|
218
218
|
try {
|
|
219
219
|
y = i.decodeValues ? decodeURIComponent(y) : y;
|
|
220
|
-
} catch (
|
|
220
|
+
} catch (d) {
|
|
221
221
|
console.error(
|
|
222
222
|
"set-cookie-parser: failed to decode cookie value. Set options.decodeValues=false to disable decoding.",
|
|
223
|
-
|
|
223
|
+
d
|
|
224
224
|
);
|
|
225
225
|
}
|
|
226
226
|
var R = r();
|
|
227
|
-
return R.name =
|
|
228
|
-
var
|
|
227
|
+
return R.name = g, R.value = y, l.forEach(function(d) {
|
|
228
|
+
var w = d.split("="), m = w.shift().trimLeft().toLowerCase();
|
|
229
229
|
if (!t(m)) {
|
|
230
|
-
var
|
|
230
|
+
var f = w.join("=");
|
|
231
231
|
if (m === "expires")
|
|
232
|
-
R.expires = new Date(
|
|
232
|
+
R.expires = new Date(f);
|
|
233
233
|
else if (m === "max-age") {
|
|
234
|
-
var
|
|
235
|
-
Number.isNaN(
|
|
236
|
-
} else m === "secure" ? R.secure = !0 : m === "httponly" ? R.httpOnly = !0 : m === "samesite" ? R.sameSite =
|
|
234
|
+
var E = parseInt(f, 10);
|
|
235
|
+
Number.isNaN(E) || (R.maxAge = E);
|
|
236
|
+
} else m === "secure" ? R.secure = !0 : m === "httponly" ? R.httpOnly = !0 : m === "samesite" ? R.sameSite = f : m === "partitioned" ? R.partitioned = !0 : m && (R[m] = f);
|
|
237
237
|
}
|
|
238
238
|
}), R;
|
|
239
239
|
}
|
|
240
240
|
function o(s) {
|
|
241
|
-
var i = "", l = "",
|
|
242
|
-
return
|
|
241
|
+
var i = "", l = "", p = s.split("=");
|
|
242
|
+
return p.length > 1 ? (i = p.shift(), l = p.join("=")) : l = s, { name: i, value: l };
|
|
243
243
|
}
|
|
244
244
|
function c(s, i) {
|
|
245
245
|
if (i = i ? Object.assign({}, e, i) : e, !s)
|
|
@@ -250,22 +250,22 @@ function yt() {
|
|
|
250
250
|
else if (s.headers["set-cookie"])
|
|
251
251
|
s = s.headers["set-cookie"];
|
|
252
252
|
else {
|
|
253
|
-
var l = s.headers[Object.keys(s.headers).find(function(
|
|
254
|
-
return
|
|
253
|
+
var l = s.headers[Object.keys(s.headers).find(function(h) {
|
|
254
|
+
return h.toLowerCase() === "set-cookie";
|
|
255
255
|
})];
|
|
256
256
|
!l && s.headers.cookie && !i.silent && console.warn(
|
|
257
257
|
"Warning: set-cookie-parser appears to have been called on a request object. It is designed to parse Set-Cookie headers from responses, not Cookie headers from requests. Set the option {silent: true} to suppress this warning."
|
|
258
258
|
), s = l;
|
|
259
259
|
}
|
|
260
260
|
if (Array.isArray(s) || (s = [s]), i.map) {
|
|
261
|
-
var
|
|
262
|
-
return s.filter(a).reduce(function(
|
|
263
|
-
var y = n(
|
|
264
|
-
return y && !t(y.name) && (
|
|
265
|
-
},
|
|
261
|
+
var p = r();
|
|
262
|
+
return s.filter(a).reduce(function(h, g) {
|
|
263
|
+
var y = n(g, i);
|
|
264
|
+
return y && !t(y.name) && (h[y.name] = y), h;
|
|
265
|
+
}, p);
|
|
266
266
|
} else
|
|
267
|
-
return s.filter(a).map(function(
|
|
268
|
-
return n(
|
|
267
|
+
return s.filter(a).map(function(h) {
|
|
268
|
+
return n(h, i);
|
|
269
269
|
}).filter(Boolean);
|
|
270
270
|
}
|
|
271
271
|
function u(s) {
|
|
@@ -273,37 +273,37 @@ function yt() {
|
|
|
273
273
|
return s;
|
|
274
274
|
if (typeof s != "string")
|
|
275
275
|
return [];
|
|
276
|
-
var i = [], l = 0,
|
|
277
|
-
function
|
|
276
|
+
var i = [], l = 0, p, h, g, y, R;
|
|
277
|
+
function d() {
|
|
278
278
|
for (; l < s.length && /\s/.test(s.charAt(l)); )
|
|
279
279
|
l += 1;
|
|
280
280
|
return l < s.length;
|
|
281
281
|
}
|
|
282
|
-
function
|
|
283
|
-
return
|
|
282
|
+
function w() {
|
|
283
|
+
return h = s.charAt(l), h !== "=" && h !== ";" && h !== ",";
|
|
284
284
|
}
|
|
285
285
|
for (; l < s.length; ) {
|
|
286
|
-
for (
|
|
287
|
-
if (
|
|
288
|
-
for (
|
|
286
|
+
for (p = l, R = !1; d(); )
|
|
287
|
+
if (h = s.charAt(l), h === ",") {
|
|
288
|
+
for (g = l, l += 1, d(), y = l; l < s.length && w(); )
|
|
289
289
|
l += 1;
|
|
290
|
-
l < s.length && s.charAt(l) === "=" ? (R = !0, l = y, i.push(s.substring(
|
|
290
|
+
l < s.length && s.charAt(l) === "=" ? (R = !0, l = y, i.push(s.substring(p, g)), p = l) : l = g + 1;
|
|
291
291
|
} else
|
|
292
292
|
l += 1;
|
|
293
|
-
(!R || l >= s.length) && i.push(s.substring(
|
|
293
|
+
(!R || l >= s.length) && i.push(s.substring(p, s.length));
|
|
294
294
|
}
|
|
295
295
|
return i;
|
|
296
296
|
}
|
|
297
|
-
return
|
|
297
|
+
return O.exports = c, O.exports.parse = c, O.exports.parseString = n, O.exports.splitCookiesString = u, O.exports;
|
|
298
298
|
}
|
|
299
|
-
var
|
|
300
|
-
function
|
|
299
|
+
var gt = /* @__PURE__ */ wt();
|
|
300
|
+
function ir({
|
|
301
301
|
context: e,
|
|
302
302
|
url: t,
|
|
303
303
|
nonce: r
|
|
304
304
|
}) {
|
|
305
305
|
typeof t == "string" && (t = new URL(t));
|
|
306
|
-
let { manifest: a, routeModules: n, criticalCss: o, serverHandoffString: c } = e, u =
|
|
306
|
+
let { manifest: a, routeModules: n, criticalCss: o, serverHandoffString: c } = e, u = qe(
|
|
307
307
|
a.routes,
|
|
308
308
|
n,
|
|
309
309
|
e.future,
|
|
@@ -313,17 +313,19 @@ function or({
|
|
|
313
313
|
...e.staticHandlerContext.loaderData
|
|
314
314
|
};
|
|
315
315
|
for (let i of e.staticHandlerContext.matches) {
|
|
316
|
-
let l = i.route.id,
|
|
317
|
-
|
|
316
|
+
let l = i.route.id, p = n[l], h = e.manifest.routes[l];
|
|
317
|
+
p && h && ee(
|
|
318
318
|
l,
|
|
319
|
-
|
|
320
|
-
|
|
319
|
+
p.clientLoader,
|
|
320
|
+
h.hasLoader,
|
|
321
321
|
e.isSpaMode
|
|
322
|
-
) && (
|
|
322
|
+
) && (p.HydrateFallback || !h.hasLoader) && delete e.staticHandlerContext.loaderData[l];
|
|
323
323
|
}
|
|
324
|
-
let s =
|
|
325
|
-
|
|
326
|
-
|
|
324
|
+
let s = Ce(u, e.staticHandlerContext, {
|
|
325
|
+
branches: e.branches
|
|
326
|
+
});
|
|
327
|
+
return /* @__PURE__ */ _.createElement(_.Fragment, null, /* @__PURE__ */ _.createElement(
|
|
328
|
+
te.Provider,
|
|
327
329
|
{
|
|
328
330
|
value: {
|
|
329
331
|
manifest: a,
|
|
@@ -334,20 +336,21 @@ function or({
|
|
|
334
336
|
ssr: e.ssr,
|
|
335
337
|
isSpaMode: e.isSpaMode,
|
|
336
338
|
routeDiscovery: e.routeDiscovery,
|
|
339
|
+
nonce: r,
|
|
337
340
|
serializeError: e.serializeError,
|
|
338
341
|
renderMeta: e.renderMeta
|
|
339
342
|
}
|
|
340
343
|
},
|
|
341
|
-
/* @__PURE__ */
|
|
342
|
-
|
|
344
|
+
/* @__PURE__ */ _.createElement(We, { location: s.state.location }, /* @__PURE__ */ _.createElement(
|
|
345
|
+
be,
|
|
343
346
|
{
|
|
344
347
|
router: s,
|
|
345
348
|
context: e.staticHandlerContext,
|
|
346
349
|
hydrate: !1
|
|
347
350
|
}
|
|
348
351
|
))
|
|
349
|
-
), e.serverHandoffStream ? /* @__PURE__ */
|
|
350
|
-
|
|
352
|
+
), e.serverHandoffStream ? /* @__PURE__ */ _.createElement(_.Suspense, null, /* @__PURE__ */ _.createElement(
|
|
353
|
+
Ve,
|
|
351
354
|
{
|
|
352
355
|
context: e,
|
|
353
356
|
identifier: 0,
|
|
@@ -357,21 +360,20 @@ function or({
|
|
|
357
360
|
}
|
|
358
361
|
)) : null);
|
|
359
362
|
}
|
|
360
|
-
function
|
|
363
|
+
function lr(e, t) {
|
|
361
364
|
return function({
|
|
362
365
|
initialEntries: a,
|
|
363
366
|
initialIndex: n,
|
|
364
367
|
hydrationData: o,
|
|
365
368
|
future: c
|
|
366
369
|
}) {
|
|
367
|
-
let u =
|
|
370
|
+
let u = _.useRef(), s = _.useRef();
|
|
368
371
|
if (u.current == null) {
|
|
369
372
|
s.current = {
|
|
370
373
|
future: {
|
|
371
|
-
|
|
372
|
-
unstable_subResourceIntegrity: c?.unstable_subResourceIntegrity === !0,
|
|
374
|
+
v8_passThroughRequests: c?.v8_passThroughRequests === !0,
|
|
373
375
|
v8_middleware: c?.v8_middleware === !0,
|
|
374
|
-
|
|
376
|
+
v8_trailingSlashAwareDataRequests: c?.v8_trailingSlashAwareDataRequests === !0
|
|
375
377
|
},
|
|
376
378
|
manifest: {
|
|
377
379
|
routes: {},
|
|
@@ -384,24 +386,24 @@ function ir(e, t) {
|
|
|
384
386
|
isSpaMode: !1,
|
|
385
387
|
routeDiscovery: { mode: "lazy", manifestPath: "/__manifest" }
|
|
386
388
|
};
|
|
387
|
-
let i =
|
|
389
|
+
let i = Ae(
|
|
388
390
|
// @ts-expect-error `StubRouteObject` is stricter about `loader`/`action`
|
|
389
391
|
// types compared to `RouteObject`
|
|
390
|
-
|
|
392
|
+
Qe(e, (l) => l),
|
|
391
393
|
t !== void 0 ? t : c?.v8_middleware ? new K() : {},
|
|
392
394
|
s.current.manifest,
|
|
393
395
|
s.current.routeModules
|
|
394
396
|
);
|
|
395
|
-
u.current =
|
|
397
|
+
u.current = Ke(i, {
|
|
396
398
|
initialEntries: a,
|
|
397
399
|
initialIndex: n,
|
|
398
400
|
hydrationData: o
|
|
399
401
|
});
|
|
400
402
|
}
|
|
401
|
-
return /* @__PURE__ */
|
|
403
|
+
return /* @__PURE__ */ _.createElement(te.Provider, { value: s.current }, /* @__PURE__ */ _.createElement(Ge, { router: u.current }));
|
|
402
404
|
};
|
|
403
405
|
}
|
|
404
|
-
function
|
|
406
|
+
function Ae(e, t, r, a, n) {
|
|
405
407
|
return e.map((o) => {
|
|
406
408
|
if (!o.id)
|
|
407
409
|
throw new Error(
|
|
@@ -411,9 +413,9 @@ function De(e, t, r, a, n) {
|
|
|
411
413
|
id: o.id,
|
|
412
414
|
path: o.path,
|
|
413
415
|
index: o.index,
|
|
414
|
-
Component: o.Component ?
|
|
415
|
-
HydrateFallback: o.HydrateFallback ?
|
|
416
|
-
ErrorBoundary: o.ErrorBoundary ?
|
|
416
|
+
Component: o.Component ? at(o.Component) : void 0,
|
|
417
|
+
HydrateFallback: o.HydrateFallback ? rt(o.HydrateFallback) : void 0,
|
|
418
|
+
ErrorBoundary: o.ErrorBoundary ? tt(o.ErrorBoundary) : void 0,
|
|
417
419
|
action: o.action ? (s) => o.action({ ...s, context: t }) : void 0,
|
|
418
420
|
loader: o.loader ? (s) => o.loader({ ...s, context: t }) : void 0,
|
|
419
421
|
middleware: o.middleware ? o.middleware.map(
|
|
@@ -446,13 +448,13 @@ function De(e, t, r, a, n) {
|
|
|
446
448
|
hydrateFallbackModule: void 0
|
|
447
449
|
};
|
|
448
450
|
return r.routes[c.id] = u, a[o.id] = {
|
|
449
|
-
default: c.Component ||
|
|
451
|
+
default: c.Component || nt,
|
|
450
452
|
ErrorBoundary: c.ErrorBoundary || void 0,
|
|
451
453
|
handle: o.handle,
|
|
452
454
|
links: o.links,
|
|
453
455
|
meta: o.meta,
|
|
454
456
|
shouldRevalidate: o.shouldRevalidate
|
|
455
|
-
}, o.children && (c.children =
|
|
457
|
+
}, o.children && (c.children = Ae(
|
|
456
458
|
o.children,
|
|
457
459
|
t,
|
|
458
460
|
r,
|
|
@@ -461,23 +463,23 @@ function De(e, t, r, a, n) {
|
|
|
461
463
|
)), c;
|
|
462
464
|
});
|
|
463
465
|
}
|
|
464
|
-
var
|
|
465
|
-
let r =
|
|
466
|
+
var ae = /* @__PURE__ */ new TextEncoder(), Rt = async (e, t) => {
|
|
467
|
+
let r = ae.encode(e), a = await De(t, ["sign"]), n = await crypto.subtle.sign("HMAC", a, r), o = btoa(String.fromCharCode(...new Uint8Array(n))).replace(
|
|
466
468
|
/=+$/,
|
|
467
469
|
""
|
|
468
470
|
);
|
|
469
471
|
return e + "." + o;
|
|
470
|
-
},
|
|
471
|
-
let r = e.lastIndexOf("."), a = e.slice(0, r), n = e.slice(r + 1), o =
|
|
472
|
+
}, vt = async (e, t) => {
|
|
473
|
+
let r = e.lastIndexOf("."), a = e.slice(0, r), n = e.slice(r + 1), o = ae.encode(a), c = await De(t, ["verify"]);
|
|
472
474
|
try {
|
|
473
475
|
let u = St(atob(n));
|
|
474
476
|
return await crypto.subtle.verify("HMAC", c, u, o) ? a : !1;
|
|
475
477
|
} catch {
|
|
476
478
|
return !1;
|
|
477
479
|
}
|
|
478
|
-
},
|
|
480
|
+
}, De = async (e, t) => crypto.subtle.importKey(
|
|
479
481
|
"raw",
|
|
480
|
-
|
|
482
|
+
ae.encode(e),
|
|
481
483
|
{ name: "HMAC", hash: "SHA-256" },
|
|
482
484
|
!1,
|
|
483
485
|
t
|
|
@@ -488,13 +490,13 @@ function St(e) {
|
|
|
488
490
|
t[r] = e.charCodeAt(r);
|
|
489
491
|
return t;
|
|
490
492
|
}
|
|
491
|
-
var
|
|
493
|
+
var Te = (e, t = {}) => {
|
|
492
494
|
let { secrets: r = [], ...a } = {
|
|
493
495
|
path: "/",
|
|
494
496
|
sameSite: "lax",
|
|
495
497
|
...t
|
|
496
498
|
};
|
|
497
|
-
return
|
|
499
|
+
return _t(e, a.expires), {
|
|
498
500
|
get name() {
|
|
499
501
|
return e;
|
|
500
502
|
},
|
|
@@ -509,14 +511,14 @@ var He = (e, t = {}) => {
|
|
|
509
511
|
let c = de.parse(n, { ...a, ...o });
|
|
510
512
|
if (e in c) {
|
|
511
513
|
let u = c[e];
|
|
512
|
-
return typeof u == "string" && u !== "" ? await
|
|
514
|
+
return typeof u == "string" && u !== "" ? await Ct(u, r) : "";
|
|
513
515
|
} else
|
|
514
516
|
return null;
|
|
515
517
|
},
|
|
516
518
|
async serialize(n, o) {
|
|
517
519
|
return de.serialize(
|
|
518
520
|
e,
|
|
519
|
-
n === "" ? "" : await
|
|
521
|
+
n === "" ? "" : await Et(n, r),
|
|
520
522
|
{
|
|
521
523
|
...a,
|
|
522
524
|
...o
|
|
@@ -524,15 +526,15 @@ var He = (e, t = {}) => {
|
|
|
524
526
|
);
|
|
525
527
|
}
|
|
526
528
|
};
|
|
527
|
-
},
|
|
528
|
-
async function vt(e, t) {
|
|
529
|
-
let r = Ct(e);
|
|
530
|
-
return t.length > 0 && (r = await gt(r, t[0])), r;
|
|
531
|
-
}
|
|
529
|
+
}, He = (e) => e != null && typeof e.name == "string" && typeof e.isSigned == "boolean" && typeof e.parse == "function" && typeof e.serialize == "function";
|
|
532
530
|
async function Et(e, t) {
|
|
531
|
+
let r = bt(e);
|
|
532
|
+
return t.length > 0 && (r = await Rt(r, t[0])), r;
|
|
533
|
+
}
|
|
534
|
+
async function Ct(e, t) {
|
|
533
535
|
if (t.length > 0) {
|
|
534
536
|
for (let r of t) {
|
|
535
|
-
let a = await
|
|
537
|
+
let a = await vt(e, r);
|
|
536
538
|
if (a !== !1)
|
|
537
539
|
return fe(a);
|
|
538
540
|
}
|
|
@@ -540,17 +542,17 @@ async function Et(e, t) {
|
|
|
540
542
|
}
|
|
541
543
|
return fe(e);
|
|
542
544
|
}
|
|
543
|
-
function
|
|
544
|
-
return btoa(
|
|
545
|
+
function bt(e) {
|
|
546
|
+
return btoa(kt(encodeURIComponent(JSON.stringify(e))));
|
|
545
547
|
}
|
|
546
548
|
function fe(e) {
|
|
547
549
|
try {
|
|
548
|
-
return JSON.parse(decodeURIComponent(
|
|
550
|
+
return JSON.parse(decodeURIComponent(xt(atob(e))));
|
|
549
551
|
} catch {
|
|
550
552
|
return {};
|
|
551
553
|
}
|
|
552
554
|
}
|
|
553
|
-
function
|
|
555
|
+
function xt(e) {
|
|
554
556
|
let t = e.toString(), r = "", a = 0, n, o;
|
|
555
557
|
for (; a < t.length; )
|
|
556
558
|
n = t.charAt(a++), /[\w*+\-./@]/.exec(n) ? r += n : (o = n.charCodeAt(0), o < 256 ? r += "%" + he(o, 2) : r += "%u" + he(o, 4).toUpperCase());
|
|
@@ -561,7 +563,7 @@ function he(e, t) {
|
|
|
561
563
|
for (; r.length < t; ) r = "0" + r;
|
|
562
564
|
return r;
|
|
563
565
|
}
|
|
564
|
-
function
|
|
566
|
+
function kt(e) {
|
|
565
567
|
let t = e.toString(), r = "", a = 0, n, o;
|
|
566
568
|
for (; a < t.length; ) {
|
|
567
569
|
if (n = t.charAt(a++), n === "%") {
|
|
@@ -579,88 +581,78 @@ function _t(e) {
|
|
|
579
581
|
}
|
|
580
582
|
return r;
|
|
581
583
|
}
|
|
582
|
-
function
|
|
583
|
-
|
|
584
|
+
function _t(e, t) {
|
|
585
|
+
ke(
|
|
584
586
|
!t,
|
|
585
587
|
`The "${e}" cookie has an "expires" property set. This will cause the expires value to not be updated when the session is committed. Instead, you should set the expires value when serializing the cookie. You can use \`commitSession(session, { expires })\` if using a session storage object, or \`cookie.serialize("value", { expires })\` if you're using the cookie directly.`
|
|
586
588
|
);
|
|
587
589
|
}
|
|
588
|
-
function
|
|
590
|
+
function At(e) {
|
|
589
591
|
return Object.keys(e).reduce((t, r) => {
|
|
590
592
|
let a = e[r];
|
|
591
593
|
return a && (t[r] = a.module), t;
|
|
592
594
|
}, {});
|
|
593
595
|
}
|
|
594
|
-
var
|
|
595
|
-
function
|
|
596
|
+
var Dt = /* @__PURE__ */ ((e) => (e.Development = "development", e.Production = "production", e.Test = "test", e))(Dt || {});
|
|
597
|
+
function Tt(e) {
|
|
596
598
|
return e === "development" || e === "production" || e === "test";
|
|
597
599
|
}
|
|
598
|
-
function
|
|
600
|
+
function ne(e, t) {
|
|
599
601
|
if (e instanceof Error && t !== "development") {
|
|
600
602
|
let r = new Error("Unexpected Server Error");
|
|
601
603
|
return r.stack = void 0, r;
|
|
602
604
|
}
|
|
603
605
|
return e;
|
|
604
606
|
}
|
|
605
|
-
function
|
|
606
|
-
return Object.entries(e).reduce((r, [a, n]) => Object.assign(r, { [a]:
|
|
607
|
+
function W(e, t) {
|
|
608
|
+
return Object.entries(e).reduce((r, [a, n]) => Object.assign(r, { [a]: ne(n, t) }), {});
|
|
607
609
|
}
|
|
608
610
|
function Fe(e, t) {
|
|
609
|
-
let r =
|
|
611
|
+
let r = ne(e, t);
|
|
610
612
|
return {
|
|
611
613
|
message: r.message,
|
|
612
614
|
stack: r.stack
|
|
613
615
|
};
|
|
614
616
|
}
|
|
615
|
-
function
|
|
616
|
-
if (!e
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
a[n] = { ...o, __type: "RouteErrorResponse" };
|
|
621
|
-
else if (o instanceof Error) {
|
|
622
|
-
let c = W(o, t);
|
|
623
|
-
a[n] = {
|
|
624
|
-
message: c.message,
|
|
625
|
-
stack: c.stack,
|
|
626
|
-
__type: "Error",
|
|
627
|
-
// If this is a subclass (i.e., ReferenceError), send up the type so we
|
|
628
|
-
// can re-create the same type during hydration. This will only apply
|
|
629
|
-
// in dev mode since all production errors are sanitized to normal
|
|
630
|
-
// Error instances
|
|
631
|
-
...c.name !== "Error" ? {
|
|
632
|
-
__subType: c.name
|
|
633
|
-
} : {}
|
|
634
|
-
};
|
|
635
|
-
} else
|
|
636
|
-
a[n] = o;
|
|
637
|
-
return a;
|
|
617
|
+
function B(e, t) {
|
|
618
|
+
if (e === !1 || e === null || typeof e > "u")
|
|
619
|
+
throw console.error(
|
|
620
|
+
"The following error is a bug in React Router; please open an issue! https://github.com/remix-run/react-router/issues/new/choose"
|
|
621
|
+
), new Error(t);
|
|
638
622
|
}
|
|
639
|
-
function
|
|
640
|
-
let
|
|
641
|
-
e,
|
|
623
|
+
function Pe(e, t, r, a, n) {
|
|
624
|
+
let o = ft(
|
|
642
625
|
t,
|
|
626
|
+
a,
|
|
627
|
+
n ?? "/",
|
|
628
|
+
!1,
|
|
643
629
|
r
|
|
644
630
|
);
|
|
645
|
-
return
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
631
|
+
return o ? o.map((c) => {
|
|
632
|
+
let u = e[c.route.id];
|
|
633
|
+
return B(
|
|
634
|
+
u,
|
|
635
|
+
`Route with id "${c.route.id}" not found in manifest.`
|
|
636
|
+
), {
|
|
637
|
+
params: c.params,
|
|
638
|
+
pathname: c.pathname,
|
|
639
|
+
route: u
|
|
640
|
+
};
|
|
641
|
+
}) : null;
|
|
650
642
|
}
|
|
651
|
-
async function
|
|
643
|
+
async function pe(e, t, r) {
|
|
652
644
|
let a = await e({
|
|
653
|
-
request: r.
|
|
654
|
-
|
|
645
|
+
request: r.v8_passThroughRequests ? t.request : Ft(Ht(t.request)),
|
|
646
|
+
url: t.url,
|
|
655
647
|
params: t.params,
|
|
656
648
|
context: t.context,
|
|
657
|
-
|
|
649
|
+
pattern: t.pattern
|
|
658
650
|
});
|
|
659
|
-
if (
|
|
651
|
+
if (dt(a) && a.init && a.init.status && re(a.init.status))
|
|
660
652
|
throw new Response(null, a.init);
|
|
661
653
|
return a;
|
|
662
654
|
}
|
|
663
|
-
function
|
|
655
|
+
function Ht(e) {
|
|
664
656
|
let t = new URL(e.url), r = t.searchParams.getAll("index");
|
|
665
657
|
t.searchParams.delete("index");
|
|
666
658
|
let a = [];
|
|
@@ -676,7 +668,7 @@ function Tt(e) {
|
|
|
676
668
|
};
|
|
677
669
|
return n.body && (n.duplex = "half"), new Request(t.href, n);
|
|
678
670
|
}
|
|
679
|
-
function
|
|
671
|
+
function Ft(e) {
|
|
680
672
|
let t = new URL(e.url);
|
|
681
673
|
t.searchParams.delete("_routes");
|
|
682
674
|
let r = {
|
|
@@ -687,14 +679,8 @@ function Ht(e) {
|
|
|
687
679
|
};
|
|
688
680
|
return r.body && (r.duplex = "half"), new Request(t.href, r);
|
|
689
681
|
}
|
|
690
|
-
function z(e, t) {
|
|
691
|
-
if (e === !1 || e === null || typeof e > "u")
|
|
692
|
-
throw console.error(
|
|
693
|
-
"The following error is a bug in React Router; please open an issue! https://github.com/remix-run/react-router/issues/new/choose"
|
|
694
|
-
), new Error(t);
|
|
695
|
-
}
|
|
696
682
|
var Ue = "__reactRouterDevServerHooks";
|
|
697
|
-
function
|
|
683
|
+
function ur(e) {
|
|
698
684
|
globalThis[Ue] = e;
|
|
699
685
|
}
|
|
700
686
|
function X() {
|
|
@@ -709,7 +695,7 @@ function Le(e, t) {
|
|
|
709
695
|
}
|
|
710
696
|
return null;
|
|
711
697
|
}
|
|
712
|
-
function
|
|
698
|
+
function Pt(e) {
|
|
713
699
|
let t = {};
|
|
714
700
|
return Object.values(e).forEach((r) => {
|
|
715
701
|
if (r) {
|
|
@@ -718,13 +704,7 @@ function Ne(e) {
|
|
|
718
704
|
}
|
|
719
705
|
}), t;
|
|
720
706
|
}
|
|
721
|
-
function
|
|
722
|
-
return (r[t] || []).map((a) => ({
|
|
723
|
-
...a,
|
|
724
|
-
children: Oe(e, a.id, r)
|
|
725
|
-
}));
|
|
726
|
-
}
|
|
727
|
-
function Ie(e, t, r = "", a = Ne(e)) {
|
|
707
|
+
function Ie(e, t, r = "", a = Pt(e)) {
|
|
728
708
|
return (a[r] || []).map((n) => {
|
|
729
709
|
let o = {
|
|
730
710
|
// Always include root due to default boundaries
|
|
@@ -741,34 +721,34 @@ function Ie(e, t, r = "", a = Ne(e)) {
|
|
|
741
721
|
);
|
|
742
722
|
if (u != null) {
|
|
743
723
|
let i = u && decodeURI(u);
|
|
744
|
-
|
|
745
|
-
let l = new TextEncoder().encode(i),
|
|
724
|
+
B(i, "Missing prerendered data for route");
|
|
725
|
+
let l = new TextEncoder().encode(i), p = new ReadableStream({
|
|
746
726
|
start(y) {
|
|
747
727
|
y.enqueue(l), y.close();
|
|
748
728
|
}
|
|
749
|
-
}),
|
|
750
|
-
if (
|
|
751
|
-
let y =
|
|
752
|
-
throw y.reload ?
|
|
729
|
+
}), g = (await st(p, global)).value;
|
|
730
|
+
if (g && M in g) {
|
|
731
|
+
let y = g[M], R = { status: y.status };
|
|
732
|
+
throw y.reload ? ot(y.redirect, R) : y.replace ? it(y.redirect, R) : lt(y.redirect, R);
|
|
753
733
|
} else {
|
|
754
|
-
|
|
755
|
-
|
|
734
|
+
B(
|
|
735
|
+
g && n.id in g,
|
|
756
736
|
"Unable to decode prerendered data"
|
|
757
737
|
);
|
|
758
|
-
let y =
|
|
759
|
-
return
|
|
738
|
+
let y = g[n.id];
|
|
739
|
+
return B(
|
|
760
740
|
"data" in y,
|
|
761
741
|
"Unable to process prerendered data"
|
|
762
742
|
), y.data;
|
|
763
743
|
}
|
|
764
744
|
}
|
|
765
|
-
return await
|
|
745
|
+
return await pe(
|
|
766
746
|
n.module.loader,
|
|
767
747
|
c,
|
|
768
748
|
t
|
|
769
749
|
);
|
|
770
750
|
} : void 0,
|
|
771
|
-
action: n.module.action ? (c) =>
|
|
751
|
+
action: n.module.action ? (c) => pe(n.module.action, c, t) : void 0,
|
|
772
752
|
handle: n.module.handle
|
|
773
753
|
};
|
|
774
754
|
return n.index ? {
|
|
@@ -786,53 +766,53 @@ function Ie(e, t, r = "", a = Ne(e)) {
|
|
|
786
766
|
};
|
|
787
767
|
});
|
|
788
768
|
}
|
|
789
|
-
function
|
|
769
|
+
function me(e) {
|
|
790
770
|
return G(JSON.stringify(e));
|
|
791
771
|
}
|
|
792
772
|
function se(e, t) {
|
|
793
|
-
return
|
|
773
|
+
return Ut(e, (r) => {
|
|
794
774
|
let a = t.routes[r.route.id];
|
|
795
|
-
return
|
|
775
|
+
return B(a, `Route with id "${r.route.id}" not found in build`), a.module.headers;
|
|
796
776
|
});
|
|
797
777
|
}
|
|
798
|
-
function
|
|
778
|
+
function Ut(e, t, r) {
|
|
799
779
|
let a = e.errors ? e.matches.findIndex((u) => e.errors[u.route.id]) : -1, n = a >= 0 ? e.matches.slice(0, a + 1) : e.matches, o;
|
|
800
780
|
if (a >= 0) {
|
|
801
781
|
let { actionHeaders: u, actionData: s, loaderHeaders: i, loaderData: l } = e;
|
|
802
|
-
e.matches.slice(a).some((
|
|
803
|
-
let
|
|
804
|
-
return u[
|
|
782
|
+
e.matches.slice(a).some((p) => {
|
|
783
|
+
let h = p.route.id;
|
|
784
|
+
return u[h] && (!s || !s.hasOwnProperty(h)) ? o = u[h] : i[h] && !l.hasOwnProperty(h) && (o = i[h]), o != null;
|
|
805
785
|
});
|
|
806
786
|
}
|
|
807
787
|
const c = new Headers(r);
|
|
808
788
|
return n.reduce((u, s, i) => {
|
|
809
|
-
let { id: l } = s.route,
|
|
789
|
+
let { id: l } = s.route, p = e.loaderHeaders[l] || new Headers(), h = e.actionHeaders[l] || new Headers(), g = o != null && i === n.length - 1, y = g && o !== p && o !== h, R = t(s);
|
|
810
790
|
if (R == null) {
|
|
811
|
-
let
|
|
812
|
-
return y && U(o,
|
|
791
|
+
let w = new Headers(u);
|
|
792
|
+
return y && U(o, w), U(h, w), U(p, w), w;
|
|
813
793
|
}
|
|
814
|
-
let
|
|
794
|
+
let d = new Headers(
|
|
815
795
|
typeof R == "function" ? R({
|
|
816
|
-
loaderHeaders:
|
|
796
|
+
loaderHeaders: p,
|
|
817
797
|
parentHeaders: u,
|
|
818
|
-
actionHeaders:
|
|
819
|
-
errorHeaders:
|
|
798
|
+
actionHeaders: h,
|
|
799
|
+
errorHeaders: g ? o : void 0
|
|
820
800
|
}) : R
|
|
821
801
|
);
|
|
822
|
-
return y && U(o,
|
|
802
|
+
return y && U(o, d), U(h, d), U(p, d), U(u, d), d;
|
|
823
803
|
}, new Headers(c));
|
|
824
804
|
}
|
|
825
805
|
function U(e, t) {
|
|
826
806
|
let r = e.get("Set-Cookie");
|
|
827
807
|
if (r) {
|
|
828
|
-
let a =
|
|
808
|
+
let a = gt.splitCookiesString(r), n = new Set(t.getSetCookie());
|
|
829
809
|
a.forEach((o) => {
|
|
830
810
|
n.has(o) || t.append("Set-Cookie", o);
|
|
831
811
|
});
|
|
832
812
|
}
|
|
833
813
|
}
|
|
834
|
-
function
|
|
835
|
-
let r = e.get("origin"), a = null;
|
|
814
|
+
function Ne(e, t) {
|
|
815
|
+
let r = e.headers.get("origin"), a = null;
|
|
836
816
|
try {
|
|
837
817
|
a = typeof r == "string" && r !== "null" ? new URL(r).host : r;
|
|
838
818
|
} catch {
|
|
@@ -840,15 +820,13 @@ function Be(e, t) {
|
|
|
840
820
|
"`origin` header is not a valid URL. Aborting the action."
|
|
841
821
|
);
|
|
842
822
|
}
|
|
843
|
-
let n =
|
|
844
|
-
if (a &&
|
|
845
|
-
throw
|
|
846
|
-
|
|
847
|
-
) : new Error(
|
|
848
|
-
"`x-forwarded-host` or `host` headers are not provided. One of these is needed to compare the `origin` header from a forwarded action request. Aborting the action."
|
|
823
|
+
let n = new URL(e.url).host;
|
|
824
|
+
if (a && a !== n && !It(a, t))
|
|
825
|
+
throw new Error(
|
|
826
|
+
"The `request.url` host does not match `origin` header from a forwarded action request. Aborting the action."
|
|
849
827
|
);
|
|
850
828
|
}
|
|
851
|
-
function
|
|
829
|
+
function Lt(e, t) {
|
|
852
830
|
const r = e.split("."), a = t.split(".");
|
|
853
831
|
if (a.length < 1 || r.length < a.length)
|
|
854
832
|
return !1;
|
|
@@ -871,25 +849,15 @@ function Ft(e, t) {
|
|
|
871
849
|
}
|
|
872
850
|
return r.length === 0;
|
|
873
851
|
}
|
|
874
|
-
function
|
|
852
|
+
function It(e, t = []) {
|
|
875
853
|
return t.some(
|
|
876
|
-
(r) => r && (r === e ||
|
|
854
|
+
(r) => r && (r === e || Lt(e, r))
|
|
877
855
|
);
|
|
878
856
|
}
|
|
879
|
-
function
|
|
880
|
-
let r = e.get("x-forwarded-host")?.split(",")[0]?.trim(), a = e.get("host");
|
|
881
|
-
return r ? {
|
|
882
|
-
type: "x-forwarded-host",
|
|
883
|
-
value: r
|
|
884
|
-
} : a ? {
|
|
885
|
-
type: "host",
|
|
886
|
-
value: a
|
|
887
|
-
} : void 0;
|
|
888
|
-
}
|
|
889
|
-
function M(e, t, r) {
|
|
857
|
+
function j(e, t, r) {
|
|
890
858
|
t = t || "/";
|
|
891
859
|
let a = new URL(e.url), n = a.pathname;
|
|
892
|
-
r?.
|
|
860
|
+
r?.v8_trailingSlashAwareDataRequests ? n.endsWith("/_.data") ? n = n.replace(/_\.data$/, "") : n = n.replace(/\.data$/, "") : (z(n, t) === "/_root.data" ? n = t : n.endsWith(".data") && (n = n.replace(/\.data$/, "")), z(n, t) !== "/" && n.endsWith("/") && (n = n.slice(0, -1)));
|
|
893
861
|
let o = new URLSearchParams(a.search);
|
|
894
862
|
o.delete("_routes");
|
|
895
863
|
let c = o.toString();
|
|
@@ -900,67 +868,67 @@ function M(e, t, r) {
|
|
|
900
868
|
hash: ""
|
|
901
869
|
};
|
|
902
870
|
}
|
|
903
|
-
var
|
|
904
|
-
...
|
|
871
|
+
var Oe = /* @__PURE__ */ new Set([
|
|
872
|
+
...pt,
|
|
905
873
|
304
|
|
906
874
|
]);
|
|
907
875
|
async function Nt(e, t, r, a, n, o, c) {
|
|
908
876
|
try {
|
|
909
877
|
try {
|
|
910
|
-
|
|
911
|
-
a
|
|
878
|
+
Ne(
|
|
879
|
+
a,
|
|
912
880
|
Array.isArray(e.allowedActionOrigins) ? e.allowedActionOrigins : []
|
|
913
881
|
);
|
|
914
882
|
} catch {
|
|
915
883
|
return s(new Error("Bad Request"), 400);
|
|
916
884
|
}
|
|
917
|
-
let l = e.future.
|
|
885
|
+
let l = e.future.v8_passThroughRequests ? a : new Request(n, {
|
|
918
886
|
method: a.method,
|
|
919
887
|
body: a.body,
|
|
920
888
|
headers: a.headers,
|
|
921
889
|
signal: a.signal,
|
|
922
890
|
...a.body ? { duplex: "half" } : void 0
|
|
923
|
-
}),
|
|
891
|
+
}), p = await r.query(l, {
|
|
924
892
|
requestContext: o,
|
|
925
893
|
skipLoaderErrorBubbling: !0,
|
|
926
894
|
skipRevalidation: !0,
|
|
927
|
-
generateMiddlewareResponse: e.future.v8_middleware ? async (
|
|
895
|
+
generateMiddlewareResponse: e.future.v8_middleware ? async (h) => {
|
|
928
896
|
try {
|
|
929
|
-
let
|
|
930
|
-
return u(
|
|
931
|
-
} catch (
|
|
932
|
-
return s(
|
|
897
|
+
let g = await h(l);
|
|
898
|
+
return u(g);
|
|
899
|
+
} catch (g) {
|
|
900
|
+
return s(g);
|
|
933
901
|
}
|
|
934
902
|
} : void 0,
|
|
935
|
-
|
|
903
|
+
normalizePath: (h) => j(h, e.basename, e.future)
|
|
936
904
|
});
|
|
937
|
-
return u(
|
|
905
|
+
return u(p);
|
|
938
906
|
} catch (l) {
|
|
939
907
|
return s(l);
|
|
940
908
|
}
|
|
941
909
|
function u(l) {
|
|
942
|
-
return
|
|
910
|
+
return I(l) ? l : i(l);
|
|
943
911
|
}
|
|
944
|
-
function s(l,
|
|
945
|
-
return c(l),
|
|
912
|
+
function s(l, p = 500) {
|
|
913
|
+
return c(l), $(a, e, t, {
|
|
946
914
|
result: { error: l },
|
|
947
915
|
headers: new Headers(),
|
|
948
|
-
status:
|
|
916
|
+
status: p
|
|
949
917
|
});
|
|
950
918
|
}
|
|
951
919
|
function i(l) {
|
|
952
|
-
let
|
|
953
|
-
if (
|
|
954
|
-
return new Response(null, { status: l.statusCode, headers:
|
|
955
|
-
l.errors && (Object.values(l.errors).forEach((
|
|
956
|
-
(!
|
|
957
|
-
}), l.errors =
|
|
958
|
-
let
|
|
959
|
-
return l.errors ?
|
|
920
|
+
let p = se(l, e);
|
|
921
|
+
if (re(l.statusCode) && p.has("Location"))
|
|
922
|
+
return new Response(null, { status: l.statusCode, headers: p });
|
|
923
|
+
l.errors && (Object.values(l.errors).forEach((g) => {
|
|
924
|
+
(!N(g) || g.error) && c(g);
|
|
925
|
+
}), l.errors = W(l.errors, t));
|
|
926
|
+
let h;
|
|
927
|
+
return l.errors ? h = { error: Object.values(l.errors)[0] } : h = {
|
|
960
928
|
data: Object.values(l.actionData || {})[0]
|
|
961
|
-
},
|
|
962
|
-
result:
|
|
963
|
-
headers:
|
|
929
|
+
}, $(a, e, t, {
|
|
930
|
+
result: h,
|
|
931
|
+
headers: p,
|
|
964
932
|
status: l.statusCode
|
|
965
933
|
});
|
|
966
934
|
}
|
|
@@ -968,69 +936,69 @@ async function Nt(e, t, r, a, n, o, c) {
|
|
|
968
936
|
async function Ot(e, t, r, a, n, o, c) {
|
|
969
937
|
let u = new URL(a.url).searchParams.get("_routes"), s = u ? new Set(u.split(",")) : null;
|
|
970
938
|
try {
|
|
971
|
-
let
|
|
939
|
+
let h = e.future.v8_passThroughRequests ? a : new Request(n, {
|
|
972
940
|
headers: a.headers,
|
|
973
941
|
signal: a.signal
|
|
974
|
-
}),
|
|
942
|
+
}), g = await r.query(h, {
|
|
975
943
|
requestContext: o,
|
|
976
944
|
filterMatchesToLoad: (y) => !s || s.has(y.route.id),
|
|
977
945
|
skipLoaderErrorBubbling: !0,
|
|
978
946
|
generateMiddlewareResponse: e.future.v8_middleware ? async (y) => {
|
|
979
947
|
try {
|
|
980
|
-
let R = await y(
|
|
948
|
+
let R = await y(h);
|
|
981
949
|
return i(R);
|
|
982
950
|
} catch (R) {
|
|
983
951
|
return l(R);
|
|
984
952
|
}
|
|
985
953
|
} : void 0,
|
|
986
|
-
|
|
954
|
+
normalizePath: (y) => j(y, e.basename, e.future)
|
|
987
955
|
});
|
|
988
|
-
return i(
|
|
989
|
-
} catch (
|
|
990
|
-
return l(
|
|
956
|
+
return i(g);
|
|
957
|
+
} catch (h) {
|
|
958
|
+
return l(h);
|
|
991
959
|
}
|
|
992
|
-
function i(
|
|
993
|
-
return
|
|
960
|
+
function i(h) {
|
|
961
|
+
return I(h) ? h : p(h);
|
|
994
962
|
}
|
|
995
|
-
function l(
|
|
996
|
-
return c(
|
|
997
|
-
result: { error:
|
|
963
|
+
function l(h) {
|
|
964
|
+
return c(h), $(a, e, t, {
|
|
965
|
+
result: { error: h },
|
|
998
966
|
headers: new Headers(),
|
|
999
967
|
status: 500
|
|
1000
968
|
});
|
|
1001
969
|
}
|
|
1002
|
-
function h
|
|
1003
|
-
let
|
|
1004
|
-
if (
|
|
1005
|
-
return new Response(null, { status:
|
|
1006
|
-
|
|
1007
|
-
(!
|
|
1008
|
-
}),
|
|
970
|
+
function p(h) {
|
|
971
|
+
let g = se(h, e);
|
|
972
|
+
if (re(h.statusCode) && g.has("Location"))
|
|
973
|
+
return new Response(null, { status: h.statusCode, headers: g });
|
|
974
|
+
h.errors && (Object.values(h.errors).forEach((d) => {
|
|
975
|
+
(!N(d) || d.error) && c(d);
|
|
976
|
+
}), h.errors = W(h.errors, t));
|
|
1009
977
|
let y = {}, R = new Set(
|
|
1010
|
-
|
|
1011
|
-
(
|
|
1012
|
-
).map((
|
|
978
|
+
h.matches.filter(
|
|
979
|
+
(d) => s ? s.has(d.route.id) : d.route.loader != null
|
|
980
|
+
).map((d) => d.route.id)
|
|
1013
981
|
);
|
|
1014
|
-
if (
|
|
1015
|
-
for (let [
|
|
1016
|
-
y[
|
|
1017
|
-
for (let [
|
|
1018
|
-
!(
|
|
1019
|
-
return
|
|
982
|
+
if (h.errors)
|
|
983
|
+
for (let [d, w] of Object.entries(h.errors))
|
|
984
|
+
y[d] = { error: w };
|
|
985
|
+
for (let [d, w] of Object.entries(h.loaderData))
|
|
986
|
+
!(d in y) && R.has(d) && (y[d] = { data: w });
|
|
987
|
+
return $(a, e, t, {
|
|
1020
988
|
result: y,
|
|
1021
|
-
headers:
|
|
1022
|
-
status:
|
|
989
|
+
headers: g,
|
|
990
|
+
status: h.statusCode
|
|
1023
991
|
});
|
|
1024
992
|
}
|
|
1025
993
|
}
|
|
1026
|
-
function
|
|
994
|
+
function $(e, t, r, {
|
|
1027
995
|
result: a,
|
|
1028
996
|
headers: n,
|
|
1029
997
|
status: o
|
|
1030
998
|
}) {
|
|
1031
999
|
let c = new Headers(n);
|
|
1032
|
-
return c.set("X-Remix-Response", "yes"),
|
|
1033
|
-
|
|
1000
|
+
return c.set("X-Remix-Response", "yes"), Oe.has(o) ? new Response(null, { status: o, headers: c }) : (c.set("Content-Type", "text/x-script"), c.delete("Content-Length"), new Response(
|
|
1001
|
+
Y(
|
|
1034
1002
|
a,
|
|
1035
1003
|
e.signal,
|
|
1036
1004
|
t.entry.module.streamTimeout,
|
|
@@ -1042,21 +1010,21 @@ function B(e, t, r, {
|
|
|
1042
1010
|
}
|
|
1043
1011
|
));
|
|
1044
1012
|
}
|
|
1045
|
-
function
|
|
1046
|
-
let n =
|
|
1013
|
+
function ye(e, t, r, a) {
|
|
1014
|
+
let n = Bt(
|
|
1047
1015
|
e.status,
|
|
1048
1016
|
e.headers,
|
|
1049
1017
|
r.basename
|
|
1050
1018
|
), o = new Headers(e.headers);
|
|
1051
|
-
return o.delete("Location"), o.set("Content-Type", "text/x-script"),
|
|
1052
|
-
result: t.method === "GET" ? { [
|
|
1019
|
+
return o.delete("Location"), o.set("Content-Type", "text/x-script"), $(t, r, a, {
|
|
1020
|
+
result: t.method === "GET" ? { [M]: n } : n,
|
|
1053
1021
|
headers: o,
|
|
1054
|
-
status:
|
|
1022
|
+
status: xe
|
|
1055
1023
|
});
|
|
1056
1024
|
}
|
|
1057
|
-
function
|
|
1025
|
+
function Bt(e, t, r) {
|
|
1058
1026
|
let a = t.get("Location");
|
|
1059
|
-
return r && (a =
|
|
1027
|
+
return r && (a = z(a, r) || a), {
|
|
1060
1028
|
redirect: a,
|
|
1061
1029
|
status: e,
|
|
1062
1030
|
revalidate: (
|
|
@@ -1073,7 +1041,7 @@ function It(e, t, r) {
|
|
|
1073
1041
|
replace: t.has("X-Remix-Replace")
|
|
1074
1042
|
};
|
|
1075
1043
|
}
|
|
1076
|
-
function
|
|
1044
|
+
function Y(e, t, r, a) {
|
|
1077
1045
|
let n = new AbortController(), o = setTimeout(
|
|
1078
1046
|
() => {
|
|
1079
1047
|
n.abort(new Error("Server Timeout")), u();
|
|
@@ -1086,21 +1054,21 @@ function Z(e, t, r, a) {
|
|
|
1086
1054
|
let u = () => {
|
|
1087
1055
|
clearTimeout(o), t.removeEventListener("abort", c);
|
|
1088
1056
|
};
|
|
1089
|
-
return
|
|
1057
|
+
return mt(e, {
|
|
1090
1058
|
signal: n.signal,
|
|
1091
1059
|
onComplete: u,
|
|
1092
1060
|
plugins: [
|
|
1093
1061
|
(s) => {
|
|
1094
1062
|
if (s instanceof Error) {
|
|
1095
|
-
let { name: i, message: l, stack:
|
|
1096
|
-
return ["SanitizedError", i, l,
|
|
1063
|
+
let { name: i, message: l, stack: p } = a === "production" ? ne(s, a) : s;
|
|
1064
|
+
return ["SanitizedError", i, l, p];
|
|
1097
1065
|
}
|
|
1098
|
-
if (s instanceof
|
|
1099
|
-
let { data: i, status: l, statusText:
|
|
1100
|
-
return ["ErrorResponse", i, l,
|
|
1066
|
+
if (s instanceof q) {
|
|
1067
|
+
let { data: i, status: l, statusText: p } = s;
|
|
1068
|
+
return ["ErrorResponse", i, l, p];
|
|
1101
1069
|
}
|
|
1102
|
-
if (s && typeof s == "object" &&
|
|
1103
|
-
return ["SingleFetchRedirect", s[
|
|
1070
|
+
if (s && typeof s == "object" && M in s)
|
|
1071
|
+
return ["SingleFetchRedirect", s[M]];
|
|
1104
1072
|
}
|
|
1105
1073
|
],
|
|
1106
1074
|
postPlugins: [
|
|
@@ -1115,206 +1083,215 @@ function Z(e, t, r, a) {
|
|
|
1115
1083
|
]
|
|
1116
1084
|
});
|
|
1117
1085
|
}
|
|
1118
|
-
function
|
|
1119
|
-
let r =
|
|
1086
|
+
function we(e, t) {
|
|
1087
|
+
let r = Ie(e.routes, e.future), a = Tt(t) ? t : "production", n = Ze(r, {
|
|
1120
1088
|
basename: e.basename,
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1089
|
+
instrumentations: e.entry.module.instrumentations,
|
|
1090
|
+
future: e.future
|
|
1091
|
+
}), o = e.entry.module.handleError || ((u, { request: s }) => {
|
|
1092
|
+
a !== "test" && !s.signal.aborted && console.error(
|
|
1124
1093
|
// @ts-expect-error This is "private" from users but intended for internal use
|
|
1125
|
-
|
|
1094
|
+
N(u) && u.error ? u.error : u
|
|
1126
1095
|
);
|
|
1127
|
-
}),
|
|
1128
|
-
let
|
|
1129
|
-
t === "development" && X()?.processRequestError?.(
|
|
1130
|
-
context:
|
|
1131
|
-
params:
|
|
1132
|
-
request:
|
|
1096
|
+
}), c = async (u, s) => {
|
|
1097
|
+
let i = {}, l, p = (m) => {
|
|
1098
|
+
t === "development" && X()?.processRequestError?.(m), o(m, {
|
|
1099
|
+
context: l,
|
|
1100
|
+
params: i,
|
|
1101
|
+
request: u
|
|
1133
1102
|
});
|
|
1134
1103
|
};
|
|
1135
1104
|
if (e.future.v8_middleware) {
|
|
1136
|
-
if (
|
|
1137
|
-
let
|
|
1105
|
+
if (s && !(s instanceof K)) {
|
|
1106
|
+
let m = new Error(
|
|
1138
1107
|
"Invalid `context` value provided to `handleRequest`. When middleware is enabled you must return an instance of `RouterContextProvider` from your `getLoadContext` function."
|
|
1139
1108
|
);
|
|
1140
|
-
return p(
|
|
1109
|
+
return p(m), V(m, a);
|
|
1141
1110
|
}
|
|
1142
|
-
|
|
1111
|
+
l = s || new K();
|
|
1143
1112
|
} else
|
|
1144
|
-
|
|
1145
|
-
let
|
|
1146
|
-
|
|
1113
|
+
l = s || {};
|
|
1114
|
+
let h = new URL(u.url), g = j(
|
|
1115
|
+
u,
|
|
1147
1116
|
e.basename,
|
|
1148
1117
|
e.future
|
|
1149
|
-
).pathname,
|
|
1118
|
+
).pathname, y = Le(u, "X-React-Router-SPA-Mode") === "yes";
|
|
1150
1119
|
if (!e.ssr) {
|
|
1151
|
-
let
|
|
1120
|
+
let m = decodeURI(g);
|
|
1152
1121
|
if (e.basename && e.basename !== "/") {
|
|
1153
|
-
let
|
|
1154
|
-
if (
|
|
1155
|
-
return
|
|
1156
|
-
new
|
|
1122
|
+
let f = z(m, e.basename);
|
|
1123
|
+
if (f == null)
|
|
1124
|
+
return o(
|
|
1125
|
+
new q(
|
|
1157
1126
|
404,
|
|
1158
1127
|
"Not Found",
|
|
1159
|
-
`Refusing to prerender the \`${
|
|
1128
|
+
`Refusing to prerender the \`${m}\` path because it does not start with the basename \`${e.basename}\``
|
|
1160
1129
|
),
|
|
1161
1130
|
{
|
|
1162
|
-
context:
|
|
1163
|
-
params:
|
|
1164
|
-
request:
|
|
1131
|
+
context: l,
|
|
1132
|
+
params: i,
|
|
1133
|
+
request: u
|
|
1165
1134
|
}
|
|
1166
1135
|
), new Response("Not Found", {
|
|
1167
1136
|
status: 404,
|
|
1168
1137
|
statusText: "Not Found"
|
|
1169
1138
|
});
|
|
1170
|
-
|
|
1139
|
+
m = f;
|
|
1171
1140
|
}
|
|
1172
1141
|
if (e.prerender.length === 0)
|
|
1173
|
-
|
|
1174
|
-
else if (!e.prerender.includes(
|
|
1175
|
-
if (
|
|
1176
|
-
return
|
|
1177
|
-
new
|
|
1142
|
+
y = !0;
|
|
1143
|
+
else if (!e.prerender.includes(m.replace(/\/$/, "")) && !e.prerender.includes(m.replace(/[^/]$/, "/"))) {
|
|
1144
|
+
if (h.pathname.endsWith(".data"))
|
|
1145
|
+
return o(
|
|
1146
|
+
new q(
|
|
1178
1147
|
404,
|
|
1179
1148
|
"Not Found",
|
|
1180
|
-
`Refusing to SSR the path \`${
|
|
1149
|
+
`Refusing to SSR the path \`${m}\` because \`ssr:false\` is set and the path is not included in the \`prerender\` config, so in production the path will be a 404.`
|
|
1181
1150
|
),
|
|
1182
1151
|
{
|
|
1183
|
-
context:
|
|
1184
|
-
params:
|
|
1185
|
-
request:
|
|
1152
|
+
context: l,
|
|
1153
|
+
params: i,
|
|
1154
|
+
request: u
|
|
1186
1155
|
}
|
|
1187
1156
|
), new Response("Not Found", {
|
|
1188
1157
|
status: 404,
|
|
1189
1158
|
statusText: "Not Found"
|
|
1190
1159
|
});
|
|
1191
|
-
|
|
1160
|
+
y = !0;
|
|
1192
1161
|
}
|
|
1193
1162
|
}
|
|
1194
|
-
let
|
|
1163
|
+
let R = ut(
|
|
1195
1164
|
e.routeDiscovery.manifestPath,
|
|
1196
1165
|
e.basename
|
|
1197
1166
|
);
|
|
1198
|
-
if (
|
|
1167
|
+
if (e.routeDiscovery.mode === "lazy" && h.pathname === R)
|
|
1199
1168
|
try {
|
|
1200
|
-
return await
|
|
1201
|
-
|
|
1202
|
-
|
|
1169
|
+
return await Mt(
|
|
1170
|
+
e,
|
|
1171
|
+
n.dataRoutes,
|
|
1172
|
+
n._internalRouteBranches,
|
|
1173
|
+
h
|
|
1174
|
+
);
|
|
1175
|
+
} catch (m) {
|
|
1176
|
+
return p(m), new Response("Unknown Server Error", { status: 500 });
|
|
1203
1177
|
}
|
|
1204
|
-
let
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1178
|
+
let d = Pe(
|
|
1179
|
+
e.routes,
|
|
1180
|
+
n.dataRoutes,
|
|
1181
|
+
n._internalRouteBranches,
|
|
1182
|
+
g,
|
|
1183
|
+
e.basename
|
|
1184
|
+
);
|
|
1185
|
+
d && d.length > 0 && Object.assign(i, d[0].params);
|
|
1186
|
+
let w;
|
|
1187
|
+
if (h.pathname.endsWith(".data"))
|
|
1188
|
+
w = await $t(
|
|
1189
|
+
a,
|
|
1215
1190
|
e,
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1191
|
+
n,
|
|
1192
|
+
u,
|
|
1193
|
+
g,
|
|
1194
|
+
l,
|
|
1220
1195
|
p
|
|
1221
|
-
), le(
|
|
1222
|
-
|
|
1223
|
-
|
|
1196
|
+
), le(w) && (w = ye(
|
|
1197
|
+
w,
|
|
1198
|
+
u,
|
|
1224
1199
|
e,
|
|
1225
|
-
|
|
1226
|
-
)), e.entry.module.handleDataRequest && (
|
|
1227
|
-
context:
|
|
1200
|
+
a
|
|
1201
|
+
)), e.entry.module.handleDataRequest && (w = await e.entry.module.handleDataRequest(w, {
|
|
1202
|
+
context: l,
|
|
1228
1203
|
params: d ? d[0].params : {},
|
|
1229
|
-
request:
|
|
1230
|
-
}), le(
|
|
1231
|
-
|
|
1232
|
-
|
|
1204
|
+
request: u
|
|
1205
|
+
}), le(w) && (w = ye(
|
|
1206
|
+
w,
|
|
1207
|
+
u,
|
|
1233
1208
|
e,
|
|
1234
|
-
|
|
1209
|
+
a
|
|
1235
1210
|
)));
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1211
|
+
else if (!y && d && d[d.length - 1].route.module.default == null && d[d.length - 1].route.module.ErrorBoundary == null)
|
|
1212
|
+
w = await zt(
|
|
1213
|
+
a,
|
|
1239
1214
|
e,
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1215
|
+
n,
|
|
1216
|
+
d.slice(-1)[0].route.id,
|
|
1217
|
+
u,
|
|
1218
|
+
l,
|
|
1244
1219
|
p
|
|
1245
1220
|
);
|
|
1246
1221
|
else {
|
|
1247
|
-
let { pathname:
|
|
1248
|
-
e.unstable_getCriticalCss ?
|
|
1249
|
-
|
|
1222
|
+
let { pathname: m } = h, f;
|
|
1223
|
+
e.unstable_getCriticalCss ? f = await e.unstable_getCriticalCss({ pathname: m }) : t === "development" && X()?.getCriticalCss && (f = await X()?.getCriticalCss?.(m)), w = await jt(
|
|
1224
|
+
a,
|
|
1250
1225
|
e,
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1226
|
+
n,
|
|
1227
|
+
u,
|
|
1228
|
+
l,
|
|
1254
1229
|
p,
|
|
1255
|
-
|
|
1256
|
-
|
|
1230
|
+
y,
|
|
1231
|
+
f
|
|
1257
1232
|
);
|
|
1258
1233
|
}
|
|
1259
|
-
return
|
|
1260
|
-
headers:
|
|
1261
|
-
status:
|
|
1262
|
-
statusText:
|
|
1263
|
-
}) :
|
|
1234
|
+
return u.method === "HEAD" ? new Response(null, {
|
|
1235
|
+
headers: w.headers,
|
|
1236
|
+
status: w.status,
|
|
1237
|
+
statusText: w.statusText
|
|
1238
|
+
}) : w;
|
|
1264
1239
|
};
|
|
1265
|
-
return e.entry.module.
|
|
1266
|
-
|
|
1267
|
-
e.entry.module.
|
|
1240
|
+
return e.entry.module.instrumentations && (c = et(
|
|
1241
|
+
c,
|
|
1242
|
+
e.entry.module.instrumentations.map((u) => u.handler).filter(Boolean)
|
|
1268
1243
|
)), {
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
errorHandler: c,
|
|
1274
|
-
requestHandler: u
|
|
1244
|
+
serverMode: a,
|
|
1245
|
+
staticHandler: n,
|
|
1246
|
+
errorHandler: o,
|
|
1247
|
+
requestHandler: c
|
|
1275
1248
|
};
|
|
1276
1249
|
}
|
|
1277
|
-
var
|
|
1278
|
-
let r, a, n, o, c
|
|
1279
|
-
return async function(
|
|
1250
|
+
var dr = (e, t) => {
|
|
1251
|
+
let r, a, n, o, c;
|
|
1252
|
+
return async function(s, i) {
|
|
1280
1253
|
if (r = typeof e == "function" ? await e() : e, typeof e == "function") {
|
|
1281
|
-
let
|
|
1282
|
-
a =
|
|
1283
|
-
} else if (!a || !n || !o || !c
|
|
1284
|
-
let
|
|
1285
|
-
a =
|
|
1254
|
+
let l = we(r, t);
|
|
1255
|
+
a = l.serverMode, n = l.staticHandler, o = l.errorHandler, c = l.requestHandler;
|
|
1256
|
+
} else if (!a || !n || !o || !c) {
|
|
1257
|
+
let l = we(r, t);
|
|
1258
|
+
a = l.serverMode, n = l.staticHandler, o = l.errorHandler, c = l.requestHandler;
|
|
1286
1259
|
}
|
|
1287
|
-
return
|
|
1260
|
+
return c(s, i);
|
|
1288
1261
|
};
|
|
1289
1262
|
};
|
|
1290
|
-
async function
|
|
1291
|
-
if (
|
|
1263
|
+
async function Mt(e, t, r, a) {
|
|
1264
|
+
if (a.toString().length > ct)
|
|
1265
|
+
return new Response(null, {
|
|
1266
|
+
statusText: "Bad Request",
|
|
1267
|
+
status: 400
|
|
1268
|
+
});
|
|
1269
|
+
if (e.assets.version !== a.searchParams.get("version"))
|
|
1292
1270
|
return new Response(null, {
|
|
1293
1271
|
status: 204,
|
|
1294
1272
|
headers: {
|
|
1295
1273
|
"X-Remix-Reload-Document": "true"
|
|
1296
1274
|
}
|
|
1297
1275
|
});
|
|
1298
|
-
let
|
|
1299
|
-
if (
|
|
1300
|
-
let
|
|
1301
|
-
(
|
|
1276
|
+
let n = {};
|
|
1277
|
+
if (a.searchParams.has("paths")) {
|
|
1278
|
+
let o = a.searchParams.get("paths") || "", c = new Set(o.split(",").filter(Boolean));
|
|
1279
|
+
for (let u of c) {
|
|
1302
1280
|
u.startsWith("/") || (u = `/${u}`);
|
|
1303
|
-
let s =
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
let s = Y(t, u, e.basename);
|
|
1281
|
+
let s = Pe(
|
|
1282
|
+
e.routes,
|
|
1283
|
+
t,
|
|
1284
|
+
r,
|
|
1285
|
+
u,
|
|
1286
|
+
e.basename
|
|
1287
|
+
);
|
|
1311
1288
|
if (s)
|
|
1312
1289
|
for (let i of s) {
|
|
1313
|
-
let l = i.route.id,
|
|
1314
|
-
|
|
1290
|
+
let l = i.route.id, p = e.assets.routes[l];
|
|
1291
|
+
p && (n[l] = p);
|
|
1315
1292
|
}
|
|
1316
1293
|
}
|
|
1317
|
-
return Response.json(
|
|
1294
|
+
return Response.json(n, {
|
|
1318
1295
|
headers: {
|
|
1319
1296
|
"Cache-Control": "public, max-age=31536000, immutable"
|
|
1320
1297
|
}
|
|
@@ -1322,9 +1299,9 @@ async function Bt(e, t, r) {
|
|
|
1322
1299
|
}
|
|
1323
1300
|
return new Response("Invalid Request", { status: 400 });
|
|
1324
1301
|
}
|
|
1325
|
-
async function
|
|
1302
|
+
async function $t(e, t, r, a, n, o, c) {
|
|
1326
1303
|
let u = new URL(a.url);
|
|
1327
|
-
return u.pathname = n, a.method
|
|
1304
|
+
return u.pathname = n, _e(a.method) ? await Nt(
|
|
1328
1305
|
t,
|
|
1329
1306
|
e,
|
|
1330
1307
|
r,
|
|
@@ -1342,12 +1319,12 @@ async function Mt(e, t, r, a, n, o, c) {
|
|
|
1342
1319
|
c
|
|
1343
1320
|
);
|
|
1344
1321
|
}
|
|
1345
|
-
async function
|
|
1322
|
+
async function jt(e, t, r, a, n, o, c, u) {
|
|
1346
1323
|
try {
|
|
1347
|
-
if (a.method
|
|
1324
|
+
if (_e(a.method))
|
|
1348
1325
|
try {
|
|
1349
|
-
|
|
1350
|
-
a
|
|
1326
|
+
Ne(
|
|
1327
|
+
a,
|
|
1351
1328
|
Array.isArray(t.allowedActionOrigins) ? t.allowedActionOrigins : []
|
|
1352
1329
|
);
|
|
1353
1330
|
} catch (l) {
|
|
@@ -1357,30 +1334,30 @@ async function $t(e, t, r, a, n, o, c, u) {
|
|
|
1357
1334
|
requestContext: n,
|
|
1358
1335
|
generateMiddlewareResponse: t.future.v8_middleware ? async (l) => {
|
|
1359
1336
|
try {
|
|
1360
|
-
let
|
|
1361
|
-
return
|
|
1362
|
-
} catch (
|
|
1363
|
-
return o(
|
|
1337
|
+
let p = await l(a);
|
|
1338
|
+
return I(p) || (p = await s(p, c)), p;
|
|
1339
|
+
} catch (p) {
|
|
1340
|
+
return o(p), new Response(null, { status: 500 });
|
|
1364
1341
|
}
|
|
1365
1342
|
} : void 0,
|
|
1366
|
-
|
|
1343
|
+
normalizePath: (l) => j(l, t.basename, t.future)
|
|
1367
1344
|
});
|
|
1368
|
-
return
|
|
1345
|
+
return I(i) || (i = await s(i, c)), i;
|
|
1369
1346
|
} catch (i) {
|
|
1370
1347
|
return o(i), new Response(null, { status: 500 });
|
|
1371
1348
|
}
|
|
1372
1349
|
async function s(i, l) {
|
|
1373
|
-
let
|
|
1374
|
-
if (
|
|
1375
|
-
return new Response(null, { status: i.statusCode, headers:
|
|
1376
|
-
i.errors && (Object.values(i.errors).forEach((
|
|
1377
|
-
(!
|
|
1378
|
-
}), i.errors =
|
|
1379
|
-
let
|
|
1350
|
+
let p = se(i, t);
|
|
1351
|
+
if (Oe.has(i.statusCode))
|
|
1352
|
+
return new Response(null, { status: i.statusCode, headers: p });
|
|
1353
|
+
i.errors && (Object.values(i.errors).forEach((d) => {
|
|
1354
|
+
(!N(d) || d.error) && o(d);
|
|
1355
|
+
}), i.errors = W(i.errors, e));
|
|
1356
|
+
let h = {
|
|
1380
1357
|
loaderData: i.loaderData,
|
|
1381
1358
|
actionData: i.actionData,
|
|
1382
|
-
errors:
|
|
1383
|
-
},
|
|
1359
|
+
errors: i.errors
|
|
1360
|
+
}, g = {
|
|
1384
1361
|
basename: t.basename,
|
|
1385
1362
|
future: t.future,
|
|
1386
1363
|
routeDiscovery: t.routeDiscovery,
|
|
@@ -1388,15 +1365,16 @@ async function $t(e, t, r, a, n, o, c, u) {
|
|
|
1388
1365
|
isSpaMode: l
|
|
1389
1366
|
}, y = {
|
|
1390
1367
|
manifest: t.assets,
|
|
1391
|
-
|
|
1368
|
+
branches: r._internalRouteBranches,
|
|
1369
|
+
routeModules: At(t.routes),
|
|
1392
1370
|
staticHandlerContext: i,
|
|
1393
1371
|
criticalCss: u,
|
|
1394
|
-
serverHandoffString:
|
|
1395
|
-
...
|
|
1372
|
+
serverHandoffString: me({
|
|
1373
|
+
...g,
|
|
1396
1374
|
criticalCss: u
|
|
1397
1375
|
}),
|
|
1398
|
-
serverHandoffStream:
|
|
1399
|
-
|
|
1376
|
+
serverHandoffStream: Y(
|
|
1377
|
+
h,
|
|
1400
1378
|
a.signal,
|
|
1401
1379
|
t.entry.module.streamTimeout,
|
|
1402
1380
|
e
|
|
@@ -1406,44 +1384,44 @@ async function $t(e, t, r, a, n, o, c, u) {
|
|
|
1406
1384
|
ssr: t.ssr,
|
|
1407
1385
|
routeDiscovery: t.routeDiscovery,
|
|
1408
1386
|
isSpaMode: l,
|
|
1409
|
-
serializeError: (
|
|
1387
|
+
serializeError: (d) => Fe(d, e)
|
|
1410
1388
|
}, R = t.entry.module.default;
|
|
1411
1389
|
try {
|
|
1412
1390
|
return await R(
|
|
1413
1391
|
a,
|
|
1414
1392
|
i.statusCode,
|
|
1415
|
-
|
|
1393
|
+
p,
|
|
1416
1394
|
y,
|
|
1417
1395
|
n
|
|
1418
1396
|
);
|
|
1419
|
-
} catch (
|
|
1420
|
-
o(
|
|
1421
|
-
let
|
|
1422
|
-
if (
|
|
1397
|
+
} catch (d) {
|
|
1398
|
+
o(d);
|
|
1399
|
+
let w = d;
|
|
1400
|
+
if (I(d))
|
|
1423
1401
|
try {
|
|
1424
|
-
let
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1402
|
+
let f = await Wt(d);
|
|
1403
|
+
w = new q(
|
|
1404
|
+
d.status,
|
|
1405
|
+
d.statusText,
|
|
1406
|
+
f
|
|
1429
1407
|
);
|
|
1430
1408
|
} catch {
|
|
1431
1409
|
}
|
|
1432
|
-
i =
|
|
1410
|
+
i = ht(
|
|
1433
1411
|
r.dataRoutes,
|
|
1434
1412
|
i,
|
|
1435
|
-
|
|
1436
|
-
), i.errors && (i.errors =
|
|
1413
|
+
w
|
|
1414
|
+
), i.errors && (i.errors = W(i.errors, e));
|
|
1437
1415
|
let m = {
|
|
1438
1416
|
loaderData: i.loaderData,
|
|
1439
1417
|
actionData: i.actionData,
|
|
1440
|
-
errors:
|
|
1418
|
+
errors: i.errors
|
|
1441
1419
|
};
|
|
1442
1420
|
y = {
|
|
1443
1421
|
...y,
|
|
1444
1422
|
staticHandlerContext: i,
|
|
1445
|
-
serverHandoffString:
|
|
1446
|
-
serverHandoffStream:
|
|
1423
|
+
serverHandoffString: me(g),
|
|
1424
|
+
serverHandoffStream: Y(
|
|
1447
1425
|
m,
|
|
1448
1426
|
a.signal,
|
|
1449
1427
|
t.entry.module.streamTimeout,
|
|
@@ -1455,12 +1433,12 @@ async function $t(e, t, r, a, n, o, c, u) {
|
|
|
1455
1433
|
return await R(
|
|
1456
1434
|
a,
|
|
1457
1435
|
i.statusCode,
|
|
1458
|
-
|
|
1436
|
+
p,
|
|
1459
1437
|
y,
|
|
1460
1438
|
n
|
|
1461
1439
|
);
|
|
1462
|
-
} catch (
|
|
1463
|
-
return o(
|
|
1440
|
+
} catch (f) {
|
|
1441
|
+
return o(f), V(f, e);
|
|
1464
1442
|
}
|
|
1465
1443
|
}
|
|
1466
1444
|
}
|
|
@@ -1472,26 +1450,26 @@ async function zt(e, t, r, a, n, o, c) {
|
|
|
1472
1450
|
requestContext: o,
|
|
1473
1451
|
generateMiddlewareResponse: t.future.v8_middleware ? async (l) => {
|
|
1474
1452
|
try {
|
|
1475
|
-
let
|
|
1476
|
-
return u(
|
|
1477
|
-
} catch (
|
|
1478
|
-
return s(
|
|
1453
|
+
let p = await l(n);
|
|
1454
|
+
return u(p);
|
|
1455
|
+
} catch (p) {
|
|
1456
|
+
return s(p);
|
|
1479
1457
|
}
|
|
1480
1458
|
} : void 0,
|
|
1481
|
-
|
|
1459
|
+
normalizePath: (l) => j(l, t.basename, t.future)
|
|
1482
1460
|
});
|
|
1483
1461
|
return u(i);
|
|
1484
1462
|
} catch (i) {
|
|
1485
1463
|
return s(i);
|
|
1486
1464
|
}
|
|
1487
1465
|
function u(i) {
|
|
1488
|
-
return
|
|
1466
|
+
return I(i) ? i : typeof i == "string" ? new Response(i) : Response.json(i);
|
|
1489
1467
|
}
|
|
1490
1468
|
function s(i) {
|
|
1491
|
-
if (
|
|
1469
|
+
if (I(i))
|
|
1492
1470
|
return i;
|
|
1493
|
-
if (
|
|
1494
|
-
return c(i),
|
|
1471
|
+
if (N(i))
|
|
1472
|
+
return c(i), qt(i, e);
|
|
1495
1473
|
if (i instanceof Error && i.message === "Expected a response from queryRoute") {
|
|
1496
1474
|
let l = new Error(
|
|
1497
1475
|
"Expected a Response to be returned from resource route handler"
|
|
@@ -1501,7 +1479,7 @@ async function zt(e, t, r, a, n, o, c) {
|
|
|
1501
1479
|
return c(i), V(i, e);
|
|
1502
1480
|
}
|
|
1503
1481
|
}
|
|
1504
|
-
function
|
|
1482
|
+
function qt(e, t) {
|
|
1505
1483
|
return Response.json(
|
|
1506
1484
|
Fe(
|
|
1507
1485
|
// @ts-expect-error This is "private" from users but intended for internal use
|
|
@@ -1525,14 +1503,14 @@ ${String(e)}`), new Response(r, {
|
|
|
1525
1503
|
}
|
|
1526
1504
|
});
|
|
1527
1505
|
}
|
|
1528
|
-
function
|
|
1506
|
+
function Wt(e) {
|
|
1529
1507
|
let t = e.headers.get("Content-Type");
|
|
1530
1508
|
return t && /\bapplication\/json\b/.test(t) ? e.body == null ? null : e.json() : e.text();
|
|
1531
1509
|
}
|
|
1532
1510
|
function J(e) {
|
|
1533
1511
|
return `__flash_${e}__`;
|
|
1534
1512
|
}
|
|
1535
|
-
var
|
|
1513
|
+
var Be = (e = {}, t = "") => {
|
|
1536
1514
|
let r = new Map(Object.entries(e));
|
|
1537
1515
|
return {
|
|
1538
1516
|
get id() {
|
|
@@ -1562,7 +1540,7 @@ var $e = (e = {}, t = "") => {
|
|
|
1562
1540
|
r.delete(a);
|
|
1563
1541
|
}
|
|
1564
1542
|
};
|
|
1565
|
-
},
|
|
1543
|
+
}, cr = (e) => e != null && typeof e.id == "string" && typeof e.data < "u" && typeof e.has == "function" && typeof e.get == "function" && typeof e.set == "function" && typeof e.flash == "function" && typeof e.unset == "function";
|
|
1566
1544
|
function Vt({
|
|
1567
1545
|
cookie: e,
|
|
1568
1546
|
createData: t,
|
|
@@ -1570,11 +1548,11 @@ function Vt({
|
|
|
1570
1548
|
updateData: a,
|
|
1571
1549
|
deleteData: n
|
|
1572
1550
|
}) {
|
|
1573
|
-
let o =
|
|
1574
|
-
return
|
|
1551
|
+
let o = He(e) ? e : Te(e?.name || "__session", e);
|
|
1552
|
+
return Me(o), {
|
|
1575
1553
|
async getSession(c, u) {
|
|
1576
1554
|
let s = c && await o.parse(c, u), i = s && await r(s);
|
|
1577
|
-
return
|
|
1555
|
+
return Be(i || {}, s || "");
|
|
1578
1556
|
},
|
|
1579
1557
|
async commitSession(c, u) {
|
|
1580
1558
|
let { id: s, data: i } = c, l = u?.maxAge != null ? new Date(Date.now() + u.maxAge * 1e3) : u?.expires != null ? u.expires : o.expires;
|
|
@@ -1589,17 +1567,17 @@ function Vt({
|
|
|
1589
1567
|
}
|
|
1590
1568
|
};
|
|
1591
1569
|
}
|
|
1592
|
-
function
|
|
1593
|
-
|
|
1570
|
+
function Me(e) {
|
|
1571
|
+
ke(
|
|
1594
1572
|
e.isSigned,
|
|
1595
1573
|
`The "${e.name}" cookie is not signed, but session cookies should be signed to prevent tampering on the client before they are sent back to the server. See https://reactrouter.com/explanation/sessions-and-cookies#signing-cookies for more information.`
|
|
1596
1574
|
);
|
|
1597
1575
|
}
|
|
1598
|
-
function
|
|
1599
|
-
let t =
|
|
1600
|
-
return
|
|
1576
|
+
function fr({ cookie: e } = {}) {
|
|
1577
|
+
let t = He(e) ? e : Te(e?.name || "__session", e);
|
|
1578
|
+
return Me(t), {
|
|
1601
1579
|
async getSession(r, a) {
|
|
1602
|
-
return
|
|
1580
|
+
return Be(
|
|
1603
1581
|
r && await t.parse(r, a) || {}
|
|
1604
1582
|
);
|
|
1605
1583
|
},
|
|
@@ -1620,7 +1598,7 @@ function cr({ cookie: e } = {}) {
|
|
|
1620
1598
|
}
|
|
1621
1599
|
};
|
|
1622
1600
|
}
|
|
1623
|
-
function
|
|
1601
|
+
function hr({ cookie: e } = {}) {
|
|
1624
1602
|
let t = /* @__PURE__ */ new Map();
|
|
1625
1603
|
return Vt({
|
|
1626
1604
|
cookie: e,
|
|
@@ -1645,8 +1623,8 @@ function fr({ cookie: e } = {}) {
|
|
|
1645
1623
|
}
|
|
1646
1624
|
});
|
|
1647
1625
|
}
|
|
1648
|
-
function
|
|
1649
|
-
let r = t[0], a =
|
|
1626
|
+
function pr(e, ...t) {
|
|
1627
|
+
let r = t[0], a = Xt(e).replace(
|
|
1650
1628
|
/\/:([\w-]+)(\?)?/g,
|
|
1651
1629
|
// same regex as in .\router\utils.ts: compilePath().
|
|
1652
1630
|
(n, o, c) => {
|
|
@@ -1664,37 +1642,37 @@ function hr(e, ...t) {
|
|
|
1664
1642
|
}
|
|
1665
1643
|
return a || "/";
|
|
1666
1644
|
}
|
|
1667
|
-
function
|
|
1645
|
+
function Xt(e) {
|
|
1668
1646
|
let t = e.length - 1, r = e[t];
|
|
1669
1647
|
if (r !== "*" && r !== "/") return e;
|
|
1670
1648
|
for (t--; t >= 0 && e[t] === "/"; t--)
|
|
1671
1649
|
;
|
|
1672
1650
|
return e.slice(0, t + 1);
|
|
1673
1651
|
}
|
|
1674
|
-
var
|
|
1675
|
-
function
|
|
1652
|
+
var Z = new TextEncoder(), ge = "</body></html>";
|
|
1653
|
+
function Re(e) {
|
|
1676
1654
|
let t = new TextDecoder(), r, a = new Promise(
|
|
1677
1655
|
(s) => r = s
|
|
1678
1656
|
), n = !1, o = [], c = null;
|
|
1679
1657
|
function u(s) {
|
|
1680
1658
|
for (let i of o) {
|
|
1681
1659
|
let l = t.decode(i, { stream: !0 });
|
|
1682
|
-
l.endsWith(
|
|
1660
|
+
l.endsWith(ge) && (l = l.slice(0, -ge.length)), s.enqueue(Z.encode(l));
|
|
1683
1661
|
}
|
|
1684
1662
|
o.length = 0, c = null;
|
|
1685
1663
|
}
|
|
1686
1664
|
return new TransformStream({
|
|
1687
1665
|
transform(s, i) {
|
|
1688
1666
|
o.push(s), !c && (c = setTimeout(async () => {
|
|
1689
|
-
u(i), n || (n = !0,
|
|
1667
|
+
u(i), n || (n = !0, Jt(e, i).catch((l) => i.error(l)).then(r));
|
|
1690
1668
|
}, 0));
|
|
1691
1669
|
},
|
|
1692
1670
|
async flush(s) {
|
|
1693
|
-
await a, c && (clearTimeout(c), u(s)), s.enqueue(
|
|
1671
|
+
await a, c && (clearTimeout(c), u(s)), s.enqueue(Z.encode("</body></html>"));
|
|
1694
1672
|
}
|
|
1695
1673
|
});
|
|
1696
1674
|
}
|
|
1697
|
-
async function
|
|
1675
|
+
async function Jt(e, t) {
|
|
1698
1676
|
let r = new TextDecoder("utf-8", { fatal: !0 });
|
|
1699
1677
|
const a = e.getReader();
|
|
1700
1678
|
try {
|
|
@@ -1722,17 +1700,17 @@ async function Xt(e, t) {
|
|
|
1722
1700
|
}
|
|
1723
1701
|
function Q(e, t) {
|
|
1724
1702
|
t.enqueue(
|
|
1725
|
-
|
|
1726
|
-
`<script>${
|
|
1703
|
+
Z.encode(
|
|
1704
|
+
`<script>${Qt(
|
|
1727
1705
|
`(self.__FLIGHT_DATA||=[]).push(${e})`
|
|
1728
1706
|
)}<\/script>`
|
|
1729
1707
|
)
|
|
1730
1708
|
);
|
|
1731
1709
|
}
|
|
1732
|
-
function
|
|
1710
|
+
function Qt(e) {
|
|
1733
1711
|
return e.replace(/<!--/g, "<\\!--").replace(/<\/(script)/gi, "</\\$1");
|
|
1734
1712
|
}
|
|
1735
|
-
var
|
|
1713
|
+
var Kt = class extends D.Component {
|
|
1736
1714
|
constructor(e) {
|
|
1737
1715
|
super(e), this.state = { error: null, location: e.location };
|
|
1738
1716
|
}
|
|
@@ -1743,8 +1721,8 @@ var Qt = class extends A.Component {
|
|
|
1743
1721
|
return t.location !== e.location ? { error: null, location: e.location } : { error: t.error, location: t.location };
|
|
1744
1722
|
}
|
|
1745
1723
|
render() {
|
|
1746
|
-
return this.state.error ? /* @__PURE__ */
|
|
1747
|
-
|
|
1724
|
+
return this.state.error ? /* @__PURE__ */ D.createElement(
|
|
1725
|
+
$e,
|
|
1748
1726
|
{
|
|
1749
1727
|
error: this.state.error,
|
|
1750
1728
|
renderAppShell: !0
|
|
@@ -1757,20 +1735,20 @@ function ve({
|
|
|
1757
1735
|
title: t,
|
|
1758
1736
|
children: r
|
|
1759
1737
|
}) {
|
|
1760
|
-
return e ? /* @__PURE__ */
|
|
1738
|
+
return e ? /* @__PURE__ */ D.createElement("html", { lang: "en" }, /* @__PURE__ */ D.createElement("head", null, /* @__PURE__ */ D.createElement("meta", { charSet: "utf-8" }), /* @__PURE__ */ D.createElement(
|
|
1761
1739
|
"meta",
|
|
1762
1740
|
{
|
|
1763
1741
|
name: "viewport",
|
|
1764
1742
|
content: "width=device-width,initial-scale=1,viewport-fit=cover"
|
|
1765
1743
|
}
|
|
1766
|
-
), /* @__PURE__ */
|
|
1744
|
+
), /* @__PURE__ */ D.createElement("title", null, t)), /* @__PURE__ */ D.createElement("body", null, /* @__PURE__ */ D.createElement("main", { style: { fontFamily: "system-ui, sans-serif", padding: "2rem" } }, r))) : r;
|
|
1767
1745
|
}
|
|
1768
|
-
function
|
|
1746
|
+
function $e({
|
|
1769
1747
|
error: e,
|
|
1770
1748
|
renderAppShell: t
|
|
1771
1749
|
}) {
|
|
1772
1750
|
console.error(e);
|
|
1773
|
-
let r = /* @__PURE__ */
|
|
1751
|
+
let r = /* @__PURE__ */ D.createElement(
|
|
1774
1752
|
"script",
|
|
1775
1753
|
{
|
|
1776
1754
|
dangerouslySetInnerHTML: {
|
|
@@ -1782,14 +1760,14 @@ function je({
|
|
|
1782
1760
|
}
|
|
1783
1761
|
}
|
|
1784
1762
|
);
|
|
1785
|
-
if (
|
|
1786
|
-
return /* @__PURE__ */
|
|
1763
|
+
if (N(e))
|
|
1764
|
+
return /* @__PURE__ */ D.createElement(
|
|
1787
1765
|
ve,
|
|
1788
1766
|
{
|
|
1789
1767
|
renderAppShell: t,
|
|
1790
1768
|
title: "Unhandled Thrown Response!"
|
|
1791
1769
|
},
|
|
1792
|
-
/* @__PURE__ */
|
|
1770
|
+
/* @__PURE__ */ D.createElement("h1", { style: { fontSize: "24px" } }, e.status, " ", e.statusText),
|
|
1793
1771
|
r
|
|
1794
1772
|
);
|
|
1795
1773
|
let a;
|
|
@@ -1799,7 +1777,7 @@ function je({
|
|
|
1799
1777
|
let n = e == null ? "Unknown Error" : typeof e == "object" && "toString" in e ? e.toString() : JSON.stringify(e);
|
|
1800
1778
|
a = new Error(n);
|
|
1801
1779
|
}
|
|
1802
|
-
return /* @__PURE__ */
|
|
1780
|
+
return /* @__PURE__ */ D.createElement(ve, { renderAppShell: t, title: "Application Error!" }, /* @__PURE__ */ D.createElement("h1", { style: { fontSize: "24px" } }, "Application Error"), /* @__PURE__ */ D.createElement(
|
|
1803
1781
|
"pre",
|
|
1804
1782
|
{
|
|
1805
1783
|
style: {
|
|
@@ -1812,42 +1790,42 @@ function je({
|
|
|
1812
1790
|
a.stack
|
|
1813
1791
|
), r);
|
|
1814
1792
|
}
|
|
1815
|
-
function
|
|
1793
|
+
function mr({
|
|
1816
1794
|
hasRootLayout: e
|
|
1817
1795
|
}) {
|
|
1818
|
-
let t =
|
|
1796
|
+
let t = Xe();
|
|
1819
1797
|
if (e === void 0)
|
|
1820
1798
|
throw new Error("Missing 'hasRootLayout' prop");
|
|
1821
|
-
return /* @__PURE__ */
|
|
1822
|
-
|
|
1799
|
+
return /* @__PURE__ */ D.createElement(
|
|
1800
|
+
$e,
|
|
1823
1801
|
{
|
|
1824
1802
|
renderAppShell: !e,
|
|
1825
1803
|
error: t
|
|
1826
1804
|
}
|
|
1827
1805
|
);
|
|
1828
1806
|
}
|
|
1829
|
-
function
|
|
1807
|
+
function Gt(e) {
|
|
1830
1808
|
const t = {};
|
|
1831
1809
|
for (const r of e.matches)
|
|
1832
|
-
|
|
1810
|
+
Yt(t, r);
|
|
1833
1811
|
return t;
|
|
1834
1812
|
}
|
|
1835
|
-
function
|
|
1813
|
+
function Yt(e, t) {
|
|
1836
1814
|
t = Array.isArray(t) ? t : [t];
|
|
1837
1815
|
for (const r of t)
|
|
1838
1816
|
e[r.id] = {
|
|
1839
1817
|
links: r.links,
|
|
1840
1818
|
meta: r.meta,
|
|
1841
|
-
default:
|
|
1819
|
+
default: Zt
|
|
1842
1820
|
};
|
|
1843
1821
|
}
|
|
1844
|
-
var
|
|
1845
|
-
function
|
|
1846
|
-
if (
|
|
1847
|
-
return
|
|
1822
|
+
var Zt = () => null, Se = "/__manifest", er = "use", Ee = _[er];
|
|
1823
|
+
function tr(e) {
|
|
1824
|
+
if (Ee)
|
|
1825
|
+
return Ee(e);
|
|
1848
1826
|
throw new Error("React Router v7 requires React 19+ for RSC features.");
|
|
1849
1827
|
}
|
|
1850
|
-
async function
|
|
1828
|
+
async function yr({
|
|
1851
1829
|
request: e,
|
|
1852
1830
|
serverResponse: t,
|
|
1853
1831
|
createFromReadableStream: r,
|
|
@@ -1855,7 +1833,7 @@ async function mr({
|
|
|
1855
1833
|
hydrate: n = !0
|
|
1856
1834
|
}) {
|
|
1857
1835
|
const o = new URL(e.url);
|
|
1858
|
-
if (
|
|
1836
|
+
if (rr(o) || ar(o) || e.headers.has("rsc-action-id") || t.headers.get("React-Router-Resource") === "true")
|
|
1859
1837
|
return t;
|
|
1860
1838
|
if (!t.body)
|
|
1861
1839
|
throw new Error("Missing body in server response");
|
|
@@ -1863,205 +1841,223 @@ async function mr({
|
|
|
1863
1841
|
let i = null;
|
|
1864
1842
|
n && (i = t.clone());
|
|
1865
1843
|
const l = t.body;
|
|
1866
|
-
let
|
|
1867
|
-
const
|
|
1844
|
+
let p, h = [];
|
|
1845
|
+
const g = () => p ? new ReadableStream({
|
|
1868
1846
|
start(m) {
|
|
1869
|
-
|
|
1847
|
+
p.forEach((f) => m.enqueue(f)), h.push(m);
|
|
1870
1848
|
}
|
|
1871
|
-
}) : (
|
|
1849
|
+
}) : (p = [], l.pipeThrough(
|
|
1872
1850
|
new TransformStream({
|
|
1873
|
-
transform(m,
|
|
1874
|
-
|
|
1851
|
+
transform(m, f) {
|
|
1852
|
+
p.push(m), f.enqueue(m), h.forEach((E) => E.enqueue(m));
|
|
1875
1853
|
},
|
|
1876
1854
|
flush() {
|
|
1877
|
-
|
|
1855
|
+
h.forEach((m) => m.close()), h = [];
|
|
1878
1856
|
}
|
|
1879
1857
|
})
|
|
1880
1858
|
));
|
|
1881
1859
|
let y = null;
|
|
1882
1860
|
const R = () => {
|
|
1883
1861
|
const m = Promise.resolve(
|
|
1884
|
-
r(
|
|
1862
|
+
r(g())
|
|
1885
1863
|
);
|
|
1886
1864
|
return Object.defineProperties(m, {
|
|
1887
1865
|
_deepestRenderedBoundaryId: {
|
|
1888
1866
|
get() {
|
|
1889
1867
|
return y;
|
|
1890
1868
|
},
|
|
1891
|
-
set(
|
|
1892
|
-
y =
|
|
1869
|
+
set(f) {
|
|
1870
|
+
y = f;
|
|
1893
1871
|
}
|
|
1894
1872
|
},
|
|
1895
1873
|
formState: {
|
|
1896
1874
|
get() {
|
|
1897
1875
|
return m.then(
|
|
1898
|
-
(
|
|
1876
|
+
(f) => f.type === "render" ? f.formState : void 0
|
|
1899
1877
|
);
|
|
1900
1878
|
}
|
|
1901
1879
|
}
|
|
1902
1880
|
});
|
|
1903
1881
|
};
|
|
1904
|
-
let
|
|
1882
|
+
let d, w;
|
|
1905
1883
|
try {
|
|
1906
1884
|
if (!s.body)
|
|
1907
1885
|
throw new Error("Failed to clone server response");
|
|
1908
1886
|
const m = await r(
|
|
1909
1887
|
s.body
|
|
1910
1888
|
);
|
|
1911
|
-
if (t.status ===
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1889
|
+
if (t.status === xe && m.type === "redirect") {
|
|
1890
|
+
if (L(m.location))
|
|
1891
|
+
throw new Error("Invalid redirect location");
|
|
1892
|
+
const b = new Headers(t.headers);
|
|
1893
|
+
return b.delete("Content-Encoding"), b.delete("Content-Length"), b.delete("Content-Type"), b.delete("X-Remix-Response"), b.set("Location", m.location), new Response(i?.body || "", {
|
|
1894
|
+
headers: b,
|
|
1915
1895
|
status: m.status,
|
|
1916
1896
|
statusText: t.statusText
|
|
1917
1897
|
});
|
|
1918
1898
|
}
|
|
1919
|
-
let
|
|
1920
|
-
onError(
|
|
1921
|
-
if (typeof
|
|
1922
|
-
if (
|
|
1923
|
-
return
|
|
1924
|
-
let
|
|
1925
|
-
if (
|
|
1926
|
-
return
|
|
1899
|
+
let f = new Headers(), E = t.status, C = t.statusText, v = await a(R, {
|
|
1900
|
+
onError(b) {
|
|
1901
|
+
if (typeof b == "object" && b && "digest" in b && typeof b.digest == "string") {
|
|
1902
|
+
if (d = oe(b.digest), d)
|
|
1903
|
+
return b.digest;
|
|
1904
|
+
let x = ie(b.digest);
|
|
1905
|
+
if (x)
|
|
1906
|
+
return w = x, E = x.status, C = x.statusText, b.digest;
|
|
1927
1907
|
}
|
|
1928
1908
|
},
|
|
1929
|
-
onHeaders(
|
|
1930
|
-
for (const [
|
|
1931
|
-
|
|
1909
|
+
onHeaders(b) {
|
|
1910
|
+
for (const [x, k] of b)
|
|
1911
|
+
f.append(x, k);
|
|
1932
1912
|
}
|
|
1933
1913
|
});
|
|
1934
|
-
const
|
|
1935
|
-
for (const [
|
|
1936
|
-
|
|
1937
|
-
if (
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1914
|
+
const S = new Headers(f);
|
|
1915
|
+
for (const [b, x] of t.headers)
|
|
1916
|
+
S.append(b, x);
|
|
1917
|
+
if (S.set("Content-Type", "text/html; charset=utf-8"), d) {
|
|
1918
|
+
if (L(d.location))
|
|
1919
|
+
throw new Error("Invalid redirect location");
|
|
1920
|
+
return S.set("Location", d.location), new Response(v, {
|
|
1921
|
+
status: d.status,
|
|
1922
|
+
headers: S
|
|
1941
1923
|
});
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1924
|
+
}
|
|
1925
|
+
const A = new TransformStream({
|
|
1926
|
+
flush(b) {
|
|
1927
|
+
if (d) {
|
|
1928
|
+
if (L(d.location))
|
|
1929
|
+
return;
|
|
1930
|
+
b.enqueue(
|
|
1931
|
+
new TextEncoder().encode(
|
|
1932
|
+
`<meta http-equiv="refresh" content="0;url=${G(d.location)}"/>`
|
|
1933
|
+
)
|
|
1934
|
+
);
|
|
1935
|
+
}
|
|
1949
1936
|
}
|
|
1950
1937
|
});
|
|
1951
1938
|
if (!n)
|
|
1952
|
-
return new Response(
|
|
1953
|
-
status:
|
|
1939
|
+
return new Response(v.pipeThrough(A), {
|
|
1940
|
+
status: E,
|
|
1954
1941
|
statusText: C,
|
|
1955
|
-
headers:
|
|
1942
|
+
headers: S
|
|
1956
1943
|
});
|
|
1957
1944
|
if (!i?.body)
|
|
1958
1945
|
throw new Error("Failed to clone server response");
|
|
1959
|
-
const
|
|
1960
|
-
return new Response(
|
|
1961
|
-
status:
|
|
1946
|
+
const H = v.pipeThrough(Re(i.body)).pipeThrough(A);
|
|
1947
|
+
return new Response(H, {
|
|
1948
|
+
status: E,
|
|
1962
1949
|
statusText: C,
|
|
1963
|
-
headers:
|
|
1950
|
+
headers: S
|
|
1964
1951
|
});
|
|
1965
1952
|
} catch (m) {
|
|
1966
1953
|
if (m instanceof Response)
|
|
1967
1954
|
return m;
|
|
1968
|
-
if (
|
|
1969
|
-
|
|
1970
|
-
|
|
1955
|
+
if (d) {
|
|
1956
|
+
if (L(d.location))
|
|
1957
|
+
throw new Error("Invalid redirect location");
|
|
1958
|
+
return new Response(`Redirect: ${d.location}`, {
|
|
1959
|
+
status: d.status,
|
|
1971
1960
|
headers: {
|
|
1972
|
-
Location:
|
|
1961
|
+
Location: d.location
|
|
1973
1962
|
}
|
|
1974
1963
|
});
|
|
1964
|
+
}
|
|
1975
1965
|
try {
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
const v = await a(
|
|
1966
|
+
let f = w ?? m, [E, C] = N(f) ? [f.status, f.statusText] : [500, ""], v, S = new Headers();
|
|
1967
|
+
const A = await a(
|
|
1979
1968
|
() => {
|
|
1980
|
-
const
|
|
1981
|
-
r(
|
|
1969
|
+
const T = Promise.resolve(
|
|
1970
|
+
r(g())
|
|
1982
1971
|
).then(
|
|
1983
|
-
(
|
|
1984
|
-
status:
|
|
1972
|
+
(F) => Object.assign(F, {
|
|
1973
|
+
status: E,
|
|
1985
1974
|
errors: y ? {
|
|
1986
|
-
[y]:
|
|
1975
|
+
[y]: f
|
|
1987
1976
|
} : {}
|
|
1988
1977
|
})
|
|
1989
1978
|
);
|
|
1990
|
-
return Object.defineProperties(
|
|
1979
|
+
return Object.defineProperties(T, {
|
|
1991
1980
|
_deepestRenderedBoundaryId: {
|
|
1992
1981
|
get() {
|
|
1993
1982
|
return y;
|
|
1994
1983
|
},
|
|
1995
|
-
set(
|
|
1996
|
-
y =
|
|
1984
|
+
set(F) {
|
|
1985
|
+
y = F;
|
|
1997
1986
|
}
|
|
1998
1987
|
},
|
|
1999
1988
|
formState: {
|
|
2000
1989
|
get() {
|
|
2001
|
-
return
|
|
2002
|
-
(
|
|
1990
|
+
return T.then(
|
|
1991
|
+
(F) => F.type === "render" ? F.formState : void 0
|
|
2003
1992
|
);
|
|
2004
1993
|
}
|
|
2005
1994
|
}
|
|
2006
1995
|
});
|
|
2007
1996
|
},
|
|
2008
1997
|
{
|
|
2009
|
-
onError(
|
|
2010
|
-
if (typeof
|
|
2011
|
-
if (
|
|
2012
|
-
return
|
|
2013
|
-
let
|
|
2014
|
-
|
|
1998
|
+
onError(k) {
|
|
1999
|
+
if (typeof k == "object" && k && "digest" in k && typeof k.digest == "string") {
|
|
2000
|
+
if (v = oe(k.digest), v)
|
|
2001
|
+
return k.digest;
|
|
2002
|
+
let T = ie(
|
|
2003
|
+
k.digest
|
|
2015
2004
|
);
|
|
2016
|
-
if (
|
|
2017
|
-
return
|
|
2005
|
+
if (T)
|
|
2006
|
+
return E = T.status, C = T.statusText, k.digest;
|
|
2018
2007
|
}
|
|
2019
2008
|
},
|
|
2020
|
-
onHeaders(
|
|
2021
|
-
for (const [
|
|
2022
|
-
|
|
2009
|
+
onHeaders(k) {
|
|
2010
|
+
for (const [T, F] of k)
|
|
2011
|
+
S.append(T, F);
|
|
2023
2012
|
}
|
|
2024
2013
|
}
|
|
2025
|
-
),
|
|
2026
|
-
for (const [
|
|
2027
|
-
|
|
2028
|
-
if (
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2014
|
+
), H = new Headers(S);
|
|
2015
|
+
for (const [k, T] of t.headers)
|
|
2016
|
+
H.append(k, T);
|
|
2017
|
+
if (H.set("Content-Type", "text/html; charset=utf-8"), v) {
|
|
2018
|
+
if (L(v.location))
|
|
2019
|
+
throw new Error("Invalid redirect location");
|
|
2020
|
+
return H.set("Location", v.location), new Response(A, {
|
|
2021
|
+
status: v.status,
|
|
2022
|
+
headers: H
|
|
2032
2023
|
});
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2024
|
+
}
|
|
2025
|
+
const b = new TransformStream({
|
|
2026
|
+
flush(k) {
|
|
2027
|
+
if (v) {
|
|
2028
|
+
if (L(v.location))
|
|
2029
|
+
return;
|
|
2030
|
+
k.enqueue(
|
|
2031
|
+
new TextEncoder().encode(
|
|
2032
|
+
`<meta http-equiv="refresh" content="0;url=${G(v.location)}"/>`
|
|
2033
|
+
)
|
|
2034
|
+
);
|
|
2035
|
+
}
|
|
2040
2036
|
}
|
|
2041
2037
|
});
|
|
2042
2038
|
if (!n)
|
|
2043
|
-
return new Response(
|
|
2044
|
-
status:
|
|
2045
|
-
statusText:
|
|
2046
|
-
headers:
|
|
2039
|
+
return new Response(A.pipeThrough(b), {
|
|
2040
|
+
status: E,
|
|
2041
|
+
statusText: C,
|
|
2042
|
+
headers: H
|
|
2047
2043
|
});
|
|
2048
2044
|
if (!i?.body)
|
|
2049
2045
|
throw new Error("Failed to clone server response");
|
|
2050
|
-
const
|
|
2051
|
-
return new Response(
|
|
2052
|
-
status:
|
|
2053
|
-
statusText:
|
|
2054
|
-
headers:
|
|
2046
|
+
const x = A.pipeThrough(Re(i.body)).pipeThrough(b);
|
|
2047
|
+
return new Response(x, {
|
|
2048
|
+
status: E,
|
|
2049
|
+
statusText: C,
|
|
2050
|
+
headers: H
|
|
2055
2051
|
});
|
|
2056
2052
|
} catch {
|
|
2057
2053
|
}
|
|
2058
2054
|
throw m;
|
|
2059
2055
|
}
|
|
2060
2056
|
}
|
|
2061
|
-
function
|
|
2062
|
-
const t = e(), r =
|
|
2057
|
+
function wr({ getPayload: e }) {
|
|
2058
|
+
const t = e(), r = tr(t);
|
|
2063
2059
|
if (r.type === "redirect")
|
|
2064
|
-
throw new Response(null, {
|
|
2060
|
+
throw L(r.location) ? new Error("Invalid redirect location") : new Response(null, {
|
|
2065
2061
|
status: r.status,
|
|
2066
2062
|
headers: {
|
|
2067
2063
|
Location: r.location
|
|
@@ -2070,7 +2066,7 @@ function yr({ getPayload: e }) {
|
|
|
2070
2066
|
if (r.type !== "render") return null;
|
|
2071
2067
|
let a = { ...r.loaderData };
|
|
2072
2068
|
for (const u of r.matches)
|
|
2073
|
-
|
|
2069
|
+
ee(
|
|
2074
2070
|
u.id,
|
|
2075
2071
|
u.clientLoader,
|
|
2076
2072
|
u.hasLoader,
|
|
@@ -2106,7 +2102,7 @@ function yr({ getPayload: e }) {
|
|
|
2106
2102
|
shouldRevalidate: u.shouldRevalidate
|
|
2107
2103
|
}
|
|
2108
2104
|
}))
|
|
2109
|
-
}, o =
|
|
2105
|
+
}, o = Ce(
|
|
2110
2106
|
r.matches.reduceRight((u, s) => {
|
|
2111
2107
|
const i = {
|
|
2112
2108
|
id: s.id,
|
|
@@ -2129,10 +2125,9 @@ function yr({ getPayload: e }) {
|
|
|
2129
2125
|
// These flags have no runtime impact so can always be false. If we add
|
|
2130
2126
|
// flags that drive runtime behavior they'll need to be proxied through.
|
|
2131
2127
|
v8_middleware: !1,
|
|
2132
|
-
|
|
2133
|
-
unstable_trailingSlashAwareDataRequests: !0,
|
|
2128
|
+
v8_trailingSlashAwareDataRequests: !0,
|
|
2134
2129
|
// always on for RSC
|
|
2135
|
-
|
|
2130
|
+
v8_passThroughRequests: !0
|
|
2136
2131
|
// always on for RSC
|
|
2137
2132
|
},
|
|
2138
2133
|
isSpaMode: !1,
|
|
@@ -2147,14 +2142,14 @@ function yr({ getPayload: e }) {
|
|
|
2147
2142
|
imports: []
|
|
2148
2143
|
}
|
|
2149
2144
|
},
|
|
2150
|
-
routeDiscovery: r.routeDiscovery.mode === "initial" ? { mode: "initial", manifestPath:
|
|
2145
|
+
routeDiscovery: r.routeDiscovery.mode === "initial" ? { mode: "initial", manifestPath: Se } : {
|
|
2151
2146
|
mode: "lazy",
|
|
2152
|
-
manifestPath: r.routeDiscovery.manifestPath ||
|
|
2147
|
+
manifestPath: r.routeDiscovery.manifestPath || Se
|
|
2153
2148
|
},
|
|
2154
|
-
routeModules:
|
|
2149
|
+
routeModules: Gt(r)
|
|
2155
2150
|
};
|
|
2156
|
-
return /* @__PURE__ */
|
|
2157
|
-
|
|
2151
|
+
return /* @__PURE__ */ _.createElement(Ye.Provider, { value: !0 }, /* @__PURE__ */ _.createElement(Kt, { location: r.location }, /* @__PURE__ */ _.createElement(te.Provider, { value: c }, /* @__PURE__ */ _.createElement(
|
|
2152
|
+
be,
|
|
2158
2153
|
{
|
|
2159
2154
|
context: n,
|
|
2160
2155
|
router: o,
|
|
@@ -2163,41 +2158,12 @@ function yr({ getPayload: e }) {
|
|
|
2163
2158
|
}
|
|
2164
2159
|
))));
|
|
2165
2160
|
}
|
|
2166
|
-
function
|
|
2161
|
+
function rr(e) {
|
|
2167
2162
|
return e.pathname.endsWith(".rsc");
|
|
2168
2163
|
}
|
|
2169
|
-
function
|
|
2164
|
+
function ar(e) {
|
|
2170
2165
|
return e.pathname.endsWith(".manifest");
|
|
2171
2166
|
}
|
|
2172
|
-
function wr(e) {
|
|
2173
|
-
if (!e) return null;
|
|
2174
|
-
let t = Object.entries(e), r = {};
|
|
2175
|
-
for (let [a, n] of t)
|
|
2176
|
-
if (n && n.__type === "RouteErrorResponse")
|
|
2177
|
-
r[a] = new O(
|
|
2178
|
-
n.status,
|
|
2179
|
-
n.statusText,
|
|
2180
|
-
n.data,
|
|
2181
|
-
n.internal === !0
|
|
2182
|
-
);
|
|
2183
|
-
else if (n && n.__type === "Error") {
|
|
2184
|
-
if (n.__subType) {
|
|
2185
|
-
let o = window[n.__subType];
|
|
2186
|
-
if (typeof o == "function")
|
|
2187
|
-
try {
|
|
2188
|
-
let c = new o(n.message);
|
|
2189
|
-
c.stack = n.stack, r[a] = c;
|
|
2190
|
-
} catch {
|
|
2191
|
-
}
|
|
2192
|
-
}
|
|
2193
|
-
if (r[a] == null) {
|
|
2194
|
-
let o = new Error(n.message);
|
|
2195
|
-
o.stack = n.stack, r[a] = o;
|
|
2196
|
-
}
|
|
2197
|
-
} else
|
|
2198
|
-
r[a] = n;
|
|
2199
|
-
return r;
|
|
2200
|
-
}
|
|
2201
2167
|
function gr({
|
|
2202
2168
|
state: e,
|
|
2203
2169
|
routes: t,
|
|
@@ -2209,11 +2175,11 @@ function gr({
|
|
|
2209
2175
|
let c = {
|
|
2210
2176
|
...e,
|
|
2211
2177
|
loaderData: { ...e.loaderData }
|
|
2212
|
-
}, u =
|
|
2178
|
+
}, u = Je(t, a, n);
|
|
2213
2179
|
if (u)
|
|
2214
2180
|
for (let s of u) {
|
|
2215
2181
|
let i = s.route.id, l = r(i);
|
|
2216
|
-
|
|
2182
|
+
ee(
|
|
2217
2183
|
i,
|
|
2218
2184
|
l.clientLoader,
|
|
2219
2185
|
l.hasLoader,
|
|
@@ -2223,8 +2189,8 @@ function gr({
|
|
|
2223
2189
|
return c;
|
|
2224
2190
|
}
|
|
2225
2191
|
const Rr = () => {
|
|
2226
|
-
const e =
|
|
2227
|
-
return
|
|
2192
|
+
const e = ze((r) => r.navigateInHortiview);
|
|
2193
|
+
return je(
|
|
2228
2194
|
(r) => e?.(r),
|
|
2229
2195
|
[e]
|
|
2230
2196
|
);
|
|
@@ -2233,42 +2199,42 @@ export {
|
|
|
2233
2199
|
Er as Await,
|
|
2234
2200
|
Cr as BrowserRouter,
|
|
2235
2201
|
br as Form,
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2202
|
+
xr as HashRouter,
|
|
2203
|
+
kr as IDLE_BLOCKER,
|
|
2204
|
+
_r as IDLE_FETCHER,
|
|
2239
2205
|
Ar as IDLE_NAVIGATION,
|
|
2240
2206
|
Dr as Link,
|
|
2241
2207
|
Tr as Links,
|
|
2242
2208
|
Hr as MemoryRouter,
|
|
2243
|
-
|
|
2244
|
-
|
|
2209
|
+
Fr as Meta,
|
|
2210
|
+
Pr as NavLink,
|
|
2245
2211
|
Ur as Navigate,
|
|
2246
2212
|
Lr as NavigationType,
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
|
|
2213
|
+
nt as Outlet,
|
|
2214
|
+
Ir as PrefetchPageLinks,
|
|
2215
|
+
Nr as Route,
|
|
2216
|
+
Or as Router,
|
|
2251
2217
|
K as RouterContextProvider,
|
|
2252
|
-
|
|
2218
|
+
Ge as RouterProvider,
|
|
2253
2219
|
Br as Routes,
|
|
2254
2220
|
Mr as Scripts,
|
|
2255
2221
|
$r as ScrollRestoration,
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2222
|
+
ir as ServerRouter,
|
|
2223
|
+
jr as StaticRouter,
|
|
2224
|
+
be as StaticRouterProvider,
|
|
2225
|
+
zr as UNSAFE_AwaitContextProvider,
|
|
2260
2226
|
qr as UNSAFE_DataRouterContext,
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2227
|
+
Wr as UNSAFE_DataRouterStateContext,
|
|
2228
|
+
q as UNSAFE_ErrorResponseImpl,
|
|
2229
|
+
Vr as UNSAFE_FetchersContext,
|
|
2230
|
+
te as UNSAFE_FrameworkContext,
|
|
2265
2231
|
Xr as UNSAFE_LocationContext,
|
|
2266
2232
|
Jr as UNSAFE_NavigationContext,
|
|
2267
|
-
|
|
2268
|
-
|
|
2233
|
+
mr as UNSAFE_RSCDefaultRootErrorBoundary,
|
|
2234
|
+
We as UNSAFE_RemixErrorBoundary,
|
|
2269
2235
|
Qr as UNSAFE_RouteContext,
|
|
2270
|
-
|
|
2271
|
-
|
|
2236
|
+
Dt as UNSAFE_ServerMode,
|
|
2237
|
+
M as UNSAFE_SingleFetchRedirectSymbol,
|
|
2272
2238
|
Kr as UNSAFE_ViewTransitionContext,
|
|
2273
2239
|
Gr as UNSAFE_WithComponentProps,
|
|
2274
2240
|
Yr as UNSAFE_WithErrorBoundaryProps,
|
|
@@ -2279,84 +2245,84 @@ export {
|
|
|
2279
2245
|
aa as UNSAFE_createHashHistory,
|
|
2280
2246
|
na as UNSAFE_createMemoryHistory,
|
|
2281
2247
|
sa as UNSAFE_createRouter,
|
|
2282
|
-
|
|
2283
|
-
wr as UNSAFE_deserializeErrors,
|
|
2248
|
+
st as UNSAFE_decodeViaTurboStream,
|
|
2284
2249
|
gr as UNSAFE_getHydrationData,
|
|
2285
2250
|
oa as UNSAFE_getPatchRoutesOnNavigationFunction,
|
|
2286
2251
|
ia as UNSAFE_getTurboStreamSingleFetchDataStrategy,
|
|
2287
2252
|
la as UNSAFE_hydrationRouteProperties,
|
|
2288
2253
|
ua as UNSAFE_invariant,
|
|
2289
2254
|
da as UNSAFE_mapRouteProperties,
|
|
2290
|
-
|
|
2255
|
+
ee as UNSAFE_shouldHydrateRouteLoader,
|
|
2291
2256
|
ca as UNSAFE_useFogOFWarDiscovery,
|
|
2292
2257
|
fa as UNSAFE_useScrollRestoration,
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2258
|
+
at as UNSAFE_withComponentProps,
|
|
2259
|
+
tt as UNSAFE_withErrorBoundaryProps,
|
|
2260
|
+
rt as UNSAFE_withHydrateFallbackProps,
|
|
2296
2261
|
ha as createBrowserRouter,
|
|
2297
2262
|
pa as createContext,
|
|
2298
|
-
|
|
2299
|
-
|
|
2263
|
+
Te as createCookie,
|
|
2264
|
+
fr as createCookieSessionStorage,
|
|
2300
2265
|
ma as createHashRouter,
|
|
2301
|
-
|
|
2302
|
-
|
|
2266
|
+
Ke as createMemoryRouter,
|
|
2267
|
+
hr as createMemorySessionStorage,
|
|
2303
2268
|
ya as createPath,
|
|
2304
|
-
|
|
2269
|
+
dr as createRequestHandler,
|
|
2305
2270
|
wa as createRoutesFromChildren,
|
|
2306
2271
|
ga as createRoutesFromElements,
|
|
2307
|
-
|
|
2272
|
+
lr as createRoutesStub,
|
|
2308
2273
|
Ra as createSearchParams,
|
|
2309
|
-
|
|
2274
|
+
Be as createSession,
|
|
2310
2275
|
Vt as createSessionStorage,
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
|
|
2276
|
+
va as createStaticHandler,
|
|
2277
|
+
Ce as createStaticRouter,
|
|
2278
|
+
Sa as data,
|
|
2314
2279
|
Ea as generatePath,
|
|
2315
|
-
|
|
2316
|
-
|
|
2317
|
-
|
|
2318
|
-
|
|
2280
|
+
pr as href,
|
|
2281
|
+
He as isCookie,
|
|
2282
|
+
N as isRouteErrorResponse,
|
|
2283
|
+
cr as isSession,
|
|
2319
2284
|
Ca as matchPath,
|
|
2320
|
-
|
|
2285
|
+
Je as matchRoutes,
|
|
2321
2286
|
ba as parsePath,
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2287
|
+
lt as redirect,
|
|
2288
|
+
ot as redirectDocument,
|
|
2289
|
+
xa as renderMatches,
|
|
2290
|
+
it as replace,
|
|
2291
|
+
ka as resolvePath,
|
|
2292
|
+
_a as unstable_HistoryRouter,
|
|
2293
|
+
wr as unstable_RSCStaticRouter,
|
|
2294
|
+
yr as unstable_routeRSCServerRequest,
|
|
2295
|
+
ur as unstable_setDevServerHooks,
|
|
2331
2296
|
Aa as unstable_usePrompt,
|
|
2332
2297
|
Da as unstable_useRoute,
|
|
2333
|
-
Ta as
|
|
2334
|
-
Ha as
|
|
2298
|
+
Ta as unstable_useRouterState,
|
|
2299
|
+
Ha as useActionData,
|
|
2300
|
+
Fa as useAsyncError,
|
|
2335
2301
|
Pa as useAsyncValue,
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2302
|
+
Ua as useBeforeUnload,
|
|
2303
|
+
La as useBlocker,
|
|
2304
|
+
Ia as useFetcher,
|
|
2339
2305
|
Na as useFetchers,
|
|
2340
2306
|
Oa as useFormAction,
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2307
|
+
Ba as useHref,
|
|
2308
|
+
Ma as useInRouterContext,
|
|
2309
|
+
$a as useLinkClickHandler,
|
|
2310
|
+
ja as useLoaderData,
|
|
2345
2311
|
za as useLocation,
|
|
2346
|
-
|
|
2347
|
-
|
|
2312
|
+
qa as useMatch,
|
|
2313
|
+
Wa as useMatches,
|
|
2348
2314
|
Rr as useNavigate,
|
|
2349
2315
|
Va as useNavigation,
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2316
|
+
Xa as useNavigationType,
|
|
2317
|
+
Ja as useOutlet,
|
|
2318
|
+
Qa as useOutletContext,
|
|
2319
|
+
Ka as useParams,
|
|
2320
|
+
Ga as useResolvedPath,
|
|
2321
|
+
Ya as useRevalidator,
|
|
2322
|
+
Xe as useRouteError,
|
|
2323
|
+
Za as useRouteLoaderData,
|
|
2324
|
+
en as useRoutes,
|
|
2325
|
+
tn as useSearchParams,
|
|
2326
|
+
rn as useSubmit,
|
|
2327
|
+
an as useViewTransitionState
|
|
2362
2328
|
};
|