@epam/ai-dial-skill-editor 1.2.0-rc.0 → 1.2.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/SkillEditor/SkillEditor.d.ts.map +1 -1
- package/index.js +117 -116
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SkillEditor.d.ts","sourceRoot":"","sources":["../../../src/components/SkillEditor/SkillEditor.tsx"],"names":[],"mappings":"AA0DA,OAAO,0CAA0C,CAAC;AAClD,OAAO,0CAA0C,CAAC;AAClD,OAAO,EAEL,EAAE,EAUH,MAAM,OAAO,CAAC;AAIf,OAAO,KAAK,EACV,gBAAgB,EAIjB,MAAM,iCAAiC,CAAC;
|
|
1
|
+
{"version":3,"file":"SkillEditor.d.ts","sourceRoot":"","sources":["../../../src/components/SkillEditor/SkillEditor.tsx"],"names":[],"mappings":"AA0DA,OAAO,0CAA0C,CAAC;AAClD,OAAO,0CAA0C,CAAC;AAClD,OAAO,EAEL,EAAE,EAUH,MAAM,OAAO,CAAC;AAIf,OAAO,KAAK,EACV,gBAAgB,EAIjB,MAAM,iCAAiC,CAAC;AAuDzC,qFAAqF;AACrF,eAAO,MAAM,WAAW,EAAE,EAAE,CAAC,gBAAgB,CA20B5C,CAAC"}
|
package/index.js
CHANGED
|
@@ -979,10 +979,10 @@ var Re = {
|
|
|
979
979
|
}, st = {
|
|
980
980
|
mode: Ze.Files,
|
|
981
981
|
targetFolderPath: ""
|
|
982
|
-
}, ct = [U.Name, U.Description], lt = 24, ut = 300, dt = "desktop:px-8 desktop:py-6", ft = "gap-4 px-4 py-6 desktop:gap-5 desktop:px-8 desktop:py-6",
|
|
982
|
+
}, ct = [U.Name, U.Description], lt = 24, ut = 300, dt = "desktop:px-8 desktop:py-6", ft = "desktop:px-8 desktop:py-6", pt = "gap-4 px-4 py-6 desktop:gap-5 desktop:px-8 desktop:py-6", mt = R(async () => {
|
|
983
983
|
let { MarkdownEditor: e } = await _e();
|
|
984
984
|
return { default: e };
|
|
985
|
-
}),
|
|
985
|
+
}), ht = ({ initialValues: r, files: i, selectedPath: s, onSelectedPathChange: v, expandedPaths: S, onExpandedPathsChange: w, isLoading: T = !1, hasLoadError: D = !1, isSubmitting: O = !1, errors: k, submitError: ee, conflict: te, onReloadLatest: j, isNameReadOnly: M = !1, onDirtyChange: N, onValuesChange: L, onRefineDescription: ie, onRefineInstructions: se, fileActions: R, supportingFileContent: fe, asideData: _e, onSubmit: ve, onCancel: ye, onBack: be, backAriaLabel: xe, title: Se, onRetry: Ce, onRetrySubmit: we, labels: Te, styles: U, dir: Ee, instructionsEditorTheme: De = y.light }) => {
|
|
986
986
|
let [W, Oe] = H({
|
|
987
987
|
name: r?.name ?? "",
|
|
988
988
|
description: r?.description ?? "",
|
|
@@ -1052,31 +1052,31 @@ var Re = {
|
|
|
1052
1052
|
]);
|
|
1053
1053
|
let [rt, it] = H(K), X = s ?? rt, Z = z((e) => {
|
|
1054
1054
|
it(e), v?.(e);
|
|
1055
|
-
}, [v]), [
|
|
1055
|
+
}, [v]), [ht, gt] = H([]), _t = S ?? ht, vt = B(() => new Set(_t), [_t]), yt = z((e) => {
|
|
1056
1056
|
let t = [...e];
|
|
1057
|
-
|
|
1058
|
-
}, [w]), [
|
|
1059
|
-
|
|
1060
|
-
}, []), [
|
|
1061
|
-
|
|
1057
|
+
gt(t), w?.(t);
|
|
1058
|
+
}, [w]), [bt, xt] = H(!1), [St, Ct] = H(st), wt = z((e) => {
|
|
1059
|
+
Ct(e), xt(!0);
|
|
1060
|
+
}, []), [Tt, Et] = H(!1), { isDragActive: Dt, dropZoneHandlers: Ot } = Xe(z((e) => {
|
|
1061
|
+
bt || wt({
|
|
1062
1062
|
...st,
|
|
1063
1063
|
initialFiles: e
|
|
1064
1064
|
});
|
|
1065
|
-
}, [
|
|
1065
|
+
}, [bt, wt])), Q = Te ?? {}, $ = U?.colors, kt = U?.typography ?? {}, At = kt.titleClassName ?? "dial-body-semi-text", jt = kt.helperTextClassName ?? "dial-tiny-semi-text", Mt = kt.removeIconClassName, Nt = kt.menuIconClassName ?? "text-secondary", Pt = o({
|
|
1066
1066
|
"--se-title-color": $?.title,
|
|
1067
1067
|
"--se-helper-text-color": $?.helperText,
|
|
1068
1068
|
"--se-refine-action-text": $?.refineActionText,
|
|
1069
1069
|
"--se-refine-error-text": $?.refineErrorText
|
|
1070
|
-
}),
|
|
1071
|
-
feedbackClassName: c($?.refineActionText && ot.refineFeedback,
|
|
1070
|
+
}), Ft = {
|
|
1071
|
+
feedbackClassName: c($?.refineActionText && ot.refineFeedback, kt.refineFeedbackClassName, Re.refineFeedback),
|
|
1072
1072
|
errorClassName: ot.refineError
|
|
1073
|
-
},
|
|
1073
|
+
}, It = {
|
|
1074
1074
|
layout: $?.border ? { colors: {
|
|
1075
1075
|
headerBorderColor: $.border,
|
|
1076
1076
|
sidebarBorderColor: $.border
|
|
1077
1077
|
} } : void 0,
|
|
1078
1078
|
section: $?.title ? { colors: { titleColor: $.title } } : void 0
|
|
1079
|
-
},
|
|
1079
|
+
}, Lt = B(() => ({
|
|
1080
1080
|
required: Q.folderNameRequiredError ?? "Enter a folder name",
|
|
1081
1081
|
invalid: Q.folderNameInvalidError ?? "Folder name can't contain / or \\, or be . or ..",
|
|
1082
1082
|
duplicate: Q.folderNameDuplicateError ?? "An item with this name already exists here"
|
|
@@ -1084,133 +1084,133 @@ var Re = {
|
|
|
1084
1084
|
Q.folderNameRequiredError,
|
|
1085
1085
|
Q.folderNameInvalidError,
|
|
1086
1086
|
Q.folderNameDuplicateError
|
|
1087
|
-
]),
|
|
1088
|
-
|
|
1089
|
-
}, [
|
|
1087
|
+
]), Rt = z((e) => {
|
|
1088
|
+
vt.has(e) || yt(new Set([...vt, e]));
|
|
1089
|
+
}, [vt, yt]), zt = Je({
|
|
1090
1090
|
files: i,
|
|
1091
1091
|
fileActions: R,
|
|
1092
1092
|
defaultName: Q.newFolderDefaultName ?? "New folder",
|
|
1093
|
-
messages:
|
|
1094
|
-
onRevealFolder:
|
|
1093
|
+
messages: Lt,
|
|
1094
|
+
onRevealFolder: Rt,
|
|
1095
1095
|
onCreated: Z
|
|
1096
|
-
}), { draftNode:
|
|
1096
|
+
}), { draftNode: Bt, draftPath: Vt, draftPane: Ht } = zt, Ut = B(() => Ve([{
|
|
1097
1097
|
path: K,
|
|
1098
1098
|
name: K,
|
|
1099
1099
|
kind: q.File
|
|
1100
|
-
}, ...i]), [i]),
|
|
1100
|
+
}, ...i]), [i]), Wt = B(() => Bt ? Ve([
|
|
1101
1101
|
{
|
|
1102
1102
|
path: K,
|
|
1103
1103
|
name: K,
|
|
1104
1104
|
kind: q.File
|
|
1105
1105
|
},
|
|
1106
1106
|
...i,
|
|
1107
|
-
|
|
1108
|
-
]) :
|
|
1107
|
+
Bt
|
|
1108
|
+
]) : Ut, [
|
|
1109
1109
|
i,
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
]),
|
|
1113
|
-
e.path !==
|
|
1114
|
-
}, [Z,
|
|
1110
|
+
Bt,
|
|
1111
|
+
Ut
|
|
1112
|
+
]), Gt = B(() => i.find((e) => e.path === X), [i, X]), Kt = z((e) => {
|
|
1113
|
+
e.path !== Vt && Z(e.path);
|
|
1114
|
+
}, [Z, Vt]), qt = z((e) => {
|
|
1115
1115
|
R.onRemoveNode(e), X === e && Z(K);
|
|
1116
1116
|
}, [
|
|
1117
1117
|
R,
|
|
1118
1118
|
X,
|
|
1119
1119
|
Z
|
|
1120
|
-
]), { startDraft:
|
|
1121
|
-
if (!
|
|
1122
|
-
let t = await
|
|
1123
|
-
t?.length &&
|
|
1120
|
+
]), { startDraft: Jt } = zt, { onCreateFolder: Yt, extractArchive: Xt, pickFromFileSystem: Zt } = R, Qt = z(async (e) => {
|
|
1121
|
+
if (!Zt) return;
|
|
1122
|
+
let t = await Zt();
|
|
1123
|
+
t?.length && wt({
|
|
1124
1124
|
mode: Ze.Files,
|
|
1125
1125
|
targetFolderPath: e,
|
|
1126
1126
|
initialEntries: t
|
|
1127
1127
|
});
|
|
1128
|
-
}, [
|
|
1129
|
-
let n = (e) => Qe(e,
|
|
1130
|
-
return
|
|
1128
|
+
}, [Zt, wt]), $t = z((e, t) => {
|
|
1129
|
+
let n = (e) => Qe(e, Nt), r = [];
|
|
1130
|
+
return Yt && r.push({
|
|
1131
1131
|
key: "create-folder",
|
|
1132
1132
|
label: Q.createFolderLabel ?? "Create folder",
|
|
1133
1133
|
icon: n(oe),
|
|
1134
|
-
onClick: () =>
|
|
1134
|
+
onClick: () => Jt(e, t)
|
|
1135
1135
|
}), r.push({
|
|
1136
1136
|
key: "upload-files",
|
|
1137
1137
|
label: Q.uploadFilesLabel ?? "Upload files from device",
|
|
1138
1138
|
icon: n(ue),
|
|
1139
|
-
onClick: () =>
|
|
1139
|
+
onClick: () => wt({
|
|
1140
1140
|
mode: Ze.Files,
|
|
1141
1141
|
targetFolderPath: e
|
|
1142
1142
|
})
|
|
1143
|
-
}),
|
|
1143
|
+
}), Xt && r.push({
|
|
1144
1144
|
key: "upload-archive",
|
|
1145
1145
|
label: Q.uploadArchiveLabel ?? "Upload archive from device",
|
|
1146
1146
|
icon: n(ae),
|
|
1147
|
-
onClick: () =>
|
|
1147
|
+
onClick: () => wt({
|
|
1148
1148
|
mode: Ze.Archive,
|
|
1149
1149
|
targetFolderPath: e
|
|
1150
1150
|
})
|
|
1151
|
-
}),
|
|
1151
|
+
}), Zt && r.push({
|
|
1152
1152
|
key: "open-file-system",
|
|
1153
1153
|
label: Q.openFileSystemLabel ?? "Open DIAL file system",
|
|
1154
1154
|
icon: n(re),
|
|
1155
|
-
onClick: () => void
|
|
1155
|
+
onClick: () => void Qt(e)
|
|
1156
1156
|
}), r;
|
|
1157
1157
|
}, [
|
|
1158
|
-
|
|
1159
|
-
Jt,
|
|
1158
|
+
Nt,
|
|
1160
1159
|
Yt,
|
|
1161
1160
|
Xt,
|
|
1161
|
+
Zt,
|
|
1162
1162
|
Q.createFolderLabel,
|
|
1163
1163
|
Q.uploadFilesLabel,
|
|
1164
1164
|
Q.uploadArchiveLabel,
|
|
1165
1165
|
Q.openFileSystemLabel,
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
]),
|
|
1166
|
+
Jt,
|
|
1167
|
+
wt,
|
|
1168
|
+
Qt
|
|
1169
|
+
]), en = B(() => {
|
|
1170
1170
|
let e = We(ze.Header, i.find((e) => e.path === X));
|
|
1171
1171
|
return {
|
|
1172
|
-
[Y.Mobile]:
|
|
1173
|
-
[Y.Desktop]:
|
|
1172
|
+
[Y.Mobile]: $t(e, Y.Mobile),
|
|
1173
|
+
[Y.Desktop]: $t(e, Y.Desktop)
|
|
1174
1174
|
};
|
|
1175
1175
|
}, [
|
|
1176
|
-
|
|
1176
|
+
$t,
|
|
1177
1177
|
i,
|
|
1178
1178
|
X
|
|
1179
|
-
]),
|
|
1180
|
-
if (e.path === "SKILL.md" || e.path ===
|
|
1179
|
+
]), tn = z((e, t) => {
|
|
1180
|
+
if (e.path === "SKILL.md" || e.path === Vt) return [];
|
|
1181
1181
|
let n = {
|
|
1182
1182
|
path: e.path,
|
|
1183
1183
|
name: e.name,
|
|
1184
1184
|
kind: e.nodeType === he.FOLDER ? q.Folder : q.File
|
|
1185
|
-
}, r = n.kind === q.Folder ?
|
|
1185
|
+
}, r = n.kind === q.Folder ? $t(We(ze.Child, n), t) : [];
|
|
1186
1186
|
return r.push({
|
|
1187
1187
|
key: "add-sibling",
|
|
1188
1188
|
icon: Qe(ce),
|
|
1189
1189
|
label: Q.addSiblingLabel ?? "Add sibling",
|
|
1190
|
-
children:
|
|
1190
|
+
children: $t(We(ze.Sibling, n), t)
|
|
1191
1191
|
}, {
|
|
1192
1192
|
key: "delete",
|
|
1193
1193
|
label: Q.deleteLabel ?? "Delete",
|
|
1194
1194
|
danger: !0,
|
|
1195
|
-
icon: Qe(le,
|
|
1196
|
-
onClick: () =>
|
|
1195
|
+
icon: Qe(le, Mt),
|
|
1196
|
+
onClick: () => qt(e.path)
|
|
1197
1197
|
}), r;
|
|
1198
1198
|
}, [
|
|
1199
|
-
|
|
1199
|
+
Vt,
|
|
1200
1200
|
Q.addSiblingLabel,
|
|
1201
1201
|
Q.deleteLabel,
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
]),
|
|
1206
|
-
[Y.Mobile]: (e) =>
|
|
1207
|
-
[Y.Desktop]: (e) =>
|
|
1208
|
-
}), [
|
|
1202
|
+
Mt,
|
|
1203
|
+
$t,
|
|
1204
|
+
qt
|
|
1205
|
+
]), nn = B(() => ({
|
|
1206
|
+
[Y.Mobile]: (e) => tn(e, Y.Mobile),
|
|
1207
|
+
[Y.Desktop]: (e) => tn(e, Y.Desktop)
|
|
1208
|
+
}), [tn]), rn = (e) => /* @__PURE__ */ I("div", {
|
|
1209
1209
|
className: "flex flex-col gap-2 desktop:gap-5",
|
|
1210
1210
|
children: [/* @__PURE__ */ I("div", {
|
|
1211
1211
|
className: "flex items-center justify-between",
|
|
1212
1212
|
children: [/* @__PURE__ */ F("span", {
|
|
1213
|
-
className: c(ot.title,
|
|
1213
|
+
className: c(ot.title, At),
|
|
1214
1214
|
children: Q.filesHeading ?? "Files"
|
|
1215
1215
|
}), /* @__PURE__ */ F(p, {
|
|
1216
1216
|
label: Q.addLabel ?? "Add",
|
|
@@ -1222,37 +1222,37 @@ var Re = {
|
|
|
1222
1222
|
"aria-hidden": !0,
|
|
1223
1223
|
stroke: _
|
|
1224
1224
|
}),
|
|
1225
|
-
items:
|
|
1225
|
+
items: en[e]
|
|
1226
1226
|
})]
|
|
1227
1227
|
}), /* @__PURE__ */ F("div", {
|
|
1228
1228
|
role: "tree",
|
|
1229
1229
|
"aria-label": Q.filesTreeAriaLabel ?? "Skill files",
|
|
1230
1230
|
children: /* @__PURE__ */ F(ge, {
|
|
1231
|
-
items:
|
|
1231
|
+
items: Ht === e ? Wt : Ut,
|
|
1232
1232
|
showFiles: !0,
|
|
1233
1233
|
selectedPath: X,
|
|
1234
|
-
expandedPaths:
|
|
1235
|
-
onExpandedPathsChange:
|
|
1236
|
-
onItemClick:
|
|
1237
|
-
getContextMenuItems:
|
|
1238
|
-
renamedPath:
|
|
1239
|
-
onRenameSave:
|
|
1240
|
-
onRenameCancel:
|
|
1241
|
-
onRenameValidate:
|
|
1234
|
+
expandedPaths: vt,
|
|
1235
|
+
onExpandedPathsChange: yt,
|
|
1236
|
+
onItemClick: Kt,
|
|
1237
|
+
getContextMenuItems: nn[e],
|
|
1238
|
+
renamedPath: Ht === e ? Vt : void 0,
|
|
1239
|
+
onRenameSave: zt.handleSave,
|
|
1240
|
+
onRenameCancel: zt.handleCancel,
|
|
1241
|
+
onRenameValidate: zt.handleValidate,
|
|
1242
1242
|
rootItemPath: ""
|
|
1243
1243
|
})
|
|
1244
1244
|
})]
|
|
1245
|
-
}),
|
|
1245
|
+
}), an = B(() => ({
|
|
1246
1246
|
name: W.name,
|
|
1247
1247
|
description: W.description,
|
|
1248
1248
|
iconUrl: "",
|
|
1249
1249
|
version: "",
|
|
1250
1250
|
topics: [],
|
|
1251
1251
|
otherLocales: []
|
|
1252
|
-
}), [W.name, W.description]),
|
|
1252
|
+
}), [W.name, W.description]), on = B(() => ({
|
|
1253
1253
|
name: k?.name,
|
|
1254
1254
|
description: k?.description
|
|
1255
|
-
}), [k?.name, k?.description]),
|
|
1255
|
+
}), [k?.name, k?.description]), sn = B(() => ({ form: {
|
|
1256
1256
|
...Pe,
|
|
1257
1257
|
name: {
|
|
1258
1258
|
label: Q.nameLabel ?? "Name",
|
|
@@ -1268,9 +1268,9 @@ var Re = {
|
|
|
1268
1268
|
Q.namePlaceholder,
|
|
1269
1269
|
Q.descriptionLabel,
|
|
1270
1270
|
Q.descriptionPlaceholder
|
|
1271
|
-
]),
|
|
1271
|
+
]), cn = (e) => {
|
|
1272
1272
|
e.name !== void 0 && Me({ name: e.name }), e.description !== void 0 && (Le.reset(), Me({ description: e.description }));
|
|
1273
|
-
},
|
|
1273
|
+
}, ln = ie ? (e, t) => /* @__PURE__ */ F(a, {
|
|
1274
1274
|
isEnabled: !0,
|
|
1275
1275
|
fieldId: t,
|
|
1276
1276
|
required: !0,
|
|
@@ -1278,9 +1278,9 @@ var Re = {
|
|
|
1278
1278
|
labels: Q,
|
|
1279
1279
|
refinement: Le,
|
|
1280
1280
|
disabled: Be || O,
|
|
1281
|
-
...
|
|
1281
|
+
...Ft,
|
|
1282
1282
|
children: e
|
|
1283
|
-
}) : void 0,
|
|
1283
|
+
}) : void 0, un = {
|
|
1284
1284
|
title: Se,
|
|
1285
1285
|
onBack: Ge,
|
|
1286
1286
|
onCancel: Ue,
|
|
@@ -1292,14 +1292,14 @@ var Re = {
|
|
|
1292
1292
|
backAriaLabel: xe ?? "Back",
|
|
1293
1293
|
savingStatusLabel: Q.savingStatusLabel ?? "Saving"
|
|
1294
1294
|
},
|
|
1295
|
-
styles:
|
|
1295
|
+
styles: It,
|
|
1296
1296
|
metadataTitle: null
|
|
1297
1297
|
};
|
|
1298
1298
|
if (T) return /* @__PURE__ */ F("div", {
|
|
1299
1299
|
dir: Ee,
|
|
1300
1300
|
className: "relative flex min-h-0 flex-1 flex-col",
|
|
1301
1301
|
children: /* @__PURE__ */ F(Ne, {
|
|
1302
|
-
...
|
|
1302
|
+
...un,
|
|
1303
1303
|
metadata: /* @__PURE__ */ F("div", {
|
|
1304
1304
|
role: "status",
|
|
1305
1305
|
"aria-label": Q.loadingAriaLabel ?? "Loading skill",
|
|
@@ -1312,7 +1312,7 @@ var Re = {
|
|
|
1312
1312
|
dir: Ee,
|
|
1313
1313
|
className: "relative flex min-h-0 flex-1 flex-col",
|
|
1314
1314
|
children: /* @__PURE__ */ F(Ne, {
|
|
1315
|
-
...
|
|
1315
|
+
...un,
|
|
1316
1316
|
metadata: /* @__PURE__ */ I("div", {
|
|
1317
1317
|
role: "alert",
|
|
1318
1318
|
className: "flex flex-col items-center gap-4 p-8",
|
|
@@ -1323,7 +1323,7 @@ var Re = {
|
|
|
1323
1323
|
})
|
|
1324
1324
|
})
|
|
1325
1325
|
});
|
|
1326
|
-
let
|
|
1326
|
+
let dn = X === K, fn = dn ? K : Q.selectedFileHeading?.(Gt?.name ?? X) ?? Gt?.name ?? X, pn = ee != null || te != null ? /* @__PURE__ */ I("div", {
|
|
1327
1327
|
className: "flex flex-col gap-2",
|
|
1328
1328
|
children: [ee != null && /* @__PURE__ */ I("div", {
|
|
1329
1329
|
className: "flex items-center gap-2",
|
|
@@ -1338,22 +1338,22 @@ var Re = {
|
|
|
1338
1338
|
onClick: j
|
|
1339
1339
|
})]
|
|
1340
1340
|
})]
|
|
1341
|
-
}) : void 0,
|
|
1341
|
+
}) : void 0, mn = /* @__PURE__ */ F(a, {
|
|
1342
1342
|
isEnabled: !!se,
|
|
1343
1343
|
fieldId: ke,
|
|
1344
1344
|
required: !0,
|
|
1345
|
-
labelClassName: c(ot.helperText,
|
|
1345
|
+
labelClassName: c(ot.helperText, jt),
|
|
1346
1346
|
label: Q.instructionsLabel ?? "Instructions",
|
|
1347
1347
|
labels: Q,
|
|
1348
1348
|
refinement: J,
|
|
1349
1349
|
disabled: Be || O,
|
|
1350
|
-
...
|
|
1350
|
+
...Ft,
|
|
1351
1351
|
children: /* @__PURE__ */ I("div", {
|
|
1352
1352
|
className: "flex flex-1 flex-col gap-2",
|
|
1353
1353
|
children: [
|
|
1354
1354
|
!se && /* @__PURE__ */ F(E, {
|
|
1355
1355
|
htmlFor: ke,
|
|
1356
|
-
className: c(ot.helperText,
|
|
1356
|
+
className: c(ot.helperText, jt),
|
|
1357
1357
|
label: Q.instructionsLabel ?? "Instructions",
|
|
1358
1358
|
required: !0
|
|
1359
1359
|
}),
|
|
@@ -1362,7 +1362,7 @@ var Re = {
|
|
|
1362
1362
|
className: c(t, e, n),
|
|
1363
1363
|
children: /* @__PURE__ */ F(de, {
|
|
1364
1364
|
fallback: /* @__PURE__ */ F(ne, { ariaLabel: Q.instructionsLoadingAriaLabel ?? "Loading" }),
|
|
1365
|
-
children: /* @__PURE__ */ F(
|
|
1365
|
+
children: /* @__PURE__ */ F(mt, {
|
|
1366
1366
|
id: ke,
|
|
1367
1367
|
ariaLabel: Q.instructionsLabel ?? "Instructions",
|
|
1368
1368
|
value: W.instructions,
|
|
@@ -1382,62 +1382,63 @@ var Re = {
|
|
|
1382
1382
|
return /* @__PURE__ */ I("div", {
|
|
1383
1383
|
dir: Ee,
|
|
1384
1384
|
className: c("relative flex min-h-0 flex-1 flex-col", Re.root),
|
|
1385
|
-
style:
|
|
1386
|
-
...
|
|
1385
|
+
style: Pt,
|
|
1386
|
+
...Ot,
|
|
1387
1387
|
children: [
|
|
1388
1388
|
/* @__PURE__ */ F($e, {
|
|
1389
|
-
isVisible:
|
|
1389
|
+
isVisible: Dt && !bt,
|
|
1390
1390
|
labels: Te
|
|
1391
1391
|
}),
|
|
1392
1392
|
/* @__PURE__ */ F(Ne, {
|
|
1393
|
-
...
|
|
1393
|
+
...un,
|
|
1394
1394
|
asideData: _e,
|
|
1395
|
+
asideSectionClassName: ft,
|
|
1395
1396
|
isSubmitting: O,
|
|
1396
1397
|
metadataSectionClassName: dt,
|
|
1397
1398
|
metadata: /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ F("div", {
|
|
1398
1399
|
className: "desktop:hidden",
|
|
1399
1400
|
children: /* @__PURE__ */ F(d, {
|
|
1400
1401
|
title: Q.editingFileLabel ?? "Editing file",
|
|
1401
|
-
description:
|
|
1402
|
-
expanded:
|
|
1403
|
-
onToggle:
|
|
1402
|
+
description: Gt?.name ?? "SKILL.md",
|
|
1403
|
+
expanded: Tt,
|
|
1404
|
+
onToggle: Et,
|
|
1404
1405
|
ariaLabel: Q.editingFileLabel ?? "Editing file",
|
|
1405
|
-
children:
|
|
1406
|
+
children: rn(Y.Mobile)
|
|
1406
1407
|
})
|
|
1407
1408
|
}), /* @__PURE__ */ F("div", {
|
|
1408
1409
|
className: "hidden desktop:block",
|
|
1409
|
-
children:
|
|
1410
|
+
children: rn(Y.Desktop)
|
|
1410
1411
|
})] }),
|
|
1411
|
-
alert:
|
|
1412
|
-
setupTitle:
|
|
1413
|
-
setupSectionClassName:
|
|
1414
|
-
setup:
|
|
1415
|
-
values:
|
|
1416
|
-
errors:
|
|
1417
|
-
onChange:
|
|
1412
|
+
alert: pn,
|
|
1413
|
+
setupTitle: fn,
|
|
1414
|
+
setupSectionClassName: pt,
|
|
1415
|
+
setup: dn ? /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ F(Ie, {
|
|
1416
|
+
values: an,
|
|
1417
|
+
errors: on,
|
|
1418
|
+
onChange: cn,
|
|
1418
1419
|
fields: ct,
|
|
1419
1420
|
isDescriptionRequired: !0,
|
|
1420
1421
|
isNameReadOnly: M,
|
|
1421
1422
|
nameCaption: k?.name ? void 0 : Q.nameCaption ?? "Lowercase letters and hyphens only, no spaces. We'll reformat automatically if needed.",
|
|
1422
|
-
renderDescription:
|
|
1423
|
-
labels:
|
|
1424
|
-
}),
|
|
1423
|
+
renderDescription: ln,
|
|
1424
|
+
labels: sn
|
|
1425
|
+
}), mn] }) : /* @__PURE__ */ F(P, { children: Gt?.kind === q.File && /* @__PURE__ */ F("div", {
|
|
1425
1426
|
className: "flex min-h-0 flex-1 flex-col",
|
|
1426
1427
|
children: fe ?? /* @__PURE__ */ F(h, { text: Q.supportingFileNote ?? "This supporting file is included in the skill package as-is. Remove it from the Files panel to replace its content." })
|
|
1427
1428
|
}) })
|
|
1428
1429
|
}),
|
|
1429
1430
|
/* @__PURE__ */ F(at, {
|
|
1430
|
-
isOpen:
|
|
1431
|
-
onClose: () =>
|
|
1431
|
+
isOpen: bt,
|
|
1432
|
+
onClose: () => xt(!1),
|
|
1432
1433
|
fileActions: R,
|
|
1433
|
-
mode:
|
|
1434
|
-
targetFolderPath:
|
|
1435
|
-
initialFiles:
|
|
1436
|
-
initialEntries:
|
|
1434
|
+
mode: St.mode,
|
|
1435
|
+
targetFolderPath: St.targetFolderPath,
|
|
1436
|
+
initialFiles: St.initialFiles,
|
|
1437
|
+
initialEntries: St.initialEntries,
|
|
1437
1438
|
labels: Te
|
|
1438
1439
|
})
|
|
1439
1440
|
]
|
|
1440
1441
|
});
|
|
1441
1442
|
};
|
|
1442
1443
|
//#endregion
|
|
1443
|
-
export { Re as SKILL_EDITOR_CLASS,
|
|
1444
|
+
export { Re as SKILL_EDITOR_CLASS, ht as SkillEditor, et as SkillFileCandidateKind, q as SkillFileNodeKind, Ze as SkillFileUploadMode, tt as SkillFileValidationStatus };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epam/ai-dial-skill-editor",
|
|
3
3
|
"description": "Host-agnostic form for authoring a DIAL Skill, with an inline supporting-file tree",
|
|
4
|
-
"version": "1.2.0-rc.
|
|
4
|
+
"version": "1.2.0-rc.1",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./index.js",
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
"@tabler/icons-react": "^3.44.0",
|
|
21
21
|
"@uiw/react-markdown-preview": "^5.2.1",
|
|
22
22
|
"@uiw/react-md-editor": "^4.1.1",
|
|
23
|
-
"@epam/ai-dial-builder-form": "1.2.0-rc.
|
|
23
|
+
"@epam/ai-dial-builder-form": "1.2.0-rc.1"
|
|
24
24
|
},
|
|
25
25
|
"peerDependencies": {
|
|
26
|
-
"@epam/ai-dial-chat-shared": "1.2.0-rc.
|
|
26
|
+
"@epam/ai-dial-chat-shared": "1.2.0-rc.1",
|
|
27
27
|
"@epam/ai-dial-ui-kit": "^0.15.0",
|
|
28
28
|
"@epam/ai-dial-react-file-manager": "^0.3.0",
|
|
29
29
|
"react": "^19.2.8"
|