@lunora/studio 1.0.0-alpha.4 → 1.0.0-alpha.40
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/LICENSE.md +6 -0
- package/__assets__/package-og.svg +1 -1
- package/dist/index.d.ts +33 -18
- package/dist/index.js +29 -29
- package/dist/mount.d.ts +1 -1
- package/dist/mount.js +3 -2
- package/dist/{packem_shared/ApiTab-W3no0KOj.js → packem_chunks/ApiTab.js} +5 -5
- package/dist/{packem_shared/AuditPanel-Bq4o_IqT.js → packem_chunks/AuditPanel.js} +29 -41
- package/dist/{packem_shared/ExportImportPanel-dxY56TDF.js → packem_chunks/ExportImportPanel.js} +16 -11
- package/dist/{packem_shared/FileBrowser-Dhy4zES8.js → packem_chunks/FileBrowser.js} +15 -15
- package/dist/{packem_shared/FunctionRunner--fQJRPAD.js → packem_chunks/FunctionRunner.js} +10 -10
- package/dist/{packem_shared/FunctionStatsPanel-BjRUA_G3.js → packem_chunks/FunctionStatsPanel.js} +153 -208
- package/dist/{packem_shared/HealthPanel-PxclMWmA.js → packem_chunks/HealthPanel.js} +37 -29
- package/dist/{packem_shared/InsightsPanel-CWS_C-xW.js → packem_chunks/InsightsPanel.js} +108 -69
- package/dist/{packem_shared/LogsPanel-CTW8CFcM.js → packem_chunks/LogsPanel.js} +46 -58
- package/dist/{packem_shared/MailPanel-BwkvfIHF.js → packem_chunks/MailPanel.js} +45 -139
- package/dist/{packem_shared/MetricsPanel-BLuOhZQ4.js → packem_chunks/MetricsPanel.js} +41 -322
- package/dist/{packem_shared/MigrationsPanel-DT3lnwHF.js → packem_chunks/MigrationsPanel.js} +44 -51
- package/dist/{packem_shared/PitrPanel-CdErL7EJ.js → packem_chunks/PitrPanel.js} +9 -9
- package/dist/{packem_shared/SchemaViewer-LJDcmNIO.js → packem_chunks/SchemaViewer.js} +17 -16
- package/dist/{packem_shared/SecurityAdvisorPanel-C_ETsPih.js → packem_chunks/SecurityAdvisorPanel.js} +47 -31
- package/dist/packem_chunks/SettingsPanel.js +391 -0
- package/dist/{packem_shared/sql-editor-panel-BFRpzj6r.js → packem_chunks/SqlEditorPanel.js} +158 -387
- package/dist/{packem_shared/TableEditor-ChfUOZec.js → packem_chunks/TableEditor.js} +10 -68
- package/dist/packem_chunks/analytics-panel.js +261 -0
- package/dist/packem_chunks/auth-config-panel.js +365 -0
- package/dist/packem_chunks/auth-sessions-panel.js +175 -0
- package/dist/packem_chunks/containers-panel.js +247 -0
- package/dist/packem_chunks/dashboards-panel.js +780 -0
- package/dist/packem_chunks/fanout-panel.js +482 -0
- package/dist/packem_chunks/flags-panel.js +176 -0
- package/dist/packem_chunks/kv-browser.js +1896 -0
- package/dist/packem_chunks/log-drains-panel.js +273 -0
- package/dist/packem_chunks/organizations-panel.js +3178 -0
- package/dist/packem_chunks/payments-panel.js +186 -0
- package/dist/packem_chunks/permissions-panel.js +805 -0
- package/dist/packem_chunks/queues-panel.js +1075 -0
- package/dist/packem_chunks/rls-panel.js +315 -0
- package/dist/packem_chunks/schedule-panel.js +831 -0
- package/dist/packem_chunks/sparkline.js +79 -0
- package/dist/packem_chunks/storage-rules-panel.js +140 -0
- package/dist/packem_chunks/subscriptions-panel.js +238 -0
- package/dist/packem_chunks/users-panel.js +1731 -0
- package/dist/packem_chunks/vector-browser.js +281 -0
- package/dist/packem_chunks/workflows-panel.js +562 -0
- package/dist/packem_shared/{ADMIN_FUNCTIONS-DmBqMZ-z.js → ADMIN_FUNCTIONS-BHHJi3Gb.js} +7 -0
- package/dist/packem_shared/{ApiDocsPanel-C5-yJ1p7.js → ApiDocsPanel-CBma-lnp.js} +2 -2
- package/dist/packem_shared/{ApiReferencePanel-1vubqG5s.js → ApiReferencePanel-CQM3pPN7.js} +2 -1
- package/dist/packem_shared/{CommandPalette-BtgkBzZI.js → CommandPalette-X2tkbyHk.js} +1 -1
- package/dist/packem_shared/{DataBrowser-CtBe1So9.js → DataBrowser-D2ywrdId.js} +198 -247
- package/dist/packem_shared/{GlobalDataBrowser-BTEmGrph.js → GlobalDataBrowser-BkTPLzAY.js} +37 -66
- package/dist/packem_shared/HomePanel-D1Q9LZgK.js +14 -0
- package/dist/packem_shared/{OpenRpcReferencePanel-vbcYbv3V.js → OpenRpcReferencePanel-Dno-hfDb.js} +2 -1
- package/dist/packem_shared/{ScheduledJobs-CabfKbyM.js → ScheduledJobs-Ctw4jYtU.js} +163 -60
- package/dist/packem_shared/Studio-lJhzDAze.js +16 -0
- package/dist/packem_shared/{StudioApp-CHOZA-z-.js → StudioApp-DiMkupvZ.js} +276 -11
- package/dist/packem_shared/{advisor-view-CGcfMiPq.js → advisor-view-BX8OhG0w.js} +6 -6
- package/dist/packem_shared/alert-CdAET2K_.js +68 -0
- package/dist/packem_shared/{app.d-CCmwDEVs.d.ts → app.d-CNLRTrWw.d.ts} +1 -1
- package/dist/packem_shared/{bar-chart-CzJAgqkp.js → bar-chart-DSwcWIRy.js} +5 -4
- package/dist/packem_shared/browser-storage-BTrX4y3B.js +215 -0
- package/dist/packem_shared/{cf-links-2cktDedA.js → cf-links-BZfRdxSE.js} +1 -1
- package/dist/packem_shared/{data-grid-B5CaV3wS.js → data-grid-CdXztApG.js} +1 -1
- package/dist/packem_shared/data-view-params-Cd6yRVbv.js +96 -0
- package/dist/packem_shared/error-alert-CXjqyGw9.js +114 -0
- package/dist/packem_shared/{grid-features-CzUfqgsM.js → grid-features-BF-KBDFz.js} +131 -163
- package/dist/packem_shared/home-panel-TFcRf9Ui.js +1889 -0
- package/dist/packem_shared/{internal-rXJEAhXS.js → internal-CYcbqMjX.js} +44 -3
- package/dist/packem_shared/modal-shell-hyaJvIJ6.js +100 -0
- package/dist/packem_shared/{reference-view-B4E49Lip.js → reference-view-DUiJcILV.js} +6 -45
- package/dist/packem_shared/scroll-area-DLhcy-ml.js +93 -0
- package/dist/packem_shared/select-UkNYCT3s.js +273 -0
- package/dist/packem_shared/skeleton-CGhL0p20.js +45 -0
- package/dist/packem_shared/{sparkline-10dG-_f0.js → sparkline-BnA1kC9X.js} +1 -1
- package/dist/packem_shared/studio-Dh9UlaF_.js +4015 -0
- package/dist/packem_shared/{table-_RzNvy3R.js → table-DsCa9Qp9.js} +1 -1
- package/dist/packem_shared/{table-list-sidebar-Bg7uzbvC.js → table-list-sidebar-UVIXQJdU.js} +1 -1
- package/dist/packem_shared/use-admin-query-CfHYWx5n.js +106 -0
- package/dist/packem_shared/use-async-submit-DJQiPc-_.js +91 -0
- package/dist/standalone/chunk-23C4TCRO.js +1 -0
- package/dist/standalone/chunk-2K47A3P6.js +1 -0
- package/dist/standalone/chunk-2NGUNNGW.js +1 -0
- package/dist/standalone/chunk-3CJW6NWG.js +4 -0
- package/dist/standalone/chunk-3OA7PECS.js +6 -0
- package/dist/standalone/chunk-4QHKBC77.js +1 -0
- package/dist/standalone/chunk-5OIBXYZM.js +1 -0
- package/dist/standalone/chunk-5ZAA2PVR.js +1 -0
- package/dist/standalone/chunk-676HEBIR.js +3 -0
- package/dist/standalone/chunk-6VO23MMW.js +4 -0
- package/dist/standalone/chunk-7RE5UW27.js +8 -0
- package/dist/standalone/chunk-7TJJXVSE.js +1 -0
- package/dist/standalone/chunk-7YXOPTWI.js +1 -0
- package/dist/standalone/chunk-AAVIFQ4Y.js +2 -0
- package/dist/standalone/chunk-AHILM3ZP.js +1 -0
- package/dist/standalone/chunk-AJFQ3LNM.js +1 -0
- package/dist/standalone/chunk-AJULNB46.js +4 -0
- package/dist/standalone/chunk-BGXOXASQ.js +1 -0
- package/dist/standalone/chunk-BJGBHGK3.js +1 -0
- package/dist/standalone/chunk-BKW7FFEO.js +1 -0
- package/dist/standalone/chunk-BOXSWNXZ.js +1 -0
- package/dist/standalone/chunk-BXOYVWJR.js +13 -0
- package/dist/standalone/chunk-C7WTJLC3.js +1 -0
- package/dist/standalone/chunk-CACB34RQ.js +1 -0
- package/dist/standalone/chunk-CICVBMEN.js +1 -0
- package/dist/standalone/chunk-CKSHCYGC.js +2 -0
- package/dist/standalone/chunk-CWEAJUHW.js +1 -0
- package/dist/standalone/chunk-DC72CQY4.js +76 -0
- package/dist/standalone/chunk-DECHEGIC.js +1 -0
- package/dist/standalone/chunk-DWDILV2E.js +1 -0
- package/dist/standalone/chunk-E75ANNWX.js +19 -0
- package/dist/standalone/chunk-ERJNDIXC.js +1 -0
- package/dist/standalone/chunk-FKACHRWO.js +1 -0
- package/dist/standalone/chunk-FSGCANAU.js +1 -0
- package/dist/standalone/chunk-GLUNBZRI.js +1 -0
- package/dist/standalone/chunk-GMSGZDDH.js +13 -0
- package/dist/standalone/chunk-GTM65MVX.js +1 -0
- package/dist/standalone/chunk-H6RKXQZU.js +1 -0
- package/dist/standalone/chunk-HV7G6DFP.js +5 -0
- package/dist/standalone/chunk-HZTGDL4L.js +1 -0
- package/dist/standalone/chunk-I7ZZRM7I.js +1 -0
- package/dist/standalone/chunk-IXDH4GL5.js +1 -0
- package/dist/standalone/chunk-J46WXQYL.js +1 -0
- package/dist/standalone/chunk-J6J54MBP.js +1 -0
- package/dist/standalone/chunk-JSEXCW5Q.js +1 -0
- package/dist/standalone/chunk-JVODY4EP.js +1 -0
- package/dist/standalone/chunk-KEGAWN6Y.js +1 -0
- package/dist/standalone/chunk-KJJ3WM6H.js +4 -0
- package/dist/standalone/chunk-KSKXW5PX.js +1 -0
- package/dist/standalone/chunk-KZ6INM5M.js +1 -0
- package/dist/standalone/chunk-L7SK4ZZD.js +1 -0
- package/dist/standalone/chunk-LAK5VSPI.js +1 -0
- package/dist/standalone/chunk-LNZIB2MD.js +1 -0
- package/dist/standalone/chunk-LYB5L53X.js +1 -0
- package/dist/standalone/chunk-MJWVMKQ4.js +6 -0
- package/dist/standalone/chunk-MT2J3H7O.js +3 -0
- package/dist/standalone/chunk-N746FOQP.js +1 -0
- package/dist/standalone/chunk-NC6MBMSI.js +1 -0
- package/dist/standalone/chunk-NN27EDQB.js +1 -0
- package/dist/standalone/chunk-NY6GDADQ.js +1 -0
- package/dist/standalone/chunk-O3NAGRTR.js +1 -0
- package/dist/standalone/chunk-OY3HD7BJ.js +4 -0
- package/dist/standalone/chunk-P5HJXCZS.js +1 -0
- package/dist/standalone/chunk-PTS5TW3J.js +1 -0
- package/dist/standalone/chunk-Q52CHOSY.js +1 -0
- package/dist/standalone/chunk-QAFAJBAW.js +1 -0
- package/dist/standalone/chunk-QBAT52GB.js +1 -0
- package/dist/standalone/chunk-QDBOPDJ7.js +1 -0
- package/dist/standalone/chunk-QHFTGJPS.js +4 -0
- package/dist/standalone/chunk-RRCPZMC2.js +22 -0
- package/dist/standalone/chunk-SEU5V7I6.js +1 -0
- package/dist/standalone/chunk-SG3ALJJU.js +1 -0
- package/dist/standalone/chunk-SSI4G2MY.js +1 -0
- package/dist/standalone/chunk-TAD43CG5.js +1 -0
- package/dist/standalone/chunk-TBMYIZIO.js +1 -0
- package/dist/standalone/chunk-TH45YG6Q.js +1 -0
- package/dist/standalone/chunk-TQ36RWOP.js +1 -0
- package/dist/standalone/chunk-UGUEC6BC.js +1 -0
- package/dist/standalone/chunk-UK64ZSUW.js +1 -0
- package/dist/standalone/chunk-UKDJ4H7I.js +1 -0
- package/dist/standalone/chunk-V6IWFYAQ.js +1 -0
- package/dist/standalone/chunk-V7SRH36W.js +1 -0
- package/dist/standalone/chunk-VLXV72QE.js +1 -0
- package/dist/standalone/chunk-VON7JUPG.js +1 -0
- package/dist/standalone/chunk-WI7GWFEG.js +1 -0
- package/dist/standalone/chunk-WPNXY7IS.js +1 -0
- package/dist/standalone/chunk-X33MSJPP.js +1 -0
- package/dist/standalone/chunk-XNJNSCLM.js +1 -0
- package/dist/standalone/chunk-XRNXOIVZ.js +1 -0
- package/dist/standalone/chunk-YAECF5LW.js +1 -0
- package/dist/standalone/chunk-YBGC4PPD.js +1 -0
- package/dist/standalone/chunk-YNZ7ARWW.js +1 -0
- package/dist/standalone/chunk-YTO65GHS.js +1 -0
- package/dist/standalone/chunk-ZE6FT5Z3.js +1 -0
- package/dist/standalone/chunk-ZHVTQ37P.js +1 -0
- package/dist/standalone/chunk-ZIGWVHCS.js +1 -0
- package/dist/standalone/chunk-ZPP2KOR4.js +1 -0
- package/dist/standalone/chunk-ZPUO7FNI.js +1 -0
- package/dist/standalone/studio.js +104 -246
- package/dist/styles.css +2 -2
- package/package.json +15 -13
- package/dist/packem_shared/HomePanel-Cw16stjq.js +0 -1273
- package/dist/packem_shared/SettingsPanel-C0uLRf5P.js +0 -176
- package/dist/packem_shared/SqlEditorPanel-CguV7otm.js +0 -13
- package/dist/packem_shared/Studio-DFWAlcuf.js +0 -33
- package/dist/packem_shared/studio-Bj8psK1c.js +0 -10303
- package/dist/packem_shared/use-live-admin-Dq6g3daN.js +0 -73
- package/dist/packem_shared/use-live-shard-seed-Cuk3dnH0.js +0 -76
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { useT } from '
|
|
4
|
-
import { ADMIN_FUNCTIONS } from '
|
|
5
|
-
import {
|
|
6
|
-
import { A as AdvisorView } from './advisor-view-CGcfMiPq.js';
|
|
1
|
+
import { c } from 'react/compiler-runtime';
|
|
2
|
+
import { u as useAdminQuery } from '../packem_shared/use-admin-query-CfHYWx5n.js';
|
|
3
|
+
import { useT } from '../packem_shared/DEFAULT_LOCALE-CiX4W7Kr.js';
|
|
4
|
+
import { ADMIN_FUNCTIONS } from '../packem_shared/ADMIN_FUNCTIONS-BHHJi3Gb.js';
|
|
5
|
+
import { A as AdvisorView } from '../packem_shared/advisor-view-BX8OhG0w.js';
|
|
7
6
|
import { jsxDEV } from 'react/jsx-dev-runtime';
|
|
8
7
|
|
|
9
|
-
const GET_SECURITY_AUDIT = adminRef(ADMIN_FUNCTIONS.getSecurityAudit);
|
|
10
8
|
const findingTitle = (t, finding) => ({
|
|
11
9
|
"admin-token-weak": t("Weak admin token"),
|
|
12
10
|
"auth-secret-weak": t("Weak auth secret"),
|
|
@@ -17,6 +15,7 @@ const findingTitle = (t, finding) => ({
|
|
|
17
15
|
"security-headers-disabled": t("Security headers are off"),
|
|
18
16
|
"ws-gate-open": t("Live admin subscriptions are ungated")
|
|
19
17
|
})[finding.kind];
|
|
18
|
+
const toFindings = (result) => Array.isArray(result.findings) ? result.findings : [];
|
|
20
19
|
const findingEntity = (finding) => ({
|
|
21
20
|
"admin-token-weak": "LUNORA_ADMIN_TOKEN",
|
|
22
21
|
"auth-secret-weak": "AUTH_SECRET",
|
|
@@ -44,36 +43,53 @@ const findingDetail = (t, finding) => ({
|
|
|
44
43
|
"ws-gate-open": t("LUNORA_WS_BEARER is unset, so the WebSocket upgrade gate is open: live admin subscriptions need no credential. Set it to gate them like the HTTP admin RPCs.")
|
|
45
44
|
})[finding.kind];
|
|
46
45
|
const SecurityAdvisorPanel = () => {
|
|
47
|
-
const
|
|
46
|
+
const $ = c(8);
|
|
48
47
|
const t = useT();
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
48
|
+
let t0;
|
|
49
|
+
if ($[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
50
|
+
t0 = {};
|
|
51
|
+
$[0] = t0;
|
|
52
|
+
} else {
|
|
53
|
+
t0 = $[0];
|
|
54
|
+
}
|
|
55
|
+
const {
|
|
56
|
+
data,
|
|
57
|
+
error,
|
|
58
|
+
errorSource
|
|
59
|
+
} = useAdminQuery(ADMIN_FUNCTIONS.getSecurityAudit, t0);
|
|
60
|
+
let t1;
|
|
61
|
+
if ($[1] !== data || $[2] !== t) {
|
|
62
|
+
const findings = data === void 0 ? null : toFindings(data);
|
|
63
|
+
t1 = findings === null ? null : findings.map((finding) => ({
|
|
65
64
|
description: findingDetail(t, finding),
|
|
66
65
|
entity: findingEntity(finding),
|
|
67
66
|
issueType: findingTitle(t, finding),
|
|
68
67
|
key: finding.kind,
|
|
69
68
|
level: finding.level
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
}
|
|
69
|
+
}));
|
|
70
|
+
$[1] = data;
|
|
71
|
+
$[2] = t;
|
|
72
|
+
$[3] = t1;
|
|
73
|
+
} else {
|
|
74
|
+
t1 = $[3];
|
|
75
|
+
}
|
|
76
|
+
const rows = t1;
|
|
77
|
+
let t2;
|
|
78
|
+
if ($[4] !== error || $[5] !== errorSource || $[6] !== rows) {
|
|
79
|
+
t2 = /* @__PURE__ */ jsxDEV(AdvisorView, {
|
|
80
|
+
error,
|
|
81
|
+
errorSource,
|
|
82
|
+
rows,
|
|
83
|
+
testId: "lunora-security-advisor"
|
|
84
|
+
}, void 0, false);
|
|
85
|
+
$[4] = error;
|
|
86
|
+
$[5] = errorSource;
|
|
87
|
+
$[6] = rows;
|
|
88
|
+
$[7] = t2;
|
|
89
|
+
} else {
|
|
90
|
+
t2 = $[7];
|
|
91
|
+
}
|
|
92
|
+
return t2;
|
|
77
93
|
};
|
|
78
94
|
|
|
79
95
|
export { SecurityAdvisorPanel as default };
|
|
@@ -0,0 +1,391 @@
|
|
|
1
|
+
import { c } from 'react/compiler-runtime';
|
|
2
|
+
import 'react';
|
|
3
|
+
import { E as ErrorAlert } from '../packem_shared/error-alert-CXjqyGw9.js';
|
|
4
|
+
import { B as Badge } from '../packem_shared/badge-B2PKA1-5.js';
|
|
5
|
+
import { C as Card, a as CardContent } from '../packem_shared/card-DURq3ElK.js';
|
|
6
|
+
import { T as Table, a as TableHeader, b as TableRow, c as TableHead, d as TableBody, e as TableCell } from '../packem_shared/table-DsCa9Qp9.js';
|
|
7
|
+
import { u as useAdminQuery } from '../packem_shared/use-admin-query-CfHYWx5n.js';
|
|
8
|
+
import { useT } from '../packem_shared/DEFAULT_LOCALE-CiX4W7Kr.js';
|
|
9
|
+
import { ADMIN_FUNCTIONS } from '../packem_shared/ADMIN_FUNCTIONS-BHHJi3Gb.js';
|
|
10
|
+
import { b as CLOUDFLARE_WORKERS_URL } from '../packem_shared/cf-links-BZfRdxSE.js';
|
|
11
|
+
import { jsxDEV } from 'react/jsx-dev-runtime';
|
|
12
|
+
|
|
13
|
+
const KIND_VARIANT = {
|
|
14
|
+
binding: "outline",
|
|
15
|
+
secret: "destructive",
|
|
16
|
+
var: "secondary"
|
|
17
|
+
};
|
|
18
|
+
const SettingsPanel = (t0) => {
|
|
19
|
+
const $ = c(68);
|
|
20
|
+
const {
|
|
21
|
+
initialShardKey
|
|
22
|
+
} = t0;
|
|
23
|
+
const t = useT();
|
|
24
|
+
let t1;
|
|
25
|
+
if ($[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
26
|
+
t1 = {};
|
|
27
|
+
$[0] = t1;
|
|
28
|
+
} else {
|
|
29
|
+
t1 = $[0];
|
|
30
|
+
}
|
|
31
|
+
const t2 = initialShardKey ?? "";
|
|
32
|
+
let t3;
|
|
33
|
+
if ($[1] !== t2) {
|
|
34
|
+
t3 = {
|
|
35
|
+
shardKey: t2
|
|
36
|
+
};
|
|
37
|
+
$[1] = t2;
|
|
38
|
+
$[2] = t3;
|
|
39
|
+
} else {
|
|
40
|
+
t3 = $[2];
|
|
41
|
+
}
|
|
42
|
+
const {
|
|
43
|
+
data: result,
|
|
44
|
+
error,
|
|
45
|
+
errorSource,
|
|
46
|
+
isLoading: loading
|
|
47
|
+
} = useAdminQuery(ADMIN_FUNCTIONS.getSettings, t1, t3);
|
|
48
|
+
let t4;
|
|
49
|
+
bb0: {
|
|
50
|
+
const deploy = result?.deploy;
|
|
51
|
+
if (deploy === void 0) {
|
|
52
|
+
let t52;
|
|
53
|
+
if ($[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
54
|
+
t52 = [];
|
|
55
|
+
$[3] = t52;
|
|
56
|
+
} else {
|
|
57
|
+
t52 = $[3];
|
|
58
|
+
}
|
|
59
|
+
t4 = t52;
|
|
60
|
+
break bb0;
|
|
61
|
+
}
|
|
62
|
+
let rows;
|
|
63
|
+
if ($[4] !== deploy.deploymentId || $[5] !== deploy.environment || $[6] !== deploy.versionTag || $[7] !== deploy.workerUrl || $[8] !== t) {
|
|
64
|
+
rows = [];
|
|
65
|
+
if (deploy.workerUrl !== void 0) {
|
|
66
|
+
let t52;
|
|
67
|
+
if ($[10] !== t) {
|
|
68
|
+
t52 = t("URL");
|
|
69
|
+
$[10] = t;
|
|
70
|
+
$[11] = t52;
|
|
71
|
+
} else {
|
|
72
|
+
t52 = $[11];
|
|
73
|
+
}
|
|
74
|
+
let t62;
|
|
75
|
+
if ($[12] !== deploy.workerUrl || $[13] !== t52) {
|
|
76
|
+
t62 = {
|
|
77
|
+
label: t52,
|
|
78
|
+
value: deploy.workerUrl
|
|
79
|
+
};
|
|
80
|
+
$[12] = deploy.workerUrl;
|
|
81
|
+
$[13] = t52;
|
|
82
|
+
$[14] = t62;
|
|
83
|
+
} else {
|
|
84
|
+
t62 = $[14];
|
|
85
|
+
}
|
|
86
|
+
rows.push(t62);
|
|
87
|
+
}
|
|
88
|
+
if (deploy.environment !== void 0) {
|
|
89
|
+
let t52;
|
|
90
|
+
if ($[15] !== t) {
|
|
91
|
+
t52 = t("Environment");
|
|
92
|
+
$[15] = t;
|
|
93
|
+
$[16] = t52;
|
|
94
|
+
} else {
|
|
95
|
+
t52 = $[16];
|
|
96
|
+
}
|
|
97
|
+
let t62;
|
|
98
|
+
if ($[17] !== deploy.environment || $[18] !== t52) {
|
|
99
|
+
t62 = {
|
|
100
|
+
label: t52,
|
|
101
|
+
value: deploy.environment
|
|
102
|
+
};
|
|
103
|
+
$[17] = deploy.environment;
|
|
104
|
+
$[18] = t52;
|
|
105
|
+
$[19] = t62;
|
|
106
|
+
} else {
|
|
107
|
+
t62 = $[19];
|
|
108
|
+
}
|
|
109
|
+
rows.push(t62);
|
|
110
|
+
}
|
|
111
|
+
if (deploy.deploymentId !== void 0) {
|
|
112
|
+
let t52;
|
|
113
|
+
if ($[20] !== t) {
|
|
114
|
+
t52 = t("Deployment");
|
|
115
|
+
$[20] = t;
|
|
116
|
+
$[21] = t52;
|
|
117
|
+
} else {
|
|
118
|
+
t52 = $[21];
|
|
119
|
+
}
|
|
120
|
+
let t62;
|
|
121
|
+
if ($[22] !== deploy.deploymentId || $[23] !== t52) {
|
|
122
|
+
t62 = {
|
|
123
|
+
label: t52,
|
|
124
|
+
value: deploy.deploymentId
|
|
125
|
+
};
|
|
126
|
+
$[22] = deploy.deploymentId;
|
|
127
|
+
$[23] = t52;
|
|
128
|
+
$[24] = t62;
|
|
129
|
+
} else {
|
|
130
|
+
t62 = $[24];
|
|
131
|
+
}
|
|
132
|
+
rows.push(t62);
|
|
133
|
+
}
|
|
134
|
+
if (deploy.versionTag !== void 0) {
|
|
135
|
+
let t52;
|
|
136
|
+
if ($[25] !== t) {
|
|
137
|
+
t52 = t("Version");
|
|
138
|
+
$[25] = t;
|
|
139
|
+
$[26] = t52;
|
|
140
|
+
} else {
|
|
141
|
+
t52 = $[26];
|
|
142
|
+
}
|
|
143
|
+
let t62;
|
|
144
|
+
if ($[27] !== deploy.versionTag || $[28] !== t52) {
|
|
145
|
+
t62 = {
|
|
146
|
+
label: t52,
|
|
147
|
+
value: deploy.versionTag
|
|
148
|
+
};
|
|
149
|
+
$[27] = deploy.versionTag;
|
|
150
|
+
$[28] = t52;
|
|
151
|
+
$[29] = t62;
|
|
152
|
+
} else {
|
|
153
|
+
t62 = $[29];
|
|
154
|
+
}
|
|
155
|
+
rows.push(t62);
|
|
156
|
+
}
|
|
157
|
+
$[4] = deploy.deploymentId;
|
|
158
|
+
$[5] = deploy.environment;
|
|
159
|
+
$[6] = deploy.versionTag;
|
|
160
|
+
$[7] = deploy.workerUrl;
|
|
161
|
+
$[8] = t;
|
|
162
|
+
$[9] = rows;
|
|
163
|
+
} else {
|
|
164
|
+
rows = $[9];
|
|
165
|
+
}
|
|
166
|
+
t4 = rows;
|
|
167
|
+
}
|
|
168
|
+
const deployRows = t4;
|
|
169
|
+
let t5;
|
|
170
|
+
if ($[30] !== result?.settings) {
|
|
171
|
+
t5 = result?.settings ?? [];
|
|
172
|
+
$[30] = result?.settings;
|
|
173
|
+
$[31] = t5;
|
|
174
|
+
} else {
|
|
175
|
+
t5 = $[31];
|
|
176
|
+
}
|
|
177
|
+
const settings = t5;
|
|
178
|
+
let t6;
|
|
179
|
+
if ($[32] !== t) {
|
|
180
|
+
t6 = t("Open in Cloudflare");
|
|
181
|
+
$[32] = t;
|
|
182
|
+
$[33] = t6;
|
|
183
|
+
} else {
|
|
184
|
+
t6 = $[33];
|
|
185
|
+
}
|
|
186
|
+
let t7;
|
|
187
|
+
if ($[34] !== t6) {
|
|
188
|
+
t7 = /* @__PURE__ */ jsxDEV("div", {
|
|
189
|
+
className: "flex flex-wrap items-center gap-3",
|
|
190
|
+
children: /* @__PURE__ */ jsxDEV("a", {
|
|
191
|
+
className: "text-sm text-primary underline-offset-4 hover:underline",
|
|
192
|
+
"data-testid": "set-cf-link",
|
|
193
|
+
href: CLOUDFLARE_WORKERS_URL,
|
|
194
|
+
rel: "noreferrer",
|
|
195
|
+
target: "_blank",
|
|
196
|
+
children: t6
|
|
197
|
+
}, void 0, false)
|
|
198
|
+
}, void 0, false);
|
|
199
|
+
$[34] = t6;
|
|
200
|
+
$[35] = t7;
|
|
201
|
+
} else {
|
|
202
|
+
t7 = $[35];
|
|
203
|
+
}
|
|
204
|
+
let t8;
|
|
205
|
+
if ($[36] !== t) {
|
|
206
|
+
t8 = t("View-only — values are masked. Edit vars, secrets, and bindings in wrangler or the Cloudflare dashboard.");
|
|
207
|
+
$[36] = t;
|
|
208
|
+
$[37] = t8;
|
|
209
|
+
} else {
|
|
210
|
+
t8 = $[37];
|
|
211
|
+
}
|
|
212
|
+
let t9;
|
|
213
|
+
if ($[38] !== t8) {
|
|
214
|
+
t9 = /* @__PURE__ */ jsxDEV("p", {
|
|
215
|
+
className: "text-sm text-muted-foreground",
|
|
216
|
+
"data-testid": "set-readonly-note",
|
|
217
|
+
children: t8
|
|
218
|
+
}, void 0, false);
|
|
219
|
+
$[38] = t8;
|
|
220
|
+
$[39] = t9;
|
|
221
|
+
} else {
|
|
222
|
+
t9 = $[39];
|
|
223
|
+
}
|
|
224
|
+
let t10;
|
|
225
|
+
if ($[40] !== error || $[41] !== errorSource) {
|
|
226
|
+
t10 = error !== null && /* @__PURE__ */ jsxDEV(ErrorAlert, {
|
|
227
|
+
error: errorSource,
|
|
228
|
+
testId: "set-error"
|
|
229
|
+
}, void 0, false);
|
|
230
|
+
$[40] = error;
|
|
231
|
+
$[41] = errorSource;
|
|
232
|
+
$[42] = t10;
|
|
233
|
+
} else {
|
|
234
|
+
t10 = $[42];
|
|
235
|
+
}
|
|
236
|
+
let t11;
|
|
237
|
+
if ($[43] !== deployRows || $[44] !== t) {
|
|
238
|
+
t11 = deployRows.length > 0 && /* @__PURE__ */ jsxDEV(Card, {
|
|
239
|
+
className: "py-0",
|
|
240
|
+
"data-testid": "set-deploy",
|
|
241
|
+
children: [/* @__PURE__ */ jsxDEV("header", {
|
|
242
|
+
className: "border-b border-border px-4 py-3",
|
|
243
|
+
children: /* @__PURE__ */ jsxDEV("span", {
|
|
244
|
+
className: "font-mono text-[11px] tracking-wide text-muted-foreground uppercase",
|
|
245
|
+
children: t("Deployment")
|
|
246
|
+
}, void 0, false)
|
|
247
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV(CardContent, {
|
|
248
|
+
className: "py-3",
|
|
249
|
+
children: /* @__PURE__ */ jsxDEV("dl", {
|
|
250
|
+
className: "grid grid-cols-[8rem_minmax(0,1fr)] gap-x-4 gap-y-1 text-sm",
|
|
251
|
+
children: deployRows.map(_temp)
|
|
252
|
+
}, void 0, false)
|
|
253
|
+
}, void 0, false)]
|
|
254
|
+
}, void 0, true);
|
|
255
|
+
$[43] = deployRows;
|
|
256
|
+
$[44] = t;
|
|
257
|
+
$[45] = t11;
|
|
258
|
+
} else {
|
|
259
|
+
t11 = $[45];
|
|
260
|
+
}
|
|
261
|
+
let t12;
|
|
262
|
+
if ($[46] !== t) {
|
|
263
|
+
t12 = t("Environment & bindings");
|
|
264
|
+
$[46] = t;
|
|
265
|
+
$[47] = t12;
|
|
266
|
+
} else {
|
|
267
|
+
t12 = $[47];
|
|
268
|
+
}
|
|
269
|
+
let t13;
|
|
270
|
+
if ($[48] !== t12) {
|
|
271
|
+
t13 = /* @__PURE__ */ jsxDEV("header", {
|
|
272
|
+
className: "border-b border-border px-4 py-3",
|
|
273
|
+
children: /* @__PURE__ */ jsxDEV("span", {
|
|
274
|
+
className: "font-mono text-[11px] tracking-wide text-muted-foreground uppercase",
|
|
275
|
+
children: t12
|
|
276
|
+
}, void 0, false)
|
|
277
|
+
}, void 0, false);
|
|
278
|
+
$[48] = t12;
|
|
279
|
+
$[49] = t13;
|
|
280
|
+
} else {
|
|
281
|
+
t13 = $[49];
|
|
282
|
+
}
|
|
283
|
+
let t14;
|
|
284
|
+
if ($[50] !== error || $[51] !== loading || $[52] !== settings.length || $[53] !== t) {
|
|
285
|
+
t14 = error === null && !loading && settings.length === 0 && /* @__PURE__ */ jsxDEV("p", {
|
|
286
|
+
className: "px-4 py-8 text-center text-sm text-muted-foreground",
|
|
287
|
+
"data-testid": "set-empty",
|
|
288
|
+
children: t("No environment variables or bindings.")
|
|
289
|
+
}, void 0, false);
|
|
290
|
+
$[50] = error;
|
|
291
|
+
$[51] = loading;
|
|
292
|
+
$[52] = settings.length;
|
|
293
|
+
$[53] = t;
|
|
294
|
+
$[54] = t14;
|
|
295
|
+
} else {
|
|
296
|
+
t14 = $[54];
|
|
297
|
+
}
|
|
298
|
+
let t15;
|
|
299
|
+
if ($[55] !== settings || $[56] !== t) {
|
|
300
|
+
t15 = settings.length > 0 && /* @__PURE__ */ jsxDEV(CardContent, {
|
|
301
|
+
className: "px-0 py-0",
|
|
302
|
+
children: /* @__PURE__ */ jsxDEV(Table, {
|
|
303
|
+
"data-testid": "set-table",
|
|
304
|
+
children: [/* @__PURE__ */ jsxDEV(TableHeader, {
|
|
305
|
+
children: /* @__PURE__ */ jsxDEV(TableRow, {
|
|
306
|
+
children: [/* @__PURE__ */ jsxDEV(TableHead, {
|
|
307
|
+
children: t("name")
|
|
308
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
|
|
309
|
+
children: t("kind")
|
|
310
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV(TableHead, {
|
|
311
|
+
children: t("value")
|
|
312
|
+
}, void 0, false)]
|
|
313
|
+
}, void 0, true)
|
|
314
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV(TableBody, {
|
|
315
|
+
children: settings.map(_temp2)
|
|
316
|
+
}, void 0, false)]
|
|
317
|
+
}, void 0, true)
|
|
318
|
+
}, void 0, false);
|
|
319
|
+
$[55] = settings;
|
|
320
|
+
$[56] = t;
|
|
321
|
+
$[57] = t15;
|
|
322
|
+
} else {
|
|
323
|
+
t15 = $[57];
|
|
324
|
+
}
|
|
325
|
+
let t16;
|
|
326
|
+
if ($[58] !== t13 || $[59] !== t14 || $[60] !== t15) {
|
|
327
|
+
t16 = /* @__PURE__ */ jsxDEV(Card, {
|
|
328
|
+
className: "py-0",
|
|
329
|
+
children: [t13, t14, t15]
|
|
330
|
+
}, void 0, true);
|
|
331
|
+
$[58] = t13;
|
|
332
|
+
$[59] = t14;
|
|
333
|
+
$[60] = t15;
|
|
334
|
+
$[61] = t16;
|
|
335
|
+
} else {
|
|
336
|
+
t16 = $[61];
|
|
337
|
+
}
|
|
338
|
+
let t17;
|
|
339
|
+
if ($[62] !== t10 || $[63] !== t11 || $[64] !== t16 || $[65] !== t7 || $[66] !== t9) {
|
|
340
|
+
t17 = /* @__PURE__ */ jsxDEV("div", {
|
|
341
|
+
className: "flex flex-col gap-4",
|
|
342
|
+
"data-testid": "lunora-settings",
|
|
343
|
+
children: [t7, t9, t10, t11, t16]
|
|
344
|
+
}, void 0, true);
|
|
345
|
+
$[62] = t10;
|
|
346
|
+
$[63] = t11;
|
|
347
|
+
$[64] = t16;
|
|
348
|
+
$[65] = t7;
|
|
349
|
+
$[66] = t9;
|
|
350
|
+
$[67] = t17;
|
|
351
|
+
} else {
|
|
352
|
+
t17 = $[67];
|
|
353
|
+
}
|
|
354
|
+
return t17;
|
|
355
|
+
};
|
|
356
|
+
function _temp(row) {
|
|
357
|
+
return /* @__PURE__ */ jsxDEV("div", {
|
|
358
|
+
className: "contents",
|
|
359
|
+
"data-testid": "set-deploy-row",
|
|
360
|
+
children: [/* @__PURE__ */ jsxDEV("dt", {
|
|
361
|
+
className: "text-muted-foreground",
|
|
362
|
+
children: row.label
|
|
363
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV("dd", {
|
|
364
|
+
className: "truncate font-mono text-xs",
|
|
365
|
+
title: row.value,
|
|
366
|
+
children: row.value
|
|
367
|
+
}, void 0, false)]
|
|
368
|
+
}, row.label, true);
|
|
369
|
+
}
|
|
370
|
+
function _temp2(entry) {
|
|
371
|
+
return /* @__PURE__ */ jsxDEV(TableRow, {
|
|
372
|
+
"data-testid": "set-row",
|
|
373
|
+
children: [/* @__PURE__ */ jsxDEV(TableCell, {
|
|
374
|
+
className: "font-mono text-xs font-medium",
|
|
375
|
+
children: entry.name
|
|
376
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
|
|
377
|
+
children: /* @__PURE__ */ jsxDEV(Badge, {
|
|
378
|
+
variant: KIND_VARIANT[entry.kind],
|
|
379
|
+
children: entry.bindingType ?? entry.kind
|
|
380
|
+
}, void 0, false)
|
|
381
|
+
}, void 0, false), /* @__PURE__ */ jsxDEV(TableCell, {
|
|
382
|
+
className: "max-w-[28ch] truncate font-mono text-xs text-muted-foreground",
|
|
383
|
+
children: entry.value ?? /* @__PURE__ */ jsxDEV("span", {
|
|
384
|
+
className: "text-muted-foreground",
|
|
385
|
+
children: "—"
|
|
386
|
+
}, void 0, false)
|
|
387
|
+
}, void 0, false)]
|
|
388
|
+
}, entry.name, true);
|
|
389
|
+
}
|
|
390
|
+
|
|
391
|
+
export { SettingsPanel };
|