@instockng/storefront-ui 1.0.63 → 1.0.64
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/index10.mjs +13 -13
- package/dist/index100.mjs +41 -51
- package/dist/index101.mjs +2 -69
- package/dist/index142.mjs +2 -2
- package/dist/index143.mjs +1 -1
- package/dist/index144.mjs +6 -6
- package/dist/index145.mjs +2 -2
- package/dist/index146.mjs +2 -2
- package/dist/index148.mjs +2 -2
- package/dist/index149.mjs +2 -2
- package/dist/index150.mjs +1 -1
- package/dist/index152.mjs +8 -8
- package/dist/index153.mjs +8 -8
- package/dist/index163.mjs +1 -1
- package/dist/index164.mjs +1 -1
- package/dist/index166.mjs +2 -2
- package/dist/index167.mjs +1 -1
- package/dist/index172.mjs +2 -2
- package/dist/index174.mjs +1 -1
- package/dist/index176.mjs +2 -2
- package/dist/index177.mjs +5 -5
- package/dist/index180.mjs +1 -1
- package/dist/index183.mjs +1 -1
- package/dist/index186.mjs +1 -1
- package/dist/index187.mjs +1 -1
- package/dist/index191.mjs +1 -1
- package/dist/index208.mjs +2 -2
- package/dist/index217.mjs +2 -2
- package/dist/index218.mjs +108 -2
- package/dist/index219.mjs +2 -2
- package/dist/index220.mjs +2 -108
- package/dist/index221.mjs +2 -2
- package/dist/index222.mjs +2 -2
- package/dist/index223.mjs +36 -243
- package/dist/index224.mjs +2 -2
- package/dist/index225.mjs +2 -33
- package/dist/index226.mjs +240 -61
- package/dist/index227.mjs +2 -25
- package/dist/index228.mjs +33 -2
- package/dist/index229.mjs +56 -28
- package/dist/index230.mjs +25 -2
- package/dist/index233.mjs +2 -2
- package/dist/index234.mjs +2 -2
- package/dist/index239.mjs +31 -2
- package/dist/index240.mjs +11 -4
- package/dist/index241.mjs +4 -13
- package/dist/index242.mjs +4 -7
- package/dist/index243.mjs +12 -30
- package/dist/index244.mjs +7 -11
- package/dist/index245.mjs +11 -3
- package/dist/index246.mjs +4 -3
- package/dist/index247.mjs +33 -12
- package/dist/index248.mjs +31 -5
- package/dist/index249.mjs +27 -32
- package/dist/index250.mjs +58 -28
- package/dist/index251.mjs +2 -28
- package/dist/index252.mjs +4 -61
- package/dist/index256.mjs +2 -2
- package/dist/index257.mjs +18 -2
- package/dist/index258.mjs +42 -13
- package/dist/index259.mjs +2 -47
- package/dist/index264.mjs +2 -1
- package/dist/index265.mjs +2 -3
- package/dist/index266.mjs +2 -2
- package/dist/index267.mjs +2 -2
- package/dist/index271.mjs +1 -1
- package/dist/index40.mjs +1 -1
- package/dist/index42.mjs +1 -1
- package/dist/index49.mjs +1 -1
- package/dist/index54.mjs +17 -17
- package/dist/index55.mjs +2 -2
- package/dist/index68.mjs +153 -2
- package/dist/index69.mjs +19 -149
- package/dist/index70.mjs +2 -23
- package/dist/index73.mjs +1 -1
- package/dist/index80.mjs +1 -1
- package/dist/index82.mjs +235 -2
- package/dist/index83.mjs +6 -34
- package/dist/index84.mjs +130 -39
- package/dist/index85.mjs +62 -229
- package/dist/index86.mjs +86 -5
- package/dist/index87.mjs +26 -131
- package/dist/index88.mjs +8 -67
- package/dist/index89.mjs +71 -83
- package/dist/index90.mjs +3 -28
- package/dist/index91.mjs +2 -9
- package/dist/index92.mjs +78 -70
- package/dist/index93.mjs +53 -3
- package/dist/index94.mjs +6 -2
- package/dist/index95.mjs +4 -82
- package/dist/index96.mjs +176 -51
- package/dist/index97.mjs +53 -6
- package/dist/index98.mjs +69 -5
- package/dist/index99.mjs +34 -179
- package/dist/styles.css +1 -1
- package/package.json +1 -1
- package/src/components/ProductAddOns.tsx +3 -3
package/dist/index10.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { jsxs as l, jsx as t, Fragment as
|
|
2
|
+
import { jsxs as l, jsx as t, Fragment as B } from "react/jsx-runtime";
|
|
3
3
|
import { useRef as M, useState as E } from "react";
|
|
4
4
|
import { ChevronLeft as F, ChevronRight as L } from "lucide-react";
|
|
5
5
|
import { Switch as O } from "./index43.mjs";
|
|
@@ -39,13 +39,13 @@ function Y({
|
|
|
39
39
|
1
|
|
40
40
|
);
|
|
41
41
|
else {
|
|
42
|
-
const
|
|
43
|
-
|
|
42
|
+
const a = i == null ? void 0 : i.items.find((s) => s.variant.id === r.id);
|
|
43
|
+
a && await C(a.id);
|
|
44
44
|
}
|
|
45
45
|
}, o = M(null), [j, D] = E(0), I = () => {
|
|
46
46
|
if (o.current) {
|
|
47
|
-
const { scrollLeft: e, scrollWidth: n, clientWidth: r } = o.current,
|
|
48
|
-
D(
|
|
47
|
+
const { scrollLeft: e, scrollWidth: n, clientWidth: r } = o.current, a = e / (n - r);
|
|
48
|
+
D(a || 0);
|
|
49
49
|
}
|
|
50
50
|
}, g = (e) => {
|
|
51
51
|
if (o.current) {
|
|
@@ -56,11 +56,11 @@ function Y({
|
|
|
56
56
|
});
|
|
57
57
|
}
|
|
58
58
|
};
|
|
59
|
-
return (!c || c.length === 0) && !x ? null : x ? /* @__PURE__ */ l("div", { className: u("w-full py-8 space-y-4 animate-pulse", f), children: [
|
|
59
|
+
return (!c || c.length === 0) && !x ? null : x ? /* @__PURE__ */ l("div", { className: u("w-full py-8 space-y-4 animate-pulse", f), style: { maxWidth: "calc(100vw - calc(var(--spacing) * 4))" }, children: [
|
|
60
60
|
/* @__PURE__ */ t("div", { className: "h-4 w-32 bg-gray-200 rounded px-1 mb-6" }),
|
|
61
61
|
/* @__PURE__ */ l("div", { className: "flex gap-4 overflow-x-hidden", children: [
|
|
62
|
-
/* @__PURE__ */ t("div", { className: "min-w-[
|
|
63
|
-
/* @__PURE__ */ t("div", { className: "min-w-[
|
|
62
|
+
/* @__PURE__ */ t("div", { className: "min-w-[90%] h-[148px] bg-gray-100 rounded-[2rem]" }),
|
|
63
|
+
/* @__PURE__ */ t("div", { className: "min-w-[90%] h-[148px] bg-gray-100 rounded-[2rem]" })
|
|
64
64
|
] })
|
|
65
65
|
] }) : /* @__PURE__ */ l("div", { className: f, children: [
|
|
66
66
|
/* @__PURE__ */ t("div", { className: "px-1 mb-3", children: /* @__PURE__ */ t("h3", { className: "text-lg font-bold tracking-tight text-gray-900", children: b }) }),
|
|
@@ -72,7 +72,7 @@ function Y({
|
|
|
72
72
|
className: "flex gap-4 overflow-x-auto scrollbar-hide snap-x snap-mandatory px-1",
|
|
73
73
|
style: { scrollbarWidth: "none", msOverflowStyle: "none", maxWidth: "calc(100vw - calc(var(--spacing) * 4))" },
|
|
74
74
|
children: c.map((e) => {
|
|
75
|
-
const n = k.includes(e.id), r = e.variants[0],
|
|
75
|
+
const n = k.includes(e.id), r = e.variants[0], a = (r == null ? void 0 : r.price) || 0, s = e.compareAtPrice || r.compareAtPrice, p = s && s > a, S = p ? Math.round((s - a) / s * 100) : 0;
|
|
76
76
|
return /* @__PURE__ */ l(
|
|
77
77
|
"div",
|
|
78
78
|
{
|
|
@@ -90,9 +90,9 @@ function Y({
|
|
|
90
90
|
/* @__PURE__ */ t("h4", { className: "text-md font-bold text-[#333] truncate pr-2", title: e.name, children: e.name }),
|
|
91
91
|
e.addonDescription && /* @__PURE__ */ t("p", { className: "text-[11px] text-gray-500 line-clamp-3 italic mb-1", children: e.addonDescription }),
|
|
92
92
|
/* @__PURE__ */ l("div", { className: "flex items-center gap-2 mt-1", children: [
|
|
93
|
-
/* @__PURE__ */ t("span", { className: "text-md font-bold text-[#333]", children: v(
|
|
94
|
-
p && /* @__PURE__ */ l(
|
|
95
|
-
/* @__PURE__ */ t("span", { className: "text-sm text-[#DC143C] line-through", children: v(
|
|
93
|
+
/* @__PURE__ */ t("span", { className: "text-md font-bold text-[#333]", children: v(a) }),
|
|
94
|
+
p && /* @__PURE__ */ l(B, { children: [
|
|
95
|
+
/* @__PURE__ */ t("span", { className: "text-sm text-[#DC143C] line-through", children: v(s) }),
|
|
96
96
|
/* @__PURE__ */ l(R, { className: "bg-[#DC143C]/10 hover:bg-[#DC143C]/20 text-[#DC143C] border-none text-[10px] font-bold px-2 py-0.5 rounded-lg uppercase tracking-tight", children: [
|
|
97
97
|
S,
|
|
98
98
|
"% OFF"
|
|
@@ -104,7 +104,7 @@ function Y({
|
|
|
104
104
|
O,
|
|
105
105
|
{
|
|
106
106
|
checked: n,
|
|
107
|
-
onCheckedChange: (
|
|
107
|
+
onCheckedChange: (W) => A(e, W),
|
|
108
108
|
className: "scale-125"
|
|
109
109
|
}
|
|
110
110
|
) })
|
package/dist/index100.mjs
CHANGED
|
@@ -1,56 +1,46 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import d from "./index96.mjs";
|
|
7
|
-
const p = {
|
|
8
|
-
http: m,
|
|
9
|
-
xhr: u,
|
|
10
|
-
fetch: {
|
|
11
|
-
get: b
|
|
2
|
+
var s = (e, r) => (e = e.replace(/\/+$/, ""), e = e + "/", r = r.replace(/^\/+/, ""), e + r), p = (e, r) => {
|
|
3
|
+
for (const [n, t] of Object.entries(r)) {
|
|
4
|
+
const c = new RegExp("/:" + n + "(?:{[^/]+})?\\??");
|
|
5
|
+
e = e.replace(c, t ? `/${t}` : "");
|
|
12
6
|
}
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
7
|
+
return e;
|
|
8
|
+
}, f = (e) => {
|
|
9
|
+
const r = new URLSearchParams();
|
|
10
|
+
for (const [n, t] of Object.entries(e))
|
|
11
|
+
if (t !== void 0)
|
|
12
|
+
if (Array.isArray(t))
|
|
13
|
+
for (const c of t)
|
|
14
|
+
r.append(n, c);
|
|
15
|
+
else
|
|
16
|
+
r.set(n, t);
|
|
17
|
+
return r;
|
|
18
|
+
}, i = (e, r) => {
|
|
19
|
+
switch (r) {
|
|
20
|
+
case "ws":
|
|
21
|
+
return e.replace(/^http/, "ws");
|
|
22
|
+
case "http":
|
|
23
|
+
return e.replace(/^ws/, "http");
|
|
21
24
|
}
|
|
22
|
-
});
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
c[n || "#" + r] = t;
|
|
37
|
-
}
|
|
38
|
-
if (!t) {
|
|
39
|
-
const r = Object.entries(c).map(
|
|
40
|
-
([l, h]) => `adapter ${l} ` + (h === !1 ? "is not supported by the environment" : "is not available in the build")
|
|
41
|
-
);
|
|
42
|
-
let n = a ? r.length > 1 ? `since :
|
|
43
|
-
` + r.map(f).join(`
|
|
44
|
-
`) : " " + f(r[0]) : "as no adapter specified";
|
|
45
|
-
throw new d(
|
|
46
|
-
"There is no suitable adapter to dispatch the request " + n,
|
|
47
|
-
"ERR_NOT_SUPPORT"
|
|
48
|
-
);
|
|
49
|
-
}
|
|
50
|
-
return t;
|
|
51
|
-
},
|
|
52
|
-
adapters: p
|
|
53
|
-
};
|
|
25
|
+
}, l = (e) => /^https?:\/\/[^\/]+?\/index(?=\?|$)/.test(e) ? e.replace(/\/index(?=\?|$)/, "/") : e.replace(/\/index(?=\?|$)/, "");
|
|
26
|
+
function a(e) {
|
|
27
|
+
return typeof e == "object" && e !== null && !Array.isArray(e);
|
|
28
|
+
}
|
|
29
|
+
function o(e, r) {
|
|
30
|
+
if (!a(e) && !a(r))
|
|
31
|
+
return r;
|
|
32
|
+
const n = { ...e };
|
|
33
|
+
for (const t in r) {
|
|
34
|
+
const c = r[t];
|
|
35
|
+
a(n[t]) && a(c) ? n[t] = o(n[t], c) : n[t] = c;
|
|
36
|
+
}
|
|
37
|
+
return n;
|
|
38
|
+
}
|
|
54
39
|
export {
|
|
55
|
-
|
|
40
|
+
f as buildSearchParams,
|
|
41
|
+
o as deepMerge,
|
|
42
|
+
s as mergePath,
|
|
43
|
+
l as removeIndexString,
|
|
44
|
+
p as replaceUrlParam,
|
|
45
|
+
i as replaceUrlProtocol
|
|
56
46
|
};
|
package/dist/index101.mjs
CHANGED
|
@@ -1,72 +1,5 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
|
|
3
|
-
Continue: 100,
|
|
4
|
-
SwitchingProtocols: 101,
|
|
5
|
-
Processing: 102,
|
|
6
|
-
EarlyHints: 103,
|
|
7
|
-
Ok: 200,
|
|
8
|
-
Created: 201,
|
|
9
|
-
Accepted: 202,
|
|
10
|
-
NonAuthoritativeInformation: 203,
|
|
11
|
-
NoContent: 204,
|
|
12
|
-
ResetContent: 205,
|
|
13
|
-
PartialContent: 206,
|
|
14
|
-
MultiStatus: 207,
|
|
15
|
-
AlreadyReported: 208,
|
|
16
|
-
ImUsed: 226,
|
|
17
|
-
MultipleChoices: 300,
|
|
18
|
-
MovedPermanently: 301,
|
|
19
|
-
Found: 302,
|
|
20
|
-
SeeOther: 303,
|
|
21
|
-
NotModified: 304,
|
|
22
|
-
UseProxy: 305,
|
|
23
|
-
Unused: 306,
|
|
24
|
-
TemporaryRedirect: 307,
|
|
25
|
-
PermanentRedirect: 308,
|
|
26
|
-
BadRequest: 400,
|
|
27
|
-
Unauthorized: 401,
|
|
28
|
-
PaymentRequired: 402,
|
|
29
|
-
Forbidden: 403,
|
|
30
|
-
NotFound: 404,
|
|
31
|
-
MethodNotAllowed: 405,
|
|
32
|
-
NotAcceptable: 406,
|
|
33
|
-
ProxyAuthenticationRequired: 407,
|
|
34
|
-
RequestTimeout: 408,
|
|
35
|
-
Conflict: 409,
|
|
36
|
-
Gone: 410,
|
|
37
|
-
LengthRequired: 411,
|
|
38
|
-
PreconditionFailed: 412,
|
|
39
|
-
PayloadTooLarge: 413,
|
|
40
|
-
UriTooLong: 414,
|
|
41
|
-
UnsupportedMediaType: 415,
|
|
42
|
-
RangeNotSatisfiable: 416,
|
|
43
|
-
ExpectationFailed: 417,
|
|
44
|
-
ImATeapot: 418,
|
|
45
|
-
MisdirectedRequest: 421,
|
|
46
|
-
UnprocessableEntity: 422,
|
|
47
|
-
Locked: 423,
|
|
48
|
-
FailedDependency: 424,
|
|
49
|
-
TooEarly: 425,
|
|
50
|
-
UpgradeRequired: 426,
|
|
51
|
-
PreconditionRequired: 428,
|
|
52
|
-
TooManyRequests: 429,
|
|
53
|
-
RequestHeaderFieldsTooLarge: 431,
|
|
54
|
-
UnavailableForLegalReasons: 451,
|
|
55
|
-
InternalServerError: 500,
|
|
56
|
-
NotImplemented: 501,
|
|
57
|
-
BadGateway: 502,
|
|
58
|
-
ServiceUnavailable: 503,
|
|
59
|
-
GatewayTimeout: 504,
|
|
60
|
-
HttpVersionNotSupported: 505,
|
|
61
|
-
VariantAlsoNegotiates: 506,
|
|
62
|
-
InsufficientStorage: 507,
|
|
63
|
-
LoopDetected: 508,
|
|
64
|
-
NotExtended: 510,
|
|
65
|
-
NetworkAuthenticationRequired: 511
|
|
66
|
-
};
|
|
67
|
-
Object.entries(e).forEach(([t, o]) => {
|
|
68
|
-
e[o] = t;
|
|
69
|
-
});
|
|
2
|
+
var o = { exports: {} };
|
|
70
3
|
export {
|
|
71
|
-
|
|
4
|
+
o as __module
|
|
72
5
|
};
|
package/dist/index142.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import f from "./
|
|
3
|
-
import d from "./
|
|
2
|
+
import f from "./index82.mjs";
|
|
3
|
+
import d from "./index239.mjs";
|
|
4
4
|
function l(e) {
|
|
5
5
|
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
|
|
6
6
|
}
|
package/dist/index143.mjs
CHANGED
package/dist/index144.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import r from "./
|
|
3
|
-
import p from "./
|
|
4
|
-
import l from "./
|
|
5
|
-
import m from "./
|
|
6
|
-
import a from "./
|
|
7
|
-
import o from "./
|
|
2
|
+
import r from "./index240.mjs";
|
|
3
|
+
import p from "./index90.mjs";
|
|
4
|
+
import l from "./index86.mjs";
|
|
5
|
+
import m from "./index88.mjs";
|
|
6
|
+
import a from "./index96.mjs";
|
|
7
|
+
import o from "./index97.mjs";
|
|
8
8
|
function d(e) {
|
|
9
9
|
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
10
10
|
throw new m(null, e);
|
package/dist/index145.mjs
CHANGED
package/dist/index146.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { VERSION as w } from "./
|
|
3
|
-
import s from "./
|
|
2
|
+
import { VERSION as w } from "./index91.mjs";
|
|
3
|
+
import s from "./index93.mjs";
|
|
4
4
|
const l = {};
|
|
5
5
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((n, t) => {
|
|
6
6
|
l[n] = function(o) {
|
package/dist/index148.mjs
CHANGED
package/dist/index149.mjs
CHANGED
package/dist/index150.mjs
CHANGED
package/dist/index152.mjs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import H from "./
|
|
3
|
-
import D from "./
|
|
2
|
+
import H from "./index82.mjs";
|
|
3
|
+
import D from "./index245.mjs";
|
|
4
4
|
import L from "./index147.mjs";
|
|
5
|
-
import n from "./
|
|
6
|
-
import y from "./
|
|
7
|
-
import O from "./
|
|
5
|
+
import n from "./index93.mjs";
|
|
6
|
+
import y from "./index88.mjs";
|
|
7
|
+
import O from "./index246.mjs";
|
|
8
8
|
import U from "./index149.mjs";
|
|
9
|
-
import q from "./
|
|
10
|
-
import { progressEventReducer as A } from "./
|
|
11
|
-
import v from "./
|
|
9
|
+
import q from "./index96.mjs";
|
|
10
|
+
import { progressEventReducer as A } from "./index247.mjs";
|
|
11
|
+
import v from "./index248.mjs";
|
|
12
12
|
const N = typeof XMLHttpRequest < "u", Q = N && function(s) {
|
|
13
13
|
return new Promise(function(C, i) {
|
|
14
14
|
const t = v(s);
|
package/dist/index153.mjs
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import K from "./index149.mjs";
|
|
3
|
-
import t from "./
|
|
4
|
-
import b from "./
|
|
5
|
-
import ee from "./
|
|
6
|
-
import { trackStream as z } from "./
|
|
7
|
-
import te from "./
|
|
8
|
-
import { progressEventDecorator as I, progressEventReducer as M, asyncDecorator as j } from "./
|
|
9
|
-
import se from "./
|
|
10
|
-
import re from "./
|
|
3
|
+
import t from "./index82.mjs";
|
|
4
|
+
import b from "./index93.mjs";
|
|
5
|
+
import ee from "./index249.mjs";
|
|
6
|
+
import { trackStream as z } from "./index250.mjs";
|
|
7
|
+
import te from "./index96.mjs";
|
|
8
|
+
import { progressEventDecorator as I, progressEventReducer as M, asyncDecorator as j } from "./index247.mjs";
|
|
9
|
+
import se from "./index248.mjs";
|
|
10
|
+
import re from "./index245.mjs";
|
|
11
11
|
const J = 64 * 1024, { isFunction: P } = t, ne = (({ Request: r, Response: n }) => ({
|
|
12
12
|
Request: r,
|
|
13
13
|
Response: n
|
package/dist/index163.mjs
CHANGED
package/dist/index164.mjs
CHANGED
package/dist/index166.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { __exports as e } from "./
|
|
3
|
-
import { __require as f } from "./
|
|
2
|
+
import { __exports as e } from "./index217.mjs";
|
|
3
|
+
import { __require as f } from "./index218.mjs";
|
|
4
4
|
import { __require as _ } from "./index111.mjs";
|
|
5
5
|
var i;
|
|
6
6
|
function R() {
|
package/dist/index167.mjs
CHANGED
package/dist/index172.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { __exports as u } from "./
|
|
3
|
-
import { __require as d } from "./
|
|
2
|
+
import { __exports as u } from "./index222.mjs";
|
|
3
|
+
import { __require as d } from "./index223.mjs";
|
|
4
4
|
var a;
|
|
5
5
|
function h() {
|
|
6
6
|
return a ? u : (a = 1, function(c) {
|
package/dist/index174.mjs
CHANGED
package/dist/index176.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { __exports as n } from "./
|
|
3
|
-
import { __require as d } from "./
|
|
2
|
+
import { __exports as n } from "./index225.mjs";
|
|
3
|
+
import { __require as d } from "./index226.mjs";
|
|
4
4
|
var o;
|
|
5
5
|
function p() {
|
|
6
6
|
return o ? n : (o = 1, function(i) {
|
package/dist/index177.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { __exports as A } from "./
|
|
3
|
-
import { __require as T } from "./
|
|
2
|
+
import { __exports as A } from "./index227.mjs";
|
|
3
|
+
import { __require as T } from "./index226.mjs";
|
|
4
4
|
import { __require as L } from "./index180.mjs";
|
|
5
|
-
import { __require as N } from "./
|
|
5
|
+
import { __require as N } from "./index228.mjs";
|
|
6
6
|
import { __require as U } from "./index172.mjs";
|
|
7
|
-
import { __require as j } from "./
|
|
8
|
-
import { __require as v } from "./
|
|
7
|
+
import { __require as j } from "./index229.mjs";
|
|
8
|
+
import { __require as v } from "./index230.mjs";
|
|
9
9
|
var S;
|
|
10
10
|
function W() {
|
|
11
11
|
return S ? A : (S = 1, function(R) {
|
package/dist/index180.mjs
CHANGED
package/dist/index183.mjs
CHANGED
package/dist/index186.mjs
CHANGED
package/dist/index187.mjs
CHANGED
package/dist/index191.mjs
CHANGED
package/dist/index208.mjs
CHANGED
package/dist/index217.mjs
CHANGED
package/dist/index218.mjs
CHANGED
|
@@ -1,5 +1,111 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
|
|
2
|
+
import { __exports as m } from "./index255.mjs";
|
|
3
|
+
var p;
|
|
4
|
+
function S() {
|
|
5
|
+
return p ? m : (p = 1, function(d) {
|
|
6
|
+
Object.defineProperty(d, "__esModule", {
|
|
7
|
+
value: !0
|
|
8
|
+
});
|
|
9
|
+
function g(o, e) {
|
|
10
|
+
for (var r in e) Object.defineProperty(o, r, {
|
|
11
|
+
enumerable: !0,
|
|
12
|
+
get: e[r]
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
g(d, {
|
|
16
|
+
getSortedRouteObjects: function() {
|
|
17
|
+
return w;
|
|
18
|
+
},
|
|
19
|
+
getSortedRoutes: function() {
|
|
20
|
+
return f;
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
class h {
|
|
24
|
+
insert(e) {
|
|
25
|
+
this._insert(e.split("/").filter(Boolean), [], !1);
|
|
26
|
+
}
|
|
27
|
+
smoosh() {
|
|
28
|
+
return this._smoosh();
|
|
29
|
+
}
|
|
30
|
+
_smoosh(e) {
|
|
31
|
+
e === void 0 && (e = "/");
|
|
32
|
+
const r = [
|
|
33
|
+
...this.children.keys()
|
|
34
|
+
].sort();
|
|
35
|
+
this.slugName !== null && r.splice(r.indexOf("[]"), 1), this.restSlugName !== null && r.splice(r.indexOf("[...]"), 1), this.optionalRestSlugName !== null && r.splice(r.indexOf("[[...]]"), 1);
|
|
36
|
+
const n = r.map((s) => this.children.get(s)._smoosh("" + e + s + "/")).reduce((s, t) => [
|
|
37
|
+
...s,
|
|
38
|
+
...t
|
|
39
|
+
], []);
|
|
40
|
+
if (this.slugName !== null && n.push(...this.children.get("[]")._smoosh(e + "[" + this.slugName + "]/")), !this.placeholder) {
|
|
41
|
+
const s = e === "/" ? "/" : e.slice(0, -1);
|
|
42
|
+
if (this.optionalRestSlugName != null)
|
|
43
|
+
throw new Error('You cannot define a route with the same specificity as a optional catch-all route ("' + s + '" and "' + s + "[[..." + this.optionalRestSlugName + ']]").');
|
|
44
|
+
n.unshift(s);
|
|
45
|
+
}
|
|
46
|
+
return this.restSlugName !== null && n.push(...this.children.get("[...]")._smoosh(e + "[..." + this.restSlugName + "]/")), this.optionalRestSlugName !== null && n.push(...this.children.get("[[...]]")._smoosh(e + "[[..." + this.optionalRestSlugName + "]]/")), n;
|
|
47
|
+
}
|
|
48
|
+
_insert(e, r, n) {
|
|
49
|
+
if (e.length === 0) {
|
|
50
|
+
this.placeholder = !1;
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
if (n)
|
|
54
|
+
throw new Error("Catch-all must be the last part of the URL.");
|
|
55
|
+
let s = e[0];
|
|
56
|
+
if (s.startsWith("[") && s.endsWith("]")) {
|
|
57
|
+
let l = function(u, a) {
|
|
58
|
+
if (u !== null && u !== a)
|
|
59
|
+
throw new Error("You cannot use different slug names for the same dynamic path ('" + u + "' !== '" + a + "').");
|
|
60
|
+
r.forEach((c) => {
|
|
61
|
+
if (c === a)
|
|
62
|
+
throw new Error('You cannot have the same slug name "' + a + '" repeat within a single dynamic path');
|
|
63
|
+
if (c.replace(/\W/g, "") === s.replace(/\W/g, ""))
|
|
64
|
+
throw new Error('You cannot have the slug names "' + c + '" and "' + a + '" differ only by non-word symbols within a single dynamic path');
|
|
65
|
+
}), r.push(a);
|
|
66
|
+
}, t = s.slice(1, -1), i = !1;
|
|
67
|
+
if (t.startsWith("[") && t.endsWith("]") && (t = t.slice(1, -1), i = !0), t.startsWith("…"))
|
|
68
|
+
throw new Error("Detected a three-dot character ('…') at ('" + t + "'). Did you mean ('...')?");
|
|
69
|
+
if (t.startsWith("...") && (t = t.substring(3), n = !0), t.startsWith("[") || t.endsWith("]"))
|
|
70
|
+
throw new Error("Segment names may not start or end with extra brackets ('" + t + "').");
|
|
71
|
+
if (t.startsWith("."))
|
|
72
|
+
throw new Error("Segment names may not start with erroneous periods ('" + t + "').");
|
|
73
|
+
if (n)
|
|
74
|
+
if (i) {
|
|
75
|
+
if (this.restSlugName != null)
|
|
76
|
+
throw new Error('You cannot use both an required and optional catch-all route at the same level ("[...' + this.restSlugName + ']" and "' + e[0] + '" ).');
|
|
77
|
+
l(this.optionalRestSlugName, t), this.optionalRestSlugName = t, s = "[[...]]";
|
|
78
|
+
} else {
|
|
79
|
+
if (this.optionalRestSlugName != null)
|
|
80
|
+
throw new Error('You cannot use both an optional and required catch-all route at the same level ("[[...' + this.optionalRestSlugName + ']]" and "' + e[0] + '").');
|
|
81
|
+
l(this.restSlugName, t), this.restSlugName = t, s = "[...]";
|
|
82
|
+
}
|
|
83
|
+
else {
|
|
84
|
+
if (i)
|
|
85
|
+
throw new Error('Optional route parameters are not yet supported ("' + e[0] + '").');
|
|
86
|
+
l(this.slugName, t), this.slugName = t, s = "[]";
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
this.children.has(s) || this.children.set(s, new h()), this.children.get(s)._insert(e.slice(1), r, n);
|
|
90
|
+
}
|
|
91
|
+
constructor() {
|
|
92
|
+
this.placeholder = !0, this.children = /* @__PURE__ */ new Map(), this.slugName = null, this.restSlugName = null, this.optionalRestSlugName = null;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
function f(o) {
|
|
96
|
+
const e = new h();
|
|
97
|
+
return o.forEach((r) => e.insert(r)), e.smoosh();
|
|
98
|
+
}
|
|
99
|
+
function w(o, e) {
|
|
100
|
+
const r = {}, n = [];
|
|
101
|
+
for (let t = 0; t < o.length; t++) {
|
|
102
|
+
const i = e(o[t]);
|
|
103
|
+
r[i] = t, n[t] = i;
|
|
104
|
+
}
|
|
105
|
+
return f(n).map((t) => o[r[t]]);
|
|
106
|
+
}
|
|
107
|
+
}(m), m);
|
|
108
|
+
}
|
|
3
109
|
export {
|
|
4
|
-
|
|
110
|
+
S as __require
|
|
5
111
|
};
|
package/dist/index219.mjs
CHANGED