@epam/ai-dial-scheduled-tasks 1.3.0-dev.159 → 1.3.0-dev.160
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/components/ScheduledTaskDetailView/ScheduledTaskDetailView.d.ts.map +1 -1
- package/components/ScheduledTaskHistorySection/ScheduledTaskHistorySection.d.ts.map +1 -1
- package/components/ScheduledTaskRunHistoryList/ScheduledTaskRunHistoryList.d.ts.map +1 -1
- package/components/ScheduledTasks/ScheduledTasks.d.ts.map +1 -1
- package/index.js +312 -319
- package/models/scheduled-task-detail-view-props.d.ts +2 -0
- package/models/scheduled-task-detail-view-props.d.ts.map +1 -1
- package/models/scheduled-task-history-section-props.d.ts +2 -0
- package/models/scheduled-task-history-section-props.d.ts.map +1 -1
- package/models/scheduled-task-run-history-list-props.d.ts +2 -0
- package/models/scheduled-task-run-history-list-props.d.ts.map +1 -1
- package/models/scheduled-tasks-props.d.ts +4 -0
- package/models/scheduled-tasks-props.d.ts.map +1 -1
- package/package.json +4 -4
package/index.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, t as s, u as c } from "./calendar-value-CjtsOQpy.js";
|
|
2
2
|
import { ConfirmationDialog as l, ConfirmationIdentityRow as u, MARKDOWN_EDITOR_MAX_HEIGHT_CLASS_NAME as d, MARKDOWN_EDITOR_PREVIEW_LIST_CLASS_NAME as f, MDMessageViewer as p, PanelEmptyState as m, ResourceSummary as h, TextRefinementField as g, buildCssVars as _, mergeClasses as v, useAvailableHeightCap as y, useIsMobile as b, useTextRefinement as x, useUnsavedChangesGuard as ee } from "@epam/ai-dial-chat-shared";
|
|
3
|
-
import { Accordion as S, ButtonAppearance as C, ButtonDropdown as w, ButtonVariant as T, Calendar as E, CalendarMode as D, CardShell as O, ConfirmationPopupVariant as te, DIAL_ICON_SIZE as k, DIAL_KIT_ICON_STROKE as A, ElementSize as ne, ErrorText as j, FolderPath as
|
|
4
|
-
import { IconAlertTriangle as
|
|
5
|
-
import { Suspense as
|
|
6
|
-
import { Fragment as
|
|
7
|
-
import { BuilderFormContainer as
|
|
8
|
-
import { LazyMarkdownEditor as
|
|
3
|
+
import { Accordion as S, ButtonAppearance as C, ButtonDropdown as w, ButtonVariant as T, Calendar as E, CalendarMode as D, CardShell as O, ConfirmationPopupVariant as te, DIAL_ICON_SIZE as k, DIAL_KIT_ICON_STROKE as A, ElementSize as ne, ErrorText as j, FolderPath as re, GhostButton as M, GhostIconButton as ie, Highlight as ae, Input as oe, Label as se, MenuItemMark as N, NeutralButton as P, NoDataContent as F, NumberInput as ce, PrimaryButton as le, Search as ue, Select as de, Skeleton as I, SkeletonVariant as L, Spinner as fe, Switch as R, Tabs as pe, Textarea as me, Tooltip as he } from "@epam/ai-dial-ui-kit";
|
|
4
|
+
import { IconAlertTriangle as z, IconArrowNarrowLeft as ge, IconArrowsSort as _e, IconCheck as B, IconCircleX as V, IconPencilMinus as ve, IconPlayerPause as H, IconPlayerPlay as ye, IconPlus as be, IconTrashX as xe } from "@tabler/icons-react";
|
|
5
|
+
import { Suspense as Se, lazy as U, useCallback as Ce, useEffect as we, useId as Te, useLayoutEffect as Ee, useMemo as W, useRef as De, useState as Oe } from "react";
|
|
6
|
+
import { Fragment as ke, jsx as G, jsxs as K } from "react/jsx-runtime";
|
|
7
|
+
import { BuilderFormContainer as Ae } from "@epam/ai-dial-builder-form";
|
|
8
|
+
import { LazyMarkdownEditor as je } from "@epam/ai-dial-ui-kit/editors";
|
|
9
9
|
//#region src/constants/public-class-names.ts
|
|
10
|
-
var
|
|
10
|
+
var Me = {
|
|
11
11
|
card: "dial-scheduled-tasks-card",
|
|
12
12
|
cardGrid: "dial-scheduled-tasks-card-grid",
|
|
13
13
|
refineFeedback: "dial-scheduled-tasks-refine-feedback"
|
|
14
14
|
}, q = /* @__PURE__ */ function(e) {
|
|
15
15
|
return e.Scheduled = "scheduled", e.Paused = "paused", e.Completed = "completed", e;
|
|
16
|
-
}({}),
|
|
16
|
+
}({}), Ne = /* @__PURE__ */ function(e) {
|
|
17
17
|
return e.Active = "active", e.Paused = "paused", e.Completed = "completed", e;
|
|
18
|
-
}({}),
|
|
18
|
+
}({}), Pe = (e) => {
|
|
19
19
|
switch (e.presentationStatus) {
|
|
20
|
-
case
|
|
21
|
-
case
|
|
22
|
-
case
|
|
20
|
+
case Ne.Active: return q.Scheduled;
|
|
21
|
+
case Ne.Paused: return q.Paused;
|
|
22
|
+
case Ne.Completed: return q.Completed;
|
|
23
23
|
}
|
|
24
24
|
return e.isCompleted ? q.Completed : e.isActive === !1 ? q.Paused : q.Scheduled;
|
|
25
25
|
}, J = {
|
|
@@ -29,7 +29,7 @@ var Ne = {
|
|
|
29
29
|
pausedLabel: "_pausedLabel_1cwco_15",
|
|
30
30
|
completedPill: "_completedPill_1cwco_19",
|
|
31
31
|
completedLabel: "_completedLabel_1cwco_24"
|
|
32
|
-
},
|
|
32
|
+
}, Fe = {
|
|
33
33
|
[q.Scheduled]: {
|
|
34
34
|
pillClassName: "inline-block rounded-lg border px-2 py-1",
|
|
35
35
|
wrapperClassName: J.schedulePill,
|
|
@@ -49,14 +49,14 @@ var Ne = {
|
|
|
49
49
|
pillClassName: "inline-flex items-center gap-1.5 rounded-full border px-2 py-1",
|
|
50
50
|
wrapperClassName: J.completedPill,
|
|
51
51
|
labelClassName: J.completedLabel,
|
|
52
|
-
renderIcon: () => /* @__PURE__ */ G(
|
|
52
|
+
renderIcon: () => /* @__PURE__ */ G(B, {
|
|
53
53
|
size: k.SM,
|
|
54
54
|
"aria-hidden": !0,
|
|
55
55
|
stroke: A
|
|
56
56
|
})
|
|
57
57
|
}
|
|
58
|
-
},
|
|
59
|
-
let { pillClassName: i, wrapperClassName: a, labelClassName: o, renderIcon: s } =
|
|
58
|
+
}, Ie = ({ status: e, text: t, textClassName: n = "dial-tiny-text", className: r }) => {
|
|
59
|
+
let { pillClassName: i, wrapperClassName: a, labelClassName: o, renderIcon: s } = Fe[e];
|
|
60
60
|
return /* @__PURE__ */ K("span", {
|
|
61
61
|
className: v(i, n, a, o, r),
|
|
62
62
|
children: [s && s(), t]
|
|
@@ -69,8 +69,8 @@ var Ne = {
|
|
|
69
69
|
newBadge: "_newBadge_hmbo0_18",
|
|
70
70
|
locationDivider: "_locationDivider_hmbo0_23",
|
|
71
71
|
card: "_card_hmbo0_34"
|
|
72
|
-
},
|
|
73
|
-
let o = b(), s = r?.newBadgeLabel ?? "NEW", c = r?.pausedBadgeLabel ?? "Paused", l = r?.completedBadgeLabel ?? "Completed", { colors: u, typography: d } = i ?? {}, f = d?.titleClassName ?? "dial-body-semi-text", p = d?.descriptionClassName ?? "dial-small-text", m = d?.descriptionSizeClassName ?? "dial-tiny-text", h = d?.scheduleLabelClassName ?? "dial-tiny-text", g = d?.pausedBadgeClassName ?? "dial-tiny-text", y = d?.completedBadgeClassName ?? "dial-tiny-text", x = d?.locationLabelClassName ?? "dial-tiny-text", ee = d?.locationLeafClassName ?? "dial-tiny-semi-text", S = d?.newBadgeClassName ?? "dial-tiny-semi-text", C =
|
|
72
|
+
}, Le = ({ item: e, searchQuery: t = "", onCardClick: n, labels: r, styles: i, className: a }) => {
|
|
73
|
+
let o = b(), s = r?.newBadgeLabel ?? "NEW", c = r?.pausedBadgeLabel ?? "Paused", l = r?.completedBadgeLabel ?? "Completed", { colors: u, typography: d } = i ?? {}, f = d?.titleClassName ?? "dial-body-semi-text", p = d?.descriptionClassName ?? "dial-small-text", m = d?.descriptionSizeClassName ?? "dial-tiny-text", h = d?.scheduleLabelClassName ?? "dial-tiny-text", g = d?.pausedBadgeClassName ?? "dial-tiny-text", y = d?.completedBadgeClassName ?? "dial-tiny-text", x = d?.locationLabelClassName ?? "dial-tiny-text", ee = d?.locationLeafClassName ?? "dial-tiny-semi-text", S = d?.newBadgeClassName ?? "dial-tiny-semi-text", C = Pe(e), { text: w, textClassName: T } = {
|
|
74
74
|
[q.Scheduled]: {
|
|
75
75
|
text: e.scheduleLabel,
|
|
76
76
|
textClassName: h
|
|
@@ -111,12 +111,12 @@ var Ne = {
|
|
|
111
111
|
role: n ? "button" : "group",
|
|
112
112
|
"aria-label": e.displayName,
|
|
113
113
|
style: E,
|
|
114
|
-
className: v("h-[var(--st-card-height,232px)]", Y.card, n && "cursor-pointer", a,
|
|
114
|
+
className: v("h-[var(--st-card-height,232px)]", Y.card, n && "cursor-pointer", a, Me.card),
|
|
115
115
|
...D,
|
|
116
116
|
children: [
|
|
117
117
|
/* @__PURE__ */ K("div", {
|
|
118
118
|
className: "flex min-w-0 shrink-0 items-start gap-2 desktop:items-center",
|
|
119
|
-
children: [/* @__PURE__ */ G(
|
|
119
|
+
children: [/* @__PURE__ */ G(ae, {
|
|
120
120
|
text: e.displayName,
|
|
121
121
|
query: t,
|
|
122
122
|
maxLines: o ? 2 : 1,
|
|
@@ -134,12 +134,12 @@ var Ne = {
|
|
|
134
134
|
className: "mt-auto flex shrink-0 flex-col gap-3",
|
|
135
135
|
children: [/* @__PURE__ */ G("div", {
|
|
136
136
|
className: "flex min-h-[28px] items-center",
|
|
137
|
-
children: /* @__PURE__ */ G(
|
|
137
|
+
children: /* @__PURE__ */ G(Ie, {
|
|
138
138
|
status: C,
|
|
139
139
|
text: w,
|
|
140
140
|
textClassName: T
|
|
141
141
|
})
|
|
142
|
-
}), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ G(
|
|
142
|
+
}), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ G(re, {
|
|
143
143
|
segments: e.locationSegments,
|
|
144
144
|
labelClassName: v(x, Y.locationLabel),
|
|
145
145
|
leafClassName: v(ee, Y.locationLeaf),
|
|
@@ -148,43 +148,43 @@ var Ne = {
|
|
|
148
148
|
})
|
|
149
149
|
]
|
|
150
150
|
});
|
|
151
|
-
},
|
|
151
|
+
}, Re = { card: "_card_18ivt_1" }, ze = [
|
|
152
152
|
"100%",
|
|
153
153
|
"100%",
|
|
154
154
|
"61%"
|
|
155
|
-
],
|
|
155
|
+
], Be = "var(--stcs-skeleton-bg)", Ve = ({ styles: e }) => {
|
|
156
156
|
let t = _({ "--stcs-skeleton-bg": e?.colors?.skeletonColor });
|
|
157
157
|
return /* @__PURE__ */ K(O, {
|
|
158
158
|
"aria-hidden": !0,
|
|
159
159
|
style: t,
|
|
160
|
-
className: v("h-[var(--st-card-height,232px)]",
|
|
160
|
+
className: v("h-[var(--st-card-height,232px)]", Re.card),
|
|
161
161
|
children: [
|
|
162
162
|
/* @__PURE__ */ G(I, {
|
|
163
163
|
variant: L.Rectangular,
|
|
164
164
|
width: "60%",
|
|
165
165
|
height: "20px",
|
|
166
|
-
color:
|
|
166
|
+
color: Be,
|
|
167
167
|
className: "shrink-0"
|
|
168
168
|
}),
|
|
169
169
|
/* @__PURE__ */ G("div", {
|
|
170
170
|
className: "flex min-h-0 flex-1 flex-col gap-3 overflow-hidden",
|
|
171
|
-
children:
|
|
171
|
+
children: ze.map((e, t) => /* @__PURE__ */ G(I, {
|
|
172
172
|
variant: L.Rectangular,
|
|
173
173
|
width: e,
|
|
174
174
|
height: "16px",
|
|
175
|
-
color:
|
|
175
|
+
color: Be
|
|
176
176
|
}, t))
|
|
177
177
|
}),
|
|
178
178
|
/* @__PURE__ */ G(I, {
|
|
179
179
|
variant: L.Rectangular,
|
|
180
180
|
width: "110px",
|
|
181
181
|
height: "28px",
|
|
182
|
-
color:
|
|
182
|
+
color: Be,
|
|
183
183
|
className: "shrink-0 rounded-lg"
|
|
184
184
|
})
|
|
185
185
|
]
|
|
186
186
|
});
|
|
187
|
-
},
|
|
187
|
+
}, He = ({ items: e, searchQuery: t, onCardClick: n, labels: r, cardStyles: i, trailingSkeletonCount: a = 0, skeletonStyles: o, layout: s }) => /* @__PURE__ */ K("div", {
|
|
188
188
|
style: {
|
|
189
189
|
"--st-grid-min-card-width": s?.minCardWidth,
|
|
190
190
|
"--st-grid-gap": s?.gap,
|
|
@@ -194,14 +194,14 @@ var Ne = {
|
|
|
194
194
|
gap: "var(--st-grid-gap, 20px)",
|
|
195
195
|
gridTemplateColumns: "repeat(auto-fill, minmax(min(100%, max(var(--st-grid-min-card-width, 320px), calc((100% - (var(--st-grid-columns) - 1) * var(--st-grid-gap, 20px)) / var(--st-grid-columns)))), 1fr))"
|
|
196
196
|
},
|
|
197
|
-
className: v("mx-auto grid w-full min-w-0",
|
|
198
|
-
children: [e.map((e) => /* @__PURE__ */ G(
|
|
197
|
+
className: v("mx-auto grid w-full min-w-0", Me.cardGrid),
|
|
198
|
+
children: [e.map((e) => /* @__PURE__ */ G(Le, {
|
|
199
199
|
item: e,
|
|
200
200
|
searchQuery: t,
|
|
201
201
|
onCardClick: n,
|
|
202
202
|
labels: r,
|
|
203
203
|
styles: i
|
|
204
|
-
}, e.id)), Array.from({ length: a }, (e, t) => /* @__PURE__ */ G(
|
|
204
|
+
}, e.id)), Array.from({ length: a }, (e, t) => /* @__PURE__ */ G(Ve, { styles: o }, `skeleton-${t}`))]
|
|
205
205
|
}), X = {
|
|
206
206
|
container: "_container_3vz4t_2",
|
|
207
207
|
subtitle: "_subtitle_3vz4t_6",
|
|
@@ -209,47 +209,43 @@ var Ne = {
|
|
|
209
209
|
sortButton: "_sortButton_3vz4t_19",
|
|
210
210
|
createButton: "_createButton_3vz4t_10",
|
|
211
211
|
sortControlHidden: "_sortControlHidden_3vz4t_49"
|
|
212
|
-
},
|
|
213
|
-
size: 48,
|
|
214
|
-
stroke: 1,
|
|
215
|
-
"aria-hidden": !0
|
|
216
|
-
}), Ge = (e, t, n, r, i, a) => {
|
|
212
|
+
}, Ue = (e, t, n, r, i, a) => {
|
|
217
213
|
if (!e) return t ? a.loadingMoreLabel : n ? a.errorLabel : r > 0 ? `${r}` : i ? a.noResultsLabel : a.emptyStateLabel;
|
|
218
|
-
},
|
|
214
|
+
}, We = (e) => {
|
|
219
215
|
if (!e || e === document.body) return null;
|
|
220
216
|
let { overflow: t, overflowY: n } = getComputedStyle(e);
|
|
221
|
-
return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e :
|
|
222
|
-
},
|
|
223
|
-
let { colors: O, typography: te } = y ?? {}, j = te?.titleClassName ?? "dial-h1-text",
|
|
217
|
+
return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e : We(e.parentElement);
|
|
218
|
+
}, Ge = ({ labels: e, onCreateClick: t, searchQuery: n, onSearchQueryChange: r, sortKey: i, onSortChange: a, items: o, isLoading: s = !1, error: c, onRetry: l, hasMore: u = !1, isLoadingMore: d = !1, skeletonCount: f = 6, onLoadMore: p, onCardClick: h, banner: g, styles: y, sortIcon: b, className: x, gridLayout: ee, cardStyles: S, loadMoreError: E, onRetryLoadMore: D }) => {
|
|
219
|
+
let { colors: O, typography: te } = y ?? {}, j = te?.titleClassName ?? "dial-h1-text", re = te?.subtitleClassName ?? "dial-body-text", ie = _({
|
|
224
220
|
"--st-bg": O?.background,
|
|
225
221
|
"--st-subtitle-text": O?.subtitleText,
|
|
226
222
|
"--st-sort-text": O?.sortButtonText
|
|
227
|
-
}),
|
|
223
|
+
}), ae = (e) => {
|
|
228
224
|
r(e ?? "");
|
|
229
|
-
}, [
|
|
230
|
-
|
|
231
|
-
}, []),
|
|
232
|
-
|
|
225
|
+
}, [oe, se] = Oe(!1), [P, F] = Oe(!1), ce = De(null), de = Ce(() => {
|
|
226
|
+
F(!0);
|
|
227
|
+
}, []), I = Ce(() => {
|
|
228
|
+
F(!1);
|
|
233
229
|
}, []);
|
|
234
|
-
|
|
235
|
-
let e =
|
|
236
|
-
|
|
237
|
-
}, [
|
|
238
|
-
let
|
|
230
|
+
Ee(() => {
|
|
231
|
+
let e = ce.current;
|
|
232
|
+
P && oe && e != null && e.offsetParent == null && se(!1);
|
|
233
|
+
}, [P, oe]);
|
|
234
|
+
let L = e.sortOptions.find((e) => e.value === i)?.label ?? e.sortLabel, R = W(() => e.sortOptions.map((e) => ({
|
|
239
235
|
key: e.value,
|
|
240
236
|
label: e.label,
|
|
241
|
-
mark:
|
|
237
|
+
mark: N.Check,
|
|
242
238
|
checked: e.value === i,
|
|
243
239
|
onClick: () => a(e.value)
|
|
244
240
|
})), [
|
|
245
241
|
e.sortOptions,
|
|
246
242
|
i,
|
|
247
243
|
a
|
|
248
|
-
]),
|
|
249
|
-
|
|
250
|
-
let e =
|
|
244
|
+
]), pe = Ue(s, d, !!c, o.length, n.trim().length > 0, e), me = De(null);
|
|
245
|
+
we(() => {
|
|
246
|
+
let e = me.current;
|
|
251
247
|
if (!e || !p) return;
|
|
252
|
-
let t =
|
|
248
|
+
let t = We(e.parentElement);
|
|
253
249
|
if (!t) return;
|
|
254
250
|
let n = () => {
|
|
255
251
|
if (d || s || E || !u) return;
|
|
@@ -264,25 +260,25 @@ var Ne = {
|
|
|
264
260
|
E,
|
|
265
261
|
p
|
|
266
262
|
]);
|
|
267
|
-
let
|
|
263
|
+
let he = () => s ? /* @__PURE__ */ G(fe, {}) : c ? /* @__PURE__ */ K("div", {
|
|
268
264
|
className: "flex flex-col items-center gap-3",
|
|
269
265
|
children: [/* @__PURE__ */ G("p", {
|
|
270
|
-
className: v(
|
|
266
|
+
className: v(re, X.subtitle),
|
|
271
267
|
children: e.errorLabel
|
|
272
|
-
}), /* @__PURE__ */ G(
|
|
268
|
+
}), /* @__PURE__ */ G(M, {
|
|
273
269
|
label: e.retryLabel,
|
|
274
270
|
onClick: l
|
|
275
271
|
})]
|
|
276
|
-
}) : o.length === 0 ? n.trim() ? /* @__PURE__ */ G(
|
|
277
|
-
|
|
278
|
-
|
|
272
|
+
}) : o.length === 0 ? n.trim() ? /* @__PURE__ */ G(m, {
|
|
273
|
+
label: e.noResultsLabel,
|
|
274
|
+
description: e.noResultsDescription
|
|
279
275
|
}) : /* @__PURE__ */ G(m, {
|
|
280
276
|
label: e.emptyStateLabel,
|
|
281
|
-
|
|
277
|
+
description: e.emptyStateDescription
|
|
282
278
|
}) : /* @__PURE__ */ K("div", {
|
|
283
279
|
className: "flex w-full flex-col gap-6",
|
|
284
280
|
children: [
|
|
285
|
-
/* @__PURE__ */ G(
|
|
281
|
+
/* @__PURE__ */ G(He, {
|
|
286
282
|
items: o,
|
|
287
283
|
searchQuery: n,
|
|
288
284
|
onCardClick: h,
|
|
@@ -296,22 +292,22 @@ var Ne = {
|
|
|
296
292
|
role: "alert",
|
|
297
293
|
className: "flex items-center gap-3",
|
|
298
294
|
children: [/* @__PURE__ */ G("span", {
|
|
299
|
-
className: v(
|
|
295
|
+
className: v(re, X.subtitle),
|
|
300
296
|
children: e.loadMoreErrorLabel ?? e.errorLabel
|
|
301
|
-
}), /* @__PURE__ */ G(
|
|
297
|
+
}), /* @__PURE__ */ G(M, {
|
|
302
298
|
label: e.retryLabel,
|
|
303
299
|
onClick: D
|
|
304
300
|
})]
|
|
305
301
|
}),
|
|
306
302
|
/* @__PURE__ */ G("div", {
|
|
307
|
-
ref:
|
|
303
|
+
ref: me,
|
|
308
304
|
"aria-hidden": !0,
|
|
309
305
|
className: "h-px w-full"
|
|
310
306
|
})
|
|
311
307
|
]
|
|
312
|
-
}),
|
|
308
|
+
}), z = s || !!c || o.length === 0;
|
|
313
309
|
return /* @__PURE__ */ K("div", {
|
|
314
|
-
style:
|
|
310
|
+
style: ie,
|
|
315
311
|
className: v("flex h-full w-full flex-col gap-4 overflow-y-auto px-4 py-4 desktop:gap-6 desktop:px-8", X.container, x),
|
|
316
312
|
children: [
|
|
317
313
|
/* @__PURE__ */ K("div", {
|
|
@@ -322,14 +318,14 @@ var Ne = {
|
|
|
322
318
|
className: v("truncate", j),
|
|
323
319
|
children: e.title
|
|
324
320
|
}), /* @__PURE__ */ G("p", {
|
|
325
|
-
className: v("mt-1",
|
|
321
|
+
className: v("mt-1", re, X.subtitle),
|
|
326
322
|
children: e.subtitle
|
|
327
323
|
})]
|
|
328
|
-
}), /* @__PURE__ */ G(
|
|
324
|
+
}), /* @__PURE__ */ G(le, {
|
|
329
325
|
label: e.createButtonLabel,
|
|
330
326
|
textClassName: X.createButtonLabel,
|
|
331
327
|
"aria-label": e.createButtonLabel,
|
|
332
|
-
iconBefore: /* @__PURE__ */ G(
|
|
328
|
+
iconBefore: /* @__PURE__ */ G(be, {
|
|
333
329
|
size: k.SM,
|
|
334
330
|
"aria-hidden": !0,
|
|
335
331
|
stroke: A
|
|
@@ -343,25 +339,25 @@ var Ne = {
|
|
|
343
339
|
children: [/* @__PURE__ */ G("div", {
|
|
344
340
|
role: "search",
|
|
345
341
|
className: "flex-1",
|
|
346
|
-
children: /* @__PURE__ */ G(
|
|
342
|
+
children: /* @__PURE__ */ G(ue, {
|
|
347
343
|
value: n,
|
|
348
|
-
onChange:
|
|
344
|
+
onChange: ae,
|
|
349
345
|
placeholder: e.searchPlaceholder,
|
|
350
346
|
clearLabel: e.clearSearchLabel,
|
|
351
347
|
"aria-label": e.searchAriaLabel,
|
|
352
348
|
size: ne.Large,
|
|
353
|
-
onFocus:
|
|
354
|
-
onBlur:
|
|
349
|
+
onFocus: de,
|
|
350
|
+
onBlur: I
|
|
355
351
|
})
|
|
356
352
|
}), e.sortOptions.length > 0 && /* @__PURE__ */ G("div", {
|
|
357
|
-
ref:
|
|
358
|
-
className: v(
|
|
353
|
+
ref: ce,
|
|
354
|
+
className: v(P && X.sortControlHidden),
|
|
359
355
|
children: /* @__PURE__ */ G(w, {
|
|
360
|
-
items:
|
|
361
|
-
label:
|
|
356
|
+
items: R,
|
|
357
|
+
label: L,
|
|
362
358
|
variant: T.Primary,
|
|
363
359
|
appearance: C.Ghost,
|
|
364
|
-
iconBefore: b === void 0 ? /* @__PURE__ */ G(
|
|
360
|
+
iconBefore: b === void 0 ? /* @__PURE__ */ G(_e, {
|
|
365
361
|
size: k.SM,
|
|
366
362
|
"aria-hidden": !0,
|
|
367
363
|
stroke: A
|
|
@@ -375,23 +371,23 @@ var Ne = {
|
|
|
375
371
|
role: "status",
|
|
376
372
|
"aria-live": "polite",
|
|
377
373
|
className: "sr-only",
|
|
378
|
-
children:
|
|
374
|
+
children: pe
|
|
379
375
|
}),
|
|
380
376
|
/* @__PURE__ */ G("div", {
|
|
381
|
-
className: v("mx-auto flex size-full w-full min-w-0 flex-col",
|
|
382
|
-
children:
|
|
377
|
+
className: v("mx-auto flex size-full w-full min-w-0 flex-col", z && "items-center justify-center"),
|
|
378
|
+
children: he()
|
|
383
379
|
})
|
|
384
380
|
]
|
|
385
381
|
});
|
|
386
|
-
},
|
|
382
|
+
}, Ke = /* @__PURE__ */ function(e) {
|
|
387
383
|
return e.FirstToRun = "firstToRun", e.LastToRun = "lastToRun", e.Newest = "newest", e.NameAZ = "nameAZ", e;
|
|
388
|
-
}({}),
|
|
384
|
+
}({}), qe = (e) => e == null ? "" : typeof e == "string" ? e.trim() : Array.isArray(e) ? e.length ? JSON.stringify(e) : "" : JSON.stringify(e), Je = (e, t) => {
|
|
389
385
|
let n = /* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(t)]);
|
|
390
|
-
for (let r of n) if (
|
|
386
|
+
for (let r of n) if (qe(e[r]) !== qe(t[r])) return !0;
|
|
391
387
|
return !1;
|
|
392
|
-
},
|
|
393
|
-
let n =
|
|
394
|
-
return
|
|
388
|
+
}, Ye = (e, t, n) => t === r.Hourly == (n === r.Hourly) ? e : void 0, Xe = (e, t) => {
|
|
389
|
+
let n = Te();
|
|
390
|
+
return Ee(() => {
|
|
395
391
|
let r = document.getElementById(e);
|
|
396
392
|
r && (t ? r.setAttribute("aria-describedby", n) : r.removeAttribute("aria-describedby"));
|
|
397
393
|
}, [
|
|
@@ -399,8 +395,8 @@ var Ne = {
|
|
|
399
395
|
n,
|
|
400
396
|
e
|
|
401
397
|
]), n;
|
|
402
|
-
},
|
|
403
|
-
let p = (e) => c(r === D.DateTime ? n(e) : i(e)), m =
|
|
398
|
+
}, Ze = { error: "_error_v2pfn_4" }, Qe = ({ id: t, mode: r, label: a, placeholder: o, value: s, onChange: c, minDate: l, error: u, errorClassName: d, disabled: f }) => {
|
|
399
|
+
let p = (e) => c(r === D.DateTime ? n(e) : i(e)), m = Xe(t, u);
|
|
404
400
|
return /* @__PURE__ */ K("div", {
|
|
405
401
|
className: "flex flex-1 flex-col gap-1",
|
|
406
402
|
children: [/* @__PURE__ */ G(E, {
|
|
@@ -416,12 +412,12 @@ var Ne = {
|
|
|
416
412
|
}), u && /* @__PURE__ */ G(j, {
|
|
417
413
|
id: m,
|
|
418
414
|
role: "alert",
|
|
419
|
-
className: v(d,
|
|
415
|
+
className: v(d, Ze.error),
|
|
420
416
|
text: u
|
|
421
417
|
})]
|
|
422
418
|
});
|
|
423
|
-
},
|
|
424
|
-
let l =
|
|
419
|
+
}, $e = { error: "_error_v2pfn_4" }, et = ({ label: e, placeholder: r, value: i, onChange: a, disabled: o, error: s, errorClassName: c = "dial-tiny-text" }) => {
|
|
420
|
+
let l = De(/* @__PURE__ */ new Date()).current, u = (e) => a(n(e)), d = Xe("scheduled-task-run-at", s);
|
|
425
421
|
return /* @__PURE__ */ K("div", {
|
|
426
422
|
className: "flex flex-col gap-1",
|
|
427
423
|
children: [/* @__PURE__ */ G(E, {
|
|
@@ -440,7 +436,7 @@ var Ne = {
|
|
|
440
436
|
}), s && /* @__PURE__ */ G(j, {
|
|
441
437
|
id: d,
|
|
442
438
|
role: "alert",
|
|
443
|
-
className: v(c,
|
|
439
|
+
className: v(c, $e.error),
|
|
444
440
|
text: s
|
|
445
441
|
})]
|
|
446
442
|
});
|
|
@@ -451,58 +447,58 @@ var Ne = {
|
|
|
451
447
|
instructionsError: "_instructionsError_1253x_18",
|
|
452
448
|
refineFeedback: "_refineFeedback_1253x_22",
|
|
453
449
|
refineError: "_refineError_1253x_26"
|
|
454
|
-
},
|
|
455
|
-
let
|
|
456
|
-
if (
|
|
457
|
-
|
|
450
|
+
}, tt = U(async () => ({ default: (await je()).MarkdownEditor })), nt = ({ labels: e, values: t, initialValues: n, errors: i, modelSelector: c, modelLabelId: u, skillSelector: p, onFieldChange: m, onBack: h, onCancel: b, onSubmit: S, isSubmitting: C = !1, onRefineDescription: w, onRefineInstructions: T, markdownEditorTheme: O, backIcon: ne, className: re, styles: M }) => {
|
|
451
|
+
let ie = Te(), ae = Te(), N = De(void 0), P = (e) => e ? async (t, n) => {
|
|
452
|
+
if (N.current && !N.current.aborted) throw new DOMException("Busy", "AbortError");
|
|
453
|
+
N.current = n;
|
|
458
454
|
try {
|
|
459
455
|
return await e(t, n);
|
|
460
456
|
} finally {
|
|
461
|
-
|
|
457
|
+
N.current === n && (N.current = void 0);
|
|
462
458
|
}
|
|
463
|
-
} : void 0,
|
|
459
|
+
} : void 0, F = x({
|
|
464
460
|
value: t.description ?? "",
|
|
465
461
|
onChange: (e) => m("description", e),
|
|
466
|
-
onRefine:
|
|
462
|
+
onRefine: P(w),
|
|
467
463
|
disabled: C
|
|
468
464
|
}), le = x({
|
|
469
465
|
value: t.prompt,
|
|
470
466
|
onChange: (e) => m("prompt", e),
|
|
471
|
-
onRefine:
|
|
467
|
+
onRefine: P(T),
|
|
472
468
|
disabled: C
|
|
473
|
-
}),
|
|
474
|
-
|
|
475
|
-
},
|
|
476
|
-
|
|
477
|
-
}),
|
|
478
|
-
|
|
479
|
-
}),
|
|
480
|
-
"--stcf-details-border":
|
|
481
|
-
"--stcf-subtitle-text":
|
|
482
|
-
"--stcf-error-text":
|
|
483
|
-
"--stcf-refine-action-text":
|
|
484
|
-
"--stcf-refine-error-text":
|
|
485
|
-
}),
|
|
486
|
-
feedbackClassName: v(
|
|
469
|
+
}), ue = F.isPending || le.isPending, I = () => {
|
|
470
|
+
F.reset(), le.reset();
|
|
471
|
+
}, L = !!(n && Je(t, n)), R = ee(L), pe = () => R.guard(() => {
|
|
472
|
+
I(), h();
|
|
473
|
+
}), he = () => R.guard(() => {
|
|
474
|
+
I(), b();
|
|
475
|
+
}), z = y(), _e = !t.skillUrls?.length, [B, V] = Oe(), ve = De(/* @__PURE__ */ new Date()).current, { colors: H, typography: ye, layout: be } = M ?? {}, xe = ye?.titleClassName ?? "dial-h1-text", U = ye?.sectionTitleClassName ?? "dial-body-semi-text", Ce = ye?.sectionSubtitleClassName ?? "dial-tiny-text", Ee = ye?.instructionsLabelClassName ?? "dial-body-semi-text mb-1", W = ye?.instructionsErrorClassName ?? "dial-tiny-text", je = _({
|
|
476
|
+
"--stcf-details-border": H?.detailsColumnBorder,
|
|
477
|
+
"--stcf-subtitle-text": H?.sectionSubtitleText,
|
|
478
|
+
"--stcf-error-text": H?.instructionsErrorText,
|
|
479
|
+
"--stcf-refine-action-text": H?.refineActionText,
|
|
480
|
+
"--stcf-refine-error-text": H?.refineErrorText
|
|
481
|
+
}), q = {
|
|
482
|
+
feedbackClassName: v(H?.refineActionText && Z.refineFeedback, ye?.refineFeedbackClassName, Me.refineFeedback),
|
|
487
483
|
errorClassName: Z.refineError
|
|
488
|
-
},
|
|
484
|
+
}, Ne = (t) => {
|
|
489
485
|
let n = s.test(t.target.value) ? void 0 : e.timeInvalidLabel;
|
|
490
|
-
|
|
486
|
+
V(n), m("time", t.target.value);
|
|
491
487
|
}, Pe = (e) => {
|
|
492
|
-
|
|
493
|
-
},
|
|
488
|
+
V(void 0), m("time", typeof e == "string" ? e : "");
|
|
489
|
+
}, J = (e) => {
|
|
494
490
|
let n = e;
|
|
495
491
|
m("repeat", n);
|
|
496
|
-
let r =
|
|
492
|
+
let r = Ye(t.startDate, t.repeat, n);
|
|
497
493
|
r !== t.startDate && m("startDate", r ?? "");
|
|
498
|
-
let i =
|
|
494
|
+
let i = Ye(t.endDate, t.repeat, n);
|
|
499
495
|
i !== t.endDate && m("endDate", i ?? "");
|
|
500
|
-
},
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
}, [
|
|
504
|
-
let ze =
|
|
505
|
-
return /* @__PURE__ */ K(
|
|
496
|
+
}, Fe = t.repeat !== r.OneTime && t.repeat !== r.Hourly, Ie = t.repeat === r.Hourly, Y = Ie ? D.DateTime : D.Date, Le = Ie ? e.startDateAndTimeLabel : e.startDateLabel, Re = Ie ? e.endDateAndTimeLabel : e.endDateLabel;
|
|
497
|
+
we(() => {
|
|
498
|
+
Fe || V(void 0);
|
|
499
|
+
}, [Fe]);
|
|
500
|
+
let ze = Fe ? B ?? i.time : void 0, Be = (e) => m("runAt", e), Ve = C || ue || !t.displayName.trim() || !t.modelId || !t.prompt.trim() && !t.skillUrls?.length || !!i.skillUrls || t.repeat === r.OneTime && (!t.runAt || !!i.runAt) || Fe && !t.time || !!ze;
|
|
501
|
+
return /* @__PURE__ */ K(ke, { children: [/* @__PURE__ */ G(Ae, {
|
|
506
502
|
labels: {
|
|
507
503
|
title: e.pageTitle,
|
|
508
504
|
backButtonLabel: e.backButtonLabel,
|
|
@@ -510,15 +506,15 @@ var Ne = {
|
|
|
510
506
|
submitButtonLabel: e.createButtonLabel,
|
|
511
507
|
submittingLabel: e.submittingLabel ?? "Saving"
|
|
512
508
|
},
|
|
513
|
-
onBack:
|
|
514
|
-
onCancel:
|
|
509
|
+
onBack: pe,
|
|
510
|
+
onCancel: he,
|
|
515
511
|
onSubmit: () => {
|
|
516
|
-
!Ve && (!
|
|
512
|
+
!Ve && (!N.current || N.current.aborted) && S();
|
|
517
513
|
},
|
|
518
514
|
isCancelDisabled: C,
|
|
519
515
|
isSubmitDisabled: Ve,
|
|
520
516
|
isSubmitting: C,
|
|
521
|
-
backIcon: ne === void 0 ? /* @__PURE__ */ G(
|
|
517
|
+
backIcon: ne === void 0 ? /* @__PURE__ */ G(ge, {
|
|
522
518
|
size: k.LG,
|
|
523
519
|
stroke: A,
|
|
524
520
|
"aria-hidden": !0,
|
|
@@ -529,14 +525,14 @@ var Ne = {
|
|
|
529
525
|
columnGap: be?.columnGap,
|
|
530
526
|
reserveEndColumn: !1
|
|
531
527
|
},
|
|
532
|
-
className:
|
|
528
|
+
className: re,
|
|
533
529
|
styles: {
|
|
534
|
-
colors: { background:
|
|
530
|
+
colors: { background: H?.background },
|
|
535
531
|
header: {
|
|
536
|
-
colors: { borderColor:
|
|
532
|
+
colors: { borderColor: H?.headerBorder },
|
|
537
533
|
typography: { fontClassName: xe }
|
|
538
534
|
},
|
|
539
|
-
cssVars:
|
|
535
|
+
cssVars: je
|
|
540
536
|
},
|
|
541
537
|
left: /* @__PURE__ */ K("div", {
|
|
542
538
|
role: "group",
|
|
@@ -546,14 +542,14 @@ var Ne = {
|
|
|
546
542
|
/* @__PURE__ */ K("div", {
|
|
547
543
|
className: "flex flex-col gap-1",
|
|
548
544
|
children: [/* @__PURE__ */ G("h2", {
|
|
549
|
-
className:
|
|
545
|
+
className: U,
|
|
550
546
|
children: e.detailsSectionTitle
|
|
551
547
|
}), /* @__PURE__ */ G("p", {
|
|
552
|
-
className: v(
|
|
548
|
+
className: v(Ce, Z.sectionSubtitle),
|
|
553
549
|
children: e.detailsSectionSubtitle
|
|
554
550
|
})]
|
|
555
551
|
}),
|
|
556
|
-
/* @__PURE__ */ G(
|
|
552
|
+
/* @__PURE__ */ G(oe, {
|
|
557
553
|
id: "scheduled-task-display-name",
|
|
558
554
|
value: t.displayName,
|
|
559
555
|
onChange: (e) => m("displayName", e ?? ""),
|
|
@@ -566,18 +562,18 @@ var Ne = {
|
|
|
566
562
|
}),
|
|
567
563
|
/* @__PURE__ */ G(g, {
|
|
568
564
|
isEnabled: !!w,
|
|
569
|
-
fieldId:
|
|
565
|
+
fieldId: ie,
|
|
570
566
|
label: e.descriptionLabel,
|
|
571
567
|
labels: e,
|
|
572
|
-
refinement:
|
|
573
|
-
disabled: C ||
|
|
568
|
+
refinement: F,
|
|
569
|
+
disabled: C || ue,
|
|
574
570
|
caption: `${(t.description ?? "").length}/500`,
|
|
575
|
-
...
|
|
571
|
+
...q,
|
|
576
572
|
children: /* @__PURE__ */ G(me, {
|
|
577
|
-
id:
|
|
573
|
+
id: ie,
|
|
578
574
|
value: t.description ?? "",
|
|
579
575
|
onChange: (e) => {
|
|
580
|
-
|
|
576
|
+
F.reset(), m("description", e);
|
|
581
577
|
},
|
|
582
578
|
labelProps: w ? void 0 : { label: e.descriptionLabel },
|
|
583
579
|
maxLength: 500,
|
|
@@ -588,14 +584,14 @@ var Ne = {
|
|
|
588
584
|
/* @__PURE__ */ K("div", {
|
|
589
585
|
className: "flex flex-col gap-1",
|
|
590
586
|
children: [
|
|
591
|
-
/* @__PURE__ */ G(
|
|
587
|
+
/* @__PURE__ */ G(se, {
|
|
592
588
|
id: u,
|
|
593
589
|
label: e.modelOrAgentLabel,
|
|
594
590
|
required: !0
|
|
595
591
|
}),
|
|
596
592
|
c,
|
|
597
593
|
i.modelId && /* @__PURE__ */ G(j, {
|
|
598
|
-
className: v(
|
|
594
|
+
className: v(W, Z.instructionsError),
|
|
599
595
|
text: i.modelId
|
|
600
596
|
})
|
|
601
597
|
]
|
|
@@ -603,25 +599,25 @@ var Ne = {
|
|
|
603
599
|
/* @__PURE__ */ K("div", {
|
|
604
600
|
className: "flex flex-col gap-3",
|
|
605
601
|
children: [
|
|
606
|
-
/* @__PURE__ */ G(
|
|
602
|
+
/* @__PURE__ */ G(de, {
|
|
607
603
|
labelProps: { label: e.repeatLabel },
|
|
608
604
|
value: t.repeat,
|
|
609
|
-
onChange:
|
|
605
|
+
onChange: J,
|
|
610
606
|
options: e.repeatOptions.map((e) => ({
|
|
611
607
|
value: e.key,
|
|
612
608
|
label: e.label
|
|
613
609
|
}))
|
|
614
610
|
}),
|
|
615
|
-
t.repeat === r.OneTime && /* @__PURE__ */ G(
|
|
611
|
+
t.repeat === r.OneTime && /* @__PURE__ */ G(et, {
|
|
616
612
|
label: e.runAtLabel,
|
|
617
613
|
placeholder: e.runAtPlaceholder,
|
|
618
614
|
value: t.runAt ?? "",
|
|
619
615
|
onChange: Be,
|
|
620
616
|
error: i.runAt,
|
|
621
|
-
errorClassName:
|
|
617
|
+
errorClassName: W,
|
|
622
618
|
disabled: C
|
|
623
619
|
}),
|
|
624
|
-
t.repeat !== r.OneTime && /* @__PURE__ */ K(
|
|
620
|
+
t.repeat !== r.OneTime && /* @__PURE__ */ K(ke, { children: [
|
|
625
621
|
t.repeat === r.Weekly && /* @__PURE__ */ K("div", {
|
|
626
622
|
className: "flex flex-col gap-1",
|
|
627
623
|
children: [/* @__PURE__ */ G(E, {
|
|
@@ -635,18 +631,18 @@ var Ne = {
|
|
|
635
631
|
},
|
|
636
632
|
invalid: !!i.dayOfWeek
|
|
637
633
|
}), i.dayOfWeek && /* @__PURE__ */ G(j, {
|
|
638
|
-
className: v(
|
|
634
|
+
className: v(W, Z.instructionsError),
|
|
639
635
|
text: i.dayOfWeek
|
|
640
636
|
})]
|
|
641
637
|
}),
|
|
642
|
-
|
|
638
|
+
Fe && /* @__PURE__ */ K("div", {
|
|
643
639
|
className: "flex flex-col gap-1",
|
|
644
640
|
children: [/* @__PURE__ */ G(E, {
|
|
645
641
|
id: "scheduled-task-time",
|
|
646
642
|
mode: D.Time,
|
|
647
643
|
value: t.time,
|
|
648
644
|
onChange: Pe,
|
|
649
|
-
onBlur:
|
|
645
|
+
onBlur: Ne,
|
|
650
646
|
labelProps: {
|
|
651
647
|
label: e.timeLabel,
|
|
652
648
|
required: !0
|
|
@@ -655,11 +651,11 @@ var Ne = {
|
|
|
655
651
|
disabled: C,
|
|
656
652
|
showTimezone: !0
|
|
657
653
|
}), ze && /* @__PURE__ */ G(j, {
|
|
658
|
-
className: v(
|
|
654
|
+
className: v(W, Z.instructionsError),
|
|
659
655
|
text: ze
|
|
660
656
|
})]
|
|
661
657
|
}),
|
|
662
|
-
t.repeat === r.Monthly && /* @__PURE__ */ G(
|
|
658
|
+
t.repeat === r.Monthly && /* @__PURE__ */ G(ce, {
|
|
663
659
|
id: "scheduled-task-day-of-month",
|
|
664
660
|
integer: !0,
|
|
665
661
|
min: 1,
|
|
@@ -673,7 +669,7 @@ var Ne = {
|
|
|
673
669
|
invalid: !!i.dayOfMonth,
|
|
674
670
|
error: i.dayOfMonth
|
|
675
671
|
}),
|
|
676
|
-
t.repeat === r.Hourly && /* @__PURE__ */ G(
|
|
672
|
+
t.repeat === r.Hourly && /* @__PURE__ */ G(ce, {
|
|
677
673
|
id: "scheduled-task-minute",
|
|
678
674
|
integer: !0,
|
|
679
675
|
min: 0,
|
|
@@ -690,27 +686,27 @@ var Ne = {
|
|
|
690
686
|
}),
|
|
691
687
|
/* @__PURE__ */ K("div", {
|
|
692
688
|
className: v("gap-3", Ie ? "flex flex-col" : "flex flex-row"),
|
|
693
|
-
children: [/* @__PURE__ */ G(
|
|
689
|
+
children: [/* @__PURE__ */ G(Qe, {
|
|
694
690
|
id: "scheduled-task-start-date",
|
|
695
|
-
mode:
|
|
696
|
-
label:
|
|
691
|
+
mode: Y,
|
|
692
|
+
label: Le,
|
|
697
693
|
placeholder: e.startDatePlaceholder,
|
|
698
694
|
value: t.startDate,
|
|
699
695
|
onChange: (e) => m("startDate", e),
|
|
700
|
-
minDate:
|
|
696
|
+
minDate: ve,
|
|
701
697
|
error: i.startDate,
|
|
702
|
-
errorClassName:
|
|
698
|
+
errorClassName: W,
|
|
703
699
|
disabled: C
|
|
704
|
-
}), /* @__PURE__ */ G(
|
|
700
|
+
}), /* @__PURE__ */ G(Qe, {
|
|
705
701
|
id: "scheduled-task-end-date",
|
|
706
|
-
mode:
|
|
702
|
+
mode: Y,
|
|
707
703
|
label: Re,
|
|
708
704
|
placeholder: e.endDatePlaceholder,
|
|
709
705
|
value: t.endDate,
|
|
710
706
|
onChange: (e) => m("endDate", e),
|
|
711
|
-
minDate:
|
|
707
|
+
minDate: ve,
|
|
712
708
|
error: i.endDate,
|
|
713
|
-
errorClassName:
|
|
709
|
+
errorClassName: W,
|
|
714
710
|
disabled: C
|
|
715
711
|
})]
|
|
716
712
|
})
|
|
@@ -727,14 +723,14 @@ var Ne = {
|
|
|
727
723
|
/* @__PURE__ */ G("div", {
|
|
728
724
|
className: "flex flex-col gap-1",
|
|
729
725
|
children: /* @__PURE__ */ G("h2", {
|
|
730
|
-
className:
|
|
726
|
+
className: U,
|
|
731
727
|
children: e.configurationSectionTitle
|
|
732
728
|
})
|
|
733
729
|
}),
|
|
734
730
|
p == null ? i.skillUrls && /* @__PURE__ */ G("div", {
|
|
735
731
|
"aria-live": "polite",
|
|
736
732
|
children: /* @__PURE__ */ G(j, {
|
|
737
|
-
className: v(
|
|
733
|
+
className: v(W, Z.instructionsError),
|
|
738
734
|
text: i.skillUrls
|
|
739
735
|
})
|
|
740
736
|
}) : /* @__PURE__ */ G("div", {
|
|
@@ -745,30 +741,30 @@ var Ne = {
|
|
|
745
741
|
className: "flex w-full max-w-[996px] min-w-0 flex-col",
|
|
746
742
|
children: /* @__PURE__ */ G(g, {
|
|
747
743
|
isEnabled: !!T,
|
|
748
|
-
fieldId:
|
|
749
|
-
labelClassName:
|
|
744
|
+
fieldId: ae,
|
|
745
|
+
labelClassName: Ee,
|
|
750
746
|
label: e.instructionsLabel,
|
|
751
|
-
required:
|
|
747
|
+
required: _e,
|
|
752
748
|
labels: e,
|
|
753
749
|
refinement: le,
|
|
754
|
-
disabled: C ||
|
|
755
|
-
...
|
|
750
|
+
disabled: C || ue,
|
|
751
|
+
...q,
|
|
756
752
|
children: /* @__PURE__ */ K("div", {
|
|
757
753
|
className: "flex flex-1 flex-col gap-1",
|
|
758
754
|
children: [
|
|
759
|
-
!T && /* @__PURE__ */ G(
|
|
760
|
-
htmlFor:
|
|
761
|
-
className:
|
|
755
|
+
!T && /* @__PURE__ */ G(se, {
|
|
756
|
+
htmlFor: ae,
|
|
757
|
+
className: Ee,
|
|
762
758
|
label: e.instructionsLabel,
|
|
763
|
-
required:
|
|
759
|
+
required: _e
|
|
764
760
|
}),
|
|
765
761
|
/* @__PURE__ */ G("div", {
|
|
766
|
-
ref:
|
|
762
|
+
ref: z,
|
|
767
763
|
className: v("w-full", d, f),
|
|
768
|
-
children: /* @__PURE__ */ G(
|
|
769
|
-
fallback: /* @__PURE__ */ G(
|
|
770
|
-
children: /* @__PURE__ */ G(
|
|
771
|
-
id:
|
|
764
|
+
children: /* @__PURE__ */ G(Se, {
|
|
765
|
+
fallback: /* @__PURE__ */ G(fe, {}),
|
|
766
|
+
children: /* @__PURE__ */ G(tt, {
|
|
767
|
+
id: ae,
|
|
772
768
|
value: t.prompt,
|
|
773
769
|
onChange: (e) => {
|
|
774
770
|
le.reset(), m("prompt", e);
|
|
@@ -780,7 +776,7 @@ var Ne = {
|
|
|
780
776
|
})
|
|
781
777
|
}),
|
|
782
778
|
i.prompt && /* @__PURE__ */ G(j, {
|
|
783
|
-
className: v(
|
|
779
|
+
className: v(W, Z.instructionsError),
|
|
784
780
|
text: i.prompt
|
|
785
781
|
})
|
|
786
782
|
]
|
|
@@ -789,28 +785,28 @@ var Ne = {
|
|
|
789
785
|
})
|
|
790
786
|
]
|
|
791
787
|
})
|
|
792
|
-
}),
|
|
788
|
+
}), R.isConfirmOpen && /* @__PURE__ */ G(l, {
|
|
793
789
|
open: !0,
|
|
794
790
|
title: e.discardTitle ?? "Discard unsaved changes?",
|
|
795
791
|
message: e.discardMessage ?? "You have unsaved changes. Leaving now will discard them.",
|
|
796
792
|
confirmLabel: e.discardConfirmLabel ?? "Discard changes",
|
|
797
793
|
cancelLabel: e.discardCancelLabel ?? "Keep editing",
|
|
798
794
|
variant: te.Danger,
|
|
799
|
-
onConfirm:
|
|
800
|
-
onClose:
|
|
795
|
+
onConfirm: R.confirm,
|
|
796
|
+
onClose: R.dismiss
|
|
801
797
|
})] });
|
|
802
|
-
},
|
|
798
|
+
}, rt = /* @__PURE__ */ function(e) {
|
|
803
799
|
return e.Details = "details", e.Configuration = "configuration", e.History = "history", e;
|
|
804
|
-
}({}),
|
|
800
|
+
}({}), it = /* @__PURE__ */ function(e) {
|
|
805
801
|
return e.Card = "card", e.Flow = "flow", e;
|
|
806
|
-
}({}),
|
|
802
|
+
}({}), at = { subtitleText: "_subtitleText_1i4x2_3" }, ot = ({ skillLabel: e, skillDisplayNames: t, instructionsLabel: n, instructionsMarkdown: r, renderInstructions: i, markdownLabels: a, fieldLabelClassName: o = "dial-tiny-text" }) => /* @__PURE__ */ K("div", {
|
|
807
803
|
className: "flex min-w-0 flex-col gap-5",
|
|
808
804
|
children: [!!t?.length && /* @__PURE__ */ K("div", {
|
|
809
805
|
role: "group",
|
|
810
806
|
"aria-label": e,
|
|
811
807
|
className: "flex min-w-0 flex-col gap-1",
|
|
812
808
|
children: [/* @__PURE__ */ G("span", {
|
|
813
|
-
className: v(o,
|
|
809
|
+
className: v(o, at.subtitleText),
|
|
814
810
|
children: e
|
|
815
811
|
}), /* @__PURE__ */ G("p", {
|
|
816
812
|
className: "break-all whitespace-normal",
|
|
@@ -824,18 +820,18 @@ var Ne = {
|
|
|
824
820
|
"aria-label": n,
|
|
825
821
|
className: "flex min-w-0 flex-col gap-1",
|
|
826
822
|
children: [/* @__PURE__ */ G("span", {
|
|
827
|
-
className: v(o,
|
|
823
|
+
className: v(o, at.subtitleText),
|
|
828
824
|
children: n
|
|
829
825
|
}), i ? i(r) : /* @__PURE__ */ G(p, {
|
|
830
826
|
content: r,
|
|
831
827
|
...a
|
|
832
828
|
})]
|
|
833
829
|
})]
|
|
834
|
-
}),
|
|
830
|
+
}), st = { subtitleText: "_subtitleText_1i4x2_3" }, ct = ({ labels: e, description: t, modelLabel: n, repeatsLabel: r, activeWindowLabel: i, completedLabel: a, fieldLabelClassName: o = "dial-tiny-text", fieldValueClassName: s = "dial-small-text" }) => /* @__PURE__ */ K(ke, { children: [
|
|
835
831
|
t && /* @__PURE__ */ K("div", {
|
|
836
832
|
className: "flex flex-col gap-1",
|
|
837
833
|
children: [/* @__PURE__ */ G("span", {
|
|
838
|
-
className: v(o,
|
|
834
|
+
className: v(o, st.subtitleText),
|
|
839
835
|
children: e.descriptionLabel
|
|
840
836
|
}), /* @__PURE__ */ G("p", {
|
|
841
837
|
className: s,
|
|
@@ -845,7 +841,7 @@ var Ne = {
|
|
|
845
841
|
a && /* @__PURE__ */ K("div", {
|
|
846
842
|
className: "flex flex-col gap-1",
|
|
847
843
|
children: [/* @__PURE__ */ G("span", {
|
|
848
|
-
className: v(o,
|
|
844
|
+
className: v(o, st.subtitleText),
|
|
849
845
|
children: e.completedFieldLabel
|
|
850
846
|
}), /* @__PURE__ */ G("p", {
|
|
851
847
|
className: s,
|
|
@@ -855,7 +851,7 @@ var Ne = {
|
|
|
855
851
|
n && /* @__PURE__ */ K("div", {
|
|
856
852
|
className: "flex flex-col gap-1",
|
|
857
853
|
children: [/* @__PURE__ */ G("span", {
|
|
858
|
-
className: v(o,
|
|
854
|
+
className: v(o, st.subtitleText),
|
|
859
855
|
children: e.modelLabel
|
|
860
856
|
}), /* @__PURE__ */ G("p", {
|
|
861
857
|
className: s,
|
|
@@ -865,7 +861,7 @@ var Ne = {
|
|
|
865
861
|
r && /* @__PURE__ */ K("div", {
|
|
866
862
|
className: "flex flex-col gap-1",
|
|
867
863
|
children: [/* @__PURE__ */ G("span", {
|
|
868
|
-
className: v(o,
|
|
864
|
+
className: v(o, st.subtitleText),
|
|
869
865
|
children: e.repeatsLabel
|
|
870
866
|
}), /* @__PURE__ */ G("p", {
|
|
871
867
|
className: s,
|
|
@@ -875,14 +871,14 @@ var Ne = {
|
|
|
875
871
|
i && /* @__PURE__ */ K("div", {
|
|
876
872
|
className: "flex flex-col gap-1",
|
|
877
873
|
children: [/* @__PURE__ */ G("span", {
|
|
878
|
-
className: v(o,
|
|
874
|
+
className: v(o, st.subtitleText),
|
|
879
875
|
children: e.activeWindowLabel
|
|
880
876
|
}), /* @__PURE__ */ G("p", {
|
|
881
877
|
className: s,
|
|
882
878
|
children: i
|
|
883
879
|
})]
|
|
884
880
|
})
|
|
885
|
-
] }),
|
|
881
|
+
] }), lt = /* @__PURE__ */ function(e) {
|
|
886
882
|
return e.Success = "success", e.Error = "error", e.InProgress = "inProgress", e.Missed = "missed", e;
|
|
887
883
|
}({}), Q = {
|
|
888
884
|
subtitleText: "_subtitleText_6i141_1",
|
|
@@ -892,25 +888,25 @@ var Ne = {
|
|
|
892
888
|
currentRun: "_currentRun_6i141_17",
|
|
893
889
|
interactiveRow: "_interactiveRow_6i141_22",
|
|
894
890
|
unreadDot: "_unreadDot_6i141_33"
|
|
895
|
-
},
|
|
891
|
+
}, ut = ({ status: e }) => {
|
|
896
892
|
switch (e) {
|
|
897
|
-
case
|
|
893
|
+
case lt.Success: return /* @__PURE__ */ G(B, {
|
|
898
894
|
size: k.SM,
|
|
899
895
|
className: Q.successIcon,
|
|
900
896
|
"aria-hidden": !0,
|
|
901
897
|
stroke: A
|
|
902
898
|
});
|
|
903
|
-
case
|
|
899
|
+
case lt.Error: return /* @__PURE__ */ G(V, {
|
|
904
900
|
size: k.SM,
|
|
905
901
|
className: Q.errorIcon,
|
|
906
902
|
"aria-hidden": !0,
|
|
907
903
|
stroke: A
|
|
908
904
|
});
|
|
909
|
-
case
|
|
905
|
+
case lt.InProgress: return /* @__PURE__ */ G("span", {
|
|
910
906
|
"aria-hidden": !0,
|
|
911
|
-
children: /* @__PURE__ */ G(
|
|
907
|
+
children: /* @__PURE__ */ G(fe, { size: k.SM })
|
|
912
908
|
});
|
|
913
|
-
case
|
|
909
|
+
case lt.Missed: return /* @__PURE__ */ G(z, {
|
|
914
910
|
size: k.SM,
|
|
915
911
|
className: Q.missedIcon,
|
|
916
912
|
"aria-hidden": !0,
|
|
@@ -918,7 +914,7 @@ var Ne = {
|
|
|
918
914
|
});
|
|
919
915
|
default: return null;
|
|
920
916
|
}
|
|
921
|
-
},
|
|
917
|
+
}, dt = ({ items: e, isLoading: t = !1, isLoadingMore: n = !1, skeletonCount: r = 6, error: i, onRetry: a, currentRunId: o, onRunClick: s, labels: c, footer: l, styles: u }) => {
|
|
922
918
|
let { colors: d, typography: f } = u ?? {}, p = f?.runTimestampClassName ?? "dial-small-paragraph-text", m = f?.runTimestampUnreadClassName ?? "dial-small-paragraph-semi-text", h = f?.subtitleClassName ?? "dial-body-text", g = c.unreadIndicatorLabel ?? "Unread", y = _({
|
|
923
919
|
"--strhl-success-icon": d?.successIconColor,
|
|
924
920
|
"--strhl-error-icon": d?.errorIconColor,
|
|
@@ -930,7 +926,7 @@ var Ne = {
|
|
|
930
926
|
"--strhl-row-focus-bg": u?.rowFocusBackground,
|
|
931
927
|
"--strhl-row-focus-outline": u?.rowFocusOutline
|
|
932
928
|
}), b = (e) => {
|
|
933
|
-
let t = c.runStatusLabels[e.status], n = e.id === o, r = e.status ===
|
|
929
|
+
let t = c.runStatusLabels[e.status], n = e.id === o, r = e.status === lt.Error && e.errorText ? e.errorText : void 0, i = [
|
|
934
930
|
r,
|
|
935
931
|
e.isUnread ? g : void 0,
|
|
936
932
|
n ? c.currentRunLabel : void 0
|
|
@@ -960,9 +956,9 @@ var Ne = {
|
|
|
960
956
|
children: /* @__PURE__ */ G("span", {
|
|
961
957
|
className: "flex shrink-0",
|
|
962
958
|
tabIndex: l ? void 0 : 0,
|
|
963
|
-
children: /* @__PURE__ */ G(
|
|
959
|
+
children: /* @__PURE__ */ G(ut, { status: e.status })
|
|
964
960
|
})
|
|
965
|
-
}) : /* @__PURE__ */ G(
|
|
961
|
+
}) : /* @__PURE__ */ G(ut, { status: e.status }), /* @__PURE__ */ K("span", {
|
|
966
962
|
className: "flex min-w-0 items-center gap-1",
|
|
967
963
|
children: [/* @__PURE__ */ G("span", {
|
|
968
964
|
className: v(e.isUnread ? m : p, "truncate"),
|
|
@@ -1009,23 +1005,18 @@ var Ne = {
|
|
|
1009
1005
|
role: "alert",
|
|
1010
1006
|
className: v(h, Q.subtitleText),
|
|
1011
1007
|
children: c.errorLabel
|
|
1012
|
-
}), /* @__PURE__ */ G(
|
|
1008
|
+
}), /* @__PURE__ */ G(M, {
|
|
1013
1009
|
label: c.retryLabel,
|
|
1014
1010
|
onClick: a
|
|
1015
1011
|
})]
|
|
1016
|
-
}) : e.length === 0 ? /* @__PURE__ */
|
|
1012
|
+
}) : e.length === 0 ? /* @__PURE__ */ G("div", {
|
|
1017
1013
|
style: y,
|
|
1018
|
-
className: "
|
|
1019
|
-
children:
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
}), /* @__PURE__ */ G("p", {
|
|
1025
|
-
role: "status",
|
|
1026
|
-
className: p,
|
|
1027
|
-
children: c.emptyLabel
|
|
1028
|
-
})]
|
|
1014
|
+
className: "w-full py-4",
|
|
1015
|
+
children: /* @__PURE__ */ G(F, {
|
|
1016
|
+
title: c.emptyLabel,
|
|
1017
|
+
description: c.emptyDescription,
|
|
1018
|
+
live: !0
|
|
1019
|
+
})
|
|
1029
1020
|
}) : /* @__PURE__ */ K("ul", {
|
|
1030
1021
|
style: {
|
|
1031
1022
|
...y,
|
|
@@ -1042,44 +1033,44 @@ var Ne = {
|
|
|
1042
1033
|
role: "alert",
|
|
1043
1034
|
className: v(h, Q.subtitleText),
|
|
1044
1035
|
children: c.errorLabel
|
|
1045
|
-
}), /* @__PURE__ */ G(
|
|
1036
|
+
}), /* @__PURE__ */ G(M, {
|
|
1046
1037
|
label: c.retryLabel,
|
|
1047
1038
|
onClick: a
|
|
1048
1039
|
})]
|
|
1049
1040
|
}) : l
|
|
1050
1041
|
]
|
|
1051
1042
|
});
|
|
1052
|
-
},
|
|
1043
|
+
}, ft = {
|
|
1053
1044
|
historyCard: "_historyCard_153p9_4",
|
|
1054
1045
|
subtitleText: "_subtitleText_153p9_8",
|
|
1055
1046
|
cardLayout: "_cardLayout_153p9_13"
|
|
1056
|
-
},
|
|
1057
|
-
let b = e ===
|
|
1047
|
+
}, pt = ({ variant: e, labels: t, nextRunLabel: n, items: r, isLoading: i = !1, isLoadingMore: a = !1, skeletonCount: o = 6, error: s, onRetry: c, loadMoreError: l, onRetryLoadMore: u, hasMore: d = !1, onLoadMore: f, onRunClick: p, runTimestampClassName: m = "dial-small-text", runTimestampUnreadClassName: h = "dial-small-semi-text", sectionTitleClassName: g = "dial-body-semi-text", colors: _, styles: y }) => {
|
|
1048
|
+
let b = e === it.Card, x = b ? v("sticky bottom-0 z-10 rounded-b-xl px-6 pb-5 pt-2", ft.historyCard) : "pt-2", ee = l ? /* @__PURE__ */ K("li", {
|
|
1058
1049
|
className: x,
|
|
1059
1050
|
children: [/* @__PURE__ */ G("p", {
|
|
1060
1051
|
role: "alert",
|
|
1061
1052
|
children: t.historyLoadMoreErrorLabel ?? t.historyErrorLabel
|
|
1062
|
-
}), u && /* @__PURE__ */ G(
|
|
1053
|
+
}), u && /* @__PURE__ */ G(M, {
|
|
1063
1054
|
label: t.historyRetryLabel,
|
|
1064
1055
|
onClick: u,
|
|
1065
1056
|
disabled: a
|
|
1066
1057
|
})]
|
|
1067
1058
|
}) : f && d && t.historyShowMoreLabel ? /* @__PURE__ */ G("li", {
|
|
1068
1059
|
className: x,
|
|
1069
|
-
children: /* @__PURE__ */ G(
|
|
1060
|
+
children: /* @__PURE__ */ G(M, {
|
|
1070
1061
|
label: t.historyShowMoreLabel,
|
|
1071
1062
|
onClick: f,
|
|
1072
1063
|
disabled: a
|
|
1073
1064
|
})
|
|
1074
1065
|
}) : void 0, S = n ? /* @__PURE__ */ G("p", {
|
|
1075
|
-
className: v(m,
|
|
1066
|
+
className: v(m, ft.subtitleText),
|
|
1076
1067
|
children: n
|
|
1077
1068
|
}) : void 0, C = t.historyLoadingMoreLabel ? /* @__PURE__ */ G("span", {
|
|
1078
1069
|
role: "status",
|
|
1079
1070
|
"aria-live": "polite",
|
|
1080
1071
|
className: "sr-only",
|
|
1081
1072
|
children: a ? t.historyLoadingMoreLabel : ""
|
|
1082
|
-
}) : void 0, w = /* @__PURE__ */ G(
|
|
1073
|
+
}) : void 0, w = /* @__PURE__ */ G(dt, {
|
|
1083
1074
|
items: r,
|
|
1084
1075
|
isLoading: i,
|
|
1085
1076
|
isLoadingMore: a,
|
|
@@ -1090,6 +1081,7 @@ var Ne = {
|
|
|
1090
1081
|
labels: {
|
|
1091
1082
|
historyTitle: t.historyTitle,
|
|
1092
1083
|
emptyLabel: t.historyEmptyLabel,
|
|
1084
|
+
emptyDescription: t.historyEmptyDescription,
|
|
1093
1085
|
errorLabel: t.historyErrorLabel,
|
|
1094
1086
|
retryLabel: t.historyRetryLabel,
|
|
1095
1087
|
runStatusLabels: t.runStatusLabels,
|
|
@@ -1109,10 +1101,10 @@ var Ne = {
|
|
|
1109
1101
|
}
|
|
1110
1102
|
});
|
|
1111
1103
|
return b ? /* @__PURE__ */ K("div", {
|
|
1112
|
-
className: v("flex max-h-[var(--st-history-max-height,70vh)] w-full max-w-full flex-col overflow-y-auto rounded-xl shadow-md",
|
|
1104
|
+
className: v("flex max-h-[var(--st-history-max-height,70vh)] w-full max-w-full flex-col overflow-y-auto rounded-xl shadow-md", ft.historyCard, ft.cardLayout),
|
|
1113
1105
|
style: { "--st-history-max-height": y?.maxHeight },
|
|
1114
1106
|
children: [/* @__PURE__ */ K("div", {
|
|
1115
|
-
className: v("sticky top-0 z-10 flex flex-col gap-4 rounded-t-xl px-6 pt-5 pb-2",
|
|
1107
|
+
className: v("sticky top-0 z-10 flex flex-col gap-4 rounded-t-xl px-6 pt-5 pb-2", ft.historyCard),
|
|
1116
1108
|
children: [
|
|
1117
1109
|
/* @__PURE__ */ G("h2", {
|
|
1118
1110
|
className: g,
|
|
@@ -1147,27 +1139,27 @@ var Ne = {
|
|
|
1147
1139
|
actionButton: "_actionButton_hdn5b_75",
|
|
1148
1140
|
roundActionButton: "_roundActionButton_hdn5b_82",
|
|
1149
1141
|
stickyTabs: "_stickyTabs_hdn5b_88"
|
|
1150
|
-
},
|
|
1151
|
-
let { colors:
|
|
1152
|
-
"--stdv-bg":
|
|
1153
|
-
"--stdv-header-border":
|
|
1154
|
-
"--stdv-details-border":
|
|
1155
|
-
"--stdv-subtitle-text":
|
|
1156
|
-
"--stdv-history-bg":
|
|
1157
|
-
}), Ee = b(), [
|
|
1142
|
+
}, mt = ({ labels: e, onBack: t, onEdit: n, onStartNow: r, isStarting: i = !1, isStartNowDisabled: a = !1, isStartNowBusy: o = !1, onDelete: s, isDeleting: c = !1, isDeleted: l = !1, isCompleted: u = !1, isActive: d, isActiveUpdating: f = !1, isActiveDisabled: p = !1, activeDisabledReason: m, onActiveChange: h, displayName: g, isLoading: y = !1, error: x, onRetry: ee, description: S, modelLabel: C, repeatsLabel: w, activeWindowLabel: E, completedLabel: D, nextRunLabel: O, instructionsMarkdown: te, skillDisplayNames: ne, renderInstructions: j, runs: re, runsIsLoading: ae = !1, runsIsLoadingMore: oe = !1, runsSkeletonCount: se = 6, runsError: N, onRunsRetry: F, runsLoadMoreError: ce, onRunsRetryLoadMore: le, runsHasMore: ue = !1, onRunsLoadMore: de, onRunClick: I, styles: L, className: me, backIcon: he, layout: z, historyStyles: _e }) => {
|
|
1143
|
+
let { colors: B, typography: V } = L ?? {}, H = V?.titleClassName ?? "dial-h2-text", be = V?.sectionTitleClassName ?? "dial-body-semi-text", Se = V?.fieldLabelClassName ?? "dial-tiny-text", U = V?.fieldValueClassName ?? "dial-small-text", Ce = V?.runTimestampClassName ?? "dial-small-text", we = _({
|
|
1144
|
+
"--stdv-bg": B?.background,
|
|
1145
|
+
"--stdv-header-border": B?.headerBorder,
|
|
1146
|
+
"--stdv-details-border": B?.detailsColumnBorder,
|
|
1147
|
+
"--stdv-subtitle-text": B?.subtitleText,
|
|
1148
|
+
"--stdv-history-bg": B?.historyCardBackground
|
|
1149
|
+
}), Ee = b(), [W, De] = Oe(rt.Details), Ae = Te(), je = o && !i ? e.startNowBusyLabel : void 0, Me = [
|
|
1158
1150
|
{
|
|
1159
|
-
id:
|
|
1151
|
+
id: rt.Details,
|
|
1160
1152
|
label: e.detailsTitle
|
|
1161
1153
|
},
|
|
1162
1154
|
{
|
|
1163
|
-
id:
|
|
1155
|
+
id: rt.Configuration,
|
|
1164
1156
|
label: e.configurationTitle
|
|
1165
1157
|
},
|
|
1166
1158
|
{
|
|
1167
|
-
id:
|
|
1159
|
+
id: rt.History,
|
|
1168
1160
|
label: e.historyTitle
|
|
1169
1161
|
}
|
|
1170
|
-
],
|
|
1162
|
+
], q = Me.find((e) => e.id === W)?.label ?? e.detailsTitle, Ne = /* @__PURE__ */ G(ct, {
|
|
1171
1163
|
labels: {
|
|
1172
1164
|
descriptionLabel: e.descriptionLabel,
|
|
1173
1165
|
modelLabel: e.modelLabel,
|
|
@@ -1180,9 +1172,9 @@ var Ne = {
|
|
|
1180
1172
|
repeatsLabel: w,
|
|
1181
1173
|
activeWindowLabel: E,
|
|
1182
1174
|
completedLabel: D,
|
|
1183
|
-
fieldLabelClassName:
|
|
1184
|
-
fieldValueClassName:
|
|
1185
|
-
}), Pe = /* @__PURE__ */ G(
|
|
1175
|
+
fieldLabelClassName: Se,
|
|
1176
|
+
fieldValueClassName: U
|
|
1177
|
+
}), Pe = /* @__PURE__ */ G(ot, {
|
|
1186
1178
|
instructionsLabel: e.instructionsLabel,
|
|
1187
1179
|
skillLabel: e.skillLabel,
|
|
1188
1180
|
skillDisplayNames: ne,
|
|
@@ -1195,12 +1187,13 @@ var Ne = {
|
|
|
1195
1187
|
tableScrollRegionAriaLabel: e.tableScrollRegionAriaLabel,
|
|
1196
1188
|
mathScrollRegionAriaLabel: e.mathScrollRegionAriaLabel
|
|
1197
1189
|
},
|
|
1198
|
-
fieldLabelClassName:
|
|
1199
|
-
}),
|
|
1190
|
+
fieldLabelClassName: Se
|
|
1191
|
+
}), J = (t) => /* @__PURE__ */ G(pt, {
|
|
1200
1192
|
variant: t,
|
|
1201
1193
|
labels: {
|
|
1202
1194
|
historyTitle: e.historyTitle,
|
|
1203
1195
|
historyEmptyLabel: e.historyEmptyLabel,
|
|
1196
|
+
historyEmptyDescription: e.historyEmptyDescription,
|
|
1204
1197
|
historyErrorLabel: e.historyErrorLabel,
|
|
1205
1198
|
historyLoadMoreErrorLabel: e.historyLoadMoreErrorLabel,
|
|
1206
1199
|
historyRetryLabel: e.historyRetryLabel,
|
|
@@ -1210,67 +1203,67 @@ var Ne = {
|
|
|
1210
1203
|
unreadIndicatorLabel: e.unreadIndicatorLabel
|
|
1211
1204
|
},
|
|
1212
1205
|
nextRunLabel: O,
|
|
1213
|
-
items:
|
|
1214
|
-
isLoading:
|
|
1215
|
-
isLoadingMore:
|
|
1216
|
-
skeletonCount:
|
|
1217
|
-
error:
|
|
1218
|
-
onRetry:
|
|
1206
|
+
items: re,
|
|
1207
|
+
isLoading: ae,
|
|
1208
|
+
isLoadingMore: oe,
|
|
1209
|
+
skeletonCount: se,
|
|
1210
|
+
error: N,
|
|
1211
|
+
onRetry: F,
|
|
1219
1212
|
loadMoreError: ce,
|
|
1220
1213
|
onRetryLoadMore: le,
|
|
1221
1214
|
hasMore: ue,
|
|
1222
|
-
onLoadMore:
|
|
1223
|
-
onRunClick:
|
|
1224
|
-
runTimestampClassName:
|
|
1225
|
-
sectionTitleClassName:
|
|
1226
|
-
colors:
|
|
1227
|
-
styles:
|
|
1215
|
+
onLoadMore: de,
|
|
1216
|
+
onRunClick: I,
|
|
1217
|
+
runTimestampClassName: Ce,
|
|
1218
|
+
sectionTitleClassName: be,
|
|
1219
|
+
colors: B,
|
|
1220
|
+
styles: _e
|
|
1228
1221
|
});
|
|
1229
1222
|
return /* @__PURE__ */ K("div", {
|
|
1230
|
-
style:
|
|
1231
|
-
className: v("flex h-full min-h-0 w-full flex-col overflow-hidden", $.container,
|
|
1223
|
+
style: we,
|
|
1224
|
+
className: v("flex h-full min-h-0 w-full flex-col overflow-hidden", $.container, me),
|
|
1232
1225
|
children: [
|
|
1233
1226
|
/* @__PURE__ */ K("div", {
|
|
1234
1227
|
className: v("flex min-h-16 shrink-0 items-start justify-between gap-2 px-4 py-2 desktop:h-16 desktop:flex-nowrap desktop:items-center desktop:px-8 desktop:py-0", $.header),
|
|
1235
1228
|
children: [/* @__PURE__ */ K("div", {
|
|
1236
1229
|
className: "flex min-w-0 items-center gap-2",
|
|
1237
1230
|
children: [
|
|
1238
|
-
/* @__PURE__ */ G(
|
|
1239
|
-
icon:
|
|
1231
|
+
/* @__PURE__ */ G(ie, {
|
|
1232
|
+
icon: he === void 0 ? /* @__PURE__ */ G(ge, {
|
|
1240
1233
|
size: k.LG,
|
|
1241
1234
|
className: "rtl:scale-x-[-1]",
|
|
1242
1235
|
"aria-hidden": !0,
|
|
1243
1236
|
stroke: A
|
|
1244
|
-
}) :
|
|
1237
|
+
}) : he,
|
|
1245
1238
|
"aria-label": e.backAriaLabel,
|
|
1246
1239
|
onClick: t
|
|
1247
1240
|
}),
|
|
1248
1241
|
/* @__PURE__ */ G("h1", {
|
|
1249
|
-
className: v("truncate", $.desktopTitle,
|
|
1242
|
+
className: v("truncate", $.desktopTitle, H),
|
|
1250
1243
|
children: g
|
|
1251
1244
|
}),
|
|
1252
1245
|
l && /* @__PURE__ */ G("span", {
|
|
1253
|
-
className: v("shrink-0", $.desktopBadge,
|
|
1246
|
+
className: v("shrink-0", $.desktopBadge, U, $.subtitleText),
|
|
1254
1247
|
children: e.deletedStateLabel
|
|
1255
1248
|
})
|
|
1256
1249
|
]
|
|
1257
1250
|
}), /* @__PURE__ */ K("div", {
|
|
1258
1251
|
className: v("flex min-w-0 flex-1 flex-wrap items-center justify-end gap-2 desktop:flex-none desktop:flex-nowrap", $.headerActions),
|
|
1259
1252
|
children: [
|
|
1260
|
-
!l && !u && d !== void 0 && /* @__PURE__ */ K(
|
|
1253
|
+
!l && !u && d !== void 0 && /* @__PURE__ */ K(ke, { children: [/* @__PURE__ */ G(R, {
|
|
1261
1254
|
id: "scheduled-task-active-switch",
|
|
1262
1255
|
labelProps: { label: e.activeStatusLabel },
|
|
1263
1256
|
isOn: d,
|
|
1264
1257
|
disabled: f || p || c,
|
|
1265
1258
|
onChange: (e) => h?.(e)
|
|
1266
1259
|
}), p && m && /* @__PURE__ */ G("span", {
|
|
1267
|
-
className: v(
|
|
1260
|
+
className: v(U, $.subtitleText),
|
|
1268
1261
|
children: m
|
|
1269
1262
|
})] }),
|
|
1270
|
-
!l && s && /* @__PURE__ */ G(
|
|
1263
|
+
!l && s && /* @__PURE__ */ G(M, {
|
|
1271
1264
|
variant: T.Danger,
|
|
1272
1265
|
label: e.deleteButtonLabel,
|
|
1273
|
-
iconBefore: /* @__PURE__ */ G(
|
|
1266
|
+
iconBefore: /* @__PURE__ */ G(xe, {
|
|
1274
1267
|
size: k.SM,
|
|
1275
1268
|
"aria-hidden": !0,
|
|
1276
1269
|
stroke: A
|
|
@@ -1280,9 +1273,9 @@ var Ne = {
|
|
|
1280
1273
|
textClassName: $.actionLabel,
|
|
1281
1274
|
className: v("min-h-11 shrink-0", $.actionButton)
|
|
1282
1275
|
}),
|
|
1283
|
-
!l && n && /* @__PURE__ */ G(
|
|
1276
|
+
!l && n && /* @__PURE__ */ G(P, {
|
|
1284
1277
|
label: e.editButtonLabel,
|
|
1285
|
-
iconBefore: /* @__PURE__ */ G(
|
|
1278
|
+
iconBefore: /* @__PURE__ */ G(ve, {
|
|
1286
1279
|
size: k.SM,
|
|
1287
1280
|
"aria-hidden": !0,
|
|
1288
1281
|
stroke: A
|
|
@@ -1295,19 +1288,19 @@ var Ne = {
|
|
|
1295
1288
|
!l && r && e.startNowButtonLabel && /* @__PURE__ */ K("div", {
|
|
1296
1289
|
"aria-busy": i,
|
|
1297
1290
|
children: [je && /* @__PURE__ */ G("span", {
|
|
1298
|
-
id:
|
|
1291
|
+
id: Ae,
|
|
1299
1292
|
className: "sr-only",
|
|
1300
1293
|
children: je
|
|
1301
|
-
}), /* @__PURE__ */ G(
|
|
1294
|
+
}), /* @__PURE__ */ G(P, {
|
|
1302
1295
|
label: i ? e.startingLabel ?? e.startNowButtonLabel : e.startNowButtonLabel,
|
|
1303
|
-
iconBefore: /* @__PURE__ */ G(
|
|
1296
|
+
iconBefore: /* @__PURE__ */ G(ye, {
|
|
1304
1297
|
size: k.SM,
|
|
1305
1298
|
"aria-hidden": !0,
|
|
1306
1299
|
stroke: A
|
|
1307
1300
|
}),
|
|
1308
1301
|
onClick: r,
|
|
1309
1302
|
disabled: c || i || a || o,
|
|
1310
|
-
"aria-describedby": je ?
|
|
1303
|
+
"aria-describedby": je ? Ae : void 0,
|
|
1311
1304
|
tooltipProps: je ? { tooltip: je } : void 0,
|
|
1312
1305
|
textClassName: $.actionLabel,
|
|
1313
1306
|
className: v("min-h-11 shrink-0", $.actionButton, $.roundActionButton)
|
|
@@ -1319,10 +1312,10 @@ var Ne = {
|
|
|
1319
1312
|
/* @__PURE__ */ K("div", {
|
|
1320
1313
|
className: v("min-w-0 items-center gap-2 px-4 py-3", $.mobileTitleRow),
|
|
1321
1314
|
children: [/* @__PURE__ */ G("h1", {
|
|
1322
|
-
className: v("truncate",
|
|
1315
|
+
className: v("truncate", H),
|
|
1323
1316
|
children: g
|
|
1324
1317
|
}), l && /* @__PURE__ */ G("span", {
|
|
1325
|
-
className: v("shrink-0",
|
|
1318
|
+
className: v("shrink-0", U, $.subtitleText),
|
|
1326
1319
|
children: e.deletedStateLabel
|
|
1327
1320
|
})]
|
|
1328
1321
|
}),
|
|
@@ -1340,14 +1333,14 @@ var Ne = {
|
|
|
1340
1333
|
}),
|
|
1341
1334
|
y && /* @__PURE__ */ G("div", {
|
|
1342
1335
|
className: "flex flex-1 items-center justify-center",
|
|
1343
|
-
children: /* @__PURE__ */ G(
|
|
1336
|
+
children: /* @__PURE__ */ G(fe, {})
|
|
1344
1337
|
}),
|
|
1345
1338
|
!y && x && /* @__PURE__ */ K("div", {
|
|
1346
1339
|
className: "flex flex-1 flex-col items-center justify-center gap-3",
|
|
1347
1340
|
children: [/* @__PURE__ */ G("p", {
|
|
1348
|
-
className: v(
|
|
1341
|
+
className: v(U, $.subtitleText),
|
|
1349
1342
|
children: e.errorLabel
|
|
1350
|
-
}), /* @__PURE__ */ G(
|
|
1343
|
+
}), /* @__PURE__ */ G(M, {
|
|
1351
1344
|
label: e.retryLabel,
|
|
1352
1345
|
onClick: ee
|
|
1353
1346
|
})]
|
|
@@ -1360,22 +1353,22 @@ var Ne = {
|
|
|
1360
1353
|
ariaLabel: e.tabsAriaLabel ?? "Scheduled task sections",
|
|
1361
1354
|
className: "px-4",
|
|
1362
1355
|
tabs: Me,
|
|
1363
|
-
activeTabId:
|
|
1364
|
-
onTabChange:
|
|
1356
|
+
activeTabId: W,
|
|
1357
|
+
onTabChange: De
|
|
1365
1358
|
})
|
|
1366
1359
|
}), /* @__PURE__ */ G("div", {
|
|
1367
1360
|
role: "tabpanel",
|
|
1368
|
-
"aria-label":
|
|
1361
|
+
"aria-label": q,
|
|
1369
1362
|
className: "flex flex-1 flex-col gap-5 px-4 py-6",
|
|
1370
|
-
children:
|
|
1363
|
+
children: W === rt.Configuration ? Pe : W === rt.History ? J(it.Flow) : Ne
|
|
1371
1364
|
})]
|
|
1372
1365
|
}) : /* @__PURE__ */ K("div", {
|
|
1373
1366
|
style: {
|
|
1374
1367
|
flexDirection: "row",
|
|
1375
|
-
"--st-details-width":
|
|
1376
|
-
"--st-history-width":
|
|
1377
|
-
"--st-history-max-height":
|
|
1378
|
-
"--st-configuration-min-width":
|
|
1368
|
+
"--st-details-width": z?.detailsWidth,
|
|
1369
|
+
"--st-history-width": z?.historyWidth,
|
|
1370
|
+
"--st-history-max-height": z?.historyMaxHeight,
|
|
1371
|
+
"--st-configuration-min-width": z?.configurationMinWidth
|
|
1379
1372
|
},
|
|
1380
1373
|
className: "flex min-h-0 flex-1 overflow-y-auto desktop:overflow-hidden",
|
|
1381
1374
|
children: [
|
|
@@ -1383,39 +1376,39 @@ var Ne = {
|
|
|
1383
1376
|
role: "group",
|
|
1384
1377
|
"aria-label": e.detailsTitle,
|
|
1385
1378
|
style: {
|
|
1386
|
-
flex: `0 1 ${
|
|
1379
|
+
flex: `0 1 ${z?.detailsWidth ?? "360px"}`,
|
|
1387
1380
|
maxWidth: "100%"
|
|
1388
1381
|
},
|
|
1389
1382
|
className: v("flex min-h-0 w-full flex-col gap-5 overflow-y-auto border-e px-8 py-6", $.detailsColumn),
|
|
1390
1383
|
children: [/* @__PURE__ */ G("h2", {
|
|
1391
|
-
className:
|
|
1384
|
+
className: be,
|
|
1392
1385
|
children: e.detailsTitle
|
|
1393
|
-
}),
|
|
1386
|
+
}), Ne]
|
|
1394
1387
|
}),
|
|
1395
1388
|
/* @__PURE__ */ K("div", {
|
|
1396
1389
|
style: {
|
|
1397
|
-
flex: `1 1 ${
|
|
1390
|
+
flex: `1 1 ${z?.configurationMinWidth ?? "320px"}`,
|
|
1398
1391
|
minWidth: 0
|
|
1399
1392
|
},
|
|
1400
1393
|
className: "flex min-h-0 w-full min-w-0 flex-col gap-5 overflow-y-auto px-8 py-6",
|
|
1401
1394
|
children: [/* @__PURE__ */ G("h2", {
|
|
1402
|
-
className:
|
|
1395
|
+
className: be,
|
|
1403
1396
|
children: e.configurationTitle
|
|
1404
1397
|
}), Pe]
|
|
1405
1398
|
}),
|
|
1406
1399
|
/* @__PURE__ */ G("div", {
|
|
1407
1400
|
style: {
|
|
1408
|
-
flex: `0 1 calc(${
|
|
1401
|
+
flex: `0 1 calc(${z?.historyWidth ?? "360px"} + 48px)`,
|
|
1409
1402
|
minWidth: 0
|
|
1410
1403
|
},
|
|
1411
1404
|
className: "flex min-h-0 w-full items-start justify-center overflow-y-auto p-6",
|
|
1412
|
-
children:
|
|
1405
|
+
children: J(it.Card)
|
|
1413
1406
|
})
|
|
1414
1407
|
]
|
|
1415
1408
|
}))
|
|
1416
1409
|
]
|
|
1417
1410
|
});
|
|
1418
|
-
},
|
|
1411
|
+
}, ht = {
|
|
1419
1412
|
h1: "dial-small-semi-text mb-3 mt-6 first:mt-0 [text-wrap:balance]",
|
|
1420
1413
|
h2: "dial-small-semi-text mb-2 mt-5 first:mt-0 [text-wrap:balance]",
|
|
1421
1414
|
h3: "dial-small-semi-text mb-2 mt-4 first:mt-0 [text-wrap:balance]",
|
|
@@ -1430,7 +1423,7 @@ var Ne = {
|
|
|
1430
1423
|
link: "break-words [overflow-wrap:anywhere]",
|
|
1431
1424
|
tableWrapper: "my-4",
|
|
1432
1425
|
mathBlock: "my-4"
|
|
1433
|
-
},
|
|
1426
|
+
}, gt = ({ modelLabel: e, skillLabel: t, skillDisplayNames: n, instructionsLabel: r, modelDisplayName: i, instructionsMarkdown: a, renderInstructions: o, instructionsClassNames: s = ht, markdownLabels: c, styles: l }) => {
|
|
1434
1427
|
let u = l?.typography?.fieldLabelClassName ?? "dial-tiny-text text-secondary", d = l?.typography?.fieldValueClassName ?? "dial-small-text";
|
|
1435
1428
|
return /* @__PURE__ */ K("div", {
|
|
1436
1429
|
className: "flex flex-col gap-3",
|
|
@@ -1471,17 +1464,17 @@ var Ne = {
|
|
|
1471
1464
|
})
|
|
1472
1465
|
]
|
|
1473
1466
|
});
|
|
1474
|
-
},
|
|
1467
|
+
}, _t = ({ className: e, children: t }) => /* @__PURE__ */ G("span", {
|
|
1475
1468
|
className: v(e, "block truncate py-1"),
|
|
1476
1469
|
children: t
|
|
1477
|
-
}),
|
|
1478
|
-
let [g, _] =
|
|
1479
|
-
|
|
1470
|
+
}), vt = ({ scheduleId: e, items: t, isLoading: n = !1, isLoadingMore: r = !1, skeletonCount: i = 6, error: a, onRetry: o, isUnavailable: s = !1, hasMore: c = !1, onLoadMore: l, currentRunId: u, onRunClick: d, labels: f, titleClassName: p = "dial-tiny-semi-text", contentClassName: m = "ps-3", unavailableTextClassName: h = "dial-body-text text-secondary" }) => {
|
|
1471
|
+
let [g, _] = Oe(!0);
|
|
1472
|
+
we(() => {
|
|
1480
1473
|
_(!0);
|
|
1481
1474
|
}, [e]);
|
|
1482
1475
|
let v = c && !n && l && f.showMoreLabel ? /* @__PURE__ */ G("li", {
|
|
1483
1476
|
className: "pt-2",
|
|
1484
|
-
children: /* @__PURE__ */ G(
|
|
1477
|
+
children: /* @__PURE__ */ G(M, {
|
|
1485
1478
|
variant: T.Primary,
|
|
1486
1479
|
label: f.showMoreLabel,
|
|
1487
1480
|
onClick: l,
|
|
@@ -1489,7 +1482,7 @@ var Ne = {
|
|
|
1489
1482
|
})
|
|
1490
1483
|
}) : void 0;
|
|
1491
1484
|
return /* @__PURE__ */ G(S, {
|
|
1492
|
-
title: /* @__PURE__ */ G(
|
|
1485
|
+
title: /* @__PURE__ */ G(_t, {
|
|
1493
1486
|
className: p,
|
|
1494
1487
|
children: f.title
|
|
1495
1488
|
}),
|
|
@@ -1500,7 +1493,7 @@ var Ne = {
|
|
|
1500
1493
|
role: "alert",
|
|
1501
1494
|
className: h,
|
|
1502
1495
|
children: f.unavailableLabel
|
|
1503
|
-
}) : /* @__PURE__ */ G(
|
|
1496
|
+
}) : /* @__PURE__ */ G(dt, {
|
|
1504
1497
|
items: t,
|
|
1505
1498
|
isLoading: n,
|
|
1506
1499
|
isLoadingMore: r,
|
|
@@ -1521,11 +1514,11 @@ var Ne = {
|
|
|
1521
1514
|
}
|
|
1522
1515
|
})
|
|
1523
1516
|
});
|
|
1524
|
-
},
|
|
1517
|
+
}, yt = /* @__PURE__ */ function(e) {
|
|
1525
1518
|
return e.Ready = "ready", e.Error = "error", e.Unavailable = "unavailable", e;
|
|
1526
|
-
}({}),
|
|
1527
|
-
let [p, m] =
|
|
1528
|
-
|
|
1519
|
+
}({}), bt = ({ scheduleId: e, state: t, onRetry: n, modelDisplayName: r, skillDisplayNames: i, instructionsMarkdown: a, renderInstructions: o, instructionsClassNames: s, markdownLabels: c, summaryStyles: l, labels: u, titleClassName: d = "dial-tiny-semi-text", unavailableTextClassName: f = "dial-body-text text-secondary" }) => {
|
|
1520
|
+
let [p, m] = Oe(!1);
|
|
1521
|
+
we(() => {
|
|
1529
1522
|
m(!1);
|
|
1530
1523
|
}, [e]);
|
|
1531
1524
|
let h = t === "error" || t === "unavailable" ? /* @__PURE__ */ K("div", {
|
|
@@ -1534,11 +1527,11 @@ var Ne = {
|
|
|
1534
1527
|
role: "alert",
|
|
1535
1528
|
className: f,
|
|
1536
1529
|
children: u.unavailableLabel
|
|
1537
|
-
}), t === "error" && n && /* @__PURE__ */ G(
|
|
1530
|
+
}), t === "error" && n && /* @__PURE__ */ G(M, {
|
|
1538
1531
|
label: u.retryLabel,
|
|
1539
1532
|
onClick: n
|
|
1540
1533
|
})]
|
|
1541
|
-
}) : /* @__PURE__ */ G(
|
|
1534
|
+
}) : /* @__PURE__ */ G(gt, {
|
|
1542
1535
|
modelLabel: u.modelLabel,
|
|
1543
1536
|
instructionsLabel: u.instructionsLabel,
|
|
1544
1537
|
skillLabel: u.skillLabel,
|
|
@@ -1551,7 +1544,7 @@ var Ne = {
|
|
|
1551
1544
|
styles: l
|
|
1552
1545
|
});
|
|
1553
1546
|
return /* @__PURE__ */ G(S, {
|
|
1554
|
-
title: /* @__PURE__ */ G(
|
|
1547
|
+
title: /* @__PURE__ */ G(_t, {
|
|
1555
1548
|
className: d,
|
|
1556
1549
|
children: u.title
|
|
1557
1550
|
}),
|
|
@@ -1559,7 +1552,7 @@ var Ne = {
|
|
|
1559
1552
|
onToggle: m,
|
|
1560
1553
|
children: h
|
|
1561
1554
|
});
|
|
1562
|
-
},
|
|
1555
|
+
}, xt = ({ taskName: e, icon: t, typeLabel: n, body: r, pendingLabel: i, isDeleting: a = !1, styles: o, ...s }) => /* @__PURE__ */ G(l, {
|
|
1563
1556
|
...s,
|
|
1564
1557
|
variant: te.Danger,
|
|
1565
1558
|
popupClassName: o?.popupClassName,
|
|
@@ -1584,4 +1577,4 @@ var Ne = {
|
|
|
1584
1577
|
})
|
|
1585
1578
|
});
|
|
1586
1579
|
//#endregion
|
|
1587
|
-
export { c as DESCRIPTION_MAX_LENGTH,
|
|
1580
|
+
export { c as DESCRIPTION_MAX_LENGTH, Me as SCHEDULED_TASKS_CLASS, Le as ScheduledTaskCard, He as ScheduledTaskCardGrid, Ve as ScheduledTaskCardSkeleton, bt as ScheduledTaskConversationDetailsSection, yt as ScheduledTaskConversationDetailsState, vt as ScheduledTaskConversationHistorySection, nt as ScheduledTaskCreateForm, xt as ScheduledTaskDeleteConfirmation, mt as ScheduledTaskDetailView, gt as ScheduledTaskDetailsSummary, pt as ScheduledTaskHistorySection, Ne as ScheduledTaskPresentationStatus, r as ScheduledTaskRepeat, dt as ScheduledTaskRunHistoryList, lt as ScheduledTaskRunStatus, q as ScheduledTaskStatus, Ge as ScheduledTasks, Ke as ScheduledTasksSortKey, s as TIME_OF_DAY_PATTERN, Pe as getScheduledTaskStatus, Je as hasScheduledTaskFormChanges };
|