@epam/ai-dial-scheduled-tasks 1.3.0-dev.326 → 1.3.0-dev.331
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{calendar-value-Ds0AiQSR.js → calendar-value-WOdrwh6p.js} +0 -1
- package/components/ScheduledTaskCreateForm/ScheduledTaskCreateForm.d.ts.map +1 -1
- package/constants/scheduled-task-create-form.d.ts.map +1 -1
- package/index.css +1 -1
- package/index.d.ts +1 -1
- package/index.d.ts.map +1 -1
- package/index.js +563 -577
- package/models/scheduled-task-create-form-props.d.ts +11 -16
- package/models/scheduled-task-create-form-props.d.ts.map +1 -1
- package/package.json +3 -3
- package/types/scheduled-task-schedule.d.ts +1 -1
- package/types/scheduled-task-schedule.d.ts.map +1 -1
- package/validation/scheduled-task-validation.d.ts +2 -0
- package/validation/scheduled-task-validation.d.ts.map +1 -1
- package/validation.js +13 -13
- package/utils/window-boundary.d.ts +0 -4
- package/utils/window-boundary.d.ts.map +0 -1
|
@@ -9,13 +9,6 @@ export interface ScheduledTaskRepeatOption {
|
|
|
9
9
|
/** Localized display label for this repeat option. */
|
|
10
10
|
label: string;
|
|
11
11
|
}
|
|
12
|
-
/** One option in the Custom repeat's "Every" week-count dropdown. */
|
|
13
|
-
export interface ScheduledTaskEveryWeekOption {
|
|
14
|
-
/** Option value: the week-count string `'1'`–`'10'`. */
|
|
15
|
-
value: string;
|
|
16
|
-
/** Localized display label, e.g. "1 week" / "2 weeks". */
|
|
17
|
-
label: string;
|
|
18
|
-
}
|
|
19
12
|
/** One weekday segment in the Custom repeat's day-of-week control. */
|
|
20
13
|
export interface ScheduledTaskCustomDayOption {
|
|
21
14
|
/** Segment value: the APScheduler-convention day string `'0'` (Monday) – `'6'` (Sunday). */
|
|
@@ -33,7 +26,7 @@ export interface ScheduledTaskCreateFormValues {
|
|
|
33
26
|
repeat: ScheduledTaskRepeat;
|
|
34
27
|
/** Local datetime-local input value used when `repeat` is `'oneTime'`. */
|
|
35
28
|
runAt?: string;
|
|
36
|
-
/** `HH:mm` time-of-day used when `repeat` is `'daily'`, `'weekly'`, or `'
|
|
29
|
+
/** `HH:mm` time-of-day used when `repeat` is `'daily'`, `'weekly'`, `'monthly'`, or `'custom'`. */
|
|
37
30
|
time: string;
|
|
38
31
|
/** Day of week (`'0'`-`'6'`) used when `repeat` is `'weekly'`. */
|
|
39
32
|
dayOfWeek?: string;
|
|
@@ -41,8 +34,8 @@ export interface ScheduledTaskCreateFormValues {
|
|
|
41
34
|
dayOfMonth?: string;
|
|
42
35
|
/** Minute of the hour (`'0'`-`'59'`) used when `repeat` is `'hourly'`. */
|
|
43
36
|
minute?: string;
|
|
44
|
-
/**
|
|
45
|
-
|
|
37
|
+
/** Days of week (`'0'` Monday – `'6'` Sunday, sorted Monday first) used when `repeat` is `'custom'`. */
|
|
38
|
+
daysOfWeek?: string[];
|
|
46
39
|
/** Window-start boundary: a whole local day as `YYYY-MM-DD`. Ignored when `repeat` is `'oneTime'`. */
|
|
47
40
|
startDate?: string;
|
|
48
41
|
/** Window-end boundary: a whole local day as `YYYY-MM-DD`. Ignored when `repeat` is `'oneTime'`. */
|
|
@@ -66,6 +59,8 @@ export interface ScheduledTaskCreateFormErrors {
|
|
|
66
59
|
time?: string;
|
|
67
60
|
/** Error shown under the day-of-week field. */
|
|
68
61
|
dayOfWeek?: string;
|
|
62
|
+
/** Error shown under the Custom days-of-week button row. */
|
|
63
|
+
daysOfWeek?: string;
|
|
69
64
|
/** Error shown under the day-of-month field. */
|
|
70
65
|
dayOfMonth?: string;
|
|
71
66
|
/** Error shown under the minute field. */
|
|
@@ -103,7 +98,7 @@ export interface ScheduledTaskCreateFormLabels extends TextRefinementLabels {
|
|
|
103
98
|
runAtLabel: string;
|
|
104
99
|
/** Placeholder shown in the run-at picker when unset. */
|
|
105
100
|
runAtPlaceholder: string;
|
|
106
|
-
/** Time-of-day field label (shown when `repeat` is "daily", "weekly", or "
|
|
101
|
+
/** Time-of-day field label (shown when `repeat` is "daily", "weekly", "monthly", or "custom"). */
|
|
107
102
|
timeLabel: string;
|
|
108
103
|
/** Validation message shown under the time field when its visible draft is not a complete `HH:mm` value. */
|
|
109
104
|
timeInvalidLabel: string;
|
|
@@ -117,11 +112,9 @@ export interface ScheduledTaskCreateFormLabels extends TextRefinementLabels {
|
|
|
117
112
|
dayOfMonthLabel: string;
|
|
118
113
|
/** Minute field label (shown when `repeat` is "hourly"). */
|
|
119
114
|
minuteLabel: string;
|
|
120
|
-
/**
|
|
121
|
-
|
|
122
|
-
/**
|
|
123
|
-
everyWeekOptions: ScheduledTaskEveryWeekOption[];
|
|
124
|
-
/** Weekday segments for the Custom repeat's day-of-week control, Monday-first. */
|
|
115
|
+
/** Label of the Custom repeat's days-of-week button row, e.g. "Days". */
|
|
116
|
+
daysOfWeekLabel: string;
|
|
117
|
+
/** Weekday buttons of the Custom repeat's days-of-week row, Monday-first. */
|
|
125
118
|
customDayOptions: ScheduledTaskCustomDayOption[];
|
|
126
119
|
/** Start-date field label (shown when `repeat` is not "oneTime"; the field itself is optional, so this label carries no required marker). */
|
|
127
120
|
startDateLabel: string;
|
|
@@ -151,6 +144,8 @@ export interface ScheduledTaskCreateFormLabels extends TextRefinementLabels {
|
|
|
151
144
|
discardTitle?: string;
|
|
152
145
|
/** Body of the discard confirmation. Defaults to `'You have unsaved changes. Leaving now will discard them.'`. */
|
|
153
146
|
discardMessage?: string;
|
|
147
|
+
/** Label of the discard confirmation's confirming action below the desktop breakpoint. Defaults to `'Discard'`. */
|
|
148
|
+
discardConfirmMobileLabel?: string;
|
|
154
149
|
/** Label of the discard confirmation's confirming action. Defaults to `'Discard changes'`. */
|
|
155
150
|
discardConfirmLabel?: string;
|
|
156
151
|
/** Label of the discard confirmation's cancel action. Defaults to `'Keep editing'`. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scheduled-task-create-form-props.d.ts","sourceRoot":"","sources":["../../src/models/scheduled-task-create-form-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACtE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAE5E,uDAAuD;AACvD,MAAM,WAAW,yBAAyB;IACxC,yFAAyF;IACzF,GAAG,EAAE,mBAAmB,CAAC;IACzB,sDAAsD;IACtD,KAAK,EAAE,MAAM,CAAC;CACf;AAED,
|
|
1
|
+
{"version":3,"file":"scheduled-task-create-form-props.d.ts","sourceRoot":"","sources":["../../src/models/scheduled-task-create-form-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACtE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAE5E,uDAAuD;AACvD,MAAM,WAAW,yBAAyB;IACxC,yFAAyF;IACzF,GAAG,EAAE,mBAAmB,CAAC;IACzB,sDAAsD;IACtD,KAAK,EAAE,MAAM,CAAC;CACf;AAED,sEAAsE;AACtE,MAAM,WAAW,4BAA4B;IAC3C,4FAA4F;IAC5F,KAAK,EAAE,MAAM,CAAC;IACd,gDAAgD;IAChD,UAAU,EAAE,MAAM,CAAC;IACnB,0EAA0E;IAC1E,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,mFAAmF;AACnF,MAAM,WAAW,6BAA6B;IAC5C,oDAAoD;IACpD,WAAW,EAAE,MAAM,CAAC;IACpB,kCAAkC;IAClC,MAAM,EAAE,mBAAmB,CAAC;IAC5B,0EAA0E;IAC1E,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,mGAAmG;I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IACxD,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,sDAAsD;IACtD,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,iGAAiG;IACjG,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,kEAAkE;IAClE,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,4HAA4H;IAC5H,mBAAmB,CAAC,EAAE,YAAY,CAAC;IACnC,sDAAsD;IACtD,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,8CAA8C;IAC9C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,uBAAuB;IACvB,MAAM,CAAC,EAAE,6BAA6B,CAAC;CACxC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epam/ai-dial-scheduled-tasks",
|
|
3
3
|
"description": "Presentational Scheduled Tasks page shell — header, toolbar, and empty state",
|
|
4
|
-
"version": "1.3.0-dev.
|
|
4
|
+
"version": "1.3.0-dev.331",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./index.js",
|
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
"@tabler/icons-react": "^3.50.0",
|
|
26
26
|
"@uiw/react-markdown-preview": "^5.2.1",
|
|
27
27
|
"@uiw/react-md-editor": "^4.2.2",
|
|
28
|
-
"@epam/ai-dial-builder-form": "1.3.0-dev.
|
|
28
|
+
"@epam/ai-dial-builder-form": "1.3.0-dev.331"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {
|
|
31
|
-
"@epam/ai-dial-chat-shared": "1.3.0-dev.
|
|
31
|
+
"@epam/ai-dial-chat-shared": "1.3.0-dev.331",
|
|
32
32
|
"@epam/ai-dial-ui-kit": "^0.16.0-dev.72",
|
|
33
33
|
"react": "^19.2.8"
|
|
34
34
|
},
|
|
@@ -10,7 +10,7 @@ export declare enum ScheduledTaskRepeat {
|
|
|
10
10
|
Weekly = "weekly",
|
|
11
11
|
/** Task runs every month on `dayOfMonth` at the specified `time`. */
|
|
12
12
|
Monthly = "monthly",
|
|
13
|
-
/** Task runs every
|
|
13
|
+
/** Task runs every week on each of `daysOfWeek` at the specified `time`. */
|
|
14
14
|
Custom = "custom"
|
|
15
15
|
}
|
|
16
16
|
//# sourceMappingURL=scheduled-task-schedule.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scheduled-task-schedule.d.ts","sourceRoot":"","sources":["../../src/types/scheduled-task-schedule.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,oBAAY,mBAAmB;IAC7B,4DAA4D;IAC5D,OAAO,YAAY;IACnB,sDAAsD;IACtD,MAAM,WAAW;IACjB,mDAAmD;IACnD,KAAK,UAAU;IACf,mEAAmE;IACnE,MAAM,WAAW;IACjB,qEAAqE;IACrE,OAAO,YAAY;IACnB,
|
|
1
|
+
{"version":3,"file":"scheduled-task-schedule.d.ts","sourceRoot":"","sources":["../../src/types/scheduled-task-schedule.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,oBAAY,mBAAmB;IAC7B,4DAA4D;IAC5D,OAAO,YAAY;IACnB,sDAAsD;IACtD,MAAM,WAAW;IACjB,mDAAmD;IACnD,KAAK,UAAU;IACf,mEAAmE;IACnE,MAAM,WAAW;IACjB,qEAAqE;IACrE,OAAO,YAAY;IACnB,4EAA4E;IAC5E,MAAM,WAAW;CAClB"}
|
|
@@ -19,6 +19,8 @@ export declare enum ScheduledTaskValidationErrorCode {
|
|
|
19
19
|
TimeInvalid = "timeInvalid",
|
|
20
20
|
MinuteInvalid = "minuteInvalid",
|
|
21
21
|
DayOfWeekInvalid = "dayOfWeekInvalid",
|
|
22
|
+
/** The Custom repeat selects no weekday, an unknown one, or the same one twice. */
|
|
23
|
+
DaysOfWeekInvalid = "daysOfWeekInvalid",
|
|
22
24
|
DayOfMonthInvalid = "dayOfMonthInvalid",
|
|
23
25
|
StartDateInvalid = "startDateInvalid",
|
|
24
26
|
/** The activity-window start boundary is earlier than the clock — its day earlier than today for a date-only value, its instant earlier than now for a time-carrying one — and differs from the option's original. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scheduled-task-validation.d.ts","sourceRoot":"","sources":["../../src/validation/scheduled-task-validation.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,4CAA4C,CAAC;AAIhG,6EAA6E;AAC7E,oBAAY,gCAAgC;IAC1C,mBAAmB,wBAAwB;IAC3C,oEAAoE;IACpE,kBAAkB,uBAAuB;IACzC,0EAA0E;IAC1E,4BAA4B,iCAAiC;IAC7D,aAAa,kBAAkB;IAC/B,cAAc,mBAAmB;IACjC,oEAAoE;IACpE,aAAa,kBAAkB;IAC/B,qDAAqD;IACrD,2BAA2B,gCAAgC;IAC3D,6DAA6D;IAC7D,gBAAgB,qBAAqB;IACrC,kBAAkB,uBAAuB;IACzC,YAAY,iBAAiB;IAC7B,WAAW,gBAAgB;IAC3B,aAAa,kBAAkB;IAC/B,gBAAgB,qBAAqB;IACrC,iBAAiB,sBAAsB;IACvC,gBAAgB,qBAAqB;IACrC,sNAAsN;IACtN,eAAe,oBAAoB;IACnC,cAAc,mBAAmB;IACjC,oNAAoN;IACpN,aAAa,kBAAkB;CAChC;AAED,+EAA+E;AAC/E,MAAM,MAAM,6BAA6B,GAAG,OAAO,CACjD,MAAM,CAAC,MAAM,6BAA6B,EAAE,gCAAgC,CAAC,CAC9E,CAAC;AAEF,kFAAkF;AAClF,MAAM,WAAW,8BAA8B;IAC7C,GAAG,EAAE,IAAI,CAAC;IACV,6GAA6G;IAC7G,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,oFAAoF;IACpF,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,gLAAgL;IAChL,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,8KAA8K;IAC9K,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,2EAA2E;AAC3E,MAAM,MAAM,sBAAsB,GAAG,aAAa,GAAG,aAAa,GAAG,QAAQ,CAAC;AAE9E;;;;GAIG;AACH,eAAO,MAAM,8BAA8B,GACzC,OAAO,sBAAsB,EAC7B,OAAO,MAAM,GAAG,SAAS,KACxB,gCAAgC,GAAG,SAoBrC,CAAC;AAEF,+FAA+F;AAC/F,eAAO,MAAM,8BAA8B,QAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"scheduled-task-validation.d.ts","sourceRoot":"","sources":["../../src/validation/scheduled-task-validation.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,4CAA4C,CAAC;AAIhG,6EAA6E;AAC7E,oBAAY,gCAAgC;IAC1C,mBAAmB,wBAAwB;IAC3C,oEAAoE;IACpE,kBAAkB,uBAAuB;IACzC,0EAA0E;IAC1E,4BAA4B,iCAAiC;IAC7D,aAAa,kBAAkB;IAC/B,cAAc,mBAAmB;IACjC,oEAAoE;IACpE,aAAa,kBAAkB;IAC/B,qDAAqD;IACrD,2BAA2B,gCAAgC;IAC3D,6DAA6D;IAC7D,gBAAgB,qBAAqB;IACrC,kBAAkB,uBAAuB;IACzC,YAAY,iBAAiB;IAC7B,WAAW,gBAAgB;IAC3B,aAAa,kBAAkB;IAC/B,gBAAgB,qBAAqB;IACrC,mFAAmF;IACnF,iBAAiB,sBAAsB;IACvC,iBAAiB,sBAAsB;IACvC,gBAAgB,qBAAqB;IACrC,sNAAsN;IACtN,eAAe,oBAAoB;IACnC,cAAc,mBAAmB;IACjC,oNAAoN;IACpN,aAAa,kBAAkB;CAChC;AAED,+EAA+E;AAC/E,MAAM,MAAM,6BAA6B,GAAG,OAAO,CACjD,MAAM,CAAC,MAAM,6BAA6B,EAAE,gCAAgC,CAAC,CAC9E,CAAC;AAEF,kFAAkF;AAClF,MAAM,WAAW,8BAA8B;IAC7C,GAAG,EAAE,IAAI,CAAC;IACV,6GAA6G;IAC7G,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,oFAAoF;IACpF,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,gLAAgL;IAChL,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,8KAA8K;IAC9K,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,2EAA2E;AAC3E,MAAM,MAAM,sBAAsB,GAAG,aAAa,GAAG,aAAa,GAAG,QAAQ,CAAC;AAE9E;;;;GAIG;AACH,eAAO,MAAM,8BAA8B,GACzC,OAAO,sBAAsB,EAC7B,OAAO,MAAM,GAAG,SAAS,KACxB,gCAAgC,GAAG,SAoBrC,CAAC;AAEF,+FAA+F;AAC/F,eAAO,MAAM,8BAA8B,QAAS,CAAC;AAsCrD;;;;GAIG;AACH,eAAO,MAAM,+BAA+B,GAC1C,QAAQ,6BAA6B,EACrC,gFAMG,8BAA8B,KAChC,6BAuHF,CAAC"}
|
package/validation.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { t as e, u as t } from "./calendar-value-
|
|
1
|
+
import { t as e, u as t } from "./calendar-value-WOdrwh6p.js";
|
|
2
2
|
import { ENTITY_INSTRUCTIONS_MAX_LENGTH as n, ENTITY_NAME_MAX_LENGTH as r, exceedsMaxLength as i, hasControlCharacters as a, isSkillSelectionUnsupported as o } from "@epam/ai-dial-chat-shared";
|
|
3
3
|
//#region src/validation/scheduled-task-validation.ts
|
|
4
4
|
var s = /* @__PURE__ */ function(e) {
|
|
5
|
-
return e.DisplayNameRequired = "displayNameRequired", e.DisplayNameTooLong = "displayNameTooLong", e.DisplayNameControlCharacters = "displayNameControlCharacters", e.ModelRequired = "modelRequired", e.PromptRequired = "promptRequired", e.PromptTooLong = "promptTooLong", e.InstructionsOrSkillRequired = "instructionsOrSkillRequired", e.SkillUnsupported = "skillUnsupported", e.DescriptionTooLong = "descriptionTooLong", e.RunAtInvalid = "runAtInvalid", e.TimeInvalid = "timeInvalid", e.MinuteInvalid = "minuteInvalid", e.DayOfWeekInvalid = "dayOfWeekInvalid", e.DayOfMonthInvalid = "dayOfMonthInvalid", e.StartDateInvalid = "startDateInvalid", e.StartDateInPast = "startDateInPast", e.EndDateInvalid = "endDateInvalid", e.EndDateInPast = "endDateInPast", e;
|
|
5
|
+
return e.DisplayNameRequired = "displayNameRequired", e.DisplayNameTooLong = "displayNameTooLong", e.DisplayNameControlCharacters = "displayNameControlCharacters", e.ModelRequired = "modelRequired", e.PromptRequired = "promptRequired", e.PromptTooLong = "promptTooLong", e.InstructionsOrSkillRequired = "instructionsOrSkillRequired", e.SkillUnsupported = "skillUnsupported", e.DescriptionTooLong = "descriptionTooLong", e.RunAtInvalid = "runAtInvalid", e.TimeInvalid = "timeInvalid", e.MinuteInvalid = "minuteInvalid", e.DayOfWeekInvalid = "dayOfWeekInvalid", e.DaysOfWeekInvalid = "daysOfWeekInvalid", e.DayOfMonthInvalid = "dayOfMonthInvalid", e.StartDateInvalid = "startDateInvalid", e.StartDateInPast = "startDateInPast", e.EndDateInvalid = "endDateInvalid", e.EndDateInPast = "endDateInPast", e;
|
|
6
6
|
}({}), c = (e, t) => {
|
|
7
7
|
let o = t?.trim() ?? "";
|
|
8
8
|
switch (e) {
|
|
@@ -10,25 +10,25 @@ var s = /* @__PURE__ */ function(e) {
|
|
|
10
10
|
case "description": return i(o, 500) ? "descriptionTooLong" : void 0;
|
|
11
11
|
case "prompt": return i(o, n) ? "promptTooLong" : void 0;
|
|
12
12
|
}
|
|
13
|
-
}, l = 6e4, u = /^(?:[0-9]|[1-5][0-9])$/, d = /^[0-6]$/, f = /^(?:[1-9]|[12][0-9]|3[01])$/, p = /^\d{4}-\d{2}-\d{2}$/, m = (e) => {
|
|
13
|
+
}, l = 6e4, u = /^(?:[0-9]|[1-5][0-9])$/, d = /^[0-6]$/, f = /^(?:[1-9]|[12][0-9]|3[01])$/, p = /^\d{4}-\d{2}-\d{2}$/, m = (e) => !!e?.length && e.every((e) => d.test(e)) && new Set(e).size === e.length, h = (e) => {
|
|
14
14
|
if (!p.test(e)) return !1;
|
|
15
15
|
let [t, n, r] = e.split("-").map(Number), i = new Date(t, n - 1, r);
|
|
16
16
|
return i.getFullYear() === t && i.getMonth() === n - 1 && i.getDate() === r;
|
|
17
|
-
},
|
|
17
|
+
}, g = (e) => {
|
|
18
18
|
let t = new Date(e).getTime();
|
|
19
19
|
return Number.isFinite(t);
|
|
20
|
-
},
|
|
21
|
-
let
|
|
20
|
+
}, _ = (e) => String(e).padStart(2, "0"), v = (e) => `${e.getFullYear()}-${_(e.getMonth() + 1)}-${_(e.getDate())}`, y = (e, t) => e < t, b = (n, { now: r, minimumLeadMs: i = l, isSkillsSupported: a, originalStartDate: s, originalEndDate: p }) => {
|
|
21
|
+
let _ = {}, b = (e, t) => {
|
|
22
22
|
let n = c(e, t);
|
|
23
|
-
n && (
|
|
23
|
+
n && (_[e] = n);
|
|
24
24
|
};
|
|
25
|
-
if (n.displayName.trim() ?
|
|
25
|
+
if (n.displayName.trim() ? b("displayName", n.displayName) : _.displayName = "displayNameRequired", n.modelId.trim() || (_.modelId = "modelRequired"), !n.prompt.trim() && !n.skillUrls?.length ? _.prompt = "instructionsOrSkillRequired" : b("prompt", n.prompt), n.skillUrls?.some((e) => o(e, a)) && (_.skillUrls = "skillUnsupported"), b("description", n.description), n.repeat === t.OneTime) {
|
|
26
26
|
let e = n.runAt ? new Date(n.runAt).getTime() : NaN;
|
|
27
|
-
return (!n.runAt || !
|
|
27
|
+
return (!n.runAt || !g(n.runAt) || !Number.isFinite(e) || e < r.getTime() + i) && (_.runAt = "runAtInvalid"), _;
|
|
28
28
|
}
|
|
29
|
-
n.repeat === t.Hourly ? u.test(n.minute ?? "") || (
|
|
30
|
-
let
|
|
31
|
-
return n.startDate && n.startDate !== s &&
|
|
29
|
+
n.repeat === t.Hourly ? u.test(n.minute ?? "") || (_.minute = "minuteInvalid") : e.test(n.time) || (_.time = "timeInvalid"), n.repeat === t.Weekly && !d.test(n.dayOfWeek ?? "") && (_.dayOfWeek = "dayOfWeekInvalid"), n.repeat === t.Custom && !m(n.daysOfWeek) && (_.daysOfWeek = "daysOfWeekInvalid"), n.repeat === t.Monthly && !f.test(n.dayOfMonth ?? "") && (_.dayOfMonth = "dayOfMonthInvalid"), n.startDate && !h(n.startDate) && (_.startDate = "startDateInvalid"), n.endDate && !h(n.endDate) && (_.endDate = "endDateInvalid"), n.startDate && n.endDate && h(n.startDate) && h(n.endDate) && n.endDate < n.startDate && (_.endDate = "endDateInvalid");
|
|
30
|
+
let x = v(r);
|
|
31
|
+
return n.startDate && n.startDate !== s && h(n.startDate) && y(n.startDate, x) && (_.startDate = "startDateInPast"), n.endDate && n.endDate !== p && h(n.endDate) && y(n.endDate, x) && (_.endDate = "endDateInPast"), _;
|
|
32
32
|
};
|
|
33
33
|
//#endregion
|
|
34
|
-
export { l as SCHEDULED_TASK_MINIMUM_LEAD_MS, s as ScheduledTaskValidationErrorCode,
|
|
34
|
+
export { l as SCHEDULED_TASK_MINIMUM_LEAD_MS, s as ScheduledTaskValidationErrorCode, b as validateScheduledTaskFormValues, c as validateScheduledTaskTextField };
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { ScheduledTaskRepeat } from '../types/scheduled-task-schedule';
|
|
2
|
-
/** Returns the boundary value to keep after a repeat switch: the value itself unless either cadence is custom (no boundary fields), in which case `undefined`. */
|
|
3
|
-
export declare const keepWindowBoundaryOnRepeatSwitch: (value: string | undefined, currentRepeat: ScheduledTaskRepeat, nextRepeat: ScheduledTaskRepeat) => string | undefined;
|
|
4
|
-
//# sourceMappingURL=window-boundary.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"window-boundary.d.ts","sourceRoot":"","sources":["../../src/utils/window-boundary.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AASvE,kKAAkK;AAClK,eAAO,MAAM,gCAAgC,GAC3C,OAAO,MAAM,GAAG,SAAS,EACzB,eAAe,mBAAmB,EAClC,YAAY,mBAAmB,KAC9B,MAAM,GAAG,SAID,CAAC"}
|