@fudrouter/fsrouter 0.6.99 → 0.6.100
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/routes/db/route.js +141 -97
- package/package.json +1 -1
- package/public/.vite/manifest.json +90 -90
- package/public/assets/EndpointPageClient.B1pL25ws.js +6 -0
- package/public/assets/Loading.C1s7rolj.js +1 -0
- package/public/assets/NoAuthProxyCard.CrFQ6U88.js +89 -0
- package/public/assets/index.2a3mqmx-.js +89 -0
- package/public/assets/index.Blvwx0HS.css +1 -0
- package/public/assets/page.1w2ClxJa.js +64 -0
- package/public/assets/page.B1WuiJNL.js +1 -0
- package/public/assets/page.B5pzcN8j.js +1 -0
- package/public/assets/page.B6HgqxIh.js +1 -0
- package/public/assets/page.B9nZj2bM.js +1 -0
- package/public/assets/page.BAjMOHLc.js +6 -0
- package/public/assets/page.BBAy2gwn.js +1 -0
- package/public/assets/page.BFCJJrr_.js +1 -0
- package/public/assets/page.BH4eYGdz.js +1 -0
- package/public/assets/page.BMlo83oM.js +1 -0
- package/public/assets/page.BPMtBhKd.js +1 -0
- package/public/assets/page.BWmMDNX0.js +5 -0
- package/public/assets/page.B_rBjC41.js +1 -0
- package/public/assets/page.Bj0MFcSW.js +1 -0
- package/public/assets/page.Bs99xyvS.js +23 -0
- package/public/assets/page.BuU3QCO4.js +1 -0
- package/public/assets/page.C-4fur3O.js +4 -0
- package/public/assets/page.C0iX9Fnf.js +1 -0
- package/public/assets/page.C0qR8Y5R.js +1 -0
- package/public/assets/page.CAAgcGqN.js +1 -0
- package/public/assets/page.CCTU0LkA.js +1 -0
- package/public/assets/page.CS8il6ZP.js +2 -0
- package/public/assets/page.CTDNnugg.js +1 -0
- package/public/assets/page.CaujBCOC.js +1 -0
- package/public/assets/page.CcYMJEkz.js +2 -0
- package/public/assets/page.CfKwOBap.js +4 -0
- package/public/assets/page.Ct47P4hB.js +1 -0
- package/public/assets/page.CtZhMjzD.js +31 -0
- package/public/assets/page.D6H2uDVR.js +1 -0
- package/public/assets/page.D7rC6efy.js +1 -0
- package/public/assets/page.DCY06u9A.js +5 -0
- package/public/assets/page.DFzXiFFW.js +1 -0
- package/public/assets/page.DOgtsHmp.js +1 -0
- package/public/assets/page.DiFYTx8K.js +1 -0
- package/public/assets/page.Dm8AHdlz.js +1 -0
- package/public/assets/page.QIyytaMO.js +1 -0
- package/public/assets/page.jbj6FFm0.js +6 -0
- package/public/index.html +4 -4
|
@@ -12,25 +12,29 @@
|
|
|
12
12
|
"file": "assets/material-symbols-outlined.B4RtTC4Y.woff2",
|
|
13
13
|
"src": "../node_modules/material-symbols/material-symbols-outlined.woff2"
|
|
14
14
|
},
|
|
15
|
-
"_EndpointPageClient.
|
|
16
|
-
"file": "assets/EndpointPageClient.
|
|
15
|
+
"_EndpointPageClient.B1pL25ws.js": {
|
|
16
|
+
"file": "assets/EndpointPageClient.B1pL25ws.js",
|
|
17
17
|
"name": "EndpointPageClient",
|
|
18
18
|
"imports": [
|
|
19
19
|
"index.html",
|
|
20
20
|
"_router.Cjj1--8t.js",
|
|
21
|
-
"_NoAuthProxyCard.
|
|
22
|
-
"_Loading.
|
|
21
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
22
|
+
"_Loading.C1s7rolj.js"
|
|
23
23
|
]
|
|
24
24
|
},
|
|
25
|
-
"_Loading.
|
|
26
|
-
"file": "assets/Loading.
|
|
25
|
+
"_Loading.C1s7rolj.js": {
|
|
26
|
+
"file": "assets/Loading.C1s7rolj.js",
|
|
27
27
|
"name": "Loading",
|
|
28
28
|
"imports": [
|
|
29
29
|
"index.html"
|
|
30
30
|
]
|
|
31
31
|
},
|
|
32
|
-
"_NoAuthProxyCard.
|
|
33
|
-
"file": "assets/NoAuthProxyCard.
|
|
32
|
+
"_NoAuthProxyCard.C5ap-Sga.css": {
|
|
33
|
+
"file": "assets/NoAuthProxyCard.C5ap-Sga.css",
|
|
34
|
+
"src": "_NoAuthProxyCard.C5ap-Sga.css"
|
|
35
|
+
},
|
|
36
|
+
"_NoAuthProxyCard.CrFQ6U88.js": {
|
|
37
|
+
"file": "assets/NoAuthProxyCard.CrFQ6U88.js",
|
|
34
38
|
"name": "NoAuthProxyCard",
|
|
35
39
|
"imports": [
|
|
36
40
|
"index.html",
|
|
@@ -40,10 +44,6 @@
|
|
|
40
44
|
"assets/NoAuthProxyCard.C5ap-Sga.css"
|
|
41
45
|
]
|
|
42
46
|
},
|
|
43
|
-
"_NoAuthProxyCard.C5ap-Sga.css": {
|
|
44
|
-
"file": "assets/NoAuthProxyCard.C5ap-Sga.css",
|
|
45
|
-
"src": "_NoAuthProxyCard.C5ap-Sga.css"
|
|
46
|
-
},
|
|
47
47
|
"_cliTools.CsdwAybi.js": {
|
|
48
48
|
"file": "assets/cliTools.CsdwAybi.js",
|
|
49
49
|
"name": "cliTools"
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
]
|
|
69
69
|
},
|
|
70
70
|
"index.html": {
|
|
71
|
-
"file": "assets/index.
|
|
71
|
+
"file": "assets/index.2a3mqmx-.js",
|
|
72
72
|
"name": "index",
|
|
73
73
|
"src": "index.html",
|
|
74
74
|
"isEntry": true,
|
|
@@ -116,14 +116,14 @@
|
|
|
116
116
|
"src/pages/update/page.jsx"
|
|
117
117
|
],
|
|
118
118
|
"css": [
|
|
119
|
-
"assets/index.
|
|
119
|
+
"assets/index.Blvwx0HS.css"
|
|
120
120
|
],
|
|
121
121
|
"assets": [
|
|
122
122
|
"assets/material-symbols-outlined.B4RtTC4Y.woff2"
|
|
123
123
|
]
|
|
124
124
|
},
|
|
125
125
|
"src/pages/audio/page.jsx": {
|
|
126
|
-
"file": "assets/page.
|
|
126
|
+
"file": "assets/page.Bj0MFcSW.js",
|
|
127
127
|
"name": "page",
|
|
128
128
|
"src": "src/pages/audio/page.jsx",
|
|
129
129
|
"isDynamicEntry": true,
|
|
@@ -134,7 +134,7 @@
|
|
|
134
134
|
]
|
|
135
135
|
},
|
|
136
136
|
"src/pages/automation/fsmail-tutorial/page.jsx": {
|
|
137
|
-
"file": "assets/page.
|
|
137
|
+
"file": "assets/page.D7rC6efy.js",
|
|
138
138
|
"name": "page",
|
|
139
139
|
"src": "src/pages/automation/fsmail-tutorial/page.jsx",
|
|
140
140
|
"isDynamicEntry": true,
|
|
@@ -145,44 +145,44 @@
|
|
|
145
145
|
]
|
|
146
146
|
},
|
|
147
147
|
"src/pages/automation/page.jsx": {
|
|
148
|
-
"file": "assets/page.
|
|
148
|
+
"file": "assets/page.Bs99xyvS.js",
|
|
149
149
|
"name": "page",
|
|
150
150
|
"src": "src/pages/automation/page.jsx",
|
|
151
151
|
"isDynamicEntry": true,
|
|
152
152
|
"imports": [
|
|
153
153
|
"index.html",
|
|
154
154
|
"_router.Cjj1--8t.js",
|
|
155
|
-
"_NoAuthProxyCard.
|
|
156
|
-
"_Loading.
|
|
155
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
156
|
+
"_Loading.C1s7rolj.js",
|
|
157
157
|
"_zustand.akaTi5uX.js"
|
|
158
158
|
]
|
|
159
159
|
},
|
|
160
160
|
"src/pages/backup-restore/page.jsx": {
|
|
161
|
-
"file": "assets/page.
|
|
161
|
+
"file": "assets/page.C-4fur3O.js",
|
|
162
162
|
"name": "page",
|
|
163
163
|
"src": "src/pages/backup-restore/page.jsx",
|
|
164
164
|
"isDynamicEntry": true,
|
|
165
165
|
"imports": [
|
|
166
166
|
"index.html",
|
|
167
167
|
"_router.Cjj1--8t.js",
|
|
168
|
-
"_NoAuthProxyCard.
|
|
168
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
169
169
|
"_zustand.akaTi5uX.js"
|
|
170
170
|
]
|
|
171
171
|
},
|
|
172
172
|
"src/pages/basic-chat/page.jsx": {
|
|
173
|
-
"file": "assets/page.
|
|
173
|
+
"file": "assets/page.B1WuiJNL.js",
|
|
174
174
|
"name": "page",
|
|
175
175
|
"src": "src/pages/basic-chat/page.jsx",
|
|
176
176
|
"isDynamicEntry": true,
|
|
177
177
|
"imports": [
|
|
178
178
|
"index.html",
|
|
179
179
|
"_router.Cjj1--8t.js",
|
|
180
|
-
"_NoAuthProxyCard.
|
|
180
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
181
181
|
"_zustand.akaTi5uX.js"
|
|
182
182
|
]
|
|
183
183
|
},
|
|
184
184
|
"src/pages/callback/page.jsx": {
|
|
185
|
-
"file": "assets/page.
|
|
185
|
+
"file": "assets/page.CaujBCOC.js",
|
|
186
186
|
"name": "page",
|
|
187
187
|
"src": "src/pages/callback/page.jsx",
|
|
188
188
|
"isDynamicEntry": true,
|
|
@@ -193,7 +193,7 @@
|
|
|
193
193
|
]
|
|
194
194
|
},
|
|
195
195
|
"src/pages/cli-tools/[toolId]/page.jsx": {
|
|
196
|
-
"file": "assets/page.
|
|
196
|
+
"file": "assets/page.CtZhMjzD.js",
|
|
197
197
|
"name": "page",
|
|
198
198
|
"src": "src/pages/cli-tools/[toolId]/page.jsx",
|
|
199
199
|
"isDynamicEntry": true,
|
|
@@ -202,13 +202,13 @@
|
|
|
202
202
|
"_router.Cjj1--8t.js",
|
|
203
203
|
"_cliTools.CsdwAybi.js",
|
|
204
204
|
"_machine.CagOtseJ.js",
|
|
205
|
-
"_NoAuthProxyCard.
|
|
206
|
-
"_Loading.
|
|
205
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
206
|
+
"_Loading.C1s7rolj.js",
|
|
207
207
|
"_zustand.akaTi5uX.js"
|
|
208
208
|
]
|
|
209
209
|
},
|
|
210
210
|
"src/pages/cli-tools/page.jsx": {
|
|
211
|
-
"file": "assets/page.
|
|
211
|
+
"file": "assets/page.CAAgcGqN.js",
|
|
212
212
|
"name": "page",
|
|
213
213
|
"src": "src/pages/cli-tools/page.jsx",
|
|
214
214
|
"isDynamicEntry": true,
|
|
@@ -216,39 +216,39 @@
|
|
|
216
216
|
"index.html",
|
|
217
217
|
"_router.Cjj1--8t.js",
|
|
218
218
|
"_machine.CagOtseJ.js",
|
|
219
|
-
"_NoAuthProxyCard.
|
|
220
|
-
"_Loading.
|
|
219
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
220
|
+
"_Loading.C1s7rolj.js",
|
|
221
221
|
"_cliTools.CsdwAybi.js",
|
|
222
222
|
"_zustand.akaTi5uX.js"
|
|
223
223
|
]
|
|
224
224
|
},
|
|
225
225
|
"src/pages/combos/page.jsx": {
|
|
226
|
-
"file": "assets/page.
|
|
226
|
+
"file": "assets/page.DCY06u9A.js",
|
|
227
227
|
"name": "page",
|
|
228
228
|
"src": "src/pages/combos/page.jsx",
|
|
229
229
|
"isDynamicEntry": true,
|
|
230
230
|
"imports": [
|
|
231
231
|
"index.html",
|
|
232
232
|
"_router.Cjj1--8t.js",
|
|
233
|
-
"_NoAuthProxyCard.
|
|
234
|
-
"_Loading.
|
|
233
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
234
|
+
"_Loading.C1s7rolj.js",
|
|
235
235
|
"_zustand.akaTi5uX.js"
|
|
236
236
|
]
|
|
237
237
|
},
|
|
238
238
|
"src/pages/console-log/page.jsx": {
|
|
239
|
-
"file": "assets/page.
|
|
239
|
+
"file": "assets/page.CCTU0LkA.js",
|
|
240
240
|
"name": "page",
|
|
241
241
|
"src": "src/pages/console-log/page.jsx",
|
|
242
242
|
"isDynamicEntry": true,
|
|
243
243
|
"imports": [
|
|
244
244
|
"index.html",
|
|
245
245
|
"_router.Cjj1--8t.js",
|
|
246
|
-
"_NoAuthProxyCard.
|
|
246
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
247
247
|
"_zustand.akaTi5uX.js"
|
|
248
248
|
]
|
|
249
249
|
},
|
|
250
250
|
"src/pages/docs/page.jsx": {
|
|
251
|
-
"file": "assets/page.
|
|
251
|
+
"file": "assets/page.C0qR8Y5R.js",
|
|
252
252
|
"name": "page",
|
|
253
253
|
"src": "src/pages/docs/page.jsx",
|
|
254
254
|
"isDynamicEntry": true,
|
|
@@ -259,7 +259,7 @@
|
|
|
259
259
|
]
|
|
260
260
|
},
|
|
261
261
|
"src/pages/endpoint/page.jsx": {
|
|
262
|
-
"file": "assets/page.
|
|
262
|
+
"file": "assets/page.DOgtsHmp.js",
|
|
263
263
|
"name": "page",
|
|
264
264
|
"src": "src/pages/endpoint/page.jsx",
|
|
265
265
|
"isDynamicEntry": true,
|
|
@@ -267,14 +267,14 @@
|
|
|
267
267
|
"index.html",
|
|
268
268
|
"_router.Cjj1--8t.js",
|
|
269
269
|
"_machine.CagOtseJ.js",
|
|
270
|
-
"_EndpointPageClient.
|
|
270
|
+
"_EndpointPageClient.B1pL25ws.js",
|
|
271
271
|
"_zustand.akaTi5uX.js",
|
|
272
|
-
"_NoAuthProxyCard.
|
|
273
|
-
"_Loading.
|
|
272
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
273
|
+
"_Loading.C1s7rolj.js"
|
|
274
274
|
]
|
|
275
275
|
},
|
|
276
276
|
"src/pages/landing/page.jsx": {
|
|
277
|
-
"file": "assets/page.
|
|
277
|
+
"file": "assets/page.QIyytaMO.js",
|
|
278
278
|
"name": "page",
|
|
279
279
|
"src": "src/pages/landing/page.jsx",
|
|
280
280
|
"isDynamicEntry": true,
|
|
@@ -285,7 +285,7 @@
|
|
|
285
285
|
]
|
|
286
286
|
},
|
|
287
287
|
"src/pages/login/page.tsx": {
|
|
288
|
-
"file": "assets/page.
|
|
288
|
+
"file": "assets/page.B6HgqxIh.js",
|
|
289
289
|
"name": "page",
|
|
290
290
|
"src": "src/pages/login/page.tsx",
|
|
291
291
|
"isDynamicEntry": true,
|
|
@@ -296,55 +296,55 @@
|
|
|
296
296
|
]
|
|
297
297
|
},
|
|
298
298
|
"src/pages/media-providers/[kind]/[id]/page.jsx": {
|
|
299
|
-
"file": "assets/page.
|
|
299
|
+
"file": "assets/page.1w2ClxJa.js",
|
|
300
300
|
"name": "page",
|
|
301
301
|
"src": "src/pages/media-providers/[kind]/[id]/page.jsx",
|
|
302
302
|
"isDynamicEntry": true,
|
|
303
303
|
"imports": [
|
|
304
304
|
"index.html",
|
|
305
305
|
"_router.Cjj1--8t.js",
|
|
306
|
-
"_NoAuthProxyCard.
|
|
306
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
307
307
|
"_zustand.akaTi5uX.js"
|
|
308
308
|
]
|
|
309
309
|
},
|
|
310
310
|
"src/pages/media-providers/[kind]/page.jsx": {
|
|
311
|
-
"file": "assets/page.
|
|
311
|
+
"file": "assets/page.DFzXiFFW.js",
|
|
312
312
|
"name": "page",
|
|
313
313
|
"src": "src/pages/media-providers/[kind]/page.jsx",
|
|
314
314
|
"isDynamicEntry": true,
|
|
315
315
|
"imports": [
|
|
316
316
|
"index.html",
|
|
317
317
|
"_router.Cjj1--8t.js",
|
|
318
|
-
"_NoAuthProxyCard.
|
|
318
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
319
319
|
"_zustand.akaTi5uX.js"
|
|
320
320
|
]
|
|
321
321
|
},
|
|
322
322
|
"src/pages/media-providers/combo/[id]/page.jsx": {
|
|
323
|
-
"file": "assets/page.
|
|
323
|
+
"file": "assets/page.BWmMDNX0.js",
|
|
324
324
|
"name": "page",
|
|
325
325
|
"src": "src/pages/media-providers/combo/[id]/page.jsx",
|
|
326
326
|
"isDynamicEntry": true,
|
|
327
327
|
"imports": [
|
|
328
328
|
"index.html",
|
|
329
329
|
"_router.Cjj1--8t.js",
|
|
330
|
-
"_NoAuthProxyCard.
|
|
330
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
331
331
|
"_zustand.akaTi5uX.js"
|
|
332
332
|
]
|
|
333
333
|
},
|
|
334
334
|
"src/pages/media-providers/web/page.jsx": {
|
|
335
|
-
"file": "assets/page.
|
|
335
|
+
"file": "assets/page.DiFYTx8K.js",
|
|
336
336
|
"name": "page",
|
|
337
337
|
"src": "src/pages/media-providers/web/page.jsx",
|
|
338
338
|
"isDynamicEntry": true,
|
|
339
339
|
"imports": [
|
|
340
340
|
"index.html",
|
|
341
341
|
"_router.Cjj1--8t.js",
|
|
342
|
-
"_NoAuthProxyCard.
|
|
342
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
343
343
|
"_zustand.akaTi5uX.js"
|
|
344
344
|
]
|
|
345
345
|
},
|
|
346
346
|
"src/pages/mitm/page.jsx": {
|
|
347
|
-
"file": "assets/page.
|
|
347
|
+
"file": "assets/page.CTDNnugg.js",
|
|
348
348
|
"name": "page",
|
|
349
349
|
"src": "src/pages/mitm/page.jsx",
|
|
350
350
|
"isDynamicEntry": true,
|
|
@@ -352,24 +352,24 @@
|
|
|
352
352
|
"index.html",
|
|
353
353
|
"_router.Cjj1--8t.js",
|
|
354
354
|
"_cliTools.CsdwAybi.js",
|
|
355
|
-
"_NoAuthProxyCard.
|
|
355
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
356
356
|
"_zustand.akaTi5uX.js"
|
|
357
357
|
]
|
|
358
358
|
},
|
|
359
359
|
"src/pages/moderations/page.jsx": {
|
|
360
|
-
"file": "assets/page.
|
|
360
|
+
"file": "assets/page.B_rBjC41.js",
|
|
361
361
|
"name": "page",
|
|
362
362
|
"src": "src/pages/moderations/page.jsx",
|
|
363
363
|
"isDynamicEntry": true,
|
|
364
364
|
"imports": [
|
|
365
365
|
"index.html",
|
|
366
366
|
"_router.Cjj1--8t.js",
|
|
367
|
-
"_Loading.
|
|
367
|
+
"_Loading.C1s7rolj.js",
|
|
368
368
|
"_zustand.akaTi5uX.js"
|
|
369
369
|
]
|
|
370
370
|
},
|
|
371
371
|
"src/pages/ocr/page.jsx": {
|
|
372
|
-
"file": "assets/page.
|
|
372
|
+
"file": "assets/page.Ct47P4hB.js",
|
|
373
373
|
"name": "page",
|
|
374
374
|
"src": "src/pages/ocr/page.jsx",
|
|
375
375
|
"isDynamicEntry": true,
|
|
@@ -380,7 +380,7 @@
|
|
|
380
380
|
]
|
|
381
381
|
},
|
|
382
382
|
"src/pages/page.jsx": {
|
|
383
|
-
"file": "assets/page.
|
|
383
|
+
"file": "assets/page.Dm8AHdlz.js",
|
|
384
384
|
"name": "page",
|
|
385
385
|
"src": "src/pages/page.jsx",
|
|
386
386
|
"isDynamicEntry": true,
|
|
@@ -388,64 +388,64 @@
|
|
|
388
388
|
"index.html",
|
|
389
389
|
"_router.Cjj1--8t.js",
|
|
390
390
|
"_machine.CagOtseJ.js",
|
|
391
|
-
"_EndpointPageClient.
|
|
391
|
+
"_EndpointPageClient.B1pL25ws.js",
|
|
392
392
|
"_zustand.akaTi5uX.js",
|
|
393
|
-
"_NoAuthProxyCard.
|
|
394
|
-
"_Loading.
|
|
393
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
394
|
+
"_Loading.C1s7rolj.js"
|
|
395
395
|
]
|
|
396
396
|
},
|
|
397
397
|
"src/pages/profile/page.jsx": {
|
|
398
|
-
"file": "assets/page.
|
|
398
|
+
"file": "assets/page.BMlo83oM.js",
|
|
399
399
|
"name": "page",
|
|
400
400
|
"src": "src/pages/profile/page.jsx",
|
|
401
401
|
"isDynamicEntry": true,
|
|
402
402
|
"imports": [
|
|
403
403
|
"index.html",
|
|
404
404
|
"_router.Cjj1--8t.js",
|
|
405
|
-
"_NoAuthProxyCard.
|
|
405
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
406
406
|
"_zustand.akaTi5uX.js"
|
|
407
407
|
]
|
|
408
408
|
},
|
|
409
409
|
"src/pages/providers/[id]/page.jsx": {
|
|
410
|
-
"file": "assets/page.
|
|
410
|
+
"file": "assets/page.CfKwOBap.js",
|
|
411
411
|
"name": "page",
|
|
412
412
|
"src": "src/pages/providers/[id]/page.jsx",
|
|
413
413
|
"isDynamicEntry": true,
|
|
414
414
|
"imports": [
|
|
415
415
|
"index.html",
|
|
416
416
|
"_router.Cjj1--8t.js",
|
|
417
|
-
"_NoAuthProxyCard.
|
|
418
|
-
"_Loading.
|
|
417
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
418
|
+
"_Loading.C1s7rolj.js",
|
|
419
419
|
"_zustand.akaTi5uX.js"
|
|
420
420
|
]
|
|
421
421
|
},
|
|
422
422
|
"src/pages/providers/new/page.jsx": {
|
|
423
|
-
"file": "assets/page.
|
|
423
|
+
"file": "assets/page.B5pzcN8j.js",
|
|
424
424
|
"name": "page",
|
|
425
425
|
"src": "src/pages/providers/new/page.jsx",
|
|
426
426
|
"isDynamicEntry": true,
|
|
427
427
|
"imports": [
|
|
428
428
|
"index.html",
|
|
429
429
|
"_router.Cjj1--8t.js",
|
|
430
|
-
"_NoAuthProxyCard.
|
|
430
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
431
431
|
"_zustand.akaTi5uX.js"
|
|
432
432
|
]
|
|
433
433
|
},
|
|
434
434
|
"src/pages/providers/page.jsx": {
|
|
435
|
-
"file": "assets/page.
|
|
435
|
+
"file": "assets/page.BH4eYGdz.js",
|
|
436
436
|
"name": "page",
|
|
437
437
|
"src": "src/pages/providers/page.jsx",
|
|
438
438
|
"isDynamicEntry": true,
|
|
439
439
|
"imports": [
|
|
440
440
|
"index.html",
|
|
441
441
|
"_router.Cjj1--8t.js",
|
|
442
|
-
"_NoAuthProxyCard.
|
|
443
|
-
"_Loading.
|
|
442
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
443
|
+
"_Loading.C1s7rolj.js",
|
|
444
444
|
"_zustand.akaTi5uX.js"
|
|
445
445
|
]
|
|
446
446
|
},
|
|
447
447
|
"src/pages/providers/weavy/pool/page.jsx": {
|
|
448
|
-
"file": "assets/page.
|
|
448
|
+
"file": "assets/page.jbj6FFm0.js",
|
|
449
449
|
"name": "page",
|
|
450
450
|
"src": "src/pages/providers/weavy/pool/page.jsx",
|
|
451
451
|
"isDynamicEntry": true,
|
|
@@ -456,33 +456,33 @@
|
|
|
456
456
|
]
|
|
457
457
|
},
|
|
458
458
|
"src/pages/proxy-pools/page.jsx": {
|
|
459
|
-
"file": "assets/page.
|
|
459
|
+
"file": "assets/page.BAjMOHLc.js",
|
|
460
460
|
"name": "page",
|
|
461
461
|
"src": "src/pages/proxy-pools/page.jsx",
|
|
462
462
|
"isDynamicEntry": true,
|
|
463
463
|
"imports": [
|
|
464
464
|
"index.html",
|
|
465
465
|
"_router.Cjj1--8t.js",
|
|
466
|
-
"_NoAuthProxyCard.
|
|
467
|
-
"_Loading.
|
|
466
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
467
|
+
"_Loading.C1s7rolj.js",
|
|
468
468
|
"_zustand.akaTi5uX.js"
|
|
469
469
|
]
|
|
470
470
|
},
|
|
471
471
|
"src/pages/quota/page.jsx": {
|
|
472
|
-
"file": "assets/page.
|
|
472
|
+
"file": "assets/page.D6H2uDVR.js",
|
|
473
473
|
"name": "page",
|
|
474
474
|
"src": "src/pages/quota/page.jsx",
|
|
475
475
|
"isDynamicEntry": true,
|
|
476
476
|
"imports": [
|
|
477
477
|
"index.html",
|
|
478
478
|
"_router.Cjj1--8t.js",
|
|
479
|
-
"_Loading.
|
|
480
|
-
"_NoAuthProxyCard.
|
|
479
|
+
"_Loading.C1s7rolj.js",
|
|
480
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
481
481
|
"_zustand.akaTi5uX.js"
|
|
482
482
|
]
|
|
483
483
|
},
|
|
484
484
|
"src/pages/rerank/page.jsx": {
|
|
485
|
-
"file": "assets/page.
|
|
485
|
+
"file": "assets/page.CcYMJEkz.js",
|
|
486
486
|
"name": "page",
|
|
487
487
|
"src": "src/pages/rerank/page.jsx",
|
|
488
488
|
"isDynamicEntry": true,
|
|
@@ -493,50 +493,50 @@
|
|
|
493
493
|
]
|
|
494
494
|
},
|
|
495
495
|
"src/pages/search/page.jsx": {
|
|
496
|
-
"file": "assets/page.
|
|
496
|
+
"file": "assets/page.C0iX9Fnf.js",
|
|
497
497
|
"name": "page",
|
|
498
498
|
"src": "src/pages/search/page.jsx",
|
|
499
499
|
"isDynamicEntry": true,
|
|
500
500
|
"imports": [
|
|
501
501
|
"index.html",
|
|
502
502
|
"_router.Cjj1--8t.js",
|
|
503
|
-
"_Loading.
|
|
503
|
+
"_Loading.C1s7rolj.js",
|
|
504
504
|
"_zustand.akaTi5uX.js"
|
|
505
505
|
]
|
|
506
506
|
},
|
|
507
507
|
"src/pages/skills/page.jsx": {
|
|
508
|
-
"file": "assets/page.
|
|
508
|
+
"file": "assets/page.BBAy2gwn.js",
|
|
509
509
|
"name": "page",
|
|
510
510
|
"src": "src/pages/skills/page.jsx",
|
|
511
511
|
"isDynamicEntry": true,
|
|
512
512
|
"imports": [
|
|
513
513
|
"index.html",
|
|
514
|
-
"_NoAuthProxyCard.
|
|
514
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
515
515
|
"_router.Cjj1--8t.js",
|
|
516
516
|
"_zustand.akaTi5uX.js"
|
|
517
517
|
]
|
|
518
518
|
},
|
|
519
519
|
"src/pages/token-saver/page.jsx": {
|
|
520
|
-
"file": "assets/page.
|
|
520
|
+
"file": "assets/page.BuU3QCO4.js",
|
|
521
521
|
"name": "page",
|
|
522
522
|
"src": "src/pages/token-saver/page.jsx",
|
|
523
523
|
"isDynamicEntry": true,
|
|
524
524
|
"imports": [
|
|
525
525
|
"index.html",
|
|
526
526
|
"_router.Cjj1--8t.js",
|
|
527
|
-
"_NoAuthProxyCard.
|
|
527
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
528
528
|
"_zustand.akaTi5uX.js"
|
|
529
529
|
]
|
|
530
530
|
},
|
|
531
531
|
"src/pages/translator/page.jsx": {
|
|
532
|
-
"file": "assets/page.
|
|
532
|
+
"file": "assets/page.CS8il6ZP.js",
|
|
533
533
|
"name": "page",
|
|
534
534
|
"src": "src/pages/translator/page.jsx",
|
|
535
535
|
"isDynamicEntry": true,
|
|
536
536
|
"imports": [
|
|
537
537
|
"index.html",
|
|
538
538
|
"_router.Cjj1--8t.js",
|
|
539
|
-
"_NoAuthProxyCard.
|
|
539
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
540
540
|
"_zustand.akaTi5uX.js"
|
|
541
541
|
],
|
|
542
542
|
"dynamicImports": [
|
|
@@ -544,7 +544,7 @@
|
|
|
544
544
|
]
|
|
545
545
|
},
|
|
546
546
|
"src/pages/update/page.jsx": {
|
|
547
|
-
"file": "assets/page.
|
|
547
|
+
"file": "assets/page.BPMtBhKd.js",
|
|
548
548
|
"name": "page",
|
|
549
549
|
"src": "src/pages/update/page.jsx",
|
|
550
550
|
"isDynamicEntry": true,
|
|
@@ -555,20 +555,20 @@
|
|
|
555
555
|
]
|
|
556
556
|
},
|
|
557
557
|
"src/pages/usage/page.jsx": {
|
|
558
|
-
"file": "assets/page.
|
|
558
|
+
"file": "assets/page.B9nZj2bM.js",
|
|
559
559
|
"name": "page",
|
|
560
560
|
"src": "src/pages/usage/page.jsx",
|
|
561
561
|
"isDynamicEntry": true,
|
|
562
562
|
"imports": [
|
|
563
563
|
"index.html",
|
|
564
564
|
"_router.Cjj1--8t.js",
|
|
565
|
-
"_NoAuthProxyCard.
|
|
566
|
-
"_Loading.
|
|
565
|
+
"_NoAuthProxyCard.CrFQ6U88.js",
|
|
566
|
+
"_Loading.C1s7rolj.js",
|
|
567
567
|
"_zustand.akaTi5uX.js"
|
|
568
568
|
]
|
|
569
569
|
},
|
|
570
570
|
"src/pages/webfetch/page.jsx": {
|
|
571
|
-
"file": "assets/page.
|
|
571
|
+
"file": "assets/page.BFCJJrr_.js",
|
|
572
572
|
"name": "page",
|
|
573
573
|
"src": "src/pages/webfetch/page.jsx",
|
|
574
574
|
"isDynamicEntry": true,
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import{r as ct,v as rs,u as is,j as e,B as c,M as $,C as os,f as cs}from"./index.2a3mqmx-.js";import{b as s}from"./router.Cjj1--8t.js";import{C as dt,I as te,T as Me}from"./NoAuthProxyCard.CrFQ6U88.js";import{C as ut}from"./Loading.C1s7rolj.js";const ds=["zh-CN","zh-TW"],us=[{icon:"public",title:"Access Anywhere",desc:"Use your API from any network"},{icon:"group",title:"Share Endpoint",desc:"Share URL with team members"},{icon:"code",title:"Use in Cursor/Cline",desc:"Connect AI tools remotely"},{icon:"lock",title:"Encrypted",desc:"End-to-end TLS via Cloudflare"}],He=2e3,mt=3e5,ms=5e3,Fe=5,hs=1e4,xs=5e3;async function ht(h){if(!h)return!1;try{return(await fetch(`${h}/api/health`,{mode:"cors",cache:"no-store",signal:AbortSignal.timeout(xs)})).ok}catch{return!1}}async function ps(...h){const d=h.filter(Boolean).map(ht);return d.length?new Promise(x=>{let j=d.length;d.forEach(U=>U.then(b=>{b?x(!0):--j===0&&x(!1)}))}):!1}const Ke=[{id:"lite",label:"Lite",desc:"Drop filler, keep grammar"},{id:"full",label:"Full",desc:"Drop articles, fragments OK"},{id:"ultra",label:"Ultra",desc:"Telegraphic, max compression"},{id:"wenyan-lite",label:"文 Lite",desc:"Classical Chinese, light compression",wenyan:!0},{id:"wenyan",label:"文 Full",desc:"Maximum 文言文, 80-90% reduction",wenyan:!0},{id:"wenyan-ultra",label:"文 Ultra",desc:"Extreme classical compression",wenyan:!0}];function fs({machineId:h}){const[d,x]=s.useState([]),[j,U]=s.useState(!0),[b,N]=s.useState(!1),[se,ae]=s.useState(""),[je,we]=s.useState(null),[w,z]=s.useState(null),[ne,We]=s.useState(!1),[B,xt]=s.useState(!0),[qe,pt]=s.useState(!0),[$e,ze]=s.useState(!1),[js,ft]=s.useState(!0),[ws,gt]=s.useState(!1),[Be,Ve]=s.useState("full"),[vs,bt]=s.useState(!1),[Je,Ge]=s.useState(""),[ks,yt]=s.useState(!1),[L,ve]=s.useState({installed:!1,running:!1,python:null,loading:!0}),[Ns,Cs]=s.useState(!1),[Ts,le]=s.useState(!1),[Ss,Xe]=s.useState(""),[Es,jt]=s.useState(!1),[Ps,wt]=s.useState("full"),[_s,vt]=s.useState(!1),[As,kt]=s.useState("full"),[Nt,Ye]=s.useState("en"),[Ct,ke]=s.useState(!0),[p,re]=s.useState(!1),[R,ie]=s.useState(!1),[I,oe]=s.useState(""),[D,Ne]=s.useState(""),[P,C]=s.useState(!1),[Tt,T]=s.useState(""),[ce,v]=s.useState(null),[St,V]=s.useState(!1),[Et,J]=s.useState(!1),[f,O]=s.useState(!1),[M,de]=s.useState(!1),[H,F]=s.useState(""),[_,G]=s.useState(!1),[Pt,A]=s.useState(""),[K,u]=s.useState(null),[Qe,Ze]=s.useState(""),[_t,et]=s.useState(""),[Ce,ue]=s.useState(null),[me,Te]=s.useState(!1),[Se,Ee]=s.useState([]),[At,tt]=s.useState(""),[Ut,Pe]=s.useState(!1),[Lt,W]=s.useState(!1),[Rt,X]=s.useState(!1),he=s.useRef(null),Y=s.useRef(0),Q=s.useRef(0),xe=s.useRef(!1),pe=s.useRef(!1),fe=s.useRef(!1),ge=s.useRef(!1),[It,_e]=s.useState(!1),[Dt,Ae]=s.useState(!1),[Ue,st]=s.useState(new Set),[Ot,Mt]=s.useState(!1);s.useEffect(()=>{typeof window<"u"&&Mt(!["localhost","127.0.0.1","::1"].includes(window.location.hostname))},[]),s.useEffect(()=>(Ye(ct()),rs(()=>Ye(ct()))),[]);const Le=ds.includes(Nt);Le||Ke.filter(t=>!t.wenyan),s.useEffect(()=>{const t=Ke.find(a=>a.id===Be);t!=null&&t.wenyan&&!Le&&(Ve("ultra"),$t({cavemanLevel:"ultra"}))},[Le,Be]);const{copied:q,copy:Z}=is(),Ht=!B||!qe,Ft=B?"Change the default dashboard password before activating the tunnel.":'Enable "Require login" and set a custom password before activating the tunnel.';s.useEffect(()=>{he.current&&(he.current.scrollTop=he.current.scrollHeight)},[Se]),s.useEffect(()=>{nt(),Kt()},[]),s.useEffect(()=>{if(!(p||f))return;const n=(!p||R)&&(!f||M),r=()=>{document.hidden||at()};if(document.addEventListener("visibilitychange",r),n)return()=>document.removeEventListener("visibilitychange",r);const o=setInterval(()=>{document.hidden||at()},ms);return()=>{clearInterval(o),document.removeEventListener("visibilitychange",r)}},[p,f,R,M]),s.useEffect(()=>{const t=async()=>{if(!document.hidden){if(p&&(I||D)){const o=await ps(D,I);xe.current=o,o?(Y.current=0,ie(!0),fe.current||(fe.current=!0,_e(!0))):(Y.current+=1,Y.current>=Fe&&ie(!1))}else xe.current=!1;if(f&&H){const o=await ht(H);pe.current=o,o?(Q.current=0,de(!0),ge.current||(ge.current=!0,Ae(!0))):(Q.current+=1,Q.current>=Fe&&de(!1))}else pe.current=!1}};if(!(p&&(I||D)||f&&H)||(t(),(!p||R)&&(!f||M)))return;const r=setInterval(t,hs);return()=>clearInterval(r)},[p,I,D,f,H,R,M]);const be=s.useCallback((t,a,l,n,r,o)=>{a.current?(l.current=0,n(!0),r.current||(r.current=!0,o(!0))):(l.current+=1,l.current>=Fe&&n(!1))},[]),at=async()=>{var t,a,l,n,r,o,m;try{const y=await fetch("/api/tunnel/status",{cache:"no-store"});if(!y.ok)return;const g=await y.json(),i=((t=g.tunnel)==null?void 0:t.settingsEnabled)??((a=g.tunnel)==null?void 0:a.enabled)??!1,E=((l=g.tunnel)==null?void 0:l.tunnelUrl)||"";oe(E),Ne(((n=g.tunnel)==null?void 0:n.publicUrl)||""),re(i),be(null,xe,Y,ie,fe,_e);const k=((r=g.tailscale)==null?void 0:r.settingsEnabled)??((o=g.tailscale)==null?void 0:o.enabled)??!1,Oe=((m=g.tailscale)==null?void 0:m.tunnelUrl)||"";F(Oe),O(k),be(null,pe,Q,de,ge,Ae)}catch{}},Kt=async()=>{var t,a,l,n,r,o,m;ke(!0);try{const[y,g]=await Promise.all([fetch("/api/settings"),fetch("/api/tunnel/status",{cache:"no-store"})]);if(y.ok){const i=await y.json();We(i.requireApiKey||!1),xt(i.requireLogin!==!1),pt(i.hasPassword||!1),ze(i.tunnelDashboardAccess||!1),ft(i.rtkEnabled!==!1),gt(!!i.cavemanEnabled),Ve(i.cavemanLevel||"full"),bt(!!i.headroomEnabled),Ge(i.headroomUrl||""),yt(!!i.headroomCompressUserMessages),jt(!!i.ponytailEnabled),wt(i.ponytailLevel||"full"),vt(!!i.paleoEnabled),kt(i.paleoLevel||"full"),ee()}if(g.ok){const i=await g.json(),E=((t=i.tunnel)==null?void 0:t.settingsEnabled)??((a=i.tunnel)==null?void 0:a.enabled)??!1,k=((l=i.tunnel)==null?void 0:l.tunnelUrl)||"";oe(k),Ne(((n=i.tunnel)==null?void 0:n.publicUrl)||""),re(E),be(null,xe,Y,ie,fe,_e);const Oe=((r=i.tailscale)==null?void 0:r.settingsEnabled)??((o=i.tailscale)==null?void 0:o.enabled)??!1,ls=((m=i.tailscale)==null?void 0:m.tunnelUrl)||"";F(ls),O(Oe),be(null,pe,Q,de,ge,Ae)}}catch(y){console.log("Error loading settings:",y)}finally{ke(!1)}},Wt=async t=>{try{(await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({tunnelDashboardAccess:t})})).ok&&ze(t)}catch(a){console.log("Error updating tunnelDashboardAccess:",a)}},qt=async t=>{try{(await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({requireApiKey:t})})).ok&&We(t)}catch(a){console.log("Error updating requireApiKey:",a)}},$t=async t=>{try{await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)})}catch(a){console.log("Error updating setting:",a)}},ee=s.useCallback(async()=>{ve(t=>({...t,loading:!0}));try{const a=await(await fetch("/api/headroom/status",{headers:{"Cache-Control":"no-store"}})).json();ve({...a,loading:!1}),a.url&&!Je&&Ge(a.url)}catch{ve({installed:!1,running:!1,python:null,loading:!1})}},[Je]);s.useCallback(async()=>{Xe(""),le(!0);try{const t=await fetch("/api/headroom/start",{method:"POST"}),a=await t.json().catch(()=>({}));if(!t.ok)throw new Error(a.error||"Failed to start proxy");await ee()}catch(t){Xe(t.message)}finally{le(!1)}},[ee]),s.useCallback(async()=>{le(!0);try{await fetch("/api/headroom/stop",{method:"POST"}),await ee()}finally{le(!1)}},[ee]);const nt=async()=>{try{const t=await fetch("/api/keys"),a=await t.json();t.ok&&x(a.keys||[])}catch(t){console.log("Error fetching data:",t)}finally{U(!1)}},zt=async(...t)=>{var n;C(!0),T("Waiting for tunnel ready...");const a=t.filter(Boolean).map(r=>`${r}/api/health`),l=Date.now();for(;Date.now()-l<mt;){if(await new Promise(o=>setTimeout(o,He)),await Promise.any(a.map(async o=>{if((await fetch(o,{mode:"cors",cache:"no-store"})).ok)return!0;throw new Error("not ready")})).catch(()=>!1))return re(!0),C(!1),T(""),!0;if((Date.now()-l)%1e4<He)try{const o=await fetch("/api/tunnel/status");if(o.ok&&!((n=(await o.json()).tunnel)!=null&&n.enabled))return v({type:"error",message:"Tunnel process stopped unexpectedly."}),C(!1),T(""),!1}catch{}}return v({type:"error",message:"Tunnel created but not reachable. Please try again."}),C(!1),T(""),!1},Bt=async()=>{V(!1),C(!0),v(null),T("Creating tunnel...");let t=!0;(async()=>{var l;for(;t;){try{const n=await fetch("/api/tunnel/status");if(n.ok){const r=await n.json();(l=r.download)!=null&&l.downloading?T(`Downloading cloudflared... ${r.download.progress}%`):t&&T("Creating tunnel...")}}catch{}await new Promise(n=>setTimeout(n,1e3))}})();try{const l=await fetch("/api/tunnel/enable",{method:"POST"});t=!1;const n=await l.json();if(!l.ok){v({type:"error",message:n.error||"Failed to enable tunnel"});return}const r=n.tunnelUrl;if(!r){v({type:"error",message:"No tunnel URL returned"});return}oe(r),Ne(n.publicUrl||""),await zt(n.publicUrl,r)}catch(l){v({type:"error",message:l.message})}finally{t=!1,C(!1),T("")}},Vt=async()=>{C(!0),v(null);try{const t=await fetch("/api/tunnel/disable",{method:"POST"}),a=await t.json();t.ok?(re(!1),oe(""),J(!1),v({type:"success",message:"Tunnel disabled"})):v({type:"error",message:a.error||"Failed to disable tunnel"})}catch(t){v({type:"error",message:t.message})}finally{C(!1)}},Jt=async()=>{ue(null);try{const t=await fetch("/api/tunnel/tailscale-check");if(t.ok){const a=await t.json();return ue(a.installed),a}}catch{}return ue(!1),{installed:!1}},Gt=async()=>{Te(!0),u(null),Ee([]);try{const t=await fetch("/api/tunnel/tailscale-install",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sudoPassword:At})});tt("");const a=t.body.getReader(),l=new TextDecoder;let n="";for(;;){const{done:r,value:o}=await a.read();if(r)break;n+=l.decode(o,{stream:!0});const m=n.split(`
|
|
2
|
+
|
|
3
|
+
`);n=m.pop()||"";for(const y of m){const g=y.split(`
|
|
4
|
+
`);let i="progress",E=null;for(const k of g)if(k.startsWith("event: ")&&(i=k.slice(7).trim()),k.startsWith("data: "))try{E=JSON.parse(k.slice(6))}catch{}if(E)if(i==="progress")Ee(k=>[...k.slice(-50),E.message]);else if(i==="done"){ue(!0),Te(!1),W(!1),Ie();return}else i==="error"&&u({type:"error",message:E.error||"Install failed"})}}}catch(t){u({type:"error",message:t.message})}finally{Te(!1)}},Re=async t=>{A("Waiting for Tailscale ready...");const a=`${t}/api/health`,l=Date.now();for(;Date.now()-l<mt;){await new Promise(n=>setTimeout(n,He));try{const n=await fetch(a,{mode:"no-cors",cache:"no-store"});if(n.ok||n.type==="opaque")return!0}catch{}}return!1},lt=(t,a)=>{Ze(t),et(a)},S=()=>{Ze(""),et("")},Ie=async()=>{W(!1),Pe(!0),G(!0),u(null),A("Connecting..."),S();try{const t=await fetch("/api/tunnel/tailscale-enable",{method:"POST"}),a=await t.json();if(t.ok&&a.success){F(a.tunnelUrl||"");const l=await Re(a.tunnelUrl);O(!0),u(l?null:{type:"warning",message:"Connected but not reachable yet."});return}if(a.needsLogin&&a.authUrl){lt(a.authUrl,"Open Login Page"),A('Login required — click "Open Login Page" to continue');for(let l=0;l<40;l++){await new Promise(n=>setTimeout(n,3e3));try{const n=await fetch("/api/tunnel/tailscale-check");if(n.ok&&(await n.json()).loggedIn){S(),A("Starting funnel...");const o=await fetch("/api/tunnel/tailscale-enable",{method:"POST"}),m=await o.json();if(o.ok&&m.success){F(m.tunnelUrl||"");const y=await Re(m.tunnelUrl);O(!0),u(y?null:{type:"warning",message:"Connected but not reachable yet."})}else m.funnelNotEnabled&&m.enableUrl?await rt(m.enableUrl):u({type:"error",message:m.error||"Failed to start funnel"});return}}catch{}}S(),u({type:"error",message:"Login timed out. Please try again."});return}if(a.funnelNotEnabled&&a.enableUrl){await rt(a.enableUrl);return}u({type:"error",message:a.error||"Failed to connect"})}catch(t){u({type:"error",message:t.message})}finally{G(!1),Pe(!1),A(""),S()}},rt=async t=>{lt(t,"Open Funnel Settings"),A('Click "Open Funnel Settings" to enable Funnel...');for(let a=0;a<40;a++){await new Promise(l=>setTimeout(l,3e3));try{const l=await fetch("/api/tunnel/tailscale-enable",{method:"POST"}),n=await l.json();if(l.ok&&n.success){S(),F(n.tunnelUrl||"");const r=await Re(n.tunnelUrl);O(!0),u(r?null:{type:"warning",message:"Connected but not reachable yet."});return}if(n.funnelNotEnabled)continue;if(n.error){S(),u({type:"error",message:n.error});return}}catch{}}S(),u({type:"error",message:"Timed out waiting for Funnel to be enabled."})},Xt=async()=>{G(!0),u(null);try{const t=await fetch("/api/tunnel/tailscale-disable",{method:"POST"}),a=await t.json();t.ok?(O(!1),F(""),X(!1),u({type:"success",message:"Tailscale disabled"})):u({type:"error",message:a.error||"Failed to disable Tailscale"})}catch(t){u({type:"error",message:t.message})}finally{G(!1)}},it=async()=>{u(null),Ee([]);const t=await Jt();t!=null&&t.installed&&(t!=null&&t.hasCachedPassword)?Ie():W(!0)},Yt=async()=>{if(se.trim())try{const t=await fetch("/api/keys",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:se})}),a=await t.json();t.ok&&(we(a.key),await nt(),ae(""),N(!1))}catch(t){console.log("Error creating key:",t)}},Qt=async t=>{z({title:"Delete API Key",message:"Delete this API key?",onConfirm:async()=>{z(null);try{(await fetch(`/api/keys/${t}`,{method:"DELETE"})).ok&&(x(d.filter(l=>l.id!==t)),st(l=>{const n=new Set(l);return n.delete(t),n}))}catch(a){console.log("Error deleting key:",a)}}})},ot=async(t,a)=>{try{(await fetch(`/api/keys/${t}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:a})})).ok&&x(n=>n.map(r=>r.id===t?{...r,isActive:a}:r))}catch(l){console.log("Error toggling key:",l)}},Zt=t=>t?t.length>8?t.slice(0,8)+"...":t:"",es=t=>{st(a=>{const l=new Set(a);return l.has(t)?l.delete(t):l.add(t),l})},[ts,ss]=s.useState("/v1");if(s.useEffect(()=>{typeof window<"u"&&ss(`${window.location.origin}/v1`)},[]),j)return e.jsxs("div",{className:"flex flex-col gap-8",children:[e.jsx(ut,{}),e.jsx(ut,{})]});const as=ts,ns=!!L.running,De=L.localUrl!==!1;return L.canStart,De&&L.managedPid,L.loading||ns||De&&L.installed,e.jsxs("div",{className:"flex flex-col gap-8",children:[e.jsxs(dt,{children:[e.jsxs("h2",{className:"text-lg font-semibold mb-4 flex items-center gap-2",children:[e.jsx("span",{className:"material-symbols-outlined text-primary",children:"api"}),"API Endpoint"]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx(gs,{label:"Local",url:as,copyId:"local_url",copied:q,onCopy:Z}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:`text-xs font-mono px-1.5 py-0.5 rounded shrink-0 min-w-[88px] text-center ${p?"bg-primary/10 text-primary":"bg-surface-2 text-text-muted"}`,children:"Tunnel"}),p&&!P&&R?e.jsxs(e.Fragment,{children:[e.jsx(te,{value:`${D||I}/v1`,readOnly:!0,className:"flex-1 font-mono text-sm"}),e.jsx("button",{onClick:()=>Z(`${D||I}/v1`,"tunnel_url"),className:"p-2 hover:bg-black/5 dark:hover:bg-white/5 rounded text-text-muted hover:text-primary transition-colors shrink-0",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:q==="tunnel_url"?"check":"content_copy"})}),e.jsx("button",{onClick:()=>J(!0),className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Disable Tunnel",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):p&&!P&&!R?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-amber-300 dark:border-amber-800 bg-amber-500/5 text-sm text-amber-600 dark:text-amber-400",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),It?"Tunnel reconnecting...":"Tunnel checking..."]}),e.jsx("button",{onClick:()=>J(!0),className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Disable Tunnel",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):P?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-border bg-input text-sm text-text-muted",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),Tt||"Creating tunnel..."]}),e.jsx("button",{onClick:()=>{C(!1),T("")},className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Stop",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):(ce==null?void 0:ce.type)==="error"?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-red-300 dark:border-red-800 bg-red-500/5 text-sm text-red-600 dark:text-red-400",children:[e.jsx("span",{className:"material-symbols-outlined text-sm",children:"error"}),ce.message]}),e.jsx(c,{size:"sm",icon:"cloud_upload",onClick:()=>V(!0),children:"Enable"})]}):Ct?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-border bg-input text-sm text-text-muted",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),"Checking..."]}),e.jsx("button",{onClick:()=>ke(!1),className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Stop",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):e.jsx(c,{size:"sm",icon:"cloud_upload",onClick:()=>{V(!0)},children:"Enable"})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:`text-xs font-mono px-1.5 py-0.5 rounded shrink-0 min-w-[88px] text-center ${f?"bg-primary/10 text-primary":"bg-surface-2 text-text-muted"}`,children:"Tailscale"}),f&&!_&&M?e.jsxs(e.Fragment,{children:[e.jsx(te,{value:`${H}/v1`,readOnly:!0,className:"flex-1 font-mono text-sm"}),e.jsx("button",{onClick:()=>Z(`${H}/v1`,"ts_url"),className:"p-2 hover:bg-black/5 dark:hover:bg-white/5 rounded text-text-muted hover:text-primary transition-colors shrink-0",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:q==="ts_url"?"check":"content_copy"})}),e.jsx("button",{onClick:()=>X(!0),className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Disable Tailscale",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):f&&!_&&!M?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-amber-300 dark:border-amber-800 bg-amber-500/5 text-sm text-amber-600 dark:text-amber-400",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),Dt?"Tailscale reconnecting...":"Tailscale checking..."]}),e.jsx("button",{onClick:()=>X(!0),className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Disable Tailscale",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):_||Ut?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-border bg-input text-sm text-text-muted",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),Pt||"Connecting..."]}),Qe&&e.jsx(c,{size:"sm",icon:"open_in_new",onClick:()=>window.open(Qe,"tailscale_auth","width=600,height=700,noopener,noreferrer"),children:_t||"Open"}),e.jsx("button",{onClick:()=>{G(!1),Pe(!1),A(""),S()},className:"p-2 hover:bg-red-500/10 rounded text-red-500 transition-colors shrink-0",title:"Stop",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"power_settings_new"})})]}):(K==null?void 0:K.type)==="error"?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex-1 flex items-center gap-2 px-3 py-1.5 rounded border border-red-300 dark:border-red-800 bg-red-500/5 text-sm text-red-600 dark:text-red-400",children:[e.jsx("span",{className:"material-symbols-outlined text-sm",children:"error"}),K.message]}),e.jsx(c,{size:"sm",icon:"vpn_lock",onClick:it,children:"Enable"})]}):e.jsx(c,{size:"sm",icon:"vpn_lock",onClick:()=>{it()},className:"bg-linear-to-r from-indigo-500 to-purple-500 hover:from-indigo-600 hover:to-purple-600 text-white!",children:"Enable"})]})]}),Ht&&!p&&!f&&e.jsx("div",{className:"mt-4",children:e.jsx(ye,{message:Ft,action:{label:"Open settings",href:"/dashboard/profile"}})}),(p||f)&&e.jsxs("div",{className:"mt-4 flex flex-col gap-2",children:[!ne&&e.jsx(ye,{message:"Require API key is disabled — your endpoint is publicly accessible without authentication.",action:{label:"Enable",href:"#require-api-key"}}),(!B||!qe)&&e.jsx(ye,{message:B?"Dashboard uses the default password — change it in Profile settings.":"Require login is disabled — anyone can access your dashboard via tunnel.",action:{label:B?"Change password":"Enable",href:"/dashboard/profile"}})]}),(p||f)&&e.jsxs("div",{className:"mt-4 pt-4 border-t border-border flex items-center gap-3",children:[e.jsx(Me,{checked:$e,onChange:()=>Wt(!$e)}),e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx("p",{className:"font-medium text-sm",children:"Allow dashboard access via tunnel"}),e.jsx(ys,{text:"When enabled, the dashboard can be accessed through your tunnel or Tailscale URL (login still required). When disabled, dashboard access via tunnel/Tailscale is completely blocked."})]})]})]}),e.jsxs(dt,{id:"require-api-key",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsxs("h2",{className:"text-lg font-semibold flex items-center gap-2",children:[e.jsx("span",{className:"material-symbols-outlined text-primary",children:"vpn_key"}),"API Keys"]}),e.jsx(c,{icon:"add",onClick:()=>N(!0),children:"Create Key"})]}),e.jsxs("div",{className:"flex items-center justify-between pb-4 mb-4 border-b border-border",children:[e.jsxs("div",{children:[e.jsx("p",{className:"font-medium",children:"Require API key"}),e.jsx("p",{className:"text-sm text-text-muted",children:"Requests without a valid key will be rejected"})]}),e.jsx(Me,{checked:ne,onChange:()=>qt(!ne)})]}),Ot&&!ne&&e.jsx("div",{className:"mb-4 -mt-2",children:e.jsx(ye,{message:"Endpoint is exposed without an API key."})}),d.length===0?e.jsxs("div",{className:"text-center py-12",children:[e.jsx("div",{className:"inline-flex items-center justify-center w-16 h-16 rounded-full bg-primary/10 text-primary mb-4",children:e.jsx("span",{className:"material-symbols-outlined text-[32px]",children:"vpn_key"})}),e.jsx("p",{className:"text-text-main font-medium mb-1",children:"No API keys yet"}),e.jsx("p",{className:"text-sm text-text-muted mb-4",children:"Create your first API key to get started"}),e.jsx(c,{icon:"add",onClick:()=>N(!0),children:"Create Key"})]}):e.jsx("div",{className:"flex flex-col",children:d.map(t=>e.jsxs("div",{className:`group flex items-center justify-between py-3 border-b border-black/[0.03] dark:border-white/[0.03] last:border-b-0 ${t.isActive===!1?"opacity-60":""}`,children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-sm font-medium",children:t.name}),e.jsxs("div",{className:"flex items-center gap-2 mt-1",children:[e.jsx("code",{className:"text-xs text-text-muted font-mono",children:Ue.has(t.id)?t.key:Zt(t.key)}),e.jsx("button",{onClick:()=>es(t.id),className:"p-1 hover:bg-black/5 dark:hover:bg-white/5 rounded text-text-muted hover:text-primary opacity-100 sm:opacity-0 sm:group-hover:opacity-100 transition-all",title:Ue.has(t.id)?"Hide key":"Show key",children:e.jsx("span",{className:"material-symbols-outlined text-[14px]",children:Ue.has(t.id)?"visibility_off":"visibility"})}),e.jsx("button",{onClick:()=>Z(t.key,t.id),className:"p-1 hover:bg-black/5 dark:hover:bg-white/5 rounded text-text-muted hover:text-primary opacity-100 sm:opacity-0 sm:group-hover:opacity-100 transition-all",children:e.jsx("span",{className:"material-symbols-outlined text-[14px]",children:q===t.id?"check":"content_copy"})})]}),e.jsxs("p",{className:"text-xs text-text-muted mt-1",children:["Created ",new Date(t.createdAt).toLocaleDateString()]}),t.isActive===!1&&e.jsx("p",{className:"text-xs text-orange-500 mt-1",children:"Paused"})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(Me,{size:"sm",checked:t.isActive??!0,onChange:a=>{t.isActive&&!a?z({title:"Pause API Key",message:`Pause API key "${t.name}"?
|
|
5
|
+
|
|
6
|
+
This key will stop working immediately but can be resumed later.`,onConfirm:async()=>{z(null),ot(t.id,a)}}):ot(t.id,a)},title:t.isActive?"Pause key":"Resume key"}),e.jsx("button",{onClick:()=>Qt(t.id),className:"p-2 hover:bg-red-500/10 rounded text-red-500 opacity-100 sm:opacity-0 sm:group-hover:opacity-100 transition-all",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:"delete"})})]})]},t.id))})]}),e.jsx($,{isOpen:b,title:"Create API Key",onClose:()=>{N(!1),ae("")},children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx(te,{label:"Key Name",value:se,onChange:t=>ae(t.target.value),placeholder:"Production Key"}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(c,{onClick:Yt,fullWidth:!0,disabled:!se.trim(),children:"Create"}),e.jsx(c,{onClick:()=>{N(!1),ae("")},variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})}),e.jsx($,{isOpen:!!je,title:"API Key Created",onClose:()=>we(null),children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsxs("div",{className:"bg-yellow-50 dark:bg-yellow-900/20 border border-yellow-200 dark:border-yellow-800 rounded-lg p-4",children:[e.jsx("p",{className:"text-sm text-yellow-800 dark:text-yellow-200 mb-2 font-medium",children:"Save this key now!"}),e.jsx("p",{className:"text-sm text-yellow-700 dark:text-yellow-300",children:"This is the only time you will see this key. Store it securely."})]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(te,{value:je||"",readOnly:!0,className:"flex-1 font-mono text-sm"}),e.jsx(c,{variant:"secondary",icon:q==="created_key"?"check":"content_copy",onClick:()=>Z(je,"created_key"),children:q==="created_key"?"Copied!":"Copy"})]}),e.jsx(c,{onClick:()=>we(null),fullWidth:!0,children:"Done"})]})}),e.jsx($,{isOpen:St,title:"Enable Tunnel",onClose:()=>V(!1),children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx("div",{className:"bg-surface-2 border border-border-subtle rounded-lg p-4",children:e.jsxs("div",{className:"flex items-start gap-3",children:[e.jsx("span",{className:"material-symbols-outlined text-primary",children:"cloud_upload"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm text-text-main font-medium mb-1",children:"Cloudflare Tunnel"}),e.jsx("p",{className:"text-sm text-text-muted",children:"Expose your local FSRouter to the internet. No port forwarding, no static IP needed. Share endpoint URL with your team or use it in Cursor, Cline, and other AI tools from anywhere."})]})]})}),e.jsx("div",{className:"grid grid-cols-2 gap-3",children:us.map(t=>e.jsxs("div",{className:"flex flex-col items-center text-center p-3 rounded-lg bg-sidebar/50",children:[e.jsx("span",{className:"material-symbols-outlined text-xl text-primary mb-1",children:t.icon}),e.jsx("p",{className:"text-xs font-semibold",children:t.title}),e.jsx("p",{className:"text-xs text-text-muted",children:t.desc})]},t.title))}),e.jsx("p",{className:"text-xs text-text-muted",children:"Requires outbound port 7844 (TCP/UDP). Connection may take 10-30s."}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(c,{onClick:Bt,fullWidth:!0,children:"Start Tunnel"}),e.jsx(c,{onClick:()=>V(!1),variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})}),e.jsx($,{isOpen:Et,title:"Disable Tunnel",onClose:()=>!P&&J(!1),children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx("p",{className:"text-sm text-text-muted",children:"The Cloudflare tunnel will be disconnected. Remote access via tunnel URL will stop working."}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(c,{onClick:Vt,fullWidth:!0,disabled:P,variant:"danger",children:P?"Disabling...":"Disable"}),e.jsx(c,{onClick:()=>J(!1),variant:"ghost",fullWidth:!0,disabled:P,children:"Cancel"})]})]})}),e.jsx($,{isOpen:Lt,title:"Tailscale Funnel",onClose:()=>{me||(W(!1),tt(""),u(null))},children:e.jsxs("div",{className:"flex flex-col gap-4",children:[Ce===null&&e.jsxs("p",{className:"text-sm text-text-muted flex items-center gap-2",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),"Checking..."]}),Ce===!1&&!me&&e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsx("p",{className:"text-sm text-text-muted",children:"Tailscale is not installed. Install it to enable Funnel."}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(c,{onClick:Gt,fullWidth:!0,children:"Install Tailscale"}),e.jsx(c,{onClick:()=>W(!1),variant:"ghost",fullWidth:!0,children:"Cancel"})]})]}),me&&e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"flex items-center gap-2 text-sm text-text-muted",children:[e.jsx("span",{className:"material-symbols-outlined animate-spin text-sm",children:"progress_activity"}),"Installing Tailscale..."]}),Se.length>0&&e.jsx("div",{ref:he,className:"bg-black/5 dark:bg-white/5 rounded p-2 max-h-40 overflow-y-auto font-mono text-xs text-text-muted",children:Se.map((t,a)=>e.jsx("div",{children:t},a))})]}),Ce===!0&&!me&&e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsxs("div",{className:"flex items-center gap-2 text-sm text-green-600 dark:text-green-400",children:[e.jsx("span",{className:"material-symbols-outlined text-[16px]",children:"check_circle"}),"Tailscale installed"]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(c,{onClick:()=>Ie(),fullWidth:!0,children:"Connect"}),e.jsx(c,{onClick:()=>W(!1),variant:"ghost",fullWidth:!0,children:"Cancel"})]})]}),K&&e.jsx(bs,{status:K})]})}),e.jsx($,{isOpen:Rt,title:"Disable Tailscale",onClose:()=>!_&&X(!1),children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx("p",{className:"text-sm text-text-muted",children:"Tailscale Funnel will be stopped. Remote access via Tailscale URL will stop working."}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx(c,{onClick:Xt,fullWidth:!0,disabled:_,variant:"danger",children:_?"Disabling...":"Disable"}),e.jsx(c,{onClick:()=>X(!1),variant:"ghost",fullWidth:!0,disabled:_,children:"Cancel"})]})]})}),e.jsx(os,{isOpen:!!w,onClose:()=>z(null),onConfirm:w==null?void 0:w.onConfirm,title:(w==null?void 0:w.title)||"Confirm",message:w==null?void 0:w.message,variant:"danger"})]})}function gs({label:h,url:d,copyId:x,copied:j,onCopy:U,badge:b,actions:N}){return e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:`text-xs font-mono px-1.5 py-0.5 rounded shrink-0 min-w-[88px] text-center ${b==="CF"||b==="TS"?"bg-primary/10 text-primary":"bg-surface-2 text-text-muted"}`,children:h}),e.jsx(te,{value:d,readOnly:!0,className:"flex-1 font-mono text-sm"}),e.jsx("button",{onClick:()=>U(d,x),className:"p-2 hover:bg-black/5 dark:hover:bg-white/5 rounded text-text-muted hover:text-primary transition-colors shrink-0",children:e.jsx("span",{className:"material-symbols-outlined text-[18px]",children:j===x?"check":"content_copy"})}),N]})}function bs({status:h,className:d=""}){const x=j=>j.split(/(https?:\/\/[^\s]+)/g).map((b,N)=>/^https?:\/\//.test(b)?e.jsx("a",{href:b,target:"_blank",rel:"noreferrer",className:"underline font-medium",children:b},N):b);return e.jsx("div",{className:`p-2 rounded text-sm ${d} ${h.type==="success"?"bg-green-500/10 text-green-600 dark:text-green-400":h.type==="warning"?"bg-yellow-500/10 text-yellow-600 dark:text-yellow-400":h.type==="info"?"bg-blue-500/10 text-blue-600 dark:text-blue-400":"bg-red-500/10 text-red-600 dark:text-red-400"}`,children:x(h.message)})}function ys({text:h}){return e.jsxs("span",{className:"relative group inline-flex items-center",children:[e.jsx("span",{className:"material-symbols-outlined text-[14px] text-text-muted cursor-help",children:"help"}),e.jsx("span",{className:"pointer-events-none absolute left-5 top-1/2 -translate-y-1/2 z-50 w-64 rounded bg-gray-900 dark:bg-gray-800 text-white text-xs px-2.5 py-1.5 opacity-0 group-hover:opacity-100 transition-opacity shadow-lg",children:h})]})}function ye({message:h,action:d}){return e.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 rounded-lg bg-amber-500/10 border border-amber-500/20 text-amber-700 dark:text-amber-400",children:[e.jsx("span",{className:"material-symbols-outlined text-[16px] shrink-0 mt-0.5",children:"warning"}),e.jsx("p",{className:"text-xs flex-1",children:h}),d&&e.jsx("a",{href:d.href,className:"text-xs font-medium underline shrink-0 hover:opacity-80",onClick:d.href.startsWith("#")?x=>{var j;x.preventDefault(),(j=document.getElementById(d.href.slice(1)))==null||j.scrollIntoView({behavior:"smooth"})}:void 0,children:d.label})]})}fs.propTypes={machineId:cs.string.isRequired};export{fs as A};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as e,n as t}from"./index.2a3mqmx-.js";function r({size:n="md",className:s}){const i={sm:"size-4",md:"size-6",lg:"size-8",xl:"size-12"};return e.jsx("span",{className:t("material-symbols-outlined animate-spin text-brand-500",i[n],s),children:"progress_activity"})}function c({message:n="Loading..."}){return e.jsxs("div",{className:"fixed inset-0 z-50 flex flex-col items-center justify-center bg-bg",children:[e.jsx(r,{size:"xl"}),e.jsx("p",{className:"mt-4 text-text-muted",children:n})]})}function a({className:n,...s}){return e.jsx("div",{className:t("animate-pulse rounded-[10px] bg-surface-2",n),...s})}function d(){return e.jsxs("div",{className:"p-6 rounded-[14px] border border-border-subtle bg-surface shadow-[var(--shadow-soft)]",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx(a,{className:"h-4 w-24"}),e.jsx(a,{className:"size-10 rounded-[10px]"})]}),e.jsx(a,{className:"h-8 w-16 mb-2"}),e.jsx(a,{className:"h-3 w-20"})]})}function x({type:n="spinner",...s}){switch(n){case"page":return e.jsx(c,{...s});case"skeleton":return e.jsx(a,{...s});case"card":return e.jsx(d,{...s});default:return e.jsx(r,{...s})}}export{d as C,x as L};
|