convex-cms 0.0.8 → 0.0.9-alpha.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/README.md +11 -1
- package/admin/src/components/BulkActionBar.tsx +6 -5
- package/admin/src/components/ContentEntryEditor.tsx +10 -9
- package/admin/src/components/ContentTypeFormModal.tsx +4 -3
- package/admin/src/components/Sidebar.tsx +3 -2
- package/admin/src/components/TaxonomyEditor.tsx +4 -3
- package/admin/src/components/TermTree.tsx +8 -6
- package/admin/src/components/VersionCompare.tsx +3 -2
- package/admin/src/components/VersionHistory.tsx +4 -3
- package/admin/src/components/fields/CategoryField.tsx +3 -2
- package/admin/src/components/fields/MediaField.tsx +6 -5
- package/admin/src/components/fields/ReferenceField.tsx +6 -5
- package/admin/src/components/fields/TagField.tsx +5 -4
- package/admin/src/components/filters/TaxonomyFilter.tsx +4 -3
- package/admin/src/components/media/MediaAssetEditDialog.tsx +4 -3
- package/admin/src/components/media/MediaFolderEditDialog.tsx +3 -2
- package/admin/src/components/media/MediaMoveModal.tsx +4 -3
- package/admin/src/components/media/MediaTaxonomyPicker.tsx +6 -5
- package/admin/src/contexts/SettingsConfigContext.tsx +19 -5
- package/admin/src/embed/contexts/ApiContext.tsx +6 -2
- package/admin/src/routes/__root.tsx +7 -3
- package/admin-dist/nitro.json +1 -1
- package/admin-dist/public/assets/{CmsEmptyState-6-PLaXtD.js → CmsEmptyState-BM4e6N83.js} +1 -1
- package/admin-dist/public/assets/{CmsPageHeader-SoF4Epu9.js → CmsPageHeader-uor3DPIk.js} +1 -1
- package/admin-dist/public/assets/{CmsStatusBadge-D7kYaohx.js → CmsStatusBadge-D8N18LJx.js} +1 -1
- package/admin-dist/public/assets/{CmsSurface-BvksBm6W.js → CmsSurface-BEcY-WpI.js} +1 -1
- package/admin-dist/public/assets/{CmsToolbar-DlZPMe2B.js → CmsToolbar-DE-bu3W8.js} +1 -1
- package/admin-dist/public/assets/ContentEntryEditor-BdkIMCUk.js +4 -0
- package/admin-dist/public/assets/TaxonomyFilter-a1-O9DPs.js +1 -0
- package/admin-dist/public/assets/{_contentTypeId-DTv8UoTp.js → _contentTypeId-XIkYOLyY.js} +1 -1
- package/admin-dist/public/assets/{_entryId-D3lr5Dvy.js → _entryId-DyP15QpI.js} +1 -1
- package/admin-dist/public/assets/{alert-BAHTL6ao.js → alert-DHBQuuib.js} +1 -1
- package/admin-dist/public/assets/{badge-oJv4Eai8.js → badge-BOhWFWzb.js} +1 -1
- package/admin-dist/public/assets/{circle-check-big-3OHxNDhO.js → circle-check-big-DjTNapen.js} +1 -1
- package/admin-dist/public/assets/{command-DwgQs69u.js → command-BIc5_8gL.js} +1 -1
- package/admin-dist/public/assets/content-C3N8Ugra.js +1 -0
- package/admin-dist/public/assets/content-types-D0wh1eUF.js +1 -0
- package/admin-dist/public/assets/{index-DOkgTSx0.js → index-B-g3F_ri.js} +1 -1
- package/admin-dist/public/assets/main-BapBJgQD.js +102 -0
- package/admin-dist/public/assets/media-8uh1MwDi.js +1 -0
- package/admin-dist/public/assets/{new._contentTypeId-VF63rpic.js → new._contentTypeId-S96rFbgY.js} +1 -1
- package/admin-dist/public/assets/{pencil-CX1CiTDD.js → pencil-DgaZav4e.js} +1 -1
- package/admin-dist/public/assets/{refresh-cw-Cm-YOeFI.js → refresh-cw-BBut4hAU.js} +1 -1
- package/admin-dist/public/assets/{rotate-ccw-B45JsL5f.js → rotate-ccw-DVCkojZZ.js} +1 -1
- package/admin-dist/public/assets/{scroll-area-b3A1HHR7.js → scroll-area-DPC4uXzf.js} +1 -1
- package/admin-dist/public/assets/{search-DKKh_DdH.js → search-CSyHHglh.js} +1 -1
- package/admin-dist/public/assets/{settings-CGVDEV1r.js → settings-cEqPsoJ0.js} +1 -1
- package/admin-dist/public/assets/{switch-BTMY8Qnk.js → switch-O2BviO8Q.js} +1 -1
- package/admin-dist/public/assets/{tabs-DUQwUoIb.js → tabs-p1MWhOqY.js} +1 -1
- package/admin-dist/public/assets/{tanstack-adapter-f7AHmQ5L.js → tanstack-adapter-CDrxoPZD.js} +1 -1
- package/admin-dist/public/assets/taxonomies-DJ9UbjXW.js +1 -0
- package/admin-dist/public/assets/{trash-D7e0uKd9.js → trash-RnpP6lXF.js} +1 -1
- package/admin-dist/public/assets/{useBreadcrumbLabel-CF2KYwsw.js → useBreadcrumbLabel-zbIWXlkc.js} +1 -1
- package/admin-dist/public/assets/{usePermissions-DWBImEOW.js → usePermissions-4CTlK-vU.js} +1 -1
- package/admin-dist/server/_chunks/_libs/@floating-ui/core.mjs +71 -65
- package/admin-dist/server/_chunks/_libs/@floating-ui/dom.mjs +1 -1
- package/admin-dist/server/_chunks/_libs/@floating-ui/utils.mjs +8 -8
- package/admin-dist/server/_chunks/_libs/@tanstack/react-router.mjs +12 -30
- package/admin-dist/server/_chunks/_libs/@tanstack/react-store.mjs +1 -56
- package/admin-dist/server/_chunks/_libs/@tanstack/router-core.mjs +130 -114
- package/admin-dist/server/_chunks/_libs/@tanstack/store.mjs +1 -134
- package/admin-dist/server/_chunks/_libs/react-dom.mjs +5 -5
- package/admin-dist/server/_chunks/_libs/react.mjs +1 -1
- package/admin-dist/server/_libs/isbot.mjs +1 -1
- package/admin-dist/server/_libs/use-sync-external-store.mjs +1 -76
- package/admin-dist/server/_ssr/{CmsEmptyState-BM8DghTl.mjs → CmsEmptyState-BA0Lc5xs.mjs} +1 -1
- package/admin-dist/server/_ssr/{CmsPageHeader-BHUmrIWD.mjs → CmsPageHeader-PMyecILZ.mjs} +1 -1
- package/admin-dist/server/_ssr/{CmsStatusBadge-D0Zb0oRl.mjs → CmsStatusBadge-CInuN2bZ.mjs} +2 -2
- package/admin-dist/server/_ssr/{CmsSurface-B2eBr-47.mjs → CmsSurface-CH1PIfcS.mjs} +1 -1
- package/admin-dist/server/_ssr/{CmsToolbar-BCrwg7OL.mjs → CmsToolbar-IuhSA7gR.mjs} +1 -1
- package/admin-dist/server/_ssr/{ContentEntryEditor-Cjfm0uhr.mjs → ContentEntryEditor-Bzhir4fQ.mjs} +38 -31
- package/admin-dist/server/_ssr/{TaxonomyFilter-C4pD0kfM.mjs → TaxonomyFilter-r4izSMBh.mjs} +6 -5
- package/admin-dist/server/_ssr/{_contentTypeId-CiDiX-p7.mjs → _contentTypeId-BWEbjqxY.mjs} +11 -13
- package/admin-dist/server/_ssr/{_entryId-9GxatOkL.mjs → _entryId-B5xoXoJf.mjs} +12 -14
- package/admin-dist/server/_ssr/_tanstack-start-manifest_v-CBTan6ii.mjs +4 -0
- package/admin-dist/server/_ssr/{badge-EI998zba.mjs → badge-DXrjBRqZ.mjs} +1 -1
- package/admin-dist/server/_ssr/{command-BLAWQhUw.mjs → command-Cj90OdCX.mjs} +1 -1
- package/admin-dist/server/_ssr/config.server-BOr7Jxr4.mjs +0 -3
- package/admin-dist/server/_ssr/{content-BHX39L4D.mjs → content-DKRI-YqL.mjs} +14 -15
- package/admin-dist/server/_ssr/{content-types-DCzrBhTH.mjs → content-types-BzgRcS8K.mjs} +7 -9
- package/admin-dist/server/_ssr/{index-DwM_5VNP.mjs → index-BPf6_agY.mjs} +4 -6
- package/admin-dist/server/_ssr/index.mjs +11 -10
- package/admin-dist/server/_ssr/{media-CbzgTRRQ.mjs → media-MpjxOZL8.mjs} +23 -21
- package/admin-dist/server/_ssr/{new._contentTypeId-6Ph-Gtlw.mjs → new._contentTypeId-DSb4qR9j.mjs} +11 -13
- package/admin-dist/server/_ssr/{router-vd1nySeP.mjs → router-Dk9ikPNc.mjs} +61 -47
- package/admin-dist/server/_ssr/{scroll-area--B9snFTJ.mjs → scroll-area-JwVD_6MZ.mjs} +1 -1
- package/admin-dist/server/_ssr/{settings-DlTO2JSj.mjs → settings-KVJNe0GM.mjs} +8 -10
- package/admin-dist/server/_ssr/{switch-C05NgNW0.mjs → switch-DvREvRv4.mjs} +1 -1
- package/admin-dist/server/_ssr/{tabs-DAk2J5xy.mjs → tabs-B0h57pFf.mjs} +1 -1
- package/admin-dist/server/_ssr/{tanstack-adapter-DWbaPByn.mjs → tanstack-adapter-gmM64LnW.mjs} +1 -1
- package/admin-dist/server/_ssr/{taxonomies-B8nqce6u.mjs → taxonomies-BbBNx260.mjs} +17 -16
- package/admin-dist/server/_ssr/{trash-zdlZgpTo.mjs → trash-JAzYGh7A.mjs} +8 -10
- package/admin-dist/server/_ssr/{useBreadcrumbLabel-DpEKyG1h.mjs → useBreadcrumbLabel-BWIujj97.mjs} +1 -1
- package/admin-dist/server/_ssr/{usePermissions-olYRd9S9.mjs → usePermissions-CcLDCSwa.mjs} +1 -1
- package/admin-dist/server/index.mjs +162 -162
- package/dist/cli/commands/init.d.ts.map +1 -1
- package/dist/cli/commands/init.js +18 -29
- package/dist/cli/commands/init.js.map +1 -1
- package/dist/cli/templates/admin.d.ts +4 -3
- package/dist/cli/templates/admin.d.ts.map +1 -1
- package/dist/cli/templates/admin.js +152 -195
- package/dist/cli/templates/admin.js.map +1 -1
- package/dist/cli/templates/cmsClient.d.ts +2 -2
- package/dist/cli/templates/cmsClient.d.ts.map +1 -1
- package/dist/cli/templates/cmsClient.js +58 -27
- package/dist/cli/templates/cmsClient.js.map +1 -1
- package/dist/cli/templates/content.d.ts +10 -0
- package/dist/cli/templates/content.d.ts.map +1 -0
- package/dist/cli/templates/content.js +257 -0
- package/dist/cli/templates/content.js.map +1 -0
- package/dist/cli/templates/index.d.ts +3 -2
- package/dist/cli/templates/index.d.ts.map +1 -1
- package/dist/cli/templates/index.js +3 -2
- package/dist/cli/templates/index.js.map +1 -1
- package/dist/cli/templates/schemas/blog.d.ts +4 -3
- package/dist/cli/templates/schemas/blog.d.ts.map +1 -1
- package/dist/cli/templates/schemas/blog.js +44 -13
- package/dist/cli/templates/schemas/blog.js.map +1 -1
- package/dist/cli/templates/schemas/docs.d.ts +4 -3
- package/dist/cli/templates/schemas/docs.d.ts.map +1 -1
- package/dist/cli/templates/schemas/docs.js +43 -12
- package/dist/cli/templates/schemas/docs.js.map +1 -1
- package/dist/cli/templates/schemas/index.d.ts +6 -4
- package/dist/cli/templates/schemas/index.d.ts.map +1 -1
- package/dist/cli/templates/schemas/index.js +6 -4
- package/dist/cli/templates/schemas/index.js.map +1 -1
- package/dist/cli/templates/schemas/landing.d.ts +4 -3
- package/dist/cli/templates/schemas/landing.d.ts.map +1 -1
- package/dist/cli/templates/schemas/landing.js +62 -15
- package/dist/cli/templates/schemas/landing.js.map +1 -1
- package/dist/cli/utils/fileUtils.d.ts.map +1 -1
- package/dist/cli/utils/fileUtils.js +6 -5
- package/dist/cli/utils/fileUtils.js.map +1 -1
- package/dist/client/admin/index.d.ts +2 -1
- package/dist/client/admin/index.d.ts.map +1 -1
- package/dist/client/admin/index.js.map +1 -1
- package/dist/client/admin/types.d.ts +14 -1
- package/dist/client/admin/types.d.ts.map +1 -1
- package/dist/client/index.d.ts +1 -1
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js.map +1 -1
- package/dist/react/index.d.ts +176 -0
- package/dist/react/index.d.ts.map +1 -1
- package/dist/react/index.js +162 -0
- package/dist/react/index.js.map +1 -1
- package/package.json +1 -1
- package/admin-dist/public/assets/ContentEntryEditor-C6n9xLS9.js +0 -4
- package/admin-dist/public/assets/TaxonomyFilter-CFX1_g8s.js +0 -1
- package/admin-dist/public/assets/content-CKQ4QwW2.js +0 -1
- package/admin-dist/public/assets/content-types-BrttaLpc.js +0 -1
- package/admin-dist/public/assets/main-DV6oxWnU.js +0 -102
- package/admin-dist/public/assets/media-B2i-mCbx.js +0 -1
- package/admin-dist/public/assets/taxonomies-DvMppdiD.js +0 -1
- package/admin-dist/server/_ssr/_tanstack-start-manifest_v-CC7UrHKE.mjs +0 -4
|
@@ -1,9 +1,13 @@
|
|
|
1
|
-
import { b as batch, S as Store } from "./store.mjs";
|
|
2
1
|
import { p as parseHref } from "./history.mjs";
|
|
3
2
|
import { i as invariant } from "../../../_libs/tiny-invariant.mjs";
|
|
4
3
|
import { ReadableStream as ReadableStream$1 } from "node:stream/web";
|
|
5
4
|
import { Readable } from "node:stream";
|
|
6
5
|
const isServer = true;
|
|
6
|
+
function batch(fn) {
|
|
7
|
+
{
|
|
8
|
+
return fn();
|
|
9
|
+
}
|
|
10
|
+
}
|
|
7
11
|
function last(arr) {
|
|
8
12
|
return arr[arr.length - 1];
|
|
9
13
|
}
|
|
@@ -16,56 +20,10 @@ function functionalUpdate(updater, previous) {
|
|
|
16
20
|
}
|
|
17
21
|
return updater;
|
|
18
22
|
}
|
|
19
|
-
const hasOwn = Object.prototype.hasOwnProperty;
|
|
20
|
-
const isEnumerable = Object.prototype.propertyIsEnumerable;
|
|
21
23
|
function replaceEqualDeep(prev, _next, _depth = 0) {
|
|
22
|
-
|
|
23
|
-
return
|
|
24
|
-
}
|
|
25
|
-
if (_depth > 500) return _next;
|
|
26
|
-
const next = _next;
|
|
27
|
-
const array = isPlainArray(prev) && isPlainArray(next);
|
|
28
|
-
if (!array && !(isPlainObject(prev) && isPlainObject(next))) return next;
|
|
29
|
-
const prevItems = array ? prev : getEnumerableOwnKeys(prev);
|
|
30
|
-
if (!prevItems) return next;
|
|
31
|
-
const nextItems = array ? next : getEnumerableOwnKeys(next);
|
|
32
|
-
if (!nextItems) return next;
|
|
33
|
-
const prevSize = prevItems.length;
|
|
34
|
-
const nextSize = nextItems.length;
|
|
35
|
-
const copy = array ? new Array(nextSize) : {};
|
|
36
|
-
let equalItems = 0;
|
|
37
|
-
for (let i = 0; i < nextSize; i++) {
|
|
38
|
-
const key = array ? i : nextItems[i];
|
|
39
|
-
const p = prev[key];
|
|
40
|
-
const n = next[key];
|
|
41
|
-
if (p === n) {
|
|
42
|
-
copy[key] = p;
|
|
43
|
-
if (array ? i < prevSize : hasOwn.call(prev, key)) equalItems++;
|
|
44
|
-
continue;
|
|
45
|
-
}
|
|
46
|
-
if (p === null || n === null || typeof p !== "object" || typeof n !== "object") {
|
|
47
|
-
copy[key] = n;
|
|
48
|
-
continue;
|
|
49
|
-
}
|
|
50
|
-
const v = replaceEqualDeep(p, n, _depth + 1);
|
|
51
|
-
copy[key] = v;
|
|
52
|
-
if (v === p) equalItems++;
|
|
53
|
-
}
|
|
54
|
-
return prevSize === nextSize && equalItems === prevSize ? prev : copy;
|
|
55
|
-
}
|
|
56
|
-
function getEnumerableOwnKeys(o) {
|
|
57
|
-
const names = Object.getOwnPropertyNames(o);
|
|
58
|
-
for (const name of names) {
|
|
59
|
-
if (!isEnumerable.call(o, name)) return false;
|
|
60
|
-
}
|
|
61
|
-
const symbols = Object.getOwnPropertySymbols(o);
|
|
62
|
-
if (symbols.length === 0) return names;
|
|
63
|
-
const keys = names;
|
|
64
|
-
for (const symbol of symbols) {
|
|
65
|
-
if (!isEnumerable.call(o, symbol)) return false;
|
|
66
|
-
keys.push(symbol);
|
|
24
|
+
{
|
|
25
|
+
return _next;
|
|
67
26
|
}
|
|
68
|
-
return keys;
|
|
69
27
|
}
|
|
70
28
|
function isPlainObject(o) {
|
|
71
29
|
if (!hasObjectPrototype(o)) {
|
|
@@ -87,9 +45,6 @@ function isPlainObject(o) {
|
|
|
87
45
|
function hasObjectPrototype(o) {
|
|
88
46
|
return Object.prototype.toString.call(o) === "[object Object]";
|
|
89
47
|
}
|
|
90
|
-
function isPlainArray(value) {
|
|
91
|
-
return Array.isArray(value) && value.length === Object.keys(value).length;
|
|
92
|
-
}
|
|
93
48
|
function deepEqual(a, b, opts) {
|
|
94
49
|
if (a === b) {
|
|
95
50
|
return true;
|
|
@@ -203,6 +158,9 @@ function escapeHtml(str) {
|
|
|
203
158
|
}
|
|
204
159
|
function decodePath(path, decodeIgnore) {
|
|
205
160
|
if (!path) return path;
|
|
161
|
+
if (!/[%\\\x00-\x1f\x7f]/.test(path) && !path.startsWith("//")) {
|
|
162
|
+
return path;
|
|
163
|
+
}
|
|
206
164
|
const re = /%25|%5C/gi;
|
|
207
165
|
let cursor = 0;
|
|
208
166
|
let result = "";
|
|
@@ -217,9 +175,9 @@ function decodePath(path, decodeIgnore) {
|
|
|
217
175
|
}
|
|
218
176
|
return result;
|
|
219
177
|
}
|
|
220
|
-
function
|
|
221
|
-
if (
|
|
222
|
-
return path.replace(
|
|
178
|
+
function encodePathLikeUrl(path) {
|
|
179
|
+
if (!/\s|[^\u0000-\u007F]/.test(path)) return path;
|
|
180
|
+
return path.replace(/\s|[^\u0000-\u007F]/gu, encodeURIComponent);
|
|
223
181
|
}
|
|
224
182
|
function createLRUCache(max) {
|
|
225
183
|
const cache = /* @__PURE__ */ new Map();
|
|
@@ -1221,7 +1179,8 @@ function encodeParam(key, params, decoder) {
|
|
|
1221
1179
|
const value = params[key];
|
|
1222
1180
|
if (typeof value !== "string") return value;
|
|
1223
1181
|
if (key === "_splat") {
|
|
1224
|
-
|
|
1182
|
+
if (/^[a-zA-Z0-9\-._~!/]*$/.test(value)) return value;
|
|
1183
|
+
return value.split("/").map((segment) => encodePathParam(segment, decoder)).join("/");
|
|
1225
1184
|
} else {
|
|
1226
1185
|
return encodePathParam(value, decoder);
|
|
1227
1186
|
}
|
|
@@ -1229,7 +1188,8 @@ function encodeParam(key, params, decoder) {
|
|
|
1229
1188
|
function interpolatePath({
|
|
1230
1189
|
path,
|
|
1231
1190
|
params,
|
|
1232
|
-
decoder
|
|
1191
|
+
decoder,
|
|
1192
|
+
server
|
|
1233
1193
|
}) {
|
|
1234
1194
|
let isMissingParams = false;
|
|
1235
1195
|
const usedParams = {};
|
|
@@ -1237,6 +1197,49 @@ function interpolatePath({
|
|
|
1237
1197
|
return { interpolatedPath: "/", usedParams, isMissingParams };
|
|
1238
1198
|
if (!path.includes("$"))
|
|
1239
1199
|
return { interpolatedPath: path, usedParams, isMissingParams };
|
|
1200
|
+
{
|
|
1201
|
+
if (path.indexOf("{") === -1) {
|
|
1202
|
+
const length2 = path.length;
|
|
1203
|
+
let cursor2 = 0;
|
|
1204
|
+
let joined2 = "";
|
|
1205
|
+
while (cursor2 < length2) {
|
|
1206
|
+
while (cursor2 < length2 && path.charCodeAt(cursor2) === 47) cursor2++;
|
|
1207
|
+
if (cursor2 >= length2) break;
|
|
1208
|
+
const start = cursor2;
|
|
1209
|
+
let end = path.indexOf("/", cursor2);
|
|
1210
|
+
if (end === -1) end = length2;
|
|
1211
|
+
cursor2 = end;
|
|
1212
|
+
const part = path.substring(start, end);
|
|
1213
|
+
if (!part) continue;
|
|
1214
|
+
if (part.charCodeAt(0) === 36) {
|
|
1215
|
+
if (part.length === 1) {
|
|
1216
|
+
const splat = params._splat;
|
|
1217
|
+
usedParams._splat = splat;
|
|
1218
|
+
usedParams["*"] = splat;
|
|
1219
|
+
if (!splat) {
|
|
1220
|
+
isMissingParams = true;
|
|
1221
|
+
continue;
|
|
1222
|
+
}
|
|
1223
|
+
const value = encodeParam("_splat", params, decoder);
|
|
1224
|
+
joined2 += "/" + value;
|
|
1225
|
+
} else {
|
|
1226
|
+
const key = part.substring(1);
|
|
1227
|
+
if (!isMissingParams && !(key in params)) {
|
|
1228
|
+
isMissingParams = true;
|
|
1229
|
+
}
|
|
1230
|
+
usedParams[key] = params[key];
|
|
1231
|
+
const value = encodeParam(key, params, decoder) ?? "undefined";
|
|
1232
|
+
joined2 += "/" + value;
|
|
1233
|
+
}
|
|
1234
|
+
} else {
|
|
1235
|
+
joined2 += "/" + part;
|
|
1236
|
+
}
|
|
1237
|
+
}
|
|
1238
|
+
if (path.endsWith("/")) joined2 += "/";
|
|
1239
|
+
const interpolatedPath2 = joined2 || "/";
|
|
1240
|
+
return { usedParams, interpolatedPath: interpolatedPath2, isMissingParams };
|
|
1241
|
+
}
|
|
1242
|
+
}
|
|
1240
1243
|
const length = path.length;
|
|
1241
1244
|
let cursor = 0;
|
|
1242
1245
|
let segment;
|
|
@@ -1401,15 +1404,6 @@ function restoreScroll({
|
|
|
1401
1404
|
}
|
|
1402
1405
|
}
|
|
1403
1406
|
}
|
|
1404
|
-
function setupScrollRestoration(router, force) {
|
|
1405
|
-
const shouldScrollRestoration = router.options.scrollRestoration ?? false;
|
|
1406
|
-
if (shouldScrollRestoration) {
|
|
1407
|
-
router.isScrollRestoring = true;
|
|
1408
|
-
}
|
|
1409
|
-
{
|
|
1410
|
-
return;
|
|
1411
|
-
}
|
|
1412
|
-
}
|
|
1413
1407
|
function encode(obj, stringify = String) {
|
|
1414
1408
|
const result = new URLSearchParams();
|
|
1415
1409
|
for (const key in obj) {
|
|
@@ -1489,12 +1483,12 @@ function stringifySearchWith(stringify, parser) {
|
|
|
1489
1483
|
const rootRouteId = "__root__";
|
|
1490
1484
|
function redirect(opts) {
|
|
1491
1485
|
opts.statusCode = opts.statusCode || opts.code || 307;
|
|
1492
|
-
if (typeof opts.href === "string" && isDangerousProtocol(opts.href)) {
|
|
1486
|
+
if (!opts._builtLocation && typeof opts.href === "string" && isDangerousProtocol(opts.href)) {
|
|
1493
1487
|
throw new Error(
|
|
1494
1488
|
`Redirect blocked: unsafe protocol in href "${opts.href}". Only ${SAFE_URL_PROTOCOLS.join(", ")} protocols are allowed.`
|
|
1495
1489
|
);
|
|
1496
1490
|
}
|
|
1497
|
-
if (!opts.reloadDocument && typeof opts.href === "string") {
|
|
1491
|
+
if (!opts._builtLocation && !opts.reloadDocument && typeof opts.href === "string") {
|
|
1498
1492
|
try {
|
|
1499
1493
|
new URL(opts.href);
|
|
1500
1494
|
opts.reloadDocument = true;
|
|
@@ -1725,9 +1719,6 @@ const executeBeforeLoad = (inner, matchId, index, route) => {
|
|
|
1725
1719
|
}
|
|
1726
1720
|
setupPendingTimeout(inner, matchId, route, match);
|
|
1727
1721
|
const abortController = new AbortController();
|
|
1728
|
-
const parentMatchId = inner.matches[index - 1]?.id;
|
|
1729
|
-
const parentMatch = parentMatchId ? inner.router.getMatch(parentMatchId) : void 0;
|
|
1730
|
-
parentMatch?.context ?? inner.router.options.context ?? void 0;
|
|
1731
1722
|
let isPending = false;
|
|
1732
1723
|
const pending = () => {
|
|
1733
1724
|
if (isPending) return;
|
|
@@ -2238,6 +2229,15 @@ function getLocationChangeInfo(routerState) {
|
|
|
2238
2229
|
const hashChanged = fromLocation?.hash !== toLocation.hash;
|
|
2239
2230
|
return { fromLocation, toLocation, pathChanged, hrefChanged, hashChanged };
|
|
2240
2231
|
}
|
|
2232
|
+
function createServerStore(initialState) {
|
|
2233
|
+
const store = {
|
|
2234
|
+
state: initialState,
|
|
2235
|
+
setState: (updater) => {
|
|
2236
|
+
store.state = updater(store.state);
|
|
2237
|
+
}
|
|
2238
|
+
};
|
|
2239
|
+
return store;
|
|
2240
|
+
}
|
|
2241
2241
|
class RouterCore {
|
|
2242
2242
|
/**
|
|
2243
2243
|
* @deprecated Use the `createRouter` function instead
|
|
@@ -2308,17 +2308,11 @@ class RouterCore {
|
|
|
2308
2308
|
this.setRoutes(processRouteTreeResult);
|
|
2309
2309
|
}
|
|
2310
2310
|
if (!this.__store && this.latestLocation) {
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
this.
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
(d) => !["redirected"].includes(d.status)
|
|
2317
|
-
)
|
|
2318
|
-
};
|
|
2319
|
-
}
|
|
2320
|
-
});
|
|
2321
|
-
setupScrollRestoration(this);
|
|
2311
|
+
{
|
|
2312
|
+
this.__store = createServerStore(
|
|
2313
|
+
getInitialRouterState(this.latestLocation)
|
|
2314
|
+
);
|
|
2315
|
+
}
|
|
2322
2316
|
}
|
|
2323
2317
|
let needsLocationUpdate = false;
|
|
2324
2318
|
const nextBasepath = this.options.basepath ?? "/";
|
|
@@ -2397,9 +2391,29 @@ class RouterCore {
|
|
|
2397
2391
|
};
|
|
2398
2392
|
this.parseLocation = (locationToParse, previousLocation) => {
|
|
2399
2393
|
const parse = ({
|
|
2394
|
+
pathname,
|
|
2395
|
+
search,
|
|
2396
|
+
hash,
|
|
2400
2397
|
href,
|
|
2401
2398
|
state
|
|
2402
2399
|
}) => {
|
|
2400
|
+
if (!this.rewrite && !/[ \x00-\x1f\x7f\u0080-\uffff]/.test(pathname)) {
|
|
2401
|
+
const parsedSearch2 = this.options.parseSearch(search);
|
|
2402
|
+
const searchStr2 = this.options.stringifySearch(parsedSearch2);
|
|
2403
|
+
return {
|
|
2404
|
+
href: pathname + searchStr2 + hash,
|
|
2405
|
+
publicHref: href,
|
|
2406
|
+
pathname: decodePath(pathname),
|
|
2407
|
+
external: false,
|
|
2408
|
+
searchStr: searchStr2,
|
|
2409
|
+
search: replaceEqualDeep(
|
|
2410
|
+
previousLocation?.search,
|
|
2411
|
+
parsedSearch2
|
|
2412
|
+
),
|
|
2413
|
+
hash: decodePath(hash.slice(1)),
|
|
2414
|
+
state: replaceEqualDeep(previousLocation?.state, state)
|
|
2415
|
+
};
|
|
2416
|
+
}
|
|
2403
2417
|
const fullUrl = new URL(href, this.origin);
|
|
2404
2418
|
const url = executeRewriteInput(this.rewrite, fullUrl);
|
|
2405
2419
|
const parsedSearch = this.options.parseSearch(url.search);
|
|
@@ -2413,7 +2427,7 @@ class RouterCore {
|
|
|
2413
2427
|
external: !!this.rewrite && url.origin !== this.origin,
|
|
2414
2428
|
searchStr,
|
|
2415
2429
|
search: replaceEqualDeep(previousLocation?.search, parsedSearch),
|
|
2416
|
-
hash: decodePath(url.hash.
|
|
2430
|
+
hash: decodePath(url.hash.slice(1)),
|
|
2417
2431
|
state: replaceEqualDeep(previousLocation?.state, state)
|
|
2418
2432
|
};
|
|
2419
2433
|
};
|
|
@@ -2498,25 +2512,22 @@ class RouterCore {
|
|
|
2498
2512
|
);
|
|
2499
2513
|
const interpolatedNextTo = interpolatePath({
|
|
2500
2514
|
path: nextTo,
|
|
2501
|
-
params: nextParams
|
|
2515
|
+
params: nextParams,
|
|
2516
|
+
decoder: this.pathParamsDecoder,
|
|
2517
|
+
server: this.isServer
|
|
2502
2518
|
}).interpolatedPath;
|
|
2503
2519
|
const destMatchResult = this.getMatchedRoutes(interpolatedNextTo);
|
|
2504
2520
|
let destRoutes = destMatchResult.matchedRoutes;
|
|
2505
2521
|
const isGlobalNotFound = destMatchResult.foundRoute ? destMatchResult.foundRoute.path !== "/" && destMatchResult.routeParams["**"] : trimPathRight(interpolatedNextTo);
|
|
2506
|
-
if (isGlobalNotFound) {
|
|
2507
|
-
|
|
2508
|
-
destRoutes = [...destRoutes, this.options.notFoundRoute];
|
|
2509
|
-
} else {
|
|
2510
|
-
findGlobalNotFoundRouteId(
|
|
2511
|
-
this.options.notFoundMode,
|
|
2512
|
-
destRoutes
|
|
2513
|
-
);
|
|
2514
|
-
}
|
|
2522
|
+
if (isGlobalNotFound && this.options.notFoundRoute) {
|
|
2523
|
+
destRoutes = [...destRoutes, this.options.notFoundRoute];
|
|
2515
2524
|
}
|
|
2525
|
+
let changedParams = false;
|
|
2516
2526
|
if (Object.keys(nextParams).length > 0) {
|
|
2517
2527
|
for (const route of destRoutes) {
|
|
2518
2528
|
const fn = route.options.params?.stringify ?? route.options.stringifyParams;
|
|
2519
2529
|
if (fn) {
|
|
2530
|
+
changedParams = true;
|
|
2520
2531
|
Object.assign(nextParams, fn(nextParams));
|
|
2521
2532
|
}
|
|
2522
2533
|
}
|
|
@@ -2526,10 +2537,11 @@ class RouterCore {
|
|
|
2526
2537
|
// This preserves the original parameter syntax including optional parameters
|
|
2527
2538
|
nextTo
|
|
2528
2539
|
) : decodePath(
|
|
2529
|
-
interpolatePath({
|
|
2540
|
+
!changedParams ? interpolatedNextTo : interpolatePath({
|
|
2530
2541
|
path: nextTo,
|
|
2531
2542
|
params: nextParams,
|
|
2532
|
-
decoder: this.pathParamsDecoder
|
|
2543
|
+
decoder: this.pathParamsDecoder,
|
|
2544
|
+
server: this.isServer
|
|
2533
2545
|
}).interpolatedPath
|
|
2534
2546
|
);
|
|
2535
2547
|
let nextSearch = fromSearch;
|
|
@@ -2578,7 +2590,7 @@ class RouterCore {
|
|
|
2578
2590
|
publicHref = rewrittenUrl.pathname + rewrittenUrl.search + rewrittenUrl.hash;
|
|
2579
2591
|
}
|
|
2580
2592
|
} else {
|
|
2581
|
-
href =
|
|
2593
|
+
href = encodePathLikeUrl(fullPath);
|
|
2582
2594
|
publicHref = href;
|
|
2583
2595
|
}
|
|
2584
2596
|
return {
|
|
@@ -2821,7 +2833,11 @@ class RouterCore {
|
|
|
2821
2833
|
});
|
|
2822
2834
|
if (this.latestLocation.publicHref !== nextLocation.publicHref) {
|
|
2823
2835
|
const href = this.getParsedLocationHref(nextLocation);
|
|
2824
|
-
|
|
2836
|
+
if (nextLocation.external) {
|
|
2837
|
+
throw redirect({ href });
|
|
2838
|
+
} else {
|
|
2839
|
+
throw redirect({ href, _builtLocation: nextLocation });
|
|
2840
|
+
}
|
|
2825
2841
|
}
|
|
2826
2842
|
}
|
|
2827
2843
|
const pendingMatches = this.matchRoutes(this.latestLocation);
|
|
@@ -2967,7 +2983,7 @@ class RouterCore {
|
|
|
2967
2983
|
};
|
|
2968
2984
|
this.startViewTransition = (fn) => {
|
|
2969
2985
|
const shouldViewTransition = this.shouldViewTransition ?? this.options.defaultViewTransition;
|
|
2970
|
-
|
|
2986
|
+
this.shouldViewTransition = void 0;
|
|
2971
2987
|
if (shouldViewTransition && typeof document !== "undefined" && "startViewTransition" in document && typeof document.startViewTransition === "function") {
|
|
2972
2988
|
let startViewTransitionParams;
|
|
2973
2989
|
if (typeof shouldViewTransition === "object" && this.isViewTransitionTypesSupported) {
|
|
@@ -3037,8 +3053,8 @@ class RouterCore {
|
|
|
3037
3053
|
};
|
|
3038
3054
|
this.resolveRedirect = (redirect2) => {
|
|
3039
3055
|
const locationHeader = redirect2.headers.get("Location");
|
|
3040
|
-
if (!redirect2.options.href) {
|
|
3041
|
-
const location = this.buildLocation(redirect2.options);
|
|
3056
|
+
if (!redirect2.options.href || redirect2.options._builtLocation) {
|
|
3057
|
+
const location = redirect2.options._builtLocation ?? this.buildLocation(redirect2.options);
|
|
3042
3058
|
const href = this.getParsedLocationHref(location);
|
|
3043
3059
|
redirect2.options.href = href;
|
|
3044
3060
|
redirect2.headers.set("Location", href);
|
|
@@ -3294,7 +3310,8 @@ class RouterCore {
|
|
|
3294
3310
|
const { interpolatedPath, usedParams } = interpolatePath({
|
|
3295
3311
|
path: route.fullPath,
|
|
3296
3312
|
params: routeParams,
|
|
3297
|
-
decoder: this.pathParamsDecoder
|
|
3313
|
+
decoder: this.pathParamsDecoder,
|
|
3314
|
+
server: this.isServer
|
|
3298
3315
|
});
|
|
3299
3316
|
const matchId = (
|
|
3300
3317
|
// route.id for disambiguation
|
|
@@ -4063,23 +4080,22 @@ function transformStreamWithRouter(router, appStream, opts) {
|
|
|
4063
4080
|
export {
|
|
4064
4081
|
BaseRootRoute as B,
|
|
4065
4082
|
RouterCore as R,
|
|
4066
|
-
|
|
4067
|
-
|
|
4068
|
-
|
|
4083
|
+
rootRouteId as a,
|
|
4084
|
+
isRedirect as b,
|
|
4085
|
+
transformPipeableStreamWithRouter as c,
|
|
4069
4086
|
defaultGetScrollRestorationKey as d,
|
|
4070
4087
|
escapeHtml as e,
|
|
4071
|
-
|
|
4088
|
+
isDangerousProtocol as f,
|
|
4072
4089
|
getLocationChangeInfo as g,
|
|
4073
|
-
|
|
4090
|
+
exactPathTest as h,
|
|
4074
4091
|
isNotFound as i,
|
|
4075
|
-
|
|
4076
|
-
|
|
4077
|
-
|
|
4078
|
-
|
|
4079
|
-
|
|
4080
|
-
|
|
4081
|
-
|
|
4082
|
-
replaceEqualDeep as r,
|
|
4092
|
+
removeTrailingSlash as j,
|
|
4093
|
+
deepEqual as k,
|
|
4094
|
+
functionalUpdate as l,
|
|
4095
|
+
BaseRoute as m,
|
|
4096
|
+
isModuleNotFoundError as n,
|
|
4097
|
+
defineHandlerCallback as o,
|
|
4098
|
+
restoreScroll as r,
|
|
4083
4099
|
storageKey as s,
|
|
4084
4100
|
transformReadableStreamWithRouter as t
|
|
4085
4101
|
};
|
|
@@ -1,134 +1 @@
|
|
|
1
|
-
|
|
2
|
-
const __derivedToStore = /* @__PURE__ */ new WeakMap();
|
|
3
|
-
const __depsThatHaveWrittenThisTick = {
|
|
4
|
-
current: []
|
|
5
|
-
};
|
|
6
|
-
let __isFlushing = false;
|
|
7
|
-
let __batchDepth = 0;
|
|
8
|
-
const __pendingUpdates = /* @__PURE__ */ new Set();
|
|
9
|
-
const __initialBatchValues = /* @__PURE__ */ new Map();
|
|
10
|
-
function __flush_internals(relatedVals) {
|
|
11
|
-
for (const derived of relatedVals) {
|
|
12
|
-
if (__depsThatHaveWrittenThisTick.current.includes(derived)) {
|
|
13
|
-
continue;
|
|
14
|
-
}
|
|
15
|
-
__depsThatHaveWrittenThisTick.current.push(derived);
|
|
16
|
-
derived.recompute();
|
|
17
|
-
const stores = __derivedToStore.get(derived);
|
|
18
|
-
if (stores) {
|
|
19
|
-
for (const store of stores) {
|
|
20
|
-
const relatedLinkedDerivedVals = __storeToDerived.get(store);
|
|
21
|
-
if (!(relatedLinkedDerivedVals == null ? void 0 : relatedLinkedDerivedVals.length)) continue;
|
|
22
|
-
__flush_internals(relatedLinkedDerivedVals);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
function __notifyListeners(store) {
|
|
28
|
-
const value = {
|
|
29
|
-
prevVal: store.prevState,
|
|
30
|
-
currentVal: store.state
|
|
31
|
-
};
|
|
32
|
-
for (const listener of store.listeners) {
|
|
33
|
-
listener(value);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
function __notifyDerivedListeners(derived) {
|
|
37
|
-
const value = {
|
|
38
|
-
prevVal: derived.prevState,
|
|
39
|
-
currentVal: derived.state
|
|
40
|
-
};
|
|
41
|
-
for (const listener of derived.listeners) {
|
|
42
|
-
listener(value);
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
function __flush(store) {
|
|
46
|
-
if (__batchDepth > 0 && !__initialBatchValues.has(store)) {
|
|
47
|
-
__initialBatchValues.set(store, store.prevState);
|
|
48
|
-
}
|
|
49
|
-
__pendingUpdates.add(store);
|
|
50
|
-
if (__batchDepth > 0) return;
|
|
51
|
-
if (__isFlushing) return;
|
|
52
|
-
try {
|
|
53
|
-
__isFlushing = true;
|
|
54
|
-
while (__pendingUpdates.size > 0) {
|
|
55
|
-
const stores = Array.from(__pendingUpdates);
|
|
56
|
-
__pendingUpdates.clear();
|
|
57
|
-
for (const store2 of stores) {
|
|
58
|
-
const prevState = __initialBatchValues.get(store2) ?? store2.prevState;
|
|
59
|
-
store2.prevState = prevState;
|
|
60
|
-
__notifyListeners(store2);
|
|
61
|
-
}
|
|
62
|
-
for (const store2 of stores) {
|
|
63
|
-
const derivedVals = __storeToDerived.get(store2);
|
|
64
|
-
if (!derivedVals) continue;
|
|
65
|
-
__depsThatHaveWrittenThisTick.current.push(store2);
|
|
66
|
-
__flush_internals(derivedVals);
|
|
67
|
-
}
|
|
68
|
-
for (const store2 of stores) {
|
|
69
|
-
const derivedVals = __storeToDerived.get(store2);
|
|
70
|
-
if (!derivedVals) continue;
|
|
71
|
-
for (const derived of derivedVals) {
|
|
72
|
-
__notifyDerivedListeners(derived);
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
} finally {
|
|
77
|
-
__isFlushing = false;
|
|
78
|
-
__depsThatHaveWrittenThisTick.current = [];
|
|
79
|
-
__initialBatchValues.clear();
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
function batch(fn) {
|
|
83
|
-
__batchDepth++;
|
|
84
|
-
try {
|
|
85
|
-
fn();
|
|
86
|
-
} finally {
|
|
87
|
-
__batchDepth--;
|
|
88
|
-
if (__batchDepth === 0) {
|
|
89
|
-
const pendingUpdateToFlush = __pendingUpdates.values().next().value;
|
|
90
|
-
if (pendingUpdateToFlush) {
|
|
91
|
-
__flush(pendingUpdateToFlush);
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
function isUpdaterFunction(updater) {
|
|
97
|
-
return typeof updater === "function";
|
|
98
|
-
}
|
|
99
|
-
class Store {
|
|
100
|
-
constructor(initialState, options) {
|
|
101
|
-
this.listeners = /* @__PURE__ */ new Set();
|
|
102
|
-
this.subscribe = (listener) => {
|
|
103
|
-
var _a, _b;
|
|
104
|
-
this.listeners.add(listener);
|
|
105
|
-
const unsub = (_b = (_a = this.options) == null ? void 0 : _a.onSubscribe) == null ? void 0 : _b.call(_a, listener, this);
|
|
106
|
-
return () => {
|
|
107
|
-
this.listeners.delete(listener);
|
|
108
|
-
unsub == null ? void 0 : unsub();
|
|
109
|
-
};
|
|
110
|
-
};
|
|
111
|
-
this.prevState = initialState;
|
|
112
|
-
this.state = initialState;
|
|
113
|
-
this.options = options;
|
|
114
|
-
}
|
|
115
|
-
setState(updater) {
|
|
116
|
-
var _a, _b, _c;
|
|
117
|
-
this.prevState = this.state;
|
|
118
|
-
if ((_a = this.options) == null ? void 0 : _a.updateFn) {
|
|
119
|
-
this.state = this.options.updateFn(this.prevState)(updater);
|
|
120
|
-
} else {
|
|
121
|
-
if (isUpdaterFunction(updater)) {
|
|
122
|
-
this.state = updater(this.prevState);
|
|
123
|
-
} else {
|
|
124
|
-
this.state = updater;
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
(_c = (_b = this.options) == null ? void 0 : _b.onUpdate) == null ? void 0 : _c.call(_b);
|
|
128
|
-
__flush(this);
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
export {
|
|
132
|
-
Store as S,
|
|
133
|
-
batch as b
|
|
134
|
-
};
|
|
1
|
+
|
|
@@ -151,7 +151,7 @@ function requireReactDom_production() {
|
|
|
151
151
|
reactDom_production.useFormStatus = function() {
|
|
152
152
|
return ReactSharedInternals.H.useHostTransitionStatus();
|
|
153
153
|
};
|
|
154
|
-
reactDom_production.version = "19.2.
|
|
154
|
+
reactDom_production.version = "19.2.4";
|
|
155
155
|
return reactDom_production;
|
|
156
156
|
}
|
|
157
157
|
var hasRequiredReactDom;
|
|
@@ -5050,7 +5050,7 @@ function requireReactDomServerLegacy_node_production() {
|
|
|
5050
5050
|
'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToPipeableStream" which supports Suspense on the server'
|
|
5051
5051
|
);
|
|
5052
5052
|
};
|
|
5053
|
-
reactDomServerLegacy_node_production.version = "19.2.
|
|
5053
|
+
reactDomServerLegacy_node_production.version = "19.2.4";
|
|
5054
5054
|
return reactDomServerLegacy_node_production;
|
|
5055
5055
|
}
|
|
5056
5056
|
var reactDomServer_node_production = {};
|
|
@@ -10224,9 +10224,9 @@ function requireReactDomServer_node_production() {
|
|
|
10224
10224
|
}
|
|
10225
10225
|
function ensureCorrectIsomorphicReactVersion() {
|
|
10226
10226
|
var isomorphicReactPackageVersion = React.version;
|
|
10227
|
-
if ("19.2.
|
|
10227
|
+
if ("19.2.4" !== isomorphicReactPackageVersion)
|
|
10228
10228
|
throw Error(
|
|
10229
|
-
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' + (isomorphicReactPackageVersion + "\n - react-dom: 19.2.
|
|
10229
|
+
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' + (isomorphicReactPackageVersion + "\n - react-dom: 19.2.4\nLearn more: https://react.dev/warnings/version-mismatch")
|
|
10230
10230
|
);
|
|
10231
10231
|
}
|
|
10232
10232
|
ensureCorrectIsomorphicReactVersion();
|
|
@@ -10749,7 +10749,7 @@ function requireReactDomServer_node_production() {
|
|
|
10749
10749
|
}
|
|
10750
10750
|
};
|
|
10751
10751
|
};
|
|
10752
|
-
reactDomServer_node_production.version = "19.2.
|
|
10752
|
+
reactDomServer_node_production.version = "19.2.4";
|
|
10753
10753
|
return reactDomServer_node_production;
|
|
10754
10754
|
}
|
|
10755
10755
|
var hasRequiredServer_node;
|
|
@@ -485,7 +485,7 @@ function requireReact_production() {
|
|
|
485
485
|
react_production.useTransition = function() {
|
|
486
486
|
return ReactSharedInternals.H.useTransition();
|
|
487
487
|
};
|
|
488
|
-
react_production.version = "19.2.
|
|
488
|
+
react_production.version = "19.2.4";
|
|
489
489
|
return react_production;
|
|
490
490
|
}
|
|
491
491
|
var hasRequiredReact;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var fullPattern = " daum[ /]| deusu/|(?:^|[^g])news(?!sapphire)|(?<! (?:channel/|google/))google(?!(app|/google| pixel))|(?<! cu)bots?(?:\\b|_)|(?<!(?:lib))http|(?<![hg]m)score|(?<!cam)scan|24x7|@[a-z][\\w-]+\\.|\\(\\)|\\.com\\b|\\b\\w+\\.ai|\\bmanus-user/|\\bperl\\b|\\btime/|\\||^[\\w \\.\\-\\(?:\\):%]+(?:/v?\\d+(?:\\.\\d+)?(?:\\.\\d{1,10})*?)?(?:,|$)|^[^ ]{50,}$|^\\d+\\b|^\\W|^\\w*search\\b|^\\w+/[\\w\\(\\)]
|
|
1
|
+
var fullPattern = " daum[ /]| deusu/|(?:^|[^g])news(?!sapphire)|(?<! (?:channel/|google/))google(?!(app|/google| pixel))|(?<! cu)bots?(?:\\b|_)|(?<!(?:lib))http|(?<![hg]m)score|(?<!cam)scan|24x7|@[a-z][\\w-]+\\.|\\(\\)|\\.com\\b|\\b\\w+\\.ai|\\bmanus-user/|\\bort/|\\bperl\\b|\\bsecurityheaders\\b|\\btime/|\\||^[\\w \\.\\-\\(?:\\):%]+(?:/v?\\d+(?:\\.\\d+)?(?:\\.\\d{1,10})*?)?(?:,|$)|^[^ ]{50,}$|^\\d+\\b|^\\W|^\\w*search\\b|^\\w+/[\\w\\(\\)]*$|^\\w+/\\d\\.\\d\\s\\([\\w@]+\\)$|^active|^ad muncher|^amaya|^apache/|^avsdevicesdk/|^azure|^biglotron|^bot|^bw/|^clamav[ /]|^client/|^cobweb/|^custom|^ddg[_-]android|^discourse|^dispatch/\\d|^downcast/|^duckduckgo|^email|^facebook|^getright/|^gozilla/|^hobbit|^hotzonu|^hwcdn/|^igetter/|^jeode/|^jetty/|^jigsaw|^microsoft bits|^movabletype|^mozilla/\\d\\.\\d\\s[\\w\\.-]+$|^mozilla/\\d\\.\\d\\s\\(compatible;?(?:\\s[\\w\\d-.]+\\/\\d+\\.\\d+)?\\)$|^navermailapp|^netsurf|^offline|^openai/|^owler|^php|^postman|^python|^rank|^read|^reed|^rest|^rss|^snapchat|^space bison|^svn|^swcd |^taringa|^thumbor/|^track|^w3c|^webbandit/|^webcopier|^wget|^whatsapp|^wordpress|^xenu link sleuth|^yahoo|^yandex|^zdm/\\d|^zoom marketplace/|advisor|agent\\b|analyzer|archive|ask jeeves/teoma|audit|bit\\.ly/|bluecoat drtr|browsex|burpcollaborator|capture|catch|check\\b|checker|chrome-lighthouse|chromeframe|classifier|cloudflare|convertify|crawl|cypress/|dareboost|datanyze|dejaclick|detect|dmbrowser|download|exaleadcloudview|feed|fetcher|firephp|functionize|grab|headless|httrack|hubspot marketing grader|ibisbrowser|infrawatch|insight|inspect|iplabel|java(?!;)|library|linkcheck|mail\\.ru/|manager|measure|neustar wpm|node\\b|nutch|offbyone|onetrust|optimize|pageburst|pagespeed|parser|phantomjs|pingdom|powermarks|preview|proxy|ptst[ /]\\d|retriever|rexx;|rigor|rss\\b|scrape|server|sogou|sparkler/|speedcurve|spider|splash|statuscake|supercleaner|synapse|synthetic|tools|torrent|transcoder|url|validator|virtuoso|wappalyzer|webglance|webkit2png|whatcms/|xtate/";
|
|
2
2
|
var naivePattern = /bot|crawl|http|lighthouse|scan|search|spider/i;
|
|
3
3
|
var pattern;
|
|
4
4
|
function getPattern() {
|