@epam/ai-dial-scheduled-tasks 1.2.0-dev.3 → 1.2.0-dev.300

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 (67) 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 +59 -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 +13 -2
  26. package/index.d.ts.map +1 -1
  27. package/index.js +998 -629
  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 +7 -0
  33. package/models/scheduled-task-configuration-section-props.d.ts.map +1 -1
  34. package/models/scheduled-task-create-form-props.d.ts +51 -4
  35. package/models/scheduled-task-create-form-props.d.ts.map +1 -1
  36. package/models/scheduled-task-detail-view-props.d.ts +52 -3
  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 +7 -0
  41. package/models/scheduled-task-details-summary-props.d.ts.map +1 -1
  42. package/models/scheduled-task-history-section-props.d.ts +21 -2
  43. package/models/scheduled-task-history-section-props.d.ts.map +1 -1
  44. package/models/scheduled-task-instructions.d.ts +18 -0
  45. package/models/scheduled-task-instructions.d.ts.map +1 -0
  46. package/models/scheduled-task-item.d.ts +20 -0
  47. package/models/scheduled-task-item.d.ts.map +1 -1
  48. package/models/scheduled-task-run-history-list-props.d.ts +8 -0
  49. package/models/scheduled-task-run-history-list-props.d.ts.map +1 -1
  50. package/models/scheduled-tasks-props.d.ts +9 -1
  51. package/models/scheduled-tasks-props.d.ts.map +1 -1
  52. package/package.json +9 -4
  53. package/types/scheduled-task-status.d.ts +15 -0
  54. package/types/scheduled-task-status.d.ts.map +1 -0
  55. package/utils/calendar-value.d.ts +2 -0
  56. package/utils/calendar-value.d.ts.map +1 -1
  57. package/utils/scheduled-task-form-values.d.ts +4 -0
  58. package/utils/scheduled-task-form-values.d.ts.map +1 -0
  59. package/utils/scheduled-task-status.d.ts +5 -0
  60. package/utils/scheduled-task-status.d.ts.map +1 -0
  61. package/validation/index.d.ts +3 -0
  62. package/validation/index.d.ts.map +1 -0
  63. package/validation/scheduled-task-validation.d.ts +57 -0
  64. package/validation/scheduled-task-validation.d.ts.map +1 -0
  65. package/validation.d.ts +3 -0
  66. package/validation.d.ts.map +1 -0
  67. package/validation.js +34 -0
