@epam/ai-dial-scheduled-tasks 1.3.0-dev.29 → 1.3.0-dev.294

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 (73) hide show
  1. package/calendar-value-Ds0AiQSR.js +34 -0
  2. package/components/ScheduledTaskBoundaryField/ScheduledTaskBoundaryField.d.ts +24 -0
  3. package/components/ScheduledTaskBoundaryField/ScheduledTaskBoundaryField.d.ts.map +1 -0
  4. package/components/ScheduledTaskCard/ScheduledTaskCard.d.ts +3 -1
  5. package/components/ScheduledTaskCard/ScheduledTaskCard.d.ts.map +1 -1
  6. package/components/ScheduledTaskCardGrid/ScheduledTaskCardGrid.d.ts.map +1 -1
  7. package/components/ScheduledTaskConfigurationSection/ScheduledTaskConfigurationSection.d.ts.map +1 -1
  8. package/components/ScheduledTaskConversationDetailsSection/ScheduledTaskConversationDetailsSection.d.ts +78 -0
  9. package/components/ScheduledTaskConversationDetailsSection/ScheduledTaskConversationDetailsSection.d.ts.map +1 -0
  10. package/components/ScheduledTaskConversationHistorySection/ScheduledTaskConversationHistorySection.d.ts +78 -0
  11. package/components/ScheduledTaskConversationHistorySection/ScheduledTaskConversationHistorySection.d.ts.map +1 -0
  12. package/components/ScheduledTaskCreateForm/ScheduledTaskCreateForm.d.ts.map +1 -1
  13. package/components/ScheduledTaskDeleteConfirmation/ScheduledTaskDeleteConfirmation.d.ts +5 -1
  14. package/components/ScheduledTaskDeleteConfirmation/ScheduledTaskDeleteConfirmation.d.ts.map +1 -1
  15. package/components/ScheduledTaskDetailView/ScheduledTaskDetailView.d.ts.map +1 -1
  16. package/components/ScheduledTaskDetailsSection/ScheduledTaskDetailsSection.d.ts.map +1 -1
  17. package/components/ScheduledTaskDetailsSummary/ScheduledTaskDetailsSummary.d.ts.map +1 -1
  18. package/components/ScheduledTaskHistorySection/ScheduledTaskHistorySection.d.ts.map +1 -1
  19. package/components/ScheduledTaskRunAtField/ScheduledTaskRunAtField.d.ts +6 -2
  20. package/components/ScheduledTaskRunAtField/ScheduledTaskRunAtField.d.ts.map +1 -1
  21. package/components/ScheduledTaskRunAtTimeField/ScheduledTaskRunAtTimeField.d.ts +5 -0
  22. package/components/ScheduledTaskRunAtTimeField/ScheduledTaskRunAtTimeField.d.ts.map +1 -0
  23. package/components/ScheduledTaskRunHistoryList/ScheduledTaskRunHistoryList.d.ts.map +1 -1
  24. package/components/ScheduledTasks/ScheduledTasks.d.ts.map +1 -1
  25. package/components/ScheduledTasksLimitedAccessBanner/ScheduledTasksLimitedAccessBanner.d.ts +20 -0
  26. package/components/ScheduledTasksLimitedAccessBanner/ScheduledTasksLimitedAccessBanner.d.ts.map +1 -0
  27. package/components/ScheduledTasksLoginBanner/ScheduledTasksLoginBanner.d.ts +32 -0
  28. package/components/ScheduledTasksLoginBanner/ScheduledTasksLoginBanner.d.ts.map +1 -0
  29. package/components/SectionAccordionTitle/SectionAccordionTitle.d.ts +15 -0
  30. package/components/SectionAccordionTitle/SectionAccordionTitle.d.ts.map +1 -0
  31. package/constants/scheduled-task-create-form.d.ts +3 -0
  32. package/constants/scheduled-task-create-form.d.ts.map +1 -1
  33. package/index.css +3 -2
  34. package/index.d.ts +14 -4
  35. package/index.d.ts.map +1 -1
  36. package/index.js +1126 -822
  37. package/models/scheduled-task-card-grid-props.d.ts +3 -1
  38. package/models/scheduled-task-card-grid-props.d.ts.map +1 -1
  39. package/models/scheduled-task-card-props.d.ts +1 -3
  40. package/models/scheduled-task-card-props.d.ts.map +1 -1
  41. package/models/scheduled-task-create-form-props.d.ts +29 -5
  42. package/models/scheduled-task-create-form-props.d.ts.map +1 -1
  43. package/models/scheduled-task-detail-view-props.d.ts +4 -0
  44. package/models/scheduled-task-detail-view-props.d.ts.map +1 -1
  45. package/models/scheduled-task-details-section-props.d.ts +1 -1
  46. package/models/scheduled-task-details-section-props.d.ts.map +1 -1
  47. package/models/scheduled-task-details-summary-props.d.ts +15 -1
  48. package/models/scheduled-task-details-summary-props.d.ts.map +1 -1
  49. package/models/scheduled-task-history-section-props.d.ts +6 -2
  50. package/models/scheduled-task-history-section-props.d.ts.map +1 -1
  51. package/models/scheduled-task-item.d.ts +2 -0
  52. package/models/scheduled-task-item.d.ts.map +1 -1
  53. package/models/scheduled-task-run-history-list-props.d.ts +9 -3
  54. package/models/scheduled-task-run-history-list-props.d.ts.map +1 -1
  55. package/models/scheduled-task-run-item.d.ts +5 -1
  56. package/models/scheduled-task-run-item.d.ts.map +1 -1
  57. package/models/scheduled-tasks-props.d.ts +6 -2
  58. package/models/scheduled-tasks-props.d.ts.map +1 -1
  59. package/package.json +6 -6
  60. package/types/scheduled-task-schedule.d.ts +3 -1
  61. package/types/scheduled-task-schedule.d.ts.map +1 -1
  62. package/utils/aria.d.ts +3 -0
  63. package/utils/aria.d.ts.map +1 -0
  64. package/utils/calendar-value.d.ts +3 -1
  65. package/utils/calendar-value.d.ts.map +1 -1
  66. package/utils/window-boundary.d.ts +4 -0
  67. package/utils/window-boundary.d.ts.map +1 -0
  68. package/validation/index.d.ts +1 -1
  69. package/validation/index.d.ts.map +1 -1
  70. package/validation/scheduled-task-validation.d.ts +7 -4
  71. package/validation/scheduled-task-validation.d.ts.map +1 -1
  72. package/validation.js +8 -8
  73. package/calendar-value-B41Uk26Z.js +0 -24
