@epam/ai-dial-scheduled-tasks 1.2.0-dev.98 → 1.2.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/ScheduledTaskCard/ScheduledTaskCard.d.ts +6 -5
- package/components/ScheduledTaskCard/ScheduledTaskCard.d.ts.map +1 -1
- package/components/ScheduledTaskConfigurationSection/ScheduledTaskConfigurationSection.d.ts +1 -1
- package/components/ScheduledTaskConfigurationSection/ScheduledTaskConfigurationSection.d.ts.map +1 -1
- package/components/ScheduledTaskCreateForm/ScheduledTaskCreateForm.d.ts.map +1 -1
- package/components/ScheduledTaskDeleteConfirmation/ScheduledTaskDeleteConfirmation.d.ts +39 -7
- package/components/ScheduledTaskDeleteConfirmation/ScheduledTaskDeleteConfirmation.d.ts.map +1 -1
- package/components/ScheduledTaskDetailView/ScheduledTaskDetailView.d.ts.map +1 -1
- package/components/ScheduledTaskDetailsSection/ScheduledTaskDetailsSection.d.ts.map +1 -1
- package/components/ScheduledTaskDetailsSummary/ScheduledTaskDetailsSummary.d.ts.map +1 -1
- package/components/ScheduledTaskHistorySection/ScheduledTaskHistorySection.d.ts.map +1 -1
- package/components/ScheduledTaskRunAtField/ScheduledTaskRunAtField.d.ts.map +1 -1
- package/components/ScheduledTaskRunHistoryList/ScheduledTaskRunHistoryList.d.ts.map +1 -1
- package/components/ScheduledTaskStatusPill/ScheduledTaskStatusPill.d.ts +16 -0
- package/components/ScheduledTaskStatusPill/ScheduledTaskStatusPill.d.ts.map +1 -0
- package/components/ScheduledTasks/ScheduledTasks.d.ts.map +1 -1
- package/constants/public-class-names.d.ts +2 -0
- package/constants/public-class-names.d.ts.map +1 -1
- package/index.css +2 -2
- package/index.d.ts +5 -1
- package/index.d.ts.map +1 -1
- package/index.js +855 -659
- package/models/scheduled-task-card-props.d.ts +6 -5
- package/models/scheduled-task-card-props.d.ts.map +1 -1
- package/models/scheduled-task-configuration-section-props.d.ts +7 -0
- package/models/scheduled-task-configuration-section-props.d.ts.map +1 -1
- package/models/scheduled-task-create-form-props.d.ts +36 -2
- package/models/scheduled-task-create-form-props.d.ts.map +1 -1
- package/models/scheduled-task-detail-view-props.d.ts +32 -3
- package/models/scheduled-task-detail-view-props.d.ts.map +1 -1
- package/models/scheduled-task-details-section-props.d.ts +4 -0
- package/models/scheduled-task-details-section-props.d.ts.map +1 -1
- package/models/scheduled-task-details-summary-props.d.ts +7 -0
- package/models/scheduled-task-details-summary-props.d.ts.map +1 -1
- package/models/scheduled-task-history-section-props.d.ts +6 -0
- package/models/scheduled-task-history-section-props.d.ts.map +1 -1
- package/models/scheduled-task-instructions.d.ts +18 -0
- package/models/scheduled-task-instructions.d.ts.map +1 -0
- package/models/scheduled-task-item.d.ts +14 -1
- package/models/scheduled-task-item.d.ts.map +1 -1
- package/models/scheduled-task-run-history-list-props.d.ts +5 -0
- package/models/scheduled-task-run-history-list-props.d.ts.map +1 -1
- package/package.json +4 -4
- package/types/scheduled-task-status.d.ts +15 -0
- package/types/scheduled-task-status.d.ts.map +1 -0
- package/utils/scheduled-task-form-values.d.ts +4 -0
- package/utils/scheduled-task-form-values.d.ts.map +1 -0
- package/utils/scheduled-task-status.d.ts +5 -0
- package/utils/scheduled-task-status.d.ts.map +1 -0
- package/validation/index.d.ts +2 -2
- package/validation/index.d.ts.map +1 -1
- package/validation/scheduled-task-validation.d.ts +30 -2
- package/validation/scheduled-task-validation.d.ts.map +1 -1
- package/validation.js +24 -11
package/index.js
CHANGED
|
@@ -1,33 +1,89 @@
|
|
|
1
1
|
import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, t as c } from "./calendar-value-B41Uk26Z.js";
|
|
2
|
-
import {
|
|
3
|
-
import { ButtonAppearance as
|
|
4
|
-
import { IconAlertTriangle as
|
|
5
|
-
import { Suspense as
|
|
6
|
-
import { Fragment as
|
|
7
|
-
import { BuilderFormContainer as
|
|
8
|
-
import { LazyMarkdownEditor as
|
|
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 S } from "@epam/ai-dial-chat-shared";
|
|
3
|
+
import { ButtonAppearance as ee, ButtonDropdown as te, ButtonVariant as ne, Calendar as C, CalendarMode as w, CardShell as T, ConfirmationPopupVariant as E, DIAL_ICON_SIZE as D, DIAL_KIT_ICON_STROKE as O, ElementSize as re, FolderPath as ie, GhostButton as k, GhostIconButton as ae, Highlight as oe, Input as se, Label as ce, MenuItemMark as le, NeutralButton as ue, NumberInput as de, PrimaryButton as fe, Search as A, Select as pe, Skeleton as j, SkeletonVariant as M, Spinner as me, Switch as he, Tabs as ge, Textarea as _e } from "@epam/ai-dial-ui-kit";
|
|
4
|
+
import { IconAlertTriangle as ve, IconArrowNarrowLeft as ye, IconArrowsSort as N, IconCheck as be, IconCircleCheck as xe, IconCircleX as P, IconClipboardX as Se, IconClockHour3 as F, IconPencilMinus as Ce, IconPlayerPause as I, IconPlayerPlay as L, IconPlus as R, IconTrashX as we } from "@tabler/icons-react";
|
|
5
|
+
import { Suspense as Te, lazy as Ee, useCallback as z, useEffect as De, useId as Oe, useLayoutEffect as ke, useMemo as Ae, useRef as B, useState as je } from "react";
|
|
6
|
+
import { Fragment as Me, jsx as V, jsxs as H } from "react/jsx-runtime";
|
|
7
|
+
import { BuilderFormContainer as Ne } from "@epam/ai-dial-builder-form";
|
|
8
|
+
import { LazyMarkdownEditor as U } from "@epam/ai-dial-ui-kit/editors";
|
|
9
9
|
//#region src/constants/public-class-names.ts
|
|
10
|
-
var
|
|
10
|
+
var W = {
|
|
11
11
|
card: "dial-scheduled-tasks-card",
|
|
12
|
-
cardGrid: "dial-scheduled-tasks-card-grid"
|
|
13
|
-
|
|
12
|
+
cardGrid: "dial-scheduled-tasks-card-grid",
|
|
13
|
+
refineFeedback: "dial-scheduled-tasks-refine-feedback"
|
|
14
|
+
}, G = /* @__PURE__ */ function(e) {
|
|
15
|
+
return e.Scheduled = "scheduled", e.Paused = "paused", e.Completed = "completed", e;
|
|
16
|
+
}({}), K = /* @__PURE__ */ function(e) {
|
|
14
17
|
return e.Active = "active", e.Paused = "paused", e.Completed = "completed", e;
|
|
15
|
-
}({}),
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
18
|
+
}({}), Pe = (e) => {
|
|
19
|
+
switch (e.presentationStatus) {
|
|
20
|
+
case K.Active: return G.Scheduled;
|
|
21
|
+
case K.Paused: return G.Paused;
|
|
22
|
+
case K.Completed: return G.Completed;
|
|
23
|
+
}
|
|
24
|
+
return e.isCompleted ? G.Completed : e.isActive === !1 ? G.Paused : G.Scheduled;
|
|
25
|
+
}, q = {
|
|
26
|
+
schedulePill: "_schedulePill_146jw_1",
|
|
27
|
+
scheduleLabel: "_scheduleLabel_146jw_6",
|
|
28
|
+
pausedPill: "_pausedPill_146jw_10",
|
|
29
|
+
pausedLabel: "_pausedLabel_146jw_15",
|
|
30
|
+
completedPill: "_completedPill_146jw_19",
|
|
31
|
+
completedLabel: "_completedLabel_146jw_24"
|
|
32
|
+
}, J = {
|
|
33
|
+
[G.Scheduled]: {
|
|
34
|
+
pillClassName: "inline-block rounded-lg border px-2 py-1",
|
|
35
|
+
wrapperClassName: q.schedulePill,
|
|
36
|
+
labelClassName: q.scheduleLabel
|
|
37
|
+
},
|
|
38
|
+
[G.Paused]: {
|
|
39
|
+
pillClassName: "inline-flex items-center gap-1.5 rounded-full border px-2 py-1",
|
|
40
|
+
wrapperClassName: q.pausedPill,
|
|
41
|
+
labelClassName: q.pausedLabel,
|
|
42
|
+
renderIcon: () => /* @__PURE__ */ V(I, {
|
|
43
|
+
size: D.SM,
|
|
44
|
+
"aria-hidden": !0,
|
|
45
|
+
stroke: O
|
|
46
|
+
})
|
|
47
|
+
},
|
|
48
|
+
[G.Completed]: {
|
|
49
|
+
pillClassName: "inline-flex items-center gap-1.5 rounded-full border px-2 py-1",
|
|
50
|
+
wrapperClassName: q.completedPill,
|
|
51
|
+
labelClassName: q.completedLabel,
|
|
52
|
+
renderIcon: () => /* @__PURE__ */ V(be, {
|
|
53
|
+
size: D.SM,
|
|
54
|
+
"aria-hidden": !0,
|
|
55
|
+
stroke: O
|
|
56
|
+
})
|
|
57
|
+
}
|
|
58
|
+
}, Fe = ({ status: e, text: t, textClassName: n = "dial-tiny-text", className: r }) => {
|
|
59
|
+
let { pillClassName: i, wrapperClassName: a, labelClassName: o, renderIcon: s } = J[e];
|
|
60
|
+
return /* @__PURE__ */ H("span", {
|
|
61
|
+
className: v(i, n, a, o, r),
|
|
62
|
+
children: [s && s(), t]
|
|
63
|
+
});
|
|
64
|
+
}, Y = {
|
|
65
|
+
title: "_title_ogabr_1",
|
|
66
|
+
description: "_description_ogabr_5",
|
|
67
|
+
locationLabel: "_locationLabel_ogabr_9",
|
|
68
|
+
locationLeaf: "_locationLeaf_ogabr_13",
|
|
69
|
+
newBadge: "_newBadge_ogabr_17",
|
|
70
|
+
locationDivider: "_locationDivider_ogabr_22"
|
|
71
|
+
}, Ie = ({ item: e, searchQuery: t = "", onCardClick: n, labels: r, styles: i, className: a }) => {
|
|
72
|
+
let o = r?.newBadgeLabel ?? "NEW", s = r?.pausedBadgeLabel ?? "Paused", c = r?.completedBadgeLabel ?? "Completed", { colors: l, typography: u } = i ?? {}, d = u?.titleClassName ?? "dial-body-semi-text", f = u?.descriptionClassName ?? "dial-small-text", p = u?.descriptionSizeClassName ?? "dial-tiny-text", m = u?.scheduleLabelClassName ?? "dial-tiny-text", h = u?.pausedBadgeClassName ?? "dial-tiny-text", g = u?.completedBadgeClassName ?? "dial-tiny-text", y = u?.locationLabelClassName ?? "dial-tiny-text", b = u?.locationLeafClassName ?? "dial-tiny-semi-text", x = u?.newBadgeClassName ?? "dial-tiny-semi-text", S = Pe(e), { text: ee, textClassName: te } = {
|
|
73
|
+
[G.Scheduled]: {
|
|
74
|
+
text: e.scheduleLabel,
|
|
75
|
+
textClassName: m
|
|
76
|
+
},
|
|
77
|
+
[G.Paused]: {
|
|
78
|
+
text: s,
|
|
79
|
+
textClassName: h
|
|
80
|
+
},
|
|
81
|
+
[G.Completed]: {
|
|
82
|
+
text: c,
|
|
83
|
+
textClassName: g
|
|
84
|
+
}
|
|
85
|
+
}[S], ne = _({
|
|
86
|
+
"--stc-title-text": l?.titleText,
|
|
31
87
|
"--stc-desc-text": l?.descriptionText,
|
|
32
88
|
"--stc-pill-bg": l?.schedulePillBackground,
|
|
33
89
|
"--stc-pill-border": l?.schedulePillBorder,
|
|
@@ -43,97 +99,88 @@ var Ce = {
|
|
|
43
99
|
"--stc-completed-bg": l?.completedBadgeBackground,
|
|
44
100
|
"--stc-completed-border": l?.completedBadgeBorder,
|
|
45
101
|
"--stc-completed-text": l?.completedBadgeText
|
|
46
|
-
}),
|
|
102
|
+
}), C = n ? {
|
|
47
103
|
tabIndex: 0,
|
|
48
104
|
onClick: () => n(e.id),
|
|
49
105
|
onKeyDown: (t) => {
|
|
50
106
|
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), n(e.id));
|
|
51
107
|
}
|
|
52
108
|
} : {};
|
|
53
|
-
return /* @__PURE__ */
|
|
109
|
+
return /* @__PURE__ */ H(T, {
|
|
54
110
|
role: n ? "button" : "group",
|
|
55
111
|
"aria-label": e.displayName,
|
|
56
|
-
style:
|
|
57
|
-
className:
|
|
58
|
-
...
|
|
112
|
+
style: ne,
|
|
113
|
+
className: v("h-[var(--st-card-height,232px)]", n && "cursor-pointer", a, W.card),
|
|
114
|
+
...C,
|
|
59
115
|
children: [
|
|
60
|
-
/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ H("div", {
|
|
61
117
|
className: "flex min-w-0 shrink-0 items-center gap-2",
|
|
62
|
-
children: [/* @__PURE__ */
|
|
118
|
+
children: [/* @__PURE__ */ V(oe, {
|
|
63
119
|
text: e.displayName,
|
|
64
120
|
query: t,
|
|
65
121
|
maxLines: 1,
|
|
66
|
-
className:
|
|
67
|
-
}), e.isNew && /* @__PURE__ */
|
|
68
|
-
className:
|
|
122
|
+
className: v(d, Y.title)
|
|
123
|
+
}), e.isNew && /* @__PURE__ */ V("span", {
|
|
124
|
+
className: v("shrink-0 rounded-full px-2 py-0.5", x, Y.newBadge),
|
|
69
125
|
children: o
|
|
70
126
|
})]
|
|
71
127
|
}),
|
|
72
|
-
e.descriptionPreview && /* @__PURE__ */
|
|
73
|
-
className:
|
|
128
|
+
e.descriptionPreview && /* @__PURE__ */ V("p", {
|
|
129
|
+
className: v("line-clamp-4 min-h-0 flex-1 overflow-hidden", p, f, Y.description),
|
|
74
130
|
children: e.descriptionPreview
|
|
75
131
|
}),
|
|
76
|
-
/* @__PURE__ */
|
|
132
|
+
/* @__PURE__ */ H("div", {
|
|
77
133
|
className: "mt-auto flex shrink-0 flex-col gap-3",
|
|
78
|
-
children: [/* @__PURE__ */
|
|
134
|
+
children: [/* @__PURE__ */ V("div", {
|
|
79
135
|
className: "flex min-h-[28px] items-center",
|
|
80
|
-
children:
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
"aria-hidden": !0,
|
|
85
|
-
stroke: w
|
|
86
|
-
}), s]
|
|
87
|
-
}) : T === K.Completed ? /* @__PURE__ */ W("span", {
|
|
88
|
-
className: m("inline-flex items-center rounded-full border px-2 py-1", q.completedPill, x, q.completedLabel),
|
|
89
|
-
children: c
|
|
90
|
-
}) : /* @__PURE__ */ W("span", {
|
|
91
|
-
className: m("inline-block rounded-lg border px-2 py-1", q.schedulePill, g, q.scheduleLabel),
|
|
92
|
-
children: e.scheduleLabel
|
|
136
|
+
children: /* @__PURE__ */ V(Fe, {
|
|
137
|
+
status: S,
|
|
138
|
+
text: ee,
|
|
139
|
+
textClassName: te
|
|
93
140
|
})
|
|
94
|
-
}), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */
|
|
141
|
+
}), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ V(ie, {
|
|
95
142
|
segments: e.locationSegments,
|
|
96
|
-
labelClassName:
|
|
97
|
-
leafClassName:
|
|
98
|
-
className:
|
|
143
|
+
labelClassName: v(y, Y.locationLabel),
|
|
144
|
+
leafClassName: v(b, Y.locationLeaf),
|
|
145
|
+
className: v("pt-3", Y.locationDivider)
|
|
99
146
|
})]
|
|
100
147
|
})
|
|
101
148
|
]
|
|
102
149
|
});
|
|
103
|
-
},
|
|
150
|
+
}, Le = { card: "_card_11bez_1" }, Re = [
|
|
104
151
|
"100%",
|
|
105
152
|
"100%",
|
|
106
153
|
"61%"
|
|
107
|
-
],
|
|
154
|
+
], ze = "var(--stcs-skeleton-bg)", Be = ({ styles: e }) => /* @__PURE__ */ H(T, {
|
|
108
155
|
"aria-hidden": !0,
|
|
109
|
-
style:
|
|
110
|
-
className:
|
|
156
|
+
style: _({ "--stcs-skeleton-bg": e?.colors?.skeletonColor }),
|
|
157
|
+
className: v("h-[var(--st-card-height,232px)]", Le.card),
|
|
111
158
|
children: [
|
|
112
|
-
/* @__PURE__ */
|
|
113
|
-
variant:
|
|
159
|
+
/* @__PURE__ */ V(j, {
|
|
160
|
+
variant: M.Rectangular,
|
|
114
161
|
width: "60%",
|
|
115
162
|
height: "20px",
|
|
116
|
-
color:
|
|
163
|
+
color: ze,
|
|
117
164
|
className: "shrink-0"
|
|
118
165
|
}),
|
|
119
|
-
/* @__PURE__ */
|
|
166
|
+
/* @__PURE__ */ V("div", {
|
|
120
167
|
className: "flex min-h-0 flex-1 flex-col gap-3 overflow-hidden",
|
|
121
|
-
children:
|
|
122
|
-
variant:
|
|
168
|
+
children: Re.map((e, t) => /* @__PURE__ */ V(j, {
|
|
169
|
+
variant: M.Rectangular,
|
|
123
170
|
width: e,
|
|
124
171
|
height: "16px",
|
|
125
|
-
color:
|
|
172
|
+
color: ze
|
|
126
173
|
}, t))
|
|
127
174
|
}),
|
|
128
|
-
/* @__PURE__ */
|
|
129
|
-
variant:
|
|
175
|
+
/* @__PURE__ */ V(j, {
|
|
176
|
+
variant: M.Rectangular,
|
|
130
177
|
width: "110px",
|
|
131
178
|
height: "28px",
|
|
132
|
-
color:
|
|
179
|
+
color: ze,
|
|
133
180
|
className: "shrink-0 rounded-lg"
|
|
134
181
|
})
|
|
135
182
|
]
|
|
136
|
-
}),
|
|
183
|
+
}), Ve = ({ items: e, searchQuery: t, onCardClick: n, labels: r, cardStyles: i, trailingSkeletonCount: a = 0, skeletonStyles: o, layout: s }) => /* @__PURE__ */ H("div", {
|
|
137
184
|
style: {
|
|
138
185
|
"--st-grid-min-card-width": s?.minCardWidth,
|
|
139
186
|
"--st-grid-gap": s?.gap,
|
|
@@ -143,197 +190,208 @@ var Ce = {
|
|
|
143
190
|
gap: "var(--st-grid-gap, 20px)",
|
|
144
191
|
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))"
|
|
145
192
|
},
|
|
146
|
-
className:
|
|
147
|
-
children: [e.map((e) => /* @__PURE__ */
|
|
193
|
+
className: v("mx-auto grid w-full min-w-0", W.cardGrid),
|
|
194
|
+
children: [e.map((e) => /* @__PURE__ */ V(Ie, {
|
|
148
195
|
item: e,
|
|
149
196
|
searchQuery: t,
|
|
150
197
|
onCardClick: n,
|
|
151
198
|
labels: r,
|
|
152
199
|
styles: i
|
|
153
|
-
}, e.id)), Array.from({ length: a }, (e, t) => /* @__PURE__ */
|
|
154
|
-
}),
|
|
200
|
+
}, e.id)), Array.from({ length: a }, (e, t) => /* @__PURE__ */ V(Be, { styles: o }, `skeleton-${t}`))]
|
|
201
|
+
}), X = {
|
|
155
202
|
container: "_container_3vz4t_2",
|
|
156
203
|
subtitle: "_subtitle_3vz4t_6",
|
|
157
204
|
createButtonLabel: "_createButtonLabel_3vz4t_10",
|
|
158
205
|
sortButton: "_sortButton_3vz4t_19",
|
|
159
206
|
createButton: "_createButton_3vz4t_10",
|
|
160
207
|
sortControlHidden: "_sortControlHidden_3vz4t_49"
|
|
161
|
-
},
|
|
208
|
+
}, He = /* @__PURE__ */ V(F, {
|
|
209
|
+
size: 48,
|
|
210
|
+
stroke: 1,
|
|
211
|
+
"aria-hidden": !0
|
|
212
|
+
}), Ue = (e, t, n, r, i, a) => {
|
|
162
213
|
if (!e) return t ? a.loadingMoreLabel : n ? a.errorLabel : r > 0 ? `${r}` : i ? a.noResultsLabel : a.emptyStateLabel;
|
|
163
|
-
},
|
|
214
|
+
}, We = (e) => {
|
|
164
215
|
if (!e || e === document.body) return null;
|
|
165
216
|
let { overflow: t, overflowY: n } = getComputedStyle(e);
|
|
166
|
-
return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e :
|
|
167
|
-
},
|
|
168
|
-
let { colors:
|
|
169
|
-
"--st-bg":
|
|
170
|
-
"--st-subtitle-text":
|
|
171
|
-
"--st-sort-text":
|
|
172
|
-
}),
|
|
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: S, cardStyles: C, loadMoreError: w, onRetryLoadMore: T }) => {
|
|
219
|
+
let { colors: E, typography: ie } = y ?? {}, ae = ie?.titleClassName ?? "dial-h1-text", oe = ie?.subtitleClassName ?? "dial-body-text", se = _({
|
|
220
|
+
"--st-bg": E?.background,
|
|
221
|
+
"--st-subtitle-text": E?.subtitleText,
|
|
222
|
+
"--st-sort-text": E?.sortButtonText
|
|
223
|
+
}), ce = (e) => {
|
|
173
224
|
r(e ?? "");
|
|
174
|
-
}, [
|
|
175
|
-
|
|
176
|
-
}, []),
|
|
177
|
-
|
|
225
|
+
}, [ue, de] = je(!1), [pe, j] = je(!1), M = B(null), he = z(() => {
|
|
226
|
+
j(!0);
|
|
227
|
+
}, []), ge = z(() => {
|
|
228
|
+
j(!1);
|
|
178
229
|
}, []);
|
|
179
|
-
|
|
180
|
-
let e =
|
|
181
|
-
|
|
182
|
-
}, [
|
|
183
|
-
let
|
|
230
|
+
ke(() => {
|
|
231
|
+
let e = M.current;
|
|
232
|
+
pe && ue && e != null && e.offsetParent == null && de(!1);
|
|
233
|
+
}, [pe, ue]);
|
|
234
|
+
let _e = e.sortOptions.find((e) => e.value === i)?.label ?? e.sortLabel, ve = Ae(() => e.sortOptions.map((e) => ({
|
|
184
235
|
key: e.value,
|
|
185
236
|
label: e.label,
|
|
186
|
-
mark:
|
|
237
|
+
mark: le.Check,
|
|
187
238
|
checked: e.value === i,
|
|
188
239
|
onClick: () => a(e.value)
|
|
189
240
|
})), [
|
|
190
241
|
e.sortOptions,
|
|
191
242
|
i,
|
|
192
243
|
a
|
|
193
|
-
]),
|
|
194
|
-
|
|
195
|
-
let e =
|
|
196
|
-
if (!e || !
|
|
197
|
-
let t =
|
|
244
|
+
]), ye = Ue(s, d, !!c, o.length, n.trim().length > 0, e), be = B(null);
|
|
245
|
+
De(() => {
|
|
246
|
+
let e = be.current;
|
|
247
|
+
if (!e || !p) return;
|
|
248
|
+
let t = We(e.parentElement);
|
|
198
249
|
if (!t) return;
|
|
199
250
|
let n = () => {
|
|
200
|
-
if (d || s ||
|
|
251
|
+
if (d || s || w || !u) return;
|
|
201
252
|
let n = t.getBoundingClientRect(), r = e.getBoundingClientRect();
|
|
202
|
-
r.top < n.bottom && r.bottom > n.top &&
|
|
253
|
+
r.top < n.bottom && r.bottom > n.top && p();
|
|
203
254
|
};
|
|
204
255
|
return t.addEventListener("scroll", n, { passive: !0 }), n(), () => t.removeEventListener("scroll", n);
|
|
205
256
|
}, [
|
|
206
257
|
u,
|
|
207
258
|
d,
|
|
208
259
|
s,
|
|
209
|
-
|
|
210
|
-
|
|
260
|
+
w,
|
|
261
|
+
p
|
|
211
262
|
]);
|
|
212
|
-
let
|
|
263
|
+
let xe = () => s ? /* @__PURE__ */ V(me, {}) : c ? /* @__PURE__ */ H("div", {
|
|
213
264
|
className: "flex flex-col items-center gap-3",
|
|
214
|
-
children: [/* @__PURE__ */
|
|
215
|
-
className:
|
|
265
|
+
children: [/* @__PURE__ */ V("p", {
|
|
266
|
+
className: v(oe, X.subtitle),
|
|
216
267
|
children: e.errorLabel
|
|
217
|
-
}), /* @__PURE__ */
|
|
268
|
+
}), /* @__PURE__ */ V(k, {
|
|
218
269
|
label: e.retryLabel,
|
|
219
270
|
onClick: l
|
|
220
271
|
})]
|
|
221
|
-
}) : o.length === 0 ? n.trim() ? /* @__PURE__ */
|
|
222
|
-
className:
|
|
272
|
+
}) : o.length === 0 ? n.trim() ? /* @__PURE__ */ V("p", {
|
|
273
|
+
className: v(oe, X.subtitle),
|
|
223
274
|
children: e.noResultsLabel
|
|
224
|
-
}) : /* @__PURE__ */
|
|
275
|
+
}) : /* @__PURE__ */ V(m, {
|
|
276
|
+
label: e.emptyStateLabel,
|
|
277
|
+
icon: He
|
|
278
|
+
}) : /* @__PURE__ */ H("div", {
|
|
225
279
|
className: "flex w-full flex-col gap-6",
|
|
226
280
|
children: [
|
|
227
|
-
/* @__PURE__ */
|
|
281
|
+
/* @__PURE__ */ V(Ve, {
|
|
228
282
|
items: o,
|
|
229
283
|
searchQuery: n,
|
|
230
|
-
onCardClick:
|
|
284
|
+
onCardClick: h,
|
|
231
285
|
labels: e.cardLabels,
|
|
232
|
-
trailingSkeletonCount: d ?
|
|
233
|
-
skeletonStyles: { colors: { skeletonColor:
|
|
234
|
-
cardStyles:
|
|
235
|
-
layout:
|
|
286
|
+
trailingSkeletonCount: d ? f : 0,
|
|
287
|
+
skeletonStyles: { colors: { skeletonColor: E?.skeletonColor } },
|
|
288
|
+
cardStyles: C,
|
|
289
|
+
layout: S
|
|
236
290
|
}),
|
|
237
|
-
|
|
291
|
+
w && /* @__PURE__ */ H("div", {
|
|
238
292
|
role: "alert",
|
|
239
293
|
className: "flex items-center gap-3",
|
|
240
|
-
children: [/* @__PURE__ */
|
|
241
|
-
className:
|
|
294
|
+
children: [/* @__PURE__ */ V("span", {
|
|
295
|
+
className: v(oe, X.subtitle),
|
|
242
296
|
children: e.loadMoreErrorLabel ?? e.errorLabel
|
|
243
|
-
}), /* @__PURE__ */
|
|
297
|
+
}), /* @__PURE__ */ V(k, {
|
|
244
298
|
label: e.retryLabel,
|
|
245
|
-
onClick:
|
|
299
|
+
onClick: T
|
|
246
300
|
})]
|
|
247
301
|
}),
|
|
248
|
-
/* @__PURE__ */
|
|
249
|
-
ref:
|
|
302
|
+
/* @__PURE__ */ V("div", {
|
|
303
|
+
ref: be,
|
|
250
304
|
"aria-hidden": !0,
|
|
251
305
|
className: "h-px w-full"
|
|
252
306
|
})
|
|
253
307
|
]
|
|
254
|
-
}),
|
|
255
|
-
return /* @__PURE__ */
|
|
256
|
-
style:
|
|
257
|
-
className:
|
|
308
|
+
}), P = s || !!c || o.length === 0;
|
|
309
|
+
return /* @__PURE__ */ H("div", {
|
|
310
|
+
style: se,
|
|
311
|
+
className: v("flex h-full w-full flex-col gap-6 overflow-y-auto px-8 py-4", X.container, x),
|
|
258
312
|
children: [
|
|
259
|
-
/* @__PURE__ */
|
|
313
|
+
/* @__PURE__ */ H("div", {
|
|
260
314
|
className: "flex items-start justify-between gap-4",
|
|
261
|
-
children: [/* @__PURE__ */
|
|
315
|
+
children: [/* @__PURE__ */ H("div", {
|
|
262
316
|
className: "min-w-0 gap-2",
|
|
263
|
-
children: [/* @__PURE__ */
|
|
264
|
-
className:
|
|
317
|
+
children: [/* @__PURE__ */ V("h1", {
|
|
318
|
+
className: v("truncate", ae),
|
|
265
319
|
children: e.title
|
|
266
|
-
}), /* @__PURE__ */
|
|
267
|
-
className:
|
|
320
|
+
}), /* @__PURE__ */ V("p", {
|
|
321
|
+
className: v("mt-1", oe, X.subtitle),
|
|
268
322
|
children: e.subtitle
|
|
269
323
|
})]
|
|
270
|
-
}), /* @__PURE__ */
|
|
324
|
+
}), /* @__PURE__ */ V(fe, {
|
|
271
325
|
label: e.createButtonLabel,
|
|
272
|
-
textClassName:
|
|
326
|
+
textClassName: X.createButtonLabel,
|
|
273
327
|
"aria-label": e.createButtonLabel,
|
|
274
|
-
iconBefore: /* @__PURE__ */
|
|
275
|
-
size:
|
|
328
|
+
iconBefore: /* @__PURE__ */ V(R, {
|
|
329
|
+
size: D.SM,
|
|
276
330
|
"aria-hidden": !0,
|
|
277
|
-
stroke:
|
|
331
|
+
stroke: O
|
|
278
332
|
}),
|
|
279
333
|
onClick: t,
|
|
280
|
-
className:
|
|
334
|
+
className: v("shrink-0", X.createButton)
|
|
281
335
|
})]
|
|
282
336
|
}),
|
|
283
|
-
/* @__PURE__ */
|
|
337
|
+
/* @__PURE__ */ H("div", {
|
|
284
338
|
className: "flex flex-wrap items-center gap-3",
|
|
285
|
-
children: [/* @__PURE__ */
|
|
339
|
+
children: [/* @__PURE__ */ V("div", {
|
|
286
340
|
role: "search",
|
|
287
341
|
className: "flex-1",
|
|
288
|
-
children: /* @__PURE__ */
|
|
342
|
+
children: /* @__PURE__ */ V(A, {
|
|
289
343
|
value: n,
|
|
290
|
-
onChange:
|
|
344
|
+
onChange: ce,
|
|
291
345
|
placeholder: e.searchPlaceholder,
|
|
292
346
|
clearLabel: e.clearSearchLabel,
|
|
293
347
|
"aria-label": e.searchAriaLabel,
|
|
294
|
-
size:
|
|
295
|
-
onFocus:
|
|
296
|
-
onBlur:
|
|
348
|
+
size: re.Large,
|
|
349
|
+
onFocus: he,
|
|
350
|
+
onBlur: ge
|
|
297
351
|
})
|
|
298
|
-
}), e.sortOptions.length > 0 && /* @__PURE__ */
|
|
299
|
-
ref:
|
|
300
|
-
className:
|
|
301
|
-
children: /* @__PURE__ */
|
|
302
|
-
items:
|
|
303
|
-
label:
|
|
304
|
-
variant:
|
|
305
|
-
appearance:
|
|
306
|
-
iconBefore:
|
|
307
|
-
size:
|
|
352
|
+
}), e.sortOptions.length > 0 && /* @__PURE__ */ V("div", {
|
|
353
|
+
ref: M,
|
|
354
|
+
className: v(pe && X.sortControlHidden),
|
|
355
|
+
children: /* @__PURE__ */ V(te, {
|
|
356
|
+
items: ve,
|
|
357
|
+
label: _e,
|
|
358
|
+
variant: ne.Primary,
|
|
359
|
+
appearance: ee.Ghost,
|
|
360
|
+
iconBefore: b === void 0 ? /* @__PURE__ */ V(N, {
|
|
361
|
+
size: D.SM,
|
|
308
362
|
"aria-hidden": !0,
|
|
309
|
-
stroke:
|
|
310
|
-
}) :
|
|
311
|
-
className:
|
|
363
|
+
stroke: O
|
|
364
|
+
}) : b,
|
|
365
|
+
className: X.sortButton
|
|
312
366
|
})
|
|
313
367
|
})]
|
|
314
368
|
}),
|
|
315
|
-
|
|
316
|
-
/* @__PURE__ */
|
|
369
|
+
g,
|
|
370
|
+
/* @__PURE__ */ V("span", {
|
|
317
371
|
role: "status",
|
|
318
372
|
"aria-live": "polite",
|
|
319
373
|
className: "sr-only",
|
|
320
|
-
children:
|
|
374
|
+
children: ye
|
|
321
375
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
323
|
-
className:
|
|
324
|
-
children:
|
|
376
|
+
/* @__PURE__ */ V("div", {
|
|
377
|
+
className: v("mx-auto flex size-full w-full min-w-0 flex-col", P && "items-center justify-center"),
|
|
378
|
+
children: xe()
|
|
325
379
|
})
|
|
326
380
|
]
|
|
327
381
|
});
|
|
328
|
-
},
|
|
382
|
+
}, Ke = /* @__PURE__ */ function(e) {
|
|
329
383
|
return e.FirstToRun = "firstToRun", e.LastToRun = "lastToRun", e.Newest = "newest", e.NameAZ = "nameAZ", e;
|
|
330
|
-
}({}),
|
|
331
|
-
let
|
|
332
|
-
|
|
384
|
+
}({}), qe = (e) => e == null ? "" : typeof e == "string" ? e.trim() : Array.isArray(e) ? e.length ? JSON.stringify(e) : "" : JSON.stringify(e), Je = (e, t) => {
|
|
385
|
+
let n = new Set([...Object.keys(e), ...Object.keys(t)]);
|
|
386
|
+
for (let r of n) if (qe(e[r]) !== qe(t[r])) return !0;
|
|
387
|
+
return !1;
|
|
388
|
+
}, Ye = { error: "_error_v2pfn_4" }, Xe = ({ label: e, value: t, onChange: r, error: i, errorClassName: a = "dial-small-text" }) => {
|
|
389
|
+
let o = B(/* @__PURE__ */ new Date()).current;
|
|
390
|
+
return /* @__PURE__ */ H("div", {
|
|
333
391
|
className: "flex flex-col gap-1",
|
|
334
|
-
children: [/* @__PURE__ */
|
|
392
|
+
children: [/* @__PURE__ */ V(C, {
|
|
335
393
|
id: "scheduled-task-run-at",
|
|
336
|
-
mode:
|
|
394
|
+
mode: w.DateTime,
|
|
337
395
|
value: s(t),
|
|
338
396
|
onChange: (e) => r(n(e)),
|
|
339
397
|
minDate: o,
|
|
@@ -342,31 +400,62 @@ var Ce = {
|
|
|
342
400
|
required: !0
|
|
343
401
|
},
|
|
344
402
|
invalid: !!i
|
|
345
|
-
}), i && /* @__PURE__ */
|
|
346
|
-
className:
|
|
403
|
+
}), i && /* @__PURE__ */ V("p", {
|
|
404
|
+
className: v(a, Ye.error),
|
|
347
405
|
children: i
|
|
348
406
|
})]
|
|
349
407
|
});
|
|
350
|
-
},
|
|
351
|
-
formColumn: "
|
|
352
|
-
detailsColumn: "
|
|
353
|
-
sectionSubtitle: "
|
|
354
|
-
instructionsError: "
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
"
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
408
|
+
}, Z = {
|
|
409
|
+
formColumn: "_formColumn_1253x_1",
|
|
410
|
+
detailsColumn: "_detailsColumn_1253x_10",
|
|
411
|
+
sectionSubtitle: "_sectionSubtitle_1253x_14",
|
|
412
|
+
instructionsError: "_instructionsError_1253x_18",
|
|
413
|
+
refineFeedback: "_refineFeedback_1253x_22",
|
|
414
|
+
refineError: "_refineError_1253x_26"
|
|
415
|
+
}, Ze = Ee(async () => ({ default: (await U()).MarkdownEditor })), Qe = ({ labels: n, values: r, initialValues: s, errors: u, modelSelector: p, modelLabelId: m, skillSelector: h, onFieldChange: b, onBack: ee, onCancel: te, onSubmit: ne, isSubmitting: T = !1, onRefineDescription: re, onRefineInstructions: ie, markdownEditorTheme: k, backIcon: ae, className: oe, styles: le }) => {
|
|
416
|
+
let ue = Oe(), fe = Oe(), A = B(void 0), j = (e) => e ? async (t, n) => {
|
|
417
|
+
if (A.current && !A.current.aborted) throw new DOMException("Busy", "AbortError");
|
|
418
|
+
A.current = n;
|
|
419
|
+
try {
|
|
420
|
+
return await e(t, n);
|
|
421
|
+
} finally {
|
|
422
|
+
A.current === n && (A.current = void 0);
|
|
423
|
+
}
|
|
424
|
+
} : void 0, M = x({
|
|
425
|
+
value: r.description ?? "",
|
|
426
|
+
onChange: (e) => b("description", e),
|
|
427
|
+
onRefine: j(re),
|
|
428
|
+
disabled: T
|
|
429
|
+
}), he = x({
|
|
430
|
+
value: r.prompt,
|
|
431
|
+
onChange: (e) => b("prompt", e),
|
|
432
|
+
onRefine: j(ie),
|
|
433
|
+
disabled: T
|
|
434
|
+
}), ge = M.isPending || he.isPending, ve = () => {
|
|
435
|
+
M.reset(), he.reset();
|
|
436
|
+
}, N = S(!!(s && Je(r, s))), be = () => N.guard(() => {
|
|
437
|
+
ve(), ee();
|
|
438
|
+
}), xe = () => N.guard(() => {
|
|
439
|
+
ve(), te();
|
|
440
|
+
}), P = y(), Se = !r.skillUrls?.length, [F, Ce] = je(), I = B(/* @__PURE__ */ new Date()).current, { colors: L, typography: R, layout: we } = le ?? {}, Ee = R?.titleClassName ?? "dial-h1-text", z = R?.sectionTitleClassName ?? "dial-body-semi-text", ke = R?.sectionSubtitleClassName ?? "dial-tiny-text", Ae = R?.instructionsLabelClassName ?? "dial-body-semi-text mb-1", U = R?.instructionsErrorClassName ?? "dial-small-text", G = _({
|
|
441
|
+
"--stcf-details-border": L?.detailsColumnBorder,
|
|
442
|
+
"--stcf-subtitle-text": L?.sectionSubtitleText,
|
|
443
|
+
"--stcf-error-text": L?.instructionsErrorText,
|
|
444
|
+
"--stcf-refine-action-text": L?.refineActionText,
|
|
445
|
+
"--stcf-refine-error-text": L?.refineErrorText
|
|
446
|
+
}), K = {
|
|
447
|
+
feedbackClassName: v(L?.refineActionText && Z.refineFeedback, R?.refineFeedbackClassName, W.refineFeedback),
|
|
448
|
+
errorClassName: Z.refineError
|
|
449
|
+
}, Pe = (e) => {
|
|
450
|
+
Ce(c.test(e.target.value) ? void 0 : n.timeInvalidLabel), b("time", e.target.value);
|
|
451
|
+
}, q = (e) => {
|
|
452
|
+
Ce(void 0), b("time", typeof e == "string" ? e : "");
|
|
453
|
+
}, J = r.repeat !== t.OneTime && r.repeat !== t.Hourly;
|
|
454
|
+
De(() => {
|
|
455
|
+
J || Ce(void 0);
|
|
456
|
+
}, [J]);
|
|
457
|
+
let Fe = J ? F ?? u.time : void 0, Y = (e) => b("runAt", e), Ie = T || ge || !r.displayName.trim() || !r.modelId || !r.prompt.trim() && !r.skillUrls?.length || !!u.skillUrls || J && !r.time || !!Fe;
|
|
458
|
+
return /* @__PURE__ */ H(Me, { children: [/* @__PURE__ */ V(Ne, {
|
|
370
459
|
labels: {
|
|
371
460
|
title: n.pageTitle,
|
|
372
461
|
backButtonLabel: n.backButtonLabel,
|
|
@@ -374,194 +463,212 @@ var Ce = {
|
|
|
374
463
|
submitButtonLabel: n.createButtonLabel,
|
|
375
464
|
submittingLabel: n.submittingLabel ?? "Saving"
|
|
376
465
|
},
|
|
377
|
-
onBack:
|
|
378
|
-
onCancel:
|
|
379
|
-
onSubmit:
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
466
|
+
onBack: be,
|
|
467
|
+
onCancel: xe,
|
|
468
|
+
onSubmit: () => {
|
|
469
|
+
!Ie && (!A.current || A.current.aborted) && ne();
|
|
470
|
+
},
|
|
471
|
+
isCancelDisabled: T,
|
|
472
|
+
isSubmitDisabled: Ie,
|
|
473
|
+
isSubmitting: T,
|
|
474
|
+
backIcon: ae === void 0 ? /* @__PURE__ */ V(ye, {
|
|
475
|
+
size: D.LG,
|
|
476
|
+
stroke: O,
|
|
386
477
|
"aria-hidden": !0,
|
|
387
478
|
className: "rtl:scale-x-[-1]"
|
|
388
|
-
}) :
|
|
479
|
+
}) : ae,
|
|
389
480
|
layout: {
|
|
390
|
-
sideColumnWidth:
|
|
391
|
-
columnGap:
|
|
481
|
+
sideColumnWidth: we?.detailsWidth,
|
|
482
|
+
columnGap: we?.columnGap,
|
|
392
483
|
reserveEndColumn: !1
|
|
393
484
|
},
|
|
394
|
-
className:
|
|
485
|
+
className: oe,
|
|
395
486
|
styles: {
|
|
396
|
-
colors: { background:
|
|
487
|
+
colors: { background: L?.background },
|
|
397
488
|
header: {
|
|
398
|
-
colors: { borderColor:
|
|
399
|
-
typography: { fontClassName:
|
|
489
|
+
colors: { borderColor: L?.headerBorder },
|
|
490
|
+
typography: { fontClassName: Ee }
|
|
400
491
|
},
|
|
401
|
-
cssVars:
|
|
492
|
+
cssVars: G
|
|
402
493
|
},
|
|
403
|
-
left: /* @__PURE__ */
|
|
494
|
+
left: /* @__PURE__ */ H("div", {
|
|
404
495
|
role: "group",
|
|
405
496
|
"aria-label": n.detailsSectionTitle,
|
|
406
|
-
className:
|
|
497
|
+
className: v("flex flex-1 flex-col gap-5 border-e py-6", Z.detailsColumn, Z.formColumn),
|
|
407
498
|
children: [
|
|
408
|
-
/* @__PURE__ */
|
|
499
|
+
/* @__PURE__ */ H("div", {
|
|
409
500
|
className: "flex flex-col gap-1",
|
|
410
|
-
children: [/* @__PURE__ */
|
|
411
|
-
className:
|
|
501
|
+
children: [/* @__PURE__ */ V("h2", {
|
|
502
|
+
className: z,
|
|
412
503
|
children: n.detailsSectionTitle
|
|
413
|
-
}), /* @__PURE__ */
|
|
414
|
-
className:
|
|
504
|
+
}), /* @__PURE__ */ V("p", {
|
|
505
|
+
className: v(ke, Z.sectionSubtitle),
|
|
415
506
|
children: n.detailsSectionSubtitle
|
|
416
507
|
})]
|
|
417
508
|
}),
|
|
418
|
-
/* @__PURE__ */
|
|
509
|
+
/* @__PURE__ */ V(se, {
|
|
419
510
|
id: "scheduled-task-display-name",
|
|
420
511
|
value: r.displayName,
|
|
421
|
-
onChange: (e) =>
|
|
512
|
+
onChange: (e) => b("displayName", e ?? ""),
|
|
422
513
|
labelProps: {
|
|
423
514
|
label: n.displayNameLabel,
|
|
424
515
|
required: !0
|
|
425
516
|
},
|
|
426
|
-
invalid: !!
|
|
427
|
-
error:
|
|
517
|
+
invalid: !!u.displayName,
|
|
518
|
+
error: u.displayName
|
|
428
519
|
}),
|
|
429
|
-
/* @__PURE__ */
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
520
|
+
/* @__PURE__ */ V(g, {
|
|
521
|
+
isEnabled: !!re,
|
|
522
|
+
fieldId: ue,
|
|
523
|
+
label: n.descriptionLabel,
|
|
524
|
+
labels: n,
|
|
525
|
+
refinement: M,
|
|
526
|
+
disabled: T || ge,
|
|
527
|
+
...K,
|
|
528
|
+
children: /* @__PURE__ */ V(_e, {
|
|
529
|
+
id: ue,
|
|
530
|
+
value: r.description ?? "",
|
|
531
|
+
onChange: (e) => {
|
|
532
|
+
M.reset(), b("description", e);
|
|
533
|
+
},
|
|
534
|
+
labelProps: re ? void 0 : { label: n.descriptionLabel },
|
|
535
|
+
maxLength: 500,
|
|
536
|
+
invalid: !!u.description,
|
|
537
|
+
error: u.description,
|
|
538
|
+
caption: r.description ? `${r.description.length}/500` : void 0
|
|
539
|
+
})
|
|
438
540
|
}),
|
|
439
|
-
/* @__PURE__ */
|
|
541
|
+
/* @__PURE__ */ H("div", {
|
|
440
542
|
className: "flex flex-col gap-1",
|
|
441
543
|
children: [
|
|
442
|
-
/* @__PURE__ */
|
|
443
|
-
id:
|
|
544
|
+
/* @__PURE__ */ V(ce, {
|
|
545
|
+
id: m,
|
|
444
546
|
label: n.modelOrAgentLabel,
|
|
445
547
|
required: !0
|
|
446
548
|
}),
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
className:
|
|
450
|
-
children:
|
|
549
|
+
p,
|
|
550
|
+
u.modelId && /* @__PURE__ */ V("p", {
|
|
551
|
+
className: v(U, Z.instructionsError),
|
|
552
|
+
children: u.modelId
|
|
451
553
|
})
|
|
452
554
|
]
|
|
453
555
|
}),
|
|
454
|
-
/* @__PURE__ */
|
|
556
|
+
/* @__PURE__ */ H("div", {
|
|
455
557
|
className: "flex flex-col gap-3",
|
|
456
558
|
children: [
|
|
457
|
-
/* @__PURE__ */
|
|
559
|
+
/* @__PURE__ */ V(pe, {
|
|
458
560
|
labelProps: { label: n.repeatLabel },
|
|
459
561
|
value: r.repeat,
|
|
460
|
-
onChange: (e) =>
|
|
562
|
+
onChange: (e) => b("repeat", e),
|
|
461
563
|
options: n.repeatOptions.map((e) => ({
|
|
462
564
|
value: e.key,
|
|
463
565
|
label: e.label
|
|
464
566
|
}))
|
|
465
567
|
}),
|
|
466
|
-
r.repeat === t.OneTime && /* @__PURE__ */
|
|
568
|
+
r.repeat === t.OneTime && /* @__PURE__ */ V(Xe, {
|
|
467
569
|
label: n.runAtLabel,
|
|
468
570
|
value: r.runAt ?? "",
|
|
469
|
-
onChange:
|
|
470
|
-
error:
|
|
471
|
-
errorClassName:
|
|
571
|
+
onChange: Y,
|
|
572
|
+
error: u.runAt,
|
|
573
|
+
errorClassName: U
|
|
472
574
|
}),
|
|
473
|
-
r.repeat !== t.OneTime && /* @__PURE__ */
|
|
474
|
-
|
|
575
|
+
r.repeat !== t.OneTime && /* @__PURE__ */ H(Me, { children: [
|
|
576
|
+
J && /* @__PURE__ */ H("div", {
|
|
475
577
|
className: "flex flex-col gap-1",
|
|
476
|
-
children: [/* @__PURE__ */
|
|
578
|
+
children: [/* @__PURE__ */ V(C, {
|
|
477
579
|
id: "scheduled-task-time",
|
|
478
|
-
mode:
|
|
580
|
+
mode: w.Time,
|
|
479
581
|
value: r.time,
|
|
480
|
-
onChange:
|
|
481
|
-
onBlur:
|
|
582
|
+
onChange: q,
|
|
583
|
+
onBlur: Pe,
|
|
482
584
|
labelProps: {
|
|
483
585
|
label: n.timeLabel,
|
|
484
586
|
required: !0
|
|
485
587
|
},
|
|
486
|
-
invalid: !!
|
|
487
|
-
disabled:
|
|
588
|
+
invalid: !!Fe,
|
|
589
|
+
disabled: T,
|
|
488
590
|
showTimezone: !0
|
|
489
|
-
}),
|
|
490
|
-
className:
|
|
491
|
-
children:
|
|
591
|
+
}), Fe && /* @__PURE__ */ V("p", {
|
|
592
|
+
className: v(U, Z.instructionsError),
|
|
593
|
+
children: Fe
|
|
492
594
|
})]
|
|
493
595
|
}),
|
|
494
|
-
r.repeat === t.Weekly && /* @__PURE__ */
|
|
596
|
+
r.repeat === t.Weekly && /* @__PURE__ */ H("div", {
|
|
495
597
|
className: "flex flex-col gap-1",
|
|
496
|
-
children: [/* @__PURE__ */
|
|
598
|
+
children: [/* @__PURE__ */ V(C, {
|
|
497
599
|
id: "scheduled-task-day-of-week",
|
|
498
|
-
mode:
|
|
600
|
+
mode: w.Weekday,
|
|
499
601
|
value: a(r.dayOfWeek),
|
|
500
|
-
onChange: (e) =>
|
|
602
|
+
onChange: (e) => b("dayOfWeek", o(e)),
|
|
501
603
|
labelProps: {
|
|
502
604
|
label: n.dayOfWeekLabel,
|
|
503
605
|
required: !0
|
|
504
606
|
},
|
|
505
|
-
invalid: !!
|
|
506
|
-
}),
|
|
507
|
-
className:
|
|
508
|
-
children:
|
|
607
|
+
invalid: !!u.dayOfWeek
|
|
608
|
+
}), u.dayOfWeek && /* @__PURE__ */ V("p", {
|
|
609
|
+
className: v(U, Z.instructionsError),
|
|
610
|
+
children: u.dayOfWeek
|
|
509
611
|
})]
|
|
510
612
|
}),
|
|
511
|
-
r.repeat === t.Monthly && /* @__PURE__ */
|
|
613
|
+
r.repeat === t.Monthly && /* @__PURE__ */ V(de, {
|
|
512
614
|
id: "scheduled-task-day-of-month",
|
|
615
|
+
integer: !0,
|
|
616
|
+
min: 1,
|
|
617
|
+
max: 31,
|
|
513
618
|
value: r.dayOfMonth ?? "",
|
|
514
|
-
onChange: (e) =>
|
|
619
|
+
onChange: (e) => b("dayOfMonth", e == null ? "" : String(e)),
|
|
515
620
|
labelProps: {
|
|
516
621
|
label: n.dayOfMonthLabel,
|
|
517
622
|
required: !0
|
|
518
623
|
},
|
|
519
|
-
invalid: !!
|
|
520
|
-
error:
|
|
624
|
+
invalid: !!u.dayOfMonth,
|
|
625
|
+
error: u.dayOfMonth
|
|
521
626
|
}),
|
|
522
|
-
r.repeat === t.Hourly && /* @__PURE__ */
|
|
627
|
+
r.repeat === t.Hourly && /* @__PURE__ */ V(de, {
|
|
523
628
|
id: "scheduled-task-minute",
|
|
524
629
|
integer: !0,
|
|
525
630
|
min: 0,
|
|
526
631
|
max: 59,
|
|
527
632
|
value: r.minute ?? "",
|
|
528
|
-
onChange: (e) =>
|
|
633
|
+
onChange: (e) => b("minute", e == null ? "" : String(e)),
|
|
529
634
|
labelProps: {
|
|
530
635
|
label: n.minuteLabel,
|
|
531
636
|
required: !0
|
|
532
637
|
},
|
|
533
|
-
invalid: !!
|
|
534
|
-
error:
|
|
638
|
+
invalid: !!u.minute,
|
|
639
|
+
error: u.minute
|
|
535
640
|
}),
|
|
536
|
-
/* @__PURE__ */
|
|
641
|
+
/* @__PURE__ */ H("div", {
|
|
537
642
|
className: "flex flex-row gap-3",
|
|
538
|
-
children: [/* @__PURE__ */
|
|
643
|
+
children: [/* @__PURE__ */ H("div", {
|
|
539
644
|
className: "flex flex-1 flex-col gap-1",
|
|
540
|
-
children: [/* @__PURE__ */
|
|
645
|
+
children: [/* @__PURE__ */ V(C, {
|
|
541
646
|
id: "scheduled-task-start-date",
|
|
542
|
-
mode:
|
|
647
|
+
mode: w.Date,
|
|
543
648
|
value: e(r.startDate),
|
|
544
|
-
onChange: (e) =>
|
|
649
|
+
onChange: (e) => b("startDate", i(e)),
|
|
650
|
+
minDate: I,
|
|
545
651
|
labelProps: { label: n.startDateLabel },
|
|
546
652
|
placeholder: n.startDatePlaceholder,
|
|
547
|
-
invalid: !!
|
|
548
|
-
}),
|
|
549
|
-
className:
|
|
550
|
-
children:
|
|
653
|
+
invalid: !!u.startDate
|
|
654
|
+
}), u.startDate && /* @__PURE__ */ V("p", {
|
|
655
|
+
className: v(U, Z.instructionsError),
|
|
656
|
+
children: u.startDate
|
|
551
657
|
})]
|
|
552
|
-
}), /* @__PURE__ */
|
|
658
|
+
}), /* @__PURE__ */ H("div", {
|
|
553
659
|
className: "flex flex-1 flex-col gap-1",
|
|
554
|
-
children: [/* @__PURE__ */
|
|
660
|
+
children: [/* @__PURE__ */ V(C, {
|
|
555
661
|
id: "scheduled-task-end-date",
|
|
556
|
-
mode:
|
|
662
|
+
mode: w.Date,
|
|
557
663
|
value: e(r.endDate),
|
|
558
|
-
onChange: (e) =>
|
|
664
|
+
onChange: (e) => b("endDate", i(e)),
|
|
665
|
+
minDate: I,
|
|
559
666
|
labelProps: { label: n.endDateLabel },
|
|
560
667
|
placeholder: n.endDatePlaceholder,
|
|
561
|
-
invalid: !!
|
|
562
|
-
}),
|
|
563
|
-
className:
|
|
564
|
-
children:
|
|
668
|
+
invalid: !!u.endDate
|
|
669
|
+
}), u.endDate && /* @__PURE__ */ V("p", {
|
|
670
|
+
className: v(U, Z.instructionsError),
|
|
671
|
+
children: u.endDate
|
|
565
672
|
})]
|
|
566
673
|
})]
|
|
567
674
|
})
|
|
@@ -570,142 +677,211 @@ var Ce = {
|
|
|
570
677
|
})
|
|
571
678
|
]
|
|
572
679
|
}),
|
|
573
|
-
children: /* @__PURE__ */
|
|
680
|
+
children: /* @__PURE__ */ H("div", {
|
|
574
681
|
role: "group",
|
|
575
682
|
"aria-label": n.configurationSectionTitle,
|
|
576
|
-
className:
|
|
577
|
-
children: [
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
className:
|
|
592
|
-
children:
|
|
593
|
-
})
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
683
|
+
className: v("flex flex-1 flex-col gap-5 py-6", Z.formColumn),
|
|
684
|
+
children: [
|
|
685
|
+
/* @__PURE__ */ H("div", {
|
|
686
|
+
className: "flex flex-col gap-1",
|
|
687
|
+
children: [/* @__PURE__ */ V("h2", {
|
|
688
|
+
className: z,
|
|
689
|
+
children: n.configurationSectionTitle
|
|
690
|
+
}), /* @__PURE__ */ V("p", {
|
|
691
|
+
className: v(ke, Z.sectionSubtitle),
|
|
692
|
+
children: n.configurationSectionSubtitle
|
|
693
|
+
})]
|
|
694
|
+
}),
|
|
695
|
+
h == null ? u.skillUrls && /* @__PURE__ */ V("div", {
|
|
696
|
+
"aria-live": "polite",
|
|
697
|
+
children: /* @__PURE__ */ V("p", {
|
|
698
|
+
className: v(U, Z.instructionsError),
|
|
699
|
+
children: u.skillUrls
|
|
700
|
+
})
|
|
701
|
+
}) : /* @__PURE__ */ V("div", {
|
|
702
|
+
className: "w-full min-w-0 max-w-[996px]",
|
|
703
|
+
children: h
|
|
704
|
+
}),
|
|
705
|
+
/* @__PURE__ */ V("div", {
|
|
706
|
+
className: "flex w-full min-w-0 max-w-[996px] flex-col",
|
|
707
|
+
children: /* @__PURE__ */ V(g, {
|
|
708
|
+
isEnabled: !!ie,
|
|
709
|
+
fieldId: fe,
|
|
710
|
+
labelClassName: Ae,
|
|
711
|
+
label: n.instructionsLabel,
|
|
712
|
+
required: Se,
|
|
713
|
+
labels: n,
|
|
714
|
+
refinement: he,
|
|
715
|
+
disabled: T || ge,
|
|
716
|
+
...K,
|
|
717
|
+
children: /* @__PURE__ */ H("div", {
|
|
718
|
+
className: "flex flex-1 flex-col gap-1",
|
|
719
|
+
children: [
|
|
720
|
+
!ie && /* @__PURE__ */ V(ce, {
|
|
721
|
+
htmlFor: fe,
|
|
722
|
+
className: Ae,
|
|
723
|
+
label: n.instructionsLabel,
|
|
724
|
+
required: Se
|
|
725
|
+
}),
|
|
726
|
+
/* @__PURE__ */ V("div", {
|
|
727
|
+
ref: P,
|
|
728
|
+
className: v("w-full", d, f),
|
|
729
|
+
children: /* @__PURE__ */ V(Te, {
|
|
730
|
+
fallback: /* @__PURE__ */ V(me, {}),
|
|
731
|
+
children: /* @__PURE__ */ V(Ze, {
|
|
732
|
+
id: fe,
|
|
733
|
+
value: r.prompt,
|
|
734
|
+
onChange: (e) => {
|
|
735
|
+
he.reset(), b("prompt", e);
|
|
736
|
+
},
|
|
737
|
+
height: 480,
|
|
738
|
+
theme: k,
|
|
739
|
+
placeholder: n.instructionsPlaceholder
|
|
740
|
+
})
|
|
741
|
+
})
|
|
742
|
+
}),
|
|
743
|
+
u.prompt && /* @__PURE__ */ V("p", {
|
|
744
|
+
className: v(U, Z.instructionsError),
|
|
745
|
+
children: u.prompt
|
|
746
|
+
})
|
|
747
|
+
]
|
|
607
748
|
})
|
|
608
|
-
}),
|
|
609
|
-
s.prompt && /* @__PURE__ */ W("p", {
|
|
610
|
-
className: m(I, Y.instructionsError),
|
|
611
|
-
children: s.prompt
|
|
612
749
|
})
|
|
613
|
-
|
|
614
|
-
|
|
750
|
+
})
|
|
751
|
+
]
|
|
615
752
|
})
|
|
616
|
-
})
|
|
617
|
-
|
|
753
|
+
}), N.isConfirmOpen && /* @__PURE__ */ V(l, {
|
|
754
|
+
open: !0,
|
|
755
|
+
title: n.discardTitle ?? "Discard unsaved changes?",
|
|
756
|
+
message: n.discardMessage ?? "You have unsaved changes. Leaving now will discard them.",
|
|
757
|
+
confirmLabel: n.discardConfirmLabel ?? "Discard changes",
|
|
758
|
+
cancelLabel: n.discardCancelLabel ?? "Keep editing",
|
|
759
|
+
variant: E.Danger,
|
|
760
|
+
onConfirm: N.confirm,
|
|
761
|
+
onClose: N.dismiss
|
|
762
|
+
})] });
|
|
763
|
+
}, $e = /* @__PURE__ */ function(e) {
|
|
618
764
|
return e.Details = "details", e.Configuration = "configuration", e.History = "history", e;
|
|
619
|
-
}({}),
|
|
765
|
+
}({}), et = /* @__PURE__ */ function(e) {
|
|
620
766
|
return e.Card = "card", e.Flow = "flow", e;
|
|
621
|
-
}({}),
|
|
622
|
-
|
|
623
|
-
"
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
className:
|
|
627
|
-
children:
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
767
|
+
}({}), tt = { subtitleText: "_subtitleText_1i4x2_3" }, nt = ({ skillLabel: e, skillDisplayNames: t, instructionsLabel: n, instructionsMarkdown: r, renderInstructions: i, markdownLabels: a, fieldLabelClassName: o = "dial-tiny-text" }) => /* @__PURE__ */ H("div", {
|
|
768
|
+
className: "flex min-w-0 flex-col gap-5",
|
|
769
|
+
children: [!!t?.length && /* @__PURE__ */ H("div", {
|
|
770
|
+
role: "group",
|
|
771
|
+
"aria-label": e,
|
|
772
|
+
className: "flex min-w-0 flex-col gap-1",
|
|
773
|
+
children: [/* @__PURE__ */ V("span", {
|
|
774
|
+
className: v(o, tt.subtitleText),
|
|
775
|
+
children: e
|
|
776
|
+
}), /* @__PURE__ */ V("p", {
|
|
777
|
+
className: "whitespace-normal break-all",
|
|
778
|
+
children: t?.map((e, t) => /* @__PURE__ */ V("span", {
|
|
779
|
+
className: "block",
|
|
780
|
+
children: e
|
|
781
|
+
}, `${t}:${e}`))
|
|
782
|
+
})]
|
|
783
|
+
}), r && /* @__PURE__ */ H("div", {
|
|
784
|
+
role: "group",
|
|
785
|
+
"aria-label": n,
|
|
786
|
+
className: "flex min-w-0 flex-col gap-1",
|
|
787
|
+
children: [/* @__PURE__ */ V("span", {
|
|
788
|
+
className: v(o, tt.subtitleText),
|
|
789
|
+
children: n
|
|
790
|
+
}), i ? i(r) : /* @__PURE__ */ V(p, {
|
|
791
|
+
content: r,
|
|
792
|
+
...a
|
|
793
|
+
})]
|
|
794
|
+
})]
|
|
795
|
+
}), rt = { subtitleText: "_subtitleText_1i4x2_3" }, it = ({ labels: e, description: t, modelLabel: n, repeatsLabel: r, activeWindowLabel: i, completedLabel: a, fieldLabelClassName: o = "dial-tiny-text", fieldValueClassName: s = "dial-small-text" }) => /* @__PURE__ */ H(Me, { children: [
|
|
796
|
+
t && /* @__PURE__ */ H("div", {
|
|
631
797
|
className: "flex flex-col gap-1",
|
|
632
|
-
children: [/* @__PURE__ */
|
|
633
|
-
className:
|
|
798
|
+
children: [/* @__PURE__ */ V("span", {
|
|
799
|
+
className: v(o, rt.subtitleText),
|
|
634
800
|
children: e.descriptionLabel
|
|
635
|
-
}), /* @__PURE__ */
|
|
636
|
-
className:
|
|
801
|
+
}), /* @__PURE__ */ V("p", {
|
|
802
|
+
className: s,
|
|
637
803
|
children: t
|
|
638
804
|
})]
|
|
639
805
|
}),
|
|
640
|
-
|
|
806
|
+
a && /* @__PURE__ */ H("div", {
|
|
807
|
+
className: "flex flex-col gap-1",
|
|
808
|
+
children: [/* @__PURE__ */ V("span", {
|
|
809
|
+
className: v(o, rt.subtitleText),
|
|
810
|
+
children: e.completedFieldLabel
|
|
811
|
+
}), /* @__PURE__ */ V("p", {
|
|
812
|
+
className: s,
|
|
813
|
+
children: a
|
|
814
|
+
})]
|
|
815
|
+
}),
|
|
816
|
+
n && /* @__PURE__ */ H("div", {
|
|
641
817
|
className: "flex flex-col gap-1",
|
|
642
|
-
children: [/* @__PURE__ */
|
|
643
|
-
className:
|
|
818
|
+
children: [/* @__PURE__ */ V("span", {
|
|
819
|
+
className: v(o, rt.subtitleText),
|
|
644
820
|
children: e.modelLabel
|
|
645
|
-
}), /* @__PURE__ */
|
|
646
|
-
className:
|
|
821
|
+
}), /* @__PURE__ */ V("p", {
|
|
822
|
+
className: s,
|
|
647
823
|
children: n
|
|
648
824
|
})]
|
|
649
825
|
}),
|
|
650
|
-
r && /* @__PURE__ */
|
|
826
|
+
r && /* @__PURE__ */ H("div", {
|
|
651
827
|
className: "flex flex-col gap-1",
|
|
652
|
-
children: [/* @__PURE__ */
|
|
653
|
-
className:
|
|
828
|
+
children: [/* @__PURE__ */ V("span", {
|
|
829
|
+
className: v(o, rt.subtitleText),
|
|
654
830
|
children: e.repeatsLabel
|
|
655
|
-
}), /* @__PURE__ */
|
|
656
|
-
className:
|
|
831
|
+
}), /* @__PURE__ */ V("p", {
|
|
832
|
+
className: s,
|
|
657
833
|
children: r
|
|
658
834
|
})]
|
|
659
835
|
}),
|
|
660
|
-
i && /* @__PURE__ */
|
|
836
|
+
i && /* @__PURE__ */ H("div", {
|
|
661
837
|
className: "flex flex-col gap-1",
|
|
662
|
-
children: [/* @__PURE__ */
|
|
663
|
-
className:
|
|
838
|
+
children: [/* @__PURE__ */ V("span", {
|
|
839
|
+
className: v(o, rt.subtitleText),
|
|
664
840
|
children: e.activeWindowLabel
|
|
665
|
-
}), /* @__PURE__ */
|
|
666
|
-
className:
|
|
841
|
+
}), /* @__PURE__ */ V("p", {
|
|
842
|
+
className: s,
|
|
667
843
|
children: i
|
|
668
844
|
})]
|
|
669
845
|
})
|
|
670
|
-
] }),
|
|
846
|
+
] }), at = /* @__PURE__ */ function(e) {
|
|
671
847
|
return e.Success = "success", e.Error = "error", e.InProgress = "inProgress", e.Missed = "missed", e;
|
|
672
|
-
}({}),
|
|
673
|
-
subtitleText: "
|
|
674
|
-
successIcon: "
|
|
675
|
-
errorIcon: "
|
|
676
|
-
missedIcon: "
|
|
677
|
-
currentRun: "
|
|
678
|
-
interactiveRow: "
|
|
679
|
-
unreadDot: "
|
|
680
|
-
rowLayout: "
|
|
681
|
-
},
|
|
848
|
+
}({}), Q = {
|
|
849
|
+
subtitleText: "_subtitleText_1d5p9_1",
|
|
850
|
+
successIcon: "_successIcon_1d5p9_5",
|
|
851
|
+
errorIcon: "_errorIcon_1d5p9_9",
|
|
852
|
+
missedIcon: "_missedIcon_1d5p9_13",
|
|
853
|
+
currentRun: "_currentRun_1d5p9_17",
|
|
854
|
+
interactiveRow: "_interactiveRow_1d5p9_22",
|
|
855
|
+
unreadDot: "_unreadDot_1d5p9_33",
|
|
856
|
+
rowLayout: "_rowLayout_1d5p9_37"
|
|
857
|
+
}, ot = ({ status: e }) => {
|
|
682
858
|
switch (e) {
|
|
683
|
-
case
|
|
684
|
-
size:
|
|
685
|
-
className:
|
|
859
|
+
case at.Success: return /* @__PURE__ */ V(xe, {
|
|
860
|
+
size: D.SM,
|
|
861
|
+
className: Q.successIcon,
|
|
686
862
|
"aria-hidden": !0,
|
|
687
|
-
stroke:
|
|
863
|
+
stroke: O
|
|
688
864
|
});
|
|
689
|
-
case
|
|
690
|
-
size:
|
|
691
|
-
className:
|
|
865
|
+
case at.Error: return /* @__PURE__ */ V(P, {
|
|
866
|
+
size: D.SM,
|
|
867
|
+
className: Q.errorIcon,
|
|
692
868
|
"aria-hidden": !0,
|
|
693
|
-
stroke:
|
|
869
|
+
stroke: O
|
|
694
870
|
});
|
|
695
|
-
case
|
|
871
|
+
case at.InProgress: return /* @__PURE__ */ V("span", {
|
|
696
872
|
"aria-hidden": !0,
|
|
697
|
-
children: /* @__PURE__ */
|
|
873
|
+
children: /* @__PURE__ */ V(me, { size: D.SM })
|
|
698
874
|
});
|
|
699
|
-
case
|
|
700
|
-
size:
|
|
701
|
-
className:
|
|
875
|
+
case at.Missed: return /* @__PURE__ */ V(ve, {
|
|
876
|
+
size: D.SM,
|
|
877
|
+
className: Q.missedIcon,
|
|
702
878
|
"aria-hidden": !0,
|
|
703
|
-
stroke:
|
|
879
|
+
stroke: O
|
|
704
880
|
});
|
|
705
881
|
default: return null;
|
|
706
882
|
}
|
|
707
|
-
},
|
|
708
|
-
let { colors: d, typography: f } = u ?? {},
|
|
883
|
+
}, st = ({ 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 }) => {
|
|
884
|
+
let { colors: d, typography: f } = u ?? {}, p = f?.runTimestampClassName ?? "dial-small-text", m = f?.subtitleClassName ?? "dial-body-text", h = c.unreadIndicatorLabel ?? "Unread", g = _({
|
|
709
885
|
"--strhl-success-icon": d?.successIconColor,
|
|
710
886
|
"--strhl-error-icon": d?.errorIconColor,
|
|
711
887
|
"--strhl-missed-icon": d?.missedIconColor,
|
|
@@ -713,10 +889,11 @@ var Ce = {
|
|
|
713
889
|
"--strhl-current-run-bg": d?.currentRunBackground,
|
|
714
890
|
"--strhl-unread-dot": d?.unreadDotColor,
|
|
715
891
|
"--strhl-row-hover-bg": u?.rowHoverBackground,
|
|
716
|
-
"--strhl-row-focus-bg": u?.rowFocusBackground
|
|
892
|
+
"--strhl-row-focus-bg": u?.rowFocusBackground,
|
|
893
|
+
"--strhl-row-focus-outline": u?.rowFocusOutline
|
|
717
894
|
}), y = (e) => {
|
|
718
|
-
let t = c.runStatusLabels[e.status], n = e.id === o, r = [e.isUnread ?
|
|
719
|
-
return /* @__PURE__ */
|
|
895
|
+
let t = c.runStatusLabels[e.status], n = e.id === o, r = [e.isUnread ? h : void 0, n ? c.currentRunLabel : void 0].filter((e) => !!e), i = [`${t} ${e.timestampLabel}`, ...r].join(" — "), a = !!e.conversationId && !!s;
|
|
896
|
+
return /* @__PURE__ */ H("li", {
|
|
720
897
|
...a ? {
|
|
721
898
|
role: "button",
|
|
722
899
|
tabIndex: 0,
|
|
@@ -727,73 +904,73 @@ var Ce = {
|
|
|
727
904
|
} : {},
|
|
728
905
|
"aria-label": i,
|
|
729
906
|
"aria-current": n ? "true" : void 0,
|
|
730
|
-
className:
|
|
731
|
-
children: [/* @__PURE__ */
|
|
907
|
+
className: v("flex min-h-[var(--strhl-row-min-height,32px)] max-w-[328px] items-center justify-between gap-2 rounded-full pe-2", Q.rowLayout, n && Q.currentRun, a && "cursor-pointer", a && Q.interactiveRow),
|
|
908
|
+
children: [/* @__PURE__ */ H("span", {
|
|
732
909
|
className: "flex items-center gap-2 truncate",
|
|
733
|
-
children: [/* @__PURE__ */
|
|
910
|
+
children: [/* @__PURE__ */ V("span", {
|
|
734
911
|
className: "relative flex size-3 shrink-0 items-center justify-center",
|
|
735
|
-
children: e.isUnread && /* @__PURE__ */
|
|
736
|
-
className:
|
|
912
|
+
children: e.isUnread && /* @__PURE__ */ V("span", {
|
|
913
|
+
className: v("size-[5.33px] rounded-full", Q.unreadDot),
|
|
737
914
|
"aria-hidden": !0
|
|
738
915
|
})
|
|
739
|
-
}), /* @__PURE__ */
|
|
740
|
-
className:
|
|
916
|
+
}), /* @__PURE__ */ V("span", {
|
|
917
|
+
className: v(p, "truncate"),
|
|
741
918
|
children: e.timestampLabel
|
|
742
919
|
})]
|
|
743
|
-
}), /* @__PURE__ */
|
|
920
|
+
}), /* @__PURE__ */ V("span", {
|
|
744
921
|
className: "flex min-h-[var(--strhl-row-min-height,32px)] w-14 shrink-0 items-center justify-end",
|
|
745
|
-
children: /* @__PURE__ */
|
|
922
|
+
children: /* @__PURE__ */ V(ot, { status: e.status })
|
|
746
923
|
})]
|
|
747
924
|
}, e.id);
|
|
748
|
-
}, b = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */
|
|
925
|
+
}, b = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ H("li", {
|
|
749
926
|
"aria-hidden": "true",
|
|
750
|
-
className:
|
|
751
|
-
children: [/* @__PURE__ */
|
|
752
|
-
variant:
|
|
927
|
+
className: v("flex min-h-[var(--strhl-row-min-height,32px)] max-w-[328px] items-center justify-between gap-2 pe-2", Q.rowLayout),
|
|
928
|
+
children: [/* @__PURE__ */ V(j, {
|
|
929
|
+
variant: M.Rectangular,
|
|
753
930
|
width: "160px",
|
|
754
931
|
height: "16px"
|
|
755
|
-
}), /* @__PURE__ */
|
|
756
|
-
variant:
|
|
932
|
+
}), /* @__PURE__ */ V(j, {
|
|
933
|
+
variant: M.Rectangular,
|
|
757
934
|
width: "16px",
|
|
758
935
|
height: "16px",
|
|
759
936
|
className: "shrink-0 rounded-full"
|
|
760
937
|
})]
|
|
761
938
|
}, `history-skeleton-${t}`));
|
|
762
|
-
return t && e.length === 0 ? /* @__PURE__ */
|
|
939
|
+
return t && e.length === 0 ? /* @__PURE__ */ V("ul", {
|
|
763
940
|
style: {
|
|
764
|
-
...
|
|
941
|
+
...g,
|
|
765
942
|
"--strhl-row-min-height": u?.rowMinHeight
|
|
766
943
|
},
|
|
767
944
|
"aria-label": c.historyTitle,
|
|
768
945
|
className: "flex flex-col gap-0.5",
|
|
769
946
|
children: b(r)
|
|
770
|
-
}) : i && e.length === 0 ? /* @__PURE__ */
|
|
771
|
-
style:
|
|
947
|
+
}) : i && e.length === 0 ? /* @__PURE__ */ H("div", {
|
|
948
|
+
style: g,
|
|
772
949
|
className: "flex flex-col items-start gap-3",
|
|
773
|
-
children: [/* @__PURE__ */
|
|
950
|
+
children: [/* @__PURE__ */ V("p", {
|
|
774
951
|
role: "alert",
|
|
775
|
-
className: m
|
|
952
|
+
className: v(m, Q.subtitleText),
|
|
776
953
|
children: c.errorLabel
|
|
777
|
-
}), /* @__PURE__ */
|
|
954
|
+
}), /* @__PURE__ */ V(k, {
|
|
778
955
|
label: c.retryLabel,
|
|
779
956
|
onClick: a
|
|
780
957
|
})]
|
|
781
|
-
}) : e.length === 0 ? /* @__PURE__ */
|
|
782
|
-
style:
|
|
958
|
+
}) : e.length === 0 ? /* @__PURE__ */ H("div", {
|
|
959
|
+
style: g,
|
|
783
960
|
className: "flex w-full flex-col items-center justify-center gap-2 py-4",
|
|
784
|
-
children: [/* @__PURE__ */
|
|
961
|
+
children: [/* @__PURE__ */ V(Se, {
|
|
785
962
|
size: 44,
|
|
786
|
-
stroke:
|
|
787
|
-
className:
|
|
963
|
+
stroke: O,
|
|
964
|
+
className: Q.subtitleText,
|
|
788
965
|
"aria-hidden": !0
|
|
789
|
-
}), /* @__PURE__ */
|
|
966
|
+
}), /* @__PURE__ */ V("p", {
|
|
790
967
|
role: "status",
|
|
791
|
-
className:
|
|
968
|
+
className: p,
|
|
792
969
|
children: c.emptyLabel
|
|
793
970
|
})]
|
|
794
|
-
}) : /* @__PURE__ */
|
|
971
|
+
}) : /* @__PURE__ */ H("ul", {
|
|
795
972
|
style: {
|
|
796
|
-
...
|
|
973
|
+
...g,
|
|
797
974
|
"--strhl-row-min-height": u?.rowMinHeight
|
|
798
975
|
},
|
|
799
976
|
"aria-label": c.historyTitle,
|
|
@@ -801,50 +978,50 @@ var Ce = {
|
|
|
801
978
|
children: [
|
|
802
979
|
e.map(y),
|
|
803
980
|
n && b(r),
|
|
804
|
-
i ? /* @__PURE__ */
|
|
981
|
+
i ? /* @__PURE__ */ H("li", {
|
|
805
982
|
className: "flex flex-col items-start gap-3 px-5 py-2",
|
|
806
|
-
children: [/* @__PURE__ */
|
|
983
|
+
children: [/* @__PURE__ */ V("p", {
|
|
807
984
|
role: "alert",
|
|
808
|
-
className: m
|
|
985
|
+
className: v(m, Q.subtitleText),
|
|
809
986
|
children: c.errorLabel
|
|
810
|
-
}), /* @__PURE__ */
|
|
987
|
+
}), /* @__PURE__ */ V(k, {
|
|
811
988
|
label: c.retryLabel,
|
|
812
989
|
onClick: a
|
|
813
990
|
})]
|
|
814
991
|
}) : l
|
|
815
992
|
]
|
|
816
993
|
});
|
|
817
|
-
},
|
|
994
|
+
}, ct = {
|
|
818
995
|
historyCard: "_historyCard_153p9_4",
|
|
819
996
|
subtitleText: "_subtitleText_153p9_8",
|
|
820
997
|
cardLayout: "_cardLayout_153p9_13"
|
|
821
|
-
},
|
|
822
|
-
let y = e ===
|
|
998
|
+
}, lt = ({ 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", sectionTitleClassName: h = "dial-body-semi-text", colors: g, styles: _ }) => {
|
|
999
|
+
let y = e === et.Card, b = y ? v("sticky bottom-0 z-10 rounded-b-xl px-6 pb-5 pt-2", ct.historyCard) : "pt-2", x = l ? /* @__PURE__ */ H("li", {
|
|
823
1000
|
className: b,
|
|
824
|
-
children: [/* @__PURE__ */
|
|
1001
|
+
children: [/* @__PURE__ */ V("p", {
|
|
825
1002
|
role: "alert",
|
|
826
1003
|
children: t.historyLoadMoreErrorLabel ?? t.historyErrorLabel
|
|
827
|
-
}), u && /* @__PURE__ */
|
|
1004
|
+
}), u && /* @__PURE__ */ V(k, {
|
|
828
1005
|
label: t.historyRetryLabel,
|
|
829
1006
|
onClick: u,
|
|
830
1007
|
disabled: a
|
|
831
1008
|
})]
|
|
832
|
-
}) : f && d && t.historyShowMoreLabel ? /* @__PURE__ */
|
|
1009
|
+
}) : f && d && t.historyShowMoreLabel ? /* @__PURE__ */ V("li", {
|
|
833
1010
|
className: b,
|
|
834
|
-
children: /* @__PURE__ */
|
|
1011
|
+
children: /* @__PURE__ */ V(k, {
|
|
835
1012
|
label: t.historyShowMoreLabel,
|
|
836
1013
|
onClick: f,
|
|
837
1014
|
disabled: a
|
|
838
1015
|
})
|
|
839
|
-
}) : void 0, S = n ? /* @__PURE__ */
|
|
840
|
-
className: m
|
|
1016
|
+
}) : void 0, S = n ? /* @__PURE__ */ V("p", {
|
|
1017
|
+
className: v(m, ct.subtitleText),
|
|
841
1018
|
children: n
|
|
842
|
-
}) : void 0,
|
|
1019
|
+
}) : void 0, ee = t.historyLoadingMoreLabel ? /* @__PURE__ */ V("span", {
|
|
843
1020
|
role: "status",
|
|
844
1021
|
"aria-live": "polite",
|
|
845
1022
|
className: "sr-only",
|
|
846
1023
|
children: a ? t.historyLoadingMoreLabel : ""
|
|
847
|
-
}) : void 0,
|
|
1024
|
+
}) : void 0, te = /* @__PURE__ */ V(st, {
|
|
848
1025
|
items: r,
|
|
849
1026
|
isLoading: i,
|
|
850
1027
|
isLoadingMore: a,
|
|
@@ -862,85 +1039,98 @@ var Ce = {
|
|
|
862
1039
|
},
|
|
863
1040
|
footer: x,
|
|
864
1041
|
styles: {
|
|
865
|
-
typography: { runTimestampClassName:
|
|
866
|
-
colors:
|
|
867
|
-
rowMinHeight:
|
|
868
|
-
rowHoverBackground:
|
|
869
|
-
rowFocusBackground:
|
|
1042
|
+
typography: { runTimestampClassName: m },
|
|
1043
|
+
colors: _?.colors ?? g,
|
|
1044
|
+
rowMinHeight: _?.rowMinHeight,
|
|
1045
|
+
rowHoverBackground: _?.rowHoverBackground,
|
|
1046
|
+
rowFocusBackground: _?.rowFocusBackground,
|
|
1047
|
+
rowFocusOutline: _?.rowFocusOutline
|
|
870
1048
|
}
|
|
871
1049
|
});
|
|
872
|
-
return y ? /* @__PURE__ */
|
|
873
|
-
className:
|
|
874
|
-
style: { "--st-history-max-height":
|
|
875
|
-
children: [/* @__PURE__ */
|
|
876
|
-
className:
|
|
1050
|
+
return y ? /* @__PURE__ */ H("div", {
|
|
1051
|
+
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", ct.historyCard, ct.cardLayout),
|
|
1052
|
+
style: { "--st-history-max-height": _?.maxHeight },
|
|
1053
|
+
children: [/* @__PURE__ */ H("div", {
|
|
1054
|
+
className: v("sticky top-0 z-10 flex flex-col gap-4 rounded-t-xl px-6 pb-2 pt-5", ct.historyCard),
|
|
877
1055
|
children: [
|
|
878
|
-
/* @__PURE__ */
|
|
879
|
-
className:
|
|
1056
|
+
/* @__PURE__ */ V("h2", {
|
|
1057
|
+
className: h,
|
|
880
1058
|
children: t.historyTitle
|
|
881
1059
|
}),
|
|
882
1060
|
S,
|
|
883
|
-
|
|
1061
|
+
ee
|
|
884
1062
|
]
|
|
885
|
-
}), /* @__PURE__ */
|
|
1063
|
+
}), /* @__PURE__ */ V("div", {
|
|
886
1064
|
className: "flex flex-1 flex-col gap-4 px-6 pb-2",
|
|
887
|
-
children:
|
|
1065
|
+
children: te
|
|
888
1066
|
})]
|
|
889
|
-
}) : /* @__PURE__ */
|
|
1067
|
+
}) : /* @__PURE__ */ H("div", {
|
|
890
1068
|
className: "flex flex-col gap-4",
|
|
891
1069
|
children: [
|
|
892
1070
|
S,
|
|
893
|
-
|
|
894
|
-
|
|
1071
|
+
ee,
|
|
1072
|
+
te
|
|
895
1073
|
]
|
|
896
1074
|
});
|
|
897
1075
|
}, $ = {
|
|
898
|
-
container: "
|
|
899
|
-
header: "
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
"--stdv-
|
|
909
|
-
"--stdv-
|
|
910
|
-
"--stdv-
|
|
911
|
-
"--stdv-
|
|
912
|
-
|
|
1076
|
+
container: "_container_1w44s_1",
|
|
1077
|
+
header: "_header_1w44s_8",
|
|
1078
|
+
headerActions: "_headerActions_1w44s_24",
|
|
1079
|
+
detailsColumn: "_detailsColumn_1w44s_30",
|
|
1080
|
+
subtitleText: "_subtitleText_1w44s_34",
|
|
1081
|
+
desktopTitle: "_desktopTitle_1w44s_39",
|
|
1082
|
+
desktopBadge: "_desktopBadge_1w44s_40",
|
|
1083
|
+
mobileTitleRow: "_mobileTitleRow_1w44s_44"
|
|
1084
|
+
}, ut = ({ 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: S, description: ee, modelLabel: te, repeatsLabel: C, activeWindowLabel: w, completedLabel: T, nextRunLabel: E, instructionsMarkdown: re, skillDisplayNames: ie, renderInstructions: oe, runs: se, runsIsLoading: ce = !1, runsIsLoadingMore: le = !1, runsSkeletonCount: de = 6, runsError: fe, onRunsRetry: A, runsLoadMoreError: pe, onRunsRetryLoadMore: j, runsHasMore: M = !1, onRunsLoadMore: _e, onRunClick: ve, styles: N, className: be, backIcon: xe, layout: P, historyStyles: Se }) => {
|
|
1085
|
+
let { colors: F, typography: I } = N ?? {}, R = I?.titleClassName ?? "dial-h2-text", Te = I?.sectionTitleClassName ?? "dial-body-semi-text", Ee = I?.fieldLabelClassName ?? "dial-tiny-text", z = I?.fieldValueClassName ?? "dial-small-text", De = I?.runTimestampClassName ?? "dial-small-text", ke = _({
|
|
1086
|
+
"--stdv-bg": F?.background,
|
|
1087
|
+
"--stdv-header-border": F?.headerBorder,
|
|
1088
|
+
"--stdv-details-border": F?.detailsColumnBorder,
|
|
1089
|
+
"--stdv-subtitle-text": F?.subtitleText,
|
|
1090
|
+
"--stdv-history-bg": F?.historyCardBackground
|
|
1091
|
+
}), Ae = b(), [B, Ne] = je($e.Details), U = Oe(), W = o && !i ? e.startNowBusyLabel : void 0, G = [
|
|
913
1092
|
{
|
|
914
|
-
id:
|
|
1093
|
+
id: $e.Details,
|
|
915
1094
|
label: e.detailsTitle
|
|
916
1095
|
},
|
|
917
1096
|
{
|
|
918
|
-
id:
|
|
1097
|
+
id: $e.Configuration,
|
|
919
1098
|
label: e.configurationTitle
|
|
920
1099
|
},
|
|
921
1100
|
{
|
|
922
|
-
id:
|
|
1101
|
+
id: $e.History,
|
|
923
1102
|
label: e.historyTitle
|
|
924
1103
|
}
|
|
925
|
-
],
|
|
1104
|
+
], K = G.find((e) => e.id === B)?.label ?? e.detailsTitle, Pe = /* @__PURE__ */ V(it, {
|
|
926
1105
|
labels: {
|
|
927
1106
|
descriptionLabel: e.descriptionLabel,
|
|
928
1107
|
modelLabel: e.modelLabel,
|
|
929
1108
|
repeatsLabel: e.repeatsLabel,
|
|
930
|
-
activeWindowLabel: e.activeWindowLabel
|
|
1109
|
+
activeWindowLabel: e.activeWindowLabel,
|
|
1110
|
+
completedFieldLabel: e.completedFieldLabel
|
|
931
1111
|
},
|
|
932
|
-
description:
|
|
933
|
-
modelLabel:
|
|
934
|
-
repeatsLabel:
|
|
935
|
-
activeWindowLabel:
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
1112
|
+
description: ee,
|
|
1113
|
+
modelLabel: te,
|
|
1114
|
+
repeatsLabel: C,
|
|
1115
|
+
activeWindowLabel: w,
|
|
1116
|
+
completedLabel: T,
|
|
1117
|
+
fieldLabelClassName: Ee,
|
|
1118
|
+
fieldValueClassName: z
|
|
1119
|
+
}), q = /* @__PURE__ */ V(nt, {
|
|
939
1120
|
instructionsLabel: e.instructionsLabel,
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
1121
|
+
skillLabel: e.skillLabel,
|
|
1122
|
+
skillDisplayNames: ie,
|
|
1123
|
+
instructionsMarkdown: re,
|
|
1124
|
+
renderInstructions: oe,
|
|
1125
|
+
markdownLabels: {
|
|
1126
|
+
codeBlockCopyLabel: e.codeBlockCopyLabel,
|
|
1127
|
+
codeBlockCopiedLabel: e.codeBlockCopiedLabel,
|
|
1128
|
+
codeBlockDownloadLabel: e.codeBlockDownloadLabel,
|
|
1129
|
+
tableScrollRegionAriaLabel: e.tableScrollRegionAriaLabel,
|
|
1130
|
+
mathScrollRegionAriaLabel: e.mathScrollRegionAriaLabel
|
|
1131
|
+
},
|
|
1132
|
+
fieldLabelClassName: Ee
|
|
1133
|
+
}), J = (t) => /* @__PURE__ */ V(lt, {
|
|
944
1134
|
variant: t,
|
|
945
1135
|
labels: {
|
|
946
1136
|
historyTitle: e.historyTitle,
|
|
@@ -953,255 +1143,261 @@ var Ce = {
|
|
|
953
1143
|
runStatusLabels: e.runStatusLabels,
|
|
954
1144
|
unreadIndicatorLabel: e.unreadIndicatorLabel
|
|
955
1145
|
},
|
|
956
|
-
nextRunLabel:
|
|
957
|
-
items:
|
|
958
|
-
isLoading:
|
|
959
|
-
isLoadingMore:
|
|
960
|
-
skeletonCount:
|
|
961
|
-
error:
|
|
1146
|
+
nextRunLabel: E,
|
|
1147
|
+
items: se,
|
|
1148
|
+
isLoading: ce,
|
|
1149
|
+
isLoadingMore: le,
|
|
1150
|
+
skeletonCount: de,
|
|
1151
|
+
error: fe,
|
|
962
1152
|
onRetry: A,
|
|
963
|
-
loadMoreError:
|
|
964
|
-
onRetryLoadMore:
|
|
965
|
-
hasMore:
|
|
966
|
-
onLoadMore:
|
|
967
|
-
onRunClick:
|
|
968
|
-
runTimestampClassName:
|
|
969
|
-
sectionTitleClassName:
|
|
970
|
-
colors:
|
|
971
|
-
styles:
|
|
1153
|
+
loadMoreError: pe,
|
|
1154
|
+
onRetryLoadMore: j,
|
|
1155
|
+
hasMore: M,
|
|
1156
|
+
onLoadMore: _e,
|
|
1157
|
+
onRunClick: ve,
|
|
1158
|
+
runTimestampClassName: De,
|
|
1159
|
+
sectionTitleClassName: Te,
|
|
1160
|
+
colors: F,
|
|
1161
|
+
styles: Se
|
|
972
1162
|
});
|
|
973
|
-
return /* @__PURE__ */
|
|
974
|
-
style:
|
|
975
|
-
className:
|
|
1163
|
+
return /* @__PURE__ */ H("div", {
|
|
1164
|
+
style: ke,
|
|
1165
|
+
className: v("flex h-full min-h-0 w-full flex-col overflow-hidden", $.container, be),
|
|
976
1166
|
children: [
|
|
977
|
-
/* @__PURE__ */
|
|
978
|
-
className:
|
|
979
|
-
children: [/* @__PURE__ */
|
|
1167
|
+
/* @__PURE__ */ H("div", {
|
|
1168
|
+
className: v("flex min-h-16 shrink-0 items-center justify-between gap-2 px-4 py-2 desktop:h-16 desktop:flex-nowrap desktop:px-8 desktop:py-0", $.header),
|
|
1169
|
+
children: [/* @__PURE__ */ H("div", {
|
|
980
1170
|
className: "flex min-w-0 items-center gap-2",
|
|
981
1171
|
children: [
|
|
982
|
-
/* @__PURE__ */
|
|
983
|
-
icon:
|
|
984
|
-
size:
|
|
1172
|
+
/* @__PURE__ */ V(ae, {
|
|
1173
|
+
icon: xe === void 0 ? /* @__PURE__ */ V(ye, {
|
|
1174
|
+
size: D.LG,
|
|
985
1175
|
className: "rtl:scale-x-[-1]",
|
|
986
1176
|
"aria-hidden": !0,
|
|
987
|
-
stroke:
|
|
988
|
-
}) :
|
|
1177
|
+
stroke: O
|
|
1178
|
+
}) : xe,
|
|
989
1179
|
"aria-label": e.backAriaLabel,
|
|
990
1180
|
onClick: t
|
|
991
1181
|
}),
|
|
992
|
-
/* @__PURE__ */
|
|
993
|
-
className:
|
|
994
|
-
children:
|
|
1182
|
+
/* @__PURE__ */ V("h1", {
|
|
1183
|
+
className: v("truncate", $.desktopTitle, R),
|
|
1184
|
+
children: g
|
|
995
1185
|
}),
|
|
996
|
-
|
|
997
|
-
className:
|
|
1186
|
+
l && /* @__PURE__ */ V("span", {
|
|
1187
|
+
className: v("shrink-0", $.desktopBadge, z, $.subtitleText),
|
|
998
1188
|
children: e.deletedStateLabel
|
|
999
1189
|
})
|
|
1000
1190
|
]
|
|
1001
|
-
}), /* @__PURE__ */
|
|
1002
|
-
className: "flex
|
|
1191
|
+
}), /* @__PURE__ */ H("div", {
|
|
1192
|
+
className: v("flex min-w-0 flex-1 flex-wrap items-center justify-end gap-2 desktop:flex-none desktop:flex-nowrap", $.headerActions),
|
|
1003
1193
|
children: [
|
|
1004
|
-
!
|
|
1194
|
+
!l && !u && d !== void 0 && /* @__PURE__ */ H(Me, { children: [/* @__PURE__ */ V(he, {
|
|
1005
1195
|
id: "scheduled-task-active-switch",
|
|
1006
1196
|
labelProps: { label: e.activeStatusLabel },
|
|
1007
|
-
isOn:
|
|
1008
|
-
disabled:
|
|
1009
|
-
onChange: (e) =>
|
|
1010
|
-
}),
|
|
1011
|
-
|
|
1012
|
-
|
|
1197
|
+
isOn: d,
|
|
1198
|
+
disabled: f || p || c,
|
|
1199
|
+
onChange: (e) => h?.(e)
|
|
1200
|
+
}), p && m && /* @__PURE__ */ V("span", {
|
|
1201
|
+
className: v(z, $.subtitleText),
|
|
1202
|
+
children: m
|
|
1203
|
+
})] }),
|
|
1204
|
+
!l && s && /* @__PURE__ */ V(k, {
|
|
1205
|
+
variant: ne.Danger,
|
|
1013
1206
|
label: e.deleteButtonLabel,
|
|
1014
|
-
iconBefore: /* @__PURE__ */
|
|
1015
|
-
size:
|
|
1207
|
+
iconBefore: /* @__PURE__ */ V(we, {
|
|
1208
|
+
size: D.SM,
|
|
1016
1209
|
"aria-hidden": !0,
|
|
1017
|
-
stroke:
|
|
1210
|
+
stroke: O
|
|
1018
1211
|
}),
|
|
1019
|
-
onClick:
|
|
1020
|
-
disabled:
|
|
1021
|
-
className: "shrink-0"
|
|
1212
|
+
onClick: s,
|
|
1213
|
+
disabled: c,
|
|
1214
|
+
className: "min-h-11 shrink-0"
|
|
1022
1215
|
}),
|
|
1023
|
-
!
|
|
1216
|
+
!l && n && /* @__PURE__ */ V(ue, {
|
|
1024
1217
|
label: e.editButtonLabel,
|
|
1025
|
-
iconBefore: /* @__PURE__ */
|
|
1026
|
-
size:
|
|
1218
|
+
iconBefore: /* @__PURE__ */ V(Ce, {
|
|
1219
|
+
size: D.SM,
|
|
1027
1220
|
"aria-hidden": !0,
|
|
1028
|
-
stroke:
|
|
1221
|
+
stroke: O
|
|
1029
1222
|
}),
|
|
1030
1223
|
onClick: n,
|
|
1031
|
-
disabled:
|
|
1032
|
-
className: "shrink-0"
|
|
1224
|
+
disabled: c,
|
|
1225
|
+
className: "min-h-11 shrink-0"
|
|
1226
|
+
}),
|
|
1227
|
+
!l && r && e.startNowButtonLabel && /* @__PURE__ */ H("div", {
|
|
1228
|
+
"aria-busy": i,
|
|
1229
|
+
children: [W && /* @__PURE__ */ V("span", {
|
|
1230
|
+
id: U,
|
|
1231
|
+
className: "sr-only",
|
|
1232
|
+
children: W
|
|
1233
|
+
}), /* @__PURE__ */ V(ue, {
|
|
1234
|
+
label: i ? e.startingLabel ?? e.startNowButtonLabel : e.startNowButtonLabel,
|
|
1235
|
+
iconBefore: /* @__PURE__ */ V(L, {
|
|
1236
|
+
size: D.SM,
|
|
1237
|
+
"aria-hidden": !0,
|
|
1238
|
+
stroke: O
|
|
1239
|
+
}),
|
|
1240
|
+
onClick: r,
|
|
1241
|
+
disabled: c || i || a || o,
|
|
1242
|
+
"aria-describedby": W ? U : void 0,
|
|
1243
|
+
tooltipProps: W ? { tooltip: W } : void 0,
|
|
1244
|
+
className: "min-h-11 shrink-0"
|
|
1245
|
+
})]
|
|
1033
1246
|
})
|
|
1034
1247
|
]
|
|
1035
1248
|
})]
|
|
1036
1249
|
}),
|
|
1037
|
-
/* @__PURE__ */
|
|
1038
|
-
className:
|
|
1039
|
-
children: [/* @__PURE__ */
|
|
1040
|
-
className:
|
|
1041
|
-
children:
|
|
1042
|
-
}),
|
|
1043
|
-
className:
|
|
1250
|
+
/* @__PURE__ */ H("div", {
|
|
1251
|
+
className: v("min-w-0 items-center gap-2 px-8 py-3", $.mobileTitleRow),
|
|
1252
|
+
children: [/* @__PURE__ */ V("h1", {
|
|
1253
|
+
className: v("truncate", R),
|
|
1254
|
+
children: g
|
|
1255
|
+
}), l && /* @__PURE__ */ V("span", {
|
|
1256
|
+
className: v("shrink-0", z, $.subtitleText),
|
|
1044
1257
|
children: e.deletedStateLabel
|
|
1045
1258
|
})]
|
|
1046
1259
|
}),
|
|
1047
|
-
e.activeStatusAnnouncement != null && /* @__PURE__ */
|
|
1260
|
+
e.activeStatusAnnouncement != null && /* @__PURE__ */ V("span", {
|
|
1048
1261
|
role: "status",
|
|
1049
1262
|
"aria-live": "polite",
|
|
1050
1263
|
className: "sr-only",
|
|
1051
1264
|
children: e.activeStatusAnnouncement
|
|
1052
1265
|
}),
|
|
1053
|
-
|
|
1266
|
+
e.startStatusAnnouncement != null && /* @__PURE__ */ V("span", {
|
|
1267
|
+
role: "status",
|
|
1268
|
+
"aria-live": "polite",
|
|
1269
|
+
className: "sr-only",
|
|
1270
|
+
children: e.startStatusAnnouncement
|
|
1271
|
+
}),
|
|
1272
|
+
y && /* @__PURE__ */ V("div", {
|
|
1054
1273
|
className: "flex flex-1 items-center justify-center",
|
|
1055
|
-
children: /* @__PURE__ */
|
|
1274
|
+
children: /* @__PURE__ */ V(me, {})
|
|
1056
1275
|
}),
|
|
1057
|
-
!
|
|
1276
|
+
!y && x && /* @__PURE__ */ H("div", {
|
|
1058
1277
|
className: "flex flex-1 flex-col items-center justify-center gap-3",
|
|
1059
|
-
children: [/* @__PURE__ */
|
|
1060
|
-
className:
|
|
1278
|
+
children: [/* @__PURE__ */ V("p", {
|
|
1279
|
+
className: v(z, $.subtitleText),
|
|
1061
1280
|
children: e.errorLabel
|
|
1062
|
-
}), /* @__PURE__ */
|
|
1281
|
+
}), /* @__PURE__ */ V(k, {
|
|
1063
1282
|
label: e.retryLabel,
|
|
1064
|
-
onClick:
|
|
1283
|
+
onClick: S
|
|
1065
1284
|
})]
|
|
1066
1285
|
}),
|
|
1067
|
-
!
|
|
1068
|
-
className: "flex flex-1 flex-col",
|
|
1069
|
-
children: [/* @__PURE__ */
|
|
1286
|
+
!y && !x && (Ae ? /* @__PURE__ */ H("div", {
|
|
1287
|
+
className: "flex min-h-0 flex-1 flex-col overflow-y-auto",
|
|
1288
|
+
children: [/* @__PURE__ */ V(ge, {
|
|
1070
1289
|
ariaLabel: e.tabsAriaLabel ?? "Scheduled task sections",
|
|
1071
1290
|
className: "px-8",
|
|
1072
|
-
tabs:
|
|
1073
|
-
activeTabId:
|
|
1074
|
-
onTabChange:
|
|
1075
|
-
}), /* @__PURE__ */
|
|
1291
|
+
tabs: G,
|
|
1292
|
+
activeTabId: B,
|
|
1293
|
+
onTabChange: Ne
|
|
1294
|
+
}), /* @__PURE__ */ V("div", {
|
|
1076
1295
|
role: "tabpanel",
|
|
1077
|
-
"aria-label":
|
|
1296
|
+
"aria-label": K,
|
|
1078
1297
|
className: "flex flex-1 flex-col gap-5 px-8 py-6",
|
|
1079
|
-
children:
|
|
1298
|
+
children: B === $e.Configuration ? q : B === $e.History ? J(et.Flow) : Pe
|
|
1080
1299
|
})]
|
|
1081
|
-
}) : /* @__PURE__ */
|
|
1300
|
+
}) : /* @__PURE__ */ H("div", {
|
|
1082
1301
|
style: {
|
|
1083
1302
|
flexDirection: "row",
|
|
1084
|
-
|
|
1085
|
-
"--st-
|
|
1086
|
-
"--st-history-
|
|
1087
|
-
"--st-
|
|
1088
|
-
"--st-configuration-min-width": L?.configurationMinWidth
|
|
1303
|
+
"--st-details-width": P?.detailsWidth,
|
|
1304
|
+
"--st-history-width": P?.historyWidth,
|
|
1305
|
+
"--st-history-max-height": P?.historyMaxHeight,
|
|
1306
|
+
"--st-configuration-min-width": P?.configurationMinWidth
|
|
1089
1307
|
},
|
|
1090
|
-
className: "flex flex-1",
|
|
1308
|
+
className: "flex min-h-0 flex-1 overflow-y-auto desktop:overflow-hidden",
|
|
1091
1309
|
children: [
|
|
1092
|
-
/* @__PURE__ */
|
|
1310
|
+
/* @__PURE__ */ H("div", {
|
|
1093
1311
|
role: "group",
|
|
1094
1312
|
"aria-label": e.detailsTitle,
|
|
1095
1313
|
style: {
|
|
1096
|
-
flex: `0 1 ${
|
|
1314
|
+
flex: `0 1 ${P?.detailsWidth ?? "360px"}`,
|
|
1097
1315
|
maxWidth: "100%"
|
|
1098
1316
|
},
|
|
1099
|
-
className:
|
|
1100
|
-
children: [/* @__PURE__ */
|
|
1101
|
-
className:
|
|
1317
|
+
className: v("flex min-h-0 w-full flex-col gap-5 overflow-y-auto border-e px-8 py-6", $.detailsColumn),
|
|
1318
|
+
children: [/* @__PURE__ */ V("h2", {
|
|
1319
|
+
className: Te,
|
|
1102
1320
|
children: e.detailsTitle
|
|
1103
|
-
}),
|
|
1321
|
+
}), Pe]
|
|
1104
1322
|
}),
|
|
1105
|
-
/* @__PURE__ */
|
|
1323
|
+
/* @__PURE__ */ H("div", {
|
|
1106
1324
|
style: {
|
|
1107
|
-
flex: `1 1 ${
|
|
1325
|
+
flex: `1 1 ${P?.configurationMinWidth ?? "320px"}`,
|
|
1108
1326
|
minWidth: 0
|
|
1109
1327
|
},
|
|
1110
|
-
className: "flex w-full min-w-0 flex-col gap-5 px-8 py-6",
|
|
1111
|
-
children: [/* @__PURE__ */
|
|
1112
|
-
className:
|
|
1328
|
+
className: "flex min-h-0 w-full min-w-0 flex-col gap-5 overflow-y-auto px-8 py-6",
|
|
1329
|
+
children: [/* @__PURE__ */ V("h2", {
|
|
1330
|
+
className: Te,
|
|
1113
1331
|
children: e.configurationTitle
|
|
1114
|
-
}),
|
|
1332
|
+
}), q]
|
|
1115
1333
|
}),
|
|
1116
|
-
/* @__PURE__ */
|
|
1334
|
+
/* @__PURE__ */ V("div", {
|
|
1117
1335
|
style: {
|
|
1118
|
-
flex: `0 1 calc(${
|
|
1336
|
+
flex: `0 1 calc(${P?.historyWidth ?? "360px"} + 48px)`,
|
|
1119
1337
|
minWidth: 0
|
|
1120
1338
|
},
|
|
1121
|
-
className: "flex w-full items-start justify-center p-6",
|
|
1122
|
-
children:
|
|
1339
|
+
className: "flex min-h-0 w-full items-start justify-center overflow-y-auto p-6",
|
|
1340
|
+
children: J(et.Card)
|
|
1123
1341
|
})
|
|
1124
1342
|
]
|
|
1125
1343
|
}))
|
|
1126
1344
|
]
|
|
1127
1345
|
});
|
|
1128
|
-
},
|
|
1129
|
-
let
|
|
1130
|
-
return /* @__PURE__ */
|
|
1346
|
+
}, dt = ({ modelLabel: e, skillLabel: t, skillDisplayNames: n, instructionsLabel: r, modelDisplayName: i, instructionsMarkdown: a, renderInstructions: o, markdownLabels: s, styles: c }) => {
|
|
1347
|
+
let l = c?.typography?.fieldLabelClassName ?? "dial-tiny-text", u = c?.typography?.fieldValueClassName ?? "dial-body-text";
|
|
1348
|
+
return /* @__PURE__ */ H("div", {
|
|
1131
1349
|
className: "flex flex-col gap-3",
|
|
1132
|
-
children: [
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
className:
|
|
1145
|
-
children:
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
};
|
|
1153
|
-
return /* @__PURE__ */ W(A, {
|
|
1154
|
-
open: e,
|
|
1155
|
-
className: f?.popupClassName,
|
|
1156
|
-
header: /* @__PURE__ */ W("span", {
|
|
1157
|
-
className: f?.titleClassName,
|
|
1158
|
-
children: n
|
|
1159
|
-
}),
|
|
1160
|
-
onClose: p,
|
|
1161
|
-
mainButtons: [{
|
|
1162
|
-
label: a,
|
|
1163
|
-
onClick: p,
|
|
1164
|
-
disabled: l,
|
|
1165
|
-
appearance: o
|
|
1166
|
-
}, {
|
|
1167
|
-
label: l ? c ?? s : s,
|
|
1168
|
-
onClick: () => {
|
|
1169
|
-
l || u();
|
|
1170
|
-
},
|
|
1171
|
-
disabled: l,
|
|
1172
|
-
variant: y.Danger,
|
|
1173
|
-
className: f?.actionClassName
|
|
1174
|
-
}],
|
|
1175
|
-
children: /* @__PURE__ */ G("div", {
|
|
1176
|
-
className: "flex flex-col gap-4 px-6 pb-4 pt-2",
|
|
1177
|
-
children: [
|
|
1178
|
-
/* @__PURE__ */ W("div", {
|
|
1179
|
-
className: "flex h-11 items-center rounded-lg border border-error-alpha bg-error px-3",
|
|
1180
|
-
children: /* @__PURE__ */ W("span", {
|
|
1181
|
-
className: "dial-small-semi-text truncate",
|
|
1182
|
-
children: t
|
|
1183
|
-
})
|
|
1184
|
-
}),
|
|
1185
|
-
/* @__PURE__ */ W("div", {
|
|
1186
|
-
className: "dial-body-paragraph-text break-words",
|
|
1187
|
-
children: r
|
|
1188
|
-
}),
|
|
1189
|
-
i.length > 0 && /* @__PURE__ */ W("ul", {
|
|
1190
|
-
className: "flex flex-col gap-2 ps-[18px]",
|
|
1191
|
-
children: i.map((e, t) => /* @__PURE__ */ W("li", {
|
|
1192
|
-
className: "dial-body-paragraph-text list-disc text-secondary marker:text-secondary",
|
|
1350
|
+
children: [
|
|
1351
|
+
i && /* @__PURE__ */ H("div", {
|
|
1352
|
+
className: "flex flex-col gap-2",
|
|
1353
|
+
children: [/* @__PURE__ */ V("span", {
|
|
1354
|
+
className: l,
|
|
1355
|
+
children: e
|
|
1356
|
+
}), /* @__PURE__ */ V("p", {
|
|
1357
|
+
className: u,
|
|
1358
|
+
children: i
|
|
1359
|
+
})]
|
|
1360
|
+
}),
|
|
1361
|
+
!!n?.length && /* @__PURE__ */ H("div", {
|
|
1362
|
+
className: "flex min-w-0 flex-col gap-2",
|
|
1363
|
+
children: [/* @__PURE__ */ V("span", {
|
|
1364
|
+
className: l,
|
|
1365
|
+
children: t
|
|
1366
|
+
}), /* @__PURE__ */ V("p", {
|
|
1367
|
+
className: `${u} whitespace-normal break-all`,
|
|
1368
|
+
children: n?.map((e, t) => /* @__PURE__ */ V("span", {
|
|
1369
|
+
className: "block",
|
|
1193
1370
|
children: e
|
|
1194
|
-
}, t))
|
|
1195
|
-
})
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1371
|
+
}, `${t}:${e}`))
|
|
1372
|
+
})]
|
|
1373
|
+
}),
|
|
1374
|
+
a && /* @__PURE__ */ H("div", {
|
|
1375
|
+
className: "flex flex-col gap-2",
|
|
1376
|
+
children: [/* @__PURE__ */ V("span", {
|
|
1377
|
+
className: l,
|
|
1378
|
+
children: r
|
|
1379
|
+
}), ((e) => o ? o(e) : /* @__PURE__ */ V(p, {
|
|
1380
|
+
content: e,
|
|
1381
|
+
...s
|
|
1382
|
+
}))(a)]
|
|
1383
|
+
})
|
|
1384
|
+
]
|
|
1204
1385
|
});
|
|
1205
|
-
}
|
|
1386
|
+
}, ft = ({ taskName: e, icon: t, typeLabel: n, body: r, pendingLabel: i, isDeleting: a = !1, styles: o, ...s }) => /* @__PURE__ */ V(l, {
|
|
1387
|
+
...s,
|
|
1388
|
+
variant: E.Danger,
|
|
1389
|
+
popupClassName: o?.popupClassName,
|
|
1390
|
+
titleClassName: o?.titleClassName,
|
|
1391
|
+
messageClassName: o?.messageClassName ?? "dial-body-paragraph-text",
|
|
1392
|
+
message: r,
|
|
1393
|
+
isLoading: a,
|
|
1394
|
+
loadingStatusLabel: i,
|
|
1395
|
+
identity: /* @__PURE__ */ V(h, { children: /* @__PURE__ */ V(u, {
|
|
1396
|
+
icon: t,
|
|
1397
|
+
typeLabel: n,
|
|
1398
|
+
name: e,
|
|
1399
|
+
styles: { colors: o?.colors }
|
|
1400
|
+
}) })
|
|
1401
|
+
});
|
|
1206
1402
|
//#endregion
|
|
1207
|
-
export { r as DESCRIPTION_MAX_LENGTH,
|
|
1403
|
+
export { r as DESCRIPTION_MAX_LENGTH, W as SCHEDULED_TASKS_CLASS, Ie as ScheduledTaskCard, Ve as ScheduledTaskCardGrid, Be as ScheduledTaskCardSkeleton, Qe as ScheduledTaskCreateForm, ft as ScheduledTaskDeleteConfirmation, ut as ScheduledTaskDetailView, dt as ScheduledTaskDetailsSummary, lt as ScheduledTaskHistorySection, K as ScheduledTaskPresentationStatus, t as ScheduledTaskRepeat, st as ScheduledTaskRunHistoryList, at as ScheduledTaskRunStatus, G as ScheduledTaskStatus, Ge as ScheduledTasks, Ke as ScheduledTasksSortKey, c as TIME_OF_DAY_PATTERN, Pe as getScheduledTaskStatus, Je as hasScheduledTaskFormChanges };
|