package/index.js CHANGED
@@ -1,316 +1,461 @@
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 { ConfirmationDialog as l, ConfirmationIdentityCard as u, ConfirmationIdentityRow as d, MARKDOWN_EDITOR_MAX_HEIGHT_CLASS_NAME as f, MARKDOWN_EDITOR_PREVIEW_LIST_CLASS_NAME as p, MDMessageViewer as m, PanelEmptyState as ee, TextRefinementField as h, buildCssVars as g, mergeClasses as _, useAvailableHeightCap as v, useIsMobile as y, useTextRefinement as b, useUnsavedChangesGuard as x } from "@epam/ai-dial-chat-shared";
3
+ import { ButtonAppearance as te, ButtonDropdown as ne, ButtonVariant as re, Calendar as S, CalendarMode as C, CardShell as w, ConfirmationPopupVariant as T, DIAL_ICON_SIZE as E, DIAL_KIT_ICON_STROKE as D, ElementSize as ie, FolderPath as O, 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
+ //#region src/constants/public-class-names.ts
10
+ var W = {
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
+ }({}), 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: E.SM,
44
+ "aria-hidden": !0,
45
+ stroke: D
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: E.SM,
54
+ "aria-hidden": !0,
55
+ stroke: D
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: _(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", ee = u?.pausedBadgeClassName ?? "dial-tiny-text", h = u?.completedBadgeClassName ?? "dial-tiny-text", v = u?.locationLabelClassName ?? "dial-tiny-text", y = u?.locationLeafClassName ?? "dial-tiny-semi-text", b = u?.newBadgeClassName ?? "dial-tiny-semi-text", x = Pe(e), { text: te, textClassName: ne } = {
73
+ [G.Scheduled]: {
74
+ text: e.scheduleLabel,
75
+ textClassName: m
76
+ },
77
+ [G.Paused]: {
78
+ text: s,
79
+ textClassName: ee
80
+ },
81
+ [G.Completed]: {
82
+ text: c,
83
+ textClassName: h
84
+ }
85
+ }[x], re = g({
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
+ }), S = 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__ */ H(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: re,
113
+ className: _("h-[var(--st-card-height,232px)]", n && "cursor-pointer", a, W.card),
114
+ ...S,
47
115
  children: [
48
- /* @__PURE__ */ V("div", {
116
+ /* @__PURE__ */ H("div", {
49
117
  className: "flex min-w-0 shrink-0 items-center gap-2",
50
- children: [/* @__PURE__ */ B(b, {
118
+ children: [/* @__PURE__ */ V(oe, {
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: _(d, Y.title)
123
+ }), e.isNew && /* @__PURE__ */ V("span", {
124
+ className: _("shrink-0 rounded-full px-2 py-0.5", b, Y.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__ */ V("p", {
129
+ className: _("line-clamp-4 min-h-0 flex-1 overflow-hidden", p, f, Y.description),
62
130
  children: e.descriptionPreview
63
131
  }),
64
- /* @__PURE__ */ V("div", {
132
+ /* @__PURE__ */ H("div", {
65
133
  className: "mt-auto flex shrink-0 flex-col gap-3",
66
- children: [/* @__PURE__ */ B("div", {
134
+ children: [/* @__PURE__ */ V("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__ */ V(Fe, {
137
+ status: x,
138
+ text: te,
139
+ textClassName: ne
78
140
  })
79
- }), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ B(_, {
141
+ }), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ V(O, {
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: _(v, Y.locationLabel),
144
+ leafClassName: _(y, Y.locationLeaf),
145
+ className: _("pt-3", Y.locationDivider)
84
146
  })]
85
147
  })
86
148
  ]
87
149
  });
88
- }, ge = { card: "_card_11bez_1" }, _e = [
150
+ }, Le = { card: "_card_11bez_1" }, Re = [
89
151
  "100%",
90
152
  "100%",
91
153
  "61%"
92
- ], W = "var(--stcs-skeleton-bg)", G = ({ styles: e }) => /* @__PURE__ */ V(p, {
154
+ ], ze = "var(--stcs-skeleton-bg)", Be = ({ styles: e }) => /* @__PURE__ */ H(w, {
93
155
  "aria-hidden": !0,
94
- style: i({ "--stcs-skeleton-bg": e?.colors?.skeletonColor }),
95
- className: a("h-[232px]", ge.card),
156
+ style: g({ "--stcs-skeleton-bg": e?.colors?.skeletonColor }),
157
+ className: _("h-[var(--st-card-height,232px)]", Le.card),
96
158
  children: [
97
- /* @__PURE__ */ B(E, {
98
- variant: D.Rectangular,
159
+ /* @__PURE__ */ V(j, {
160
+ variant: M.Rectangular,
99
161
  width: "60%",
100
162
  height: "20px",
101
- color: W,
163
+ color: ze,
102
164
  className: "shrink-0"
103
165
  }),
104
- /* @__PURE__ */ B("div", {
166
+ /* @__PURE__ */ V("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: Re.map((e, t) => /* @__PURE__ */ V(j, {
169
+ variant: M.Rectangular,
108
170
  width: e,
109
171
  height: "16px",
110
- color: W
172
+ color: ze
111
173
  }, t))
112
174
  }),
113
- /* @__PURE__ */ B(E, {
114
- variant: D.Rectangular,
175
+ /* @__PURE__ */ V(j, {
176
+ variant: M.Rectangular,
115
177
  width: "110px",
116
178
  height: "28px",
117
- color: W,
179
+ color: ze,
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
+ }), Ve = ({ items: e, searchQuery: t, onCardClick: n, labels: r, cardStyles: i, trailingSkeletonCount: a = 0, skeletonStyles: o, layout: s }) => /* @__PURE__ */ H("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: _("mx-auto grid w-full min-w-0", W.cardGrid),
194
+ children: [e.map((e) => /* @__PURE__ */ V(Ie, {
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__ */ V(Be, { styles: o }, `skeleton-${t}`))]
201
+ }), X = {
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
+ }, He = /* @__PURE__ */ V(F, {
209
+ size: 48,
210
+ stroke: 1,
211
+ "aria-hidden": !0
212
+ }), Ue = (e, t, n, r, i, a) => {
137
213
  if (!e) return t ? a.loadingMoreLabel : n ? a.errorLabel : r > 0 ? `${r}` : i ? a.noResultsLabel : a.emptyStateLabel;
138
- }, be = (e) => {
214
+ }, We = (e) => {
139
215
  if (!e || e === document.body) return null;
140
216
  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);
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: m, banner: h, styles: v, sortIcon: y, className: b, gridLayout: x, cardStyles: S, loadMoreError: C, onRetryLoadMore: w }) => {
219
+ let { colors: T, typography: O } = v ?? {}, ae = O?.titleClassName ?? "dial-h1-text", oe = O?.subtitleClassName ?? "dial-body-text", se = g({
220
+ "--st-bg": T?.background,
221
+ "--st-subtitle-text": T?.subtitleText,
222
+ "--st-sort-text": T?.sortButtonText
223
+ }), ce = (e) => {
224
+ r(e ?? "");
225
+ }, [ue, de] = je(!1), [pe, j] = je(!1), M = B(null), he = z(() => {
226
+ j(!0);
227
+ }, []), ge = z(() => {
228
+ j(!1);
153
229
  }, []);
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) => ({
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) => ({
159
235
  key: e.value,
160
236
  label: e.label,
161
- mark: C.Check,
162
- checked: e.value === s,
163
- onClick: () => d(e.value)
237
+ mark: le.Check,
238
+ checked: e.value === i,
239
+ onClick: () => a(e.value)
164
240
  })), [
165
241
  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);
242
+ i,
243
+ a
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);
173
249
  if (!t) return;
174
250
  let n = () => {
175
- if (x || p || !b) return;
251
+ if (d || s || C || !u) return;
176
252
  let n = t.getBoundingClientRect(), r = e.getBoundingClientRect();
177
- r.top < n.bottom && r.bottom > n.top && w();
253
+ r.top < n.bottom && r.bottom > n.top && p();
178
254
  };
179
255
  return t.addEventListener("scroll", n, { passive: !0 }), n(), () => t.removeEventListener("scroll", n);
180
256
  }, [
181
- b,
182
- x,
183
- p,
184
- w
257
+ u,
258
+ d,
259
+ s,
260
+ C,
261
+ p
185
262
  ]);
186
- let me = () => p ? /* @__PURE__ */ B(O, {}) : _ ? /* @__PURE__ */ V("div", {
263
+ let xe = () => s ? /* @__PURE__ */ V(me, {}) : c ? /* @__PURE__ */ H("div", {
187
264
  className: "flex flex-col items-center gap-3",
188
- children: [/* @__PURE__ */ B("p", {
189
- className: a(A, K.subtitle),
265
+ children: [/* @__PURE__ */ V("p", {
266
+ className: _(oe, X.subtitle),
190
267
  children: e.errorLabel
191
- }), /* @__PURE__ */ B(v, {
268
+ }), /* @__PURE__ */ V(k, {
192
269
  label: e.retryLabel,
193
- onClick: y
270
+ onClick: l
194
271
  })]
195
- }) : f.length === 0 ? n.trim() ? /* @__PURE__ */ B("p", {
196
- className: a(A, K.subtitle),
272
+ }) : o.length === 0 ? n.trim() ? /* @__PURE__ */ V("p", {
273
+ className: _(oe, X.subtitle),
197
274
  children: e.noResultsLabel
198
- }) : /* @__PURE__ */ B(r, { label: e.emptyStateLabel }) : /* @__PURE__ */ V("div", {
275
+ }) : /* @__PURE__ */ V(ee, {
276
+ label: e.emptyStateLabel,
277
+ icon: He
278
+ }) : /* @__PURE__ */ H("div", {
199
279
  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
280
  children: [
281
+ /* @__PURE__ */ V(Ve, {
282
+ items: o,
283
+ searchQuery: n,
284
+ onCardClick: m,
285
+ labels: e.cardLabels,
286
+ trailingSkeletonCount: d ? f : 0,
287
+ skeletonStyles: { colors: { skeletonColor: T?.skeletonColor } },
288
+ cardStyles: S,
289
+ layout: x
290
+ }),
291
+ C && /* @__PURE__ */ H("div", {
292
+ role: "alert",
293
+ className: "flex items-center gap-3",
294
+ children: [/* @__PURE__ */ V("span", {
295
+ className: _(oe, X.subtitle),
296
+ children: e.loadMoreErrorLabel ?? e.errorLabel
297
+ }), /* @__PURE__ */ V(k, {
298
+ label: e.retryLabel,
299
+ onClick: w
300
+ })]
301
+ }),
217
302
  /* @__PURE__ */ V("div", {
303
+ ref: be,
304
+ "aria-hidden": !0,
305
+ className: "h-px w-full"
306
+ })
307
+ ]
308
+ }), P = s || !!c || o.length === 0;
309
+ return /* @__PURE__ */ H("div", {
310
+ style: se,
311
+ className: _("flex h-full w-full flex-col gap-6 overflow-y-auto px-8 py-4", X.container, b),
312
+ children: [
313
+ /* @__PURE__ */ H("div", {
218
314
  className: "flex items-start justify-between gap-4",
219
- children: [/* @__PURE__ */ V("div", {
315
+ children: [/* @__PURE__ */ H("div", {
220
316
  className: "min-w-0 gap-2",
221
- children: [/* @__PURE__ */ B("h1", {
222
- className: a("truncate", re),
317
+ children: [/* @__PURE__ */ V("h1", {
318
+ className: _("truncate", ae),
223
319
  children: e.title
224
- }), /* @__PURE__ */ B("p", {
225
- className: a("mt-1", A, K.subtitle),
320
+ }), /* @__PURE__ */ V("p", {
321
+ className: _("mt-1", oe, X.subtitle),
226
322
  children: e.subtitle
227
323
  })]
228
- }), /* @__PURE__ */ B(te, {
324
+ }), /* @__PURE__ */ V(fe, {
229
325
  label: e.createButtonLabel,
230
- textClassName: "hidden desktop:inline",
326
+ textClassName: X.createButtonLabel,
231
327
  "aria-label": e.createButtonLabel,
232
- iconBefore: /* @__PURE__ */ B(ce, {
233
- size: m.SM,
328
+ iconBefore: /* @__PURE__ */ V(R, {
329
+ size: E.SM,
234
330
  "aria-hidden": !0,
235
- stroke: h
331
+ stroke: D
236
332
  }),
237
333
  onClick: t,
238
- className: a("shrink-0", K.createButton)
334
+ className: _("shrink-0", X.createButton)
239
335
  })]
240
336
  }),
241
- /* @__PURE__ */ V("div", {
337
+ /* @__PURE__ */ H("div", {
242
338
  className: "flex flex-wrap items-center gap-3",
243
- children: [/* @__PURE__ */ B("div", {
339
+ children: [/* @__PURE__ */ V("div", {
244
340
  role: "search",
245
341
  className: "flex-1",
246
- children: /* @__PURE__ */ B(T, {
342
+ children: /* @__PURE__ */ V(A, {
247
343
  value: n,
248
- onChange: ie,
344
+ onChange: ce,
249
345
  placeholder: e.searchPlaceholder,
250
346
  clearLabel: e.clearSearchLabel,
251
347
  "aria-label": e.searchAriaLabel,
252
- size: g.Large,
253
- onFocus: le,
254
- onBlur: ue
348
+ size: ie.Large,
349
+ onFocus: he,
350
+ onBlur: ge
255
351
  })
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
352
+ }), e.sortOptions.length > 0 && /* @__PURE__ */ V("div", {
353
+ ref: M,
354
+ className: _(pe && X.sortControlHidden),
355
+ children: /* @__PURE__ */ V(ne, {
356
+ items: ve,
357
+ label: _e,
358
+ variant: re.Primary,
359
+ appearance: te.Ghost,
360
+ iconBefore: y === void 0 ? /* @__PURE__ */ V(N, {
361
+ size: E.SM,
362
+ "aria-hidden": !0,
363
+ stroke: D
364
+ }) : y,
365
+ className: X.sortButton
265
366
  })
266
367
  })]
267
368
  }),
268
- ne,
269
- /* @__PURE__ */ B("span", {
369
+ h,
370
+ /* @__PURE__ */ V("span", {
270
371
  role: "status",
271
372
  "aria-live": "polite",
272
373
  className: "sr-only",
273
- children: z
374
+ children: ye
274
375
  }),
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()
376
+ /* @__PURE__ */ V("div", {
377
+ className: _("mx-auto flex size-full w-full min-w-0 flex-col", P && "items-center justify-center"),
378
+ children: xe()
278
379
  })
279
380
  ]
280
381
  });
281
- }, Se = /* @__PURE__ */ function(e) {
382
+ }, Ke = /* @__PURE__ */ function(e) {
282
383
  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, {
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", {
391
+ className: "flex flex-col gap-1",
392
+ children: [/* @__PURE__ */ V(S, {
393
+ id: "scheduled-task-run-at",
394
+ mode: C.DateTime,
395
+ value: s(t),
396
+ onChange: (e) => r(n(e)),
397
+ minDate: o,
398
+ labelProps: {
399
+ label: e,
400
+ required: !0
401
+ },
402
+ invalid: !!i
403
+ }), i && /* @__PURE__ */ V("p", {
404
+ className: _(a, Ye.error),
405
+ children: i
406
+ })]
407
+ });
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: d, modelLabelId: m, skillSelector: ee, onFieldChange: y, onBack: te, onCancel: ne, onSubmit: re, isSubmitting: w = !1, onRefineDescription: ie, onRefineInstructions: O, 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 = b({
425
+ value: r.description ?? "",
426
+ onChange: (e) => y("description", e),
427
+ onRefine: j(ie),
428
+ disabled: w
429
+ }), he = b({
430
+ value: r.prompt,
431
+ onChange: (e) => y("prompt", e),
432
+ onRefine: j(O),
433
+ disabled: w
434
+ }), ge = M.isPending || he.isPending, ve = () => {
435
+ M.reset(), he.reset();
436
+ }, N = x(!!(s && Je(r, s))), be = () => N.guard(() => {
437
+ ve(), te();
438
+ }), xe = () => N.guard(() => {
439
+ ve(), ne();
440
+ }), P = v(), 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 = 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: _(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), y("time", e.target.value);
451
+ }, q = (e) => {
452
+ Ce(void 0), y("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) => y("runAt", e), Ie = w || 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, {
314
459
  labels: {
315
460
  title: n.pageTitle,
316
461
  backButtonLabel: n.backButtonLabel,
@@ -318,189 +463,212 @@ var U = {
318
463
  submitButtonLabel: n.createButtonLabel,
319
464
  submittingLabel: n.submittingLabel ?? "Saving"
320
465
  },
321
- onBack: p,
322
- onCancel: m,
323
- onSubmit: h,
324
- isCancelDisabled: g,
325
- isSubmitDisabled: j,
326
- isSubmitting: g,
466
+ onBack: be,
467
+ onCancel: xe,
468
+ onSubmit: () => {
469
+ !Ie && (!A.current || A.current.aborted) && re();
470
+ },
471
+ isCancelDisabled: w,
472
+ isSubmitDisabled: Ie,
473
+ isSubmitting: w,
474
+ backIcon: ae === void 0 ? /* @__PURE__ */ V(ye, {
475
+ size: E.LG,
476
+ stroke: D,
477
+ "aria-hidden": !0,
478
+ className: "rtl:scale-x-[-1]"
479
+ }) : ae,
480
+ layout: {
481
+ sideColumnWidth: we?.detailsWidth,
482
+ columnGap: we?.columnGap,
483
+ reserveEndColumn: !1
484
+ },
485
+ className: oe,
327
486
  styles: {
328
- colors: { background: C?.background },
487
+ colors: { background: L?.background },
329
488
  header: {
330
- colors: { borderColor: C?.headerBorder },
331
- typography: { fontClassName: te }
489
+ colors: { borderColor: L?.headerBorder },
490
+ typography: { fontClassName: Ee }
332
491
  },
333
- cssVars: re
492
+ cssVars: G
334
493
  },
335
- left: /* @__PURE__ */ V("div", {
494
+ left: /* @__PURE__ */ H("div", {
336
495
  role: "group",
337
496
  "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),
497
+ className: _("flex flex-1 flex-col gap-5 border-e py-6", Z.detailsColumn, Z.formColumn),
339
498
  children: [
340
- /* @__PURE__ */ V("div", {
499
+ /* @__PURE__ */ H("div", {
341
500
  className: "flex flex-col gap-1",
342
- children: [/* @__PURE__ */ B("h2", {
343
- className: T,
501
+ children: [/* @__PURE__ */ V("h2", {
502
+ className: z,
344
503
  children: n.detailsSectionTitle
345
- }), /* @__PURE__ */ B("p", {
346
- className: a(E, Y.sectionSubtitle),
504
+ }), /* @__PURE__ */ V("p", {
505
+ className: _(ke, Z.sectionSubtitle),
347
506
  children: n.detailsSectionSubtitle
348
507
  })]
349
508
  }),
350
- /* @__PURE__ */ B(x, {
509
+ /* @__PURE__ */ V(se, {
351
510
  id: "scheduled-task-display-name",
352
511
  value: r.displayName,
353
- onChange: (e) => u("displayName", e ?? ""),
512
+ onChange: (e) => y("displayName", e ?? ""),
354
513
  labelProps: {
355
514
  label: n.displayNameLabel,
356
515
  required: !0
357
516
  },
358
- invalid: !!s.displayName,
359
- error: s.displayName
517
+ invalid: !!u.displayName,
518
+ error: u.displayName
360
519
  }),
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
520
+ /* @__PURE__ */ V(h, {
521
+ isEnabled: !!ie,
522
+ fieldId: ue,
523
+ label: n.descriptionLabel,
524
+ labels: n,
525
+ refinement: M,
526
+ disabled: w || ge,
527
+ ...K,
528
+ children: /* @__PURE__ */ V(_e, {
529
+ id: ue,
530
+ value: r.description ?? "",
531
+ onChange: (e) => {
532
+ M.reset(), y("description", e);
533
+ },
534
+ labelProps: ie ? 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
+ })
370
540
  }),
371
- /* @__PURE__ */ V("div", {
541
+ /* @__PURE__ */ H("div", {
372
542
  className: "flex flex-col gap-1",
373
543
  children: [
374
- /* @__PURE__ */ B(S, {
375
- id: l,
544
+ /* @__PURE__ */ V(ce, {
545
+ id: m,
376
546
  label: n.modelOrAgentLabel,
377
547
  required: !0
378
548
  }),
379
- c,
380
- s.modelId && /* @__PURE__ */ B("p", {
381
- className: a(k, Y.instructionsError),
382
- children: s.modelId
549
+ d,
550
+ u.modelId && /* @__PURE__ */ V("p", {
551
+ className: _(U, Z.instructionsError),
552
+ children: u.modelId
383
553
  })
384
554
  ]
385
555
  }),
386
- /* @__PURE__ */ V("div", {
556
+ /* @__PURE__ */ H("div", {
387
557
  className: "flex flex-col gap-3",
388
558
  children: [
389
- /* @__PURE__ */ B(ne, {
559
+ /* @__PURE__ */ V(pe, {
390
560
  labelProps: { label: n.repeatLabel },
391
561
  value: r.repeat,
392
- onChange: (e) => u("repeat", e),
562
+ onChange: (e) => y("repeat", e),
393
563
  options: n.repeatOptions.map((e) => ({
394
564
  value: e.key,
395
565
  label: e.label
396
566
  }))
397
567
  }),
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
- })]
568
+ r.repeat === t.OneTime && /* @__PURE__ */ V(Xe, {
569
+ label: n.runAtLabel,
570
+ value: r.runAt ?? "",
571
+ onChange: Y,
572
+ error: u.runAt,
573
+ errorClassName: U
414
574
  }),
415
- r.repeat !== q.OneTime && /* @__PURE__ */ V(z, { children: [
416
- r.repeat !== q.Hourly && /* @__PURE__ */ V("div", {
575
+ r.repeat !== t.OneTime && /* @__PURE__ */ H(Me, { children: [
576
+ J && /* @__PURE__ */ H("div", {
417
577
  className: "flex flex-col gap-1",
418
- children: [/* @__PURE__ */ B(d, {
578
+ children: [/* @__PURE__ */ V(S, {
419
579
  id: "scheduled-task-time",
420
- mode: f.Time,
580
+ mode: C.Time,
421
581
  value: r.time,
422
- onChange: (e) => u("time", typeof e == "string" ? e : ""),
582
+ onChange: q,
583
+ onBlur: Pe,
423
584
  labelProps: {
424
585
  label: n.timeLabel,
425
586
  required: !0
426
587
  },
427
- invalid: !!s.time
428
- }), s.time && /* @__PURE__ */ B("p", {
429
- className: a(k, Y.instructionsError),
430
- children: s.time
588
+ invalid: !!Fe,
589
+ disabled: w,
590
+ showTimezone: !0
591
+ }), Fe && /* @__PURE__ */ V("p", {
592
+ className: _(U, Z.instructionsError),
593
+ children: Fe
431
594
  })]
432
595
  }),
433
- r.repeat === q.Weekly && /* @__PURE__ */ V("div", {
596
+ r.repeat === t.Weekly && /* @__PURE__ */ H("div", {
434
597
  className: "flex flex-col gap-1",
435
- children: [/* @__PURE__ */ B(d, {
598
+ children: [/* @__PURE__ */ V(S, {
436
599
  id: "scheduled-task-day-of-week",
437
- mode: f.Weekday,
438
- value: Oe(r.dayOfWeek),
439
- onChange: (e) => u("dayOfWeek", ke(e)),
600
+ mode: C.Weekday,
601
+ value: a(r.dayOfWeek),
602
+ onChange: (e) => y("dayOfWeek", o(e)),
440
603
  labelProps: {
441
604
  label: n.dayOfWeekLabel,
442
605
  required: !0
443
606
  },
444
- invalid: !!s.dayOfWeek
445
- }), s.dayOfWeek && /* @__PURE__ */ B("p", {
446
- className: a(k, Y.instructionsError),
447
- children: s.dayOfWeek
607
+ invalid: !!u.dayOfWeek
608
+ }), u.dayOfWeek && /* @__PURE__ */ V("p", {
609
+ className: _(U, Z.instructionsError),
610
+ children: u.dayOfWeek
448
611
  })]
449
612
  }),
450
- r.repeat === q.Monthly && /* @__PURE__ */ B(x, {
613
+ r.repeat === t.Monthly && /* @__PURE__ */ V(de, {
451
614
  id: "scheduled-task-day-of-month",
615
+ integer: !0,
616
+ min: 1,
617
+ max: 31,
452
618
  value: r.dayOfMonth ?? "",
453
- onChange: (e) => u("dayOfMonth", e ?? ""),
619
+ onChange: (e) => y("dayOfMonth", e == null ? "" : String(e)),
454
620
  labelProps: {
455
621
  label: n.dayOfMonthLabel,
456
622
  required: !0
457
623
  },
458
- invalid: !!s.dayOfMonth,
459
- error: s.dayOfMonth
624
+ invalid: !!u.dayOfMonth,
625
+ error: u.dayOfMonth
460
626
  }),
461
- r.repeat === q.Hourly && /* @__PURE__ */ B(ee, {
627
+ r.repeat === t.Hourly && /* @__PURE__ */ V(de, {
462
628
  id: "scheduled-task-minute",
463
629
  integer: !0,
464
630
  min: 0,
465
631
  max: 59,
466
632
  value: r.minute ?? "",
467
- onChange: (e) => u("minute", e == null ? "" : String(e)),
633
+ onChange: (e) => y("minute", e == null ? "" : String(e)),
468
634
  labelProps: {
469
635
  label: n.minuteLabel,
470
636
  required: !0
471
637
  },
472
- invalid: !!s.minute,
473
- error: s.minute
638
+ invalid: !!u.minute,
639
+ error: u.minute
474
640
  }),
475
- /* @__PURE__ */ V("div", {
476
- className: "flex flex-row gap-3 desktop:flex-col",
477
- children: [/* @__PURE__ */ V("div", {
641
+ /* @__PURE__ */ H("div", {
642
+ className: "flex flex-row gap-3",
643
+ children: [/* @__PURE__ */ H("div", {
478
644
  className: "flex flex-1 flex-col gap-1",
479
- children: [/* @__PURE__ */ B(d, {
645
+ children: [/* @__PURE__ */ V(S, {
480
646
  id: "scheduled-task-start-date",
481
- mode: f.Date,
482
- value: Ee(r.startDate),
483
- onChange: (e) => u("startDate", De(e)),
647
+ mode: C.Date,
648
+ value: e(r.startDate),
649
+ onChange: (e) => y("startDate", i(e)),
650
+ minDate: I,
484
651
  labelProps: { label: n.startDateLabel },
485
652
  placeholder: n.startDatePlaceholder,
486
- invalid: !!s.startDate
487
- }), s.startDate && /* @__PURE__ */ B("p", {
488
- className: a(k, Y.instructionsError),
489
- children: s.startDate
653
+ invalid: !!u.startDate
654
+ }), u.startDate && /* @__PURE__ */ V("p", {
655
+ className: _(U, Z.instructionsError),
656
+ children: u.startDate
490
657
  })]
491
- }), /* @__PURE__ */ V("div", {
658
+ }), /* @__PURE__ */ H("div", {
492
659
  className: "flex flex-1 flex-col gap-1",
493
- children: [/* @__PURE__ */ B(d, {
660
+ children: [/* @__PURE__ */ V(S, {
494
661
  id: "scheduled-task-end-date",
495
- mode: f.Date,
496
- value: Ee(r.endDate),
497
- onChange: (e) => u("endDate", De(e)),
662
+ mode: C.Date,
663
+ value: e(r.endDate),
664
+ onChange: (e) => y("endDate", i(e)),
665
+ minDate: I,
498
666
  labelProps: { label: n.endDateLabel },
499
667
  placeholder: n.endDatePlaceholder,
500
- invalid: !!s.endDate
501
- }), s.endDate && /* @__PURE__ */ B("p", {
502
- className: a(k, Y.instructionsError),
503
- children: s.endDate
668
+ invalid: !!u.endDate
669
+ }), u.endDate && /* @__PURE__ */ V("p", {
670
+ className: _(U, Z.instructionsError),
671
+ children: u.endDate
504
672
  })]
505
673
  })]
506
674
  })
@@ -509,266 +677,358 @@ var U = {
509
677
  })
510
678
  ]
511
679
  }),
512
- children: /* @__PURE__ */ V("div", {
680
+ children: /* @__PURE__ */ H("div", {
513
681
  role: "group",
514
682
  "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: _
544
- })
683
+ className: _("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: _(ke, Z.sectionSubtitle),
692
+ children: n.configurationSectionSubtitle
693
+ })]
694
+ }),
695
+ ee == null ? u.skillUrls && /* @__PURE__ */ V("div", {
696
+ "aria-live": "polite",
697
+ children: /* @__PURE__ */ V("p", {
698
+ className: _(U, Z.instructionsError),
699
+ children: u.skillUrls
700
+ })
701
+ }) : /* @__PURE__ */ V("div", {
702
+ className: "w-full min-w-0 max-w-[996px]",
703
+ children: ee
704
+ }),
705
+ /* @__PURE__ */ V("div", {
706
+ className: "flex w-full min-w-0 max-w-[996px] flex-col",
707
+ children: /* @__PURE__ */ V(h, {
708
+ isEnabled: !!O,
709
+ fieldId: fe,
710
+ labelClassName: Ae,
711
+ label: n.instructionsLabel,
712
+ required: Se,
713
+ labels: n,
714
+ refinement: he,
715
+ disabled: w || ge,
716
+ ...K,
717
+ children: /* @__PURE__ */ H("div", {
718
+ className: "flex flex-1 flex-col gap-1",
719
+ children: [
720
+ !O && /* @__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: _("w-full", f, p),
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(), y("prompt", e);
736
+ },
737
+ height: 480,
738
+ theme: k,
739
+ placeholder: n.instructionsPlaceholder
740
+ })
741
+ })
742
+ }),
743
+ u.prompt && /* @__PURE__ */ V("p", {
744
+ className: _(U, Z.instructionsError),
745
+ children: u.prompt
746
+ })
747
+ ]
545
748
  })
546
- }),
547
- s.prompt && /* @__PURE__ */ B("p", {
548
- className: a(k, Y.instructionsError),
549
- children: s.prompt
550
749
  })
551
- ]
552
- })]
750
+ })
751
+ ]
553
752
  })
554
- });
555
- }, X = /* @__PURE__ */ function(e) {
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: T.Danger,
760
+ onConfirm: N.confirm,
761
+ onClose: N.dismiss
762
+ })] });
763
+ }, $e = /* @__PURE__ */ function(e) {
556
764
  return e.Details = "details", e.Configuration = "configuration", e.History = "history", e;
557
- }({}), Me = /* @__PURE__ */ function(e) {
765
+ }({}), et = /* @__PURE__ */ function(e) {
558
766
  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", {
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: _(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: _(o, tt.subtitleText),
789
+ children: n
790
+ }), i ? i(r) : /* @__PURE__ */ V(m, {
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", {
569
797
  className: "flex flex-col gap-1",
570
- children: [/* @__PURE__ */ B("span", {
571
- className: a(o, Fe.subtitleText),
798
+ children: [/* @__PURE__ */ V("span", {
799
+ className: _(o, rt.subtitleText),
572
800
  children: e.descriptionLabel
573
- }), /* @__PURE__ */ B("p", {
801
+ }), /* @__PURE__ */ V("p", {
574
802
  className: s,
575
803
  children: t
576
804
  })]
577
805
  }),
578
- n && /* @__PURE__ */ V("div", {
806
+ a && /* @__PURE__ */ H("div", {
807
+ className: "flex flex-col gap-1",
808
+ children: [/* @__PURE__ */ V("span", {
809
+ className: _(o, rt.subtitleText),
810
+ children: e.completedFieldLabel
811
+ }), /* @__PURE__ */ V("p", {
812
+ className: s,
813
+ children: a
814
+ })]
815
+ }),
816
+ n && /* @__PURE__ */ H("div", {
579
817
  className: "flex flex-col gap-1",
580
- children: [/* @__PURE__ */ B("span", {
581
- className: a(o, Fe.subtitleText),
818
+ children: [/* @__PURE__ */ V("span", {
819
+ className: _(o, rt.subtitleText),
582
820
  children: e.modelLabel
583
- }), /* @__PURE__ */ B("p", {
821
+ }), /* @__PURE__ */ V("p", {
584
822
  className: s,
585
823
  children: n
586
824
  })]
587
825
  }),
588
- r && /* @__PURE__ */ V("div", {
826
+ r && /* @__PURE__ */ H("div", {
589
827
  className: "flex flex-col gap-1",
590
- children: [/* @__PURE__ */ B("span", {
591
- className: a(o, Fe.subtitleText),
828
+ children: [/* @__PURE__ */ V("span", {
829
+ className: _(o, rt.subtitleText),
592
830
  children: e.repeatsLabel
593
- }), /* @__PURE__ */ B("p", {
831
+ }), /* @__PURE__ */ V("p", {
594
832
  className: s,
595
833
  children: r
596
834
  })]
597
835
  }),
598
- i && /* @__PURE__ */ V("div", {
836
+ i && /* @__PURE__ */ H("div", {
599
837
  className: "flex flex-col gap-1",
600
- children: [/* @__PURE__ */ B("span", {
601
- className: a(o, Fe.subtitleText),
838
+ children: [/* @__PURE__ */ V("span", {
839
+ className: _(o, rt.subtitleText),
602
840
  children: e.activeWindowLabel
603
- }), /* @__PURE__ */ B("p", {
841
+ }), /* @__PURE__ */ V("p", {
604
842
  className: s,
605
843
  children: i
606
844
  })]
607
845
  })
608
- ] }), Z = /* @__PURE__ */ function(e) {
846
+ ] }), at = /* @__PURE__ */ function(e) {
609
847
  return e.Success = "success", e.Error = "error", e.InProgress = "inProgress", e.Missed = "missed", e;
610
848
  }({}), 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 }) => {
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 }) => {
618
858
  switch (e) {
619
- case Z.Success: return /* @__PURE__ */ B(M, {
620
- size: m.SM,
859
+ case at.Success: return /* @__PURE__ */ V(xe, {
860
+ size: E.SM,
621
861
  className: Q.successIcon,
622
862
  "aria-hidden": !0,
623
- stroke: h
863
+ stroke: D
624
864
  });
625
- case Z.Error: return /* @__PURE__ */ B(ae, {
626
- size: m.SM,
865
+ case at.Error: return /* @__PURE__ */ V(P, {
866
+ size: E.SM,
627
867
  className: Q.errorIcon,
628
868
  "aria-hidden": !0,
629
- stroke: h
869
+ stroke: D
630
870
  });
631
- case Z.InProgress: return /* @__PURE__ */ B("span", {
871
+ case at.InProgress: return /* @__PURE__ */ V("span", {
632
872
  "aria-hidden": !0,
633
- children: /* @__PURE__ */ B(O, { size: m.SM })
873
+ children: /* @__PURE__ */ V(me, { size: E.SM })
634
874
  });
635
- case Z.Missed: return /* @__PURE__ */ B(j, {
636
- size: m.SM,
875
+ case at.Missed: return /* @__PURE__ */ V(ve, {
876
+ size: E.SM,
637
877
  className: Q.missedIcon,
638
878
  "aria-hidden": !0,
639
- stroke: h
879
+ stroke: D
640
880
  });
641
881
  default: return null;
642
882
  }
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 ? {
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", ee = c.unreadIndicatorLabel ?? "Unread", h = g({
885
+ "--strhl-success-icon": d?.successIconColor,
886
+ "--strhl-error-icon": d?.errorIconColor,
887
+ "--strhl-missed-icon": d?.missedIconColor,
888
+ "--strhl-subtitle-text": d?.subtitleTextColor,
889
+ "--strhl-current-run-bg": d?.currentRunBackground,
890
+ "--strhl-unread-dot": d?.unreadDotColor,
891
+ "--strhl-row-hover-bg": u?.rowHoverBackground,
892
+ "--strhl-row-focus-bg": u?.rowFocusBackground,
893
+ "--strhl-row-focus-outline": u?.rowFocusOutline
894
+ }), v = (e) => {
895
+ let t = c.runStatusLabels[e.status], n = e.id === o, r = [e.isUnread ? ee : 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", {
897
+ ...a ? {
655
898
  role: "button",
656
899
  tabIndex: 0,
657
- onClick: () => l?.(e),
900
+ onClick: () => s?.(e),
658
901
  onKeyDown: (t) => {
659
- (t.key === "Enter" || t.key === " ") && (t.preventDefault(), l?.(e));
902
+ (t.key === "Enter" || t.key === " ") && (t.preventDefault(), s?.(e));
660
903
  }
661
904
  } : {},
662
905
  "aria-label": i,
663
906
  "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", {
907
+ className: _("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", {
666
909
  className: "flex items-center gap-2 truncate",
667
- children: [/* @__PURE__ */ B("span", {
910
+ children: [/* @__PURE__ */ V("span", {
668
911
  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),
912
+ children: e.isUnread && /* @__PURE__ */ V("span", {
913
+ className: _("size-[5.33px] rounded-full", Q.unreadDot),
671
914
  "aria-hidden": !0
672
915
  })
673
- }), /* @__PURE__ */ B("span", {
674
- className: a(g, "truncate"),
916
+ }), /* @__PURE__ */ V("span", {
917
+ className: _(p, "truncate"),
675
918
  children: e.timestampLabel
676
919
  })]
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 })
920
+ }), /* @__PURE__ */ V("span", {
921
+ className: "flex min-h-[var(--strhl-row-min-height,32px)] w-14 shrink-0 items-center justify-end",
922
+ children: /* @__PURE__ */ V(ot, { status: e.status })
680
923
  })]
681
924
  }, e.id);
682
- }, S = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ V("li", {
925
+ }, y = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ H("li", {
683
926
  "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,
927
+ className: _("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,
687
930
  width: "160px",
688
931
  height: "16px"
689
- }), /* @__PURE__ */ B(E, {
690
- variant: D.Rectangular,
932
+ }), /* @__PURE__ */ V(j, {
933
+ variant: M.Rectangular,
691
934
  width: "16px",
692
935
  height: "16px",
693
936
  className: "shrink-0 rounded-full"
694
937
  })]
695
938
  }, `history-skeleton-${t}`));
696
- return t && e.length === 0 ? /* @__PURE__ */ B("ul", {
697
- style: b,
698
- "aria-label": u.historyTitle,
939
+ return t && e.length === 0 ? /* @__PURE__ */ V("ul", {
940
+ style: {
941
+ ...h,
942
+ "--strhl-row-min-height": u?.rowMinHeight
943
+ },
944
+ "aria-label": c.historyTitle,
699
945
  className: "flex flex-col gap-0.5",
700
- children: S(r)
701
- }) : o && e.length === 0 ? /* @__PURE__ */ V("div", {
702
- style: b,
946
+ children: y(r)
947
+ }) : i && e.length === 0 ? /* @__PURE__ */ H("div", {
948
+ style: h,
703
949
  className: "flex flex-col items-start gap-3",
704
- children: [/* @__PURE__ */ B("p", {
950
+ children: [/* @__PURE__ */ V("p", {
705
951
  role: "alert",
706
- className: a(_, Q.subtitleText),
707
- children: u.errorLabel
708
- }), /* @__PURE__ */ B(v, {
709
- label: u.retryLabel,
710
- onClick: s
952
+ className: _(m, Q.subtitleText),
953
+ children: c.errorLabel
954
+ }), /* @__PURE__ */ V(k, {
955
+ label: c.retryLabel,
956
+ onClick: a
711
957
  })]
712
- }) : e.length === 0 ? /* @__PURE__ */ V("div", {
713
- style: b,
958
+ }) : e.length === 0 ? /* @__PURE__ */ H("div", {
959
+ style: h,
714
960
  className: "flex w-full flex-col items-center justify-center gap-2 py-4",
715
- children: [/* @__PURE__ */ B(N, {
961
+ children: [/* @__PURE__ */ V(Se, {
716
962
  size: 44,
717
- stroke: h,
963
+ stroke: D,
718
964
  className: Q.subtitleText,
719
965
  "aria-hidden": !0
720
- }), /* @__PURE__ */ B("p", {
966
+ }), /* @__PURE__ */ V("p", {
721
967
  role: "status",
722
- className: g,
723
- children: u.emptyLabel
968
+ className: p,
969
+ children: c.emptyLabel
724
970
  })]
725
- }) : /* @__PURE__ */ V("ul", {
726
- style: b,
727
- "aria-label": u.historyTitle,
971
+ }) : /* @__PURE__ */ H("ul", {
972
+ style: {
973
+ ...h,
974
+ "--strhl-row-min-height": u?.rowMinHeight
975
+ },
976
+ "aria-label": c.historyTitle,
728
977
  className: "flex flex-col gap-0.5",
729
978
  children: [
730
- e.map(x),
731
- n && S(r),
732
- o ? /* @__PURE__ */ V("li", {
979
+ e.map(v),
980
+ n && y(r),
981
+ i ? /* @__PURE__ */ H("li", {
733
982
  className: "flex flex-col items-start gap-3 px-5 py-2",
734
- children: [/* @__PURE__ */ B("p", {
983
+ children: [/* @__PURE__ */ V("p", {
735
984
  role: "alert",
736
- className: a(_, Q.subtitleText),
737
- children: u.errorLabel
738
- }), /* @__PURE__ */ B(v, {
739
- label: u.retryLabel,
740
- onClick: s
985
+ className: _(m, Q.subtitleText),
986
+ children: c.errorLabel
987
+ }), /* @__PURE__ */ V(k, {
988
+ label: c.retryLabel,
989
+ onClick: a
741
990
  })]
742
- }) : d
991
+ }) : l
743
992
  ]
744
993
  });
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, {
994
+ }, ct = {
995
+ historyCard: "_historyCard_153p9_4",
996
+ subtitleText: "_subtitleText_153p9_8",
997
+ cardLayout: "_cardLayout_153p9_13"
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: ee = "dial-body-semi-text", colors: h, styles: g }) => {
999
+ let v = e === et.Card, y = v ? _("sticky bottom-0 z-10 rounded-b-xl px-6 pb-5 pt-2", ct.historyCard) : "pt-2", b = l ? /* @__PURE__ */ H("li", {
1000
+ className: y,
1001
+ children: [/* @__PURE__ */ V("p", {
1002
+ role: "alert",
1003
+ children: t.historyLoadMoreErrorLabel ?? t.historyErrorLabel
1004
+ }), u && /* @__PURE__ */ V(k, {
1005
+ label: t.historyRetryLabel,
1006
+ onClick: u,
1007
+ disabled: a
1008
+ })]
1009
+ }) : f && d && t.historyShowMoreLabel ? /* @__PURE__ */ V("li", {
1010
+ className: y,
1011
+ children: /* @__PURE__ */ V(k, {
752
1012
  label: t.historyShowMoreLabel,
753
- onClick: d,
754
- disabled: o
1013
+ onClick: f,
1014
+ disabled: a
755
1015
  })
756
- }) : void 0, b = n ? /* @__PURE__ */ B("p", {
757
- className: a(p, ze.subtitleText),
1016
+ }) : void 0, x = n ? /* @__PURE__ */ V("p", {
1017
+ className: _(m, ct.subtitleText),
758
1018
  children: n
759
- }) : void 0, x = t.historyLoadingMoreLabel ? /* @__PURE__ */ B("span", {
1019
+ }) : void 0, te = t.historyLoadingMoreLabel ? /* @__PURE__ */ V("span", {
760
1020
  role: "status",
761
1021
  "aria-live": "polite",
762
1022
  className: "sr-only",
763
- children: o ? t.historyLoadingMoreLabel : ""
764
- }) : void 0, S = /* @__PURE__ */ B(Re, {
1023
+ children: a ? t.historyLoadingMoreLabel : ""
1024
+ }) : void 0, ne = /* @__PURE__ */ V(st, {
765
1025
  items: r,
766
1026
  isLoading: i,
767
- isLoadingMore: o,
768
- skeletonCount: s,
769
- error: c,
770
- onRetry: l,
771
- onRunClick: f,
1027
+ isLoadingMore: a,
1028
+ skeletonCount: o,
1029
+ error: s,
1030
+ onRetry: c,
1031
+ onRunClick: p,
772
1032
  labels: {
773
1033
  historyTitle: t.historyTitle,
774
1034
  emptyLabel: t.historyEmptyLabel,
@@ -777,85 +1037,106 @@ var U = {
777
1037
  runStatusLabels: t.runStatusLabels,
778
1038
  unreadIndicatorLabel: t.unreadIndicatorLabel
779
1039
  },
780
- footer: y,
1040
+ footer: b,
781
1041
  styles: {
782
- typography: { runTimestampClassName: p },
783
- colors: h
1042
+ typography: { runTimestampClassName: m },
1043
+ colors: g?.colors ?? h,
1044
+ rowMinHeight: g?.rowMinHeight,
1045
+ rowHoverBackground: g?.rowHoverBackground,
1046
+ rowFocusBackground: g?.rowFocusBackground,
1047
+ rowFocusOutline: g?.rowFocusOutline
784
1048
  }
785
1049
  });
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),
1050
+ return v ? /* @__PURE__ */ H("div", {
1051
+ className: _("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": g?.maxHeight },
1053
+ children: [/* @__PURE__ */ H("div", {
1054
+ className: _("sticky top-0 z-10 flex flex-col gap-4 rounded-t-xl px-6 pb-2 pt-5", ct.historyCard),
790
1055
  children: [
791
- /* @__PURE__ */ B("h2", {
792
- className: m,
1056
+ /* @__PURE__ */ V("h2", {
1057
+ className: ee,
793
1058
  children: t.historyTitle
794
1059
  }),
795
- b,
796
- x
1060
+ x,
1061
+ te
797
1062
  ]
798
- }), /* @__PURE__ */ B("div", {
1063
+ }), /* @__PURE__ */ V("div", {
799
1064
  className: "flex flex-1 flex-col gap-4 px-6 pb-2",
800
- children: S
1065
+ children: ne
801
1066
  })]
802
- }) : /* @__PURE__ */ V("div", {
1067
+ }) : /* @__PURE__ */ H("div", {
803
1068
  className: "flex flex-col gap-4",
804
1069
  children: [
805
- b,
806
1070
  x,
807
- S
1071
+ te,
1072
+ ne
808
1073
  ]
809
1074
  });
810
1075
  }, $ = {
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 = [
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: ee, displayName: h, isLoading: v = !1, error: b, onRetry: x, description: te, modelLabel: ne, repeatsLabel: S, activeWindowLabel: C, completedLabel: w, nextRunLabel: T, instructionsMarkdown: ie, skillDisplayNames: O, 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 = g({
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 = y(), [B, Ne] = je($e.Details), U = Oe(), W = o && !i ? e.startNowBusyLabel : void 0, G = [
823
1092
  {
824
- id: X.Details,
1093
+ id: $e.Details,
825
1094
  label: e.detailsTitle
826
1095
  },
827
1096
  {
828
- id: X.Configuration,
1097
+ id: $e.Configuration,
829
1098
  label: e.configurationTitle
830
1099
  },
831
1100
  {
832
- id: X.History,
1101
+ id: $e.History,
833
1102
  label: e.historyTitle
834
1103
  }
835
- ], _e = ge.find((e) => e.id === U)?.label ?? e.detailsTitle, W = /* @__PURE__ */ B(Ie, {
1104
+ ], K = G.find((e) => e.id === B)?.label ?? e.detailsTitle, Pe = /* @__PURE__ */ V(it, {
836
1105
  labels: {
837
1106
  descriptionLabel: e.descriptionLabel,
838
1107
  modelLabel: e.modelLabel,
839
1108
  repeatsLabel: e.repeatsLabel,
840
- activeWindowLabel: e.activeWindowLabel
1109
+ activeWindowLabel: e.activeWindowLabel,
1110
+ completedFieldLabel: e.completedFieldLabel
841
1111
  },
842
- description: S,
843
- modelLabel: C,
844
- repeatsLabel: ee,
845
- activeWindowLabel: te,
846
- fieldLabelClassName: fe,
847
- fieldValueClassName: R
848
- }), G = /* @__PURE__ */ B(Pe, {
1112
+ description: te,
1113
+ modelLabel: ne,
1114
+ repeatsLabel: S,
1115
+ activeWindowLabel: C,
1116
+ completedLabel: w,
1117
+ fieldLabelClassName: Ee,
1118
+ fieldValueClassName: z
1119
+ }), q = /* @__PURE__ */ V(nt, {
849
1120
  instructionsLabel: e.instructionsLabel,
850
- instructionsMarkdown: ne,
851
- renderInstructions: E,
852
- fieldLabelClassName: fe
853
- }), ve = (t) => /* @__PURE__ */ B(Be, {
1121
+ skillLabel: e.skillLabel,
1122
+ skillDisplayNames: O,
1123
+ instructionsMarkdown: ie,
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, {
854
1134
  variant: t,
855
1135
  labels: {
856
1136
  historyTitle: e.historyTitle,
857
1137
  historyEmptyLabel: e.historyEmptyLabel,
858
1138
  historyErrorLabel: e.historyErrorLabel,
1139
+ historyLoadMoreErrorLabel: e.historyLoadMoreErrorLabel,
859
1140
  historyRetryLabel: e.historyRetryLabel,
860
1141
  historyLoadingMoreLabel: e.historyLoadingMoreLabel,
861
1142
  historyShowMoreLabel: e.historyShowMoreLabel,
@@ -863,175 +1144,263 @@ var U = {
863
1144
  unreadIndicatorLabel: e.unreadIndicatorLabel
864
1145
  },
865
1146
  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
1147
+ items: se,
1148
+ isLoading: ce,
1149
+ isLoadingMore: le,
1150
+ skeletonCount: de,
1151
+ error: fe,
1152
+ onRetry: A,
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
878
1162
  });
879
- return /* @__PURE__ */ V("div", {
880
- style: H,
881
- className: a("flex h-full w-full flex-col overflow-y-auto", $.container),
1163
+ return /* @__PURE__ */ H("div", {
1164
+ style: ke,
1165
+ className: _("flex h-full min-h-0 w-full flex-col overflow-hidden", $.container, be),
882
1166
  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", {
1167
+ /* @__PURE__ */ H("div", {
1168
+ className: _("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", {
886
1170
  className: "flex min-w-0 items-center gap-2",
887
1171
  children: [
888
- /* @__PURE__ */ B(y, {
889
- icon: /* @__PURE__ */ B(ie, {
890
- size: m.LG,
1172
+ /* @__PURE__ */ V(ae, {
1173
+ icon: xe === void 0 ? /* @__PURE__ */ V(ye, {
1174
+ size: E.LG,
891
1175
  className: "rtl:scale-x-[-1]",
892
1176
  "aria-hidden": !0,
893
- stroke: h
894
- }),
1177
+ stroke: D
1178
+ }) : xe,
895
1179
  "aria-label": e.backAriaLabel,
896
1180
  onClick: t
897
1181
  }),
898
- /* @__PURE__ */ B("h1", {
899
- className: a("hidden truncate desktop:block", I),
900
- children: g
1182
+ /* @__PURE__ */ V("h1", {
1183
+ className: _("truncate", $.desktopTitle, R),
1184
+ children: h
901
1185
  }),
902
- c && /* @__PURE__ */ B("span", {
903
- className: a("hidden shrink-0 desktop:inline", R, $.subtitleText),
1186
+ l && /* @__PURE__ */ V("span", {
1187
+ className: _("shrink-0", $.desktopBadge, z, $.subtitleText),
904
1188
  children: e.deletedStateLabel
905
1189
  })
906
1190
  ]
907
- }), /* @__PURE__ */ V("div", {
908
- className: "flex shrink-0 items-center gap-2",
1191
+ }), /* @__PURE__ */ H("div", {
1192
+ className: _("flex min-w-0 flex-1 flex-wrap items-center justify-end gap-2 desktop:flex-none desktop:flex-nowrap", $.headerActions),
909
1193
  children: [
910
- !c && l !== void 0 && /* @__PURE__ */ B(k, {
1194
+ !l && !u && d !== void 0 && /* @__PURE__ */ H(Me, { children: [/* @__PURE__ */ V(he, {
911
1195
  id: "scheduled-task-active-switch",
912
1196
  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,
1197
+ isOn: d,
1198
+ disabled: f || p || c,
1199
+ onChange: (e) => ee?.(e)
1200
+ }), p && m && /* @__PURE__ */ V("span", {
1201
+ className: _(z, $.subtitleText),
1202
+ children: m
1203
+ })] }),
1204
+ !l && s && /* @__PURE__ */ V(k, {
1205
+ variant: re.Danger,
919
1206
  label: e.deleteButtonLabel,
920
- iconBefore: /* @__PURE__ */ B(le, {
921
- size: m.SM,
1207
+ iconBefore: /* @__PURE__ */ V(we, {
1208
+ size: E.SM,
922
1209
  "aria-hidden": !0,
923
- stroke: h
1210
+ stroke: D
924
1211
  }),
925
- onClick: r,
926
- disabled: o,
927
- className: "shrink-0"
1212
+ onClick: s,
1213
+ disabled: c,
1214
+ className: "min-h-11 shrink-0"
928
1215
  }),
929
- !c && n && /* @__PURE__ */ B(w, {
1216
+ !l && n && /* @__PURE__ */ V(ue, {
930
1217
  label: e.editButtonLabel,
931
- iconBefore: /* @__PURE__ */ B(oe, {
932
- size: m.SM,
1218
+ iconBefore: /* @__PURE__ */ V(Ce, {
1219
+ size: E.SM,
933
1220
  "aria-hidden": !0,
934
- stroke: h
1221
+ stroke: D
935
1222
  }),
936
1223
  onClick: n,
937
- disabled: o,
938
- 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: E.SM,
1237
+ "aria-hidden": !0,
1238
+ stroke: D
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
+ })]
939
1246
  })
940
1247
  ]
941
1248
  })]
942
1249
  }),
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),
1250
+ /* @__PURE__ */ H("div", {
1251
+ className: _("min-w-0 items-center gap-2 px-8 py-3", $.mobileTitleRow),
1252
+ children: [/* @__PURE__ */ V("h1", {
1253
+ className: _("truncate", R),
1254
+ children: h
1255
+ }), l && /* @__PURE__ */ V("span", {
1256
+ className: _("shrink-0", z, $.subtitleText),
950
1257
  children: e.deletedStateLabel
951
1258
  })]
952
1259
  }),
953
- e.activeStatusAnnouncement != null && /* @__PURE__ */ B("span", {
1260
+ e.activeStatusAnnouncement != null && /* @__PURE__ */ V("span", {
954
1261
  role: "status",
955
1262
  "aria-live": "polite",
956
1263
  className: "sr-only",
957
1264
  children: e.activeStatusAnnouncement
958
1265
  }),
959
- _ && /* @__PURE__ */ B("div", {
1266
+ e.startStatusAnnouncement != null && /* @__PURE__ */ V("span", {
1267
+ role: "status",
1268
+ "aria-live": "polite",
1269
+ className: "sr-only",
1270
+ children: e.startStatusAnnouncement
1271
+ }),
1272
+ v && /* @__PURE__ */ V("div", {
960
1273
  className: "flex flex-1 items-center justify-center",
961
- children: /* @__PURE__ */ B(O, {})
1274
+ children: /* @__PURE__ */ V(me, {})
962
1275
  }),
963
- !_ && b && /* @__PURE__ */ V("div", {
1276
+ !v && b && /* @__PURE__ */ H("div", {
964
1277
  className: "flex flex-1 flex-col items-center justify-center gap-3",
965
- children: [/* @__PURE__ */ B("p", {
966
- className: a(R, $.subtitleText),
1278
+ children: [/* @__PURE__ */ V("p", {
1279
+ className: _(z, $.subtitleText),
967
1280
  children: e.errorLabel
968
- }), /* @__PURE__ */ B(v, {
1281
+ }), /* @__PURE__ */ V(k, {
969
1282
  label: e.retryLabel,
970
1283
  onClick: x
971
1284
  })]
972
1285
  }),
973
- !_ && !b && (me ? /* @__PURE__ */ V("div", {
974
- className: "flex flex-1 flex-col",
975
- children: [/* @__PURE__ */ B(re, {
1286
+ !v && !b && (Ae ? /* @__PURE__ */ H("div", {
1287
+ className: "flex min-h-0 flex-1 flex-col overflow-y-auto",
1288
+ children: [/* @__PURE__ */ V(ge, {
976
1289
  ariaLabel: e.tabsAriaLabel ?? "Scheduled task sections",
977
1290
  className: "px-8",
978
- tabs: ge,
979
- activeTabId: U,
980
- onTabChange: he
981
- }), /* @__PURE__ */ B("div", {
1291
+ tabs: G,
1292
+ activeTabId: B,
1293
+ onTabChange: Ne
1294
+ }), /* @__PURE__ */ V("div", {
982
1295
  role: "tabpanel",
983
- "aria-label": _e,
1296
+ "aria-label": K,
984
1297
  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
1298
+ children: B === $e.Configuration ? q : B === $e.History ? J(et.Flow) : Pe
986
1299
  })]
987
- }) : /* @__PURE__ */ V("div", {
988
- className: "flex flex-1 flex-col desktop:flex-row",
1300
+ }) : /* @__PURE__ */ H("div", {
1301
+ style: {
1302
+ flexDirection: "row",
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
1307
+ },
1308
+ className: "flex min-h-0 flex-1 overflow-y-auto desktop:overflow-hidden",
989
1309
  children: [
990
- /* @__PURE__ */ V("div", {
1310
+ /* @__PURE__ */ H("div", {
991
1311
  role: "group",
992
1312
  "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,
1313
+ style: {
1314
+ flex: `0 1 ${P?.detailsWidth ?? "360px"}`,
1315
+ maxWidth: "100%"
1316
+ },
1317
+ className: _("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,
996
1320
  children: e.detailsTitle
997
- }), W]
1321
+ }), Pe]
998
1322
  }),
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,
1323
+ /* @__PURE__ */ H("div", {
1324
+ style: {
1325
+ flex: `1 1 ${P?.configurationMinWidth ?? "320px"}`,
1326
+ minWidth: 0
1327
+ },
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,
1003
1331
  children: e.configurationTitle
1004
- }), G]
1332
+ }), q]
1005
1333
  }),
1006
- /* @__PURE__ */ B("div", {
1007
- className: "flex w-full justify-center p-6 desktop:w-auto desktop:items-start",
1008
- children: ve(Me.Card)
1334
+ /* @__PURE__ */ V("div", {
1335
+ style: {
1336
+ flex: `0 1 calc(${P?.historyWidth ?? "360px"} + 48px)`,
1337
+ minWidth: 0
1338
+ },
1339
+ className: "flex min-h-0 w-full items-start justify-center overflow-y-auto p-6",
1340
+ children: J(et.Card)
1009
1341
  })
1010
1342
  ]
1011
1343
  }))
1012
1344
  ]
1013
1345
  });
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", {
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", {
1017
1349
  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
- })]
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",
1370
+ children: e
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(m, {
1380
+ content: e,
1381
+ ...s
1382
+ }))(a)]
1383
+ })
1384
+ ]
1034
1385
  });
1035
- };
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: T.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(u, {
1396
+ variant: T.Danger,
1397
+ children: /* @__PURE__ */ V(d, {
1398
+ icon: t,
1399
+ typeLabel: n,
1400
+ name: e,
1401
+ styles: { colors: o?.colors }
1402
+ })
1403
+ })
1404
+ });
1036
1405
  //#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 };
1406
+ 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 };