package/index.js CHANGED
@@ -1,89 +1,89 @@
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, ConfirmationIdentityRow as u, MARKDOWN_EDITOR_MAX_HEIGHT_CLASS_NAME as d, MARKDOWN_EDITOR_PREVIEW_LIST_CLASS_NAME as f, MDMessageViewer as p, PanelEmptyState as m, ResourceSummary as h, TextRefinementField as g, buildCssVars as _, mergeClasses as v, useAvailableHeightCap as y, useIsMobile as b, useTextRefinement as x, useUnsavedChangesGuard as ee } from "@epam/ai-dial-chat-shared";
3
- import { ButtonAppearance as te, ButtonDropdown as S, ButtonVariant as ne, Calendar as C, CalendarMode as w, CardShell as T, ConfirmationPopupVariant as E, DIAL_ICON_SIZE as D, DIAL_KIT_ICON_STROKE as O, ElementSize as re, FolderPath as ie, GhostButton as k, GhostIconButton as ae, Highlight as oe, Input as se, Label as ce, MenuItemMark as le, NeutralButton as ue, NumberInput as de, PrimaryButton as fe, Search as A, Select as pe, Skeleton as j, SkeletonVariant as M, Spinner as me, Switch as he, Tabs as ge, Textarea as _e } from "@epam/ai-dial-ui-kit";
4
- import { IconAlertTriangle as ve, IconArrowNarrowLeft as ye, IconArrowsSort as N, IconCheck as be, IconCircleCheck as xe, IconCircleX as P, IconClipboardX as Se, IconClockHour3 as F, IconPencilMinus as Ce, IconPlayerPause as I, IconPlayerPlay as L, IconPlus as R, IconTrashX as we } from "@tabler/icons-react";
5
- import { Suspense as Te, lazy as Ee, useCallback as z, useEffect as De, useId as Oe, useLayoutEffect as ke, useMemo as Ae, useRef as B, useState as je } from "react";
6
- import { Fragment as Me, jsx as V, jsxs as H } from "react/jsx-runtime";
7
- import { BuilderFormContainer as Ne } from "@epam/ai-dial-builder-form";
8
- import { LazyMarkdownEditor as U } from "@epam/ai-dial-ui-kit/editors";
9
- //#region src/constants/public-class-names.ts
10
- var W = {
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, u as l } from "./calendar-value-Ds0AiQSR.js";
2
+ import { COMPACT_MARKDOWN_CLASS_NAMES as u, ConfirmationDialog as d, ConfirmationIdentityRow as f, MARKDOWN_EDITOR_MAX_HEIGHT_CLASS_NAME as p, MARKDOWN_EDITOR_PREVIEW_LIST_CLASS_NAME as m, MDMessageViewer as h, PanelEmptyState as g, ResourceSummary as _, TextRefinementField as v, buildCssVars as y, mergeClasses as b, useAvailableHeightCap as x, useControlErrorAssociation as S, useIsMobile as C, useTextRefinement as w, useUnsavedChangesGuard as ee } from "@epam/ai-dial-chat-shared";
3
+ import { Accordion as T, Button as te, ButtonAppearance as ne, ButtonDropdown as re, ButtonVariant as ie, Calendar as E, CalendarMode as D, CardShell as ae, ConfirmationPopupVariant as oe, DIAL_ICON_SIZE as O, DIAL_KIT_ICON_STROKE as k, ElementSize as se, EllipsisTooltip as ce, ErrorMessageNotification as le, ErrorText as A, FolderPath as ue, GhostButton as j, GhostIconButton as de, Highlight as fe, Input as pe, Label as me, LinkButton as he, LiveRegion as M, LiveRegionElement as N, LiveRegionPoliteness as ge, MenuItemMark as P, NeutralButton as _e, NoDataContent as F, Notification as I, NotificationSurface as L, NotificationType as ve, NotificationVariant as R, NumberInput as ye, PrimaryButton as z, Search as be, Select as xe, Skeleton as B, SkeletonVariant as Se, Spinner as Ce, Switch as we, Tabs as Te, Textarea as Ee, Tooltip as De, WarningMessageNotification as Oe } from "@epam/ai-dial-ui-kit";
4
+ import { IconAlertTriangle as V, IconArrowNarrowLeft as ke, IconArrowRight as H, IconArrowsSort as U, IconCheck as Ae, IconCircleX as je, IconPencilMinus as Me, IconPlayerPause as Ne, IconPlayerPlay as W, IconPlus as Pe, IconTrashX as Fe } from "@tabler/icons-react";
5
+ import { Suspense as Ie, lazy as Le, memo as Re, useCallback as ze, useEffect as Be, useId as G, useLayoutEffect as Ve, useMemo as He, useRef as Ue, useState as We } from "react";
6
+ import { Fragment as K, jsx as q, jsxs as J } from "react/jsx-runtime";
7
+ import { BuilderFormContainer as Ge } from "@epam/ai-dial-builder-form";
8
+ import { LazyMarkdownEditor as Ke } from "@epam/ai-dial-ui-kit/editors";
9
+ //#region src/models/scheduled-task-card-grid-props.ts
10
+ var qe = "1180px", Je = {
11
11
  card: "dial-scheduled-tasks-card",
12
12
  cardGrid: "dial-scheduled-tasks-card-grid",
13
13
  refineFeedback: "dial-scheduled-tasks-refine-feedback"
14
- }, G = /* @__PURE__ */ function(e) {
14
+ }, Y = /* @__PURE__ */ function(e) {
15
15
  return e.Scheduled = "scheduled", e.Paused = "paused", e.Completed = "completed", e;
16
- }({}), K = /* @__PURE__ */ function(e) {
16
+ }({}), Ye = /* @__PURE__ */ function(e) {
17
17
  return e.Active = "active", e.Paused = "paused", e.Completed = "completed", e;
18
- }({}), Pe = (e) => {
18
+ }({}), Xe = (e) => {
19
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;
20
+ case Ye.Active: return Y.Scheduled;
21
+ case Ye.Paused: return Y.Paused;
22
+ case Ye.Completed: return Y.Completed;
23
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]: {
24
+ return e.isCompleted ? Y.Completed : e.isActive === !1 ? Y.Paused : Y.Scheduled;
25
+ }, X = {
26
+ schedulePill: "_schedulePill_1cwco_1",
27
+ scheduleLabel: "_scheduleLabel_1cwco_6",
28
+ pausedPill: "_pausedPill_1cwco_10",
29
+ pausedLabel: "_pausedLabel_1cwco_15",
30
+ completedPill: "_completedPill_1cwco_19",
31
+ completedLabel: "_completedLabel_1cwco_24"
32
+ }, Ze = {
33
+ [Y.Scheduled]: {
34
34
  pillClassName: "inline-block rounded-lg border px-2 py-1",
35
- wrapperClassName: q.schedulePill,
36
- labelClassName: q.scheduleLabel
35
+ wrapperClassName: X.schedulePill,
36
+ labelClassName: X.scheduleLabel
37
37
  },
38
- [G.Paused]: {
38
+ [Y.Paused]: {
39
39
  pillClassName: "inline-flex items-center gap-1.5 rounded-full border px-2 py-1",
40
- wrapperClassName: q.pausedPill,
41
- labelClassName: q.pausedLabel,
42
- renderIcon: () => /* @__PURE__ */ V(I, {
43
- size: D.SM,
40
+ wrapperClassName: X.pausedPill,
41
+ labelClassName: X.pausedLabel,
42
+ renderIcon: () => /* @__PURE__ */ q(Ne, {
43
+ size: O.SM,
44
44
  "aria-hidden": !0,
45
- stroke: O
45
+ stroke: k
46
46
  })
47
47
  },
48
- [G.Completed]: {
48
+ [Y.Completed]: {
49
49
  pillClassName: "inline-flex items-center gap-1.5 rounded-full border px-2 py-1",
50
- wrapperClassName: q.completedPill,
51
- labelClassName: q.completedLabel,
52
- renderIcon: () => /* @__PURE__ */ V(be, {
53
- size: D.SM,
50
+ wrapperClassName: X.completedPill,
51
+ labelClassName: X.completedLabel,
52
+ renderIcon: () => /* @__PURE__ */ q(Ae, {
53
+ size: O.SM,
54
54
  "aria-hidden": !0,
55
- stroke: O
55
+ stroke: k
56
56
  })
57
57
  }
58
- }, Fe = ({ status: e, text: t, textClassName: n = "dial-tiny-text", className: r }) => {
59
- let { pillClassName: i, wrapperClassName: a, labelClassName: o, renderIcon: s } = J[e];
60
- return /* @__PURE__ */ H("span", {
61
- className: v(i, n, a, o, r),
58
+ }, Qe = ({ status: e, text: t, textClassName: n = "dial-tiny-text", className: r }) => {
59
+ let { pillClassName: i, wrapperClassName: a, labelClassName: o, renderIcon: s } = Ze[e];
60
+ return /* @__PURE__ */ J("span", {
61
+ className: b(i, n, a, o, r),
62
62
  children: [s && s(), t]
63
63
  });
64
- }, Y = {
65
- title: "_title_hmbo0_2",
66
- description: "_description_hmbo0_6",
67
- locationLabel: "_locationLabel_hmbo0_10",
68
- locationLeaf: "_locationLeaf_hmbo0_14",
69
- newBadge: "_newBadge_hmbo0_18",
70
- locationDivider: "_locationDivider_hmbo0_23",
71
- card: "_card_hmbo0_34"
72
- }, Ie = ({ item: e, searchQuery: t = "", onCardClick: n, labels: r, styles: i, className: a }) => {
73
- let o = b(), s = r?.newBadgeLabel ?? "NEW", c = r?.pausedBadgeLabel ?? "Paused", l = r?.completedBadgeLabel ?? "Completed", { colors: u, typography: d } = i ?? {}, f = d?.titleClassName ?? "dial-body-semi-text", p = d?.descriptionClassName ?? "dial-small-text", m = d?.descriptionSizeClassName ?? "dial-tiny-text", h = d?.scheduleLabelClassName ?? "dial-tiny-text", g = d?.pausedBadgeClassName ?? "dial-tiny-text", y = d?.completedBadgeClassName ?? "dial-tiny-text", x = d?.locationLabelClassName ?? "dial-tiny-text", ee = d?.locationLeafClassName ?? "dial-tiny-semi-text", te = d?.newBadgeClassName ?? "dial-tiny-semi-text", S = Pe(e), { text: ne, textClassName: C } = {
74
- [G.Scheduled]: {
64
+ }, $e = {
65
+ title: "_title_7p2ui_2",
66
+ description: "_description_7p2ui_6",
67
+ locationLabel: "_locationLabel_7p2ui_10",
68
+ locationLeaf: "_locationLeaf_7p2ui_14",
69
+ newBadge: "_newBadge_7p2ui_18",
70
+ locationDivider: "_locationDivider_7p2ui_23",
71
+ card: "_card_7p2ui_34"
72
+ }, et = ({ item: e, searchQuery: t = "", onCardClick: n, labels: r, styles: i, className: a }) => {
73
+ let o = C(), s = e.newBadgeLabel ?? r?.newBadgeLabel ?? "NEW", c = r?.pausedBadgeLabel ?? "Paused", l = r?.completedBadgeLabel ?? "Completed", { colors: u, typography: d } = i ?? {}, f = d?.titleClassName ?? "dial-body-semi-text", p = d?.descriptionClassName ?? "dial-small-paragraph-text", m = d?.scheduleLabelClassName ?? "dial-tiny-text", h = d?.pausedBadgeClassName ?? "dial-tiny-text", g = d?.completedBadgeClassName ?? "dial-tiny-text", _ = d?.locationLabelClassName ?? "dial-tiny-text", v = d?.locationLeafClassName ?? "dial-tiny-semi-text", x = d?.newBadgeClassName ?? "dial-tiny-semi-text", S = Xe(e), { text: w, textClassName: ee } = {
74
+ [Y.Scheduled]: {
75
75
  text: e.scheduleLabel,
76
- textClassName: h
76
+ textClassName: m
77
77
  },
78
- [G.Paused]: {
78
+ [Y.Paused]: {
79
79
  text: c,
80
- textClassName: g
80
+ textClassName: h
81
81
  },
82
- [G.Completed]: {
82
+ [Y.Completed]: {
83
83
  text: l,
84
- textClassName: y
84
+ textClassName: g
85
85
  }
86
- }[S], w = _({
86
+ }[S], T = y({
87
87
  "--stc-title-text": u?.titleText,
88
88
  "--stc-desc-text": u?.descriptionText,
89
89
  "--stc-pill-bg": u?.schedulePillBackground,
@@ -100,88 +100,91 @@ var W = {
100
100
  "--stc-completed-bg": u?.completedBadgeBackground,
101
101
  "--stc-completed-border": u?.completedBadgeBorder,
102
102
  "--stc-completed-text": u?.completedBadgeText
103
- }), E = n ? {
103
+ }), te = n ? {
104
104
  tabIndex: 0,
105
105
  onClick: () => n(e.id),
106
106
  onKeyDown: (t) => {
107
107
  (t.key === "Enter" || t.key === " ") && (t.preventDefault(), n(e.id));
108
108
  }
109
109
  } : {};
110
- return /* @__PURE__ */ H(T, {
110
+ return /* @__PURE__ */ J(ae, {
111
111
  role: n ? "button" : "group",
112
112
  "aria-label": e.displayName,
113
- style: w,
114
- className: v("h-[var(--st-card-height,232px)]", Y.card, n && "cursor-pointer", a, W.card),
115
- ...E,
113
+ style: T,
114
+ className: b("h-(--st-card-height,232px) min-w-0", $e.card, n && "cursor-pointer", a, Je.card),
115
+ ...te,
116
116
  children: [
117
- /* @__PURE__ */ H("div", {
117
+ /* @__PURE__ */ J("div", {
118
118
  className: "flex min-w-0 shrink-0 items-start gap-2 desktop:items-center",
119
- children: [/* @__PURE__ */ V(oe, {
119
+ children: [/* @__PURE__ */ q(fe, {
120
120
  text: e.displayName,
121
121
  query: t,
122
122
  maxLines: o ? 2 : 1,
123
- className: v(f, Y.title)
124
- }), e.isNew && /* @__PURE__ */ V("span", {
125
- className: v("shrink-0 rounded-full px-2 py-0.5", te, Y.newBadge),
123
+ className: b(f, $e.title)
124
+ }), e.isNew && /* @__PURE__ */ q("span", {
125
+ className: b("shrink-0 rounded-full px-2 py-0.5", x, $e.newBadge),
126
126
  children: s
127
127
  })]
128
128
  }),
129
- e.descriptionPreview && /* @__PURE__ */ V("p", {
130
- className: v("line-clamp-4 min-h-0 flex-1 overflow-hidden", m, p, Y.description),
129
+ e.descriptionPreview && /* @__PURE__ */ q("p", {
130
+ className: b("line-clamp-3 min-h-0 min-w-0 overflow-hidden wrap-anywhere", p, $e.description),
131
131
  children: e.descriptionPreview
132
132
  }),
133
- /* @__PURE__ */ H("div", {
133
+ /* @__PURE__ */ J("div", {
134
134
  className: "mt-auto flex shrink-0 flex-col gap-3",
135
- children: [/* @__PURE__ */ V("div", {
135
+ children: [/* @__PURE__ */ q("div", {
136
136
  className: "flex min-h-[28px] items-center",
137
- children: /* @__PURE__ */ V(Fe, {
137
+ children: /* @__PURE__ */ q(Qe, {
138
138
  status: S,
139
- text: ne,
140
- textClassName: C
139
+ text: w,
140
+ textClassName: ee
141
141
  })
142
- }), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ V(ie, {
142
+ }), e.locationSegments && e.locationSegments.length > 0 && /* @__PURE__ */ q(ue, {
143
143
  segments: e.locationSegments,
144
- labelClassName: v(x, Y.locationLabel),
145
- leafClassName: v(ee, Y.locationLeaf),
146
- className: v("pt-3", Y.locationDivider)
144
+ labelClassName: b(_, $e.locationLabel),
145
+ leafClassName: b(v, $e.locationLeaf),
146
+ className: b("pt-3", $e.locationDivider)
147
147
  })]
148
148
  })
149
149
  ]
150
150
  });
151
- }, Le = { card: "_card_18ivt_1" }, Re = [
151
+ }, tt = { card: "_card_18ivt_1" }, nt = [
152
152
  "100%",
153
153
  "100%",
154
154
  "61%"
155
- ], ze = "var(--stcs-skeleton-bg)", Be = ({ styles: e }) => /* @__PURE__ */ H(T, {
156
- "aria-hidden": !0,
157
- style: _({ "--stcs-skeleton-bg": e?.colors?.skeletonColor }),
158
- className: v("h-[var(--st-card-height,232px)]", Le.card),
159
- children: [
160
- /* @__PURE__ */ V(j, {
161
- variant: M.Rectangular,
162
- width: "60%",
163
- height: "20px",
164
- color: ze,
165
- className: "shrink-0"
166
- }),
167
- /* @__PURE__ */ V("div", {
168
- className: "flex min-h-0 flex-1 flex-col gap-3 overflow-hidden",
169
- children: Re.map((e, t) => /* @__PURE__ */ V(j, {
170
- variant: M.Rectangular,
171
- width: e,
172
- height: "16px",
173
- color: ze
174
- }, t))
175
- }),
176
- /* @__PURE__ */ V(j, {
177
- variant: M.Rectangular,
178
- width: "110px",
179
- height: "28px",
180
- color: ze,
181
- className: "shrink-0 rounded-lg"
182
- })
183
- ]
184
- }), Ve = ({ items: e, searchQuery: t, onCardClick: n, labels: r, cardStyles: i, trailingSkeletonCount: a = 0, skeletonStyles: o, layout: s }) => /* @__PURE__ */ H("div", {
155
+ ], rt = "var(--stcs-skeleton-bg)", it = ({ styles: e }) => {
156
+ let t = y({ "--stcs-skeleton-bg": e?.colors?.skeletonColor });
157
+ return /* @__PURE__ */ J(ae, {
158
+ "aria-hidden": !0,
159
+ style: t,
160
+ className: b("h-(--st-card-height,232px)", tt.card),
161
+ children: [
162
+ /* @__PURE__ */ q(B, {
163
+ variant: Se.Rectangular,
164
+ width: "60%",
165
+ height: "20px",
166
+ color: rt,
167
+ className: "shrink-0"
168
+ }),
169
+ /* @__PURE__ */ q("div", {
170
+ className: "flex min-h-0 flex-1 flex-col gap-3 overflow-hidden",
171
+ children: nt.map((e, t) => /* @__PURE__ */ q(B, {
172
+ variant: Se.Rectangular,
173
+ width: e,
174
+ height: "16px",
175
+ color: rt
176
+ }, t))
177
+ }),
178
+ /* @__PURE__ */ q(B, {
179
+ variant: Se.Rectangular,
180
+ width: "110px",
181
+ height: "28px",
182
+ color: rt,
183
+ className: "shrink-0 rounded-lg"
184
+ })
185
+ ]
186
+ });
187
+ }, at = ({ items: e, searchQuery: t, onCardClick: n, labels: r, cardStyles: i, trailingSkeletonCount: a = 0, skeletonStyles: o, layout: s }) => /* @__PURE__ */ J("div", {
185
188
  style: {
186
189
  "--st-grid-min-card-width": s?.minCardWidth,
187
190
  "--st-grid-gap": s?.gap,
@@ -191,62 +194,58 @@ var W = {
191
194
  gap: "var(--st-grid-gap, 20px)",
192
195
  gridTemplateColumns: "repeat(auto-fill, minmax(min(100%, max(var(--st-grid-min-card-width, 320px), calc((100% - (var(--st-grid-columns) - 1) * var(--st-grid-gap, 20px)) / var(--st-grid-columns)))), 1fr))"
193
196
  },
194
- className: v("mx-auto grid w-full min-w-0", W.cardGrid),
195
- children: [e.map((e) => /* @__PURE__ */ V(Ie, {
197
+ className: b("mx-auto grid w-full min-w-0", Je.cardGrid),
198
+ children: [e.map((e) => /* @__PURE__ */ q(et, {
196
199
  item: e,
197
200
  searchQuery: t,
198
201
  onCardClick: n,
199
202
  labels: r,
200
203
  styles: i
201
- }, e.id)), Array.from({ length: a }, (e, t) => /* @__PURE__ */ V(Be, { styles: o }, `skeleton-${t}`))]
202
- }), X = {
204
+ }, e.id)), Array.from({ length: a }, (e, t) => /* @__PURE__ */ q(it, { styles: o }, `skeleton-${t}`))]
205
+ }), ot = {
203
206
  container: "_container_3vz4t_2",
204
207
  subtitle: "_subtitle_3vz4t_6",
205
208
  createButtonLabel: "_createButtonLabel_3vz4t_10",
206
209
  sortButton: "_sortButton_3vz4t_19",
207
210
  createButton: "_createButton_3vz4t_10",
208
211
  sortControlHidden: "_sortControlHidden_3vz4t_49"
209
- }, He = /* @__PURE__ */ V(F, {
210
- size: 48,
211
- stroke: 1,
212
- "aria-hidden": !0
213
- }), Ue = (e, t, n, r, i, a) => {
212
+ }, st = (e, t, n, r, i, a) => {
214
213
  if (!e) return t ? a.loadingMoreLabel : n ? a.errorLabel : r > 0 ? `${r}` : i ? a.noResultsLabel : a.emptyStateLabel;
215
- }, We = (e) => {
214
+ }, ct = (e) => {
216
215
  if (!e || e === document.body) return null;
217
216
  let { overflow: t, overflowY: n } = getComputedStyle(e);
218
- return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e : We(e.parentElement);
219
- }, Ge = ({ labels: e, onCreateClick: t, searchQuery: n, onSearchQueryChange: r, sortKey: i, onSortChange: a, items: o, isLoading: s = !1, error: c, onRetry: l, hasMore: u = !1, isLoadingMore: d = !1, skeletonCount: f = 6, onLoadMore: p, onCardClick: h, banner: g, styles: y, sortIcon: b, className: x, gridLayout: ee, cardStyles: C, loadMoreError: w, onRetryLoadMore: T }) => {
220
- let { colors: E, typography: ie } = y ?? {}, ae = ie?.titleClassName ?? "dial-h1-text", oe = ie?.subtitleClassName ?? "dial-body-text", se = _({
221
- "--st-bg": E?.background,
222
- "--st-subtitle-text": E?.subtitleText,
223
- "--st-sort-text": E?.sortButtonText
224
- }), ce = (e) => {
217
+ return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e : ct(e.parentElement);
218
+ }, lt = ({ 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: _, sortIcon: v, className: x, gridLayout: S, cardStyles: C, loadMoreError: w, onRetryLoadMore: ee }) => {
219
+ let { colors: T, typography: te } = _ ?? {}, E = te?.titleClassName ?? "dial-h1-text", D = te?.subtitleClassName ?? "dial-body-text", ae = y({
220
+ "--st-bg": T?.background,
221
+ "--st-subtitle-text": T?.subtitleText,
222
+ "--st-sort-text": T?.sortButtonText
223
+ }), oe = (e) => {
225
224
  r(e ?? "");
226
- }, [ue, de] = je(!1), [pe, j] = je(!1), M = B(null), he = z(() => {
227
- j(!0);
228
- }, []), ge = z(() => {
229
- j(!1);
225
+ }, [ce, A] = We(!1), [ue, de] = We(!1), fe = Ue(null), pe = ze(() => {
226
+ de(!0);
227
+ }, []), me = ze(() => {
228
+ de(!1);
230
229
  }, []);
231
- ke(() => {
232
- let e = M.current;
233
- pe && ue && e != null && e.offsetParent == null && de(!1);
234
- }, [pe, ue]);
235
- let _e = e.sortOptions.find((e) => e.value === i)?.label ?? e.sortLabel, ve = Ae(() => e.sortOptions.map((e) => ({
230
+ Ve(() => {
231
+ let e = fe.current;
232
+ ue && ce && e != null && e.offsetParent == null && A(!1);
233
+ }, [ue, ce]);
234
+ let he = e.sortOptions.find((e) => e.value === i)?.label ?? e.sortLabel, ge = He(() => e.sortOptions.map((e) => ({
236
235
  key: e.value,
237
236
  label: e.label,
238
- mark: le.Check,
237
+ mark: P.Check,
239
238
  checked: e.value === i,
240
239
  onClick: () => a(e.value)
241
240
  })), [
242
241
  e.sortOptions,
243
242
  i,
244
243
  a
245
- ]), ye = Ue(s, d, !!c, o.length, n.trim().length > 0, e), be = B(null);
246
- De(() => {
247
- let e = be.current;
244
+ ]), _e = st(s, d, !!c, o.length, n.trim().length > 0, e), F = Ue(null);
245
+ Be(() => {
246
+ let e = F.current;
248
247
  if (!e || !p) return;
249
- let t = We(e.parentElement);
248
+ let t = ct(e.parentElement);
250
249
  if (!t) return;
251
250
  let n = () => {
252
251
  if (d || s || w || !u) return;
@@ -261,149 +260,192 @@ var W = {
261
260
  w,
262
261
  p
263
262
  ]);
264
- let xe = () => s ? /* @__PURE__ */ V(me, {}) : c ? /* @__PURE__ */ H("div", {
263
+ let I = () => s ? /* @__PURE__ */ q(Ce, {}) : c ? /* @__PURE__ */ J("div", {
265
264
  className: "flex flex-col items-center gap-3",
266
- children: [/* @__PURE__ */ V("p", {
267
- className: v(oe, X.subtitle),
265
+ children: [/* @__PURE__ */ q("p", {
266
+ className: b(D, ot.subtitle),
268
267
  children: e.errorLabel
269
- }), /* @__PURE__ */ V(k, {
268
+ }), /* @__PURE__ */ q(j, {
270
269
  label: e.retryLabel,
271
270
  onClick: l
272
271
  })]
273
- }) : o.length === 0 ? n.trim() ? /* @__PURE__ */ V("p", {
274
- className: v(oe, X.subtitle),
275
- children: e.noResultsLabel
276
- }) : /* @__PURE__ */ V(m, {
272
+ }) : o.length === 0 ? n.trim() ? /* @__PURE__ */ q(g, {
273
+ label: e.noResultsLabel,
274
+ description: e.noResultsDescription
275
+ }) : /* @__PURE__ */ q(g, {
277
276
  label: e.emptyStateLabel,
278
- icon: He
279
- }) : /* @__PURE__ */ H("div", {
277
+ description: e.emptyStateDescription
278
+ }) : /* @__PURE__ */ J("div", {
280
279
  className: "flex w-full flex-col gap-6",
281
280
  children: [
282
- /* @__PURE__ */ V(Ve, {
281
+ /* @__PURE__ */ q(at, {
283
282
  items: o,
284
283
  searchQuery: n,
285
- onCardClick: h,
284
+ onCardClick: m,
286
285
  labels: e.cardLabels,
287
286
  trailingSkeletonCount: d ? f : 0,
288
- skeletonStyles: { colors: { skeletonColor: E?.skeletonColor } },
287
+ skeletonStyles: { colors: { skeletonColor: T?.skeletonColor } },
289
288
  cardStyles: C,
290
- layout: ee
289
+ layout: S
291
290
  }),
292
- w && /* @__PURE__ */ H("div", {
293
- role: "alert",
294
- className: "flex items-center gap-3",
295
- children: [/* @__PURE__ */ V("span", {
296
- className: v(oe, X.subtitle),
297
- children: e.loadMoreErrorLabel ?? e.errorLabel
298
- }), /* @__PURE__ */ V(k, {
291
+ w && /* @__PURE__ */ q(le, {
292
+ message: e.loadMoreErrorLabel ?? e.errorLabel,
293
+ textClassName: D,
294
+ iconStroke: k,
295
+ action: /* @__PURE__ */ q(j, {
299
296
  label: e.retryLabel,
300
- onClick: T
301
- })]
297
+ onClick: ee
298
+ })
302
299
  }),
303
- /* @__PURE__ */ V("div", {
304
- ref: be,
300
+ /* @__PURE__ */ q("div", {
301
+ ref: F,
305
302
  "aria-hidden": !0,
306
303
  className: "h-px w-full"
307
304
  })
308
305
  ]
309
- }), P = s || !!c || o.length === 0;
310
- return /* @__PURE__ */ H("div", {
311
- style: se,
312
- className: v("flex h-full w-full flex-col gap-4 overflow-y-auto px-4 py-4 desktop:gap-6 desktop:px-8", X.container, x),
306
+ }), L = s || !!c || o.length === 0;
307
+ return /* @__PURE__ */ J("div", {
308
+ style: ae,
309
+ className: b("flex h-full w-full flex-col gap-4 overflow-y-auto px-4 py-4 desktop:gap-6 desktop:px-8", ot.container, x),
313
310
  children: [
314
- /* @__PURE__ */ H("div", {
311
+ /* @__PURE__ */ J("div", {
315
312
  className: "flex items-start justify-between gap-4",
316
- children: [/* @__PURE__ */ H("div", {
313
+ children: [/* @__PURE__ */ J("div", {
317
314
  className: "min-w-0 gap-2",
318
- children: [/* @__PURE__ */ V("h1", {
319
- className: v("truncate", ae),
315
+ children: [/* @__PURE__ */ q("h1", {
316
+ className: b("truncate", E),
320
317
  children: e.title
321
- }), /* @__PURE__ */ V("p", {
322
- className: v("mt-1", oe, X.subtitle),
318
+ }), /* @__PURE__ */ q("p", {
319
+ className: b("mt-1", D, ot.subtitle),
323
320
  children: e.subtitle
324
321
  })]
325
- }), /* @__PURE__ */ V(fe, {
322
+ }), t != null && /* @__PURE__ */ q(z, {
326
323
  label: e.createButtonLabel,
327
- textClassName: X.createButtonLabel,
324
+ textClassName: ot.createButtonLabel,
328
325
  "aria-label": e.createButtonLabel,
329
- iconBefore: /* @__PURE__ */ V(R, {
330
- size: D.SM,
326
+ iconBefore: /* @__PURE__ */ q(Pe, {
327
+ size: O.SM,
331
328
  "aria-hidden": !0,
332
- stroke: O
329
+ stroke: k
333
330
  }),
334
331
  onClick: t,
335
- className: v("shrink-0", X.createButton)
332
+ className: b("shrink-0", ot.createButton)
336
333
  })]
337
334
  }),
338
- /* @__PURE__ */ H("div", {
335
+ /* @__PURE__ */ J("div", {
339
336
  className: "flex flex-wrap items-center gap-3",
340
- children: [/* @__PURE__ */ V("div", {
337
+ children: [/* @__PURE__ */ q("div", {
341
338
  role: "search",
342
339
  className: "flex-1",
343
- children: /* @__PURE__ */ V(A, {
340
+ children: /* @__PURE__ */ q(be, {
344
341
  value: n,
345
- onChange: ce,
342
+ onChange: oe,
346
343
  placeholder: e.searchPlaceholder,
347
344
  clearLabel: e.clearSearchLabel,
348
345
  "aria-label": e.searchAriaLabel,
349
- size: re.Large,
350
- onFocus: he,
351
- onBlur: ge
346
+ size: se.Large,
347
+ onFocus: pe,
348
+ onBlur: me
352
349
  })
353
- }), e.sortOptions.length > 0 && /* @__PURE__ */ V("div", {
354
- ref: M,
355
- className: v(pe && X.sortControlHidden),
356
- children: /* @__PURE__ */ V(S, {
357
- items: ve,
358
- label: _e,
359
- variant: ne.Primary,
360
- appearance: te.Ghost,
361
- iconBefore: b === void 0 ? /* @__PURE__ */ V(N, {
362
- size: D.SM,
350
+ }), e.sortOptions.length > 0 && /* @__PURE__ */ q("div", {
351
+ ref: fe,
352
+ className: b(ue && ot.sortControlHidden),
353
+ children: /* @__PURE__ */ q(re, {
354
+ items: ge,
355
+ label: he,
356
+ variant: ie.Primary,
357
+ appearance: ne.Ghost,
358
+ iconBefore: v === void 0 ? /* @__PURE__ */ q(U, {
359
+ size: O.SM,
363
360
  "aria-hidden": !0,
364
- stroke: O
365
- }) : b,
366
- className: X.sortButton
361
+ stroke: k
362
+ }) : v,
363
+ className: ot.sortButton
367
364
  })
368
365
  })]
369
366
  }),
370
- g,
371
- /* @__PURE__ */ V("span", {
372
- role: "status",
373
- "aria-live": "polite",
374
- className: "sr-only",
375
- children: ye
367
+ h != null && typeof h != "boolean" && /* @__PURE__ */ q("div", {
368
+ className: "mx-auto w-full min-w-0",
369
+ style: { maxWidth: S?.maxWidth ?? "1180px" },
370
+ children: h
376
371
  }),
377
- /* @__PURE__ */ V("div", {
378
- className: v("mx-auto flex size-full w-full min-w-0 flex-col", P && "items-center justify-center"),
379
- children: xe()
372
+ /* @__PURE__ */ q(M, {
373
+ visuallyHidden: !0,
374
+ as: N.Span,
375
+ children: _e
376
+ }),
377
+ /* @__PURE__ */ q("div", {
378
+ className: b("mx-auto flex size-full w-full min-w-0 flex-col", L && "items-center justify-center"),
379
+ children: I()
380
380
  })
381
381
  ]
382
382
  });
383
- }, Ke = /* @__PURE__ */ function(e) {
383
+ }, ut = /* @__PURE__ */ function(e) {
384
384
  return e.FirstToRun = "firstToRun", e.LastToRun = "lastToRun", e.Newest = "newest", e.NameAZ = "nameAZ", e;
385
- }({}), qe = (e) => e == null ? "" : typeof e == "string" ? e.trim() : Array.isArray(e) ? e.length ? JSON.stringify(e) : "" : JSON.stringify(e), Je = (e, t) => {
386
- let n = new Set([...Object.keys(e), ...Object.keys(t)]);
387
- for (let r of n) if (qe(e[r]) !== qe(t[r])) return !0;
385
+ }({}), dt = (e) => Array.from(document.querySelectorAll("[aria-labelledby]")).find((t) => (t.getAttribute("aria-labelledby") ?? "").split(/\s+/).includes(e)) ?? null, ft = (e) => e == null ? "" : typeof e == "string" ? e.trim() : Array.isArray(e) ? e.length ? JSON.stringify(e) : "" : JSON.stringify(e), pt = (e, t) => {
386
+ let n = /* @__PURE__ */ new Set([...Object.keys(e), ...Object.keys(t)]);
387
+ for (let r of n) if (ft(e[r]) !== ft(t[r])) return !0;
388
388
  return !1;
389
- }, Ye = { error: "_error_v2pfn_4" }, Xe = ({ label: e, value: t, onChange: r, error: i, errorClassName: a = "dial-small-text" }) => {
390
- let o = B(/* @__PURE__ */ new Date()).current;
391
- return /* @__PURE__ */ H("div", {
389
+ }, mt = (e, t, n) => t === l.Custom || n === l.Custom ? void 0 : e, ht = { error: "_error_v2pfn_4" }, gt = ({ id: t, label: n, placeholder: r, value: a, onChange: o, minDate: s, error: c, errorClassName: l, disabled: u }) => {
390
+ let d = (e) => o(i(e)), f = G();
391
+ return S(() => document.getElementById(t), f, !!c), /* @__PURE__ */ J("div", {
392
+ className: "flex flex-1 flex-col gap-1",
393
+ children: [/* @__PURE__ */ q(E, {
394
+ id: t,
395
+ mode: D.Date,
396
+ value: e(a),
397
+ onChange: d,
398
+ minDate: s,
399
+ labelProps: { label: n },
400
+ placeholder: r,
401
+ invalid: !!c,
402
+ disabled: u
403
+ }), /* @__PURE__ */ q(A, {
404
+ announce: ge.Assertive,
405
+ id: f,
406
+ className: b(l, ht.error),
407
+ text: c ?? ""
408
+ })]
409
+ });
410
+ }, _t = ({ value: e, onChange: t, onBlur: n, disabled: r, invalid: i, ariaLabel: a }) => /* @__PURE__ */ q(E, {
411
+ mode: D.Time,
412
+ value: e,
413
+ onChange: (e) => {
414
+ typeof e == "string" && t(e);
415
+ },
416
+ onBlur: n,
417
+ disabled: r,
418
+ invalid: i,
419
+ labelProps: {
420
+ label: a,
421
+ className: "sr-only"
422
+ },
423
+ className: "w-[120px] gap-y-0",
424
+ fieldClassName: "px-3 py-1.5 pe-9",
425
+ pickerButtonClassName: "size-6 inset-e-1.5"
426
+ }), vt = { error: "_error_v2pfn_4" }, yt = (e) => /* @__PURE__ */ q(_t, { ...e }), bt = ({ label: e, placeholder: t, value: r, onChange: i, disabled: a, error: o, errorClassName: c = "dial-tiny-text" }) => {
427
+ let l = Ue(/* @__PURE__ */ new Date()).current, u = (e) => i(n(e)), d = G();
428
+ return S(() => document.getElementById("scheduled-task-run-at"), d, !!o), /* @__PURE__ */ J("div", {
392
429
  className: "flex flex-col gap-1",
393
- children: [/* @__PURE__ */ V(C, {
430
+ children: [/* @__PURE__ */ q(E, {
394
431
  id: "scheduled-task-run-at",
395
- mode: w.DateTime,
396
- value: s(t),
397
- onChange: (e) => r(n(e)),
398
- minDate: o,
432
+ mode: D.DateTime,
433
+ value: s(r),
434
+ onChange: u,
435
+ minDate: l,
399
436
  labelProps: {
400
437
  label: e,
401
438
  required: !0
402
439
  },
403
- invalid: !!i
404
- }), i && /* @__PURE__ */ V("p", {
405
- className: v(a, Ye.error),
406
- children: i
440
+ placeholder: t,
441
+ invalid: !!o,
442
+ disabled: a,
443
+ renderTimeField: yt
444
+ }), /* @__PURE__ */ q(A, {
445
+ announce: ge.Assertive,
446
+ id: d,
447
+ className: b(c, vt.error),
448
+ text: o ?? ""
407
449
  })]
408
450
  });
409
451
  }, Z = {
@@ -413,264 +455,316 @@ var W = {
413
455
  instructionsError: "_instructionsError_1253x_18",
414
456
  refineFeedback: "_refineFeedback_1253x_22",
415
457
  refineError: "_refineError_1253x_26"
416
- }, Ze = Ee(async () => ({ default: (await U()).MarkdownEditor })), Qe = ({ labels: n, values: r, initialValues: s, errors: u, modelSelector: p, modelLabelId: m, skillSelector: h, onFieldChange: b, onBack: te, onCancel: S, onSubmit: ne, isSubmitting: T = !1, onRefineDescription: re, onRefineInstructions: ie, markdownEditorTheme: k, backIcon: ae, className: oe, styles: le }) => {
417
- let ue = Oe(), fe = Oe(), A = B(void 0), j = (e) => e ? async (t, n) => {
418
- if (A.current && !A.current.aborted) throw new DOMException("Busy", "AbortError");
419
- A.current = n;
458
+ }, xt = Le(async () => ({ default: (await Ke()).MarkdownEditor })), St = ({ labels: e, values: t, initialValues: n, errors: r, modelSelector: i, modelLabelId: s, skillSelector: u, onFieldChange: f, onBack: h, onCancel: g, onSubmit: _, isSubmitting: C = !1, onRefineDescription: T, onRefineInstructions: re, markdownEditorTheme: ae, backIcon: se, className: ce, styles: le }) => {
459
+ let ue = G(), j = G(), de = G(), fe = G(), he = G(), M = G(), N = G(), P = Ue(void 0), _e = (e) => e ? async (t, n) => {
460
+ if (P.current && !P.current.aborted) throw new DOMException("Busy", "AbortError");
461
+ P.current = n;
420
462
  try {
421
463
  return await e(t, n);
422
464
  } finally {
423
- A.current === n && (A.current = void 0);
465
+ P.current === n && (P.current = void 0);
424
466
  }
425
- } : void 0, M = x({
426
- value: r.description ?? "",
427
- onChange: (e) => b("description", e),
428
- onRefine: j(re),
429
- disabled: T
430
- }), he = x({
431
- value: r.prompt,
432
- onChange: (e) => b("prompt", e),
433
- onRefine: j(ie),
434
- disabled: T
435
- }), ge = M.isPending || he.isPending, ve = () => {
436
- M.reset(), he.reset();
437
- }, N = ee(!!(s && Je(r, s))), be = () => N.guard(() => {
438
- ve(), te();
439
- }), xe = () => N.guard(() => {
440
- ve(), S();
441
- }), P = y(), Se = !r.skillUrls?.length, [F, Ce] = je(), I = B(/* @__PURE__ */ new Date()).current, { colors: L, typography: R, layout: we } = le ?? {}, Ee = R?.titleClassName ?? "dial-h1-text", z = R?.sectionTitleClassName ?? "dial-body-semi-text", ke = R?.sectionSubtitleClassName ?? "dial-tiny-text", Ae = R?.instructionsLabelClassName ?? "dial-body-semi-text mb-1", U = R?.instructionsErrorClassName ?? "dial-small-text", G = _({
442
- "--stcf-details-border": L?.detailsColumnBorder,
443
- "--stcf-subtitle-text": L?.sectionSubtitleText,
444
- "--stcf-error-text": L?.instructionsErrorText,
445
- "--stcf-refine-action-text": L?.refineActionText,
446
- "--stcf-refine-error-text": L?.refineErrorText
447
- }), K = {
448
- feedbackClassName: v(L?.refineActionText && Z.refineFeedback, R?.refineFeedbackClassName, W.refineFeedback),
467
+ } : void 0, F = w({
468
+ value: t.description ?? "",
469
+ onChange: (e) => f("description", e),
470
+ onRefine: _e(T),
471
+ disabled: C
472
+ }), I = w({
473
+ value: t.prompt,
474
+ onChange: (e) => f("prompt", e),
475
+ onRefine: _e(re),
476
+ disabled: C
477
+ }), L = F.isPending || I.isPending, ve = () => {
478
+ F.reset(), I.reset();
479
+ }, R = !!(n && pt(t, n)), z = ee(R), be = () => z.guard(() => {
480
+ ve(), h();
481
+ }), B = () => z.guard(() => {
482
+ ve(), g();
483
+ }), Se = x(), we = !t.skillUrls?.length, [Te, De] = We(), Oe = Ue(/* @__PURE__ */ new Date()).current, { colors: V, typography: H, layout: U } = le ?? {}, Ae = H?.titleClassName ?? "dial-h1-text", je = H?.sectionTitleClassName ?? "dial-body-semi-text", Me = H?.sectionSubtitleClassName ?? "dial-tiny-text", Ne = H?.instructionsLabelClassName ?? "dial-body-semi-text mb-1", W = H?.instructionsErrorClassName ?? "dial-tiny-text", Pe = y({
484
+ "--stcf-details-border": V?.detailsColumnBorder,
485
+ "--stcf-subtitle-text": V?.sectionSubtitleText,
486
+ "--stcf-error-text": V?.instructionsErrorText,
487
+ "--stcf-refine-action-text": V?.refineActionText,
488
+ "--stcf-refine-error-text": V?.refineErrorText
489
+ }), Fe = {
490
+ feedbackClassName: b(V?.refineActionText && Z.refineFeedback, H?.refineFeedbackClassName, Je.refineFeedback),
449
491
  errorClassName: Z.refineError
450
- }, Pe = (e) => {
451
- Ce(c.test(e.target.value) ? void 0 : n.timeInvalidLabel), b("time", e.target.value);
452
- }, q = (e) => {
453
- Ce(void 0), b("time", typeof e == "string" ? e : "");
454
- }, J = r.repeat !== t.OneTime && r.repeat !== t.Hourly;
455
- De(() => {
456
- J || Ce(void 0);
457
- }, [J]);
458
- let Fe = J ? F ?? u.time : void 0, Y = (e) => b("runAt", e), Ie = T || ge || !r.displayName.trim() || !r.modelId || !r.prompt.trim() && !r.skillUrls?.length || !!u.skillUrls || J && !r.time || !!Fe;
459
- return /* @__PURE__ */ H(Me, { children: [/* @__PURE__ */ V(Ne, {
492
+ }, Le = (t) => {
493
+ let n = c.test(t.target.value) ? void 0 : e.timeInvalidLabel;
494
+ De(n), f("time", t.target.value);
495
+ }, Re = (e) => {
496
+ De(void 0), f("time", typeof e == "string" ? e : "");
497
+ }, ze = (e) => {
498
+ let n = e;
499
+ f("repeat", n);
500
+ let r = mt(t.startDate, t.repeat, n);
501
+ r !== t.startDate && f("startDate", r ?? "");
502
+ let i = mt(t.endDate, t.repeat, n);
503
+ i !== t.endDate && f("endDate", i ?? "");
504
+ }, Ve = t.repeat !== l.OneTime && t.repeat !== l.Hourly, He = t.repeat === l.Custom, Ke = He && !t.dayOfWeek;
505
+ Be(() => {
506
+ Ve || De(void 0);
507
+ }, [Ve]);
508
+ let qe = Ve ? Te ?? r.time : void 0;
509
+ S(() => dt(s), fe, !!r.modelId), S(() => document.getElementById("scheduled-task-day-of-week"), he, !!r.dayOfWeek), S(() => document.getElementById("scheduled-task-time"), M, !!qe), S(() => document.getElementById(j), N, !!r.prompt);
510
+ let Y = (e) => f("runAt", e), Ye = (e) => {
511
+ f("everyWeeks", e);
512
+ }, Xe = (e) => {
513
+ e !== t.dayOfWeek && f("dayOfWeek", e);
514
+ }, X = C || L || !t.displayName.trim() || !t.modelId || !t.prompt.trim() && !t.skillUrls?.length || !!r.skillUrls || t.repeat === l.OneTime && (!t.runAt || !!r.runAt) || Ve && !t.time || Ke || !!qe;
515
+ return /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q(Ge, {
460
516
  labels: {
461
- title: n.pageTitle,
462
- backButtonLabel: n.backButtonLabel,
463
- cancelButtonLabel: n.cancelButtonLabel,
464
- submitButtonLabel: n.createButtonLabel,
465
- submittingLabel: n.submittingLabel ?? "Saving"
517
+ title: e.pageTitle,
518
+ backButtonLabel: e.backButtonLabel,
519
+ cancelButtonLabel: e.cancelButtonLabel,
520
+ submitButtonLabel: e.createButtonLabel,
521
+ submittingLabel: e.submittingLabel ?? "Saving"
466
522
  },
467
523
  onBack: be,
468
- onCancel: xe,
524
+ onCancel: B,
469
525
  onSubmit: () => {
470
- !Ie && (!A.current || A.current.aborted) && ne();
526
+ !X && (!P.current || P.current.aborted) && _();
471
527
  },
472
- isCancelDisabled: T,
473
- isSubmitDisabled: Ie,
474
- isSubmitting: T,
475
- backIcon: ae === void 0 ? /* @__PURE__ */ V(ye, {
476
- size: D.LG,
477
- stroke: O,
528
+ isCancelDisabled: C,
529
+ isSubmitDisabled: X,
530
+ isSubmitting: C,
531
+ backIcon: se === void 0 ? /* @__PURE__ */ q(ke, {
532
+ size: O.LG,
533
+ stroke: k,
478
534
  "aria-hidden": !0,
479
535
  className: "rtl:scale-x-[-1]"
480
- }) : ae,
536
+ }) : se,
481
537
  layout: {
482
- sideColumnWidth: we?.detailsWidth,
483
- columnGap: we?.columnGap,
538
+ sideColumnWidth: U?.detailsWidth,
539
+ columnGap: U?.columnGap,
484
540
  reserveEndColumn: !1
485
541
  },
486
- className: oe,
542
+ className: ce,
487
543
  styles: {
488
- colors: { background: L?.background },
544
+ colors: { background: V?.background },
489
545
  header: {
490
- colors: { borderColor: L?.headerBorder },
491
- typography: { fontClassName: Ee }
546
+ colors: { borderColor: V?.headerBorder },
547
+ typography: { fontClassName: Ae }
492
548
  },
493
- cssVars: G
549
+ cssVars: Pe
494
550
  },
495
- left: /* @__PURE__ */ H("div", {
551
+ left: /* @__PURE__ */ J("div", {
496
552
  role: "group",
497
- "aria-label": n.detailsSectionTitle,
498
- className: v("flex flex-1 flex-col gap-5 py-6 desktop:border-e", Z.detailsColumn, Z.formColumn),
553
+ "aria-label": e.detailsSectionTitle,
554
+ className: b("flex flex-1 flex-col gap-5 py-6 desktop:border-e", Z.detailsColumn, Z.formColumn),
499
555
  children: [
500
- /* @__PURE__ */ H("div", {
556
+ /* @__PURE__ */ J("div", {
501
557
  className: "flex flex-col gap-1",
502
- children: [/* @__PURE__ */ V("h2", {
503
- className: z,
504
- children: n.detailsSectionTitle
505
- }), /* @__PURE__ */ V("p", {
506
- className: v(ke, Z.sectionSubtitle),
507
- children: n.detailsSectionSubtitle
558
+ children: [/* @__PURE__ */ q("h2", {
559
+ className: je,
560
+ children: e.detailsSectionTitle
561
+ }), /* @__PURE__ */ q("p", {
562
+ className: b(Me, Z.sectionSubtitle),
563
+ children: e.detailsSectionSubtitle
508
564
  })]
509
565
  }),
510
- /* @__PURE__ */ V(se, {
566
+ /* @__PURE__ */ q(pe, {
511
567
  id: "scheduled-task-display-name",
512
- value: r.displayName,
513
- onChange: (e) => b("displayName", e ?? ""),
568
+ value: t.displayName,
569
+ onChange: (e) => f("displayName", e ?? ""),
514
570
  labelProps: {
515
- label: n.displayNameLabel,
571
+ label: e.displayNameLabel,
516
572
  required: !0
517
573
  },
518
- invalid: !!u.displayName,
519
- error: u.displayName
574
+ invalid: !!r.displayName,
575
+ error: r.displayName
520
576
  }),
521
- /* @__PURE__ */ V(g, {
522
- isEnabled: !!re,
577
+ /* @__PURE__ */ q(v, {
578
+ isEnabled: !!T,
523
579
  fieldId: ue,
524
- label: n.descriptionLabel,
525
- labels: n,
526
- refinement: M,
527
- disabled: T || ge,
528
- ...K,
529
- children: /* @__PURE__ */ V(_e, {
580
+ label: e.descriptionLabel,
581
+ labels: e,
582
+ refinement: F,
583
+ disabled: C || L,
584
+ caption: `${(t.description ?? "").length}/500`,
585
+ ...Fe,
586
+ children: /* @__PURE__ */ q(Ee, {
530
587
  id: ue,
531
- value: r.description ?? "",
588
+ value: t.description ?? "",
532
589
  onChange: (e) => {
533
- M.reset(), b("description", e);
590
+ F.reset(), f("description", e);
534
591
  },
535
- labelProps: re ? void 0 : { label: n.descriptionLabel },
592
+ labelProps: T ? void 0 : { label: e.descriptionLabel },
536
593
  maxLength: 500,
537
- invalid: !!u.description,
538
- error: u.description,
539
- caption: r.description ? `${r.description.length}/500` : void 0
594
+ invalid: !!r.description,
595
+ error: r.description
540
596
  })
541
597
  }),
542
- /* @__PURE__ */ H("div", {
598
+ /* @__PURE__ */ J("div", {
543
599
  className: "flex flex-col gap-1",
544
600
  children: [
545
- /* @__PURE__ */ V(ce, {
546
- id: m,
547
- label: n.modelOrAgentLabel,
601
+ /* @__PURE__ */ q(me, {
602
+ id: s,
603
+ label: e.modelOrAgentLabel,
548
604
  required: !0
549
605
  }),
550
- p,
551
- u.modelId && /* @__PURE__ */ V("p", {
552
- className: v(U, Z.instructionsError),
553
- children: u.modelId
606
+ i,
607
+ r.modelId && /* @__PURE__ */ q(A, {
608
+ id: fe,
609
+ className: b(W, Z.instructionsError),
610
+ text: r.modelId
554
611
  })
555
612
  ]
556
613
  }),
557
- /* @__PURE__ */ H("div", {
614
+ /* @__PURE__ */ J("div", {
558
615
  className: "flex flex-col gap-3",
559
616
  children: [
560
- /* @__PURE__ */ V(pe, {
561
- labelProps: { label: n.repeatLabel },
562
- value: r.repeat,
563
- onChange: (e) => b("repeat", e),
564
- options: n.repeatOptions.map((e) => ({
617
+ /* @__PURE__ */ q(xe, {
618
+ labelProps: { label: e.repeatLabel },
619
+ value: t.repeat,
620
+ onChange: ze,
621
+ options: e.repeatOptions.map((e) => ({
565
622
  value: e.key,
566
623
  label: e.label
567
624
  }))
568
625
  }),
569
- r.repeat === t.OneTime && /* @__PURE__ */ V(Xe, {
570
- label: n.runAtLabel,
571
- value: r.runAt ?? "",
626
+ t.repeat === l.OneTime && /* @__PURE__ */ q(bt, {
627
+ label: e.runAtLabel,
628
+ placeholder: e.runAtPlaceholder,
629
+ value: t.runAt ?? "",
572
630
  onChange: Y,
573
- error: u.runAt,
574
- errorClassName: U
631
+ error: r.runAt,
632
+ errorClassName: W,
633
+ disabled: C
575
634
  }),
576
- r.repeat !== t.OneTime && /* @__PURE__ */ H(Me, { children: [
577
- J && /* @__PURE__ */ H("div", {
635
+ t.repeat !== l.OneTime && /* @__PURE__ */ J(K, { children: [
636
+ He && /* @__PURE__ */ q(xe, {
637
+ id: "scheduled-task-every-weeks",
638
+ labelProps: { label: e.everyLabel },
639
+ value: t.everyWeeks ?? "",
640
+ onChange: Ye,
641
+ options: e.everyWeekOptions,
642
+ disabled: C
643
+ }),
644
+ t.repeat === l.Weekly && /* @__PURE__ */ J("div", {
578
645
  className: "flex flex-col gap-1",
579
- children: [/* @__PURE__ */ V(C, {
580
- id: "scheduled-task-time",
581
- mode: w.Time,
582
- value: r.time,
583
- onChange: q,
584
- onBlur: Pe,
646
+ children: [/* @__PURE__ */ q(E, {
647
+ id: "scheduled-task-day-of-week",
648
+ mode: D.Weekday,
649
+ value: a(t.dayOfWeek),
650
+ onChange: (e) => f("dayOfWeek", o(e)),
585
651
  labelProps: {
586
- label: n.timeLabel,
652
+ label: e.dayOfWeekLabel,
587
653
  required: !0
588
654
  },
589
- invalid: !!Fe,
590
- disabled: T,
591
- showTimezone: !0
592
- }), Fe && /* @__PURE__ */ V("p", {
593
- className: v(U, Z.instructionsError),
594
- children: Fe
655
+ invalid: !!r.dayOfWeek
656
+ }), r.dayOfWeek && /* @__PURE__ */ q(A, {
657
+ id: he,
658
+ className: b(W, Z.instructionsError),
659
+ text: r.dayOfWeek
595
660
  })]
596
661
  }),
597
- r.repeat === t.Weekly && /* @__PURE__ */ H("div", {
662
+ Ve && /* @__PURE__ */ J("div", {
598
663
  className: "flex flex-col gap-1",
599
- children: [/* @__PURE__ */ V(C, {
600
- id: "scheduled-task-day-of-week",
601
- mode: w.Weekday,
602
- value: a(r.dayOfWeek),
603
- onChange: (e) => b("dayOfWeek", o(e)),
664
+ children: [/* @__PURE__ */ q(E, {
665
+ id: "scheduled-task-time",
666
+ mode: D.Time,
667
+ value: t.time,
668
+ onChange: Re,
669
+ onBlur: Le,
604
670
  labelProps: {
605
- label: n.dayOfWeekLabel,
671
+ label: e.timeLabel,
606
672
  required: !0
607
673
  },
608
- invalid: !!u.dayOfWeek
609
- }), u.dayOfWeek && /* @__PURE__ */ V("p", {
610
- className: v(U, Z.instructionsError),
611
- children: u.dayOfWeek
674
+ invalid: !!qe,
675
+ disabled: C,
676
+ showTimezone: !0
677
+ }), qe && /* @__PURE__ */ q(A, {
678
+ id: M,
679
+ className: b(W, Z.instructionsError),
680
+ text: qe
612
681
  })]
613
682
  }),
614
- r.repeat === t.Monthly && /* @__PURE__ */ V(de, {
683
+ He && /* @__PURE__ */ J("div", {
684
+ className: "flex flex-col gap-1",
685
+ children: [
686
+ /* @__PURE__ */ q(me, {
687
+ id: de,
688
+ label: e.dayOfWeekLabel,
689
+ required: !0
690
+ }),
691
+ /* @__PURE__ */ q("div", {
692
+ role: "group",
693
+ "aria-labelledby": de,
694
+ className: "flex gap-0.5",
695
+ children: e.customDayOptions.map((e) => {
696
+ let n = e.value === t.dayOfWeek;
697
+ return /* @__PURE__ */ q(te, {
698
+ "aria-label": e.fullName,
699
+ "aria-pressed": n,
700
+ "aria-describedby": r.dayOfWeek ? he : void 0,
701
+ variant: n ? ie.Primary : ie.Neutral,
702
+ appearance: ne.Solid,
703
+ className: "w-10 rounded-full",
704
+ label: e.shortLabel,
705
+ onClick: () => Xe(e.value),
706
+ disabled: C
707
+ }, e.value);
708
+ })
709
+ }),
710
+ r.dayOfWeek && /* @__PURE__ */ q(A, {
711
+ id: he,
712
+ className: b(W, Z.instructionsError),
713
+ text: r.dayOfWeek
714
+ })
715
+ ]
716
+ }),
717
+ t.repeat === l.Monthly && /* @__PURE__ */ q(ye, {
615
718
  id: "scheduled-task-day-of-month",
616
719
  integer: !0,
617
720
  min: 1,
618
721
  max: 31,
619
- value: r.dayOfMonth ?? "",
620
- onChange: (e) => b("dayOfMonth", e == null ? "" : String(e)),
722
+ value: t.dayOfMonth ?? "",
723
+ onChange: (e) => f("dayOfMonth", e == null ? "" : String(e)),
621
724
  labelProps: {
622
- label: n.dayOfMonthLabel,
725
+ label: e.dayOfMonthLabel,
623
726
  required: !0
624
727
  },
625
- invalid: !!u.dayOfMonth,
626
- error: u.dayOfMonth
728
+ invalid: !!r.dayOfMonth,
729
+ error: r.dayOfMonth
627
730
  }),
628
- r.repeat === t.Hourly && /* @__PURE__ */ V(de, {
731
+ t.repeat === l.Hourly && /* @__PURE__ */ q(ye, {
629
732
  id: "scheduled-task-minute",
630
733
  integer: !0,
631
734
  min: 0,
632
735
  max: 59,
633
- value: r.minute ?? "",
634
- onChange: (e) => b("minute", e == null ? "" : String(e)),
736
+ wrapperClassName: "w-[142px]",
737
+ value: t.minute ?? "",
738
+ onChange: (e) => f("minute", e == null ? "" : String(e)),
635
739
  labelProps: {
636
- label: n.minuteLabel,
740
+ label: e.minuteLabel,
637
741
  required: !0
638
742
  },
639
- invalid: !!u.minute,
640
- error: u.minute
743
+ invalid: !!r.minute,
744
+ error: r.minute
641
745
  }),
642
- /* @__PURE__ */ H("div", {
746
+ !He && /* @__PURE__ */ J("div", {
643
747
  className: "flex flex-row gap-3",
644
- children: [/* @__PURE__ */ H("div", {
645
- className: "flex flex-1 flex-col gap-1",
646
- children: [/* @__PURE__ */ V(C, {
647
- id: "scheduled-task-start-date",
648
- mode: w.Date,
649
- value: e(r.startDate),
650
- onChange: (e) => b("startDate", i(e)),
651
- minDate: I,
652
- labelProps: { label: n.startDateLabel },
653
- placeholder: n.startDatePlaceholder,
654
- invalid: !!u.startDate
655
- }), u.startDate && /* @__PURE__ */ V("p", {
656
- className: v(U, Z.instructionsError),
657
- children: u.startDate
658
- })]
659
- }), /* @__PURE__ */ H("div", {
660
- className: "flex flex-1 flex-col gap-1",
661
- children: [/* @__PURE__ */ V(C, {
662
- id: "scheduled-task-end-date",
663
- mode: w.Date,
664
- value: e(r.endDate),
665
- onChange: (e) => b("endDate", i(e)),
666
- minDate: I,
667
- labelProps: { label: n.endDateLabel },
668
- placeholder: n.endDatePlaceholder,
669
- invalid: !!u.endDate
670
- }), u.endDate && /* @__PURE__ */ V("p", {
671
- className: v(U, Z.instructionsError),
672
- children: u.endDate
673
- })]
748
+ children: [/* @__PURE__ */ q(gt, {
749
+ id: "scheduled-task-start-date",
750
+ label: e.startDateLabel,
751
+ placeholder: e.startDatePlaceholder,
752
+ value: t.startDate,
753
+ onChange: (e) => f("startDate", e),
754
+ minDate: Oe,
755
+ error: r.startDate,
756
+ errorClassName: W,
757
+ disabled: C
758
+ }), /* @__PURE__ */ q(gt, {
759
+ id: "scheduled-task-end-date",
760
+ label: e.endDateLabel,
761
+ placeholder: e.endDatePlaceholder,
762
+ value: t.endDate,
763
+ onChange: (e) => f("endDate", e),
764
+ minDate: Oe,
765
+ error: r.endDate,
766
+ errorClassName: W,
767
+ disabled: C
674
768
  })]
675
769
  })
676
770
  ] })
@@ -678,72 +772,68 @@ var W = {
678
772
  })
679
773
  ]
680
774
  }),
681
- children: /* @__PURE__ */ H("div", {
775
+ children: /* @__PURE__ */ J("div", {
682
776
  role: "group",
683
- "aria-label": n.configurationSectionTitle,
684
- className: v("flex flex-1 flex-col gap-5 py-6", Z.formColumn),
777
+ "aria-label": e.configurationSectionTitle,
778
+ className: b("flex flex-1 flex-col gap-5 py-6", Z.formColumn),
685
779
  children: [
686
- /* @__PURE__ */ H("div", {
780
+ /* @__PURE__ */ q("div", {
687
781
  className: "flex flex-col gap-1",
688
- children: [/* @__PURE__ */ V("h2", {
689
- className: z,
690
- children: n.configurationSectionTitle
691
- }), /* @__PURE__ */ V("p", {
692
- className: v(ke, Z.sectionSubtitle),
693
- children: n.configurationSectionSubtitle
694
- })]
695
- }),
696
- h == null ? u.skillUrls && /* @__PURE__ */ V("div", {
697
- "aria-live": "polite",
698
- children: /* @__PURE__ */ V("p", {
699
- className: v(U, Z.instructionsError),
700
- children: u.skillUrls
782
+ children: /* @__PURE__ */ q("h2", {
783
+ className: je,
784
+ children: e.configurationSectionTitle
701
785
  })
702
- }) : /* @__PURE__ */ V("div", {
703
- className: "w-full min-w-0 max-w-[996px]",
704
- children: h
705
786
  }),
706
- /* @__PURE__ */ V("div", {
707
- className: "flex w-full min-w-0 max-w-[996px] flex-col",
708
- children: /* @__PURE__ */ V(g, {
709
- isEnabled: !!ie,
710
- fieldId: fe,
711
- labelClassName: Ae,
712
- label: n.instructionsLabel,
713
- required: Se,
714
- labels: n,
715
- refinement: he,
716
- disabled: T || ge,
717
- ...K,
718
- children: /* @__PURE__ */ H("div", {
787
+ u == null ? /* @__PURE__ */ q(A, {
788
+ announce: ge.Polite,
789
+ className: b(W, Z.instructionsError),
790
+ text: r.skillUrls ?? ""
791
+ }) : /* @__PURE__ */ q("div", {
792
+ className: "w-full max-w-[996px] min-w-0",
793
+ children: u
794
+ }),
795
+ /* @__PURE__ */ q("div", {
796
+ className: "flex w-full max-w-[996px] min-w-0 flex-col",
797
+ children: /* @__PURE__ */ q(v, {
798
+ isEnabled: !!re,
799
+ fieldId: j,
800
+ labelClassName: Ne,
801
+ label: e.instructionsLabel,
802
+ required: we,
803
+ labels: e,
804
+ refinement: I,
805
+ disabled: C || L,
806
+ ...Fe,
807
+ children: /* @__PURE__ */ J("div", {
719
808
  className: "flex flex-1 flex-col gap-1",
720
809
  children: [
721
- !ie && /* @__PURE__ */ V(ce, {
722
- htmlFor: fe,
723
- className: Ae,
724
- label: n.instructionsLabel,
725
- required: Se
810
+ !re && /* @__PURE__ */ q(me, {
811
+ htmlFor: j,
812
+ className: Ne,
813
+ label: e.instructionsLabel,
814
+ required: we
726
815
  }),
727
- /* @__PURE__ */ V("div", {
728
- ref: P,
729
- className: v("w-full", d, f),
730
- children: /* @__PURE__ */ V(Te, {
731
- fallback: /* @__PURE__ */ V(me, {}),
732
- children: /* @__PURE__ */ V(Ze, {
733
- id: fe,
734
- value: r.prompt,
816
+ /* @__PURE__ */ q("div", {
817
+ ref: Se,
818
+ className: b("w-full", p, m),
819
+ children: /* @__PURE__ */ q(Ie, {
820
+ fallback: /* @__PURE__ */ q(Ce, {}),
821
+ children: /* @__PURE__ */ q(xt, {
822
+ id: j,
823
+ value: t.prompt,
735
824
  onChange: (e) => {
736
- he.reset(), b("prompt", e);
825
+ I.reset(), f("prompt", e);
737
826
  },
738
827
  height: 480,
739
- theme: k,
740
- placeholder: n.instructionsPlaceholder
828
+ theme: ae,
829
+ placeholder: e.instructionsPlaceholder
741
830
  })
742
831
  })
743
832
  }),
744
- u.prompt && /* @__PURE__ */ V("p", {
745
- className: v(U, Z.instructionsError),
746
- children: u.prompt
833
+ r.prompt && /* @__PURE__ */ q(A, {
834
+ id: N,
835
+ className: b(W, Z.instructionsError),
836
+ text: r.prompt
747
837
  })
748
838
  ]
749
839
  })
@@ -751,278 +841,308 @@ var W = {
751
841
  })
752
842
  ]
753
843
  })
754
- }), N.isConfirmOpen && /* @__PURE__ */ V(l, {
844
+ }), z.isConfirmOpen && /* @__PURE__ */ q(d, {
755
845
  open: !0,
756
- title: n.discardTitle ?? "Discard unsaved changes?",
757
- message: n.discardMessage ?? "You have unsaved changes. Leaving now will discard them.",
758
- confirmLabel: n.discardConfirmLabel ?? "Discard changes",
759
- cancelLabel: n.discardCancelLabel ?? "Keep editing",
760
- variant: E.Danger,
761
- onConfirm: N.confirm,
762
- onClose: N.dismiss
846
+ title: e.discardTitle ?? "Discard unsaved changes?",
847
+ message: e.discardMessage ?? "You have unsaved changes. Leaving now will discard them.",
848
+ confirmLabel: e.discardConfirmLabel ?? "Discard changes",
849
+ cancelLabel: e.discardCancelLabel ?? "Keep editing",
850
+ variant: oe.Danger,
851
+ onConfirm: z.confirm,
852
+ onClose: z.dismiss
763
853
  })] });
764
- }, $e = /* @__PURE__ */ function(e) {
854
+ }, Ct = /* @__PURE__ */ function(e) {
765
855
  return e.Details = "details", e.Configuration = "configuration", e.History = "history", e;
766
- }({}), et = /* @__PURE__ */ function(e) {
856
+ }({}), wt = /* @__PURE__ */ function(e) {
767
857
  return e.Card = "card", e.Flow = "flow", e;
768
- }({}), 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", {
858
+ }({}), Tt = { subtitleText: "_subtitleText_1i4x2_3" }, Et = {
859
+ ...u,
860
+ ul: "dial-small-paragraph-text mb-3 space-y-1",
861
+ ol: "dial-small-paragraph-text mb-3 space-y-1"
862
+ }, Dt = ({ skillLabel: e, skillDisplayNames: t, instructionsLabel: n, instructionsMarkdown: r, renderInstructions: i, markdownLabels: a, fieldLabelClassName: o = "dial-tiny-text" }) => /* @__PURE__ */ J("div", {
769
863
  className: "flex min-w-0 flex-col gap-5",
770
- children: [!!t?.length && /* @__PURE__ */ H("div", {
864
+ children: [!!t?.length && /* @__PURE__ */ J("div", {
771
865
  role: "group",
772
866
  "aria-label": e,
773
867
  className: "flex min-w-0 flex-col gap-1",
774
- children: [/* @__PURE__ */ V("span", {
775
- className: v(o, tt.subtitleText),
868
+ children: [/* @__PURE__ */ q("span", {
869
+ className: b(o, Tt.subtitleText),
776
870
  children: e
777
- }), /* @__PURE__ */ V("p", {
778
- className: "whitespace-normal break-all",
779
- children: t?.map((e, t) => /* @__PURE__ */ V("span", {
871
+ }), /* @__PURE__ */ q("p", {
872
+ className: "wrap-anywhere whitespace-normal",
873
+ children: t?.map((e, t) => /* @__PURE__ */ q("span", {
780
874
  className: "block",
781
875
  children: e
782
876
  }, `${t}:${e}`))
783
877
  })]
784
- }), r && /* @__PURE__ */ H("div", {
878
+ }), r && /* @__PURE__ */ J("div", {
785
879
  role: "group",
786
880
  "aria-label": n,
787
881
  className: "flex min-w-0 flex-col gap-1",
788
- children: [/* @__PURE__ */ V("span", {
789
- className: v(o, tt.subtitleText),
882
+ children: [/* @__PURE__ */ q("span", {
883
+ className: b(o, Tt.subtitleText),
790
884
  children: n
791
- }), i ? i(r) : /* @__PURE__ */ V(p, {
885
+ }), i ? i(r) : /* @__PURE__ */ q(h, {
792
886
  content: r,
887
+ classNames: Et,
793
888
  ...a
794
889
  })]
795
890
  })]
796
- }), 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: [
797
- t && /* @__PURE__ */ H("div", {
798
- className: "flex flex-col gap-1",
799
- children: [/* @__PURE__ */ V("span", {
800
- className: v(o, rt.subtitleText),
801
- children: e.descriptionLabel
802
- }), /* @__PURE__ */ V("p", {
803
- className: s,
804
- children: t
805
- })]
806
- }),
807
- a && /* @__PURE__ */ H("div", {
808
- className: "flex flex-col gap-1",
809
- children: [/* @__PURE__ */ V("span", {
810
- className: v(o, rt.subtitleText),
811
- children: e.completedFieldLabel
812
- }), /* @__PURE__ */ V("p", {
813
- className: s,
814
- children: a
815
- })]
816
- }),
817
- n && /* @__PURE__ */ H("div", {
818
- className: "flex flex-col gap-1",
819
- children: [/* @__PURE__ */ V("span", {
820
- className: v(o, rt.subtitleText),
821
- children: e.modelLabel
822
- }), /* @__PURE__ */ V("p", {
823
- className: s,
824
- children: n
825
- })]
826
- }),
827
- r && /* @__PURE__ */ H("div", {
828
- className: "flex flex-col gap-1",
829
- children: [/* @__PURE__ */ V("span", {
830
- className: v(o, rt.subtitleText),
831
- children: e.repeatsLabel
832
- }), /* @__PURE__ */ V("p", {
833
- className: s,
834
- children: r
835
- })]
836
- }),
837
- i && /* @__PURE__ */ H("div", {
838
- className: "flex flex-col gap-1",
839
- children: [/* @__PURE__ */ V("span", {
840
- className: v(o, rt.subtitleText),
841
- children: e.activeWindowLabel
842
- }), /* @__PURE__ */ V("p", {
843
- className: s,
844
- children: i
845
- })]
846
- })
847
- ] }), at = /* @__PURE__ */ function(e) {
891
+ }), Ot = {
892
+ subtitleText: "_subtitleText_1ncri_4",
893
+ description: "_description_1ncri_10"
894
+ }, kt = ({ labels: e, description: t, modelLabel: n, repeatsLabel: r, activeWindowLabel: i, completedLabel: a, fieldLabelClassName: o = "dial-tiny-text", fieldValueClassName: s = "dial-small-text" }) => {
895
+ let c = t?.trim();
896
+ return /* @__PURE__ */ J(K, { children: [
897
+ c && /* @__PURE__ */ J("div", {
898
+ className: "flex min-w-0 flex-col gap-1",
899
+ children: [/* @__PURE__ */ q("span", {
900
+ className: b(o, Ot.subtitleText),
901
+ children: e.descriptionLabel
902
+ }), /* @__PURE__ */ q("p", {
903
+ className: b(s, "wrap-anywhere whitespace-pre-wrap", Ot.description),
904
+ children: c
905
+ })]
906
+ }),
907
+ a && /* @__PURE__ */ J("div", {
908
+ className: "flex min-w-0 flex-col gap-1",
909
+ children: [/* @__PURE__ */ q("span", {
910
+ className: b(o, Ot.subtitleText),
911
+ children: e.completedFieldLabel
912
+ }), /* @__PURE__ */ q("p", {
913
+ className: s,
914
+ children: a
915
+ })]
916
+ }),
917
+ n && /* @__PURE__ */ J("div", {
918
+ className: "flex min-w-0 flex-col gap-1",
919
+ children: [/* @__PURE__ */ q("span", {
920
+ className: b(o, Ot.subtitleText),
921
+ children: e.modelLabel
922
+ }), /* @__PURE__ */ q("p", {
923
+ className: s,
924
+ children: n
925
+ })]
926
+ }),
927
+ r && /* @__PURE__ */ J("div", {
928
+ className: "flex min-w-0 flex-col gap-1",
929
+ children: [/* @__PURE__ */ q("span", {
930
+ className: b(o, Ot.subtitleText),
931
+ children: e.repeatsLabel
932
+ }), /* @__PURE__ */ q("p", {
933
+ className: s,
934
+ children: r
935
+ })]
936
+ }),
937
+ i && /* @__PURE__ */ J("div", {
938
+ className: "flex min-w-0 flex-col gap-1",
939
+ children: [/* @__PURE__ */ q("span", {
940
+ className: b(o, Ot.subtitleText),
941
+ children: e.activeWindowLabel
942
+ }), /* @__PURE__ */ q("p", {
943
+ className: s,
944
+ children: i
945
+ })]
946
+ })
947
+ ] });
948
+ }, At = /* @__PURE__ */ function(e) {
848
949
  return e.Success = "success", e.Error = "error", e.InProgress = "inProgress", e.Missed = "missed", e;
849
950
  }({}), Q = {
850
- subtitleText: "_subtitleText_1d5p9_1",
851
- successIcon: "_successIcon_1d5p9_5",
852
- errorIcon: "_errorIcon_1d5p9_9",
853
- missedIcon: "_missedIcon_1d5p9_13",
854
- currentRun: "_currentRun_1d5p9_17",
855
- interactiveRow: "_interactiveRow_1d5p9_22",
856
- unreadDot: "_unreadDot_1d5p9_33",
857
- rowLayout: "_rowLayout_1d5p9_37"
858
- }, ot = ({ status: e }) => {
951
+ subtitleText: "_subtitleText_1sqjy_1",
952
+ successIcon: "_successIcon_1sqjy_5",
953
+ errorIcon: "_errorIcon_1sqjy_9",
954
+ missedIcon: "_missedIcon_1sqjy_13",
955
+ currentRun: "_currentRun_1sqjy_17",
956
+ interactiveRow: "_interactiveRow_1sqjy_27",
957
+ unreadDot: "_unreadDot_1sqjy_38"
958
+ }, jt = ({ status: e }) => {
859
959
  switch (e) {
860
- case at.Success: return /* @__PURE__ */ V(xe, {
861
- size: D.SM,
960
+ case At.Success: return /* @__PURE__ */ q(Ae, {
961
+ size: O.SM,
862
962
  className: Q.successIcon,
863
963
  "aria-hidden": !0,
864
- stroke: O
964
+ stroke: k
865
965
  });
866
- case at.Error: return /* @__PURE__ */ V(P, {
867
- size: D.SM,
966
+ case At.Error: return /* @__PURE__ */ q(je, {
967
+ size: O.SM,
868
968
  className: Q.errorIcon,
869
969
  "aria-hidden": !0,
870
- stroke: O
970
+ stroke: k
871
971
  });
872
- case at.InProgress: return /* @__PURE__ */ V("span", {
972
+ case At.InProgress: return /* @__PURE__ */ q("span", {
873
973
  "aria-hidden": !0,
874
- children: /* @__PURE__ */ V(me, { size: D.SM })
974
+ children: /* @__PURE__ */ q(Ce, { size: O.SM })
875
975
  });
876
- case at.Missed: return /* @__PURE__ */ V(ve, {
877
- size: D.SM,
976
+ case At.Missed: return /* @__PURE__ */ q(V, {
977
+ size: O.SM,
878
978
  className: Q.missedIcon,
879
979
  "aria-hidden": !0,
880
- stroke: O
980
+ stroke: k
881
981
  });
882
982
  default: return null;
883
983
  }
884
- }, 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 }) => {
885
- let { colors: d, typography: f } = u ?? {}, p = f?.runTimestampClassName ?? "dial-small-text", m = f?.subtitleClassName ?? "dial-body-text", h = c.unreadIndicatorLabel ?? "Unread", g = _({
984
+ }, Mt = ({ 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 }) => {
985
+ let { colors: d, typography: f } = u ?? {}, p = f?.runTimestampClassName ?? "dial-small-paragraph-text", m = f?.runTimestampUnreadClassName ?? "dial-small-paragraph-semi-text", h = f?.subtitleClassName ?? "dial-body-text", g = c.unreadIndicatorLabel ?? "Unread", _ = y({
886
986
  "--strhl-success-icon": d?.successIconColor,
887
987
  "--strhl-error-icon": d?.errorIconColor,
888
988
  "--strhl-missed-icon": d?.missedIconColor,
889
989
  "--strhl-subtitle-text": d?.subtitleTextColor,
890
990
  "--strhl-current-run-bg": d?.currentRunBackground,
991
+ "--strhl-current-run-subtitle-text": d?.currentRunSubtitleTextColor,
891
992
  "--strhl-unread-dot": d?.unreadDotColor,
892
993
  "--strhl-row-hover-bg": u?.rowHoverBackground,
893
994
  "--strhl-row-focus-bg": u?.rowFocusBackground,
894
995
  "--strhl-row-focus-outline": u?.rowFocusOutline
895
- }), y = (e) => {
896
- let t = c.runStatusLabels[e.status], n = e.id === o, r = [e.isUnread ? h : void 0, n ? c.currentRunLabel : void 0].filter((e) => !!e), i = [`${t} ${e.timestampLabel}`, ...r].join(" — "), a = !!e.conversationId && !!s;
897
- return /* @__PURE__ */ H("li", {
898
- ...a ? {
899
- role: "button",
900
- tabIndex: 0,
901
- onClick: () => s?.(e),
902
- onKeyDown: (t) => {
903
- (t.key === "Enter" || t.key === " ") && (t.preventDefault(), s?.(e));
904
- }
905
- } : {},
906
- "aria-label": i,
907
- "aria-current": n ? "true" : void 0,
908
- className: v("flex min-h-[var(--strhl-row-min-height,32px)] max-w-[328px] items-center justify-between gap-2 rounded-full pe-2", Q.rowLayout, n && Q.currentRun, a && "cursor-pointer", a && Q.interactiveRow),
909
- children: [/* @__PURE__ */ H("span", {
910
- className: "flex items-center gap-2 truncate",
911
- children: [/* @__PURE__ */ V("span", {
912
- className: "relative flex size-3 shrink-0 items-center justify-center",
913
- children: e.isUnread && /* @__PURE__ */ V("span", {
914
- className: v("size-[5.33px] rounded-full", Q.unreadDot),
915
- "aria-hidden": !0
916
- })
917
- }), /* @__PURE__ */ V("span", {
918
- className: v(p, "truncate"),
996
+ }), v = (e) => {
997
+ let t = c.runStatusLabels[e.status], n = e.id === o, r = e.status === At.Error && e.errorText ? e.errorText : void 0, i = [
998
+ r,
999
+ e.isUnread ? g : void 0,
1000
+ n ? c.currentRunLabel : void 0
1001
+ ].filter((e) => !!e), a = [[
1002
+ t,
1003
+ e.timestampLabel,
1004
+ e.durationLabel
1005
+ ].filter(Boolean).join(" "), ...i].join(" — "), l = !!e.conversationId && !!s, u = b("-mx-(--strhl-row-bleed,0px) flex min-h-(--strhl-row-min-height,32px) max-w-[328px] items-center justify-between gap-2 rounded-full px-3", n && Q.currentRun, l && "w-full cursor-pointer text-start", l && Q.interactiveRow), d = /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ J("span", {
1006
+ className: "flex min-w-0 items-center gap-1",
1007
+ children: [r ? /* @__PURE__ */ q(De, {
1008
+ tooltip: r,
1009
+ asChild: !0,
1010
+ contentClassName: "max-w-[320px] whitespace-pre-wrap break-words",
1011
+ children: /* @__PURE__ */ q("span", {
1012
+ className: "flex shrink-0",
1013
+ tabIndex: l ? void 0 : 0,
1014
+ children: /* @__PURE__ */ q(jt, { status: e.status })
1015
+ })
1016
+ }) : /* @__PURE__ */ q(jt, { status: e.status }), /* @__PURE__ */ J("span", {
1017
+ className: "flex min-w-0 items-center gap-1",
1018
+ children: [/* @__PURE__ */ q("span", {
1019
+ className: b(e.isUnread ? m : p, "truncate"),
919
1020
  children: e.timestampLabel
1021
+ }), e.durationLabel && /* @__PURE__ */ q("span", {
1022
+ className: b(p, Q.subtitleText, "shrink-0"),
1023
+ children: e.durationLabel
920
1024
  })]
921
- }), /* @__PURE__ */ V("span", {
922
- className: "flex min-h-[var(--strhl-row-min-height,32px)] w-14 shrink-0 items-center justify-end",
923
- children: /* @__PURE__ */ V(ot, { status: e.status })
924
1025
  })]
1026
+ }), /* @__PURE__ */ q("span", {
1027
+ className: "relative flex size-3 shrink-0 items-center justify-center",
1028
+ children: e.isUnread && /* @__PURE__ */ q("span", {
1029
+ className: b("size-[5.33px] rounded-full", Q.unreadDot),
1030
+ "aria-hidden": !0
1031
+ })
1032
+ })] });
1033
+ return l ? /* @__PURE__ */ q("li", { children: /* @__PURE__ */ q("button", {
1034
+ type: "button",
1035
+ "aria-label": a,
1036
+ "aria-current": n ? "true" : void 0,
1037
+ className: u,
1038
+ onClick: () => s?.(e),
1039
+ children: d
1040
+ }) }, e.id) : /* @__PURE__ */ q("li", {
1041
+ "aria-label": a,
1042
+ "aria-current": n ? "true" : void 0,
1043
+ className: u,
1044
+ children: d
925
1045
  }, e.id);
926
- }, b = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ H("li", {
1046
+ }, x = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ J("li", {
927
1047
  "aria-hidden": "true",
928
- className: v("flex min-h-[var(--strhl-row-min-height,32px)] max-w-[328px] items-center justify-between gap-2 pe-2", Q.rowLayout),
929
- children: [/* @__PURE__ */ V(j, {
930
- variant: M.Rectangular,
1048
+ className: "-mx-(--strhl-row-bleed,0px) flex min-h-(--strhl-row-min-height,32px) max-w-[328px] items-center justify-between gap-2 px-3",
1049
+ children: [/* @__PURE__ */ q(B, {
1050
+ variant: Se.Rectangular,
931
1051
  width: "160px",
932
1052
  height: "16px"
933
- }), /* @__PURE__ */ V(j, {
934
- variant: M.Rectangular,
1053
+ }), /* @__PURE__ */ q(B, {
1054
+ variant: Se.Rectangular,
935
1055
  width: "16px",
936
1056
  height: "16px",
937
1057
  className: "shrink-0 rounded-full"
938
1058
  })]
939
1059
  }, `history-skeleton-${t}`));
940
- return t && e.length === 0 ? /* @__PURE__ */ V("ul", {
1060
+ return t && e.length === 0 ? /* @__PURE__ */ q("ul", {
941
1061
  style: {
942
- ...g,
1062
+ ..._,
943
1063
  "--strhl-row-min-height": u?.rowMinHeight
944
1064
  },
945
1065
  "aria-label": c.historyTitle,
946
1066
  className: "flex flex-col gap-0.5",
947
- children: b(r)
948
- }) : i && e.length === 0 ? /* @__PURE__ */ H("div", {
949
- style: g,
1067
+ children: x(r)
1068
+ }) : i && e.length === 0 ? /* @__PURE__ */ J("div", {
1069
+ style: _,
950
1070
  className: "flex flex-col items-start gap-3",
951
- children: [/* @__PURE__ */ V("p", {
952
- role: "alert",
953
- className: v(m, Q.subtitleText),
1071
+ children: [/* @__PURE__ */ q("p", {
1072
+ role: "status",
1073
+ className: b(h, Q.subtitleText),
954
1074
  children: c.errorLabel
955
- }), /* @__PURE__ */ V(k, {
1075
+ }), /* @__PURE__ */ q(j, {
956
1076
  label: c.retryLabel,
957
1077
  onClick: a
958
1078
  })]
959
- }) : e.length === 0 ? /* @__PURE__ */ H("div", {
960
- style: g,
961
- className: "flex w-full flex-col items-center justify-center gap-2 py-4",
962
- children: [/* @__PURE__ */ V(Se, {
963
- size: 44,
964
- stroke: O,
965
- className: Q.subtitleText,
966
- "aria-hidden": !0
967
- }), /* @__PURE__ */ V("p", {
968
- role: "status",
969
- className: p,
970
- children: c.emptyLabel
971
- })]
972
- }) : /* @__PURE__ */ H("ul", {
1079
+ }) : e.length === 0 ? /* @__PURE__ */ q("div", {
1080
+ style: _,
1081
+ className: "w-full py-4",
1082
+ children: /* @__PURE__ */ q(F, {
1083
+ title: c.emptyLabel,
1084
+ description: c.emptyDescription,
1085
+ live: !0
1086
+ })
1087
+ }) : /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ J("ul", {
973
1088
  style: {
974
- ...g,
1089
+ ..._,
975
1090
  "--strhl-row-min-height": u?.rowMinHeight
976
1091
  },
977
1092
  "aria-label": c.historyTitle,
978
1093
  className: "flex flex-col gap-0.5",
979
1094
  children: [
980
- e.map(y),
981
- n && b(r),
982
- i ? /* @__PURE__ */ H("li", {
1095
+ e.map(v),
1096
+ n && x(r),
1097
+ i ? /* @__PURE__ */ J("li", {
983
1098
  className: "flex flex-col items-start gap-3 px-5 py-2",
984
- children: [/* @__PURE__ */ V("p", {
985
- role: "alert",
986
- className: v(m, Q.subtitleText),
1099
+ children: [/* @__PURE__ */ q("p", {
1100
+ className: b(h, Q.subtitleText),
987
1101
  children: c.errorLabel
988
- }), /* @__PURE__ */ V(k, {
1102
+ }), /* @__PURE__ */ q(j, {
989
1103
  label: c.retryLabel,
990
1104
  onClick: a
991
1105
  })]
992
1106
  }) : l
993
1107
  ]
994
- });
995
- }, ct = {
1108
+ }), /* @__PURE__ */ q(M, {
1109
+ politeness: ge.Assertive,
1110
+ visuallyHidden: !0,
1111
+ as: N.Span,
1112
+ children: i ? c.errorLabel : ""
1113
+ })] });
1114
+ }, Nt = {
996
1115
  historyCard: "_historyCard_153p9_4",
997
1116
  subtitleText: "_subtitleText_153p9_8",
998
1117
  cardLayout: "_cardLayout_153p9_13"
999
- }, lt = ({ variant: e, labels: t, nextRunLabel: n, items: r, isLoading: i = !1, isLoadingMore: a = !1, skeletonCount: o = 6, error: s, onRetry: c, loadMoreError: l, onRetryLoadMore: u, hasMore: d = !1, onLoadMore: f, onRunClick: p, runTimestampClassName: m = "dial-small-text", sectionTitleClassName: h = "dial-body-semi-text", colors: g, styles: _ }) => {
1000
- let y = e === et.Card, b = y ? v("sticky bottom-0 z-10 rounded-b-xl px-6 pb-5 pt-2", ct.historyCard) : "pt-2", x = l ? /* @__PURE__ */ H("li", {
1001
- className: b,
1002
- children: [/* @__PURE__ */ V("p", {
1003
- role: "alert",
1004
- children: t.historyLoadMoreErrorLabel ?? t.historyErrorLabel
1005
- }), u && /* @__PURE__ */ V(k, {
1118
+ }, Pt = ({ variant: e, labels: t, nextRunLabel: n, items: r, isLoading: i = !1, isLoadingMore: a = !1, skeletonCount: o = 6, error: s, onRetry: c, loadMoreError: l, onRetryLoadMore: u, hasMore: d = !1, onLoadMore: f, onRunClick: p, runTimestampClassName: m = "dial-small-text", runTimestampUnreadClassName: h = "dial-small-semi-text", sectionTitleClassName: g = "dial-body-semi-text", colors: _, styles: v }) => {
1119
+ let y = e === wt.Card, x = y ? b("sticky bottom-0 z-10 rounded-b-xl px-6 pb-5 pt-2", Nt.historyCard) : "pt-2", S = t.historyLoadMoreErrorLabel ?? t.historyErrorLabel, C = l ? /* @__PURE__ */ J("li", {
1120
+ className: x,
1121
+ children: [/* @__PURE__ */ q("p", { children: S }), u && /* @__PURE__ */ q(j, {
1006
1122
  label: t.historyRetryLabel,
1007
1123
  onClick: u,
1008
1124
  disabled: a
1009
1125
  })]
1010
- }) : f && d && t.historyShowMoreLabel ? /* @__PURE__ */ V("li", {
1011
- className: b,
1012
- children: /* @__PURE__ */ V(k, {
1126
+ }) : f && d && t.historyShowMoreLabel ? /* @__PURE__ */ q("li", {
1127
+ className: x,
1128
+ children: /* @__PURE__ */ q(j, {
1013
1129
  label: t.historyShowMoreLabel,
1014
1130
  onClick: f,
1015
1131
  disabled: a
1016
1132
  })
1017
- }) : void 0, ee = n ? /* @__PURE__ */ V("p", {
1018
- className: v(m, ct.subtitleText),
1133
+ }) : void 0, w = n ? /* @__PURE__ */ q("p", {
1134
+ className: b(m, Nt.subtitleText),
1019
1135
  children: n
1020
- }) : void 0, te = t.historyLoadingMoreLabel ? /* @__PURE__ */ V("span", {
1021
- role: "status",
1022
- "aria-live": "polite",
1023
- className: "sr-only",
1136
+ }) : void 0, ee = /* @__PURE__ */ q(M, {
1137
+ politeness: ge.Assertive,
1138
+ visuallyHidden: !0,
1139
+ as: N.Span,
1140
+ children: l ? S : ""
1141
+ }), T = t.historyLoadingMoreLabel ? /* @__PURE__ */ q(M, {
1142
+ visuallyHidden: !0,
1143
+ as: N.Span,
1024
1144
  children: a ? t.historyLoadingMoreLabel : ""
1025
- }) : void 0, S = /* @__PURE__ */ V(st, {
1145
+ }) : void 0, te = /* @__PURE__ */ q(Mt, {
1026
1146
  items: r,
1027
1147
  isLoading: i,
1028
1148
  isLoadingMore: a,
@@ -1033,44 +1153,51 @@ var W = {
1033
1153
  labels: {
1034
1154
  historyTitle: t.historyTitle,
1035
1155
  emptyLabel: t.historyEmptyLabel,
1156
+ emptyDescription: t.historyEmptyDescription,
1036
1157
  errorLabel: t.historyErrorLabel,
1037
1158
  retryLabel: t.historyRetryLabel,
1038
1159
  runStatusLabels: t.runStatusLabels,
1039
1160
  unreadIndicatorLabel: t.unreadIndicatorLabel
1040
1161
  },
1041
- footer: x,
1162
+ footer: C,
1042
1163
  styles: {
1043
- typography: { runTimestampClassName: m },
1044
- colors: _?.colors ?? g,
1045
- rowMinHeight: _?.rowMinHeight,
1046
- rowHoverBackground: _?.rowHoverBackground,
1047
- rowFocusBackground: _?.rowFocusBackground,
1048
- rowFocusOutline: _?.rowFocusOutline
1164
+ typography: {
1165
+ runTimestampClassName: m,
1166
+ runTimestampUnreadClassName: h
1167
+ },
1168
+ colors: v?.colors ?? _,
1169
+ rowMinHeight: v?.rowMinHeight,
1170
+ rowHoverBackground: v?.rowHoverBackground,
1171
+ rowFocusBackground: v?.rowFocusBackground,
1172
+ rowFocusOutline: v?.rowFocusOutline
1049
1173
  }
1050
1174
  });
1051
- return y ? /* @__PURE__ */ H("div", {
1052
- className: v("flex max-h-[var(--st-history-max-height,70vh)] w-full max-w-full flex-col overflow-y-auto rounded-xl shadow-md", ct.historyCard, ct.cardLayout),
1053
- style: { "--st-history-max-height": _?.maxHeight },
1054
- children: [/* @__PURE__ */ H("div", {
1055
- className: v("sticky top-0 z-10 flex flex-col gap-4 rounded-t-xl px-6 pb-2 pt-5", ct.historyCard),
1175
+ return y ? /* @__PURE__ */ J("div", {
1176
+ className: b("flex max-h-(--st-history-max-height,70vh) w-full max-w-full flex-col overflow-y-auto rounded-xl shadow-md", Nt.historyCard, Nt.cardLayout),
1177
+ style: { "--st-history-max-height": v?.maxHeight },
1178
+ children: [/* @__PURE__ */ J("div", {
1179
+ className: b("sticky top-0 z-10 flex flex-col gap-4 rounded-t-xl px-6 pt-5 pb-2", Nt.historyCard),
1056
1180
  children: [
1057
- /* @__PURE__ */ V("h2", {
1058
- className: h,
1181
+ /* @__PURE__ */ q("h2", {
1182
+ className: g,
1059
1183
  children: t.historyTitle
1060
1184
  }),
1061
- ee,
1062
- te
1185
+ w,
1186
+ T,
1187
+ ee
1063
1188
  ]
1064
- }), /* @__PURE__ */ V("div", {
1189
+ }), /* @__PURE__ */ q("div", {
1065
1190
  className: "flex flex-1 flex-col gap-4 px-6 pb-2",
1066
- children: S
1191
+ style: { "--strhl-row-bleed": "12px" },
1192
+ children: te
1067
1193
  })]
1068
- }) : /* @__PURE__ */ H("div", {
1194
+ }) : /* @__PURE__ */ J("div", {
1069
1195
  className: "flex flex-col gap-4",
1070
1196
  children: [
1197
+ w,
1198
+ T,
1071
1199
  ee,
1072
- te,
1073
- S
1200
+ te
1074
1201
  ]
1075
1202
  });
1076
1203
  }, $ = {
@@ -1086,27 +1213,28 @@ var W = {
1086
1213
  actionButton: "_actionButton_hdn5b_75",
1087
1214
  roundActionButton: "_roundActionButton_hdn5b_82",
1088
1215
  stickyTabs: "_stickyTabs_hdn5b_88"
1089
- }, ut = ({ labels: e, onBack: t, onEdit: n, onStartNow: r, isStarting: i = !1, isStartNowDisabled: a = !1, isStartNowBusy: o = !1, onDelete: s, isDeleting: c = !1, isDeleted: l = !1, isCompleted: u = !1, isActive: d, isActiveUpdating: f = !1, isActiveDisabled: p = !1, activeDisabledReason: m, onActiveChange: h, displayName: g, isLoading: y = !1, error: x, onRetry: ee, description: te, modelLabel: S, repeatsLabel: C, activeWindowLabel: w, completedLabel: T, nextRunLabel: E, instructionsMarkdown: re, skillDisplayNames: ie, renderInstructions: oe, runs: se, runsIsLoading: ce = !1, runsIsLoadingMore: le = !1, runsSkeletonCount: de = 6, runsError: fe, onRunsRetry: A, runsLoadMoreError: pe, onRunsRetryLoadMore: j, runsHasMore: M = !1, onRunsLoadMore: _e, onRunClick: ve, styles: N, className: be, backIcon: xe, layout: P, historyStyles: Se }) => {
1090
- 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 = _({
1091
- "--stdv-bg": F?.background,
1092
- "--stdv-header-border": F?.headerBorder,
1093
- "--stdv-details-border": F?.detailsColumnBorder,
1094
- "--stdv-subtitle-text": F?.subtitleText,
1095
- "--stdv-history-bg": F?.historyCardBackground
1096
- }), Ae = b(), [B, Ne] = je($e.Details), U = Oe(), W = o && !i ? e.startNowBusyLabel : void 0, G = [
1216
+ }, Ft = "min-w-0 max-w-[600px]", It = ({ labels: e, onBack: t, onEdit: n, onStartNow: r, isStarting: i = !1, isStartNowDisabled: a = !1, isStartNowBusy: o = !1, onDelete: s, isDeleting: c = !1, isDeleted: l = !1, isCompleted: u = !1, isActive: d, isActiveUpdating: f = !1, isActiveDisabled: p = !1, activeDisabledReason: m, onActiveChange: h, displayName: g, isLoading: _ = !1, error: v, onRetry: x, description: S, modelLabel: w, repeatsLabel: ee, activeWindowLabel: T, completedLabel: te, nextRunLabel: ne, instructionsMarkdown: re, skillDisplayNames: E, renderInstructions: D, runs: ae, runsIsLoading: oe = !1, runsIsLoadingMore: se = !1, runsSkeletonCount: le = 6, runsError: A, onRunsRetry: ue, runsLoadMoreError: fe, onRunsRetryLoadMore: pe, runsHasMore: me = !1, onRunsLoadMore: he, onRunClick: ge, styles: P, className: F, backIcon: I, layout: L, historyStyles: ve }) => {
1217
+ let { colors: R, typography: ye } = P ?? {}, z = ye?.titleClassName ?? "dial-h2-text", be = ye?.sectionTitleClassName ?? "dial-body-semi-text", xe = ye?.fieldLabelClassName ?? "dial-tiny-text", B = ye?.fieldValueClassName ?? "dial-small-text", Se = ye?.runTimestampClassName ?? "dial-small-text", Ee = y({
1218
+ "--stdv-bg": R?.background,
1219
+ "--stdv-header-border": R?.headerBorder,
1220
+ "--stdv-details-border": R?.detailsColumnBorder,
1221
+ "--stdv-subtitle-text": R?.subtitleText,
1222
+ "--stdv-description-text": R?.descriptionText,
1223
+ "--stdv-history-bg": R?.historyCardBackground
1224
+ }), De = C(), [Oe, V] = We(Ct.Details), H = G(), U = o && !i ? e.startNowBusyLabel : void 0, Ae = [
1097
1225
  {
1098
- id: $e.Details,
1226
+ id: Ct.Details,
1099
1227
  label: e.detailsTitle
1100
1228
  },
1101
1229
  {
1102
- id: $e.Configuration,
1230
+ id: Ct.Configuration,
1103
1231
  label: e.configurationTitle
1104
1232
  },
1105
1233
  {
1106
- id: $e.History,
1234
+ id: Ct.History,
1107
1235
  label: e.historyTitle
1108
1236
  }
1109
- ], K = G.find((e) => e.id === B)?.label ?? e.detailsTitle, Pe = /* @__PURE__ */ V(it, {
1237
+ ], je = Ae.find((e) => e.id === Oe)?.label ?? e.detailsTitle, Ne = /* @__PURE__ */ q(kt, {
1110
1238
  labels: {
1111
1239
  descriptionLabel: e.descriptionLabel,
1112
1240
  modelLabel: e.modelLabel,
@@ -1114,19 +1242,19 @@ var W = {
1114
1242
  activeWindowLabel: e.activeWindowLabel,
1115
1243
  completedFieldLabel: e.completedFieldLabel
1116
1244
  },
1117
- description: te,
1118
- modelLabel: S,
1119
- repeatsLabel: C,
1120
- activeWindowLabel: w,
1121
- completedLabel: T,
1122
- fieldLabelClassName: Ee,
1123
- fieldValueClassName: z
1124
- }), q = /* @__PURE__ */ V(nt, {
1245
+ description: S,
1246
+ modelLabel: w,
1247
+ repeatsLabel: ee,
1248
+ activeWindowLabel: T,
1249
+ completedLabel: te,
1250
+ fieldLabelClassName: xe,
1251
+ fieldValueClassName: B
1252
+ }), Pe = /* @__PURE__ */ q(Dt, {
1125
1253
  instructionsLabel: e.instructionsLabel,
1126
1254
  skillLabel: e.skillLabel,
1127
- skillDisplayNames: ie,
1255
+ skillDisplayNames: E,
1128
1256
  instructionsMarkdown: re,
1129
- renderInstructions: oe,
1257
+ renderInstructions: D,
1130
1258
  markdownLabels: {
1131
1259
  codeBlockCopyLabel: e.codeBlockCopyLabel,
1132
1260
  codeBlockCopiedLabel: e.codeBlockCopiedLabel,
@@ -1134,12 +1262,13 @@ var W = {
1134
1262
  tableScrollRegionAriaLabel: e.tableScrollRegionAriaLabel,
1135
1263
  mathScrollRegionAriaLabel: e.mathScrollRegionAriaLabel
1136
1264
  },
1137
- fieldLabelClassName: Ee
1138
- }), J = (t) => /* @__PURE__ */ V(lt, {
1265
+ fieldLabelClassName: xe
1266
+ }), Ie = (t) => /* @__PURE__ */ q(Pt, {
1139
1267
  variant: t,
1140
1268
  labels: {
1141
1269
  historyTitle: e.historyTitle,
1142
1270
  historyEmptyLabel: e.historyEmptyLabel,
1271
+ historyEmptyDescription: e.historyEmptyDescription,
1143
1272
  historyErrorLabel: e.historyErrorLabel,
1144
1273
  historyLoadMoreErrorLabel: e.historyLoadMoreErrorLabel,
1145
1274
  historyRetryLabel: e.historyRetryLabel,
@@ -1148,267 +1277,442 @@ var W = {
1148
1277
  runStatusLabels: e.runStatusLabels,
1149
1278
  unreadIndicatorLabel: e.unreadIndicatorLabel
1150
1279
  },
1151
- nextRunLabel: E,
1152
- items: se,
1153
- isLoading: ce,
1154
- isLoadingMore: le,
1155
- skeletonCount: de,
1156
- error: fe,
1157
- onRetry: A,
1158
- loadMoreError: pe,
1159
- onRetryLoadMore: j,
1160
- hasMore: M,
1161
- onLoadMore: _e,
1162
- onRunClick: ve,
1163
- runTimestampClassName: De,
1164
- sectionTitleClassName: Te,
1165
- colors: F,
1166
- styles: Se
1280
+ nextRunLabel: ne,
1281
+ items: ae,
1282
+ isLoading: oe,
1283
+ isLoadingMore: se,
1284
+ skeletonCount: le,
1285
+ error: A,
1286
+ onRetry: ue,
1287
+ loadMoreError: fe,
1288
+ onRetryLoadMore: pe,
1289
+ hasMore: me,
1290
+ onLoadMore: he,
1291
+ onRunClick: ge,
1292
+ runTimestampClassName: Se,
1293
+ sectionTitleClassName: be,
1294
+ colors: R,
1295
+ styles: ve
1167
1296
  });
1168
- return /* @__PURE__ */ H("div", {
1169
- style: ke,
1170
- className: v("flex h-full min-h-0 w-full flex-col overflow-hidden", $.container, be),
1297
+ return /* @__PURE__ */ J("div", {
1298
+ style: Ee,
1299
+ className: b("flex h-full min-h-0 w-full flex-col overflow-hidden", $.container, F),
1171
1300
  children: [
1172
- /* @__PURE__ */ H("div", {
1173
- className: v("flex min-h-16 shrink-0 items-start justify-between gap-2 px-4 py-2 desktop:h-16 desktop:flex-nowrap desktop:items-center desktop:px-8 desktop:py-0", $.header),
1174
- children: [/* @__PURE__ */ H("div", {
1301
+ /* @__PURE__ */ J("div", {
1302
+ className: b("flex min-h-16 shrink-0 items-start justify-between gap-2 px-4 py-2 desktop:h-16 desktop:flex-nowrap desktop:items-center desktop:px-8 desktop:py-0", $.header),
1303
+ children: [/* @__PURE__ */ J("div", {
1175
1304
  className: "flex min-w-0 items-center gap-2",
1176
1305
  children: [
1177
- /* @__PURE__ */ V(ae, {
1178
- icon: xe === void 0 ? /* @__PURE__ */ V(ye, {
1179
- size: D.LG,
1306
+ /* @__PURE__ */ q(de, {
1307
+ icon: I === void 0 ? /* @__PURE__ */ q(ke, {
1308
+ size: O.LG,
1180
1309
  className: "rtl:scale-x-[-1]",
1181
1310
  "aria-hidden": !0,
1182
- stroke: O
1183
- }) : xe,
1311
+ stroke: k
1312
+ }) : I,
1184
1313
  "aria-label": e.backAriaLabel,
1185
1314
  onClick: t
1186
1315
  }),
1187
- /* @__PURE__ */ V("h1", {
1188
- className: v("truncate", $.desktopTitle, R),
1189
- children: g
1316
+ /* @__PURE__ */ q("h1", {
1317
+ className: b(Ft, $.desktopTitle),
1318
+ children: /* @__PURE__ */ q(ce, {
1319
+ text: g,
1320
+ className: z
1321
+ })
1190
1322
  }),
1191
- l && /* @__PURE__ */ V("span", {
1192
- className: v("shrink-0", $.desktopBadge, z, $.subtitleText),
1323
+ l && /* @__PURE__ */ q("span", {
1324
+ className: b("shrink-0", $.desktopBadge, B, $.subtitleText),
1193
1325
  children: e.deletedStateLabel
1194
1326
  })
1195
1327
  ]
1196
- }), /* @__PURE__ */ H("div", {
1197
- className: v("flex min-w-0 flex-1 flex-wrap items-center justify-end gap-2 desktop:flex-none desktop:flex-nowrap", $.headerActions),
1328
+ }), /* @__PURE__ */ J("div", {
1329
+ className: b("flex min-w-0 flex-1 flex-wrap items-center justify-end gap-2 desktop:flex-none desktop:flex-nowrap", $.headerActions),
1198
1330
  children: [
1199
- !l && !u && d !== void 0 && /* @__PURE__ */ H(Me, { children: [/* @__PURE__ */ V(he, {
1331
+ !l && !u && d !== void 0 && /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q(we, {
1200
1332
  id: "scheduled-task-active-switch",
1201
1333
  labelProps: { label: e.activeStatusLabel },
1202
1334
  isOn: d,
1203
1335
  disabled: f || p || c,
1204
1336
  onChange: (e) => h?.(e)
1205
- }), p && m && /* @__PURE__ */ V("span", {
1206
- className: v(z, $.subtitleText),
1337
+ }), p && m && /* @__PURE__ */ q("span", {
1338
+ className: b(B, $.subtitleText),
1207
1339
  children: m
1208
1340
  })] }),
1209
- !l && s && /* @__PURE__ */ V(k, {
1210
- variant: ne.Danger,
1341
+ !l && s && /* @__PURE__ */ q(j, {
1342
+ variant: ie.Danger,
1211
1343
  label: e.deleteButtonLabel,
1212
- iconBefore: /* @__PURE__ */ V(we, {
1213
- size: D.SM,
1344
+ iconBefore: /* @__PURE__ */ q(Fe, {
1345
+ size: O.SM,
1214
1346
  "aria-hidden": !0,
1215
- stroke: O
1347
+ stroke: k
1216
1348
  }),
1217
1349
  onClick: s,
1218
1350
  disabled: c,
1219
1351
  textClassName: $.actionLabel,
1220
- className: v("min-h-11 shrink-0", $.actionButton)
1352
+ className: b("min-h-11 shrink-0", $.actionButton)
1221
1353
  }),
1222
- !l && n && /* @__PURE__ */ V(ue, {
1354
+ !l && n && /* @__PURE__ */ q(_e, {
1223
1355
  label: e.editButtonLabel,
1224
- iconBefore: /* @__PURE__ */ V(Ce, {
1225
- size: D.SM,
1356
+ iconBefore: /* @__PURE__ */ q(Me, {
1357
+ size: O.SM,
1226
1358
  "aria-hidden": !0,
1227
- stroke: O
1359
+ stroke: k
1228
1360
  }),
1229
1361
  onClick: n,
1230
1362
  disabled: c,
1231
1363
  textClassName: $.actionLabel,
1232
- className: v("min-h-11 shrink-0", $.actionButton, $.roundActionButton)
1364
+ className: b("min-h-11 shrink-0", $.actionButton, $.roundActionButton)
1233
1365
  }),
1234
- !l && r && e.startNowButtonLabel && /* @__PURE__ */ H("div", {
1366
+ !l && r && e.startNowButtonLabel && /* @__PURE__ */ J("div", {
1235
1367
  "aria-busy": i,
1236
- children: [W && /* @__PURE__ */ V("span", {
1237
- id: U,
1368
+ children: [U && /* @__PURE__ */ q("span", {
1369
+ id: H,
1238
1370
  className: "sr-only",
1239
- children: W
1240
- }), /* @__PURE__ */ V(ue, {
1371
+ children: U
1372
+ }), /* @__PURE__ */ q(_e, {
1241
1373
  label: i ? e.startingLabel ?? e.startNowButtonLabel : e.startNowButtonLabel,
1242
- iconBefore: /* @__PURE__ */ V(L, {
1243
- size: D.SM,
1374
+ iconBefore: /* @__PURE__ */ q(W, {
1375
+ size: O.SM,
1244
1376
  "aria-hidden": !0,
1245
- stroke: O
1377
+ stroke: k
1246
1378
  }),
1247
1379
  onClick: r,
1248
1380
  disabled: c || i || a || o,
1249
- "aria-describedby": W ? U : void 0,
1250
- tooltipProps: W ? { tooltip: W } : void 0,
1381
+ "aria-describedby": U ? H : void 0,
1382
+ tooltipProps: U ? { tooltip: U } : void 0,
1251
1383
  textClassName: $.actionLabel,
1252
- className: v("min-h-11 shrink-0", $.actionButton, $.roundActionButton)
1384
+ className: b("min-h-11 shrink-0", $.actionButton, $.roundActionButton)
1253
1385
  })]
1254
1386
  })
1255
1387
  ]
1256
1388
  })]
1257
1389
  }),
1258
- /* @__PURE__ */ H("div", {
1259
- className: v("min-w-0 items-center gap-2 px-4 py-3", $.mobileTitleRow),
1260
- children: [/* @__PURE__ */ V("h1", {
1261
- className: v("truncate", R),
1262
- children: g
1263
- }), l && /* @__PURE__ */ V("span", {
1264
- className: v("shrink-0", z, $.subtitleText),
1390
+ /* @__PURE__ */ J("div", {
1391
+ className: b("min-w-0 items-center gap-2 px-4 py-3", $.mobileTitleRow),
1392
+ children: [/* @__PURE__ */ q("h1", {
1393
+ className: Ft,
1394
+ children: /* @__PURE__ */ q(ce, {
1395
+ text: g,
1396
+ className: z
1397
+ })
1398
+ }), l && /* @__PURE__ */ q("span", {
1399
+ className: b("shrink-0", B, $.subtitleText),
1265
1400
  children: e.deletedStateLabel
1266
1401
  })]
1267
1402
  }),
1268
- e.activeStatusAnnouncement != null && /* @__PURE__ */ V("span", {
1269
- role: "status",
1270
- "aria-live": "polite",
1271
- className: "sr-only",
1403
+ e.activeStatusAnnouncement != null && /* @__PURE__ */ q(M, {
1404
+ visuallyHidden: !0,
1405
+ as: N.Span,
1272
1406
  children: e.activeStatusAnnouncement
1273
1407
  }),
1274
- e.startStatusAnnouncement != null && /* @__PURE__ */ V("span", {
1275
- role: "status",
1276
- "aria-live": "polite",
1277
- className: "sr-only",
1408
+ e.startStatusAnnouncement != null && /* @__PURE__ */ q(M, {
1409
+ visuallyHidden: !0,
1410
+ as: N.Span,
1278
1411
  children: e.startStatusAnnouncement
1279
1412
  }),
1280
- y && /* @__PURE__ */ V("div", {
1413
+ _ && /* @__PURE__ */ q("div", {
1281
1414
  className: "flex flex-1 items-center justify-center",
1282
- children: /* @__PURE__ */ V(me, {})
1415
+ children: /* @__PURE__ */ q(Ce, {})
1283
1416
  }),
1284
- !y && x && /* @__PURE__ */ H("div", {
1417
+ !_ && v && /* @__PURE__ */ J("div", {
1285
1418
  className: "flex flex-1 flex-col items-center justify-center gap-3",
1286
- children: [/* @__PURE__ */ V("p", {
1287
- className: v(z, $.subtitleText),
1419
+ children: [/* @__PURE__ */ q("p", {
1420
+ className: b(B, $.subtitleText),
1288
1421
  children: e.errorLabel
1289
- }), /* @__PURE__ */ V(k, {
1422
+ }), /* @__PURE__ */ q(j, {
1290
1423
  label: e.retryLabel,
1291
- onClick: ee
1424
+ onClick: x
1292
1425
  })]
1293
1426
  }),
1294
- !y && !x && (Ae ? /* @__PURE__ */ H("div", {
1427
+ !_ && !v && (De ? /* @__PURE__ */ J("div", {
1295
1428
  className: "flex min-h-0 flex-1 flex-col overflow-y-auto",
1296
- children: [/* @__PURE__ */ V("div", {
1297
- className: v("sticky top-0 z-10", $.stickyTabs),
1298
- children: /* @__PURE__ */ V(ge, {
1429
+ children: [/* @__PURE__ */ q("div", {
1430
+ className: b("sticky top-0 z-10", $.stickyTabs),
1431
+ children: /* @__PURE__ */ q(Te, {
1299
1432
  ariaLabel: e.tabsAriaLabel ?? "Scheduled task sections",
1300
1433
  className: "px-4",
1301
- tabs: G,
1302
- activeTabId: B,
1303
- onTabChange: Ne
1434
+ tabs: Ae,
1435
+ activeTabId: Oe,
1436
+ onTabChange: V
1304
1437
  })
1305
- }), /* @__PURE__ */ V("div", {
1438
+ }), /* @__PURE__ */ q("div", {
1306
1439
  role: "tabpanel",
1307
- "aria-label": K,
1440
+ "aria-label": je,
1308
1441
  className: "flex flex-1 flex-col gap-5 px-4 py-6",
1309
- children: B === $e.Configuration ? q : B === $e.History ? J(et.Flow) : Pe
1442
+ children: Oe === Ct.Configuration ? Pe : Oe === Ct.History ? Ie(wt.Flow) : Ne
1310
1443
  })]
1311
- }) : /* @__PURE__ */ H("div", {
1444
+ }) : /* @__PURE__ */ J("div", {
1312
1445
  style: {
1313
1446
  flexDirection: "row",
1314
- "--st-details-width": P?.detailsWidth,
1315
- "--st-history-width": P?.historyWidth,
1316
- "--st-history-max-height": P?.historyMaxHeight,
1317
- "--st-configuration-min-width": P?.configurationMinWidth
1447
+ "--st-details-width": L?.detailsWidth,
1448
+ "--st-history-width": L?.historyWidth,
1449
+ "--st-history-max-height": L?.historyMaxHeight,
1450
+ "--st-configuration-min-width": L?.configurationMinWidth
1318
1451
  },
1319
1452
  className: "flex min-h-0 flex-1 overflow-y-auto desktop:overflow-hidden",
1320
1453
  children: [
1321
- /* @__PURE__ */ H("div", {
1454
+ /* @__PURE__ */ J("div", {
1322
1455
  role: "group",
1323
1456
  "aria-label": e.detailsTitle,
1324
1457
  style: {
1325
- flex: `0 1 ${P?.detailsWidth ?? "360px"}`,
1458
+ flex: `0 1 ${L?.detailsWidth ?? "360px"}`,
1326
1459
  maxWidth: "100%"
1327
1460
  },
1328
- className: v("flex min-h-0 w-full flex-col gap-5 overflow-y-auto border-e px-8 py-6", $.detailsColumn),
1329
- children: [/* @__PURE__ */ V("h2", {
1330
- className: Te,
1461
+ className: b("flex min-h-0 w-full min-w-0 flex-col gap-5 overflow-y-auto border-e px-8 py-6", $.detailsColumn),
1462
+ children: [/* @__PURE__ */ q("h2", {
1463
+ className: be,
1331
1464
  children: e.detailsTitle
1332
- }), Pe]
1465
+ }), Ne]
1333
1466
  }),
1334
- /* @__PURE__ */ H("div", {
1467
+ /* @__PURE__ */ J("div", {
1335
1468
  style: {
1336
- flex: `1 1 ${P?.configurationMinWidth ?? "320px"}`,
1469
+ flex: `1 1 ${L?.configurationMinWidth ?? "320px"}`,
1337
1470
  minWidth: 0
1338
1471
  },
1339
1472
  className: "flex min-h-0 w-full min-w-0 flex-col gap-5 overflow-y-auto px-8 py-6",
1340
- children: [/* @__PURE__ */ V("h2", {
1341
- className: Te,
1473
+ children: [/* @__PURE__ */ q("h2", {
1474
+ className: be,
1342
1475
  children: e.configurationTitle
1343
- }), q]
1476
+ }), Pe]
1344
1477
  }),
1345
- /* @__PURE__ */ V("div", {
1478
+ /* @__PURE__ */ q("div", {
1346
1479
  style: {
1347
- flex: `0 1 calc(${P?.historyWidth ?? "360px"} + 48px)`,
1480
+ flex: `0 1 calc(${L?.historyWidth ?? "360px"} + 48px)`,
1348
1481
  minWidth: 0
1349
1482
  },
1350
1483
  className: "flex min-h-0 w-full items-start justify-center overflow-y-auto p-6",
1351
- children: J(et.Card)
1484
+ children: Ie(wt.Card)
1352
1485
  })
1353
1486
  ]
1354
1487
  }))
1355
1488
  ]
1356
1489
  });
1357
- }, dt = ({ modelLabel: e, skillLabel: t, skillDisplayNames: n, instructionsLabel: r, modelDisplayName: i, instructionsMarkdown: a, renderInstructions: o, markdownLabels: s, styles: c }) => {
1358
- let l = c?.typography?.fieldLabelClassName ?? "dial-tiny-text", u = c?.typography?.fieldValueClassName ?? "dial-body-text";
1359
- return /* @__PURE__ */ H("div", {
1490
+ }, Lt = { fieldLabel: "_fieldLabel_8nxg8_1" }, Rt = {
1491
+ h1: "mb-3 mt-6 first:mt-0 [text-wrap:balance]",
1492
+ h2: "mb-2 mt-5 first:mt-0 [text-wrap:balance]",
1493
+ h3: "mb-2 mt-4 first:mt-0 [text-wrap:balance]",
1494
+ h4: "mb-2 mt-4 first:mt-0 [text-wrap:balance]",
1495
+ h5: "mb-2 mt-4 first:mt-0 [text-wrap:balance]",
1496
+ h6: "mb-2 mt-4 first:mt-0 [text-wrap:balance]",
1497
+ p: "mb-3 break-words [overflow-wrap:anywhere] [text-wrap:pretty] last:mb-0",
1498
+ ul: "mb-3 space-y-1",
1499
+ ol: "mb-3 space-y-1",
1500
+ codeInline: "mx-0.5 px-1.5 break-words [overflow-wrap:anywhere]",
1501
+ blockquote: "my-4",
1502
+ link: "break-words [overflow-wrap:anywhere]",
1503
+ tableWrapper: "my-4",
1504
+ mathBlock: "my-4"
1505
+ }, zt = ({ modelLabel: e, skillLabel: t, skillDisplayNames: n, instructionsLabel: r, modelDisplayName: i, instructionsMarkdown: a, renderInstructions: o, instructionsClassNames: s, markdownLabels: c, styles: l }) => {
1506
+ let u = b(l?.typography?.fieldLabelClassName ?? "dial-tiny-text", Lt.fieldLabel), d = l?.typography?.fieldValueClassName ?? "dial-small-text", f = l?.typography?.instructionsHeadingClassName ?? "dial-small-semi-text", p = l?.typography?.instructionsTextClassName ?? "dial-small-text", m = He(() => {
1507
+ let e = Rt;
1508
+ return {
1509
+ ...e,
1510
+ h1: b(f, e.h1),
1511
+ h2: b(f, e.h2),
1512
+ h3: b(f, e.h3),
1513
+ h4: b(f, e.h4),
1514
+ h5: b(f, e.h5),
1515
+ h6: b(f, e.h6),
1516
+ p: b(p, e.p),
1517
+ ul: b(p, e.ul),
1518
+ ol: b(p, e.ol),
1519
+ ...s
1520
+ };
1521
+ }, [
1522
+ f,
1523
+ p,
1524
+ s
1525
+ ]), g = y({ "--stds-field-label": l?.colors?.fieldLabel });
1526
+ return /* @__PURE__ */ J("div", {
1360
1527
  className: "flex flex-col gap-3",
1528
+ style: g,
1361
1529
  children: [
1362
- i && /* @__PURE__ */ H("div", {
1530
+ i && /* @__PURE__ */ J("div", {
1363
1531
  className: "flex flex-col gap-2",
1364
- children: [/* @__PURE__ */ V("span", {
1365
- className: l,
1366
- children: e
1367
- }), /* @__PURE__ */ V("p", {
1532
+ children: [/* @__PURE__ */ q("span", {
1368
1533
  className: u,
1534
+ children: e
1535
+ }), /* @__PURE__ */ q("p", {
1536
+ className: d,
1369
1537
  children: i
1370
1538
  })]
1371
1539
  }),
1372
- !!n?.length && /* @__PURE__ */ H("div", {
1540
+ !!n?.length && /* @__PURE__ */ J("div", {
1373
1541
  className: "flex min-w-0 flex-col gap-2",
1374
- children: [/* @__PURE__ */ V("span", {
1375
- className: l,
1542
+ children: [/* @__PURE__ */ q("span", {
1543
+ className: u,
1376
1544
  children: t
1377
- }), /* @__PURE__ */ V("p", {
1378
- className: `${u} whitespace-normal break-all`,
1379
- children: n?.map((e, t) => /* @__PURE__ */ V("span", {
1545
+ }), /* @__PURE__ */ q("p", {
1546
+ className: b(d, "wrap-anywhere whitespace-normal"),
1547
+ children: n?.map((e, t) => /* @__PURE__ */ q("span", {
1380
1548
  className: "block",
1381
1549
  children: e
1382
1550
  }, `${t}:${e}`))
1383
1551
  })]
1384
1552
  }),
1385
- a && /* @__PURE__ */ H("div", {
1553
+ a && /* @__PURE__ */ J("div", {
1386
1554
  className: "flex flex-col gap-2",
1387
- children: [/* @__PURE__ */ V("span", {
1388
- className: l,
1555
+ children: [/* @__PURE__ */ q("span", {
1556
+ className: u,
1389
1557
  children: r
1390
- }), ((e) => o ? o(e) : /* @__PURE__ */ V(p, {
1558
+ }), ((e) => o ? o(e) : /* @__PURE__ */ q(h, {
1391
1559
  content: e,
1392
- ...s
1560
+ classNames: m,
1561
+ ...c
1393
1562
  }))(a)]
1394
1563
  })
1395
1564
  ]
1396
1565
  });
1397
- }, ft = ({ taskName: e, icon: t, typeLabel: n, body: r, pendingLabel: i, isDeleting: a = !1, styles: o, ...s }) => /* @__PURE__ */ V(l, {
1566
+ }, Bt = ({ className: e, children: t }) => /* @__PURE__ */ q("span", {
1567
+ className: b(e, "block truncate py-1"),
1568
+ children: t
1569
+ }), Vt = { unavailableText: "_unavailableText_1ifqz_1" }, Ht = ({ scheduleId: e, items: t, isLoading: n = !1, isLoadingMore: r = !1, skeletonCount: i = 6, error: a, onRetry: o, isUnavailable: s = !1, hasMore: c = !1, onLoadMore: l, currentRunId: u, onRunClick: d, labels: f, titleClassName: p = "dial-tiny-semi-text", contentClassName: m = "ps-3", unavailableTextClassName: h = "dial-body-text", colors: g }) => {
1570
+ let [_, v] = We(!0);
1571
+ Be(() => {
1572
+ v(!0);
1573
+ }, [e]);
1574
+ let x = c && !n && l && f.showMoreLabel ? /* @__PURE__ */ q("li", {
1575
+ className: "pt-2",
1576
+ children: /* @__PURE__ */ q(j, {
1577
+ variant: ie.Primary,
1578
+ label: f.showMoreLabel,
1579
+ onClick: l,
1580
+ disabled: r
1581
+ })
1582
+ }) : void 0;
1583
+ return /* @__PURE__ */ J(T, {
1584
+ title: /* @__PURE__ */ q(Bt, {
1585
+ className: p,
1586
+ children: f.title
1587
+ }),
1588
+ expanded: _,
1589
+ onToggle: v,
1590
+ contentClassName: m,
1591
+ children: [/* @__PURE__ */ q(M, {
1592
+ as: N.P,
1593
+ className: b(h, Vt.unavailableText),
1594
+ style: y({ "--stch-unavailable-text": g?.unavailableText }),
1595
+ children: s && f.unavailableLabel
1596
+ }), !s && /* @__PURE__ */ q(Mt, {
1597
+ items: t,
1598
+ isLoading: n,
1599
+ isLoadingMore: r,
1600
+ skeletonCount: i,
1601
+ error: a,
1602
+ onRetry: o,
1603
+ currentRunId: u,
1604
+ onRunClick: d,
1605
+ footer: x,
1606
+ labels: {
1607
+ historyTitle: f.title,
1608
+ emptyLabel: f.emptyLabel,
1609
+ errorLabel: f.errorLabel,
1610
+ retryLabel: f.retryLabel,
1611
+ runStatusLabels: f.runStatusLabels,
1612
+ currentRunLabel: f.currentRunLabel,
1613
+ unreadIndicatorLabel: f.unreadIndicatorLabel
1614
+ }
1615
+ })]
1616
+ });
1617
+ }, Ut = { unavailableText: "_unavailableText_j7lij_1" }, Wt = /* @__PURE__ */ function(e) {
1618
+ return e.Ready = "ready", e.Error = "error", e.Unavailable = "unavailable", e;
1619
+ }({}), Gt = ({ scheduleId: e, state: t, onRetry: n, modelDisplayName: r, skillDisplayNames: i, instructionsMarkdown: a, renderInstructions: o, instructionsClassNames: s, markdownLabels: c, summaryStyles: l, labels: u, titleClassName: d = "dial-tiny-semi-text", unavailableTextClassName: f = "dial-body-text", colors: p }) => {
1620
+ let [m, h] = We(!1);
1621
+ Be(() => {
1622
+ h(!1);
1623
+ }, [e]);
1624
+ let g = t === "error" || t === "unavailable", _ = t === "error" && n != null, v = /* @__PURE__ */ J(K, { children: [
1625
+ /* @__PURE__ */ q(M, {
1626
+ as: N.P,
1627
+ className: b(f, Ut.unavailableText),
1628
+ style: y({ "--stcd-unavailable-text": p?.unavailableText }),
1629
+ children: g && u.unavailableLabel
1630
+ }),
1631
+ _ && /* @__PURE__ */ q("div", {
1632
+ className: "mt-2",
1633
+ children: /* @__PURE__ */ q(j, {
1634
+ label: u.retryLabel,
1635
+ onClick: n
1636
+ })
1637
+ }),
1638
+ !g && /* @__PURE__ */ q(zt, {
1639
+ modelLabel: u.modelLabel,
1640
+ instructionsLabel: u.instructionsLabel,
1641
+ skillLabel: u.skillLabel,
1642
+ skillDisplayNames: i,
1643
+ modelDisplayName: r,
1644
+ instructionsMarkdown: a,
1645
+ renderInstructions: o,
1646
+ instructionsClassNames: s,
1647
+ markdownLabels: c,
1648
+ styles: l
1649
+ })
1650
+ ] });
1651
+ return /* @__PURE__ */ q(T, {
1652
+ title: /* @__PURE__ */ q(Bt, {
1653
+ className: d,
1654
+ children: u.title
1655
+ }),
1656
+ expanded: m,
1657
+ onToggle: h,
1658
+ children: v
1659
+ });
1660
+ }, Kt = (e, t, n) => e ? n?.loggingIn ?? "Logging in…" : t == null ? n?.logIn ?? "Log in" : n?.retry ?? "Retry", qt = Re(({ isVisible: e, isLoggingIn: t = !1, retryMessage: n, liveAnnouncement: r = "", labels: i, onLogIn: a }) => /* @__PURE__ */ J(K, { children: [e && /* @__PURE__ */ q(Oe, {
1661
+ surface: L.Neutral,
1662
+ title: i?.title ?? "Log in required.",
1663
+ message: i?.body ?? "Scheduled tasks need authorization to run offline.",
1664
+ action: a && /* @__PURE__ */ q(he, {
1665
+ label: Kt(t, n, i),
1666
+ disabled: t,
1667
+ iconAfter: /* @__PURE__ */ q(H, {
1668
+ size: O.SM,
1669
+ stroke: k,
1670
+ "aria-hidden": !0,
1671
+ className: "rtl:scale-x-[-1]"
1672
+ }),
1673
+ onClick: a,
1674
+ className: "min-h-11 min-w-11"
1675
+ })
1676
+ }), /* @__PURE__ */ q(M, {
1677
+ visuallyHidden: !0,
1678
+ as: N.Span,
1679
+ children: n ?? r
1680
+ })] })), Jt = Re(({ labels: e, titleClassName: t = "dial-small-paragraph-semi-text", bodyClassName: n = "dial-small-paragraph-text" }) => /* @__PURE__ */ q(I, {
1681
+ variant: R.Error,
1682
+ type: ve.SectionMessage,
1683
+ message: /* @__PURE__ */ J("span", {
1684
+ className: "flex min-w-0 flex-wrap items-baseline gap-x-1",
1685
+ children: [/* @__PURE__ */ q("span", {
1686
+ className: b("min-w-0 wrap-break-word", t),
1687
+ children: e?.title ?? "Limited access."
1688
+ }), /* @__PURE__ */ q("span", {
1689
+ className: b("min-w-0 wrap-break-word", n),
1690
+ children: e?.body ?? "You can't create or edit tasks. Contact your administrator for more details."
1691
+ })]
1692
+ })
1693
+ })), Yt = ({ taskName: e, icon: t, typeLabel: n, body: r, pendingLabel: i, isDeleting: a = !1, styles: o, ...s }) => /* @__PURE__ */ q(d, {
1398
1694
  ...s,
1399
- variant: E.Danger,
1695
+ variant: oe.Danger,
1400
1696
  popupClassName: o?.popupClassName,
1401
- titleClassName: o?.titleClassName,
1697
+ titleClassName: o?.titleClassName ?? "dial-body-semi-text",
1402
1698
  messageClassName: o?.messageClassName ?? "dial-body-paragraph-text",
1699
+ viewClassName: "pt-0",
1700
+ footerStyles: { colors: { border: "transparent" } },
1403
1701
  message: r,
1404
1702
  isLoading: a,
1405
1703
  loadingStatusLabel: i,
1406
- identity: /* @__PURE__ */ V(h, { children: /* @__PURE__ */ V(u, {
1407
- icon: t,
1408
- typeLabel: n,
1409
- name: e,
1410
- styles: { colors: o?.colors }
1411
- }) })
1704
+ identity: /* @__PURE__ */ q(_, {
1705
+ styles: { colors: {
1706
+ background: o?.colors?.summaryBackground ?? "var(--bg-error, #f3d6d8)",
1707
+ border: o?.colors?.summaryBorder ?? "var(--stroke-error-alpha, #ae2f2f73)"
1708
+ } },
1709
+ children: /* @__PURE__ */ q(f, {
1710
+ icon: t,
1711
+ typeLabel: n,
1712
+ name: e,
1713
+ styles: { colors: o?.colors }
1714
+ })
1715
+ })
1412
1716
  });
1413
1717
  //#endregion
1414
- 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 };
1718
+ export { t as DESCRIPTION_MAX_LENGTH, Je as SCHEDULED_TASKS_CLASS, qe as SCHEDULED_TASKS_GRID_DEFAULT_MAX_WIDTH, r as SCHEDULED_TASK_CREATE_DEFAULT_VALUES, et as ScheduledTaskCard, at as ScheduledTaskCardGrid, it as ScheduledTaskCardSkeleton, Gt as ScheduledTaskConversationDetailsSection, Wt as ScheduledTaskConversationDetailsState, Ht as ScheduledTaskConversationHistorySection, St as ScheduledTaskCreateForm, Yt as ScheduledTaskDeleteConfirmation, It as ScheduledTaskDetailView, zt as ScheduledTaskDetailsSummary, Pt as ScheduledTaskHistorySection, Ye as ScheduledTaskPresentationStatus, l as ScheduledTaskRepeat, Mt as ScheduledTaskRunHistoryList, At as ScheduledTaskRunStatus, Y as ScheduledTaskStatus, lt as ScheduledTasks, Jt as ScheduledTasksLimitedAccessBanner, qt as ScheduledTasksLoginBanner, ut as ScheduledTasksSortKey, c as TIME_OF_DAY_PATTERN, i as calendarValueToDateValue, n as calendarValueToRunAt, e as dateValueToCalendarValue, Xe as getScheduledTaskStatus, pt as hasScheduledTaskFormChanges, s as runAtToCalendarValue };