@epam/ai-dial-scheduled-tasks 1.2.0-dev.15 → 1.2.0-dev.153

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