@lumerahq/ui 0.13.0-dev.1 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -16
- package/dist/{RecordSheet-CmOeQ0M-.js → RecordSheet-BGs3rudM.js} +299 -379
- package/dist/{automations-DOek1EjJ.js → automations-DGUEnAYR.js} +199 -218
- package/dist/components/audit-log/AuditLog.d.ts +3 -3
- package/dist/components/audit-log/AuditLog.d.ts.map +1 -1
- package/dist/components/audit-log/AuditLogEntry.d.ts.map +1 -1
- package/dist/components/index.js +1 -1
- package/dist/{highlighted-body-OFNGDK62-CkZgLnjq.js → highlighted-body-OFNGDK62-V6FEuBTg.js} +1 -1
- package/dist/hooks/index.js +2 -2
- package/dist/index.js +39 -44
- package/dist/lib/audit-log-core.d.ts +0 -12
- package/dist/lib/audit-log-core.d.ts.map +1 -1
- package/dist/lib/audit-log.d.ts +1 -1
- package/dist/lib/audit-log.d.ts.map +1 -1
- package/dist/lib/bridge.d.ts +28 -0
- package/dist/lib/bridge.d.ts.map +1 -1
- package/dist/lib/index.d.ts +1 -2
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/index.js +36 -41
- package/dist/mermaid-GHXKKRXX-AvjGDhsO.js +4 -0
- package/dist/{use-automation-run-Vo2NXx-h.js → use-automation-run-D6DIaHy3.js} +142 -1
- package/dist/{use-sql-table-yjz6z8nW.js → use-sql-table-BfA0A-w3.js} +1 -1
- package/package.json +1 -1
- package/dist/mermaid-GHXKKRXX-DXYmvmZa.js +0 -4
|
@@ -428,6 +428,143 @@ const directApiStream = (request2, handlers) => {
|
|
|
428
428
|
close: () => controller.abort()
|
|
429
429
|
};
|
|
430
430
|
};
|
|
431
|
+
const isDirectMode = () => typeof window !== "undefined" && !isEmbedded() && !isStandaloneDevMode() && !isPlaygroundMode();
|
|
432
|
+
const directHostApiRequest = async (request2) => {
|
|
433
|
+
log("Direct mode: same-origin fetch", { url: request2.url, method: request2.method });
|
|
434
|
+
try {
|
|
435
|
+
const built = buildFetchBodyAndHeaders(request2);
|
|
436
|
+
const response = await fetch(request2.url, {
|
|
437
|
+
method: request2.method,
|
|
438
|
+
credentials: "same-origin",
|
|
439
|
+
headers: {
|
|
440
|
+
...built.headers,
|
|
441
|
+
"X-Lumera-Client": "lumera-custom-app"
|
|
442
|
+
},
|
|
443
|
+
body: built.body
|
|
444
|
+
});
|
|
445
|
+
const text = await response.text();
|
|
446
|
+
let body = text;
|
|
447
|
+
try {
|
|
448
|
+
body = JSON.parse(text);
|
|
449
|
+
} catch {
|
|
450
|
+
}
|
|
451
|
+
return {
|
|
452
|
+
id: "direct-host",
|
|
453
|
+
ok: response.ok,
|
|
454
|
+
status: response.status,
|
|
455
|
+
body,
|
|
456
|
+
error: response.ok ? void 0 : text
|
|
457
|
+
};
|
|
458
|
+
} catch (err) {
|
|
459
|
+
return {
|
|
460
|
+
id: "direct-host",
|
|
461
|
+
ok: false,
|
|
462
|
+
status: 0,
|
|
463
|
+
error: err instanceof Error ? err.message : "Network error"
|
|
464
|
+
};
|
|
465
|
+
}
|
|
466
|
+
};
|
|
467
|
+
const directHostApiStream = (request2, handlers) => {
|
|
468
|
+
const id = generateId();
|
|
469
|
+
const controller = new AbortController();
|
|
470
|
+
void (async () => {
|
|
471
|
+
try {
|
|
472
|
+
const response = await fetch(request2.url, {
|
|
473
|
+
method: request2.method,
|
|
474
|
+
credentials: "same-origin",
|
|
475
|
+
headers: {
|
|
476
|
+
"Content-Type": "application/json",
|
|
477
|
+
Accept: "text/event-stream",
|
|
478
|
+
"X-Lumera-Client": "lumera-custom-app",
|
|
479
|
+
...request2.headers
|
|
480
|
+
},
|
|
481
|
+
body: request2.body ? JSON.stringify(request2.body) : void 0,
|
|
482
|
+
signal: controller.signal
|
|
483
|
+
});
|
|
484
|
+
if (!response.ok) {
|
|
485
|
+
if (response.status === 409) {
|
|
486
|
+
return;
|
|
487
|
+
}
|
|
488
|
+
const message = await response.text().catch(() => `HTTP ${response.status}`);
|
|
489
|
+
handlers.onError?.(new BridgeError(message || `HTTP ${response.status}`, response.status));
|
|
490
|
+
return;
|
|
491
|
+
}
|
|
492
|
+
handlers.onOpen?.({
|
|
493
|
+
id,
|
|
494
|
+
ok: response.ok,
|
|
495
|
+
status: response.status,
|
|
496
|
+
headers: responseHeadersToRecord(response.headers)
|
|
497
|
+
});
|
|
498
|
+
const reader = response.body?.getReader();
|
|
499
|
+
if (!reader) {
|
|
500
|
+
handlers.onError?.(new BridgeError("Streaming response had no body", response.status));
|
|
501
|
+
return;
|
|
502
|
+
}
|
|
503
|
+
const decoder = new TextDecoder();
|
|
504
|
+
for (; ; ) {
|
|
505
|
+
const { done, value } = await reader.read();
|
|
506
|
+
if (done) break;
|
|
507
|
+
handlers.onChunk(decoder.decode(value, { stream: true }));
|
|
508
|
+
}
|
|
509
|
+
const trailing = decoder.decode();
|
|
510
|
+
if (trailing) handlers.onChunk(trailing);
|
|
511
|
+
} catch (err) {
|
|
512
|
+
if (err instanceof Error && err.name === "AbortError") return;
|
|
513
|
+
handlers.onError?.(new BridgeError(err instanceof Error ? err.message : "Network error"));
|
|
514
|
+
} finally {
|
|
515
|
+
handlers.onClose?.();
|
|
516
|
+
}
|
|
517
|
+
})();
|
|
518
|
+
return {
|
|
519
|
+
id,
|
|
520
|
+
close: () => controller.abort()
|
|
521
|
+
};
|
|
522
|
+
};
|
|
523
|
+
let directModeInitFired = false;
|
|
524
|
+
const fireDirectModeInit = () => {
|
|
525
|
+
if (directModeInitFired || !isDirectMode()) return;
|
|
526
|
+
directModeInitFired = true;
|
|
527
|
+
void (async () => {
|
|
528
|
+
let payload;
|
|
529
|
+
try {
|
|
530
|
+
const response = await fetch("/api/me", { credentials: "same-origin" });
|
|
531
|
+
if (response.ok || response.status === 401) {
|
|
532
|
+
let me;
|
|
533
|
+
try {
|
|
534
|
+
me = await response.json();
|
|
535
|
+
} catch {
|
|
536
|
+
me = void 0;
|
|
537
|
+
}
|
|
538
|
+
if (me) {
|
|
539
|
+
payload = {
|
|
540
|
+
company: me.company_id ? { id: me.company_id, apiName: me.company_api_name } : void 0,
|
|
541
|
+
user: me.user ?? void 0,
|
|
542
|
+
app: {
|
|
543
|
+
projectExternalId: me.project_external_id,
|
|
544
|
+
accessLevel: me.access_level
|
|
545
|
+
},
|
|
546
|
+
subjectType: me.subject_type
|
|
547
|
+
};
|
|
548
|
+
}
|
|
549
|
+
}
|
|
550
|
+
} catch (err) {
|
|
551
|
+
log("Direct mode: /api/me failed", err);
|
|
552
|
+
}
|
|
553
|
+
if (hasStoredHostPayload) return;
|
|
554
|
+
log("Direct mode: firing init payload", payload);
|
|
555
|
+
cacheHostPayload(payload, { origin: window.location.origin });
|
|
556
|
+
initListeners.forEach((listener) => listener(payload));
|
|
557
|
+
})();
|
|
558
|
+
};
|
|
559
|
+
const redirectToLogin = (returnTo) => {
|
|
560
|
+
if (typeof window === "undefined") return;
|
|
561
|
+
const target = returnTo ?? window.location.pathname + window.location.search;
|
|
562
|
+
window.location.href = `/api/auth/app-session/login?return_to=${encodeURIComponent(target)}`;
|
|
563
|
+
};
|
|
564
|
+
const logout = async () => {
|
|
565
|
+
if (typeof window === "undefined") return;
|
|
566
|
+
await fetch("/api/auth/app-session/logout", { method: "POST", credentials: "same-origin" });
|
|
567
|
+
};
|
|
431
568
|
const fireDevModeInit = () => {
|
|
432
569
|
if (devModeInitFired || !isStandaloneDevMode()) return;
|
|
433
570
|
devModeInitFired = true;
|
|
@@ -628,6 +765,12 @@ const postReadyMessage = () => {
|
|
|
628
765
|
fireDevModeInit();
|
|
629
766
|
return;
|
|
630
767
|
}
|
|
768
|
+
if (isDirectMode()) {
|
|
769
|
+
log("Direct mode: skipping postMessage, resolving identity from /api/me");
|
|
770
|
+
ensureListener();
|
|
771
|
+
fireDirectModeInit();
|
|
772
|
+
return;
|
|
773
|
+
}
|
|
631
774
|
ensureListener();
|
|
632
775
|
if (isPlaygroundMode()) {
|
|
633
776
|
log("Playground mode: initializing via VirtualBackend");
|
|
@@ -687,6 +830,16 @@ const onInitMessage = (listener) => {
|
|
|
687
830
|
fireDevModeInit();
|
|
688
831
|
return () => initListeners.delete(listener);
|
|
689
832
|
}
|
|
833
|
+
if (isDirectMode()) {
|
|
834
|
+
ensureListener();
|
|
835
|
+
initListeners.add(listener);
|
|
836
|
+
if (hasStoredHostPayload) {
|
|
837
|
+
setTimeout(() => listener(storedHostPayload), 0);
|
|
838
|
+
} else {
|
|
839
|
+
fireDirectModeInit();
|
|
840
|
+
}
|
|
841
|
+
return () => initListeners.delete(listener);
|
|
842
|
+
}
|
|
690
843
|
ensureListener();
|
|
691
844
|
initListeners.add(listener);
|
|
692
845
|
if (hasStoredHostPayload) {
|
|
@@ -701,8 +854,11 @@ const parentApiRequest = async (request2) => {
|
|
|
701
854
|
if (isPlaygroundMode()) {
|
|
702
855
|
return playgroundApiRequest(request2);
|
|
703
856
|
}
|
|
704
|
-
if (typeof window === "undefined"
|
|
705
|
-
throw new BridgeError("
|
|
857
|
+
if (typeof window === "undefined") {
|
|
858
|
+
throw new BridgeError("Bridge API requests are only available in the browser");
|
|
859
|
+
}
|
|
860
|
+
if (!isEmbedded()) {
|
|
861
|
+
return directHostApiRequest(request2);
|
|
706
862
|
}
|
|
707
863
|
ensureListener();
|
|
708
864
|
const id = generateId();
|
|
@@ -744,8 +900,11 @@ const parentApiStream = (request2, handlers) => {
|
|
|
744
900
|
if (isPlaygroundMode()) {
|
|
745
901
|
return playgroundApiStream(handlers);
|
|
746
902
|
}
|
|
747
|
-
if (typeof window === "undefined"
|
|
748
|
-
throw new BridgeError("
|
|
903
|
+
if (typeof window === "undefined") {
|
|
904
|
+
throw new BridgeError("Bridge API streams are only available in the browser");
|
|
905
|
+
}
|
|
906
|
+
if (!isEmbedded()) {
|
|
907
|
+
return directHostApiStream(request2, handlers);
|
|
749
908
|
}
|
|
750
909
|
ensureListener();
|
|
751
910
|
const id = generateId();
|
|
@@ -1035,174 +1194,6 @@ async function sendEmail(options) {
|
|
|
1035
1194
|
async function pbUpdateRecord(collectionId, recordId, data) {
|
|
1036
1195
|
return pbUpdate(collectionId, recordId, data);
|
|
1037
1196
|
}
|
|
1038
|
-
const AUDIT_LOG_EXPORT_LIMIT = 1e4;
|
|
1039
|
-
const AUDIT_LOG_MAX_COLLECTIONS = 20;
|
|
1040
|
-
const normalizeAuditLogPageSize = (value = 50) => Math.min(200, Math.max(1, Math.trunc(value) || 50));
|
|
1041
|
-
const normalizeAuditLogExportLimit = (value = AUDIT_LOG_EXPORT_LIMIT) => Math.min(AUDIT_LOG_EXPORT_LIMIT, Math.max(1, Math.trunc(value) || AUDIT_LOG_EXPORT_LIMIT));
|
|
1042
|
-
const abbreviatedActorID = (id) => id.length > 8 ? `${id.slice(0, 6)}…` : id;
|
|
1043
|
-
const auditLogActorLabel = (actor) => {
|
|
1044
|
-
const id = actor.id?.trim() || "";
|
|
1045
|
-
const name = actor.name?.trim() || "";
|
|
1046
|
-
if (name && name !== id) return name;
|
|
1047
|
-
if (actor.email?.trim()) return actor.email.trim();
|
|
1048
|
-
if (id) return `${actor.type_label || "Actor"} ${abbreviatedActorID(id)}`;
|
|
1049
|
-
return actor.type_label || "Unknown actor";
|
|
1050
|
-
};
|
|
1051
|
-
function normalizeRecordAuditCollections(collections) {
|
|
1052
|
-
const normalized = [];
|
|
1053
|
-
const seen = /* @__PURE__ */ new Set();
|
|
1054
|
-
for (const value of collections) {
|
|
1055
|
-
const collection = value.trim();
|
|
1056
|
-
if (!collection || seen.has(collection)) continue;
|
|
1057
|
-
seen.add(collection);
|
|
1058
|
-
normalized.push(collection);
|
|
1059
|
-
}
|
|
1060
|
-
return normalized;
|
|
1061
|
-
}
|
|
1062
|
-
function normalizeAuditLogFilterState(collections, filters = {}) {
|
|
1063
|
-
const available = normalizeRecordAuditCollections(collections);
|
|
1064
|
-
const allowed = new Set(available);
|
|
1065
|
-
const selected = normalizeRecordAuditCollections(filters.collections ?? available).filter(
|
|
1066
|
-
(name) => allowed.has(name)
|
|
1067
|
-
);
|
|
1068
|
-
return {
|
|
1069
|
-
collections: selected.length > 0 ? selected : available,
|
|
1070
|
-
event: filters.event,
|
|
1071
|
-
actor: filters.actor?.trim() || void 0,
|
|
1072
|
-
since: filters.since?.trim() || void 0,
|
|
1073
|
-
until: filters.until?.trim() || void 0
|
|
1074
|
-
};
|
|
1075
|
-
}
|
|
1076
|
-
function buildRecordAuditLogPath(params) {
|
|
1077
|
-
const collections = normalizeRecordAuditCollections(params.collections);
|
|
1078
|
-
if (collections.length === 0) {
|
|
1079
|
-
throw new Error("At least one collection is required");
|
|
1080
|
-
}
|
|
1081
|
-
if (collections.length > AUDIT_LOG_MAX_COLLECTIONS) {
|
|
1082
|
-
throw new Error(`At most ${AUDIT_LOG_MAX_COLLECTIONS} collections can be requested`);
|
|
1083
|
-
}
|
|
1084
|
-
const query = new URLSearchParams({
|
|
1085
|
-
domain: "record",
|
|
1086
|
-
limit: String(normalizeAuditLogPageSize(params.limit))
|
|
1087
|
-
});
|
|
1088
|
-
for (const collection of collections) query.append("collection", collection);
|
|
1089
|
-
if (params.cursor?.trim()) query.set("cursor", params.cursor.trim());
|
|
1090
|
-
if (params.event) query.set("event", params.event);
|
|
1091
|
-
if (params.actor?.trim()) query.set("actor", params.actor.trim());
|
|
1092
|
-
if (params.since?.trim()) query.set("since", params.since.trim());
|
|
1093
|
-
if (params.until?.trim()) query.set("until", params.until.trim());
|
|
1094
|
-
return `/audit-log?${query.toString()}`;
|
|
1095
|
-
}
|
|
1096
|
-
const auditLogDetailValue = (entry, label) => entry.details.find((field) => field.label === label)?.value ?? "";
|
|
1097
|
-
const auditLogRequestedCollectionName = (collection, statuses) => statuses.find((status) => status.name === collection)?.requested_name || collection;
|
|
1098
|
-
function auditLogSummaryWithCollectionLabel(entry, collectionLabel) {
|
|
1099
|
-
const label = collectionLabel.trim();
|
|
1100
|
-
if (!label) return entry.summary;
|
|
1101
|
-
const recordSegment = entry.summary.find((segment) => segment.emphasis === "strong");
|
|
1102
|
-
const suffixSegments = entry.summary.filter(
|
|
1103
|
-
(segment) => segment.emphasis === "none" && /^\(.+\)$/.test(segment.text.trim())
|
|
1104
|
-
);
|
|
1105
|
-
const eventLabel = entry.event[0].toUpperCase() + entry.event.slice(1);
|
|
1106
|
-
return [
|
|
1107
|
-
{ text: `${eventLabel} ${label}`, emphasis: "none" },
|
|
1108
|
-
...recordSegment ? [recordSegment] : [],
|
|
1109
|
-
...suffixSegments
|
|
1110
|
-
];
|
|
1111
|
-
}
|
|
1112
|
-
const collectionLabelFor = (collection, options = {}) => options.collectionLabels?.[collection]?.trim() || collection;
|
|
1113
|
-
const activityLabelFor = (collection, options = {}) => options.activityNouns?.[collection]?.trim() || options.collectionLabels?.[collection]?.trim() || "";
|
|
1114
|
-
const summaryText = (entry, options = {}) => {
|
|
1115
|
-
const collection = entry.collection;
|
|
1116
|
-
const collectionLabel = collection ? activityLabelFor(collection, options) : "";
|
|
1117
|
-
const summary = collectionLabel ? auditLogSummaryWithCollectionLabel(entry, collectionLabel) : entry.summary;
|
|
1118
|
-
return summary.map((segment) => segment.text).join(" ");
|
|
1119
|
-
};
|
|
1120
|
-
const protectSpreadsheetCell = (value) => /^[\t\r ]*[=+\-@]/.test(value) ? `'${value}` : value;
|
|
1121
|
-
const csvCell = (value) => `"${protectSpreadsheetCell(value).replaceAll('"', '""')}"`;
|
|
1122
|
-
function buildAuditLogCsv(entries, options = {}) {
|
|
1123
|
-
const rows = entries.map((entry) => {
|
|
1124
|
-
const collectionApiName = entry.collection;
|
|
1125
|
-
return [
|
|
1126
|
-
entry.occurred_at,
|
|
1127
|
-
collectionApiName ? collectionLabelFor(collectionApiName, options) : "",
|
|
1128
|
-
collectionApiName,
|
|
1129
|
-
auditLogActorLabel(entry.actor),
|
|
1130
|
-
entry.actor.type,
|
|
1131
|
-
entry.actor.id || "",
|
|
1132
|
-
entry.event,
|
|
1133
|
-
entry.record_id,
|
|
1134
|
-
summaryText(entry, options)
|
|
1135
|
-
].map(csvCell).join(",");
|
|
1136
|
-
});
|
|
1137
|
-
return [
|
|
1138
|
-
[
|
|
1139
|
-
"time",
|
|
1140
|
-
"collection_label",
|
|
1141
|
-
"collection_api_name",
|
|
1142
|
-
"actor",
|
|
1143
|
-
"actor_type",
|
|
1144
|
-
"actor_id",
|
|
1145
|
-
"event",
|
|
1146
|
-
"record_id",
|
|
1147
|
-
"summary"
|
|
1148
|
-
].map(csvCell).join(","),
|
|
1149
|
-
...rows
|
|
1150
|
-
].join("\n");
|
|
1151
|
-
}
|
|
1152
|
-
async function listRecordAuditLog(params) {
|
|
1153
|
-
return requestApi(buildRecordAuditLogPath(params), { method: "GET" });
|
|
1154
|
-
}
|
|
1155
|
-
async function getRecordAuditLogSnapshot(id, store) {
|
|
1156
|
-
const normalizedID = id.trim();
|
|
1157
|
-
if (!normalizedID) {
|
|
1158
|
-
throw new Error("Audit log ID is required");
|
|
1159
|
-
}
|
|
1160
|
-
return requestApi(
|
|
1161
|
-
`/audit-log/${encodeURIComponent(normalizedID)}/snapshot?store=${encodeURIComponent(store)}`,
|
|
1162
|
-
{ method: "GET" }
|
|
1163
|
-
);
|
|
1164
|
-
}
|
|
1165
|
-
async function fetchRecordAuditLogCsv(params, maxRows = AUDIT_LOG_EXPORT_LIMIT, options = {}) {
|
|
1166
|
-
const limit = normalizeAuditLogExportLimit(maxRows);
|
|
1167
|
-
const entries = [];
|
|
1168
|
-
let cursor = "";
|
|
1169
|
-
let truncated = false;
|
|
1170
|
-
const requestedNames = /* @__PURE__ */ new Map();
|
|
1171
|
-
while (entries.length < limit) {
|
|
1172
|
-
const page = await listRecordAuditLog({
|
|
1173
|
-
...params,
|
|
1174
|
-
cursor: cursor || void 0,
|
|
1175
|
-
limit: Math.min(200, limit - entries.length)
|
|
1176
|
-
});
|
|
1177
|
-
entries.push(...page.audit_logs.slice(0, limit - entries.length));
|
|
1178
|
-
for (const status of page.record_collections ?? []) {
|
|
1179
|
-
requestedNames.set(status.name, status.requested_name);
|
|
1180
|
-
}
|
|
1181
|
-
if (!page.pagination.has_more) break;
|
|
1182
|
-
const nextCursor = page.pagination.next_cursor?.trim();
|
|
1183
|
-
if (!nextCursor || nextCursor === cursor) {
|
|
1184
|
-
throw new Error("Audit log export could not continue");
|
|
1185
|
-
}
|
|
1186
|
-
if (entries.length >= limit) {
|
|
1187
|
-
truncated = true;
|
|
1188
|
-
break;
|
|
1189
|
-
}
|
|
1190
|
-
cursor = nextCursor;
|
|
1191
|
-
}
|
|
1192
|
-
const withRequestedNameAliases = (values) => {
|
|
1193
|
-
if (!values) return void 0;
|
|
1194
|
-
const merged = { ...values };
|
|
1195
|
-
for (const [apiName, requestedName] of requestedNames) {
|
|
1196
|
-
if (!merged[apiName] && merged[requestedName]) merged[apiName] = merged[requestedName];
|
|
1197
|
-
}
|
|
1198
|
-
return merged;
|
|
1199
|
-
};
|
|
1200
|
-
const resolvedOptions = {
|
|
1201
|
-
collectionLabels: withRequestedNameAliases(options.collectionLabels),
|
|
1202
|
-
activityNouns: withRequestedNameAliases(options.activityNouns)
|
|
1203
|
-
};
|
|
1204
|
-
return { csv: buildAuditLogCsv(entries, resolvedOptions), count: entries.length, truncated };
|
|
1205
|
-
}
|
|
1206
1197
|
const API_PREFIX = "/api";
|
|
1207
1198
|
const TERMINAL_STATUSES = ["succeeded", "failed", "cancelled"];
|
|
1208
1199
|
const ACTIVE_STATUSES = ["preparing", "queued", "running", "cancelling"];
|
|
@@ -1432,43 +1423,33 @@ async function listRunsByExternalId(params) {
|
|
|
1432
1423
|
});
|
|
1433
1424
|
}
|
|
1434
1425
|
export {
|
|
1435
|
-
|
|
1436
|
-
cancelAutomationRun as A,
|
|
1426
|
+
uploadFile as A,
|
|
1437
1427
|
BridgeError as B,
|
|
1438
|
-
|
|
1439
|
-
|
|
1428
|
+
automationStatuses as C,
|
|
1429
|
+
cancelAutomationRun as D,
|
|
1440
1430
|
EXPECTED_PARENT_ORIGIN as E,
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
auditLogRequestedCollectionName as _,
|
|
1431
|
+
cancelRun as F,
|
|
1432
|
+
clearAutomationCache as G,
|
|
1433
|
+
createAutomationRun as H,
|
|
1434
|
+
createRun as I,
|
|
1435
|
+
ensureAutomationRun as J,
|
|
1436
|
+
ensureRun as K,
|
|
1437
|
+
getAutomationByExternalId as L,
|
|
1438
|
+
getAutomationRun as M,
|
|
1439
|
+
getAutomationRunFileDownloadUrl as N,
|
|
1440
|
+
getRun as O,
|
|
1441
|
+
getRunFiles as P,
|
|
1442
|
+
getRunFileUrl as Q,
|
|
1443
|
+
isActiveStatus as R,
|
|
1444
|
+
isTerminalStatus as S,
|
|
1445
|
+
listAutomationRunFiles as T,
|
|
1446
|
+
listRuns as U,
|
|
1447
|
+
listRunsByAgent as V,
|
|
1448
|
+
listRunsByExternalId as W,
|
|
1449
|
+
pollAutomationRun as X,
|
|
1450
|
+
pollRun as Y,
|
|
1451
|
+
requestApi as Z,
|
|
1463
1452
|
getShareableAppUrl as a,
|
|
1464
|
-
getRecordAuditLogSnapshot as a0,
|
|
1465
|
-
listRecordAuditLog as a1,
|
|
1466
|
-
normalizeRecordAuditCollections as a2,
|
|
1467
|
-
normalizeAuditLogPageSize as a3,
|
|
1468
|
-
auditLogSummaryWithCollectionLabel as a4,
|
|
1469
|
-
auditLogDetailValue as a5,
|
|
1470
|
-
normalizeAuditLogFilterState as a6,
|
|
1471
|
-
normalizeAuditLogExportLimit as a7,
|
|
1472
1453
|
buildShareableAppUrl as b,
|
|
1473
1454
|
configureBridge as c,
|
|
1474
1455
|
parentApiStream as d,
|
|
@@ -1479,19 +1460,19 @@ export {
|
|
|
1479
1460
|
isEmbedded as i,
|
|
1480
1461
|
pbBulkDelete as j,
|
|
1481
1462
|
pbBulkUpdate as k,
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1463
|
+
logout as l,
|
|
1464
|
+
pbCreate as m,
|
|
1465
|
+
pbDelete as n,
|
|
1485
1466
|
onInitMessage as o,
|
|
1486
1467
|
parentApiRequest as p,
|
|
1487
|
-
|
|
1488
|
-
|
|
1468
|
+
pbGet as q,
|
|
1469
|
+
redirectToLogin as r,
|
|
1489
1470
|
serializeBridgeRuntimeConfig as s,
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1471
|
+
pbList as t,
|
|
1472
|
+
pbSearch as u,
|
|
1473
|
+
pbSql as v,
|
|
1474
|
+
pbUpdate as w,
|
|
1475
|
+
pbUpdateRecord as x,
|
|
1476
|
+
pbUpsert as y,
|
|
1477
|
+
sendEmail as z
|
|
1497
1478
|
};
|
|
@@ -4,11 +4,11 @@ export type AuditLogDensity = 'compact' | 'comfortable';
|
|
|
4
4
|
export type AuditLogFilterState = AuditLogFilterStateData;
|
|
5
5
|
export type AuditLogRecord = AuditLogEntryData;
|
|
6
6
|
export type AuditLogProps = {
|
|
7
|
-
/**
|
|
7
|
+
/** Collections whose combined record history should be shown (maximum 20). */
|
|
8
8
|
collections: readonly string[];
|
|
9
|
-
/** Friendly display names keyed by
|
|
9
|
+
/** Friendly display names keyed by collection API name. */
|
|
10
10
|
collectionLabels?: Readonly<Record<string, string>>;
|
|
11
|
-
/** Singular activity nouns keyed by
|
|
11
|
+
/** Singular activity nouns keyed by collection API name, e.g. "invoice" or "payment". */
|
|
12
12
|
activityNouns?: Readonly<Record<string, string>>;
|
|
13
13
|
/** Controlled filter state. */
|
|
14
14
|
filters?: AuditLogFilterState;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AuditLog.d.ts","sourceRoot":"","sources":["../../../src/components/audit-log/AuditLog.tsx"],"names":[],"mappings":"AAYA,OAAO,EAAE,KAAK,SAAS,
|
|
1
|
+
{"version":3,"file":"AuditLog.d.ts","sourceRoot":"","sources":["../../../src/components/audit-log/AuditLog.tsx"],"names":[],"mappings":"AAYA,OAAO,EAAE,KAAK,SAAS,EAA4B,MAAM,OAAO,CAAC;AAmBjE,OAAO,EAGL,KAAK,aAAa,IAAI,iBAAiB,EAEvC,KAAK,mBAAmB,IAAI,uBAAuB,EAOpD,MAAM,iBAAiB,CAAC;AAGzB,MAAM,MAAM,eAAe,GAAG,SAAS,GAAG,aAAa,CAAC;AACxD,MAAM,MAAM,mBAAmB,GAAG,uBAAuB,CAAC;AAC1D,MAAM,MAAM,cAAc,GAAG,iBAAiB,CAAC;AAE/C,MAAM,MAAM,aAAa,GAAG;IAC1B,8EAA8E;IAC9E,WAAW,EAAE,SAAS,MAAM,EAAE,CAAC;IAC/B,2DAA2D;IAC3D,gBAAgB,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACpD,yFAAyF;IACzF,aAAa,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACjD,+BAA+B;IAC/B,OAAO,CAAC,EAAE,mBAAmB,CAAC;IAC9B,gEAAgE;IAChE,cAAc,CAAC,EAAE,OAAO,CAAC,mBAAmB,CAAC,CAAC;IAC9C,iFAAiF;IACjF,eAAe,CAAC,EAAE,CAAC,OAAO,EAAE,mBAAmB,KAAK,IAAI,CAAC;IACzD,qEAAqE;IACrE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,+EAA+E;IAC/E,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,sEAAsE;IACtE,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,2CAA2C;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,0CAA0C;IAC1C,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,oDAAoD;IACpD,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,+CAA+C;IAC/C,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,6EAA6E;IAC7E,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,mEAAmE;IACnE,WAAW,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IAC/C,sEAAsE;IACtE,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,iBAAiB,KAAK,MAAM,GAAG,SAAS,CAAC;IACjE,8DAA8D;IAC9D,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,iBAAiB,KAAK,IAAI,CAAC;IACnD,2DAA2D;IAC3D,YAAY,CAAC,EAAE,SAAS,CAAC;IACzB,yDAAyD;IACzD,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,mDAAmD;IACnD,UAAU,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,SAAS,CAAC;IACzC,gDAAgD;IAChD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AA4FF,wBAAgB,QAAQ,CAAC,EACvB,WAAW,EACX,gBAAgB,EAChB,aAAa,EACb,OAAO,EAAE,iBAAiB,EAC1B,cAAc,EACd,eAAe,EACf,QAAa,EACb,aAAa,EACb,cAAc,EACd,KAAkB,EAClB,OAAmB,EACnB,oBAA2B,EAC3B,eAAsB,EACtB,gBAAuB,EACvB,WAAW,EACX,aAAa,EACb,aAAa,EACb,YAAY,EACZ,UAAU,EACV,UAAU,EACV,SAAS,GACV,EAAE,aAAa,2CAyiBf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AuditLogEntry.d.ts","sourceRoot":"","sources":["../../../src/components/audit-log/AuditLogEntry.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAGvE,OAAO,EACL,KAAK,aAAa,IAAI,iBAAiB,EAMxC,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"AuditLogEntry.d.ts","sourceRoot":"","sources":["../../../src/components/audit-log/AuditLogEntry.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAGvE,OAAO,EACL,KAAK,aAAa,IAAI,iBAAiB,EAMxC,MAAM,iBAAiB,CAAC;AA6KzB,KAAK,kBAAkB,GAAG;IACxB,KAAK,EAAE,iBAAiB,CAAC;IACzB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,eAAe,EAAE,MAAM,CAAC;IACxB,uBAAuB,CAAC,EAAE,MAAM,CAAC;IACjC,OAAO,EAAE,eAAe,CAAC;IACzB,oBAAoB,EAAE,OAAO,CAAC;IAC9B,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,WAAW,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IAC/C,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,iBAAiB,KAAK,MAAM,GAAG,SAAS,CAAC;IACjE,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,iBAAiB,KAAK,IAAI,CAAC;CACpD,CAAC;AAEF,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,iBAAiB,EACjB,eAAe,EACf,uBAAuB,EACvB,OAAO,EACP,oBAAoB,EACpB,eAAe,EACf,gBAAgB,EAChB,WAAW,EACX,WAAW,EACX,aAAa,EACb,aAAa,GACd,EAAE,kBAAkB,2CA6HpB"}
|
package/dist/components/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A, a, e, j, k, n, o, p, D, q, r, R, T, b, c, d, f, g, h, i, l, u, w, m } from "../RecordSheet-
|
|
1
|
+
import { A, a, e, j, k, n, o, p, D, q, r, R, T, b, c, d, f, g, h, i, l, u, w, m } from "../RecordSheet-BGs3rudM.js";
|
|
2
2
|
export {
|
|
3
3
|
A as AgentChat,
|
|
4
4
|
a as ArtifactCard,
|
package/dist/{highlighted-body-OFNGDK62-CkZgLnjq.js → highlighted-body-OFNGDK62-V6FEuBTg.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as R$1, L as Li, v as At } from "./RecordSheet-
|
|
1
|
+
import { t as R$1, L as Li, v as At } from "./RecordSheet-BGs3rudM.js";
|
|
2
2
|
import { useContext, useState, useEffect } from "react";
|
|
3
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
var R = ({ code: s, language: e, raw: t, className: h, startLine: d, lineNumbers: m, ...p }) => {
|
package/dist/hooks/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { u, a, b, c } from "../use-automation-run-
|
|
2
|
-
import { u as u2, a as a2, b as b2, c as c2, d, e } from "../use-sql-table-
|
|
1
|
+
import { u, a, b, c } from "../use-automation-run-D6DIaHy3.js";
|
|
2
|
+
import { u as u2, a as a2, b as b2, c as c2, d, e } from "../use-sql-table-BfA0A-w3.js";
|
|
3
3
|
export {
|
|
4
4
|
u as useAgentChat,
|
|
5
5
|
a as useAgentChatSessions,
|
package/dist/index.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import { A, a, e, j, k, n, o, p, D, q, r, R, T, b, c, d, f, g, h, i, l, u, w, m } from "./RecordSheet-
|
|
2
|
-
import { u as u2, a as a2, b as b2, c as c2 } from "./use-automation-run-
|
|
3
|
-
import { u as u3, a as a3, b as b3, c as c3, d as d2, e as e2 } from "./use-sql-table-
|
|
4
|
-
import {
|
|
1
|
+
import { A, a, e, j, k, n, o, p, D, q, r, R, T, b, c, d, f, g, h, i, l, u, w, m } from "./RecordSheet-BGs3rudM.js";
|
|
2
|
+
import { u as u2, a as a2, b as b2, c as c2 } from "./use-automation-run-D6DIaHy3.js";
|
|
3
|
+
import { u as u3, a as a3, b as b3, c as c3, d as d2, e as e2 } from "./use-sql-table-BfA0A-w3.js";
|
|
4
|
+
import { B, E, C, b as b4, D as D2, F, G, c as c4, H, I, J, K, g as g2, L, M, N, f as f2, O, Q, P, a as a4, h as h2, R as R2, i as i2, S, T as T2, U, V, W, l as l2, o as o2, p as p2, d as d3, j as j2, k as k2, m as m2, n as n2, q as q2, t, u as u4, v, w as w2, x, y, X, Y, e as e3, r as r2, z, s, A as A2 } from "./automations-DGUEnAYR.js";
|
|
5
5
|
import { o as o3, f as f3, a as a5, b as b5, c as c5, d as d4, e as e4, g as g3, h as h3, i as i3, j as j3, k as k3, l as l3, m as m3, n as n3, s as s2 } from "./formatters-D4T821Dv.js";
|
|
6
6
|
import { q as q3 } from "./query-client-DdOWay4_.js";
|
|
7
7
|
export {
|
|
8
|
-
X as AUDIT_LOG_EXPORT_LIMIT,
|
|
9
|
-
Y as AUDIT_LOG_MAX_COLLECTIONS,
|
|
10
8
|
A as AgentChat,
|
|
11
9
|
a as ArtifactCard,
|
|
12
10
|
e as AssistantChat,
|
|
@@ -23,22 +21,19 @@ export {
|
|
|
23
21
|
R as RecordSheet,
|
|
24
22
|
T as ToolCallCard,
|
|
25
23
|
b as ToolRenderersProvider,
|
|
26
|
-
|
|
27
|
-
_ as auditLogRequestedCollectionName,
|
|
28
|
-
z as automationStatuses,
|
|
24
|
+
C as automationStatuses,
|
|
29
25
|
b4 as buildShareableAppUrl,
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
26
|
+
D2 as cancelAutomationRun,
|
|
27
|
+
F as cancelRun,
|
|
28
|
+
G as clearAutomationCache,
|
|
33
29
|
o3 as cn,
|
|
34
30
|
c4 as configureBridge,
|
|
35
|
-
|
|
31
|
+
H as createAutomationRun,
|
|
36
32
|
c as createLumeraAgentChatTransport,
|
|
37
|
-
|
|
33
|
+
I as createRun,
|
|
38
34
|
d as defaultToolRenderers,
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
$ as fetchRecordAuditLogCsv,
|
|
35
|
+
J as ensureAutomationRun,
|
|
36
|
+
K as ensureRun,
|
|
42
37
|
f as findRenderer,
|
|
43
38
|
f3 as formatBoolean,
|
|
44
39
|
a5 as formatCellValue,
|
|
@@ -55,50 +50,50 @@ export {
|
|
|
55
50
|
m3 as formatSelect,
|
|
56
51
|
n3 as formatText,
|
|
57
52
|
g2 as getAppProjectExternalId,
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
53
|
+
L as getAutomationByExternalId,
|
|
54
|
+
M as getAutomationRun,
|
|
55
|
+
N as getAutomationRunFileDownloadUrl,
|
|
61
56
|
g as getCollectionMap,
|
|
62
57
|
f2 as getDownloadUrl,
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
N as getRunFiles,
|
|
58
|
+
O as getRun,
|
|
59
|
+
Q as getRunFileUrl,
|
|
60
|
+
P as getRunFiles,
|
|
67
61
|
a4 as getShareableAppUrl,
|
|
68
62
|
h2 as getUploadUrl,
|
|
69
63
|
h as humanizeCollectionName,
|
|
70
|
-
|
|
64
|
+
R2 as isActiveStatus,
|
|
71
65
|
i2 as isEmbedded,
|
|
72
66
|
i as isExploratoryToolCallError,
|
|
73
67
|
l as isMutatingToolCall,
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
68
|
+
S as isTerminalStatus,
|
|
69
|
+
T2 as listAutomationRunFiles,
|
|
70
|
+
U as listRuns,
|
|
71
|
+
V as listRunsByAgent,
|
|
72
|
+
W as listRunsByExternalId,
|
|
73
|
+
l2 as logout,
|
|
80
74
|
o2 as onInitMessage,
|
|
81
75
|
p2 as parentApiRequest,
|
|
82
76
|
d3 as parentApiStream,
|
|
83
77
|
j2 as pbBulkDelete,
|
|
84
78
|
k2 as pbBulkUpdate,
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
79
|
+
m2 as pbCreate,
|
|
80
|
+
n2 as pbDelete,
|
|
81
|
+
q2 as pbGet,
|
|
82
|
+
t as pbList,
|
|
83
|
+
u4 as pbSearch,
|
|
84
|
+
v as pbSql,
|
|
85
|
+
w2 as pbUpdate,
|
|
86
|
+
x as pbUpdateRecord,
|
|
87
|
+
y as pbUpsert,
|
|
88
|
+
X as pollAutomationRun,
|
|
89
|
+
Y as pollRun,
|
|
96
90
|
e3 as postReadyMessage,
|
|
97
91
|
q3 as queryClient,
|
|
98
|
-
|
|
92
|
+
r2 as redirectToLogin,
|
|
93
|
+
z as sendEmail,
|
|
99
94
|
s as serializeBridgeRuntimeConfig,
|
|
100
95
|
s2 as stripHtml,
|
|
101
|
-
|
|
96
|
+
A2 as uploadFile,
|
|
102
97
|
u2 as useAgentChat,
|
|
103
98
|
a2 as useAgentChatSessions,
|
|
104
99
|
b2 as useAuditLog,
|