@burdenoff/microfe-bigconsole 2026.1031.3 → 2026.1102.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bigconsole/assistant/generationContext.d.ts +20 -0
- package/dist/bigconsole/assistant/generationContext.js +10 -0
- package/dist/bigconsole/assistant/pageContext.d.ts +22 -2
- package/dist/bigconsole/assistant/pageContext.js +55 -20
- package/dist/bigconsole/components/pipeline/PipelineRunHistory.d.ts +15 -0
- package/dist/bigconsole/components/pipeline/PipelineRunHistory.js +270 -0
- package/dist/bigconsole/hooks/usePipelineOperations.d.ts +2 -1
- package/dist/bigconsole/pages/InsightsPage.js +347 -346
- package/dist/bigconsole/pages/PipelineBuilderPage.js +307 -306
- package/dist/bigconsole/pages/PipelineViewPage.js +201 -310
- package/dist/bigconsole/utils/pipelineExecutionTimeline.d.ts +47 -0
- package/dist/bigconsole/utils/pipelineExecutionTimeline.js +87 -0
- package/dist/bigconsole/utils/pipelineStages.d.ts +41 -0
- package/dist/bigconsole/utils/pipelineStages.js +49 -0
- package/package.json +1 -1
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Active prompt-generation context (BOFF-3718).
|
|
3
|
+
*
|
|
4
|
+
* A `PromptGeneration` is not addressable from the route: the Insights page
|
|
5
|
+
* keeps the generation the user is previewing or refining in component state.
|
|
6
|
+
* So the assistant could not resolve "this generation" — the page tells this
|
|
7
|
+
* module which generation is currently in focus, and `gatherPageContext()`
|
|
8
|
+
* reads it back when the user is on the Insights route.
|
|
9
|
+
*
|
|
10
|
+
* Deliberately a module-level holder, not a zustand store: it has exactly one
|
|
11
|
+
* writer (the Insights page's preview/refine effects) and one reader
|
|
12
|
+
* (`pageContext.ts`), no subscription is ever needed, and a store would tempt
|
|
13
|
+
* components to render from it. Setting `null` clears the context; the writer
|
|
14
|
+
* owns clearing on unmount so a stale generation is never reported from
|
|
15
|
+
* another page.
|
|
16
|
+
*/
|
|
17
|
+
/** Called by the Insights page when the previewed/refined generation changes. */
|
|
18
|
+
export declare function setActiveGenerationContext(generationId: string | null): void;
|
|
19
|
+
/** The generation currently in focus, or null. Read by `gatherPageContext()`. */
|
|
20
|
+
export declare function getActiveGenerationContext(): string | null;
|
|
@@ -35,10 +35,30 @@ export type PageContext = {
|
|
|
35
35
|
platform: string;
|
|
36
36
|
version: string;
|
|
37
37
|
viewportSize: string;
|
|
38
|
-
userAgent: string;
|
|
39
|
-
timestamp: string;
|
|
40
38
|
};
|
|
41
39
|
export declare function gatherPageContext(): PageContext;
|
|
40
|
+
/**
|
|
41
|
+
* Entity context that the route cannot express (BOFF-3718): in the builder, the
|
|
42
|
+
* selected Widget and the current DashboardPage are component state, and on
|
|
43
|
+
* Insights the generation being previewed/refined is page state. Without this,
|
|
44
|
+
* "why is this chart empty?" / "delete this widget" / "retry this generation"
|
|
45
|
+
* cost a follow-up question asking for an id the user should never have to
|
|
46
|
+
* know.
|
|
47
|
+
*
|
|
48
|
+
* Precedence is narrow on purpose — the route table stays authoritative
|
|
49
|
+
* everywhere else, so `/dashboards/:id` still resolves `BIGCONSOLE_DASHBOARD`
|
|
50
|
+
* exactly as before:
|
|
51
|
+
*
|
|
52
|
+
* - a selected widget on a dashboard view/builder route → `BIGCONSOLE_WIDGET`
|
|
53
|
+
* - the active page on a **builder** route → `BIGCONSOLE_PAGE` (the view route
|
|
54
|
+
* keeps reporting the dashboard: pages there are tabs, not the focus)
|
|
55
|
+
* - a previewed/refined generation on the Insights route → `BIGCONSOLE_GENERATION`
|
|
56
|
+
*
|
|
57
|
+
* Returns null when no selection state applies, and never throws: a store that
|
|
58
|
+
* has not been hydrated (or a test environment without one) must degrade to
|
|
59
|
+
* the route resolution, not break the prompt.
|
|
60
|
+
*/
|
|
61
|
+
export declare function resolveSelectionEntityContext(pathname: string): ConversationContextShape | null;
|
|
42
62
|
/**
|
|
43
63
|
* Route segment → human label.
|
|
44
64
|
*
|
|
@@ -1,21 +1,56 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { useWidgetStore as e } from "../store/widgetStore.js";
|
|
2
|
+
import { useDashboardStore as t } from "../store/dashboardStore.js";
|
|
3
|
+
import { BIGCONSOLE_PRODUCT as n } from "./product.js";
|
|
4
|
+
import { getActiveGenerationContext as r } from "./generationContext.js";
|
|
2
5
|
//#region src/bigconsole/assistant/pageContext.ts
|
|
3
|
-
function
|
|
4
|
-
let
|
|
6
|
+
function i() {
|
|
7
|
+
let e = window.location.href, t = window.location.pathname.split("/").filter(Boolean).slice(0, 3).join("/") || "home", r = a(window.location.pathname) ?? u(window.location.pathname, window.location.search);
|
|
5
8
|
return {
|
|
6
|
-
currentUrl:
|
|
7
|
-
currentPage:
|
|
9
|
+
currentUrl: e,
|
|
10
|
+
currentPage: t,
|
|
8
11
|
entityType: r.entityType,
|
|
9
12
|
entityId: r.entityId,
|
|
10
|
-
platform:
|
|
13
|
+
platform: n,
|
|
11
14
|
version: "2026.430.500",
|
|
12
|
-
viewportSize: `${window.innerWidth}x${window.innerHeight}
|
|
13
|
-
userAgent: navigator.userAgent,
|
|
14
|
-
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
15
|
+
viewportSize: `${window.innerWidth}x${window.innerHeight}`
|
|
15
16
|
};
|
|
16
17
|
}
|
|
17
|
-
|
|
18
|
-
|
|
18
|
+
function a(n) {
|
|
19
|
+
try {
|
|
20
|
+
let i = n.match(/^\/bigconsole\/dashboards\/([^/]+)(\/builder)?$/);
|
|
21
|
+
if (i && !d(i[1])) {
|
|
22
|
+
let n = i[1], r = i[2] === "/builder", a = e.getState().selectedWidgetId;
|
|
23
|
+
if (a) return {
|
|
24
|
+
entityType: "BIGCONSOLE_WIDGET",
|
|
25
|
+
entityId: a,
|
|
26
|
+
metadata: {
|
|
27
|
+
dashboardId: n,
|
|
28
|
+
source: "builder-selection"
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
let o = t.getState().activePageId;
|
|
32
|
+
return r && o ? {
|
|
33
|
+
entityType: "BIGCONSOLE_PAGE",
|
|
34
|
+
entityId: o,
|
|
35
|
+
metadata: {
|
|
36
|
+
dashboardId: n,
|
|
37
|
+
source: "builder-selection"
|
|
38
|
+
}
|
|
39
|
+
} : null;
|
|
40
|
+
}
|
|
41
|
+
if (/^\/bigconsole\/insights(?:\/|$)/.test(n)) {
|
|
42
|
+
let e = r();
|
|
43
|
+
if (e) return {
|
|
44
|
+
entityType: "BIGCONSOLE_GENERATION",
|
|
45
|
+
entityId: e,
|
|
46
|
+
metadata: { source: "insights-preview" }
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
} catch {}
|
|
50
|
+
return null;
|
|
51
|
+
}
|
|
52
|
+
var o = "Home", s = {
|
|
53
|
+
home: o,
|
|
19
54
|
dashboards: "Dashboards",
|
|
20
55
|
datasinks: "Data sinks",
|
|
21
56
|
datasources: "Data sources",
|
|
@@ -27,14 +62,14 @@ var n = "Home", r = {
|
|
|
27
62
|
workflows: "Workflows",
|
|
28
63
|
workflow: "Workflows"
|
|
29
64
|
};
|
|
30
|
-
function
|
|
31
|
-
let { currentPage: e } =
|
|
32
|
-
return !
|
|
65
|
+
function c() {
|
|
66
|
+
let { currentPage: e } = i(), t = e.split("/").filter(Boolean), n = (t[0] === "bigconsole" ? t[1] : t[0]) ?? "";
|
|
67
|
+
return !n || n === "home" ? o : s[n] ?? n.split("-").map((e) => e && e.charAt(0).toUpperCase() + e.slice(1)).join(" ");
|
|
33
68
|
}
|
|
34
|
-
function
|
|
69
|
+
function l(e, t) {
|
|
35
70
|
return t.match(e);
|
|
36
71
|
}
|
|
37
|
-
function
|
|
72
|
+
function u(e, t) {
|
|
38
73
|
let n = new URLSearchParams(t);
|
|
39
74
|
for (let [t, n] of [
|
|
40
75
|
[/^\/bigconsole\/dashboards\/[^/]+\/parsers\/([^/]+)(?:\/edit)?$/, "BIGCONSOLE_PARSER"],
|
|
@@ -44,8 +79,8 @@ function o(e, t) {
|
|
|
44
79
|
[/^\/bigconsole\/pipelines\/([^/]+)(?:\/edit)?$/, "BIGCONSOLE_PIPELINE"],
|
|
45
80
|
[/^\/bigconsole\/workflows\/([^/]+)(?:\/edit)?$/, "BIGCONSOLE_WORKFLOW"]
|
|
46
81
|
]) {
|
|
47
|
-
let r =
|
|
48
|
-
if (r && r[1] && !
|
|
82
|
+
let r = l(t, e);
|
|
83
|
+
if (r && r[1] && !d(r[1])) return {
|
|
49
84
|
entityType: n,
|
|
50
85
|
entityId: r[1],
|
|
51
86
|
metadata: { routePattern: t.source }
|
|
@@ -60,8 +95,8 @@ function o(e, t) {
|
|
|
60
95
|
metadata: { ...r ? { activeTab: r } : {} }
|
|
61
96
|
};
|
|
62
97
|
}
|
|
63
|
-
function
|
|
98
|
+
function d(e) {
|
|
64
99
|
return e === "new" || e === "builder" || e === "list";
|
|
65
100
|
}
|
|
66
101
|
//#endregion
|
|
67
|
-
export {
|
|
102
|
+
export { s as BIGCONSOLE_PAGE_LABELS, c as describeCurrentPage, i as gatherPageContext, u as resolveBigConsoleConversationContext, a as resolveSelectionEntityContext };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { PipelineExecution, PipelineStage } from '../../types';
|
|
2
|
+
export interface PipelineRunHistoryListProps {
|
|
3
|
+
/** Runs of this pipeline, newest first. */
|
|
4
|
+
executions: readonly PipelineExecution[];
|
|
5
|
+
selectedId: string | null;
|
|
6
|
+
onSelect: (execution: PipelineExecution) => void;
|
|
7
|
+
currentActorId: string | null | undefined;
|
|
8
|
+
}
|
|
9
|
+
export declare const PipelineRunHistoryList: import('react').NamedExoticComponent<PipelineRunHistoryListProps>;
|
|
10
|
+
export interface PipelineStageTimelineProps {
|
|
11
|
+
execution: PipelineExecution;
|
|
12
|
+
stages: readonly PipelineStage[] | null | undefined;
|
|
13
|
+
currentActorId: string | null | undefined;
|
|
14
|
+
}
|
|
15
|
+
export declare const PipelineStageTimeline: import('react').NamedExoticComponent<PipelineStageTimelineProps>;
|
|
@@ -0,0 +1,270 @@
|
|
|
1
|
+
import { SECTION_FOCUS_RING as e } from "../common/sectionStyles.js";
|
|
2
|
+
import { Section as t } from "../common/Section.js";
|
|
3
|
+
import "../common/index.js";
|
|
4
|
+
import { buildStageTimeline as n, formatDurationMs as r, runDurationMs as i, runStatusTone as a, triggeredByLabel as o } from "../../utils/pipelineExecutionTimeline.js";
|
|
5
|
+
import { memo as s, useMemo as c } from "react";
|
|
6
|
+
import { useI18n as l } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
|
|
7
|
+
import { jsx as u, jsxs as d } from "react/jsx-runtime";
|
|
8
|
+
//#region src/bigconsole/components/pipeline/PipelineRunHistory.tsx
|
|
9
|
+
var f = {
|
|
10
|
+
success: "bg-[var(--color-status-success-bgSubtle)] text-[var(--color-status-success-text)] border-[var(--color-status-success-border)]",
|
|
11
|
+
danger: "bg-[var(--color-status-error-bgSubtle)] text-[var(--color-status-error-text)] border-[var(--color-status-error-border)]",
|
|
12
|
+
warning: "bg-[var(--color-status-warning-bgSubtle)] text-[var(--color-status-warning-text)] border-[var(--color-status-warning-border)]",
|
|
13
|
+
info: "bg-[var(--color-status-info-bgSubtle)] text-[var(--color-status-info-text)] border-[var(--color-status-info-border)]",
|
|
14
|
+
neutral: "bg-bg-surface text-text-secondary border-[var(--color-border-subtle)]"
|
|
15
|
+
}, p = {
|
|
16
|
+
success: "bg-[var(--color-status-success-text)]",
|
|
17
|
+
danger: "bg-[var(--color-status-error-text)]",
|
|
18
|
+
warning: "bg-[var(--color-status-warning-text)]",
|
|
19
|
+
info: "bg-[var(--color-status-info-text)]",
|
|
20
|
+
neutral: "bg-[var(--color-border-strong)]"
|
|
21
|
+
}, m = "rounded-button bg-bg-surface px-1.5 py-0.5 font-mono break-all text-text-primary";
|
|
22
|
+
function h({ tone: e, label: t }) {
|
|
23
|
+
return /* @__PURE__ */ u("span", {
|
|
24
|
+
className: `inline-flex items-center whitespace-nowrap rounded-pill border px-2 py-0.5 text-xs font-medium ${f[e]}`,
|
|
25
|
+
children: t
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
function g() {
|
|
29
|
+
let { t: e } = l();
|
|
30
|
+
return (t) => {
|
|
31
|
+
switch (t) {
|
|
32
|
+
case "completed": return e("bigconsole.pipelines.execution.status.completed", "Completed");
|
|
33
|
+
case "failed": return e("bigconsole.pipelines.execution.status.failed", "Failed");
|
|
34
|
+
case "running": return e("bigconsole.pipelines.execution.status.running", "Running");
|
|
35
|
+
case "pending": return e("bigconsole.pipelines.execution.status.pending", "Pending");
|
|
36
|
+
case "success": return e("bigconsole.pipelines.execution.status.success", "Success");
|
|
37
|
+
case "skipped": return e("bigconsole.pipelines.execution.status.skipped", "Skipped");
|
|
38
|
+
default: return t;
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
function _(e) {
|
|
43
|
+
if (!e) return "—";
|
|
44
|
+
let t = new Date(e);
|
|
45
|
+
return Number.isNaN(t.getTime()) ? "—" : t.toLocaleString();
|
|
46
|
+
}
|
|
47
|
+
var v = s(function({ executions: n, selectedId: s, onSelect: c, currentActorId: f }) {
|
|
48
|
+
let { t: p } = l(), m = g();
|
|
49
|
+
return /* @__PURE__ */ u(t, {
|
|
50
|
+
headingLevel: 2,
|
|
51
|
+
title: p("bigconsole.pipelines.execution.historyHeading", "Previous runs"),
|
|
52
|
+
meta: n.length > 0 ? /* @__PURE__ */ u("span", {
|
|
53
|
+
className: "rounded-pill bg-bg-sunken px-2 py-0.5 text-xs font-medium text-text-secondary",
|
|
54
|
+
children: n.length
|
|
55
|
+
}) : null,
|
|
56
|
+
"data-testid": "pipeline-execution-history",
|
|
57
|
+
children: n.length === 0 ? /* @__PURE__ */ u("p", {
|
|
58
|
+
className: "text-sm text-text-secondary",
|
|
59
|
+
children: p("bigconsole.pipelines.execution.noHistory", "No execution history yet. Test this pipeline with sample input to inspect its stages.")
|
|
60
|
+
}) : /* @__PURE__ */ u("ol", {
|
|
61
|
+
className: "flex flex-col gap-control-gap",
|
|
62
|
+
"aria-label": p("bigconsole.pipelines.execution.runList", "Runs"),
|
|
63
|
+
children: n.map((t) => {
|
|
64
|
+
let n = t.id === s, l = o(t.executedBy, f);
|
|
65
|
+
return /* @__PURE__ */ u("li", { children: /* @__PURE__ */ d("button", {
|
|
66
|
+
type: "button",
|
|
67
|
+
"aria-pressed": n,
|
|
68
|
+
onClick: () => c(t),
|
|
69
|
+
"data-testid": "pipeline-execution-run",
|
|
70
|
+
"data-status": t.status,
|
|
71
|
+
className: `flex w-full min-w-0 flex-col gap-1 rounded-button border p-3 text-left ${e} ${n ? "border-[var(--color-border-strong)] bg-bg-sunken" : "border-[var(--color-border-subtle)] bg-bg-surface"}`,
|
|
72
|
+
children: [
|
|
73
|
+
/* @__PURE__ */ d("span", {
|
|
74
|
+
className: "flex flex-wrap items-center justify-between gap-2 text-sm font-medium text-text-primary",
|
|
75
|
+
children: [/* @__PURE__ */ u(h, {
|
|
76
|
+
tone: a(t.status),
|
|
77
|
+
label: m(t.status)
|
|
78
|
+
}), /* @__PURE__ */ u("span", { children: r(i(t)) })]
|
|
79
|
+
}),
|
|
80
|
+
/* @__PURE__ */ u("span", {
|
|
81
|
+
className: "break-words text-xs text-text-secondary",
|
|
82
|
+
children: _(t.startedAt ?? t.createdAt)
|
|
83
|
+
}),
|
|
84
|
+
/* @__PURE__ */ d("span", {
|
|
85
|
+
className: "flex flex-wrap justify-between gap-2 text-xs text-text-muted",
|
|
86
|
+
children: [/* @__PURE__ */ d("span", { children: [
|
|
87
|
+
p("bigconsole.pipelines.execution.triggeredBy", "By"),
|
|
88
|
+
" ",
|
|
89
|
+
/* @__PURE__ */ u("span", {
|
|
90
|
+
className: "font-mono",
|
|
91
|
+
title: t.executedBy,
|
|
92
|
+
children: l ?? p("bigconsole.pipelines.execution.triggeredByYou", "you")
|
|
93
|
+
})
|
|
94
|
+
] }), /* @__PURE__ */ u("span", { children: p("bigconsole.pipelines.execution.versionShort", "v{{version}}", { version: t.pipelineVersion }) })]
|
|
95
|
+
})
|
|
96
|
+
]
|
|
97
|
+
}) }, t.id);
|
|
98
|
+
})
|
|
99
|
+
})
|
|
100
|
+
});
|
|
101
|
+
}), y = s(function({ execution: e, stages: s, currentActorId: f }) {
|
|
102
|
+
let { t: v } = l(), y = g(), b = c(() => n(e, s), [e, s]), x = o(e.executedBy, f);
|
|
103
|
+
return /* @__PURE__ */ u(t, {
|
|
104
|
+
emphasis: "primary",
|
|
105
|
+
headingLevel: 2,
|
|
106
|
+
title: v("bigconsole.pipelines.execution.timelineHeading", "Stage timeline"),
|
|
107
|
+
meta: /* @__PURE__ */ u(h, {
|
|
108
|
+
tone: a(e.status),
|
|
109
|
+
label: y(e.status)
|
|
110
|
+
}),
|
|
111
|
+
"data-testid": "pipeline-stage-timeline",
|
|
112
|
+
children: /* @__PURE__ */ d("div", {
|
|
113
|
+
className: "flex flex-col gap-form-gap",
|
|
114
|
+
children: [
|
|
115
|
+
/* @__PURE__ */ d("dl", {
|
|
116
|
+
className: "grid grid-cols-2 gap-form-gap sm:grid-cols-4",
|
|
117
|
+
children: [
|
|
118
|
+
/* @__PURE__ */ d("div", {
|
|
119
|
+
className: "min-w-0",
|
|
120
|
+
children: [/* @__PURE__ */ u("dt", {
|
|
121
|
+
className: "text-xs text-text-muted",
|
|
122
|
+
children: v("bigconsole.pipelines.execution.totalDuration", "Total duration")
|
|
123
|
+
}), /* @__PURE__ */ u("dd", {
|
|
124
|
+
className: "text-text-primary",
|
|
125
|
+
"data-testid": "pipeline-run-duration",
|
|
126
|
+
children: r(i(e))
|
|
127
|
+
})]
|
|
128
|
+
}),
|
|
129
|
+
/* @__PURE__ */ d("div", {
|
|
130
|
+
className: "min-w-0",
|
|
131
|
+
children: [/* @__PURE__ */ u("dt", {
|
|
132
|
+
className: "text-xs text-text-muted",
|
|
133
|
+
children: v("bigconsole.pipelines.execution.started", "Started")
|
|
134
|
+
}), /* @__PURE__ */ u("dd", {
|
|
135
|
+
className: "break-words text-text-primary",
|
|
136
|
+
children: _(e.startedAt)
|
|
137
|
+
})]
|
|
138
|
+
}),
|
|
139
|
+
/* @__PURE__ */ d("div", {
|
|
140
|
+
className: "min-w-0",
|
|
141
|
+
children: [/* @__PURE__ */ u("dt", {
|
|
142
|
+
className: "text-xs text-text-muted",
|
|
143
|
+
children: v("bigconsole.pipelines.execution.finished", "Finished")
|
|
144
|
+
}), /* @__PURE__ */ u("dd", {
|
|
145
|
+
className: "break-words text-text-primary",
|
|
146
|
+
children: _(e.completedAt)
|
|
147
|
+
})]
|
|
148
|
+
}),
|
|
149
|
+
/* @__PURE__ */ d("div", {
|
|
150
|
+
className: "min-w-0",
|
|
151
|
+
children: [/* @__PURE__ */ u("dt", {
|
|
152
|
+
className: "text-xs text-text-muted",
|
|
153
|
+
children: v("bigconsole.pipelines.execution.triggeredByHeading", "Triggered by")
|
|
154
|
+
}), /* @__PURE__ */ u("dd", {
|
|
155
|
+
className: "break-all font-mono text-text-primary",
|
|
156
|
+
title: e.executedBy,
|
|
157
|
+
children: x ?? v("bigconsole.pipelines.execution.triggeredByYou", "you")
|
|
158
|
+
})]
|
|
159
|
+
})
|
|
160
|
+
]
|
|
161
|
+
}),
|
|
162
|
+
/* @__PURE__ */ u("p", {
|
|
163
|
+
className: "text-xs text-text-secondary",
|
|
164
|
+
"data-testid": "pipeline-stage-counts",
|
|
165
|
+
children: v("bigconsole.pipelines.execution.stageCounts", "{{success}} succeeded · {{skipped}} skipped · {{failed}} failed", b.counts)
|
|
166
|
+
}),
|
|
167
|
+
b.rows.length === 0 ? /* @__PURE__ */ u("p", {
|
|
168
|
+
className: "text-sm text-text-secondary",
|
|
169
|
+
children: v("bigconsole.pipelines.execution.noStageResults", "This run recorded no stage results.")
|
|
170
|
+
}) : /* @__PURE__ */ u("ol", {
|
|
171
|
+
className: "flex flex-col gap-control-gap",
|
|
172
|
+
children: b.rows.map((e) => /* @__PURE__ */ d("li", {
|
|
173
|
+
"data-testid": "pipeline-timeline-stage",
|
|
174
|
+
"data-status": e.status,
|
|
175
|
+
className: "min-w-0 rounded-card border border-[var(--color-border-subtle)] bg-bg-sunken p-3",
|
|
176
|
+
children: [
|
|
177
|
+
/* @__PURE__ */ d("div", {
|
|
178
|
+
className: "flex flex-wrap items-center justify-between gap-control-gap",
|
|
179
|
+
children: [/* @__PURE__ */ d("h3", {
|
|
180
|
+
className: "min-w-0 break-words text-sm font-medium text-text-primary",
|
|
181
|
+
children: [
|
|
182
|
+
e.step,
|
|
183
|
+
". ",
|
|
184
|
+
e.name
|
|
185
|
+
]
|
|
186
|
+
}), /* @__PURE__ */ d("span", {
|
|
187
|
+
className: "flex items-center gap-2 text-sm text-text-secondary",
|
|
188
|
+
children: [/* @__PURE__ */ u(h, {
|
|
189
|
+
tone: e.tone,
|
|
190
|
+
label: y(e.status)
|
|
191
|
+
}), /* @__PURE__ */ u("span", { children: r(e.durationMs) })]
|
|
192
|
+
})]
|
|
193
|
+
}),
|
|
194
|
+
/* @__PURE__ */ u("div", {
|
|
195
|
+
className: "relative mt-2 h-2 w-full overflow-hidden rounded-pill bg-bg-surface",
|
|
196
|
+
role: "img",
|
|
197
|
+
"aria-label": v("bigconsole.pipelines.execution.barLabel", "{{name}}: {{duration}}, {{share}}% of stage time", {
|
|
198
|
+
name: e.name,
|
|
199
|
+
duration: r(e.durationMs),
|
|
200
|
+
share: Math.round(e.widthPercent)
|
|
201
|
+
}),
|
|
202
|
+
children: /* @__PURE__ */ u("span", {
|
|
203
|
+
className: `absolute inset-y-0 rounded-pill ${p[e.tone]}`,
|
|
204
|
+
style: {
|
|
205
|
+
left: `${e.offsetPercent}%`,
|
|
206
|
+
width: `${e.widthPercent}%`
|
|
207
|
+
}
|
|
208
|
+
})
|
|
209
|
+
}),
|
|
210
|
+
(e.inputKey || e.outputKey) && /* @__PURE__ */ d("div", {
|
|
211
|
+
className: "mt-2 flex flex-wrap items-center gap-x-2 gap-y-1 text-xs text-text-secondary",
|
|
212
|
+
children: [
|
|
213
|
+
/* @__PURE__ */ u("span", {
|
|
214
|
+
className: "text-text-muted",
|
|
215
|
+
children: v("bigconsole.pipelines.execution.reads", "Reads")
|
|
216
|
+
}),
|
|
217
|
+
/* @__PURE__ */ u("code", {
|
|
218
|
+
className: m,
|
|
219
|
+
children: e.inputKey ?? "—"
|
|
220
|
+
}),
|
|
221
|
+
/* @__PURE__ */ u("span", {
|
|
222
|
+
"aria-hidden": "true",
|
|
223
|
+
children: "→"
|
|
224
|
+
}),
|
|
225
|
+
/* @__PURE__ */ u("span", {
|
|
226
|
+
className: "text-text-muted",
|
|
227
|
+
children: v("bigconsole.pipelines.execution.writes", "writes")
|
|
228
|
+
}),
|
|
229
|
+
/* @__PURE__ */ u("code", {
|
|
230
|
+
className: m,
|
|
231
|
+
children: e.outputKey ?? "—"
|
|
232
|
+
})
|
|
233
|
+
]
|
|
234
|
+
}),
|
|
235
|
+
e.error && /* @__PURE__ */ u("p", {
|
|
236
|
+
className: "mt-2 break-words text-sm text-status-error-text",
|
|
237
|
+
"data-testid": "pipeline-timeline-error",
|
|
238
|
+
children: e.error
|
|
239
|
+
}),
|
|
240
|
+
e.hasOutput && /* @__PURE__ */ d("details", {
|
|
241
|
+
className: "mt-2",
|
|
242
|
+
children: [/* @__PURE__ */ u("summary", {
|
|
243
|
+
className: "cursor-pointer rounded-button text-sm text-text-secondary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
244
|
+
children: v("bigconsole.pipelines.execution.stageOutput", "Stage output")
|
|
245
|
+
}), /* @__PURE__ */ u("pre", {
|
|
246
|
+
className: "mt-2 max-h-48 overflow-auto rounded-input bg-bg-canvas p-3 text-xs text-text-primary",
|
|
247
|
+
children: JSON.stringify(e.output, null, 2)
|
|
248
|
+
})]
|
|
249
|
+
})
|
|
250
|
+
]
|
|
251
|
+
}, e.id))
|
|
252
|
+
}),
|
|
253
|
+
e.error && /* @__PURE__ */ u("p", {
|
|
254
|
+
role: "alert",
|
|
255
|
+
className: "break-words text-sm text-status-error-text",
|
|
256
|
+
children: e.error
|
|
257
|
+
}),
|
|
258
|
+
e.outputData !== null && e.outputData !== void 0 && /* @__PURE__ */ d("details", { children: [/* @__PURE__ */ u("summary", {
|
|
259
|
+
className: "cursor-pointer rounded-button text-sm text-text-secondary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-bg-surface",
|
|
260
|
+
children: v("bigconsole.pipelines.execution.runOutput", "Run output")
|
|
261
|
+
}), /* @__PURE__ */ u("pre", {
|
|
262
|
+
className: "mt-2 max-h-64 overflow-auto rounded-input bg-bg-canvas p-3 text-xs text-text-primary",
|
|
263
|
+
children: JSON.stringify(e.outputData, null, 2)
|
|
264
|
+
})] })
|
|
265
|
+
]
|
|
266
|
+
})
|
|
267
|
+
});
|
|
268
|
+
});
|
|
269
|
+
//#endregion
|
|
270
|
+
export { v as PipelineRunHistoryList, y as PipelineStageTimeline };
|
|
@@ -18,7 +18,8 @@ interface UpdatePipelineInput {
|
|
|
18
18
|
name?: string;
|
|
19
19
|
description?: string;
|
|
20
20
|
status?: PipelineStatus;
|
|
21
|
-
|
|
21
|
+
/** Full replacement of the stage list, in order (the service replaces stages wholesale). */
|
|
22
|
+
stages?: UpdatePipelineStageInput[];
|
|
22
23
|
}
|
|
23
24
|
interface CreatePipelineStageInput {
|
|
24
25
|
parserId: string;
|