@adoptai/genui-components 0.1.33 → 0.1.45
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 -0
- package/dist/builders/BuilderForm.d.ts +16 -1
- package/dist/builders/BuilderForm.d.ts.map +1 -1
- package/dist/builders/EscalationCard.d.ts +6 -1
- package/dist/builders/EscalationCard.d.ts.map +1 -1
- package/dist/builders/FieldRenderer.d.ts +5 -1
- package/dist/builders/FieldRenderer.d.ts.map +1 -1
- package/dist/builders/FormBuilder.d.ts +7 -1
- package/dist/builders/FormBuilder.d.ts.map +1 -1
- package/dist/builders/StepperBuilder.d.ts +6 -1
- package/dist/builders/StepperBuilder.d.ts.map +1 -1
- package/dist/builders/fields.d.ts +5 -1
- package/dist/builders/fields.d.ts.map +1 -1
- package/dist/builders/resolver.d.ts +11 -0
- package/dist/builders/resolver.d.ts.map +1 -1
- package/dist/composites/aging-report/resolver.cjs +1 -1
- package/dist/composites/aging-report/resolver.cjs.map +1 -1
- package/dist/composites/aging-report/resolver.js +1 -1
- package/dist/composites/aging-report/resolver.js.map +1 -1
- package/dist/composites/balance-sheet/resolver.cjs +1 -1
- package/dist/composites/balance-sheet/resolver.cjs.map +1 -1
- package/dist/composites/balance-sheet/resolver.js +1 -1
- package/dist/composites/balance-sheet/resolver.js.map +1 -1
- package/dist/composites/connect-integration/resolver.cjs +465 -0
- package/dist/composites/connect-integration/resolver.cjs.map +1 -0
- package/dist/composites/connect-integration/resolver.js +463 -0
- package/dist/composites/connect-integration/resolver.js.map +1 -0
- package/dist/composites/entity-card-grid/resolver.cjs +2 -2
- package/dist/composites/entity-card-grid/resolver.cjs.map +1 -1
- package/dist/composites/entity-card-grid/resolver.js +2 -2
- package/dist/composites/entity-card-grid/resolver.js.map +1 -1
- package/dist/composites/general-ledger/resolver.cjs +1 -0
- package/dist/composites/general-ledger/resolver.cjs.map +1 -1
- package/dist/composites/general-ledger/resolver.d.ts.map +1 -1
- package/dist/composites/general-ledger/resolver.js +1 -0
- package/dist/composites/general-ledger/resolver.js.map +1 -1
- package/dist/composites/income-statement/resolver.cjs +1 -1
- package/dist/composites/income-statement/resolver.cjs.map +1 -1
- package/dist/composites/income-statement/resolver.js +1 -1
- package/dist/composites/income-statement/resolver.js.map +1 -1
- package/dist/composites/integrations-list/resolver.cjs +511 -0
- package/dist/composites/integrations-list/resolver.cjs.map +1 -0
- package/dist/composites/integrations-list/resolver.js +509 -0
- package/dist/composites/integrations-list/resolver.js.map +1 -0
- package/dist/composites/key-value-list/resolver.cjs +28 -3
- package/dist/composites/key-value-list/resolver.cjs.map +1 -1
- package/dist/composites/key-value-list/resolver.d.ts.map +1 -1
- package/dist/composites/key-value-list/resolver.js +28 -3
- package/dist/composites/key-value-list/resolver.js.map +1 -1
- package/dist/composites/pipeline-preview/resolver.cjs +926 -0
- package/dist/composites/pipeline-preview/resolver.cjs.map +1 -0
- package/dist/composites/pipeline-preview/resolver.js +924 -0
- package/dist/composites/pipeline-preview/resolver.js.map +1 -0
- package/dist/composites/reconciliation-view/resolver.cjs +90 -32
- package/dist/composites/reconciliation-view/resolver.cjs.map +1 -1
- package/dist/composites/reconciliation-view/resolver.d.ts.map +1 -1
- package/dist/composites/reconciliation-view/resolver.js +91 -33
- package/dist/composites/reconciliation-view/resolver.js.map +1 -1
- package/dist/composites/stacked-breakdown/resolver.cjs +13 -2
- package/dist/composites/stacked-breakdown/resolver.cjs.map +1 -1
- package/dist/composites/stacked-breakdown/resolver.d.ts.map +1 -1
- package/dist/composites/stacked-breakdown/resolver.js +13 -2
- package/dist/composites/stacked-breakdown/resolver.js.map +1 -1
- package/dist/composites/stat-grid/resolver.cjs +83 -5
- package/dist/composites/stat-grid/resolver.cjs.map +1 -1
- package/dist/composites/stat-grid/resolver.d.ts.map +1 -1
- package/dist/composites/stat-grid/resolver.js +84 -6
- package/dist/composites/stat-grid/resolver.js.map +1 -1
- package/dist/composites/trial-balance/resolver.cjs +1 -1
- package/dist/composites/trial-balance/resolver.cjs.map +1 -1
- package/dist/composites/trial-balance/resolver.js +1 -1
- package/dist/composites/trial-balance/resolver.js.map +1 -1
- package/dist/composites/variance-analysis/resolver.cjs +1 -1
- package/dist/composites/variance-analysis/resolver.cjs.map +1 -1
- package/dist/composites/variance-analysis/resolver.js +1 -1
- package/dist/composites/variance-analysis/resolver.js.map +1 -1
- package/dist/composites/workflow-stepper/resolver.cjs +976 -0
- package/dist/composites/workflow-stepper/resolver.cjs.map +1 -0
- package/dist/composites/workflow-stepper/resolver.d.ts +20 -0
- package/dist/composites/workflow-stepper/resolver.d.ts.map +1 -0
- package/dist/composites/workflow-stepper/resolver.js +969 -0
- package/dist/composites/workflow-stepper/resolver.js.map +1 -0
- package/dist/index.cjs +1182 -275
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1019 -120
- package/dist/index.js.map +1 -1
- package/dist/renderer.cjs +1067 -211
- package/dist/renderer.cjs.map +1 -1
- package/dist/renderer.js +929 -73
- package/dist/renderer.js.map +1 -1
- package/dist/resolver.cjs +1066 -210
- package/dist/resolver.cjs.map +1 -1
- package/dist/resolver.d.ts.map +1 -1
- package/dist/resolver.js +929 -73
- package/dist/resolver.js.map +1 -1
- package/dist/schemas/index.cjs +75 -1
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.d.ts +122 -0
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +75 -1
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/workflow-stepper.d.ts +122 -0
- package/dist/schemas/workflow-stepper.d.ts.map +1 -0
- package/dist/shared/FitText.d.ts +22 -0
- package/dist/shared/FitText.d.ts.map +1 -0
- package/dist/shared/InteractionContext.d.ts +20 -0
- package/dist/shared/InteractionContext.d.ts.map +1 -0
- package/dist/shared/styles.d.ts +14 -0
- package/dist/shared/styles.d.ts.map +1 -0
- package/dist/tool-definitions.json +114 -3
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var React41 = require('react');
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var dagre = require('@dagrejs/dagre');
|
|
7
7
|
var reactDom = require('react-dom');
|
|
@@ -37,7 +37,7 @@ function _interopNamespace(e) {
|
|
|
37
37
|
return Object.freeze(n);
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
-
var
|
|
40
|
+
var React41__default = /*#__PURE__*/_interopDefault(React41);
|
|
41
41
|
var dagre__default = /*#__PURE__*/_interopDefault(dagre);
|
|
42
42
|
var XLSX__namespace = /*#__PURE__*/_interopNamespace(XLSX);
|
|
43
43
|
var Papa__default = /*#__PURE__*/_interopDefault(Papa);
|
|
@@ -111,14 +111,14 @@ var init_theme = __esm({
|
|
|
111
111
|
}
|
|
112
112
|
});
|
|
113
113
|
function GenUIThemeProvider({ colors, children }) {
|
|
114
|
-
const merged =
|
|
114
|
+
const merged = React41.useMemo(
|
|
115
115
|
() => colors ? __spreadValues(__spreadValues({}, exports.DEFAULT_TOKENS), colors) : exports.DEFAULT_TOKENS,
|
|
116
116
|
[colors]
|
|
117
117
|
);
|
|
118
118
|
return /* @__PURE__ */ jsxRuntime.jsx(GenUIThemeContext.Provider, { value: merged, children });
|
|
119
119
|
}
|
|
120
120
|
function useTheme() {
|
|
121
|
-
return
|
|
121
|
+
return React41.useContext(GenUIThemeContext);
|
|
122
122
|
}
|
|
123
123
|
exports.DEFAULT_TOKENS = void 0; var GenUIThemeContext;
|
|
124
124
|
var init_ThemeContext = __esm({
|
|
@@ -134,7 +134,7 @@ var init_ThemeContext = __esm({
|
|
|
134
134
|
SECONDARY: exports.SECONDARY,
|
|
135
135
|
CHART_PALETTE: [...exports.CHART_PALETTE]
|
|
136
136
|
};
|
|
137
|
-
GenUIThemeContext =
|
|
137
|
+
GenUIThemeContext = React41.createContext(exports.DEFAULT_TOKENS);
|
|
138
138
|
}
|
|
139
139
|
});
|
|
140
140
|
function renderInline(text) {
|
|
@@ -864,11 +864,11 @@ async function getMermaid(t) {
|
|
|
864
864
|
}
|
|
865
865
|
function MermaidFallback({ diagram, title }) {
|
|
866
866
|
const tokens = useTheme();
|
|
867
|
-
const [svg, setSvg] =
|
|
868
|
-
const [err, setErr] =
|
|
869
|
-
const [full, setFull] =
|
|
870
|
-
const idRef =
|
|
871
|
-
|
|
867
|
+
const [svg, setSvg] = React41.useState("");
|
|
868
|
+
const [err, setErr] = React41.useState(false);
|
|
869
|
+
const [full, setFull] = React41.useState(false);
|
|
870
|
+
const idRef = React41.useRef(0);
|
|
871
|
+
React41.useEffect(() => {
|
|
872
872
|
const id = ++renderSeq;
|
|
873
873
|
idRef.current = id;
|
|
874
874
|
setErr(false);
|
|
@@ -937,7 +937,7 @@ function FullscreenModalInner({ nodes, edges, title, onClose }) {
|
|
|
937
937
|
] }) });
|
|
938
938
|
}
|
|
939
939
|
function FullscreenModal({ nodes, edges, title, onClose }) {
|
|
940
|
-
|
|
940
|
+
React41.useEffect(() => {
|
|
941
941
|
const h = (e) => {
|
|
942
942
|
if (e.key === "Escape") onClose();
|
|
943
943
|
};
|
|
@@ -950,8 +950,8 @@ function FullscreenModal({ nodes, edges, title, onClose }) {
|
|
|
950
950
|
);
|
|
951
951
|
}
|
|
952
952
|
function usePrefersReducedMotion() {
|
|
953
|
-
const [reduced, setReduced] =
|
|
954
|
-
|
|
953
|
+
const [reduced, setReduced] = React41.useState(false);
|
|
954
|
+
React41.useEffect(() => {
|
|
955
955
|
var _a;
|
|
956
956
|
if (typeof matchMedia === "undefined") return;
|
|
957
957
|
const mq = matchMedia("(prefers-reduced-motion: reduce)");
|
|
@@ -995,9 +995,9 @@ function topoOrder(nodeIds, edges) {
|
|
|
995
995
|
}
|
|
996
996
|
function useAutoplay(order, enabled) {
|
|
997
997
|
const reduced = usePrefersReducedMotion();
|
|
998
|
-
const [step, setStep] =
|
|
998
|
+
const [step, setStep] = React41.useState(0);
|
|
999
999
|
const key = order.join("|");
|
|
1000
|
-
|
|
1000
|
+
React41.useEffect(() => {
|
|
1001
1001
|
if (!enabled || reduced || order.length === 0) {
|
|
1002
1002
|
setStep(0);
|
|
1003
1003
|
return;
|
|
@@ -1019,7 +1019,7 @@ function useAutoplay(order, enabled) {
|
|
|
1019
1019
|
timer = setTimeout(tick, 850);
|
|
1020
1020
|
return () => clearTimeout(timer);
|
|
1021
1021
|
}, [enabled, reduced, key]);
|
|
1022
|
-
return
|
|
1022
|
+
return React41.useMemo(() => {
|
|
1023
1023
|
const m = {};
|
|
1024
1024
|
order.forEach((id, i) => {
|
|
1025
1025
|
m[id] = i < step ? "done" : i === step ? "active" : "pending";
|
|
@@ -1041,13 +1041,13 @@ function resolveStates(nodes, nodeStates) {
|
|
|
1041
1041
|
}
|
|
1042
1042
|
function Inner({ diagram, title, autoplay, nodeStates }) {
|
|
1043
1043
|
const tokens = useTheme();
|
|
1044
|
-
const [full, setFull] =
|
|
1045
|
-
const [focused, setFocused] =
|
|
1046
|
-
const [boxW, setBoxW] =
|
|
1047
|
-
const containerRef =
|
|
1048
|
-
const parsed =
|
|
1049
|
-
const layout =
|
|
1050
|
-
const themedEdges =
|
|
1044
|
+
const [full, setFull] = React41.useState(false);
|
|
1045
|
+
const [focused, setFocused] = React41.useState(false);
|
|
1046
|
+
const [boxW, setBoxW] = React41.useState(640);
|
|
1047
|
+
const containerRef = React41.useRef(null);
|
|
1048
|
+
const parsed = React41.useMemo(() => parseMermaidFlow(diagram), [diagram]);
|
|
1049
|
+
const layout = React41.useMemo(() => parsed ? computeLayout(parsed) : null, [parsed]);
|
|
1050
|
+
const themedEdges = React41.useMemo(
|
|
1051
1051
|
() => {
|
|
1052
1052
|
var _a;
|
|
1053
1053
|
return ((_a = layout == null ? void 0 : layout.edges) != null ? _a : []).map((e) => __spreadProps(__spreadValues({}, e), {
|
|
@@ -1059,7 +1059,7 @@ function Inner({ diagram, title, autoplay, nodeStates }) {
|
|
|
1059
1059
|
},
|
|
1060
1060
|
[layout, tokens.ACCENT, tokens.MUTED]
|
|
1061
1061
|
);
|
|
1062
|
-
const order =
|
|
1062
|
+
const order = React41.useMemo(
|
|
1063
1063
|
() => {
|
|
1064
1064
|
var _a, _b;
|
|
1065
1065
|
return topoOrder(((_a = layout == null ? void 0 : layout.nodes) != null ? _a : []).map((n) => n.id), (_b = layout == null ? void 0 : layout.edges) != null ? _b : []);
|
|
@@ -1067,19 +1067,19 @@ function Inner({ diagram, title, autoplay, nodeStates }) {
|
|
|
1067
1067
|
[layout]
|
|
1068
1068
|
);
|
|
1069
1069
|
const autoStatus = useAutoplay(order, !!autoplay);
|
|
1070
|
-
const staticStatus =
|
|
1070
|
+
const staticStatus = React41.useMemo(() => {
|
|
1071
1071
|
var _a;
|
|
1072
1072
|
return resolveStates((_a = layout == null ? void 0 : layout.nodes) != null ? _a : [], nodeStates);
|
|
1073
1073
|
}, [layout, nodeStates]);
|
|
1074
1074
|
const statusMap = autoplay ? autoStatus : staticStatus;
|
|
1075
|
-
const displayNodes =
|
|
1075
|
+
const displayNodes = React41.useMemo(
|
|
1076
1076
|
() => {
|
|
1077
1077
|
var _a;
|
|
1078
1078
|
return ((_a = layout == null ? void 0 : layout.nodes) != null ? _a : []).map((n) => __spreadProps(__spreadValues({}, n), { data: __spreadProps(__spreadValues({}, n.data), { status: statusMap[n.id] }) }));
|
|
1079
1079
|
},
|
|
1080
1080
|
[layout, statusMap]
|
|
1081
1081
|
);
|
|
1082
|
-
const displayEdges =
|
|
1082
|
+
const displayEdges = React41.useMemo(
|
|
1083
1083
|
() => themedEdges.map((e) => {
|
|
1084
1084
|
const ss = statusMap[e.source];
|
|
1085
1085
|
const ts = statusMap[e.target];
|
|
@@ -1099,13 +1099,13 @@ function Inner({ diagram, title, autoplay, nodeStates }) {
|
|
|
1099
1099
|
const [nodes, setNodes, onNC] = react.useNodesState(displayNodes);
|
|
1100
1100
|
const [edges, setEdges, onEC] = react.useEdgesState(displayEdges);
|
|
1101
1101
|
const rf = react.useReactFlow();
|
|
1102
|
-
|
|
1102
|
+
React41.useEffect(() => {
|
|
1103
1103
|
setNodes(displayNodes);
|
|
1104
1104
|
}, [displayNodes, setNodes]);
|
|
1105
|
-
|
|
1105
|
+
React41.useEffect(() => {
|
|
1106
1106
|
setEdges(displayEdges);
|
|
1107
1107
|
}, [displayEdges, setEdges]);
|
|
1108
|
-
|
|
1108
|
+
React41.useEffect(() => {
|
|
1109
1109
|
const id = requestAnimationFrame(() => {
|
|
1110
1110
|
try {
|
|
1111
1111
|
rf.fitView({ padding: 0.1 });
|
|
@@ -1114,14 +1114,14 @@ function Inner({ diagram, title, autoplay, nodeStates }) {
|
|
|
1114
1114
|
});
|
|
1115
1115
|
return () => cancelAnimationFrame(id);
|
|
1116
1116
|
}, [layout, rf]);
|
|
1117
|
-
const handleClickOutside =
|
|
1117
|
+
const handleClickOutside = React41.useCallback((e) => {
|
|
1118
1118
|
if (containerRef.current && !containerRef.current.contains(e.target)) setFocused(false);
|
|
1119
1119
|
}, []);
|
|
1120
|
-
|
|
1120
|
+
React41.useEffect(() => {
|
|
1121
1121
|
document.addEventListener("mousedown", handleClickOutside);
|
|
1122
1122
|
return () => document.removeEventListener("mousedown", handleClickOutside);
|
|
1123
1123
|
}, [handleClickOutside]);
|
|
1124
|
-
|
|
1124
|
+
React41.useEffect(() => {
|
|
1125
1125
|
const el = containerRef.current;
|
|
1126
1126
|
if (!el) return;
|
|
1127
1127
|
let raf = 0;
|
|
@@ -1280,15 +1280,15 @@ __export(PdfViewer_exports, {
|
|
|
1280
1280
|
PdfViewer: () => PdfViewer
|
|
1281
1281
|
});
|
|
1282
1282
|
function PdfViewer({ url, base64, onLoadSuccess }) {
|
|
1283
|
-
const [numPages, setNumPages] =
|
|
1284
|
-
const [currentPage, setCurrentPage] =
|
|
1285
|
-
const [loading, setLoading] =
|
|
1286
|
-
const handleLoad =
|
|
1283
|
+
const [numPages, setNumPages] = React41.useState(0);
|
|
1284
|
+
const [currentPage, setCurrentPage] = React41.useState(1);
|
|
1285
|
+
const [loading, setLoading] = React41.useState(true);
|
|
1286
|
+
const handleLoad = React41.useCallback(({ numPages: n }) => {
|
|
1287
1287
|
setNumPages(n);
|
|
1288
1288
|
setLoading(false);
|
|
1289
1289
|
onLoadSuccess == null ? void 0 : onLoadSuccess(n);
|
|
1290
1290
|
}, [onLoadSuccess]);
|
|
1291
|
-
|
|
1291
|
+
React41.useEffect(() => {
|
|
1292
1292
|
if (numPages <= 1) return;
|
|
1293
1293
|
const handler = (e) => {
|
|
1294
1294
|
var _a;
|
|
@@ -1384,13 +1384,13 @@ __export(ExcelViewer_exports, {
|
|
|
1384
1384
|
ExcelViewer: () => ExcelViewer
|
|
1385
1385
|
});
|
|
1386
1386
|
function ExcelViewer({ url, base64, onLoadSuccess }) {
|
|
1387
|
-
const [sheetNames, setSheetNames] =
|
|
1388
|
-
const [activeSheet, setActiveSheet] =
|
|
1389
|
-
const [data, setData] =
|
|
1390
|
-
const [loading, setLoading] =
|
|
1391
|
-
const [error, setError] =
|
|
1392
|
-
const wbRef =
|
|
1393
|
-
|
|
1387
|
+
const [sheetNames, setSheetNames] = React41.useState([]);
|
|
1388
|
+
const [activeSheet, setActiveSheet] = React41.useState(0);
|
|
1389
|
+
const [data, setData] = React41.useState([]);
|
|
1390
|
+
const [loading, setLoading] = React41.useState(true);
|
|
1391
|
+
const [error, setError] = React41.useState(null);
|
|
1392
|
+
const wbRef = React41.useRef(null);
|
|
1393
|
+
React41.useEffect(() => {
|
|
1394
1394
|
let cancelled = false;
|
|
1395
1395
|
setLoading(true);
|
|
1396
1396
|
setError(null);
|
|
@@ -1448,7 +1448,7 @@ function ExcelViewer({ url, base64, onLoadSuccess }) {
|
|
|
1448
1448
|
const rows = XLSX__namespace.utils.sheet_to_json(wbRef.current.Sheets[wbRef.current.SheetNames[idx]], { header: 1 });
|
|
1449
1449
|
setData(rows);
|
|
1450
1450
|
};
|
|
1451
|
-
|
|
1451
|
+
React41.useEffect(() => {
|
|
1452
1452
|
if (sheetNames.length <= 1) return;
|
|
1453
1453
|
const handler = (e) => {
|
|
1454
1454
|
var _a;
|
|
@@ -1573,10 +1573,10 @@ __export(CsvViewer_exports, {
|
|
|
1573
1573
|
});
|
|
1574
1574
|
function CsvViewer({ url, base64, delimiter, maxRows }) {
|
|
1575
1575
|
const { BORDER: BORDER4, MUTED: MUTED2, PAPER: PAPER2 } = useTheme();
|
|
1576
|
-
const [rows, setRows] =
|
|
1577
|
-
const [loading, setLoading] =
|
|
1578
|
-
const [error, setError] =
|
|
1579
|
-
|
|
1576
|
+
const [rows, setRows] = React41.useState([]);
|
|
1577
|
+
const [loading, setLoading] = React41.useState(true);
|
|
1578
|
+
const [error, setError] = React41.useState(null);
|
|
1579
|
+
React41.useEffect(() => {
|
|
1580
1580
|
let cancelled = false;
|
|
1581
1581
|
setLoading(true);
|
|
1582
1582
|
setError(null);
|
|
@@ -1695,10 +1695,10 @@ __export(TextViewer_exports, {
|
|
|
1695
1695
|
});
|
|
1696
1696
|
function TextViewer({ url, base64, markdown = false, maxLines }) {
|
|
1697
1697
|
const { MUTED: MUTED2 } = useTheme();
|
|
1698
|
-
const [text, setText] =
|
|
1699
|
-
const [loading, setLoading] =
|
|
1700
|
-
const [error, setError] =
|
|
1701
|
-
|
|
1698
|
+
const [text, setText] = React41.useState("");
|
|
1699
|
+
const [loading, setLoading] = React41.useState(true);
|
|
1700
|
+
const [error, setError] = React41.useState(null);
|
|
1701
|
+
React41.useEffect(() => {
|
|
1702
1702
|
let cancelled = false;
|
|
1703
1703
|
setLoading(true);
|
|
1704
1704
|
setError(null);
|
|
@@ -1796,10 +1796,10 @@ function sanitize(html) {
|
|
|
1796
1796
|
}
|
|
1797
1797
|
function DocxViewer({ url, base64 }) {
|
|
1798
1798
|
const { MUTED: MUTED2, BORDER: BORDER4 } = useTheme();
|
|
1799
|
-
const [html, setHtml] =
|
|
1800
|
-
const [loading, setLoading] =
|
|
1801
|
-
const [error, setError] =
|
|
1802
|
-
|
|
1799
|
+
const [html, setHtml] = React41.useState("");
|
|
1800
|
+
const [loading, setLoading] = React41.useState(true);
|
|
1801
|
+
const [error, setError] = React41.useState(null);
|
|
1802
|
+
React41.useEffect(() => {
|
|
1803
1803
|
let cancelled = false;
|
|
1804
1804
|
setLoading(true);
|
|
1805
1805
|
setError(null);
|
|
@@ -5242,6 +5242,79 @@ var pipelinePreviewTool = {
|
|
|
5242
5242
|
required: ["type", "name", "steps"]
|
|
5243
5243
|
}
|
|
5244
5244
|
};
|
|
5245
|
+
var workflowStepperSchema = zod.z.object({
|
|
5246
|
+
type: zod.z.literal("workflow-stepper"),
|
|
5247
|
+
id: zod.z.string().optional(),
|
|
5248
|
+
title: zod.z.string(),
|
|
5249
|
+
period: zod.z.string().optional(),
|
|
5250
|
+
badge: zod.z.string().optional(),
|
|
5251
|
+
active_step: zod.z.string().optional(),
|
|
5252
|
+
steps: zod.z.array(
|
|
5253
|
+
zod.z.object({
|
|
5254
|
+
id: zod.z.string(),
|
|
5255
|
+
n: zod.z.number().int().positive().optional(),
|
|
5256
|
+
title: zod.z.string(),
|
|
5257
|
+
sub: zod.z.string().optional(),
|
|
5258
|
+
status: zod.z.enum(["done", "active", "review", "pending", "failed"]),
|
|
5259
|
+
assignees: zod.z.array(
|
|
5260
|
+
zod.z.object({
|
|
5261
|
+
name: zod.z.string(),
|
|
5262
|
+
kind: zod.z.enum(["agent", "human"]),
|
|
5263
|
+
initials: zod.z.string().max(3).optional(),
|
|
5264
|
+
color: zod.z.string().optional(),
|
|
5265
|
+
role: zod.z.string().optional()
|
|
5266
|
+
})
|
|
5267
|
+
).max(6).optional()
|
|
5268
|
+
})
|
|
5269
|
+
).min(2).max(12)
|
|
5270
|
+
});
|
|
5271
|
+
var workflowStepperTool = {
|
|
5272
|
+
name: "render_workflow_stepper",
|
|
5273
|
+
description: "Render a recurring-process workflow stepper \u2014 a horizontal strip of sequential step cards (e.g. a monthly close pipeline) with per-step status (done/active/review/pending/failed) and human + agent assignee avatars. Use for org processes with named steps and owners, NOT for generic progress bars or project phase summaries.",
|
|
5274
|
+
input_schema: {
|
|
5275
|
+
type: "object",
|
|
5276
|
+
properties: {
|
|
5277
|
+
type: { type: "string", enum: ["workflow-stepper"] },
|
|
5278
|
+
id: { type: "string", description: "Stable id for update-in-place rendering" },
|
|
5279
|
+
title: { type: "string", description: "Process name, e.g. 'Monthly Close'" },
|
|
5280
|
+
period: { type: "string", description: "Period label, e.g. 'Period 04 \xB7 FY2026'" },
|
|
5281
|
+
badge: { type: "string", description: "Framework/compliance badge, e.g. 'SOX controlled'" },
|
|
5282
|
+
active_step: { type: "string", description: "Id of the currently active step" },
|
|
5283
|
+
steps: {
|
|
5284
|
+
type: "array",
|
|
5285
|
+
minItems: 2,
|
|
5286
|
+
maxItems: 12,
|
|
5287
|
+
items: {
|
|
5288
|
+
type: "object",
|
|
5289
|
+
properties: {
|
|
5290
|
+
id: { type: "string" },
|
|
5291
|
+
n: { type: "number", description: "Step number; defaults to index + 1" },
|
|
5292
|
+
title: { type: "string" },
|
|
5293
|
+
sub: { type: "string", description: "Short status caption, e.g. '7 accounts \xB7 2 exceptions'" },
|
|
5294
|
+
status: { type: "string", enum: ["done", "active", "review", "pending", "failed"] },
|
|
5295
|
+
assignees: {
|
|
5296
|
+
type: "array",
|
|
5297
|
+
maxItems: 6,
|
|
5298
|
+
items: {
|
|
5299
|
+
type: "object",
|
|
5300
|
+
properties: {
|
|
5301
|
+
name: { type: "string" },
|
|
5302
|
+
kind: { type: "string", enum: ["agent", "human"] },
|
|
5303
|
+
initials: { type: "string" },
|
|
5304
|
+
color: { type: "string" },
|
|
5305
|
+
role: { type: "string" }
|
|
5306
|
+
},
|
|
5307
|
+
required: ["name", "kind"]
|
|
5308
|
+
}
|
|
5309
|
+
}
|
|
5310
|
+
},
|
|
5311
|
+
required: ["id", "title", "status"]
|
|
5312
|
+
}
|
|
5313
|
+
}
|
|
5314
|
+
},
|
|
5315
|
+
required: ["type", "title", "steps"]
|
|
5316
|
+
}
|
|
5317
|
+
};
|
|
5245
5318
|
|
|
5246
5319
|
// src/schemas/buildRenderUITool.ts
|
|
5247
5320
|
function buildRenderUITool(selectedSchemas) {
|
|
@@ -5359,7 +5432,8 @@ var schemaRegistry = {
|
|
|
5359
5432
|
"scatter-chart": { schema: scatterChartSchema, tool: scatterChartTool },
|
|
5360
5433
|
"connect-integration": { schema: connectIntegrationSchema, tool: connectIntegrationTool },
|
|
5361
5434
|
"integrations-list": { schema: integrationsListSchema, tool: integrationsListTool },
|
|
5362
|
-
"pipeline-preview": { schema: pipelinePreviewSchema, tool: pipelinePreviewTool }
|
|
5435
|
+
"pipeline-preview": { schema: pipelinePreviewSchema, tool: pipelinePreviewTool },
|
|
5436
|
+
"workflow-stepper": { schema: workflowStepperSchema, tool: workflowStepperTool }
|
|
5363
5437
|
};
|
|
5364
5438
|
|
|
5365
5439
|
// src/shared/ColumnSettingsPanel.tsx
|
|
@@ -5411,16 +5485,16 @@ init_theme();
|
|
|
5411
5485
|
var DOT_COLOR = "#aaaaaa";
|
|
5412
5486
|
var DOT_HOVER = "#555555";
|
|
5413
5487
|
function ComponentActions({ children, onDownloadCSV, columnConfig, filename = "component" }) {
|
|
5414
|
-
const [open, setOpen] =
|
|
5415
|
-
const [view, setView] =
|
|
5416
|
-
const contentRef =
|
|
5417
|
-
const menuRef =
|
|
5418
|
-
const btnRef =
|
|
5419
|
-
const close =
|
|
5488
|
+
const [open, setOpen] = React41.useState(false);
|
|
5489
|
+
const [view, setView] = React41.useState("main");
|
|
5490
|
+
const contentRef = React41.useRef(null);
|
|
5491
|
+
const menuRef = React41.useRef(null);
|
|
5492
|
+
const btnRef = React41.useRef(null);
|
|
5493
|
+
const close = React41.useCallback(() => {
|
|
5420
5494
|
setOpen(false);
|
|
5421
5495
|
setView("main");
|
|
5422
5496
|
}, []);
|
|
5423
|
-
|
|
5497
|
+
React41.useEffect(() => {
|
|
5424
5498
|
if (!open) return;
|
|
5425
5499
|
const handler = (e) => {
|
|
5426
5500
|
var _a, _b;
|
|
@@ -5431,7 +5505,7 @@ function ComponentActions({ children, onDownloadCSV, columnConfig, filename = "c
|
|
|
5431
5505
|
document.addEventListener("mousedown", handler);
|
|
5432
5506
|
return () => document.removeEventListener("mousedown", handler);
|
|
5433
5507
|
}, [open, close]);
|
|
5434
|
-
const handleDownloadPNG =
|
|
5508
|
+
const handleDownloadPNG = React41.useCallback(async () => {
|
|
5435
5509
|
if (!contentRef.current) return;
|
|
5436
5510
|
try {
|
|
5437
5511
|
const url = await htmlToImage.toPng(contentRef.current, { backgroundColor: "white", pixelRatio: 2 });
|
|
@@ -5443,7 +5517,7 @@ function ComponentActions({ children, onDownloadCSV, columnConfig, filename = "c
|
|
|
5443
5517
|
}
|
|
5444
5518
|
close();
|
|
5445
5519
|
}, [filename, close]);
|
|
5446
|
-
const handleCSV =
|
|
5520
|
+
const handleCSV = React41.useCallback(() => {
|
|
5447
5521
|
onDownloadCSV == null ? void 0 : onDownloadCSV();
|
|
5448
5522
|
close();
|
|
5449
5523
|
}, [onDownloadCSV, close]);
|
|
@@ -5555,12 +5629,12 @@ function MenuButton({ label, onClick }) {
|
|
|
5555
5629
|
);
|
|
5556
5630
|
}
|
|
5557
5631
|
function useColumnVisibility(columns) {
|
|
5558
|
-
const [hidden, setHidden] =
|
|
5559
|
-
const visibleColumns =
|
|
5632
|
+
const [hidden, setHidden] = React41.useState(/* @__PURE__ */ new Set());
|
|
5633
|
+
const visibleColumns = React41.useMemo(
|
|
5560
5634
|
() => columns.filter((c) => !hidden.has(c.key)),
|
|
5561
5635
|
[columns, hidden]
|
|
5562
5636
|
);
|
|
5563
|
-
const toggle =
|
|
5637
|
+
const toggle = React41.useCallback((key) => {
|
|
5564
5638
|
setHidden((prev) => {
|
|
5565
5639
|
const next = new Set(prev);
|
|
5566
5640
|
if (next.has(key)) next.delete(key);
|
|
@@ -5568,8 +5642,8 @@ function useColumnVisibility(columns) {
|
|
|
5568
5642
|
return next;
|
|
5569
5643
|
});
|
|
5570
5644
|
}, []);
|
|
5571
|
-
const showAll =
|
|
5572
|
-
const hideAll =
|
|
5645
|
+
const showAll = React41.useCallback(() => setHidden(/* @__PURE__ */ new Set()), []);
|
|
5646
|
+
const hideAll = React41.useCallback(
|
|
5573
5647
|
() => setHidden(new Set(columns.map((c) => c.key))),
|
|
5574
5648
|
[columns]
|
|
5575
5649
|
);
|
|
@@ -5819,6 +5893,61 @@ function AlertResolver(p) {
|
|
|
5819
5893
|
|
|
5820
5894
|
// src/composites/stat-grid/resolver.tsx
|
|
5821
5895
|
init_Markdown();
|
|
5896
|
+
function FitText({ children, max = 22, min = 13, title, className, style }) {
|
|
5897
|
+
const ref = React41.useRef(null);
|
|
5898
|
+
const [size, setSize] = React41.useState(max);
|
|
5899
|
+
React41.useLayoutEffect(() => {
|
|
5900
|
+
const el = ref.current;
|
|
5901
|
+
if (!el) return void 0;
|
|
5902
|
+
const fit = () => {
|
|
5903
|
+
let s = max;
|
|
5904
|
+
el.style.fontSize = `${s}px`;
|
|
5905
|
+
while (s > min && el.scrollWidth > el.clientWidth + 1) {
|
|
5906
|
+
s -= 1;
|
|
5907
|
+
el.style.fontSize = `${s}px`;
|
|
5908
|
+
}
|
|
5909
|
+
setSize(s);
|
|
5910
|
+
};
|
|
5911
|
+
fit();
|
|
5912
|
+
if (typeof ResizeObserver === "undefined") return void 0;
|
|
5913
|
+
const ro = new ResizeObserver(fit);
|
|
5914
|
+
ro.observe(el);
|
|
5915
|
+
return () => ro.disconnect();
|
|
5916
|
+
}, [children, max, min]);
|
|
5917
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5918
|
+
"span",
|
|
5919
|
+
{
|
|
5920
|
+
ref,
|
|
5921
|
+
title,
|
|
5922
|
+
className,
|
|
5923
|
+
style: __spreadValues({
|
|
5924
|
+
display: "block",
|
|
5925
|
+
minWidth: 0,
|
|
5926
|
+
maxWidth: "100%",
|
|
5927
|
+
whiteSpace: "nowrap",
|
|
5928
|
+
overflow: "hidden",
|
|
5929
|
+
textOverflow: "ellipsis",
|
|
5930
|
+
fontSize: `${size}px`
|
|
5931
|
+
}, style),
|
|
5932
|
+
children
|
|
5933
|
+
}
|
|
5934
|
+
);
|
|
5935
|
+
}
|
|
5936
|
+
|
|
5937
|
+
// src/shared/styles.ts
|
|
5938
|
+
var TRUNCATE = {
|
|
5939
|
+
minWidth: 0,
|
|
5940
|
+
overflow: "hidden",
|
|
5941
|
+
textOverflow: "ellipsis",
|
|
5942
|
+
whiteSpace: "nowrap"
|
|
5943
|
+
};
|
|
5944
|
+
var NUMERIC_CELL = {
|
|
5945
|
+
fontVariantNumeric: "tabular-nums",
|
|
5946
|
+
whiteSpace: "nowrap",
|
|
5947
|
+
textAlign: "right"
|
|
5948
|
+
};
|
|
5949
|
+
|
|
5950
|
+
// src/composites/stat-grid/resolver.tsx
|
|
5822
5951
|
init_ThemeContext();
|
|
5823
5952
|
var changeColor = (type) => {
|
|
5824
5953
|
if (type === "positive") return "#15803d";
|
|
@@ -5829,15 +5958,28 @@ var cardStyle = {
|
|
|
5829
5958
|
border: "1px solid #dedede",
|
|
5830
5959
|
borderRadius: "0.75rem",
|
|
5831
5960
|
background: "white",
|
|
5832
|
-
padding: "14px"
|
|
5961
|
+
padding: "14px",
|
|
5962
|
+
// Let the card shrink inside the grid track so big values can't push it
|
|
5963
|
+
// wider than its column.
|
|
5964
|
+
minWidth: 0,
|
|
5965
|
+
overflow: "hidden"
|
|
5833
5966
|
};
|
|
5834
5967
|
function StatGridResolver(p) {
|
|
5835
5968
|
var _a;
|
|
5836
5969
|
const { MUTED: MUTED2 } = useTheme();
|
|
5837
|
-
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: "stat-grid", children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: { width: "100%", display: "grid", gap: "10px", gridTemplateColumns: "repeat(auto-fill, minmax(140px, 1fr))" }, children: ((_a = p.stats) != null ? _a : []).map((stat, i) => /* @__PURE__ */ jsxRuntime.jsx("div", { style: cardStyle, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "4px", padding: "4px 0" }, children: [
|
|
5838
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontSize: "11.5px", color: MUTED2, letterSpacing: "0.02em", textTransform: "uppercase", margin: 0 }, children: stat.label }),
|
|
5839
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5840
|
-
|
|
5970
|
+
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: "stat-grid", children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: { width: "100%", display: "grid", gap: "10px", gridTemplateColumns: "repeat(auto-fill, minmax(min(140px, 100%), 1fr))" }, children: ((_a = p.stats) != null ? _a : []).map((stat, i) => /* @__PURE__ */ jsxRuntime.jsx("div", { style: cardStyle, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "4px", padding: "4px 0", minWidth: 0 }, children: [
|
|
5971
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { style: __spreadValues({ fontSize: "11.5px", color: MUTED2, letterSpacing: "0.02em", textTransform: "uppercase", margin: 0 }, TRUNCATE), children: stat.label }),
|
|
5972
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5973
|
+
FitText,
|
|
5974
|
+
{
|
|
5975
|
+
max: 22,
|
|
5976
|
+
min: 13,
|
|
5977
|
+
title: typeof stat.value === "string" ? stat.value : void 0,
|
|
5978
|
+
style: { fontFamily: "var(--font-serif)", fontWeight: 600, color: "var(--foreground)", letterSpacing: "-0.01em", lineHeight: 1.1, fontVariantNumeric: "tabular-nums" },
|
|
5979
|
+
children: stat.value
|
|
5980
|
+
}
|
|
5981
|
+
),
|
|
5982
|
+
stat.change && /* @__PURE__ */ jsxRuntime.jsx("p", { style: __spreadValues({ fontSize: "12px", fontWeight: 500, color: changeColor(stat.changeType), fontVariantNumeric: "tabular-nums", margin: 0 }, TRUNCATE), children: stat.change }),
|
|
5841
5983
|
stat.description && /* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontSize: "11.5px", color: "#888888", lineHeight: 1.4, margin: 0 }, children: /* @__PURE__ */ jsxRuntime.jsx(Markdown, { inline: true, content: stat.description }) })
|
|
5842
5984
|
] }) }, i)) }) });
|
|
5843
5985
|
}
|
|
@@ -5846,7 +5988,7 @@ init_ThemeContext();
|
|
|
5846
5988
|
function TabsPanelResolver(p) {
|
|
5847
5989
|
var _a;
|
|
5848
5990
|
const { BORDER: BORDER4, MUTED: MUTED2, PAPER: PAPER2, ACCENT: ACCENT2 } = useTheme();
|
|
5849
|
-
const [activeIdx, setActiveIdx] =
|
|
5991
|
+
const [activeIdx, setActiveIdx] = React41.useState(0);
|
|
5850
5992
|
const activeTab = p.tabs[activeIdx];
|
|
5851
5993
|
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: "tabs-panel", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { width: "100%", display: "flex", flexDirection: "column", gap: "0" }, children: [
|
|
5852
5994
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -6004,17 +6146,17 @@ function SparklineTableResolver(p) {
|
|
|
6004
6146
|
// src/composites/heatmap-table/resolver.tsx
|
|
6005
6147
|
init_theme();
|
|
6006
6148
|
init_ThemeContext();
|
|
6007
|
-
function heatColor(
|
|
6008
|
-
const clamped = Math.max(-3, Math.min(3,
|
|
6149
|
+
function heatColor(z59) {
|
|
6150
|
+
const clamped = Math.max(-3, Math.min(3, z59));
|
|
6009
6151
|
const abs = Math.abs(clamped);
|
|
6010
6152
|
const lightness = 95 - abs * 8;
|
|
6011
6153
|
const hue = clamped >= 0 ? 142 : 0;
|
|
6012
6154
|
return `hsl(${hue} 60% ${lightness}%)`;
|
|
6013
6155
|
}
|
|
6014
|
-
function heatTextColor(
|
|
6015
|
-
const abs = Math.abs(
|
|
6016
|
-
if (abs > 2) return
|
|
6017
|
-
if (abs > 1) return
|
|
6156
|
+
function heatTextColor(z59) {
|
|
6157
|
+
const abs = Math.abs(z59);
|
|
6158
|
+
if (abs > 2) return z59 >= 0 ? "#14532d" : "#7f1d1d";
|
|
6159
|
+
if (abs > 1) return z59 >= 0 ? "#166534" : "#991b1b";
|
|
6018
6160
|
return "var(--foreground)";
|
|
6019
6161
|
}
|
|
6020
6162
|
var th2 = {
|
|
@@ -6112,7 +6254,7 @@ var thStyle2 = {
|
|
|
6112
6254
|
function ScreenerTableResolver(p) {
|
|
6113
6255
|
var _a, _b, _c, _d, _e, _f;
|
|
6114
6256
|
const { ACCENT: ACCENT2, BORDER: BORDER4, MUTED: MUTED2, PAPER: PAPER2 } = useTheme();
|
|
6115
|
-
const [activeFilters, setActiveFilters] =
|
|
6257
|
+
const [activeFilters, setActiveFilters] = React41.useState(new Set((_a = p.activeFilters) != null ? _a : []));
|
|
6116
6258
|
const { visibleColumns, hidden, toggle, showAll, hideAll, allColumns } = useColumnVisibility((_b = p.columns) != null ? _b : []);
|
|
6117
6259
|
const toggleFilter = (f) => setActiveFilters((prev) => {
|
|
6118
6260
|
const next = new Set(prev);
|
|
@@ -6182,7 +6324,7 @@ var th3 = {
|
|
|
6182
6324
|
};
|
|
6183
6325
|
function GroupRows({ group, columns, depth }) {
|
|
6184
6326
|
var _a, _b;
|
|
6185
|
-
const [open, setOpen] =
|
|
6327
|
+
const [open, setOpen] = React41.useState(true);
|
|
6186
6328
|
const indent = depth * 14;
|
|
6187
6329
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
6188
6330
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -6287,7 +6429,7 @@ var dotColor = {
|
|
|
6287
6429
|
function NewsFeedResolver(p) {
|
|
6288
6430
|
var _a, _b;
|
|
6289
6431
|
const { ACCENT: ACCENT2, MUTED: MUTED2 } = useTheme();
|
|
6290
|
-
const [filter, setFilter] =
|
|
6432
|
+
const [filter, setFilter] = React41.useState(null);
|
|
6291
6433
|
const sentiments = ["positive", "neutral", "negative"].filter(
|
|
6292
6434
|
(s) => {
|
|
6293
6435
|
var _a2;
|
|
@@ -6329,9 +6471,9 @@ function NewsFeedResolver(p) {
|
|
|
6329
6471
|
] }) });
|
|
6330
6472
|
}
|
|
6331
6473
|
function useSeriesToggle(seriesKeys) {
|
|
6332
|
-
const [hidden, setHidden] =
|
|
6333
|
-
const isVisible =
|
|
6334
|
-
const toggle =
|
|
6474
|
+
const [hidden, setHidden] = React41.useState(/* @__PURE__ */ new Set());
|
|
6475
|
+
const isVisible = React41.useCallback((key) => !hidden.has(key), [hidden]);
|
|
6476
|
+
const toggle = React41.useCallback((key) => {
|
|
6335
6477
|
setHidden((prev) => {
|
|
6336
6478
|
const next = new Set(prev);
|
|
6337
6479
|
if (next.has(key)) next.delete(key);
|
|
@@ -6339,7 +6481,7 @@ function useSeriesToggle(seriesKeys) {
|
|
|
6339
6481
|
return next;
|
|
6340
6482
|
});
|
|
6341
6483
|
}, []);
|
|
6342
|
-
const showAll =
|
|
6484
|
+
const showAll = React41.useCallback(() => setHidden(/* @__PURE__ */ new Set()), []);
|
|
6343
6485
|
return { hidden, isVisible, toggle, showAll, allKeys: seriesKeys };
|
|
6344
6486
|
}
|
|
6345
6487
|
|
|
@@ -6634,7 +6776,7 @@ function WaterfallChartResolver(p) {
|
|
|
6634
6776
|
] }) });
|
|
6635
6777
|
}
|
|
6636
6778
|
init_ThemeContext();
|
|
6637
|
-
var FlowGraph2 =
|
|
6779
|
+
var FlowGraph2 = React41__default.default.lazy(
|
|
6638
6780
|
() => Promise.resolve().then(() => (init_FlowGraph(), FlowGraph_exports)).then((m) => ({ default: m.FlowGraph }))
|
|
6639
6781
|
);
|
|
6640
6782
|
function FlowCanvasRenderer({
|
|
@@ -6675,7 +6817,7 @@ function FlowCanvasRenderer({
|
|
|
6675
6817
|
overflow: "hidden",
|
|
6676
6818
|
background: "#ffffff",
|
|
6677
6819
|
position: "relative"
|
|
6678
|
-
}, diagram ? {} : { height: "320px" }), children: diagram ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
6820
|
+
}, diagram ? {} : { height: "320px" }), children: diagram ? /* @__PURE__ */ jsxRuntime.jsx(React41.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(FlowGraph2, { diagram, title, autoplay, nodeStates }) }) : /* @__PURE__ */ jsxRuntime.jsx("div", { style: {
|
|
6679
6821
|
position: "absolute",
|
|
6680
6822
|
inset: 0,
|
|
6681
6823
|
display: "flex",
|
|
@@ -6887,7 +7029,7 @@ function TrialBalanceResolver(p) {
|
|
|
6887
7029
|
color: balanced ? "#15803d" : "#dc2626"
|
|
6888
7030
|
}, children: balanced ? "\u2713 Balanced" : "\u2717 Unbalanced" })
|
|
6889
7031
|
] }),
|
|
6890
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.05)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "380px" }, children: [
|
|
7032
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", minWidth: 0, borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.05)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "380px" }, children: [
|
|
6891
7033
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { children: /* @__PURE__ */ jsxRuntime.jsx("tr", { children: ["Code", "Account", "Debit", "Credit"].map((h, i) => /* @__PURE__ */ jsxRuntime.jsx("th", { style: {
|
|
6892
7034
|
fontSize: "11px",
|
|
6893
7035
|
fontWeight: 500,
|
|
@@ -6908,7 +7050,7 @@ function TrialBalanceResolver(p) {
|
|
|
6908
7050
|
gDebit += a.debit;
|
|
6909
7051
|
gCredit += a.credit;
|
|
6910
7052
|
});
|
|
6911
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7053
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
6912
7054
|
/* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan: 4, style: {
|
|
6913
7055
|
padding: "8px 12px",
|
|
6914
7056
|
fontSize: "12px",
|
|
@@ -7065,7 +7207,7 @@ function AgingReportResolver(p) {
|
|
|
7065
7207
|
p.asOfDate
|
|
7066
7208
|
] })
|
|
7067
7209
|
] }),
|
|
7068
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.04)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse" }, children: [
|
|
7210
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", minWidth: 0, borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.04)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse" }, children: [
|
|
7069
7211
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { children: /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
|
|
7070
7212
|
/* @__PURE__ */ jsxRuntime.jsx("th", { style: { fontSize: "11px", fontWeight: 500, color: MUTED2, padding: "8px 12px", textAlign: "left", borderBottom: `1px solid ${BORDER4}`, background: PAPER2, textTransform: "uppercase", letterSpacing: "0.02em" }, children: "Entity" }),
|
|
7071
7213
|
buckets.map((b, i) => /* @__PURE__ */ jsxRuntime.jsx("th", { style: { fontSize: "11px", fontWeight: 500, color: MUTED2, padding: "8px 12px", textAlign: "right", borderBottom: `1px solid ${BORDER4}`, background: PAPER2, textTransform: "uppercase", letterSpacing: "0.02em", whiteSpace: "nowrap" }, children: b }, i)),
|
|
@@ -7122,7 +7264,7 @@ function VarianceAnalysisResolver(p) {
|
|
|
7122
7264
|
p.title && /* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontFamily: "var(--font-serif)", fontSize: "15px", fontWeight: 600, color: "var(--foreground)", letterSpacing: "-0.005em" }, children: p.title }),
|
|
7123
7265
|
p.period && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "11px", color: MUTED2 }, children: p.period })
|
|
7124
7266
|
] }),
|
|
7125
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.05)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "480px" }, children: [
|
|
7267
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", minWidth: 0, borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.05)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "480px" }, children: [
|
|
7126
7268
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { children: /* @__PURE__ */ jsxRuntime.jsx("tr", { children: ["Line Item", "Budget", "Actual", "Variance $", "Variance %", ""].map((h, i) => /* @__PURE__ */ jsxRuntime.jsx("th", { style: {
|
|
7127
7269
|
fontSize: "11px",
|
|
7128
7270
|
fontWeight: 500,
|
|
@@ -7240,6 +7382,8 @@ function StackedBreakdownResolver(p) {
|
|
|
7240
7382
|
alignItems: "center",
|
|
7241
7383
|
gap: "6px",
|
|
7242
7384
|
fontSize: "12px",
|
|
7385
|
+
maxWidth: "100%",
|
|
7386
|
+
minWidth: 0,
|
|
7243
7387
|
color: isVisible(cat.name) ? MUTED2 : "#b3b3b3",
|
|
7244
7388
|
cursor: "pointer",
|
|
7245
7389
|
userSelect: "none",
|
|
@@ -7251,12 +7395,13 @@ function StackedBreakdownResolver(p) {
|
|
|
7251
7395
|
width: "10px",
|
|
7252
7396
|
height: "10px",
|
|
7253
7397
|
borderRadius: "2px",
|
|
7398
|
+
flexShrink: 0,
|
|
7254
7399
|
background: (_a2 = cat.color) != null ? _a2 : PALETTE2[ci % PALETTE2.length],
|
|
7255
7400
|
display: "inline-block",
|
|
7256
7401
|
opacity: isVisible(cat.name) ? 1 : 0.3,
|
|
7257
7402
|
transition: "opacity 0.15s"
|
|
7258
7403
|
} }),
|
|
7259
|
-
cat.name
|
|
7404
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { style: TRUNCATE, title: cat.name, children: cat.name })
|
|
7260
7405
|
]
|
|
7261
7406
|
},
|
|
7262
7407
|
cat.name
|
|
@@ -7278,7 +7423,7 @@ function StackedBreakdownResolver(p) {
|
|
|
7278
7423
|
((_b2 = p.periods) != null ? _b2 : []).map((_, pi) => {
|
|
7279
7424
|
var _a3, _b3;
|
|
7280
7425
|
const v = pi < ((_a3 = cat.values) != null ? _a3 : []).length ? ((_b3 = cat.values) != null ? _b3 : [])[pi] : 0;
|
|
7281
|
-
return /* @__PURE__ */ jsxRuntime.jsx("td", { style: { padding: "6px 12px", fontSize: "13px", textAlign: "right", fontVariantNumeric: "tabular-nums", borderBottom: `1px solid #f2f2f2`, color: v < 0 ? "#dc2626" : void 0 }, children: v < 0 ? `(${fmt5(Math.abs(v), p.currency)})` : fmt5(v, p.currency) }, pi);
|
|
7426
|
+
return /* @__PURE__ */ jsxRuntime.jsx("td", { style: { padding: "6px 12px", fontSize: "13px", textAlign: "right", fontVariantNumeric: "tabular-nums", whiteSpace: "nowrap", borderBottom: `1px solid #f2f2f2`, color: v < 0 ? "#dc2626" : void 0 }, children: v < 0 ? `(${fmt5(Math.abs(v), p.currency)})` : fmt5(v, p.currency) }, pi);
|
|
7282
7427
|
})
|
|
7283
7428
|
] }, cat.name);
|
|
7284
7429
|
}),
|
|
@@ -7442,7 +7587,7 @@ function ItemRow({ item }) {
|
|
|
7442
7587
|
] });
|
|
7443
7588
|
}
|
|
7444
7589
|
function Section({ section }) {
|
|
7445
|
-
const [open, setOpen] =
|
|
7590
|
+
const [open, setOpen] = React41.useState(true);
|
|
7446
7591
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
7447
7592
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
7448
7593
|
"button",
|
|
@@ -7564,7 +7709,7 @@ function ReconciliationViewResolver(p) {
|
|
|
7564
7709
|
const { BORDER: BORDER4, MUTED: MUTED2, PAPER: PAPER2, ACCENT: ACCENT2 } = useTheme();
|
|
7565
7710
|
const sourceA = (_a = p.sourceA) != null ? _a : { label: "Source A" };
|
|
7566
7711
|
const sourceB = (_b = p.sourceB) != null ? _b : { label: "Source B" };
|
|
7567
|
-
const [activeTab, setActiveTab] =
|
|
7712
|
+
const [activeTab, setActiveTab] = React41.useState("matched");
|
|
7568
7713
|
const balanceA = (_d = (_c = p.summary) == null ? void 0 : _c.balanceA) != null ? _d : 0;
|
|
7569
7714
|
const balanceB = (_f = (_e = p.summary) == null ? void 0 : _e.balanceB) != null ? _f : 0;
|
|
7570
7715
|
const difference = (_h = (_g = p.summary) == null ? void 0 : _g.difference) != null ? _h : balanceA - balanceB;
|
|
@@ -7651,7 +7796,7 @@ function ReconciliationViewResolver(p) {
|
|
|
7651
7796
|
{
|
|
7652
7797
|
style: {
|
|
7653
7798
|
display: "grid",
|
|
7654
|
-
gridTemplateColumns: "repeat(auto-fit, minmax(
|
|
7799
|
+
gridTemplateColumns: "repeat(auto-fit, minmax(min(120px, 100%), 1fr))",
|
|
7655
7800
|
gap: "0",
|
|
7656
7801
|
marginBottom: "14px",
|
|
7657
7802
|
borderRadius: "10px",
|
|
@@ -7659,31 +7804,28 @@ function ReconciliationViewResolver(p) {
|
|
|
7659
7804
|
overflow: "hidden"
|
|
7660
7805
|
},
|
|
7661
7806
|
children: [
|
|
7662
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { padding: "10px 12px", background: PAPER2 }, children: [
|
|
7807
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { padding: "10px 12px", background: PAPER2, minWidth: 0 }, children: [
|
|
7663
7808
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7664
7809
|
"div",
|
|
7665
7810
|
{
|
|
7666
|
-
style: {
|
|
7811
|
+
style: __spreadValues({
|
|
7667
7812
|
fontSize: "10px",
|
|
7668
7813
|
fontWeight: 500,
|
|
7669
7814
|
color: MUTED2,
|
|
7670
7815
|
textTransform: "uppercase",
|
|
7671
7816
|
letterSpacing: "0.04em",
|
|
7672
7817
|
marginBottom: "4px"
|
|
7673
|
-
},
|
|
7818
|
+
}, TRUNCATE),
|
|
7674
7819
|
children: sourceA.label
|
|
7675
7820
|
}
|
|
7676
7821
|
),
|
|
7677
7822
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7678
|
-
|
|
7823
|
+
FitText,
|
|
7679
7824
|
{
|
|
7680
|
-
|
|
7681
|
-
|
|
7682
|
-
|
|
7683
|
-
|
|
7684
|
-
fontVariantNumeric: "tabular-nums",
|
|
7685
|
-
letterSpacing: "-0.01em"
|
|
7686
|
-
},
|
|
7825
|
+
max: 15,
|
|
7826
|
+
min: 11,
|
|
7827
|
+
title: fmt6(balanceA, p.currency),
|
|
7828
|
+
style: { fontWeight: 600, color: "var(--foreground)", fontVariantNumeric: "tabular-nums", letterSpacing: "-0.01em" },
|
|
7687
7829
|
children: fmt6(balanceA, p.currency)
|
|
7688
7830
|
}
|
|
7689
7831
|
)
|
|
@@ -7695,33 +7837,31 @@ function ReconciliationViewResolver(p) {
|
|
|
7695
7837
|
padding: "10px 12px",
|
|
7696
7838
|
background: PAPER2,
|
|
7697
7839
|
borderLeft: `1px solid ${BORDER4}`,
|
|
7698
|
-
borderRight: `1px solid ${BORDER4}
|
|
7840
|
+
borderRight: `1px solid ${BORDER4}`,
|
|
7841
|
+
minWidth: 0
|
|
7699
7842
|
},
|
|
7700
7843
|
children: [
|
|
7701
7844
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7702
7845
|
"div",
|
|
7703
7846
|
{
|
|
7704
|
-
style: {
|
|
7847
|
+
style: __spreadValues({
|
|
7705
7848
|
fontSize: "10px",
|
|
7706
7849
|
fontWeight: 500,
|
|
7707
7850
|
color: MUTED2,
|
|
7708
7851
|
textTransform: "uppercase",
|
|
7709
7852
|
letterSpacing: "0.04em",
|
|
7710
7853
|
marginBottom: "4px"
|
|
7711
|
-
},
|
|
7854
|
+
}, TRUNCATE),
|
|
7712
7855
|
children: sourceB.label
|
|
7713
7856
|
}
|
|
7714
7857
|
),
|
|
7715
7858
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7716
|
-
|
|
7859
|
+
FitText,
|
|
7717
7860
|
{
|
|
7718
|
-
|
|
7719
|
-
|
|
7720
|
-
|
|
7721
|
-
|
|
7722
|
-
fontVariantNumeric: "tabular-nums",
|
|
7723
|
-
letterSpacing: "-0.01em"
|
|
7724
|
-
},
|
|
7861
|
+
max: 15,
|
|
7862
|
+
min: 11,
|
|
7863
|
+
title: fmt6(balanceB, p.currency),
|
|
7864
|
+
style: { fontWeight: 600, color: "var(--foreground)", fontVariantNumeric: "tabular-nums", letterSpacing: "-0.01em" },
|
|
7725
7865
|
children: fmt6(balanceB, p.currency)
|
|
7726
7866
|
}
|
|
7727
7867
|
)
|
|
@@ -7733,7 +7873,8 @@ function ReconciliationViewResolver(p) {
|
|
|
7733
7873
|
{
|
|
7734
7874
|
style: {
|
|
7735
7875
|
padding: "10px 12px",
|
|
7736
|
-
background: difference === 0 ? "#f0fdf4" : "#fef2f2"
|
|
7876
|
+
background: difference === 0 ? "#f0fdf4" : "#fef2f2",
|
|
7877
|
+
minWidth: 0
|
|
7737
7878
|
},
|
|
7738
7879
|
children: [
|
|
7739
7880
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -7773,15 +7914,12 @@ function ReconciliationViewResolver(p) {
|
|
|
7773
7914
|
}
|
|
7774
7915
|
),
|
|
7775
7916
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7776
|
-
|
|
7917
|
+
FitText,
|
|
7777
7918
|
{
|
|
7778
|
-
|
|
7779
|
-
|
|
7780
|
-
|
|
7781
|
-
|
|
7782
|
-
fontVariantNumeric: "tabular-nums",
|
|
7783
|
-
letterSpacing: "-0.01em"
|
|
7784
|
-
},
|
|
7919
|
+
max: 15,
|
|
7920
|
+
min: 11,
|
|
7921
|
+
title: fmt6(difference, p.currency),
|
|
7922
|
+
style: { fontWeight: 700, color: difference === 0 ? MATCH_GREEN : DIFF_RED, fontVariantNumeric: "tabular-nums", letterSpacing: "-0.01em" },
|
|
7785
7923
|
children: fmt6(difference, p.currency)
|
|
7786
7924
|
}
|
|
7787
7925
|
)
|
|
@@ -8214,7 +8352,7 @@ function ChangesView({ changes }) {
|
|
|
8214
8352
|
}
|
|
8215
8353
|
function EventCard({ event }) {
|
|
8216
8354
|
var _a;
|
|
8217
|
-
const [showChanges, setShowChanges] =
|
|
8355
|
+
const [showChanges, setShowChanges] = React41.useState(false);
|
|
8218
8356
|
const ac = (_a = actionConfig[event.action]) != null ? _a : actionConfig.commented;
|
|
8219
8357
|
const hasChanges = event.changes && event.changes.length > 0;
|
|
8220
8358
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", gap: "12px", position: "relative" }, children: [
|
|
@@ -8272,23 +8410,23 @@ function AuditTrailResolver(p) {
|
|
|
8272
8410
|
}
|
|
8273
8411
|
init_Markdown();
|
|
8274
8412
|
function useFullscreen(ref) {
|
|
8275
|
-
const [isFullscreen, setIsFullscreen] =
|
|
8276
|
-
|
|
8413
|
+
const [isFullscreen, setIsFullscreen] = React41.useState(false);
|
|
8414
|
+
React41.useEffect(() => {
|
|
8277
8415
|
const handler = () => {
|
|
8278
8416
|
setIsFullscreen(!!document.fullscreenElement);
|
|
8279
8417
|
};
|
|
8280
8418
|
document.addEventListener("fullscreenchange", handler);
|
|
8281
8419
|
return () => document.removeEventListener("fullscreenchange", handler);
|
|
8282
8420
|
}, []);
|
|
8283
|
-
const enter =
|
|
8421
|
+
const enter = React41.useCallback(() => {
|
|
8284
8422
|
var _a, _b;
|
|
8285
8423
|
(_b = (_a = ref.current) == null ? void 0 : _a.requestFullscreen) == null ? void 0 : _b.call(_a);
|
|
8286
8424
|
}, [ref]);
|
|
8287
|
-
const exit =
|
|
8425
|
+
const exit = React41.useCallback(() => {
|
|
8288
8426
|
var _a;
|
|
8289
8427
|
if (document.fullscreenElement) (_a = document.exitFullscreen) == null ? void 0 : _a.call(document);
|
|
8290
8428
|
}, []);
|
|
8291
|
-
const toggle =
|
|
8429
|
+
const toggle = React41.useCallback(() => {
|
|
8292
8430
|
if (isFullscreen) exit();
|
|
8293
8431
|
else enter();
|
|
8294
8432
|
}, [isFullscreen, enter, exit]);
|
|
@@ -8298,10 +8436,10 @@ function useFullscreen(ref) {
|
|
|
8298
8436
|
// src/composites/document-preview/resolver.tsx
|
|
8299
8437
|
init_theme();
|
|
8300
8438
|
init_ThemeContext();
|
|
8301
|
-
var PdfViewer2 =
|
|
8439
|
+
var PdfViewer2 = React41__default.default.lazy(
|
|
8302
8440
|
() => Promise.resolve().then(() => (init_PdfViewer(), PdfViewer_exports)).then((m) => ({ default: m.PdfViewer }))
|
|
8303
8441
|
);
|
|
8304
|
-
var ExcelViewer2 =
|
|
8442
|
+
var ExcelViewer2 = React41__default.default.lazy(
|
|
8305
8443
|
() => Promise.resolve().then(() => (init_ExcelViewer(), ExcelViewer_exports)).then((m) => ({ default: m.ExcelViewer }))
|
|
8306
8444
|
);
|
|
8307
8445
|
var highlightColors = {
|
|
@@ -8351,8 +8489,8 @@ function DownloadIcon() {
|
|
|
8351
8489
|
function DocumentPreviewResolver(p) {
|
|
8352
8490
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u;
|
|
8353
8491
|
const { BORDER: BORDER4, MUTED: MUTED2, PAPER: PAPER2, ACCENT: ACCENT2 } = useTheme();
|
|
8354
|
-
const [currentPage, setCurrentPage] =
|
|
8355
|
-
const containerRef =
|
|
8492
|
+
const [currentPage, setCurrentPage] = React41.useState(0);
|
|
8493
|
+
const containerRef = React41.useRef(null);
|
|
8356
8494
|
const { isFullscreen, toggle } = useFullscreen(containerRef);
|
|
8357
8495
|
const hasRealFile = !!(((_a = p.source) == null ? void 0 : _a.url) || ((_b = p.source) == null ? void 0 : _b.base64));
|
|
8358
8496
|
const isPdf = p.documentType === "pdf";
|
|
@@ -8360,9 +8498,9 @@ function DocumentPreviewResolver(p) {
|
|
|
8360
8498
|
const totalPages = ((_c = p.pages) != null ? _c : []).length;
|
|
8361
8499
|
const page = p.pages[currentPage];
|
|
8362
8500
|
const pageHighlights = ((_d = p.highlights) != null ? _d : []).filter((h) => h.pageIndex === currentPage);
|
|
8363
|
-
const handlePdfLoad =
|
|
8501
|
+
const handlePdfLoad = React41.useCallback(() => {
|
|
8364
8502
|
}, []);
|
|
8365
|
-
const handleExcelLoad =
|
|
8503
|
+
const handleExcelLoad = React41.useCallback(() => {
|
|
8366
8504
|
}, []);
|
|
8367
8505
|
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: (_e = p.title) != null ? _e : "document-preview", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8368
8506
|
"div",
|
|
@@ -8475,7 +8613,7 @@ function DocumentPreviewResolver(p) {
|
|
|
8475
8613
|
display: "flex",
|
|
8476
8614
|
flexDirection: "column"
|
|
8477
8615
|
}, children: [
|
|
8478
|
-
hasRealFile && isPdf ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
8616
|
+
hasRealFile && isPdf ? /* @__PURE__ */ jsxRuntime.jsx(React41.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(PdfViewer2, { url: (_q = p.source) == null ? void 0 : _q.url, base64: (_r = p.source) == null ? void 0 : _r.base64, onLoadSuccess: handlePdfLoad }) }) : hasRealFile && isExcel ? /* @__PURE__ */ jsxRuntime.jsx(React41.Suspense, { fallback: null, children: /* @__PURE__ */ jsxRuntime.jsx(ExcelViewer2, { url: (_s = p.source) == null ? void 0 : _s.url, base64: (_t = p.source) == null ? void 0 : _t.base64, onLoadSuccess: handleExcelLoad }) }) : (page == null ? void 0 : page.imageUrl) ? /* @__PURE__ */ jsxRuntime.jsx("div", { style: { padding: "20px" }, children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: page.imageUrl, alt: page.label, style: { maxWidth: "100%", borderRadius: "4px" } }) }) : (page == null ? void 0 : page.content) ? /* @__PURE__ */ jsxRuntime.jsx("div", { style: { fontFamily: "var(--font-sans, system-ui)", fontSize: "13px", color: "var(--foreground)", lineHeight: 1.6, margin: 0, padding: "20px" }, children: /* @__PURE__ */ jsxRuntime.jsx(Markdown, { content: page.content }) }) : /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", justifyContent: "center", height: "120px", color: MUTED2, fontSize: "13px" }, children: [
|
|
8479
8617
|
"No content available for ",
|
|
8480
8618
|
(_u = page == null ? void 0 : page.label) != null ? _u : "this page"
|
|
8481
8619
|
] }),
|
|
@@ -8538,7 +8676,7 @@ function ConfidenceBar({ confidence, height = 6 }) {
|
|
|
8538
8676
|
}
|
|
8539
8677
|
function StepCard({ step, isLast }) {
|
|
8540
8678
|
var _a;
|
|
8541
|
-
const [expanded, setExpanded] =
|
|
8679
|
+
const [expanded, setExpanded] = React41.useState(false);
|
|
8542
8680
|
const cfg = stepTypeConfig[step.stepType];
|
|
8543
8681
|
const detail = (_a = step.detail) != null ? _a : "";
|
|
8544
8682
|
const isLong = detail.length > 100;
|
|
@@ -9043,7 +9181,7 @@ function ExampleRow({ example }) {
|
|
|
9043
9181
|
);
|
|
9044
9182
|
}
|
|
9045
9183
|
function PartSection({ part, defaultOpen }) {
|
|
9046
|
-
const [open, setOpen] =
|
|
9184
|
+
const [open, setOpen] = React41.useState(defaultOpen);
|
|
9047
9185
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
9048
9186
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
9049
9187
|
"button",
|
|
@@ -9173,7 +9311,7 @@ function EngagementPipelineResolver(p) {
|
|
|
9173
9311
|
const defaultActive = phases.findIndex(
|
|
9174
9312
|
(ph) => ph.status === "in-progress" || ph.status === "blocked"
|
|
9175
9313
|
);
|
|
9176
|
-
const [activeIdx, setActiveIdx] =
|
|
9314
|
+
const [activeIdx, setActiveIdx] = React41.useState(defaultActive >= 0 ? defaultActive : 0);
|
|
9177
9315
|
const activePhase = phases[activeIdx];
|
|
9178
9316
|
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: (_b = p.title) != null ? _b : "engagement-pipeline", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { width: "100%", display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
|
9179
9317
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "4px" }, children: [
|
|
@@ -9257,7 +9395,7 @@ function EngagementPipelineResolver(p) {
|
|
|
9257
9395
|
const color = (_a2 = statusColor2[phase.status]) != null ? _a2 : "#d6d3d1";
|
|
9258
9396
|
const isCurrent = i === activeIdx;
|
|
9259
9397
|
const size = isCurrent ? 28 : 20;
|
|
9260
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
9398
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
9261
9399
|
i > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
9262
9400
|
"div",
|
|
9263
9401
|
{
|
|
@@ -9564,7 +9702,7 @@ function Avatar({ name, avatar, hovered }) {
|
|
|
9564
9702
|
function EntityCardGridResolver(p) {
|
|
9565
9703
|
var _a, _b;
|
|
9566
9704
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2 } = useTheme();
|
|
9567
|
-
const [hoveredId, setHoveredId] =
|
|
9705
|
+
const [hoveredId, setHoveredId] = React41.useState(null);
|
|
9568
9706
|
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: (_a = p.title) != null ? _a : "entity-card-grid", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { width: "100%", display: "flex", flexDirection: "column", gap: "10px" }, children: [
|
|
9569
9707
|
p.title && /* @__PURE__ */ jsxRuntime.jsx(
|
|
9570
9708
|
"p",
|
|
@@ -9585,7 +9723,7 @@ function EntityCardGridResolver(p) {
|
|
|
9585
9723
|
{
|
|
9586
9724
|
style: {
|
|
9587
9725
|
display: "grid",
|
|
9588
|
-
gridTemplateColumns: `repeat(auto-fit, minmax(220px, 1fr))`,
|
|
9726
|
+
gridTemplateColumns: `repeat(auto-fit, minmax(min(220px, 100%), 1fr))`,
|
|
9589
9727
|
gap: "12px",
|
|
9590
9728
|
width: "100%"
|
|
9591
9729
|
},
|
|
@@ -9676,7 +9814,7 @@ function EntityCardGridResolver(p) {
|
|
|
9676
9814
|
{
|
|
9677
9815
|
style: {
|
|
9678
9816
|
display: "grid",
|
|
9679
|
-
gridTemplateColumns: item.fields.length > 2 ? "repeat(auto-fit, minmax(90px, 1fr))" : "1fr",
|
|
9817
|
+
gridTemplateColumns: item.fields.length > 2 ? "repeat(auto-fit, minmax(min(90px, 100%), 1fr))" : "1fr",
|
|
9680
9818
|
gap: "6px 12px",
|
|
9681
9819
|
borderTop: `1px solid ${BORDER4}`,
|
|
9682
9820
|
paddingTop: "8px"
|
|
@@ -9820,7 +9958,7 @@ function StepRow({ step }) {
|
|
|
9820
9958
|
function JobTrackerResolver(p) {
|
|
9821
9959
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
9822
9960
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2, PAPER: PAPER2 } = useTheme();
|
|
9823
|
-
const [stepsOpen, setStepsOpen] =
|
|
9961
|
+
const [stepsOpen, setStepsOpen] = React41.useState(true);
|
|
9824
9962
|
const barColor = (_a = statusColors2[p.status]) != null ? _a : MUTED2;
|
|
9825
9963
|
const badge = (_b = statusBadgeConfig[p.status]) != null ? _b : statusBadgeConfig.queued;
|
|
9826
9964
|
const progress = (_c = p.progress) != null ? _c : p.status === "completed" ? 100 : 0;
|
|
@@ -10260,7 +10398,7 @@ function CitationCard({
|
|
|
10260
10398
|
);
|
|
10261
10399
|
}
|
|
10262
10400
|
function FollowUpItem({ text }) {
|
|
10263
|
-
const [hovered, setHovered] =
|
|
10401
|
+
const [hovered, setHovered] = React41.useState(false);
|
|
10264
10402
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10265
10403
|
"span",
|
|
10266
10404
|
{
|
|
@@ -10285,7 +10423,7 @@ function CitationMarker({
|
|
|
10285
10423
|
index,
|
|
10286
10424
|
onClick
|
|
10287
10425
|
}) {
|
|
10288
|
-
const [hovered, setHovered] =
|
|
10426
|
+
const [hovered, setHovered] = React41.useState(false);
|
|
10289
10427
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
10290
10428
|
"sup",
|
|
10291
10429
|
{
|
|
@@ -10314,7 +10452,7 @@ function CitationMarker({
|
|
|
10314
10452
|
function CitedAnswerResolver(p) {
|
|
10315
10453
|
var _a, _b, _c, _d, _e;
|
|
10316
10454
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2, SECONDARY: SECONDARY2 } = useTheme();
|
|
10317
|
-
const [expandedIds, setExpandedIds] =
|
|
10455
|
+
const [expandedIds, setExpandedIds] = React41.useState(/* @__PURE__ */ new Set());
|
|
10318
10456
|
const toggleCitation = (id) => {
|
|
10319
10457
|
setExpandedIds((prev) => {
|
|
10320
10458
|
const next = new Set(prev);
|
|
@@ -10618,7 +10756,7 @@ function TransactionFeedResolver(p) {
|
|
|
10618
10756
|
var _a, _b, _c, _d, _e;
|
|
10619
10757
|
const { BORDER: BORDER4, MUTED: MUTED2 } = useTheme();
|
|
10620
10758
|
const currency = (_a = p.currency) != null ? _a : "USD";
|
|
10621
|
-
const [hoveredIndex, setHoveredIndex] =
|
|
10759
|
+
const [hoveredIndex, setHoveredIndex] = React41.useState(null);
|
|
10622
10760
|
const hasBalance = ((_b = p.transactions) != null ? _b : []).some((tx) => tx.balance != null);
|
|
10623
10761
|
const totalInflows = p.transactions.filter((tx) => tx.amount > 0 && tx.status !== "reversed").reduce((sum, tx) => sum + tx.amount, 0);
|
|
10624
10762
|
const totalOutflows = p.transactions.filter((tx) => tx.amount < 0 && tx.status !== "reversed").reduce((sum, tx) => sum + tx.amount, 0);
|
|
@@ -10775,7 +10913,7 @@ function formatDate2(dateStr) {
|
|
|
10775
10913
|
}
|
|
10776
10914
|
function FileRow({ item }) {
|
|
10777
10915
|
var _a;
|
|
10778
|
-
const [hovered, setHovered] =
|
|
10916
|
+
const [hovered, setHovered] = React41.useState(false);
|
|
10779
10917
|
const cfg = getDocConfig(item.docType);
|
|
10780
10918
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10781
10919
|
"div",
|
|
@@ -10851,8 +10989,8 @@ function FileRow({ item }) {
|
|
|
10851
10989
|
);
|
|
10852
10990
|
}
|
|
10853
10991
|
function GroupSection({ groupName, items }) {
|
|
10854
|
-
const [open, setOpen] =
|
|
10855
|
-
const [headerHovered, setHeaderHovered] =
|
|
10992
|
+
const [open, setOpen] = React41.useState(true);
|
|
10993
|
+
const [headerHovered, setHeaderHovered] = React41.useState(false);
|
|
10856
10994
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
10857
10995
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
10858
10996
|
"button",
|
|
@@ -11041,15 +11179,15 @@ function isExpirySoon(expiresAt) {
|
|
|
11041
11179
|
|
|
11042
11180
|
// src/shared/viewers/PreviewHost.tsx
|
|
11043
11181
|
init_ThemeContext();
|
|
11044
|
-
var PdfViewer3 =
|
|
11182
|
+
var PdfViewer3 = React41.lazy(
|
|
11045
11183
|
() => Promise.resolve().then(() => (init_PdfViewer(), PdfViewer_exports)).then((m) => ({ default: m.PdfViewer }))
|
|
11046
11184
|
);
|
|
11047
|
-
var ExcelViewer3 =
|
|
11185
|
+
var ExcelViewer3 = React41.lazy(
|
|
11048
11186
|
() => Promise.resolve().then(() => (init_ExcelViewer(), ExcelViewer_exports)).then((m) => ({ default: m.ExcelViewer }))
|
|
11049
11187
|
);
|
|
11050
|
-
var CsvViewer2 =
|
|
11051
|
-
var TextViewer2 =
|
|
11052
|
-
var DocxViewer2 =
|
|
11188
|
+
var CsvViewer2 = React41.lazy(() => Promise.resolve().then(() => (init_CsvViewer(), CsvViewer_exports)).then((m) => ({ default: m.CsvViewer })));
|
|
11189
|
+
var TextViewer2 = React41.lazy(() => Promise.resolve().then(() => (init_TextViewer(), TextViewer_exports)).then((m) => ({ default: m.TextViewer })));
|
|
11190
|
+
var DocxViewer2 = React41.lazy(() => Promise.resolve().then(() => (init_DocxViewer(), DocxViewer_exports)).then((m) => ({ default: m.DocxViewer })));
|
|
11053
11191
|
var PEEK_ROWS = 20;
|
|
11054
11192
|
var PEEK_LINES = 40;
|
|
11055
11193
|
function PreviewHost({ kind, source, mode = "full" }) {
|
|
@@ -11079,7 +11217,7 @@ function PreviewHost({ kind, source, mode = "full" }) {
|
|
|
11079
11217
|
default:
|
|
11080
11218
|
return null;
|
|
11081
11219
|
}
|
|
11082
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
11220
|
+
return /* @__PURE__ */ jsxRuntime.jsx(React41.Suspense, { fallback, children: viewer });
|
|
11083
11221
|
}
|
|
11084
11222
|
|
|
11085
11223
|
// src/shared/PreviewModal.tsx
|
|
@@ -11095,7 +11233,7 @@ function PreviewModal({
|
|
|
11095
11233
|
onDownload
|
|
11096
11234
|
}) {
|
|
11097
11235
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2 } = useTheme();
|
|
11098
|
-
|
|
11236
|
+
React41.useEffect(() => {
|
|
11099
11237
|
if (!open) return;
|
|
11100
11238
|
const onKey = (e) => {
|
|
11101
11239
|
if (e.key === "Escape") onClose();
|
|
@@ -11268,17 +11406,17 @@ function FileCard({
|
|
|
11268
11406
|
previewDisabled = false
|
|
11269
11407
|
}) {
|
|
11270
11408
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2 } = useTheme();
|
|
11271
|
-
const [cardHover, setCardHover] =
|
|
11272
|
-
const [btnHover, setBtnHover] =
|
|
11273
|
-
const [pvHover, setPvHover] =
|
|
11409
|
+
const [cardHover, setCardHover] = React41.useState(false);
|
|
11410
|
+
const [btnHover, setBtnHover] = React41.useState(false);
|
|
11411
|
+
const [pvHover, setPvHover] = React41.useState(false);
|
|
11274
11412
|
const previewKind = previewKindFor(fileType, filename);
|
|
11275
11413
|
const canPreview = !previewDisabled && previewKind !== null && (!!previewUrl || !!fetchPreviewBlob);
|
|
11276
|
-
const [peekOpen, setPeekOpen] =
|
|
11277
|
-
const [modalOpen, setModalOpen] =
|
|
11278
|
-
const [source, setSource] =
|
|
11279
|
-
const [pvLoading, setPvLoading] =
|
|
11280
|
-
const [pvError, setPvError] =
|
|
11281
|
-
const ensureSource =
|
|
11414
|
+
const [peekOpen, setPeekOpen] = React41.useState(false);
|
|
11415
|
+
const [modalOpen, setModalOpen] = React41.useState(false);
|
|
11416
|
+
const [source, setSource] = React41.useState(previewUrl ? { url: previewUrl } : null);
|
|
11417
|
+
const [pvLoading, setPvLoading] = React41.useState(false);
|
|
11418
|
+
const [pvError, setPvError] = React41.useState(null);
|
|
11419
|
+
const ensureSource = React41.useCallback(async () => {
|
|
11282
11420
|
if (source) return source;
|
|
11283
11421
|
if (previewUrl) {
|
|
11284
11422
|
const s = { url: previewUrl };
|
|
@@ -11300,7 +11438,7 @@ function FileCard({
|
|
|
11300
11438
|
setPvLoading(false);
|
|
11301
11439
|
}
|
|
11302
11440
|
}, [source, previewUrl, fetchPreviewBlob]);
|
|
11303
|
-
const togglePeek =
|
|
11441
|
+
const togglePeek = React41.useCallback(async () => {
|
|
11304
11442
|
if (peekOpen) {
|
|
11305
11443
|
setPeekOpen(false);
|
|
11306
11444
|
return;
|
|
@@ -11308,7 +11446,7 @@ function FileCard({
|
|
|
11308
11446
|
setPeekOpen(true);
|
|
11309
11447
|
await ensureSource();
|
|
11310
11448
|
}, [peekOpen, ensureSource]);
|
|
11311
|
-
const openModal =
|
|
11449
|
+
const openModal = React41.useCallback(async () => {
|
|
11312
11450
|
const s = await ensureSource();
|
|
11313
11451
|
if (s) setModalOpen(true);
|
|
11314
11452
|
}, [ensureSource]);
|
|
@@ -11423,7 +11561,7 @@ function FileCard({
|
|
|
11423
11561
|
whiteSpace: "nowrap"
|
|
11424
11562
|
},
|
|
11425
11563
|
children: [
|
|
11426
|
-
metaTokens.map((t, i) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11564
|
+
metaTokens.map((t, i) => /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
11427
11565
|
i > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { color: "#c4c4c4" }, children: "\xB7" }),
|
|
11428
11566
|
/* @__PURE__ */ jsxRuntime.jsx("span", { children: t })
|
|
11429
11567
|
] }, i)),
|
|
@@ -11767,7 +11905,7 @@ function ServiceCard({ item, isHovered, onHover, onLeave: onLeave2 }) {
|
|
|
11767
11905
|
function OpsDashboardResolver(p) {
|
|
11768
11906
|
var _a, _b, _c;
|
|
11769
11907
|
const { BORDER: BORDER4, MUTED: MUTED2 } = useTheme();
|
|
11770
|
-
const [hoveredId, setHoveredId] =
|
|
11908
|
+
const [hoveredId, setHoveredId] = React41.useState(null);
|
|
11771
11909
|
const hasRunning = ((_a = p.items) != null ? _a : []).some((item) => item.state === "running");
|
|
11772
11910
|
return /* @__PURE__ */ jsxRuntime.jsxs(ComponentActions, { filename: (_b = p.title) != null ? _b : "ops-dashboard", children: [
|
|
11773
11911
|
hasRunning && /* @__PURE__ */ jsxRuntime.jsx("style", { children: PULSE_KEYFRAMES }),
|
|
@@ -11820,8 +11958,8 @@ function formatDate3(value) {
|
|
|
11820
11958
|
}
|
|
11821
11959
|
}
|
|
11822
11960
|
function CopyButton({ value, rowHovered }) {
|
|
11823
|
-
const [copied, setCopied] =
|
|
11824
|
-
const [btnHovered, setBtnHovered] =
|
|
11961
|
+
const [copied, setCopied] = React41.useState(false);
|
|
11962
|
+
const [btnHovered, setBtnHovered] = React41.useState(false);
|
|
11825
11963
|
const handleCopy = () => {
|
|
11826
11964
|
navigator.clipboard.writeText(value).then(() => {
|
|
11827
11965
|
setCopied(true);
|
|
@@ -11907,13 +12045,13 @@ function ValueCell({ item }) {
|
|
|
11907
12045
|
)
|
|
11908
12046
|
] });
|
|
11909
12047
|
case "currency":
|
|
11910
|
-
return /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "13px", fontWeight: 600, fontVariantNumeric: "tabular-nums", marginLeft: "auto" }, children: item.value });
|
|
12048
|
+
return /* @__PURE__ */ jsxRuntime.jsx("span", { title: item.value, style: __spreadValues({ fontSize: "13px", fontWeight: 600, fontVariantNumeric: "tabular-nums", marginLeft: "auto" }, TRUNCATE), children: item.value });
|
|
11911
12049
|
default:
|
|
11912
|
-
return /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "13px", color: "var(--foreground)" }, children: /* @__PURE__ */ jsxRuntime.jsx(Markdown, { inline: true, content: item.value }) });
|
|
12050
|
+
return /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "13px", color: "var(--foreground)", minWidth: 0, overflowWrap: "anywhere" }, children: /* @__PURE__ */ jsxRuntime.jsx(Markdown, { inline: true, content: item.value }) });
|
|
11913
12051
|
}
|
|
11914
12052
|
}
|
|
11915
12053
|
function KVRow({ item, isLast, index }) {
|
|
11916
|
-
const [hovered, setHovered] =
|
|
12054
|
+
const [hovered, setHovered] = React41.useState(false);
|
|
11917
12055
|
const altBg = index % 2 === 1 ? "#fcfcfc" : "white";
|
|
11918
12056
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11919
12057
|
"div",
|
|
@@ -11942,7 +12080,7 @@ function KVRow({ item, isLast, index }) {
|
|
|
11942
12080
|
children: item.key
|
|
11943
12081
|
}
|
|
11944
12082
|
),
|
|
11945
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { flex: 1, display: "flex", alignItems: "center", gap: "6px" }, children: /* @__PURE__ */ jsxRuntime.jsx(ValueCell, { item }) }),
|
|
12083
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { flex: 1, minWidth: 0, display: "flex", alignItems: "center", gap: "6px" }, children: /* @__PURE__ */ jsxRuntime.jsx(ValueCell, { item }) }),
|
|
11946
12084
|
item.copyable && /* @__PURE__ */ jsxRuntime.jsx(CopyButton, { value: item.value, rowHovered: hovered })
|
|
11947
12085
|
]
|
|
11948
12086
|
}
|
|
@@ -11998,7 +12136,7 @@ function KeyValueListResolver(p) {
|
|
|
11998
12136
|
var _a3;
|
|
11999
12137
|
return sum + ((_a3 = g.items) != null ? _a3 : []).length;
|
|
12000
12138
|
}, 0);
|
|
12001
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12139
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12002
12140
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
12003
12141
|
"div",
|
|
12004
12142
|
{
|
|
@@ -12134,7 +12272,7 @@ function BalanceSheetResolver(p) {
|
|
|
12134
12272
|
color: balanced ? "#15803d" : "#dc2626"
|
|
12135
12273
|
}, children: balanced ? "\u2713 A = L + E" : "\u2717 Out of Balance" })
|
|
12136
12274
|
] }),
|
|
12137
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.04)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "380px" }, children: [
|
|
12275
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", minWidth: 0, borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.04)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "380px" }, children: [
|
|
12138
12276
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { children: /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
|
|
12139
12277
|
/* @__PURE__ */ jsxRuntime.jsx("th", { style: {
|
|
12140
12278
|
fontSize: "11px",
|
|
@@ -12176,7 +12314,7 @@ function BalanceSheetResolver(p) {
|
|
|
12176
12314
|
/* @__PURE__ */ jsxRuntime.jsxs("tbody", { children: [
|
|
12177
12315
|
((_p = p.sections) != null ? _p : []).map((section) => {
|
|
12178
12316
|
var _a2;
|
|
12179
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12317
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12180
12318
|
/* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan, style: {
|
|
12181
12319
|
padding: "8px 12px",
|
|
12182
12320
|
fontSize: "12px",
|
|
@@ -12189,7 +12327,7 @@ function BalanceSheetResolver(p) {
|
|
|
12189
12327
|
}, children: (_a2 = categoryLabels2[section.category]) != null ? _a2 : section.category }) }),
|
|
12190
12328
|
section.subsections.map((sub, si) => {
|
|
12191
12329
|
var _a3;
|
|
12192
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12330
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12193
12331
|
/* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan, style: {
|
|
12194
12332
|
padding: "6px 10px 6px 24px",
|
|
12195
12333
|
fontSize: "12px",
|
|
@@ -12351,7 +12489,7 @@ function IncomeStatementResolver(p) {
|
|
|
12351
12489
|
].filter(Boolean).join(" \xB7 ") })
|
|
12352
12490
|
] }),
|
|
12353
12491
|
p.title && /* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontFamily: "var(--font-serif)", fontSize: "15px", fontWeight: 400, color: "var(--foreground)", letterSpacing: "-0.01em", margin: 0 }, children: p.title }),
|
|
12354
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.05)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "380px" }, children: [
|
|
12492
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflowX: "auto", minWidth: 0, borderRadius: "0.75rem", border: `1px solid ${BORDER4}`, boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.05)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("table", { style: { width: "100%", borderCollapse: "collapse", minWidth: "380px" }, children: [
|
|
12355
12493
|
/* @__PURE__ */ jsxRuntime.jsx("thead", { children: /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
|
|
12356
12494
|
/* @__PURE__ */ jsxRuntime.jsx("th", { style: {
|
|
12357
12495
|
fontSize: "11px",
|
|
@@ -12365,7 +12503,7 @@ function IncomeStatementResolver(p) {
|
|
|
12365
12503
|
textAlign: "left",
|
|
12366
12504
|
whiteSpace: "nowrap"
|
|
12367
12505
|
}, children: "\xA0" }),
|
|
12368
|
-
periods.map((period) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12506
|
+
periods.map((period) => /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12369
12507
|
/* @__PURE__ */ jsxRuntime.jsx("th", { style: {
|
|
12370
12508
|
fontSize: "11px",
|
|
12371
12509
|
fontWeight: 500,
|
|
@@ -12396,7 +12534,7 @@ function IncomeStatementResolver(p) {
|
|
|
12396
12534
|
sections.map((section, si) => {
|
|
12397
12535
|
var _a2;
|
|
12398
12536
|
const isSubtotal = section.sectionType === "subtotal";
|
|
12399
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12537
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12400
12538
|
/* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx("td", { colSpan: colCount, style: {
|
|
12401
12539
|
padding: "8px 12px",
|
|
12402
12540
|
fontSize: "12px",
|
|
@@ -12427,7 +12565,7 @@ function IncomeStatementResolver(p) {
|
|
|
12427
12565
|
var _a4;
|
|
12428
12566
|
const val = (_a4 = amounts[pi]) != null ? _a4 : 0;
|
|
12429
12567
|
const isNeg = val < 0;
|
|
12430
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12568
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12431
12569
|
/* @__PURE__ */ jsxRuntime.jsx("td", { style: {
|
|
12432
12570
|
padding: "6px 10px",
|
|
12433
12571
|
fontSize: "13px",
|
|
@@ -12462,7 +12600,7 @@ function IncomeStatementResolver(p) {
|
|
|
12462
12600
|
var _a2;
|
|
12463
12601
|
const val = (_a2 = grossProfit[pi]) != null ? _a2 : 0;
|
|
12464
12602
|
const isNeg = val < 0;
|
|
12465
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12603
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12466
12604
|
/* @__PURE__ */ jsxRuntime.jsx("td", { style: {
|
|
12467
12605
|
padding: "8px 10px",
|
|
12468
12606
|
fontSize: "12px",
|
|
@@ -12497,7 +12635,7 @@ function IncomeStatementResolver(p) {
|
|
|
12497
12635
|
var _a2;
|
|
12498
12636
|
const val = (_a2 = operatingIncome[pi]) != null ? _a2 : 0;
|
|
12499
12637
|
const isNeg = val < 0;
|
|
12500
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12638
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12501
12639
|
/* @__PURE__ */ jsxRuntime.jsx("td", { style: {
|
|
12502
12640
|
padding: "8px 10px",
|
|
12503
12641
|
fontSize: "12px",
|
|
@@ -12531,7 +12669,7 @@ function IncomeStatementResolver(p) {
|
|
|
12531
12669
|
var _a2;
|
|
12532
12670
|
const val = (_a2 = netIncome[pi]) != null ? _a2 : 0;
|
|
12533
12671
|
const isNeg = val < 0;
|
|
12534
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12672
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12535
12673
|
/* @__PURE__ */ jsxRuntime.jsx("td", { style: {
|
|
12536
12674
|
padding: "10px 10px",
|
|
12537
12675
|
fontSize: "13px",
|
|
@@ -12751,7 +12889,7 @@ function CashFlowStatementResolver(p) {
|
|
|
12751
12889
|
/* @__PURE__ */ jsxRuntime.jsxs("tbody", { children: [
|
|
12752
12890
|
activities.map((activity, ai) => {
|
|
12753
12891
|
var _a2, _b2, _c2;
|
|
12754
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12892
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
12755
12893
|
ai > 0 && /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
12756
12894
|
"td",
|
|
12757
12895
|
{
|
|
@@ -13134,6 +13272,7 @@ function GeneralLedgerResolver(p) {
|
|
|
13134
13272
|
{
|
|
13135
13273
|
style: {
|
|
13136
13274
|
overflowX: "auto",
|
|
13275
|
+
minWidth: 0,
|
|
13137
13276
|
borderRadius: "0.75rem",
|
|
13138
13277
|
border: `1px solid ${BORDER4}`,
|
|
13139
13278
|
boxShadow: "0 1px 2px rgba(0,0,0,0.03), 0 4px 12px rgba(0,0,0,0.04)"
|
|
@@ -15163,8 +15302,8 @@ var PRIORITY_STYLES = {
|
|
|
15163
15302
|
function EscalationCardResolver(p) {
|
|
15164
15303
|
var _a, _b, _c, _d;
|
|
15165
15304
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2, ACCENT_SOFT: ACCENT_SOFT2 } = useTheme();
|
|
15166
|
-
const [cardHovered, setCardHovered] =
|
|
15167
|
-
const [btnHovered, setBtnHovered] =
|
|
15305
|
+
const [cardHovered, setCardHovered] = React41.useState(false);
|
|
15306
|
+
const [btnHovered, setBtnHovered] = React41.useState(false);
|
|
15168
15307
|
const priorityStyle = p.priority ? PRIORITY_STYLES[p.priority] : null;
|
|
15169
15308
|
const railColor = (_a = priorityStyle == null ? void 0 : priorityStyle.color) != null ? _a : ACCENT2;
|
|
15170
15309
|
const iconBg = (_b = priorityStyle == null ? void 0 : priorityStyle.bg) != null ? _b : "#fff2ec";
|
|
@@ -16011,9 +16150,9 @@ var CONNECTED_GREEN = "#15803d";
|
|
|
16011
16150
|
function ConnectIntegrationResolver(p) {
|
|
16012
16151
|
var _a;
|
|
16013
16152
|
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2, ACCENT_SOFT: ACCENT_SOFT2 } = useTheme();
|
|
16014
|
-
const [cardHovered, setCardHovered] =
|
|
16015
|
-
const [btnHovered, setBtnHovered] =
|
|
16016
|
-
const [imgFailed, setImgFailed] =
|
|
16153
|
+
const [cardHovered, setCardHovered] = React41.useState(false);
|
|
16154
|
+
const [btnHovered, setBtnHovered] = React41.useState(false);
|
|
16155
|
+
const [imgFailed, setImgFailed] = React41.useState(false);
|
|
16017
16156
|
const name = (p.integrationName || "Integration").trim();
|
|
16018
16157
|
const initial = name.charAt(0).toUpperCase();
|
|
16019
16158
|
const iconSrc = p.iconUrl || brandIconUrl(name);
|
|
@@ -16175,9 +16314,9 @@ function IntegrationsListResolver(p) {
|
|
|
16175
16314
|
var _a, _b;
|
|
16176
16315
|
const { BORDER: BORDER4, MUTED: MUTED2, PAPER: PAPER2, ACCENT: ACCENT2, ACCENT_SOFT: ACCENT_SOFT2 } = useTheme();
|
|
16177
16316
|
const integrations = Array.isArray(p.integrations) ? p.integrations : [];
|
|
16178
|
-
const [rowHover, setRowHover] =
|
|
16179
|
-
const [btnHover, setBtnHover] =
|
|
16180
|
-
const [failed, setFailed] =
|
|
16317
|
+
const [rowHover, setRowHover] = React41.useState(null);
|
|
16318
|
+
const [btnHover, setBtnHover] = React41.useState(null);
|
|
16319
|
+
const [failed, setFailed] = React41.useState({});
|
|
16181
16320
|
const connectedCount = integrations.filter((i) => i.status === "connected").length;
|
|
16182
16321
|
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: (_a = p.title) != null ? _a : "integrations", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { width: "100%", display: "flex", flexDirection: "column", gap: "11px" }, children: [
|
|
16183
16322
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: [
|
|
@@ -16660,13 +16799,13 @@ var ellipsis = {
|
|
|
16660
16799
|
function PipelinePreviewResolver(p) {
|
|
16661
16800
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
16662
16801
|
const { MUTED: MUTED2, PAPER: PAPER2, BORDER: BORDER4, ACCENT: ACCENT2, ACCENT_SOFT: ACCENT_SOFT2 } = useTheme();
|
|
16663
|
-
const [btnHovered, setBtnHovered] =
|
|
16802
|
+
const [btnHovered, setBtnHovered] = React41.useState(false);
|
|
16664
16803
|
const stateCfg = STATE_CONFIG[(_a = p.state) != null ? _a : "draft"];
|
|
16665
16804
|
const destinations = (_b = p.destinations) != null ? _b : [];
|
|
16666
16805
|
const steps = (_c = p.steps) != null ? _c : [];
|
|
16667
16806
|
const workstreams = (_d = p.workstreams) != null ? _d : [];
|
|
16668
16807
|
const scheduleLabel = p.schedule ? p.schedule.type === "manual" ? "Manual" : (_f = (_e = p.schedule.label) != null ? _e : p.schedule.cron) != null ? _f : "Scheduled" : null;
|
|
16669
|
-
const { nodes, edges, viewBox, vbW, vbH } =
|
|
16808
|
+
const { nodes, edges, viewBox, vbW, vbH } = React41.useMemo(() => {
|
|
16670
16809
|
const res = layoutGraph(steps);
|
|
16671
16810
|
const b = layoutBounds(res.nodes);
|
|
16672
16811
|
const pad = 24;
|
|
@@ -16680,7 +16819,7 @@ function PipelinePreviewResolver(p) {
|
|
|
16680
16819
|
vbH: h
|
|
16681
16820
|
};
|
|
16682
16821
|
}, [steps]);
|
|
16683
|
-
const nodeMap =
|
|
16822
|
+
const nodeMap = React41.useMemo(() => {
|
|
16684
16823
|
const m = {};
|
|
16685
16824
|
nodes.forEach((n) => m[n.id] = n);
|
|
16686
16825
|
return m;
|
|
@@ -17048,6 +17187,729 @@ function PipelinePreviewResolver(p) {
|
|
|
17048
17187
|
)
|
|
17049
17188
|
] }) });
|
|
17050
17189
|
}
|
|
17190
|
+
init_ThemeContext();
|
|
17191
|
+
var DEFAULT_INTERACTION = {
|
|
17192
|
+
selectedStepId: null,
|
|
17193
|
+
onStepSelect: void 0
|
|
17194
|
+
};
|
|
17195
|
+
var GenUIInteractionContext = React41.createContext(DEFAULT_INTERACTION);
|
|
17196
|
+
function GenUIInteractionProvider({ value, children }) {
|
|
17197
|
+
return /* @__PURE__ */ jsxRuntime.jsx(GenUIInteractionContext.Provider, { value, children });
|
|
17198
|
+
}
|
|
17199
|
+
function useGenUIInteraction() {
|
|
17200
|
+
return React41.useContext(GenUIInteractionContext);
|
|
17201
|
+
}
|
|
17202
|
+
var STATUS_COLORS3 = {
|
|
17203
|
+
done: "#15803d",
|
|
17204
|
+
active: "",
|
|
17205
|
+
// filled from theme ACCENT at render time
|
|
17206
|
+
review: "#f59e0b",
|
|
17207
|
+
pending: "#9ca3af",
|
|
17208
|
+
failed: "#dc2626"
|
|
17209
|
+
};
|
|
17210
|
+
var STATUS_LABELS = {
|
|
17211
|
+
done: "Complete",
|
|
17212
|
+
active: "In progress",
|
|
17213
|
+
review: "In review",
|
|
17214
|
+
pending: "Pending",
|
|
17215
|
+
failed: "Failed"
|
|
17216
|
+
};
|
|
17217
|
+
var HUMAN_PALETTE = ["#2563eb", "#0f766e", "#7c3aed", "#b45309", "#be185d", "#4d7c0f"];
|
|
17218
|
+
function hashColor(name) {
|
|
17219
|
+
let h = 0;
|
|
17220
|
+
for (let i = 0; i < name.length; i++) h = h * 31 + name.charCodeAt(i) | 0;
|
|
17221
|
+
return HUMAN_PALETTE[Math.abs(h) % HUMAN_PALETTE.length];
|
|
17222
|
+
}
|
|
17223
|
+
function initialsOf(a) {
|
|
17224
|
+
var _a, _b, _c, _d;
|
|
17225
|
+
if (a.initials) return a.initials.slice(0, 2).toUpperCase();
|
|
17226
|
+
const parts = a.name.trim().split(/\s+/);
|
|
17227
|
+
return (((_b = (_a = parts[0]) == null ? void 0 : _a[0]) != null ? _b : "") + ((_d = (_c = parts[1]) == null ? void 0 : _c[0]) != null ? _d : "")).toUpperCase() || "?";
|
|
17228
|
+
}
|
|
17229
|
+
function SparkMark({ size, color }) {
|
|
17230
|
+
return /* @__PURE__ */ jsxRuntime.jsx("svg", { width: size, height: size, viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
17231
|
+
"path",
|
|
17232
|
+
{
|
|
17233
|
+
d: "M12 2C12 2 12.8 6.5 14.5 9.5C16.2 12.5 20 13 20 13C20 13 16.2 13.5 14.5 16.5C12.8 19.5 12 24 12 24C12 24 11.2 19.5 9.5 16.5C7.8 13.5 4 13 4 13C4 13 7.8 12.5 9.5 9.5C11.2 6.5 12 2 12 2Z",
|
|
17234
|
+
fill: color
|
|
17235
|
+
}
|
|
17236
|
+
) });
|
|
17237
|
+
}
|
|
17238
|
+
function AvatarStack({ assignees, accent }) {
|
|
17239
|
+
const shown = assignees.slice(0, 4);
|
|
17240
|
+
const overflow = assignees.length - shown.length;
|
|
17241
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center" }, children: [
|
|
17242
|
+
shown.map((a, i) => {
|
|
17243
|
+
const isAgent = a.kind === "agent";
|
|
17244
|
+
const bg = isAgent ? `${accent}1f` : a.color || hashColor(a.name);
|
|
17245
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17246
|
+
"div",
|
|
17247
|
+
{
|
|
17248
|
+
title: `${a.name}${a.role ? ` \xB7 ${a.role}` : isAgent ? " \xB7 agent" : ""}`,
|
|
17249
|
+
style: {
|
|
17250
|
+
width: 20,
|
|
17251
|
+
height: 20,
|
|
17252
|
+
borderRadius: "50%",
|
|
17253
|
+
flexShrink: 0,
|
|
17254
|
+
marginLeft: i === 0 ? 0 : -7,
|
|
17255
|
+
zIndex: shown.length - i,
|
|
17256
|
+
display: "flex",
|
|
17257
|
+
alignItems: "center",
|
|
17258
|
+
justifyContent: "center",
|
|
17259
|
+
background: bg,
|
|
17260
|
+
border: "1.5px solid white",
|
|
17261
|
+
boxShadow: isAgent ? `inset 0 0 0 1px ${accent}59` : "none"
|
|
17262
|
+
},
|
|
17263
|
+
children: isAgent ? /* @__PURE__ */ jsxRuntime.jsx(SparkMark, { size: 11, color: accent }) : /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: 8, fontWeight: 700, color: "white", letterSpacing: "0.02em" }, children: initialsOf(a) })
|
|
17264
|
+
},
|
|
17265
|
+
`${a.name}-${i}`
|
|
17266
|
+
);
|
|
17267
|
+
}),
|
|
17268
|
+
overflow > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
17269
|
+
"span",
|
|
17270
|
+
{
|
|
17271
|
+
style: {
|
|
17272
|
+
marginLeft: -7,
|
|
17273
|
+
zIndex: 0,
|
|
17274
|
+
width: 20,
|
|
17275
|
+
height: 20,
|
|
17276
|
+
borderRadius: "50%",
|
|
17277
|
+
background: "#f2f2f2",
|
|
17278
|
+
border: "1.5px solid white",
|
|
17279
|
+
display: "flex",
|
|
17280
|
+
alignItems: "center",
|
|
17281
|
+
justifyContent: "center",
|
|
17282
|
+
fontSize: 8,
|
|
17283
|
+
fontWeight: 700,
|
|
17284
|
+
color: "#777777"
|
|
17285
|
+
},
|
|
17286
|
+
children: [
|
|
17287
|
+
"+",
|
|
17288
|
+
overflow
|
|
17289
|
+
]
|
|
17290
|
+
}
|
|
17291
|
+
)
|
|
17292
|
+
] });
|
|
17293
|
+
}
|
|
17294
|
+
function IndexDot({ step, index, accent }) {
|
|
17295
|
+
var _a;
|
|
17296
|
+
const n = (_a = step.n) != null ? _a : index + 1;
|
|
17297
|
+
const base = {
|
|
17298
|
+
width: 18,
|
|
17299
|
+
height: 18,
|
|
17300
|
+
borderRadius: "50%",
|
|
17301
|
+
flexShrink: 0,
|
|
17302
|
+
display: "flex",
|
|
17303
|
+
alignItems: "center",
|
|
17304
|
+
justifyContent: "center",
|
|
17305
|
+
fontSize: 10,
|
|
17306
|
+
fontWeight: 700,
|
|
17307
|
+
lineHeight: 1
|
|
17308
|
+
};
|
|
17309
|
+
if (step.status === "done") {
|
|
17310
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { style: __spreadProps(__spreadValues({}, base), { background: "#15803d", color: "white" }), children: /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: 10 }, children: "\u2713" }) });
|
|
17311
|
+
}
|
|
17312
|
+
if (step.status === "failed") {
|
|
17313
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { style: __spreadProps(__spreadValues({}, base), { background: "#dc2626", color: "white" }), children: /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: 10 }, children: "!" }) });
|
|
17314
|
+
}
|
|
17315
|
+
if (step.status === "active") {
|
|
17316
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { style: __spreadProps(__spreadValues({}, base), { background: accent, color: "white" }), children: n });
|
|
17317
|
+
}
|
|
17318
|
+
if (step.status === "review") {
|
|
17319
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { style: __spreadProps(__spreadValues({}, base), { background: "white", border: "1.5px solid #f59e0b", color: "#b45309" }), children: n });
|
|
17320
|
+
}
|
|
17321
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { style: __spreadProps(__spreadValues({}, base), { background: "#f2f2f2", color: "#9ca3af" }), children: n });
|
|
17322
|
+
}
|
|
17323
|
+
var CARD_MIN = 132;
|
|
17324
|
+
var CARD_GAP = 16;
|
|
17325
|
+
var AUTO_COMPACT_BELOW = 360;
|
|
17326
|
+
function useContainerWidth(ref) {
|
|
17327
|
+
const [w, setW] = React41__default.default.useState(0);
|
|
17328
|
+
React41__default.default.useLayoutEffect(() => {
|
|
17329
|
+
const el = ref.current;
|
|
17330
|
+
if (!el || typeof ResizeObserver === "undefined") return;
|
|
17331
|
+
const ro = new ResizeObserver((entries) => {
|
|
17332
|
+
var _a;
|
|
17333
|
+
const cr = (_a = entries[0]) == null ? void 0 : _a.contentRect;
|
|
17334
|
+
if (cr) setW(cr.width);
|
|
17335
|
+
});
|
|
17336
|
+
ro.observe(el);
|
|
17337
|
+
setW(el.getBoundingClientRect().width);
|
|
17338
|
+
return () => ro.disconnect();
|
|
17339
|
+
}, [ref]);
|
|
17340
|
+
return w;
|
|
17341
|
+
}
|
|
17342
|
+
var KEYFRAMES = `
|
|
17343
|
+
@keyframes wfsPulse{0%,100%{opacity:1}50%{opacity:.35}}
|
|
17344
|
+
@keyframes wfsLampPulse{0%,100%{box-shadow:0 0 0 0 var(--wfs-accent,#6366f1)73}50%{box-shadow:0 0 0 4px transparent}}
|
|
17345
|
+
@keyframes wfsRise{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
|
|
17346
|
+
@keyframes wfsShimmer{0%{background-position:-200px 0}100%{background-position:calc(200px + 100%) 0}}
|
|
17347
|
+
.wfs-rise{animation:wfsRise 0.32s cubic-bezier(0.22,1,0.36,1) both}
|
|
17348
|
+
@media (prefers-reduced-motion: reduce){
|
|
17349
|
+
.wfs-anim,.wfs-rise,.wfs-shim{animation:none !important}
|
|
17350
|
+
.wfs-rise{opacity:1 !important;transform:none !important}
|
|
17351
|
+
}`;
|
|
17352
|
+
function ProgressMeter({
|
|
17353
|
+
done,
|
|
17354
|
+
total,
|
|
17355
|
+
accent,
|
|
17356
|
+
muted,
|
|
17357
|
+
loading
|
|
17358
|
+
}) {
|
|
17359
|
+
const pct = total > 0 ? Math.round(done / total * 100) : 0;
|
|
17360
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
17361
|
+
"div",
|
|
17362
|
+
{
|
|
17363
|
+
"data-testid": "workflow-stepper-progress",
|
|
17364
|
+
style: { display: "flex", alignItems: "center", gap: 8, padding: "0 2px 6px" },
|
|
17365
|
+
children: [
|
|
17366
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17367
|
+
"span",
|
|
17368
|
+
{
|
|
17369
|
+
style: {
|
|
17370
|
+
fontSize: 10.5,
|
|
17371
|
+
fontWeight: 600,
|
|
17372
|
+
color: muted,
|
|
17373
|
+
fontVariantNumeric: "tabular-nums",
|
|
17374
|
+
letterSpacing: "0.01em",
|
|
17375
|
+
whiteSpace: "nowrap"
|
|
17376
|
+
},
|
|
17377
|
+
children: loading ? "\u2014" : `${done} / ${total} \xB7 ${pct}%`
|
|
17378
|
+
}
|
|
17379
|
+
),
|
|
17380
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17381
|
+
"span",
|
|
17382
|
+
{
|
|
17383
|
+
style: {
|
|
17384
|
+
flex: 1,
|
|
17385
|
+
height: 3,
|
|
17386
|
+
borderRadius: 3,
|
|
17387
|
+
background: "#eceff4",
|
|
17388
|
+
overflow: "hidden",
|
|
17389
|
+
minWidth: 40
|
|
17390
|
+
},
|
|
17391
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
17392
|
+
"span",
|
|
17393
|
+
{
|
|
17394
|
+
className: loading ? "wfs-shim" : void 0,
|
|
17395
|
+
style: {
|
|
17396
|
+
display: "block",
|
|
17397
|
+
height: "100%",
|
|
17398
|
+
width: loading ? "100%" : `${pct}%`,
|
|
17399
|
+
borderRadius: 3,
|
|
17400
|
+
background: loading ? `linear-gradient(90deg, #eceff4, ${accent}55, #eceff4)` : accent,
|
|
17401
|
+
backgroundSize: loading ? "200px 100%" : void 0,
|
|
17402
|
+
animation: loading ? "wfsShimmer 1.1s linear infinite" : void 0,
|
|
17403
|
+
transition: "width 0.45s cubic-bezier(0.22,1,0.36,1)"
|
|
17404
|
+
}
|
|
17405
|
+
}
|
|
17406
|
+
)
|
|
17407
|
+
}
|
|
17408
|
+
)
|
|
17409
|
+
]
|
|
17410
|
+
}
|
|
17411
|
+
);
|
|
17412
|
+
}
|
|
17413
|
+
function WorkflowStepperRenderer({
|
|
17414
|
+
data,
|
|
17415
|
+
selectedStep = null,
|
|
17416
|
+
onSelectStep,
|
|
17417
|
+
density = "auto",
|
|
17418
|
+
loading = false,
|
|
17419
|
+
loadingSteps = 6,
|
|
17420
|
+
showProgress = true
|
|
17421
|
+
}) {
|
|
17422
|
+
var _a, _b, _c, _d, _e, _f;
|
|
17423
|
+
const { BORDER: BORDER4, MUTED: MUTED2, ACCENT: ACCENT2 } = useTheme();
|
|
17424
|
+
const steps = (_a = data.steps) != null ? _a : [];
|
|
17425
|
+
const activeStepId = (_d = (_c = data.active_step) != null ? _c : (_b = steps.find((s) => s.status === "active")) == null ? void 0 : _b.id) != null ? _d : null;
|
|
17426
|
+
const interactive = typeof onSelectStep === "function";
|
|
17427
|
+
const statusColor3 = (s) => s === "active" ? ACCENT2 : STATUS_COLORS3[s];
|
|
17428
|
+
const doneCount = steps.filter((s) => s.status === "done").length;
|
|
17429
|
+
const rootRef = React41__default.default.useRef(null);
|
|
17430
|
+
const containerW = useContainerWidth(rootRef);
|
|
17431
|
+
let resolved = density === "auto" ? "full" : density;
|
|
17432
|
+
if (density === "auto" && containerW > 0) {
|
|
17433
|
+
const needed = steps.length * CARD_MIN + Math.max(0, steps.length - 1) * CARD_GAP;
|
|
17434
|
+
resolved = containerW < AUTO_COMPACT_BELOW || needed > containerW * 1.6 ? "compact" : "full";
|
|
17435
|
+
}
|
|
17436
|
+
const scrollerRef = React41__default.default.useRef(null);
|
|
17437
|
+
React41__default.default.useEffect(() => {
|
|
17438
|
+
if (resolved !== "full" || loading) return;
|
|
17439
|
+
const sc = scrollerRef.current;
|
|
17440
|
+
if (!sc) return;
|
|
17441
|
+
const el = sc.querySelector(
|
|
17442
|
+
`[data-testid="workflow-stepper-step-${selectedStep != null ? selectedStep : activeStepId}"]`
|
|
17443
|
+
);
|
|
17444
|
+
if (el && sc.scrollWidth > sc.clientWidth) {
|
|
17445
|
+
el.scrollIntoView({ inline: "center", block: "nearest", behavior: "smooth" });
|
|
17446
|
+
}
|
|
17447
|
+
}, [resolved, loading, selectedStep, activeStepId]);
|
|
17448
|
+
const [edges, setEdges] = React41__default.default.useState({
|
|
17449
|
+
left: false,
|
|
17450
|
+
right: false
|
|
17451
|
+
});
|
|
17452
|
+
const updateEdges = React41__default.default.useCallback(() => {
|
|
17453
|
+
const sc = scrollerRef.current;
|
|
17454
|
+
if (!sc) return;
|
|
17455
|
+
const max = sc.scrollWidth - sc.clientWidth;
|
|
17456
|
+
const sl = sc.scrollLeft;
|
|
17457
|
+
const left = sl > 1;
|
|
17458
|
+
const right = sl < max - 1;
|
|
17459
|
+
setEdges((prev) => prev.left === left && prev.right === right ? prev : { left, right });
|
|
17460
|
+
}, []);
|
|
17461
|
+
React41__default.default.useLayoutEffect(() => {
|
|
17462
|
+
if (resolved !== "full" || loading) return;
|
|
17463
|
+
updateEdges();
|
|
17464
|
+
const sc = scrollerRef.current;
|
|
17465
|
+
if (!sc || typeof ResizeObserver === "undefined") return;
|
|
17466
|
+
const ro = new ResizeObserver(updateEdges);
|
|
17467
|
+
ro.observe(sc);
|
|
17468
|
+
return () => ro.disconnect();
|
|
17469
|
+
}, [resolved, loading, steps.length, updateEdges]);
|
|
17470
|
+
const edgeMask = edges.left || edges.right ? `linear-gradient(90deg, ${edges.left ? "transparent 0, #000 14px" : "#000 0"}, ${edges.right ? "#000 calc(100% - 14px), transparent 100%" : "#000 100%"})` : void 0;
|
|
17471
|
+
const themeStyle = { ["--wfs-accent"]: ACCENT2 };
|
|
17472
|
+
if (loading) {
|
|
17473
|
+
const ghosts = Array.from({ length: Math.max(2, loadingSteps) });
|
|
17474
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-testid": "workflow-stepper-loading", style: __spreadValues({ width: "100%", minWidth: 0 }, themeStyle), children: [
|
|
17475
|
+
/* @__PURE__ */ jsxRuntime.jsx("style", { children: KEYFRAMES }),
|
|
17476
|
+
showProgress && /* @__PURE__ */ jsxRuntime.jsx(ProgressMeter, { done: 0, total: 0, accent: ACCENT2, muted: MUTED2, loading: true }),
|
|
17477
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", alignItems: "stretch", gap: CARD_GAP, padding: "2px 2px 6px", overflow: "hidden" }, children: ghosts.map((_, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
17478
|
+
"div",
|
|
17479
|
+
{
|
|
17480
|
+
className: "wfs-shim",
|
|
17481
|
+
"aria-hidden": "true",
|
|
17482
|
+
style: {
|
|
17483
|
+
flex: "0 1 168px",
|
|
17484
|
+
minWidth: CARD_MIN,
|
|
17485
|
+
height: 84,
|
|
17486
|
+
borderRadius: 10,
|
|
17487
|
+
border: `1px solid ${BORDER4}`,
|
|
17488
|
+
background: `linear-gradient(90deg, #f4f6f9, #eceff4 40%, #f4f6f9 80%)`,
|
|
17489
|
+
backgroundSize: "200px 100%",
|
|
17490
|
+
animation: "wfsShimmer 1.1s linear infinite",
|
|
17491
|
+
animationDelay: `${i * 0.08}s`
|
|
17492
|
+
}
|
|
17493
|
+
},
|
|
17494
|
+
i
|
|
17495
|
+
)) })
|
|
17496
|
+
] });
|
|
17497
|
+
}
|
|
17498
|
+
if (resolved === "compact") {
|
|
17499
|
+
const activeStep = (_e = steps.find((s) => s.id === activeStepId)) != null ? _e : null;
|
|
17500
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
17501
|
+
"div",
|
|
17502
|
+
{
|
|
17503
|
+
ref: rootRef,
|
|
17504
|
+
"data-testid": "workflow-stepper-compact",
|
|
17505
|
+
style: __spreadValues({ width: "100%", minWidth: 0 }, themeStyle),
|
|
17506
|
+
children: [
|
|
17507
|
+
/* @__PURE__ */ jsxRuntime.jsx("style", { children: KEYFRAMES }),
|
|
17508
|
+
showProgress && /* @__PURE__ */ jsxRuntime.jsx(ProgressMeter, { done: doneCount, total: steps.length, accent: ACCENT2, muted: MUTED2 }),
|
|
17509
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: 12, minWidth: 0 }, children: [
|
|
17510
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", alignItems: "center", flexShrink: 0 }, children: steps.map((s, i) => {
|
|
17511
|
+
const sel = selectedStep === s.id;
|
|
17512
|
+
const act = s.status === "active";
|
|
17513
|
+
const done = s.status === "done";
|
|
17514
|
+
const reached = s.status !== "pending";
|
|
17515
|
+
const clickable = interactive && reached;
|
|
17516
|
+
const size = act ? 11 : done ? 9 : 8;
|
|
17517
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
17518
|
+
i > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17519
|
+
"span",
|
|
17520
|
+
{
|
|
17521
|
+
"aria-hidden": "true",
|
|
17522
|
+
style: {
|
|
17523
|
+
width: 14,
|
|
17524
|
+
height: 1.5,
|
|
17525
|
+
borderRadius: 1,
|
|
17526
|
+
background: steps[i - 1].status === "done" ? "#15803d" : "#e5e7eb",
|
|
17527
|
+
transition: "background 0.36s ease-out"
|
|
17528
|
+
}
|
|
17529
|
+
}
|
|
17530
|
+
),
|
|
17531
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17532
|
+
"button",
|
|
17533
|
+
{
|
|
17534
|
+
type: "button",
|
|
17535
|
+
disabled: interactive && !reached,
|
|
17536
|
+
"aria-disabled": interactive && !reached ? true : void 0,
|
|
17537
|
+
title: `${s.title} \xB7 ${STATUS_LABELS[s.status]}`,
|
|
17538
|
+
onClick: clickable ? () => onSelectStep == null ? void 0 : onSelectStep(sel ? null : s.id) : void 0,
|
|
17539
|
+
"data-testid": `workflow-stepper-step-${s.id}`,
|
|
17540
|
+
"data-status": s.status,
|
|
17541
|
+
"data-reached": reached || void 0,
|
|
17542
|
+
className: act ? "wfs-anim" : void 0,
|
|
17543
|
+
style: {
|
|
17544
|
+
position: "relative",
|
|
17545
|
+
width: size,
|
|
17546
|
+
height: size,
|
|
17547
|
+
padding: 0,
|
|
17548
|
+
borderRadius: "50%",
|
|
17549
|
+
background: statusColor3(s.status),
|
|
17550
|
+
flexShrink: 0,
|
|
17551
|
+
// border-box so the selected 2px border can't grow the dot
|
|
17552
|
+
// and reflow the rail.
|
|
17553
|
+
boxSizing: "border-box",
|
|
17554
|
+
opacity: reached ? 1 : 0.55,
|
|
17555
|
+
border: sel ? `2px solid ${ACCENT2}` : done ? "none" : "1px solid rgba(255,255,255,0.6)",
|
|
17556
|
+
boxShadow: sel ? "0 0 0 2px #fff" : "none",
|
|
17557
|
+
cursor: clickable ? "pointer" : "default",
|
|
17558
|
+
transition: "width 0.15s, height 0.15s",
|
|
17559
|
+
animation: act ? "wfsLampPulse 1.8s ease-in-out infinite" : "none"
|
|
17560
|
+
}
|
|
17561
|
+
}
|
|
17562
|
+
)
|
|
17563
|
+
] }, s.id);
|
|
17564
|
+
}) }),
|
|
17565
|
+
activeStep && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
17566
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": "true", style: { width: 1, height: 16, background: "#e6eaf1", flexShrink: 0 } }),
|
|
17567
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { style: { display: "flex", alignItems: "center", gap: 7, minWidth: 0 }, children: [
|
|
17568
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17569
|
+
"span",
|
|
17570
|
+
{
|
|
17571
|
+
"aria-hidden": "true",
|
|
17572
|
+
style: {
|
|
17573
|
+
width: 17,
|
|
17574
|
+
height: 17,
|
|
17575
|
+
borderRadius: "50%",
|
|
17576
|
+
flexShrink: 0,
|
|
17577
|
+
display: "flex",
|
|
17578
|
+
alignItems: "center",
|
|
17579
|
+
justifyContent: "center",
|
|
17580
|
+
fontSize: 9.5,
|
|
17581
|
+
fontWeight: 700,
|
|
17582
|
+
lineHeight: 1,
|
|
17583
|
+
background: activeStep.status === "done" ? "#15803d" : activeStep.status === "review" ? "#fff" : activeStep.status === "failed" ? "#dc2626" : ACCENT2,
|
|
17584
|
+
color: activeStep.status === "review" ? "#b45309" : "#fff",
|
|
17585
|
+
border: activeStep.status === "review" ? "1.5px solid #f59e0b" : "none"
|
|
17586
|
+
},
|
|
17587
|
+
children: activeStep.status === "done" ? "\u2713" : activeStep.status === "failed" ? "!" : (_f = activeStep.n) != null ? _f : steps.findIndex((x) => x.id === activeStep.id) + 1
|
|
17588
|
+
}
|
|
17589
|
+
),
|
|
17590
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
17591
|
+
"span",
|
|
17592
|
+
{
|
|
17593
|
+
style: {
|
|
17594
|
+
fontSize: 12.5,
|
|
17595
|
+
fontWeight: 650,
|
|
17596
|
+
color: "var(--foreground)",
|
|
17597
|
+
letterSpacing: "-0.01em",
|
|
17598
|
+
whiteSpace: "nowrap",
|
|
17599
|
+
overflow: "hidden",
|
|
17600
|
+
textOverflow: "ellipsis",
|
|
17601
|
+
minWidth: 0
|
|
17602
|
+
},
|
|
17603
|
+
children: [
|
|
17604
|
+
activeStep.title,
|
|
17605
|
+
activeStep.sub ? /* @__PURE__ */ jsxRuntime.jsxs("span", { style: { fontWeight: 400, color: MUTED2 }, children: [
|
|
17606
|
+
" \xB7 ",
|
|
17607
|
+
activeStep.sub
|
|
17608
|
+
] }) : null
|
|
17609
|
+
]
|
|
17610
|
+
}
|
|
17611
|
+
)
|
|
17612
|
+
] })
|
|
17613
|
+
] })
|
|
17614
|
+
] })
|
|
17615
|
+
]
|
|
17616
|
+
}
|
|
17617
|
+
);
|
|
17618
|
+
}
|
|
17619
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref: rootRef, "data-testid": "workflow-stepper", style: __spreadValues({ width: "100%", minWidth: 0 }, themeStyle), children: [
|
|
17620
|
+
/* @__PURE__ */ jsxRuntime.jsx("style", { children: KEYFRAMES }),
|
|
17621
|
+
showProgress && /* @__PURE__ */ jsxRuntime.jsx(ProgressMeter, { done: doneCount, total: steps.length, accent: ACCENT2, muted: MUTED2 }),
|
|
17622
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
17623
|
+
"div",
|
|
17624
|
+
{
|
|
17625
|
+
ref: scrollerRef,
|
|
17626
|
+
className: "wfs-scroller",
|
|
17627
|
+
onScroll: updateEdges,
|
|
17628
|
+
style: {
|
|
17629
|
+
display: "flex",
|
|
17630
|
+
alignItems: "stretch",
|
|
17631
|
+
overflowX: "auto",
|
|
17632
|
+
scrollSnapType: "x proximity",
|
|
17633
|
+
padding: "2px 2px 4px",
|
|
17634
|
+
// Thin, always-styled scrollbar (Firefox + Windows/desktop WebKit
|
|
17635
|
+
// where overlay scrollbars aren't available). macOS/mobile show
|
|
17636
|
+
// overlay scrollbars on scroll; harmless either way.
|
|
17637
|
+
scrollbarWidth: "thin",
|
|
17638
|
+
scrollbarColor: "#c2c9d6 transparent",
|
|
17639
|
+
// Edge fade ONLY on the side(s) with hidden content — never when the
|
|
17640
|
+
// row isn't scrollable, so the last card's right edge stays crisp.
|
|
17641
|
+
maskImage: edgeMask,
|
|
17642
|
+
WebkitMaskImage: edgeMask
|
|
17643
|
+
},
|
|
17644
|
+
children: [
|
|
17645
|
+
/* @__PURE__ */ jsxRuntime.jsx("style", { children: `
|
|
17646
|
+
.wfs-scroller::-webkit-scrollbar{height:8px}
|
|
17647
|
+
.wfs-scroller::-webkit-scrollbar-track{background:transparent}
|
|
17648
|
+
.wfs-scroller::-webkit-scrollbar-thumb{background:#c2c9d6;border-radius:8px;border:2px solid transparent;background-clip:padding-box}
|
|
17649
|
+
.wfs-scroller:hover::-webkit-scrollbar-thumb{background:#aab2c2;background-clip:padding-box}
|
|
17650
|
+
` }),
|
|
17651
|
+
steps.map((step, i) => {
|
|
17652
|
+
var _a2;
|
|
17653
|
+
const isSelected = selectedStep === step.id;
|
|
17654
|
+
const isActive = step.status === "active";
|
|
17655
|
+
const reached = step.status !== "pending";
|
|
17656
|
+
const clickable = interactive && reached;
|
|
17657
|
+
const color = statusColor3(step.status);
|
|
17658
|
+
const humans = ((_a2 = step.assignees) != null ? _a2 : []).filter((a) => a.kind === "human");
|
|
17659
|
+
const roleCaption = humans.map((h) => h.role).filter(Boolean).slice(0, 2).join(" \xB7 ");
|
|
17660
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React41__default.default.Fragment, { children: [
|
|
17661
|
+
i > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17662
|
+
"div",
|
|
17663
|
+
{
|
|
17664
|
+
style: {
|
|
17665
|
+
width: CARD_GAP,
|
|
17666
|
+
flexShrink: 0,
|
|
17667
|
+
display: "flex",
|
|
17668
|
+
alignItems: "center"
|
|
17669
|
+
},
|
|
17670
|
+
"aria-hidden": "true",
|
|
17671
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
17672
|
+
"div",
|
|
17673
|
+
{
|
|
17674
|
+
style: {
|
|
17675
|
+
width: "100%",
|
|
17676
|
+
height: 1.5,
|
|
17677
|
+
borderRadius: 1,
|
|
17678
|
+
// Fill sweep: completed rails wash green left→right.
|
|
17679
|
+
background: steps[i - 1].status === "done" ? "linear-gradient(90deg, #15803d, #15803d)" : "#e5e7eb",
|
|
17680
|
+
backgroundSize: "100% 100%",
|
|
17681
|
+
transition: "background 0.36s ease-out"
|
|
17682
|
+
}
|
|
17683
|
+
}
|
|
17684
|
+
)
|
|
17685
|
+
}
|
|
17686
|
+
),
|
|
17687
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
17688
|
+
"div",
|
|
17689
|
+
{
|
|
17690
|
+
role: clickable ? "button" : void 0,
|
|
17691
|
+
tabIndex: clickable ? 0 : void 0,
|
|
17692
|
+
"aria-disabled": interactive && !reached ? true : void 0,
|
|
17693
|
+
className: "wfs-rise",
|
|
17694
|
+
"data-testid": `workflow-stepper-step-${step.id}`,
|
|
17695
|
+
"data-status": step.status,
|
|
17696
|
+
"data-selected": isSelected || void 0,
|
|
17697
|
+
"data-reached": reached || void 0,
|
|
17698
|
+
onClick: clickable ? () => onSelectStep == null ? void 0 : onSelectStep(isSelected ? null : step.id) : void 0,
|
|
17699
|
+
onKeyDown: clickable ? (e) => {
|
|
17700
|
+
if (e.key === "Enter" || e.key === " ") {
|
|
17701
|
+
e.preventDefault();
|
|
17702
|
+
onSelectStep == null ? void 0 : onSelectStep(isSelected ? null : step.id);
|
|
17703
|
+
}
|
|
17704
|
+
} : void 0,
|
|
17705
|
+
onMouseEnter: clickable ? (e) => {
|
|
17706
|
+
e.currentTarget.style.transform = "translateY(-1px)";
|
|
17707
|
+
e.currentTarget.style.boxShadow = "0 3px 10px rgba(15,23,42,0.08)";
|
|
17708
|
+
} : void 0,
|
|
17709
|
+
onMouseLeave: clickable ? (e) => {
|
|
17710
|
+
e.currentTarget.style.transform = "none";
|
|
17711
|
+
e.currentTarget.style.boxShadow = "0 1px 2px rgba(0,0,0,0.04)";
|
|
17712
|
+
} : void 0,
|
|
17713
|
+
style: {
|
|
17714
|
+
position: "relative",
|
|
17715
|
+
flex: "0 1 168px",
|
|
17716
|
+
minWidth: CARD_MIN,
|
|
17717
|
+
maxWidth: 208,
|
|
17718
|
+
scrollSnapAlign: "center",
|
|
17719
|
+
borderRadius: 10,
|
|
17720
|
+
boxSizing: "border-box",
|
|
17721
|
+
// Selection changes border COLOR only (constant 1px width) so
|
|
17722
|
+
// the card never reflows the row on click.
|
|
17723
|
+
border: `1px solid ${isSelected ? ACCENT2 : BORDER4}`,
|
|
17724
|
+
background: isSelected ? `${ACCENT2}0d` : "white",
|
|
17725
|
+
boxShadow: "0 1px 2px rgba(0,0,0,0.04)",
|
|
17726
|
+
padding: "10px 11px",
|
|
17727
|
+
display: "flex",
|
|
17728
|
+
flexDirection: "column",
|
|
17729
|
+
gap: 7,
|
|
17730
|
+
cursor: clickable ? "pointer" : "default",
|
|
17731
|
+
opacity: reached ? 1 : 0.62,
|
|
17732
|
+
transition: "border-color 0.15s, background 0.15s, transform 0.12s, box-shadow 0.12s",
|
|
17733
|
+
animationDelay: `${Math.min(i, 10) * 0.04}s`,
|
|
17734
|
+
overflow: "hidden"
|
|
17735
|
+
},
|
|
17736
|
+
children: [
|
|
17737
|
+
isActive && !isSelected && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17738
|
+
"span",
|
|
17739
|
+
{
|
|
17740
|
+
style: {
|
|
17741
|
+
position: "absolute",
|
|
17742
|
+
left: 0,
|
|
17743
|
+
top: 6,
|
|
17744
|
+
bottom: 6,
|
|
17745
|
+
width: 2,
|
|
17746
|
+
borderRadius: 2,
|
|
17747
|
+
background: ACCENT2
|
|
17748
|
+
}
|
|
17749
|
+
}
|
|
17750
|
+
),
|
|
17751
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between" }, children: [
|
|
17752
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: 6 }, children: [
|
|
17753
|
+
/* @__PURE__ */ jsxRuntime.jsx(IndexDot, { step, index: i, accent: ACCENT2 }),
|
|
17754
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17755
|
+
"span",
|
|
17756
|
+
{
|
|
17757
|
+
className: isActive ? "wfs-anim" : void 0,
|
|
17758
|
+
style: {
|
|
17759
|
+
width: 6,
|
|
17760
|
+
height: 6,
|
|
17761
|
+
borderRadius: "50%",
|
|
17762
|
+
background: color,
|
|
17763
|
+
animation: isActive ? "wfsLampPulse 1.8s ease-in-out infinite" : "none"
|
|
17764
|
+
}
|
|
17765
|
+
}
|
|
17766
|
+
)
|
|
17767
|
+
] }),
|
|
17768
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17769
|
+
"span",
|
|
17770
|
+
{
|
|
17771
|
+
style: {
|
|
17772
|
+
fontSize: 9,
|
|
17773
|
+
fontWeight: 600,
|
|
17774
|
+
letterSpacing: "0.05em",
|
|
17775
|
+
textTransform: "uppercase",
|
|
17776
|
+
color
|
|
17777
|
+
},
|
|
17778
|
+
children: STATUS_LABELS[step.status]
|
|
17779
|
+
}
|
|
17780
|
+
)
|
|
17781
|
+
] }),
|
|
17782
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { minWidth: 0 }, children: [
|
|
17783
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17784
|
+
"div",
|
|
17785
|
+
{
|
|
17786
|
+
style: {
|
|
17787
|
+
fontSize: 12.5,
|
|
17788
|
+
fontWeight: 600,
|
|
17789
|
+
color: "var(--foreground)",
|
|
17790
|
+
lineHeight: 1.25,
|
|
17791
|
+
letterSpacing: "-0.01em",
|
|
17792
|
+
overflow: "hidden",
|
|
17793
|
+
textOverflow: "ellipsis",
|
|
17794
|
+
whiteSpace: "nowrap"
|
|
17795
|
+
},
|
|
17796
|
+
children: step.title
|
|
17797
|
+
}
|
|
17798
|
+
),
|
|
17799
|
+
step.sub && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17800
|
+
"div",
|
|
17801
|
+
{
|
|
17802
|
+
style: {
|
|
17803
|
+
fontSize: 10.5,
|
|
17804
|
+
color: MUTED2,
|
|
17805
|
+
marginTop: 2,
|
|
17806
|
+
overflow: "hidden",
|
|
17807
|
+
textOverflow: "ellipsis",
|
|
17808
|
+
whiteSpace: "nowrap"
|
|
17809
|
+
},
|
|
17810
|
+
children: step.sub
|
|
17811
|
+
}
|
|
17812
|
+
)
|
|
17813
|
+
] }),
|
|
17814
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
17815
|
+
"div",
|
|
17816
|
+
{
|
|
17817
|
+
style: {
|
|
17818
|
+
display: "flex",
|
|
17819
|
+
alignItems: "center",
|
|
17820
|
+
justifyContent: "space-between",
|
|
17821
|
+
marginTop: "auto",
|
|
17822
|
+
minHeight: 20
|
|
17823
|
+
},
|
|
17824
|
+
children: [
|
|
17825
|
+
step.assignees && step.assignees.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(AvatarStack, { assignees: step.assignees, accent: ACCENT2 }) : /* @__PURE__ */ jsxRuntime.jsx("span", {}),
|
|
17826
|
+
roleCaption && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17827
|
+
"span",
|
|
17828
|
+
{
|
|
17829
|
+
style: {
|
|
17830
|
+
fontSize: 9,
|
|
17831
|
+
color: "#9ca3af",
|
|
17832
|
+
fontWeight: 500,
|
|
17833
|
+
textAlign: "right",
|
|
17834
|
+
maxWidth: 76,
|
|
17835
|
+
lineHeight: 1.2,
|
|
17836
|
+
overflow: "hidden"
|
|
17837
|
+
},
|
|
17838
|
+
children: roleCaption
|
|
17839
|
+
}
|
|
17840
|
+
)
|
|
17841
|
+
]
|
|
17842
|
+
}
|
|
17843
|
+
)
|
|
17844
|
+
]
|
|
17845
|
+
}
|
|
17846
|
+
)
|
|
17847
|
+
] }, step.id);
|
|
17848
|
+
})
|
|
17849
|
+
]
|
|
17850
|
+
}
|
|
17851
|
+
)
|
|
17852
|
+
] });
|
|
17853
|
+
}
|
|
17854
|
+
function WorkflowStepperResolver(p) {
|
|
17855
|
+
var _a;
|
|
17856
|
+
const { selectedStepId, onStepSelect } = useGenUIInteraction();
|
|
17857
|
+
return /* @__PURE__ */ jsxRuntime.jsx(ComponentActions, { filename: (_a = p.title) != null ? _a : "workflow-stepper", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { width: "100%", display: "flex", flexDirection: "column", gap: 10 }, children: [
|
|
17858
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: 8, flexWrap: "wrap" }, children: [
|
|
17859
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17860
|
+
"p",
|
|
17861
|
+
{
|
|
17862
|
+
style: {
|
|
17863
|
+
fontFamily: "var(--font-serif)",
|
|
17864
|
+
fontSize: "15px",
|
|
17865
|
+
fontWeight: 400,
|
|
17866
|
+
color: "var(--foreground)",
|
|
17867
|
+
letterSpacing: "-0.01em",
|
|
17868
|
+
margin: 0
|
|
17869
|
+
},
|
|
17870
|
+
children: p.title
|
|
17871
|
+
}
|
|
17872
|
+
),
|
|
17873
|
+
p.period && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17874
|
+
"span",
|
|
17875
|
+
{
|
|
17876
|
+
style: {
|
|
17877
|
+
fontSize: 11,
|
|
17878
|
+
fontWeight: 600,
|
|
17879
|
+
padding: "2px 8px",
|
|
17880
|
+
borderRadius: 9999,
|
|
17881
|
+
background: "#f2f2f2",
|
|
17882
|
+
color: "#777777",
|
|
17883
|
+
fontVariantNumeric: "tabular-nums"
|
|
17884
|
+
},
|
|
17885
|
+
children: p.period
|
|
17886
|
+
}
|
|
17887
|
+
),
|
|
17888
|
+
p.badge && /* @__PURE__ */ jsxRuntime.jsx(
|
|
17889
|
+
"span",
|
|
17890
|
+
{
|
|
17891
|
+
style: {
|
|
17892
|
+
fontSize: 11,
|
|
17893
|
+
fontWeight: 600,
|
|
17894
|
+
padding: "2px 8px",
|
|
17895
|
+
borderRadius: 9999,
|
|
17896
|
+
border: "1px solid #dedede",
|
|
17897
|
+
color: "#777777"
|
|
17898
|
+
},
|
|
17899
|
+
children: p.badge
|
|
17900
|
+
}
|
|
17901
|
+
)
|
|
17902
|
+
] }),
|
|
17903
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
17904
|
+
WorkflowStepperRenderer,
|
|
17905
|
+
{
|
|
17906
|
+
data: p,
|
|
17907
|
+
selectedStep: selectedStepId,
|
|
17908
|
+
onSelectStep: onStepSelect
|
|
17909
|
+
}
|
|
17910
|
+
)
|
|
17911
|
+
] }) });
|
|
17912
|
+
}
|
|
17051
17913
|
function resolveUI(rawPayload) {
|
|
17052
17914
|
const payload = coercePayload(rawPayload);
|
|
17053
17915
|
switch (payload.type) {
|
|
@@ -17163,6 +18025,8 @@ function resolveUI(rawPayload) {
|
|
|
17163
18025
|
return /* @__PURE__ */ jsxRuntime.jsx(IntegrationsListResolver, __spreadValues({}, payload));
|
|
17164
18026
|
case "pipeline-preview":
|
|
17165
18027
|
return /* @__PURE__ */ jsxRuntime.jsx(PipelinePreviewResolver, __spreadValues({}, payload));
|
|
18028
|
+
case "workflow-stepper":
|
|
18029
|
+
return /* @__PURE__ */ jsxRuntime.jsx(WorkflowStepperResolver, __spreadValues({}, payload));
|
|
17166
18030
|
default: {
|
|
17167
18031
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17168
18032
|
"div",
|
|
@@ -17204,7 +18068,7 @@ function InlineSpinner() {
|
|
|
17204
18068
|
}
|
|
17205
18069
|
function GenUIRenderer({ payload }) {
|
|
17206
18070
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
17207
|
-
|
|
18071
|
+
React41.Suspense,
|
|
17208
18072
|
{
|
|
17209
18073
|
fallback: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: "8px", padding: "8px 0" }, children: [
|
|
17210
18074
|
/* @__PURE__ */ jsxRuntime.jsx(InlineSpinner, {}),
|
|
@@ -17290,7 +18154,7 @@ var INPUT_ERROR = { borderColor: "#dc2626" };
|
|
|
17290
18154
|
var SELECT_EXTRA = { cursor: "pointer" };
|
|
17291
18155
|
function useInputBase() {
|
|
17292
18156
|
const { BORDER: BORDER4 } = useTheme();
|
|
17293
|
-
return
|
|
18157
|
+
return React41.useMemo(() => ({
|
|
17294
18158
|
font: "inherit",
|
|
17295
18159
|
fontSize: "13px",
|
|
17296
18160
|
padding: "7px 10px",
|
|
@@ -17371,7 +18235,7 @@ function SelectField({ field, value, onChange, disabled, error }) {
|
|
|
17371
18235
|
}
|
|
17372
18236
|
function MultiSelectField({ field, value, onChange, disabled }) {
|
|
17373
18237
|
const { MUTED: MUTED2, ACCENT: ACCENT2, BORDER: BORDER4 } = useTheme();
|
|
17374
|
-
const [hovered, setHovered] =
|
|
18238
|
+
const [hovered, setHovered] = React41.useState(null);
|
|
17375
18239
|
const options = field.options || [];
|
|
17376
18240
|
const selected = Array.isArray(value) ? value : [];
|
|
17377
18241
|
const toggle = (optValue) => {
|
|
@@ -17486,10 +18350,10 @@ function DocGlyph({ color }) {
|
|
|
17486
18350
|
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M14 2v6h6" })
|
|
17487
18351
|
] });
|
|
17488
18352
|
}
|
|
17489
|
-
function FileUploadField({ field, value, onChange, disabled, onFileUpload, error }) {
|
|
18353
|
+
function FileUploadField({ field, value, onChange, disabled, onFileUpload, error, dense }) {
|
|
17490
18354
|
const { MUTED: MUTED2, ACCENT: ACCENT2, BORDER: BORDER4, PAPER: PAPER2 } = useTheme();
|
|
17491
|
-
const keyRef =
|
|
17492
|
-
const [entries, setEntries] =
|
|
18355
|
+
const keyRef = React41__default.default.useRef(0);
|
|
18356
|
+
const [entries, setEntries] = React41.useState(() => {
|
|
17493
18357
|
const arr = Array.isArray(value) ? value : value && typeof value === "object" ? [value] : [];
|
|
17494
18358
|
return arr.map((item) => {
|
|
17495
18359
|
var _a, _b;
|
|
@@ -17497,11 +18361,11 @@ function FileUploadField({ field, value, onChange, disabled, onFileUpload, error
|
|
|
17497
18361
|
return { key: keyRef.current += 1, name: (_b = (_a = r.filename) != null ? _a : r.name) != null ? _b : "file", size: r.size, status: "done", result: r };
|
|
17498
18362
|
});
|
|
17499
18363
|
});
|
|
17500
|
-
const entriesRef =
|
|
18364
|
+
const entriesRef = React41__default.default.useRef(entries);
|
|
17501
18365
|
entriesRef.current = entries;
|
|
17502
|
-
const [dragOver, setDragOver] =
|
|
17503
|
-
const inputRef =
|
|
17504
|
-
|
|
18366
|
+
const [dragOver, setDragOver] = React41.useState(false);
|
|
18367
|
+
const inputRef = React41__default.default.useRef(null);
|
|
18368
|
+
React41__default.default.useEffect(() => {
|
|
17505
18369
|
ensureFileUploadKeyframes();
|
|
17506
18370
|
}, []);
|
|
17507
18371
|
const interactive = !disabled;
|
|
@@ -17545,6 +18409,7 @@ function FileUploadField({ field, value, onChange, disabled, onFileUpload, error
|
|
|
17545
18409
|
const removeEntry = (key) => commit(entriesRef.current.filter((e) => e.key !== key));
|
|
17546
18410
|
const borderColor = dragOver ? ACCENT2 : error ? "#dc2626" : BORDER4;
|
|
17547
18411
|
const hasFiles = entries.length > 0;
|
|
18412
|
+
const denseRow = !!dense && !hasFiles;
|
|
17548
18413
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "8px" }, children: [
|
|
17549
18414
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
17550
18415
|
"div",
|
|
@@ -17566,12 +18431,12 @@ function FileUploadField({ field, value, onChange, disabled, onFileUpload, error
|
|
|
17566
18431
|
onDrop: handleDrop,
|
|
17567
18432
|
style: {
|
|
17568
18433
|
display: "flex",
|
|
17569
|
-
flexDirection: "column",
|
|
18434
|
+
flexDirection: denseRow ? "row" : "column",
|
|
17570
18435
|
alignItems: "center",
|
|
17571
|
-
justifyContent: "center",
|
|
17572
|
-
gap: hasFiles ? "4px" : "7px",
|
|
17573
|
-
padding: hasFiles ? "12px 14px" : "18px 14px",
|
|
17574
|
-
textAlign: "center",
|
|
18436
|
+
justifyContent: denseRow ? "flex-start" : "center",
|
|
18437
|
+
gap: denseRow ? "9px" : hasFiles ? "4px" : "7px",
|
|
18438
|
+
padding: denseRow ? "9px 12px" : hasFiles ? "12px 14px" : "18px 14px",
|
|
18439
|
+
textAlign: denseRow ? "left" : "center",
|
|
17575
18440
|
border: `1.5px dashed ${borderColor}`,
|
|
17576
18441
|
borderRadius: "0.75rem",
|
|
17577
18442
|
background: dragOver ? `${ACCENT2}0d` : PAPER2,
|
|
@@ -17584,11 +18449,11 @@ function FileUploadField({ field, value, onChange, disabled, onFileUpload, error
|
|
|
17584
18449
|
},
|
|
17585
18450
|
children: [
|
|
17586
18451
|
/* @__PURE__ */ jsxRuntime.jsx(UploadGlyph, { color: dragOver ? ACCENT2 : MUTED2 }),
|
|
17587
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { style: { fontSize: "12.5px", color: "var(--foreground)" }, children: [
|
|
18452
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { style: { fontSize: denseRow ? "12px" : "12.5px", color: "var(--foreground)" }, children: [
|
|
17588
18453
|
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { color: ACCENT2, fontWeight: 600 }, children: hasFiles ? "Add more files" : "Click to upload" }),
|
|
17589
18454
|
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { color: MUTED2 }, children: " or drag and drop" })
|
|
17590
18455
|
] }),
|
|
17591
|
-
!hasFiles && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "11px", color: MUTED2 }, children: hint }),
|
|
18456
|
+
!hasFiles && !denseRow && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "11px", color: MUTED2 }, children: hint }),
|
|
17592
18457
|
/* @__PURE__ */ jsxRuntime.jsx("input", { ref: inputRef, type: "file", multiple: true, accept, onChange: handleInput, disabled: !interactive, style: { display: "none" }, tabIndex: -1 })
|
|
17593
18458
|
]
|
|
17594
18459
|
}
|
|
@@ -17626,7 +18491,7 @@ var FIELD_REGISTRY = {
|
|
|
17626
18491
|
checkbox: CheckboxField,
|
|
17627
18492
|
file_upload: FileUploadField
|
|
17628
18493
|
};
|
|
17629
|
-
function FieldRenderer({ field, value, onChange, disabled, error, onFileUpload }) {
|
|
18494
|
+
function FieldRenderer({ field, value, onChange, disabled, error, onFileUpload, dense }) {
|
|
17630
18495
|
const { MUTED: MUTED2 } = useTheme();
|
|
17631
18496
|
const FieldComp = FIELD_REGISTRY[field.field_type] || FIELD_REGISTRY.text;
|
|
17632
18497
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "3px" }, children: [
|
|
@@ -17634,12 +18499,12 @@ function FieldRenderer({ field, value, onChange, disabled, error, onFileUpload }
|
|
|
17634
18499
|
field.label,
|
|
17635
18500
|
field.required && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { color: "#dc2626", marginLeft: "2px" }, children: "*" })
|
|
17636
18501
|
] }),
|
|
17637
|
-
field.description && /* @__PURE__ */ jsxRuntime.jsx("div", { style: { fontSize: "11px", color: MUTED2, lineHeight: 1.4 }, children: field.description }),
|
|
17638
|
-
/* @__PURE__ */ jsxRuntime.jsx(FieldComp, { field, value, onChange, disabled, error, onFileUpload: field.field_type === "file_upload" ? onFileUpload : void 0 }),
|
|
18502
|
+
field.description && !dense && /* @__PURE__ */ jsxRuntime.jsx("div", { style: { fontSize: "11px", color: MUTED2, lineHeight: 1.4 }, children: field.description }),
|
|
18503
|
+
/* @__PURE__ */ jsxRuntime.jsx(FieldComp, { field, value, onChange, disabled, error, dense, onFileUpload: field.field_type === "file_upload" ? onFileUpload : void 0 }),
|
|
17639
18504
|
error && /* @__PURE__ */ jsxRuntime.jsx("div", { style: { fontSize: "11px", color: "#dc2626", fontWeight: 500, marginTop: "1px" }, children: error })
|
|
17640
18505
|
] });
|
|
17641
18506
|
}
|
|
17642
|
-
var SlotErrorBoundary = class extends
|
|
18507
|
+
var SlotErrorBoundary = class extends React41__default.default.Component {
|
|
17643
18508
|
constructor(props) {
|
|
17644
18509
|
super(props);
|
|
17645
18510
|
this.state = { hasError: false };
|
|
@@ -17685,7 +18550,7 @@ function BuilderRecap({ builder, state }) {
|
|
|
17685
18550
|
return String(value);
|
|
17686
18551
|
};
|
|
17687
18552
|
const decisionField = (b) => (b.fields || []).find((f) => f.field_type === "select") || (b.fields || [])[0];
|
|
17688
|
-
const rows =
|
|
18553
|
+
const rows = React41.useMemo(
|
|
17689
18554
|
() => blocks.map((b) => {
|
|
17690
18555
|
const df = decisionField(b);
|
|
17691
18556
|
const decision = df ? display(df, state.getValue(b.id, df.name)) : "";
|
|
@@ -17695,7 +18560,7 @@ function BuilderRecap({ builder, state }) {
|
|
|
17695
18560
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
17696
18561
|
[blocks, state.values]
|
|
17697
18562
|
);
|
|
17698
|
-
const counts =
|
|
18563
|
+
const counts = React41.useMemo(() => {
|
|
17699
18564
|
const m = /* @__PURE__ */ new Map();
|
|
17700
18565
|
for (const r of rows) {
|
|
17701
18566
|
const k = r.decision || "\u2014";
|
|
@@ -17818,20 +18683,21 @@ function S3(t) {
|
|
|
17818
18683
|
}
|
|
17819
18684
|
};
|
|
17820
18685
|
}
|
|
17821
|
-
function FormBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUpload }) {
|
|
18686
|
+
function FormBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUpload, dense, hideActions }) {
|
|
17822
18687
|
var _a;
|
|
17823
18688
|
const t = useTheme();
|
|
17824
|
-
const S4 =
|
|
18689
|
+
const S4 = React41.useMemo(() => makeStyles(t), [t]);
|
|
17825
18690
|
const block = builder.blocks[0];
|
|
17826
18691
|
if (!block) return null;
|
|
17827
18692
|
if (disabled) return /* @__PURE__ */ jsxRuntime.jsx(BuilderRecap, { builder, state });
|
|
17828
|
-
|
|
17829
|
-
|
|
18693
|
+
const containerStyle = dense ? { display: "flex", flexDirection: "column", gap: "12px" } : S4.card;
|
|
18694
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: containerStyle, children: [
|
|
18695
|
+
dense ? builder.description && /* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontSize: "12px", color: t.MUTED, lineHeight: 1.45, margin: 0 }, children: builder.description }) : /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: [
|
|
17830
18696
|
/* @__PURE__ */ jsxRuntime.jsx("p", { style: S4.title, children: builder.title }),
|
|
17831
18697
|
builder.description && /* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontSize: "12px", color: t.MUTED, lineHeight: 1.45, margin: 0 }, children: builder.description })
|
|
17832
18698
|
] }),
|
|
17833
18699
|
((_a = block.context) == null ? void 0 : _a.type) && /* @__PURE__ */ jsxRuntime.jsx(ContextSlot, { payload: block.context }),
|
|
17834
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: (block.fields || []).map((field) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
18700
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", gap: dense ? "8px" : "12px" }, children: (block.fields || []).map((field) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
17835
18701
|
FieldRenderer,
|
|
17836
18702
|
{
|
|
17837
18703
|
field,
|
|
@@ -17839,15 +18705,16 @@ function FormBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUploa
|
|
|
17839
18705
|
onChange: (v) => state.setFieldValue(block.id, field.name, v),
|
|
17840
18706
|
disabled,
|
|
17841
18707
|
error: state.getError(block.id, field.name),
|
|
18708
|
+
dense,
|
|
17842
18709
|
onFileUpload
|
|
17843
18710
|
},
|
|
17844
18711
|
`${block.id}:${field.name}`
|
|
17845
18712
|
)) }),
|
|
17846
|
-
|
|
18713
|
+
hideActions ? null : /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: "8px", paddingTop: "4px" }, children: [
|
|
17847
18714
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { flex: 1 } }),
|
|
17848
18715
|
onCancel && /* @__PURE__ */ jsxRuntime.jsx("button", { type: "button", onClick: onCancel, style: S4.cancelBtn, children: builder.cancel_label || "Cancel" }),
|
|
17849
18716
|
/* @__PURE__ */ jsxRuntime.jsx("button", { type: "button", onClick: onSubmit, style: S4.submitBtn, children: builder.submit_label || "Submit" })
|
|
17850
|
-
] })
|
|
18717
|
+
] })
|
|
17851
18718
|
] });
|
|
17852
18719
|
}
|
|
17853
18720
|
function makeStyles(t) {
|
|
@@ -17904,10 +18771,10 @@ function makeStyles(t) {
|
|
|
17904
18771
|
|
|
17905
18772
|
// src/builders/StepperBuilder.tsx
|
|
17906
18773
|
init_ThemeContext();
|
|
17907
|
-
function StepperBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUpload }) {
|
|
18774
|
+
function StepperBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUpload, dense }) {
|
|
17908
18775
|
var _a;
|
|
17909
18776
|
const t = useTheme();
|
|
17910
|
-
const S4 =
|
|
18777
|
+
const S4 = React41.useMemo(() => makeStyles2(t), [t]);
|
|
17911
18778
|
const { blocks } = builder;
|
|
17912
18779
|
const total = blocks.length;
|
|
17913
18780
|
const idx = Math.min(Math.max(state.currentBlock, 0), Math.max(total - 1, 0));
|
|
@@ -17920,14 +18787,16 @@ function StepperBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUp
|
|
|
17920
18787
|
if (state.validateBlock(idx)) state.setCurrentBlock(idx + 1);
|
|
17921
18788
|
};
|
|
17922
18789
|
const handleBack = () => state.setCurrentBlock(Math.max(idx - 1, 0));
|
|
17923
|
-
|
|
18790
|
+
const cardStyle2 = dense ? { display: "flex", flexDirection: "column", height: "100%", minHeight: 0, width: "100%", minWidth: 0, boxSizing: "border-box", overflow: "hidden" } : S4.card;
|
|
18791
|
+
const headerStyle = dense ? { flexShrink: 0, padding: "0 0 10px" } : S4.header;
|
|
18792
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: cardStyle2, children: [
|
|
17924
18793
|
/* @__PURE__ */ jsxRuntime.jsx("style", { children: "@keyframes agStepFade{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:none}}" }),
|
|
17925
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { style:
|
|
17926
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: [
|
|
18794
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: headerStyle, children: [
|
|
18795
|
+
!dense && /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: [
|
|
17927
18796
|
/* @__PURE__ */ jsxRuntime.jsx("p", { style: S4.title, children: builder.title }),
|
|
17928
18797
|
builder.description && /* @__PURE__ */ jsxRuntime.jsx("p", { style: S4.subtitle, children: builder.description })
|
|
17929
18798
|
] }),
|
|
17930
|
-
!disabled && total > 1 && /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "6px", marginTop: "10px" }, children: [
|
|
18799
|
+
!disabled && total > 1 && /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "6px", marginTop: dense ? 0 : "10px" }, children: [
|
|
17931
18800
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "baseline", justifyContent: "space-between", gap: "10px" }, children: [
|
|
17932
18801
|
/* @__PURE__ */ jsxRuntime.jsx("span", { style: S4.currentTitle, children: (block == null ? void 0 : block.title) || `Step ${idx + 1}` }),
|
|
17933
18802
|
/* @__PURE__ */ jsxRuntime.jsxs("span", { style: S4.stepCount, children: [
|
|
@@ -17940,7 +18809,7 @@ function StepperBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUp
|
|
|
17940
18809
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: S4.progressTrack, role: "progressbar", "aria-valuenow": pct, "aria-valuemin": 0, "aria-valuemax": 100, children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: __spreadProps(__spreadValues({}, S4.progressFill), { width: `${pct}%` }) }) })
|
|
17941
18810
|
] })
|
|
17942
18811
|
] }),
|
|
17943
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: S4.body, children: block && /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "12px", animation: "agStepFade 0.22s ease" }, children: [
|
|
18812
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: dense ? __spreadProps(__spreadValues({}, S4.body), { padding: "12px 0" }) : S4.body, children: block && /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "12px", animation: "agStepFade 0.22s ease" }, children: [
|
|
17944
18813
|
block.description && /* @__PURE__ */ jsxRuntime.jsx("div", { style: S4.blockDesc, children: block.description }),
|
|
17945
18814
|
((_a = block.context) == null ? void 0 : _a.type) && /* @__PURE__ */ jsxRuntime.jsx(ContextSlot, { payload: block.context }),
|
|
17946
18815
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: (block.fields || []).map((field) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -17951,12 +18820,13 @@ function StepperBuilder({ builder, state, onSubmit, onCancel, disabled, onFileUp
|
|
|
17951
18820
|
onChange: (v) => state.setFieldValue(block.id, field.name, v),
|
|
17952
18821
|
disabled,
|
|
17953
18822
|
error: state.getError(block.id, field.name),
|
|
18823
|
+
dense,
|
|
17954
18824
|
onFileUpload
|
|
17955
18825
|
},
|
|
17956
18826
|
`${block.id}:${field.name}`
|
|
17957
18827
|
)) })
|
|
17958
18828
|
] }, idx) }),
|
|
17959
|
-
!disabled ? /* @__PURE__ */ jsxRuntime.jsxs("div", { style: S4.footer, children: [
|
|
18829
|
+
!disabled ? /* @__PURE__ */ jsxRuntime.jsxs("div", { style: dense ? __spreadProps(__spreadValues({}, S4.footer), { borderTop: "none", background: "transparent", padding: "10px 0 0" }) : S4.footer, children: [
|
|
17960
18830
|
!isFirst && /* @__PURE__ */ jsxRuntime.jsx("button", { type: "button", onClick: handleBack, style: S4.cancelBtn, children: "Back" }),
|
|
17961
18831
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { flex: 1 } }),
|
|
17962
18832
|
onCancel && /* @__PURE__ */ jsxRuntime.jsx("button", { type: "button", onClick: onCancel, style: S4.cancelBtn, children: builder.cancel_label || "Cancel" }),
|
|
@@ -18080,21 +18950,22 @@ function makeStyles2(t) {
|
|
|
18080
18950
|
|
|
18081
18951
|
// src/builders/EscalationCard.tsx
|
|
18082
18952
|
init_ThemeContext();
|
|
18083
|
-
function EscalationCard({ builder, state, onSubmit, disabled, onFileUpload }) {
|
|
18953
|
+
function EscalationCard({ builder, state, onSubmit, disabled, onFileUpload, hideActions, dense }) {
|
|
18084
18954
|
var _a;
|
|
18085
18955
|
const t = useTheme();
|
|
18086
|
-
const S4 =
|
|
18956
|
+
const S4 = React41.useMemo(() => makeStyles3(t), [t]);
|
|
18087
18957
|
const block = builder.blocks[0];
|
|
18088
18958
|
if (!block) return null;
|
|
18089
18959
|
if (disabled) return /* @__PURE__ */ jsxRuntime.jsx(BuilderRecap, { builder, state });
|
|
18090
|
-
|
|
18091
|
-
|
|
18960
|
+
const containerStyle = dense ? { display: "flex", flexDirection: "column", gap: "10px" } : S4.card;
|
|
18961
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { style: containerStyle, children: [
|
|
18962
|
+
builder.description && /* @__PURE__ */ jsxRuntime.jsx("p", { style: { fontSize: dense ? "12px" : "13px", color: dense ? t.MUTED : "var(--foreground)", lineHeight: 1.45, margin: 0 }, children: builder.description }),
|
|
18092
18963
|
((_a = block.context) == null ? void 0 : _a.type) && /* @__PURE__ */ jsxRuntime.jsx(ContextSlot, { payload: block.context }),
|
|
18093
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", gap: "10px" }, children: (block.fields || []).map((field) => /* @__PURE__ */ jsxRuntime.jsx(FieldRenderer, { field, value: state.getValue(block.id, field.name), onChange: (v) => state.setFieldValue(block.id, field.name, v), disabled, error: state.getError(block.id, field.name), onFileUpload }, `${block.id}:${field.name}`)) }),
|
|
18094
|
-
|
|
18964
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", gap: dense ? "8px" : "10px" }, children: (block.fields || []).map((field) => /* @__PURE__ */ jsxRuntime.jsx(FieldRenderer, { field, value: state.getValue(block.id, field.name), onChange: (v) => state.setFieldValue(block.id, field.name, v), disabled, error: state.getError(block.id, field.name), onFileUpload, dense }, `${block.id}:${field.name}`)) }),
|
|
18965
|
+
disabled ? /* @__PURE__ */ jsxRuntime.jsx("div", { style: { fontSize: "11px", fontWeight: 600, color: t.MUTED, textAlign: "center", padding: "2px 0" }, children: "Submitted" }) : hideActions ? null : /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: "8px", paddingTop: "2px" }, children: [
|
|
18095
18966
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { flex: 1 } }),
|
|
18096
18967
|
/* @__PURE__ */ jsxRuntime.jsx("button", { type: "button", onClick: onSubmit, style: S4.continueBtn, children: builder.submit_label || "Continue" })
|
|
18097
|
-
] })
|
|
18968
|
+
] })
|
|
18098
18969
|
] });
|
|
18099
18970
|
}
|
|
18100
18971
|
function makeStyles3(t) {
|
|
@@ -18134,7 +19005,7 @@ function fieldKey(blockId, name) {
|
|
|
18134
19005
|
}
|
|
18135
19006
|
function useBuilderState(blocks) {
|
|
18136
19007
|
const isMultiBlock = blocks.length > 1;
|
|
18137
|
-
const [values, setValues] =
|
|
19008
|
+
const [values, setValues] = React41.useState(() => {
|
|
18138
19009
|
const init = {};
|
|
18139
19010
|
for (const block of blocks) {
|
|
18140
19011
|
for (const field of block.fields || []) {
|
|
@@ -18143,17 +19014,17 @@ function useBuilderState(blocks) {
|
|
|
18143
19014
|
}
|
|
18144
19015
|
return init;
|
|
18145
19016
|
});
|
|
18146
|
-
const [errors, setErrors] =
|
|
18147
|
-
const [currentBlock, setCurrentBlock] =
|
|
18148
|
-
const getValue =
|
|
19017
|
+
const [errors, setErrors] = React41.useState({});
|
|
19018
|
+
const [currentBlock, setCurrentBlock] = React41.useState(0);
|
|
19019
|
+
const getValue = React41.useCallback(
|
|
18149
19020
|
(blockId, name) => values[fieldKey(blockId, name)],
|
|
18150
19021
|
[values]
|
|
18151
19022
|
);
|
|
18152
|
-
const getError =
|
|
19023
|
+
const getError = React41.useCallback(
|
|
18153
19024
|
(blockId, name) => errors[fieldKey(blockId, name)],
|
|
18154
19025
|
[errors]
|
|
18155
19026
|
);
|
|
18156
|
-
const setFieldValue =
|
|
19027
|
+
const setFieldValue = React41.useCallback((blockId, name, value) => {
|
|
18157
19028
|
const k = fieldKey(blockId, name);
|
|
18158
19029
|
setValues((prev) => __spreadProps(__spreadValues({}, prev), { [k]: value }));
|
|
18159
19030
|
setErrors((prev) => {
|
|
@@ -18163,7 +19034,7 @@ function useBuilderState(blocks) {
|
|
|
18163
19034
|
return next;
|
|
18164
19035
|
});
|
|
18165
19036
|
}, []);
|
|
18166
|
-
const validateBlock =
|
|
19037
|
+
const validateBlock = React41.useCallback(
|
|
18167
19038
|
(blockIdx) => {
|
|
18168
19039
|
const block = blocks[blockIdx];
|
|
18169
19040
|
if (!block) return true;
|
|
@@ -18197,7 +19068,7 @@ function useBuilderState(blocks) {
|
|
|
18197
19068
|
},
|
|
18198
19069
|
[blocks, values]
|
|
18199
19070
|
);
|
|
18200
|
-
const validateAll =
|
|
19071
|
+
const validateAll = React41.useCallback(() => {
|
|
18201
19072
|
let firstFailing = -1;
|
|
18202
19073
|
const allErrors = {};
|
|
18203
19074
|
for (let i = 0; i < blocks.length; i++) {
|
|
@@ -18228,24 +19099,47 @@ function useBuilderState(blocks) {
|
|
|
18228
19099
|
isMultiBlock
|
|
18229
19100
|
};
|
|
18230
19101
|
}
|
|
18231
|
-
function BuilderFormResolver({
|
|
19102
|
+
function BuilderFormResolver({
|
|
19103
|
+
builder,
|
|
19104
|
+
onSubmit,
|
|
19105
|
+
onCancel,
|
|
19106
|
+
disabled,
|
|
19107
|
+
onFileUpload,
|
|
19108
|
+
onChange,
|
|
19109
|
+
submitRef,
|
|
19110
|
+
hideActions,
|
|
19111
|
+
dense
|
|
19112
|
+
}) {
|
|
18232
19113
|
const state = useBuilderState(builder.blocks);
|
|
18233
19114
|
const kind = builder.builder_kind || "form";
|
|
18234
|
-
const
|
|
18235
|
-
if (disabled) return;
|
|
18236
|
-
if (!state.validateAll()) return;
|
|
19115
|
+
const buildSubmission = React41.useCallback(() => {
|
|
18237
19116
|
const blocks = (builder.blocks || []).map((b) => ({
|
|
18238
19117
|
id: b.id,
|
|
18239
19118
|
title: b.title,
|
|
18240
19119
|
values: Object.fromEntries((b.fields || []).map((f) => [f.name, state.getValue(b.id, f.name)]))
|
|
18241
19120
|
}));
|
|
18242
|
-
|
|
19121
|
+
return __spreadValues({
|
|
18243
19122
|
builder_id: builder.builder_id,
|
|
18244
19123
|
builder_kind: kind,
|
|
18245
19124
|
blocks
|
|
18246
19125
|
}, blocks.length === 1 ? { values: blocks[0].values } : {});
|
|
18247
|
-
|
|
18248
|
-
|
|
19126
|
+
}, [builder, kind, state.getValue]);
|
|
19127
|
+
const handleSubmit = React41.useCallback(() => {
|
|
19128
|
+
if (disabled) return;
|
|
19129
|
+
if (!state.validateAll()) return;
|
|
19130
|
+
onSubmit(buildSubmission());
|
|
19131
|
+
}, [disabled, state.validateAll, onSubmit, buildSubmission]);
|
|
19132
|
+
React41.useEffect(() => {
|
|
19133
|
+
if (!onChange) return;
|
|
19134
|
+
onChange(buildSubmission());
|
|
19135
|
+
}, [onChange, state.values]);
|
|
19136
|
+
React41.useEffect(() => {
|
|
19137
|
+
if (!submitRef) return;
|
|
19138
|
+
submitRef.current = handleSubmit;
|
|
19139
|
+
return () => {
|
|
19140
|
+
submitRef.current = null;
|
|
19141
|
+
};
|
|
19142
|
+
}, [submitRef, handleSubmit]);
|
|
18249
19143
|
switch (kind) {
|
|
18250
19144
|
case "stepper":
|
|
18251
19145
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -18256,7 +19150,8 @@ function BuilderFormResolver({ builder, onSubmit, onCancel, disabled, onFileUplo
|
|
|
18256
19150
|
onSubmit: handleSubmit,
|
|
18257
19151
|
onCancel,
|
|
18258
19152
|
disabled,
|
|
18259
|
-
onFileUpload
|
|
19153
|
+
onFileUpload,
|
|
19154
|
+
dense
|
|
18260
19155
|
}
|
|
18261
19156
|
);
|
|
18262
19157
|
case "escalation":
|
|
@@ -18267,7 +19162,9 @@ function BuilderFormResolver({ builder, onSubmit, onCancel, disabled, onFileUplo
|
|
|
18267
19162
|
state,
|
|
18268
19163
|
onSubmit: handleSubmit,
|
|
18269
19164
|
disabled,
|
|
18270
|
-
onFileUpload
|
|
19165
|
+
onFileUpload,
|
|
19166
|
+
hideActions,
|
|
19167
|
+
dense
|
|
18271
19168
|
}
|
|
18272
19169
|
);
|
|
18273
19170
|
default:
|
|
@@ -18279,13 +19176,15 @@ function BuilderFormResolver({ builder, onSubmit, onCancel, disabled, onFileUplo
|
|
|
18279
19176
|
onSubmit: handleSubmit,
|
|
18280
19177
|
onCancel,
|
|
18281
19178
|
disabled,
|
|
18282
|
-
onFileUpload
|
|
19179
|
+
onFileUpload,
|
|
19180
|
+
dense,
|
|
19181
|
+
hideActions
|
|
18283
19182
|
}
|
|
18284
19183
|
);
|
|
18285
19184
|
}
|
|
18286
19185
|
}
|
|
18287
19186
|
function resolveBuilder(payload, callbacks) {
|
|
18288
|
-
return
|
|
19187
|
+
return React41__default.default.createElement(BuilderFormResolver, __spreadValues({
|
|
18289
19188
|
builder: payload
|
|
18290
19189
|
}, callbacks));
|
|
18291
19190
|
}
|
|
@@ -18305,14 +19204,17 @@ exports.ComparativeBarChartResolver = ComparativeBarChartResolver;
|
|
|
18305
19204
|
exports.ComplianceChecklistResolver = ComplianceChecklistResolver;
|
|
18306
19205
|
exports.ComponentActions = ComponentActions;
|
|
18307
19206
|
exports.ContextSlot = ContextSlot;
|
|
19207
|
+
exports.DEFAULT_INTERACTION = DEFAULT_INTERACTION;
|
|
18308
19208
|
exports.DataTableResolver = DataTableResolver;
|
|
18309
19209
|
exports.DocumentPreviewResolver = DocumentPreviewResolver;
|
|
18310
19210
|
exports.EngagementPipelineResolver = EngagementPipelineResolver;
|
|
18311
19211
|
exports.FIELD_REGISTRY = FIELD_REGISTRY;
|
|
18312
19212
|
exports.FieldRenderer = FieldRenderer;
|
|
18313
19213
|
exports.FileCard = FileCard;
|
|
19214
|
+
exports.FitText = FitText;
|
|
18314
19215
|
exports.FlowCanvasRenderer = FlowCanvasRenderer;
|
|
18315
19216
|
exports.FlowCanvasResolver = FlowCanvasResolver;
|
|
19217
|
+
exports.GenUIInteractionProvider = GenUIInteractionProvider;
|
|
18316
19218
|
exports.GenUIRenderer = GenUIRenderer;
|
|
18317
19219
|
exports.GenUIThemeProvider = GenUIThemeProvider;
|
|
18318
19220
|
exports.GroupedTableResolver = GroupedTableResolver;
|
|
@@ -18320,6 +19222,7 @@ exports.HeatmapTableResolver = HeatmapTableResolver;
|
|
|
18320
19222
|
exports.JournalEntryResolver = JournalEntryResolver;
|
|
18321
19223
|
exports.LegalTestResultResolver = LegalTestResultResolver;
|
|
18322
19224
|
exports.Markdown = Markdown;
|
|
19225
|
+
exports.NUMERIC_CELL = NUMERIC_CELL;
|
|
18323
19226
|
exports.NewsFeedResolver = NewsFeedResolver;
|
|
18324
19227
|
exports.PreviewHost = PreviewHost;
|
|
18325
19228
|
exports.PreviewModal = PreviewModal;
|
|
@@ -18331,10 +19234,13 @@ exports.SparklineTableResolver = SparklineTableResolver;
|
|
|
18331
19234
|
exports.StackedBreakdownResolver = StackedBreakdownResolver;
|
|
18332
19235
|
exports.StatGridResolver = StatGridResolver;
|
|
18333
19236
|
exports.StatusCardResolver = StatusCardResolver;
|
|
19237
|
+
exports.TRUNCATE = TRUNCATE;
|
|
18334
19238
|
exports.TabsPanelResolver = TabsPanelResolver;
|
|
18335
19239
|
exports.TrialBalanceResolver = TrialBalanceResolver;
|
|
18336
19240
|
exports.VarianceAnalysisResolver = VarianceAnalysisResolver;
|
|
18337
19241
|
exports.WaterfallChartResolver = WaterfallChartResolver;
|
|
19242
|
+
exports.WorkflowStepperRenderer = WorkflowStepperRenderer;
|
|
19243
|
+
exports.WorkflowStepperResolver = WorkflowStepperResolver;
|
|
18338
19244
|
exports.buildRenderUITool = buildRenderUITool;
|
|
18339
19245
|
exports.builderBlockSchema = builderBlockSchema;
|
|
18340
19246
|
exports.builderFieldSchema = builderFieldSchema;
|
|
@@ -18350,6 +19256,7 @@ exports.resolveBuilder = resolveBuilder;
|
|
|
18350
19256
|
exports.resolveUI = resolveUI;
|
|
18351
19257
|
exports.schemaRegistry = schemaRegistry;
|
|
18352
19258
|
exports.useBuilderState = useBuilderState;
|
|
19259
|
+
exports.useGenUIInteraction = useGenUIInteraction;
|
|
18353
19260
|
exports.useTheme = useTheme;
|
|
18354
19261
|
exports.validateBuilderPayload = validateBuilderPayload;
|
|
18355
19262
|
exports.validatePayload = validatePayload;
|