twd-js 1.6.1 → 1.6.3
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/bundled.es.js +1079 -966
- package/dist/componentMocks-BFMYYH2e.js +12 -0
- package/dist/componentMocks-CwMyWCu5.cjs +1 -0
- package/dist/index.cjs.js +48 -48
- package/dist/index.d.ts +0 -602
- package/dist/index.es.js +8783 -10753
- package/dist/mock-sw.js +4 -4
- package/dist/runner-BmEWmCyd.js +240 -0
- package/dist/runner-Dr_mUWED.cjs +1 -0
- package/dist/runner-ci.cjs.js +1 -1
- package/dist/runner-ci.d.ts +0 -27
- package/dist/runner-ci.es.js +35 -23
- package/dist/runner.cjs.js +1 -1
- package/dist/runner.d.ts +0 -62
- package/dist/runner.es.js +8 -221
- package/dist/ui.cjs.js +1 -1
- package/dist/ui.d.ts +0 -9
- package/dist/ui.es.js +6 -8
- package/dist/vite-plugin.cjs.js +1 -1
- package/dist/vite-plugin.d.ts +0 -66
- package/dist/vite-plugin.es.js +0 -1
- package/package.json +12 -10
- package/dist/jsx-runtime-BGWd3k7q.mjs +0 -274
- package/dist/jsx-runtime-BbmOcM6v.js +0 -6
- /package/dist/{bundled.d.ts → src/bundled.d.ts} +0 -0
package/dist/runner.es.js
CHANGED
|
@@ -1,223 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
var v = (s, t, e) => t in s ? E(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e;
|
|
3
|
-
var g = (s, t, e) => v(s, typeof t != "symbol" ? t + "" : t, e);
|
|
4
|
-
const _ = () => typeof window < "u" ? (window.__TWD_STATE__ || (window.__TWD_STATE__ = {
|
|
5
|
-
handlers: /* @__PURE__ */ new Map(),
|
|
6
|
-
beforeEachHooks: /* @__PURE__ */ new Map(),
|
|
7
|
-
afterEachHooks: /* @__PURE__ */ new Map(),
|
|
8
|
-
stack: []
|
|
9
|
-
}), window.__TWD_STATE__) : {
|
|
10
|
-
handlers: /* @__PURE__ */ new Map(),
|
|
11
|
-
beforeEachHooks: /* @__PURE__ */ new Map(),
|
|
12
|
-
afterEachHooks: /* @__PURE__ */ new Map(),
|
|
13
|
-
stack: []
|
|
14
|
-
}, y = _(), r = y.handlers, h = y.beforeEachHooks, u = y.afterEachHooks, o = y.stack, l = () => Math.random().toString(36).slice(2, 11), k = (s, t) => {
|
|
15
|
-
const e = l(), n = o.at(-1);
|
|
16
|
-
r.set(e, {
|
|
17
|
-
id: e,
|
|
18
|
-
name: s,
|
|
19
|
-
type: "suite",
|
|
20
|
-
children: [],
|
|
21
|
-
logs: [],
|
|
22
|
-
depth: o.length,
|
|
23
|
-
parent: n,
|
|
24
|
-
handler: t
|
|
25
|
-
}), n && r.get(n).children.push(e), o.push(e), t(), o.pop();
|
|
26
|
-
};
|
|
27
|
-
k.only = (s, t) => {
|
|
28
|
-
const e = l(), n = o.at(-1);
|
|
29
|
-
r.set(e, {
|
|
30
|
-
id: e,
|
|
31
|
-
name: s,
|
|
32
|
-
type: "suite",
|
|
33
|
-
children: [],
|
|
34
|
-
logs: [],
|
|
35
|
-
depth: o.length,
|
|
36
|
-
parent: n,
|
|
37
|
-
handler: t,
|
|
38
|
-
only: !0
|
|
39
|
-
}), n && r.get(n).children.push(e), o.push(e), t(), o.pop();
|
|
40
|
-
};
|
|
41
|
-
k.skip = (s, t) => {
|
|
42
|
-
const e = l(), n = o.at(-1);
|
|
43
|
-
r.set(e, {
|
|
44
|
-
id: e,
|
|
45
|
-
name: s,
|
|
46
|
-
type: "suite",
|
|
47
|
-
children: [],
|
|
48
|
-
logs: [],
|
|
49
|
-
depth: o.length,
|
|
50
|
-
parent: n,
|
|
51
|
-
handler: t,
|
|
52
|
-
skip: !0
|
|
53
|
-
}), n && r.get(n).children.push(e), o.push(e), t(), o.pop();
|
|
54
|
-
};
|
|
55
|
-
const w = (s, t) => {
|
|
56
|
-
const e = l(), n = o.at(-1), a = {
|
|
57
|
-
id: e,
|
|
58
|
-
name: s,
|
|
59
|
-
type: "test",
|
|
60
|
-
depth: o.length,
|
|
61
|
-
handler: t,
|
|
62
|
-
logs: [],
|
|
63
|
-
parent: n
|
|
64
|
-
};
|
|
65
|
-
n && r.get(n).children.push(e), r.set(e, a);
|
|
66
|
-
};
|
|
67
|
-
w.only = (s, t) => {
|
|
68
|
-
const e = l(), n = o.at(-1), a = {
|
|
69
|
-
id: e,
|
|
70
|
-
name: s,
|
|
71
|
-
type: "test",
|
|
72
|
-
depth: o.length,
|
|
73
|
-
handler: t,
|
|
74
|
-
logs: [],
|
|
75
|
-
parent: n,
|
|
76
|
-
only: !0
|
|
77
|
-
};
|
|
78
|
-
n && r.get(n).children.push(e), r.set(e, a);
|
|
79
|
-
};
|
|
80
|
-
w.skip = (s, t) => {
|
|
81
|
-
const e = l(), n = o.at(-1), a = {
|
|
82
|
-
id: e,
|
|
83
|
-
name: s,
|
|
84
|
-
type: "test",
|
|
85
|
-
depth: o.length,
|
|
86
|
-
handler: t || (() => {
|
|
87
|
-
}),
|
|
88
|
-
logs: [],
|
|
89
|
-
parent: n,
|
|
90
|
-
skip: !0
|
|
91
|
-
};
|
|
92
|
-
n && r.get(n).children.push(e), r.set(e, a);
|
|
93
|
-
};
|
|
94
|
-
const A = (s) => {
|
|
95
|
-
const t = o.at(-1);
|
|
96
|
-
if (!t) throw new Error("beforeEach() must be inside a describe()");
|
|
97
|
-
h.has(t) || h.set(t, []), h.get(t).push(s);
|
|
98
|
-
}, H = (s) => {
|
|
99
|
-
const t = o.at(-1);
|
|
100
|
-
if (!t) throw new Error("afterEach() must be inside a describe()");
|
|
101
|
-
u.has(t) || u.set(t, []), u.get(t).push(s);
|
|
102
|
-
}, T = (s) => {
|
|
103
|
-
const t = [], e = [];
|
|
104
|
-
let n = s;
|
|
105
|
-
for (; n; )
|
|
106
|
-
h.has(n) && t.unshift(...h.get(n)), u.has(n) && e.push(...u.get(n)), n = r.get(n)?.parent;
|
|
107
|
-
return { before: t, after: e };
|
|
108
|
-
}, f = (s) => {
|
|
109
|
-
const t = r.get(s);
|
|
110
|
-
return t ? t.only ? !0 : t.children ? t.children.some((e) => f(e)) : !1 : !1;
|
|
111
|
-
}, b = (s) => {
|
|
112
|
-
let t = r.get(s);
|
|
113
|
-
for (; t?.parent; ) {
|
|
114
|
-
const e = r.get(t.parent);
|
|
115
|
-
if (e?.only) return !0;
|
|
116
|
-
t = e;
|
|
117
|
-
}
|
|
118
|
-
return !1;
|
|
119
|
-
}, S = (s) => {
|
|
120
|
-
let t = r.get(s);
|
|
121
|
-
for (; t; ) {
|
|
122
|
-
if (t.skip) return !0;
|
|
123
|
-
if (!t.parent) break;
|
|
124
|
-
t = r.get(t.parent);
|
|
125
|
-
}
|
|
126
|
-
return !1;
|
|
127
|
-
}, M = () => {
|
|
128
|
-
r.clear(), h.clear(), u.clear();
|
|
129
|
-
};
|
|
130
|
-
class I {
|
|
131
|
-
constructor(t, e) {
|
|
132
|
-
g(this, "events");
|
|
133
|
-
g(this, "retryCount");
|
|
134
|
-
this.events = t, this.retryCount = e?.retryCount ?? 1;
|
|
135
|
-
}
|
|
136
|
-
async runAll() {
|
|
137
|
-
const t = Array.from(r.values()).filter(
|
|
138
|
-
(n) => !n.parent && n.type === "suite"
|
|
139
|
-
), e = Array.from(r.values()).some((n) => n.only);
|
|
140
|
-
for (const n of t)
|
|
141
|
-
await this.runSuite(n, e);
|
|
142
|
-
return r;
|
|
143
|
-
}
|
|
144
|
-
async runSingle(t) {
|
|
145
|
-
const e = r.get(t);
|
|
146
|
-
if (!e || e.type !== "test") return;
|
|
147
|
-
await this.runTest(e, !1);
|
|
148
|
-
}
|
|
149
|
-
async runByIds(t) {
|
|
150
|
-
const e = new Set(t), n = Array.from(r.values()).filter(
|
|
151
|
-
(i) => !i.parent && i.type === "suite"
|
|
152
|
-
), a = Array.from(r.values()).some((i) => i.only);
|
|
153
|
-
for (const i of n)
|
|
154
|
-
await this.runSuiteByIds(i, e, a);
|
|
155
|
-
return r;
|
|
156
|
-
}
|
|
157
|
-
async runSuiteByIds(t, e, n) {
|
|
158
|
-
if (!this.hasDescendantInSet(t, e)) return;
|
|
159
|
-
if (S(t.id) && !f(t.id)) {
|
|
160
|
-
this.events.onSkip?.(t);
|
|
161
|
-
return;
|
|
162
|
-
}
|
|
163
|
-
if (n && !f(t.id)) return;
|
|
164
|
-
this.events.onSuiteStart?.(t);
|
|
165
|
-
const d = (t.children || []).map((c) => r.get(c));
|
|
166
|
-
for (const c of d)
|
|
167
|
-
c.type === "suite" ? await this.runSuiteByIds(c, e, n) : c.type === "test" && e.has(c.id) && await this.runTest(c, n);
|
|
168
|
-
this.events.onSuiteEnd?.(t);
|
|
169
|
-
}
|
|
170
|
-
hasDescendantInSet(t, e) {
|
|
171
|
-
return e.has(t.id) ? !0 : t.children ? t.children.some((n) => {
|
|
172
|
-
const a = r.get(n);
|
|
173
|
-
return a ? this.hasDescendantInSet(a, e) : !1;
|
|
174
|
-
}) : !1;
|
|
175
|
-
}
|
|
176
|
-
async runSuite(t, e) {
|
|
177
|
-
if (S(t.id) && !f(t.id)) {
|
|
178
|
-
this.events.onSkip?.(t);
|
|
179
|
-
return;
|
|
180
|
-
}
|
|
181
|
-
if (e && !f(t.id)) return;
|
|
182
|
-
this.events.onSuiteStart?.(t);
|
|
183
|
-
const a = (t.children || []).map((i) => r.get(i));
|
|
184
|
-
for (const i of a)
|
|
185
|
-
i.type === "suite" ? await this.runSuite(i, e) : i.type === "test" && await this.runTest(i, e);
|
|
186
|
-
this.events.onSuiteEnd?.(t);
|
|
187
|
-
}
|
|
188
|
-
async runTest(t, e) {
|
|
189
|
-
if ((S(t.id) || t.skip) && !t.only) {
|
|
190
|
-
this.events.onSkip(t);
|
|
191
|
-
return;
|
|
192
|
-
}
|
|
193
|
-
const a = b(t.id);
|
|
194
|
-
if (e && !t.only && !a) {
|
|
195
|
-
this.events.onSkip(t);
|
|
196
|
-
return;
|
|
197
|
-
}
|
|
198
|
-
this.events.onStart?.(t);
|
|
199
|
-
const i = T(t.parent);
|
|
200
|
-
let d = null;
|
|
201
|
-
for (let c = 1; c <= this.retryCount; c++)
|
|
202
|
-
try {
|
|
203
|
-
for (const p of i.before) await p();
|
|
204
|
-
t.logs = [], await t.handler(), this.events.onPass(t, c > 1 ? c : void 0);
|
|
205
|
-
return;
|
|
206
|
-
} catch (p) {
|
|
207
|
-
d = p;
|
|
208
|
-
} finally {
|
|
209
|
-
for (const p of i.after) await p();
|
|
210
|
-
}
|
|
211
|
-
this.events.onFail(t, d);
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
window.__testRunner = I;
|
|
1
|
+
import { a as s, i as e, n as r, o as t, r as o, s as c, t as i } from "./runner-BmEWmCyd.js";
|
|
215
2
|
export {
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
3
|
+
i as TestRunner,
|
|
4
|
+
r as afterEach,
|
|
5
|
+
o as beforeEach,
|
|
6
|
+
e as clearTests,
|
|
7
|
+
s as describe,
|
|
8
|
+
t as handlers,
|
|
9
|
+
c as it
|
|
223
10
|
};
|
package/dist/ui.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./componentMocks-CwMyWCu5.cjs"),u=require("./index.cjs.js");let t=require("react/jsx-runtime");function c({name:r,children:e}){const o=n.getMockForComponent(r);return o?(0,t.jsx)(o,{...e.props}):e}exports.MockedComponent=c;
|
package/dist/ui.d.ts
CHANGED
|
@@ -1,10 +1 @@
|
|
|
1
|
-
import { JSX } from 'react/jsx-runtime';
|
|
2
|
-
|
|
3
|
-
export declare function MockedComponent<TProps extends Record<string, any>>({ name, children, }: MockedComponentProps<TProps>): JSX.Element;
|
|
4
|
-
|
|
5
|
-
declare interface MockedComponentProps<TProps = any> {
|
|
6
|
-
name: string;
|
|
7
|
-
children: React.ReactElement<TProps>;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
1
|
export { }
|
package/dist/ui.es.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
})
|
|
6
|
-
const t = r(n);
|
|
7
|
-
return t ? /* @__PURE__ */ e.jsx(t, { ...o.props }) : o;
|
|
1
|
+
import { n } from "./componentMocks-BFMYYH2e.js";
|
|
2
|
+
import { jsx as p } from "react/jsx-runtime";
|
|
3
|
+
function c({ name: t, children: o }) {
|
|
4
|
+
const r = n(t);
|
|
5
|
+
return r ? /* @__PURE__ */ p(r, { ...o.props }) : o;
|
|
8
6
|
}
|
|
9
7
|
export {
|
|
10
|
-
|
|
8
|
+
c as MockedComponent
|
|
11
9
|
};
|
package/dist/vite-plugin.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("./index.cjs.js");let s=require("fs"),l=require("path");function i(){return{name:"remove-mock-sw",apply:"build",closeBundle(){try{(0,s.rmSync)((0,l.resolve)("dist/mock-sw.js")),console.log("🧹 Removed mock-sw.js from build")}catch{console.log("🧹 No mock-sw.js found in build")}}}}function c(o={}){const{testFilePattern:e=".twd.test.ts"}=o,r=typeof e=="function"?e:t=>t.endsWith(e);return{name:"twd-hmr",apply:"serve",handleHotUpdate({file:t,server:n}){if(r(t))return n.ws.send({type:"full-reload",path:"*"}),[]}}}exports.removeMockServiceWorker=i;exports.twdHmr=c;
|
package/dist/vite-plugin.d.ts
CHANGED
|
@@ -1,67 +1 @@
|
|
|
1
|
-
import { Plugin as Plugin_2 } from 'vite';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Vite plugin to remove the mock service worker file from the build output.
|
|
5
|
-
* This is useful for production builds where you don't want the mock service worker to be included.
|
|
6
|
-
*
|
|
7
|
-
* @example
|
|
8
|
-
* ```ts
|
|
9
|
-
* import { removeMockServiceWorker } from 'twd-js';
|
|
10
|
-
*
|
|
11
|
-
* export default defineConfig({
|
|
12
|
-
* plugins: [
|
|
13
|
-
* // ... other plugins
|
|
14
|
-
* removeMockServiceWorker()
|
|
15
|
-
* ]
|
|
16
|
-
* });
|
|
17
|
-
* ```
|
|
18
|
-
*/
|
|
19
|
-
export declare function removeMockServiceWorker(): Plugin_2;
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Vite plugin to handle HMR for TWD test files.
|
|
23
|
-
* When a TWD test file is updated, it forces a full page reload to prevent
|
|
24
|
-
* duplicate test entries that occur when HMR reloads test modules.
|
|
25
|
-
*
|
|
26
|
-
* This plugin only runs in development mode (serve) and does not affect Vitest test runs.
|
|
27
|
-
*
|
|
28
|
-
* @param options - Configuration options for the plugin
|
|
29
|
-
* @example
|
|
30
|
-
* ```ts
|
|
31
|
-
* import { twdHmr } from 'twd-js/vite-plugin';
|
|
32
|
-
*
|
|
33
|
-
* export default defineConfig({
|
|
34
|
-
* plugins: [
|
|
35
|
-
* // ... other plugins
|
|
36
|
-
* twdHmr() // Uses default pattern: .twd.test.ts
|
|
37
|
-
* ]
|
|
38
|
-
* });
|
|
39
|
-
* ```
|
|
40
|
-
* @example
|
|
41
|
-
* ```ts
|
|
42
|
-
* // Custom pattern
|
|
43
|
-
* twdHmr({ testFilePattern: '.twd.test.tsx' })
|
|
44
|
-
* ```
|
|
45
|
-
* @example
|
|
46
|
-
* ```ts
|
|
47
|
-
* // Custom function
|
|
48
|
-
* twdHmr({
|
|
49
|
-
* testFilePattern: (file) => file.includes('.twd.test.')
|
|
50
|
-
* })
|
|
51
|
-
* ```
|
|
52
|
-
*/
|
|
53
|
-
export declare function twdHmr(options?: TwdHmrOptions): Plugin_2;
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* Options for the TWD HMR plugin.
|
|
57
|
-
*/
|
|
58
|
-
export declare interface TwdHmrOptions {
|
|
59
|
-
/**
|
|
60
|
-
* Pattern to match test files. Defaults to `.twd.test.ts`.
|
|
61
|
-
* Can be a string (checked with `endsWith`) or a function that returns a boolean.
|
|
62
|
-
* @default ".twd.test.ts"
|
|
63
|
-
*/
|
|
64
|
-
testFilePattern?: string | ((file: string) => boolean);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
1
|
export { }
|
package/dist/vite-plugin.es.js
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "twd-js",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.3",
|
|
4
4
|
"description": "Test While Developing (TWD) - in-browser testing",
|
|
5
|
+
"type": "module",
|
|
5
6
|
"license": "MIT",
|
|
6
7
|
"author": "BRIKEV",
|
|
7
8
|
"homepage": "https://github.com/BRIKEV/twd#readme",
|
|
@@ -70,27 +71,28 @@
|
|
|
70
71
|
"docs:preview": "vitepress preview docs",
|
|
71
72
|
"copy:mock-sw": "cp dist/mock-sw.js examples/twd-test-app/public/mock-sw.js && cp dist/mock-sw.js examples/tutorial-example/public/mock-sw.js && cp dist/mock-sw.js examples/vue-twd-example/public/mock-sw.js",
|
|
72
73
|
"copy:dist:vue-twd-example": "cp -r dist examples/vue-twd-example/src",
|
|
73
|
-
"copy:dist:tutorial-example": "cp -r dist examples/tutorial-example/src"
|
|
74
|
+
"copy:dist:tutorial-example": "cp -r dist examples/tutorial-example/src",
|
|
75
|
+
"copy:dist:examples": "npm run copy:dist:vue-twd-example && npm run copy:dist:tutorial-example"
|
|
74
76
|
},
|
|
75
77
|
"peerDependencies": {
|
|
76
78
|
"react": ">=17.0.0",
|
|
77
79
|
"react-dom": ">=17.0.0"
|
|
78
80
|
},
|
|
79
81
|
"devDependencies": {
|
|
80
|
-
"@preact/preset-vite": "^2.10.
|
|
82
|
+
"@preact/preset-vite": "^2.10.5",
|
|
81
83
|
"@testing-library/jest-dom": "^6.9.1",
|
|
82
84
|
"@testing-library/react": "^16.3.2",
|
|
83
85
|
"@types/react": "^19.2.14",
|
|
84
86
|
"@types/react-dom": "^19.2.3",
|
|
85
|
-
"@vitejs/plugin-react": "^
|
|
86
|
-
"@vitest/coverage-v8": "^4.
|
|
87
|
+
"@vitejs/plugin-react": "^6.0.1",
|
|
88
|
+
"@vitest/coverage-v8": "^4.1.2",
|
|
87
89
|
"conventional-changelog": "^7.2.0",
|
|
88
|
-
"jsdom": "^
|
|
89
|
-
"typescript": "^
|
|
90
|
-
"vite": "^
|
|
90
|
+
"jsdom": "^29.0.1",
|
|
91
|
+
"typescript": "^6.0.2",
|
|
92
|
+
"vite": "^8.0.3",
|
|
91
93
|
"vite-plugin-dts": "^4.5.4",
|
|
92
94
|
"vitepress": "^2.0.0-alpha.12",
|
|
93
|
-
"vitest": "^4.
|
|
95
|
+
"vitest": "^4.1.2"
|
|
94
96
|
},
|
|
95
97
|
"keywords": [
|
|
96
98
|
"testing",
|
|
@@ -107,6 +109,6 @@
|
|
|
107
109
|
"@testing-library/user-event": "^14.6.1",
|
|
108
110
|
"@types/chai": "^5.2.3",
|
|
109
111
|
"chai": "^6.2.2",
|
|
110
|
-
"preact": "^10.
|
|
112
|
+
"preact": "^10.29.0"
|
|
111
113
|
}
|
|
112
114
|
}
|
|
@@ -1,274 +0,0 @@
|
|
|
1
|
-
import ee from "react";
|
|
2
|
-
const P = /* @__PURE__ */ new Map(), oe = (o, l) => {
|
|
3
|
-
P.set(o, l);
|
|
4
|
-
};
|
|
5
|
-
function se() {
|
|
6
|
-
P.clear();
|
|
7
|
-
}
|
|
8
|
-
const ue = (o) => P.get(o);
|
|
9
|
-
var b = { exports: {} }, _ = {};
|
|
10
|
-
var F;
|
|
11
|
-
function re() {
|
|
12
|
-
if (F) return _;
|
|
13
|
-
F = 1;
|
|
14
|
-
var o = /* @__PURE__ */ Symbol.for("react.transitional.element"), l = /* @__PURE__ */ Symbol.for("react.fragment");
|
|
15
|
-
function i(f, s, u) {
|
|
16
|
-
var m = null;
|
|
17
|
-
if (u !== void 0 && (m = "" + u), s.key !== void 0 && (m = "" + s.key), "key" in s) {
|
|
18
|
-
u = {};
|
|
19
|
-
for (var d in s)
|
|
20
|
-
d !== "key" && (u[d] = s[d]);
|
|
21
|
-
} else u = s;
|
|
22
|
-
return s = u.ref, {
|
|
23
|
-
$$typeof: o,
|
|
24
|
-
type: f,
|
|
25
|
-
key: m,
|
|
26
|
-
ref: s !== void 0 ? s : null,
|
|
27
|
-
props: u
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
return _.Fragment = l, _.jsx = i, _.jsxs = i, _;
|
|
31
|
-
}
|
|
32
|
-
var E = {};
|
|
33
|
-
var I;
|
|
34
|
-
function te() {
|
|
35
|
-
return I || (I = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
36
|
-
function o(e) {
|
|
37
|
-
if (e == null) return null;
|
|
38
|
-
if (typeof e == "function")
|
|
39
|
-
return e.$$typeof === Z ? null : e.displayName || e.name || null;
|
|
40
|
-
if (typeof e == "string") return e;
|
|
41
|
-
switch (e) {
|
|
42
|
-
case v:
|
|
43
|
-
return "Fragment";
|
|
44
|
-
case q:
|
|
45
|
-
return "Profiler";
|
|
46
|
-
case U:
|
|
47
|
-
return "StrictMode";
|
|
48
|
-
case G:
|
|
49
|
-
return "Suspense";
|
|
50
|
-
case X:
|
|
51
|
-
return "SuspenseList";
|
|
52
|
-
case H:
|
|
53
|
-
return "Activity";
|
|
54
|
-
}
|
|
55
|
-
if (typeof e == "object")
|
|
56
|
-
switch (typeof e.tag == "number" && console.error(
|
|
57
|
-
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
58
|
-
), e.$$typeof) {
|
|
59
|
-
case W:
|
|
60
|
-
return "Portal";
|
|
61
|
-
case V:
|
|
62
|
-
return e.displayName || "Context";
|
|
63
|
-
case J:
|
|
64
|
-
return (e._context.displayName || "Context") + ".Consumer";
|
|
65
|
-
case z:
|
|
66
|
-
var r = e.render;
|
|
67
|
-
return e = e.displayName, e || (e = r.displayName || r.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
|
|
68
|
-
case B:
|
|
69
|
-
return r = e.displayName || null, r !== null ? r : o(e.type) || "Memo";
|
|
70
|
-
case T:
|
|
71
|
-
r = e._payload, e = e._init;
|
|
72
|
-
try {
|
|
73
|
-
return o(e(r));
|
|
74
|
-
} catch {
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
return null;
|
|
78
|
-
}
|
|
79
|
-
function l(e) {
|
|
80
|
-
return "" + e;
|
|
81
|
-
}
|
|
82
|
-
function i(e) {
|
|
83
|
-
try {
|
|
84
|
-
l(e);
|
|
85
|
-
var r = !1;
|
|
86
|
-
} catch {
|
|
87
|
-
r = !0;
|
|
88
|
-
}
|
|
89
|
-
if (r) {
|
|
90
|
-
r = console;
|
|
91
|
-
var t = r.error, n = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
|
|
92
|
-
return t.call(
|
|
93
|
-
r,
|
|
94
|
-
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
95
|
-
n
|
|
96
|
-
), l(e);
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
function f(e) {
|
|
100
|
-
if (e === v) return "<>";
|
|
101
|
-
if (typeof e == "object" && e !== null && e.$$typeof === T)
|
|
102
|
-
return "<...>";
|
|
103
|
-
try {
|
|
104
|
-
var r = o(e);
|
|
105
|
-
return r ? "<" + r + ">" : "<...>";
|
|
106
|
-
} catch {
|
|
107
|
-
return "<...>";
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
function s() {
|
|
111
|
-
var e = k.A;
|
|
112
|
-
return e === null ? null : e.getOwner();
|
|
113
|
-
}
|
|
114
|
-
function u() {
|
|
115
|
-
return Error("react-stack-top-frame");
|
|
116
|
-
}
|
|
117
|
-
function m(e) {
|
|
118
|
-
if (x.call(e, "key")) {
|
|
119
|
-
var r = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
120
|
-
if (r && r.isReactWarning) return !1;
|
|
121
|
-
}
|
|
122
|
-
return e.key !== void 0;
|
|
123
|
-
}
|
|
124
|
-
function d(e, r) {
|
|
125
|
-
function t() {
|
|
126
|
-
h || (h = !0, console.error(
|
|
127
|
-
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
128
|
-
r
|
|
129
|
-
));
|
|
130
|
-
}
|
|
131
|
-
t.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
132
|
-
get: t,
|
|
133
|
-
configurable: !0
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
|
-
function D() {
|
|
137
|
-
var e = o(this.type);
|
|
138
|
-
return N[e] || (N[e] = !0, console.error(
|
|
139
|
-
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
140
|
-
)), e = this.props.ref, e !== void 0 ? e : null;
|
|
141
|
-
}
|
|
142
|
-
function L(e, r, t, n, p, A) {
|
|
143
|
-
var a = t.ref;
|
|
144
|
-
return e = {
|
|
145
|
-
$$typeof: j,
|
|
146
|
-
type: e,
|
|
147
|
-
key: r,
|
|
148
|
-
props: t,
|
|
149
|
-
_owner: n
|
|
150
|
-
}, (a !== void 0 ? a : null) !== null ? Object.defineProperty(e, "ref", {
|
|
151
|
-
enumerable: !1,
|
|
152
|
-
get: D
|
|
153
|
-
}) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
|
|
154
|
-
configurable: !1,
|
|
155
|
-
enumerable: !1,
|
|
156
|
-
writable: !0,
|
|
157
|
-
value: 0
|
|
158
|
-
}), Object.defineProperty(e, "_debugInfo", {
|
|
159
|
-
configurable: !1,
|
|
160
|
-
enumerable: !1,
|
|
161
|
-
writable: !0,
|
|
162
|
-
value: null
|
|
163
|
-
}), Object.defineProperty(e, "_debugStack", {
|
|
164
|
-
configurable: !1,
|
|
165
|
-
enumerable: !1,
|
|
166
|
-
writable: !0,
|
|
167
|
-
value: p
|
|
168
|
-
}), Object.defineProperty(e, "_debugTask", {
|
|
169
|
-
configurable: !1,
|
|
170
|
-
enumerable: !1,
|
|
171
|
-
writable: !0,
|
|
172
|
-
value: A
|
|
173
|
-
}), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
|
|
174
|
-
}
|
|
175
|
-
function w(e, r, t, n, p, A) {
|
|
176
|
-
var a = r.children;
|
|
177
|
-
if (a !== void 0)
|
|
178
|
-
if (n)
|
|
179
|
-
if (Q(a)) {
|
|
180
|
-
for (n = 0; n < a.length; n++)
|
|
181
|
-
g(a[n]);
|
|
182
|
-
Object.freeze && Object.freeze(a);
|
|
183
|
-
} else
|
|
184
|
-
console.error(
|
|
185
|
-
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
186
|
-
);
|
|
187
|
-
else g(a);
|
|
188
|
-
if (x.call(r, "key")) {
|
|
189
|
-
a = o(e);
|
|
190
|
-
var c = Object.keys(r).filter(function(K) {
|
|
191
|
-
return K !== "key";
|
|
192
|
-
});
|
|
193
|
-
n = 0 < c.length ? "{key: someKey, " + c.join(": ..., ") + ": ...}" : "{key: someKey}", $[a + n] || (c = 0 < c.length ? "{" + c.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
194
|
-
`A props object containing a "key" prop is being spread into JSX:
|
|
195
|
-
let props = %s;
|
|
196
|
-
<%s {...props} />
|
|
197
|
-
React keys must be passed directly to JSX without using spread:
|
|
198
|
-
let props = %s;
|
|
199
|
-
<%s key={someKey} {...props} />`,
|
|
200
|
-
n,
|
|
201
|
-
a,
|
|
202
|
-
c,
|
|
203
|
-
a
|
|
204
|
-
), $[a + n] = !0);
|
|
205
|
-
}
|
|
206
|
-
if (a = null, t !== void 0 && (i(t), a = "" + t), m(r) && (i(r.key), a = "" + r.key), "key" in r) {
|
|
207
|
-
t = {};
|
|
208
|
-
for (var S in r)
|
|
209
|
-
S !== "key" && (t[S] = r[S]);
|
|
210
|
-
} else t = r;
|
|
211
|
-
return a && d(
|
|
212
|
-
t,
|
|
213
|
-
typeof e == "function" ? e.displayName || e.name || "Unknown" : e
|
|
214
|
-
), L(
|
|
215
|
-
e,
|
|
216
|
-
a,
|
|
217
|
-
t,
|
|
218
|
-
s(),
|
|
219
|
-
p,
|
|
220
|
-
A
|
|
221
|
-
);
|
|
222
|
-
}
|
|
223
|
-
function g(e) {
|
|
224
|
-
y(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e !== null && e.$$typeof === T && (e._payload.status === "fulfilled" ? y(e._payload.value) && e._payload.value._store && (e._payload.value._store.validated = 1) : e._store && (e._store.validated = 1));
|
|
225
|
-
}
|
|
226
|
-
function y(e) {
|
|
227
|
-
return typeof e == "object" && e !== null && e.$$typeof === j;
|
|
228
|
-
}
|
|
229
|
-
var R = ee, j = /* @__PURE__ */ Symbol.for("react.transitional.element"), W = /* @__PURE__ */ Symbol.for("react.portal"), v = /* @__PURE__ */ Symbol.for("react.fragment"), U = /* @__PURE__ */ Symbol.for("react.strict_mode"), q = /* @__PURE__ */ Symbol.for("react.profiler"), J = /* @__PURE__ */ Symbol.for("react.consumer"), V = /* @__PURE__ */ Symbol.for("react.context"), z = /* @__PURE__ */ Symbol.for("react.forward_ref"), G = /* @__PURE__ */ Symbol.for("react.suspense"), X = /* @__PURE__ */ Symbol.for("react.suspense_list"), B = /* @__PURE__ */ Symbol.for("react.memo"), T = /* @__PURE__ */ Symbol.for("react.lazy"), H = /* @__PURE__ */ Symbol.for("react.activity"), Z = /* @__PURE__ */ Symbol.for("react.client.reference"), k = R.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, x = Object.prototype.hasOwnProperty, Q = Array.isArray, O = console.createTask ? console.createTask : function() {
|
|
230
|
-
return null;
|
|
231
|
-
};
|
|
232
|
-
R = {
|
|
233
|
-
react_stack_bottom_frame: function(e) {
|
|
234
|
-
return e();
|
|
235
|
-
}
|
|
236
|
-
};
|
|
237
|
-
var h, N = {}, C = R.react_stack_bottom_frame.bind(
|
|
238
|
-
R,
|
|
239
|
-
u
|
|
240
|
-
)(), Y = O(f(u)), $ = {};
|
|
241
|
-
E.Fragment = v, E.jsx = function(e, r, t) {
|
|
242
|
-
var n = 1e4 > k.recentlyCreatedOwnerStacks++;
|
|
243
|
-
return w(
|
|
244
|
-
e,
|
|
245
|
-
r,
|
|
246
|
-
t,
|
|
247
|
-
!1,
|
|
248
|
-
n ? Error("react-stack-top-frame") : C,
|
|
249
|
-
n ? O(f(e)) : Y
|
|
250
|
-
);
|
|
251
|
-
}, E.jsxs = function(e, r, t) {
|
|
252
|
-
var n = 1e4 > k.recentlyCreatedOwnerStacks++;
|
|
253
|
-
return w(
|
|
254
|
-
e,
|
|
255
|
-
r,
|
|
256
|
-
t,
|
|
257
|
-
!0,
|
|
258
|
-
n ? Error("react-stack-top-frame") : C,
|
|
259
|
-
n ? O(f(e)) : Y
|
|
260
|
-
);
|
|
261
|
-
};
|
|
262
|
-
})()), E;
|
|
263
|
-
}
|
|
264
|
-
var M;
|
|
265
|
-
function ne() {
|
|
266
|
-
return M || (M = 1, process.env.NODE_ENV === "production" ? b.exports = re() : b.exports = te()), b.exports;
|
|
267
|
-
}
|
|
268
|
-
var le = ne();
|
|
269
|
-
export {
|
|
270
|
-
se as c,
|
|
271
|
-
ue as g,
|
|
272
|
-
le as j,
|
|
273
|
-
oe as m
|
|
274
|
-
};
|