@epam/ai-dial-skills 1.2.0-dev.174 → 1.2.0-dev.181

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.
@@ -0,0 +1,11 @@
1
+ import { CatalogContentFileTreeRenderProps } from '@epam/ai-dial-catalog';
2
+ import { FC } from 'react';
3
+ /**
4
+ * The skill details panel's Content-tab file tree, drawn with the file
5
+ * manager's `DialFoldersTree` so it matches the skill editor's tree. It is
6
+ * read-only — no context menu, no rename — and fully controlled by the
7
+ * catalog's `DetailsPanel`: expansion changes are reported back one folder
8
+ * at a time through `onToggleFolder`.
9
+ */
10
+ export declare const SkillContentFileTree: FC<CatalogContentFileTreeRenderProps>;
11
+ //# sourceMappingURL=SkillContentFileTree.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SkillContentFileTree.d.ts","sourceRoot":"","sources":["../../../src/components/SkillContentFileTree/SkillContentFileTree.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,uBAAuB,CAAC;AAM/E,OAAO,EAAE,KAAK,EAAE,EAAW,MAAM,OAAO,CAAC;AAGzC;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB,EAAE,EAAE,CAAC,iCAAiC,CA2CtE,CAAC"}
@@ -4,7 +4,8 @@ import { SkillDetailsSidePanelProps } from '../../models/skill-details-side-pane
4
4
  * Right-anchored side panel showing one skill's details, composed from
5
5
  * `@epam/ai-dial-catalog`'s `DetailsPanel` — the skills-scoped composition
6
6
  * point for hosts that surface skill details outside the Catalog page,
7
- * without its page chrome.
7
+ * without its page chrome. The Content tab's file selector renders the file
8
+ * manager's folders tree, the same tree the skill editor shows.
8
9
  */
9
10
  export declare const SkillDetailsSidePanel: FC<SkillDetailsSidePanelProps>;
10
11
  //# sourceMappingURL=SkillDetailsSidePanel.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SkillDetailsSidePanel.d.ts","sourceRoot":"","sources":["../../../src/components/SkillDetailsSidePanel/SkillDetailsSidePanel.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAChC,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,6CAA6C,CAAC;AAE9F;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,EAAE,EAAE,CAAC,0BAA0B,CAEjC,CAAC"}
1
+ {"version":3,"file":"SkillDetailsSidePanel.d.ts","sourceRoot":"","sources":["../../../src/components/SkillDetailsSidePanel/SkillDetailsSidePanel.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAChC,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,6CAA6C,CAAC;AAG9F;;;;;;GAMG;AACH,eAAO,MAAM,qBAAqB,EAAE,EAAE,CAAC,0BAA0B,CAShE,CAAC"}
package/index.d.ts CHANGED
@@ -2,6 +2,7 @@ export { ChatSkill } from './components/ChatSkill/ChatSkill';
2
2
  export { FavoriteSkillsPanel } from './components/FavoriteSkillsPanel/FavoriteSkillsPanel';
3
3
  export { SkillArchiveUploadDialog } from './components/SkillArchiveUploadDialog/SkillArchiveUploadDialog';
4
4
  export { SkillCatalogModal } from './components/SkillCatalogModal/SkillCatalogModal';
5
+ export { SkillContentFileTree } from './components/SkillContentFileTree/SkillContentFileTree';
5
6
  export { SkillDetailsSidePanel } from './components/SkillDetailsSidePanel/SkillDetailsSidePanel';
6
7
  export { SkillInfoTooltipContent } from './components/SkillInfoTooltipContent/SkillInfoTooltipContent';
7
8
  export { useSkillMentions } from './hooks/useSkillMentions/useSkillMentions';
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,sDAAsD,CAAC;AAC3F,OAAO,EAAE,wBAAwB,EAAE,MAAM,gEAAgE,CAAC;AAC1G,OAAO,EAAE,iBAAiB,EAAE,MAAM,kDAAkD,CAAC;AACrF,OAAO,EAAE,qBAAqB,EAAE,MAAM,0DAA0D,CAAC;AACjG,OAAO,EAAE,uBAAuB,EAAE,MAAM,8DAA8D,CAAC;AACvG,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAC7E,OAAO,EAAE,uBAAuB,EAAE,MAAM,yDAAyD,CAAC;AAClG,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,YAAY,EACZ,gBAAgB,GACjB,MAAM,gCAAgC,CAAC;AACxC,YAAY,EACV,uBAAuB,EACvB,eAAe,EACf,cAAc,GACf,MAAM,2BAA2B,CAAC;AACnC,YAAY,EACV,iBAAiB,EACjB,iBAAiB,GAClB,MAAM,8BAA8B,CAAC;AACtC,YAAY,EACV,yBAAyB,EACzB,yBAAyB,EACzB,wBAAwB,GACzB,MAAM,sCAAsC,CAAC;AAC9C,YAAY,EACV,8BAA8B,EAC9B,6BAA6B,GAC9B,MAAM,4CAA4C,CAAC;AACpD,YAAY,EAAE,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AACjF,YAAY,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAC1F,YAAY,EAAE,4BAA4B,EAAE,MAAM,2CAA2C,CAAC;AAC9F,YAAY,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACxE,YAAY,EACV,+BAA+B,EAC/B,0BAA0B,EAC1B,8BAA8B,EAC9B,6BAA6B,GAC9B,MAAM,iCAAiC,CAAC;AACzC,YAAY,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AACxF,YAAY,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAC3E,YAAY,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,oDAAoD,CAAC;AACxF,YAAY,EACV,uBAAuB,EACvB,wBAAwB,EACxB,wBAAwB,GACzB,MAAM,qCAAqC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,sDAAsD,CAAC;AAC3F,OAAO,EAAE,wBAAwB,EAAE,MAAM,gEAAgE,CAAC;AAC1G,OAAO,EAAE,iBAAiB,EAAE,MAAM,kDAAkD,CAAC;AACrF,OAAO,EAAE,oBAAoB,EAAE,MAAM,wDAAwD,CAAC;AAC9F,OAAO,EAAE,qBAAqB,EAAE,MAAM,0DAA0D,CAAC;AACjG,OAAO,EAAE,uBAAuB,EAAE,MAAM,8DAA8D,CAAC;AACvG,OAAO,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAC;AAC7E,OAAO,EAAE,uBAAuB,EAAE,MAAM,yDAAyD,CAAC;AAClG,OAAO,EAAE,sBAAsB,EAAE,MAAM,8BAA8B,CAAC;AACtE,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,YAAY,EACZ,gBAAgB,GACjB,MAAM,gCAAgC,CAAC;AACxC,YAAY,EACV,uBAAuB,EACvB,eAAe,EACf,cAAc,GACf,MAAM,2BAA2B,CAAC;AACnC,YAAY,EACV,iBAAiB,EACjB,iBAAiB,GAClB,MAAM,8BAA8B,CAAC;AACtC,YAAY,EACV,yBAAyB,EACzB,yBAAyB,EACzB,wBAAwB,GACzB,MAAM,sCAAsC,CAAC;AAC9C,YAAY,EACV,8BAA8B,EAC9B,6BAA6B,GAC9B,MAAM,4CAA4C,CAAC;AACpD,YAAY,EAAE,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AACjF,YAAY,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAC1F,YAAY,EAAE,4BAA4B,EAAE,MAAM,2CAA2C,CAAC;AAC9F,YAAY,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACxE,YAAY,EACV,+BAA+B,EAC/B,0BAA0B,EAC1B,8BAA8B,EAC9B,6BAA6B,GAC9B,MAAM,iCAAiC,CAAC;AACzC,YAAY,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AACxF,YAAY,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAC3E,YAAY,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,oDAAoD,CAAC;AACxF,YAAY,EACV,uBAAuB,EACvB,wBAAwB,EACxB,wBAAwB,GACzB,MAAM,qCAAqC,CAAC"}
package/index.js CHANGED
@@ -3,13 +3,14 @@ import { BASE_ICON_SIZE as i, Button as a, ButtonAppearance as o, ButtonVariant
3
3
  import { Suspense as x, useCallback as S, useEffect as C, useId as ee, useLayoutEffect as w, useMemo as T, useRef as E, useState as D } from "react";
4
4
  import { IconBlocks as O, IconChevronDown as te, IconEye as ne, IconStarFilled as k, IconX as re } from "@tabler/icons-react";
5
5
  import { Fragment as A, jsx as j, jsxs as M } from "react/jsx-runtime";
6
- import { DetailsPanel as N } from "@epam/ai-dial-catalog";
6
+ import { DialFileNodeType as N, DialFoldersTree as P } from "@epam/ai-dial-react-file-manager";
7
+ import { CatalogContentNodeType as F, DetailsPanel as I } from "@epam/ai-dial-catalog";
7
8
  //#region src/constants/public-class-names.ts
8
- var P = {
9
+ var L = {
9
10
  selectorField: "dial-skills-selector-field",
10
11
  favoritesPanel: "dial-skills-favorites-panel",
11
12
  chip: "dial-skills-chip"
12
- }, F = ({ description: e, unsupportedMessage: t, viewDetailsLabel: n = "View details", onViewDetails: r, viewDetailsTabIndex: i }) => t == null ? /* @__PURE__ */ M("div", {
13
+ }, R = ({ description: e, unsupportedMessage: t, viewDetailsLabel: n = "View details", onViewDetails: r, viewDetailsTabIndex: i }) => t == null ? /* @__PURE__ */ M("div", {
13
14
  className: "flex flex-col gap-3",
14
15
  children: [e != null && e !== "" && /* @__PURE__ */ j("p", {
15
16
  className: "text-start",
@@ -30,7 +31,7 @@ var P = {
30
31
  }) : /* @__PURE__ */ j("p", {
31
32
  className: "text-start",
32
33
  children: t
33
- }), I = ({ name: e, path: t, description: n, isUnsupported: i = !1, labelClassName: a = "dial-body-paragraph-text text-accent", unsupportedLabelClassName: o = "text-error", unsupportedClassName: s = "bg-error", detailsTrigger: c = "hover", onViewDetails: l, labels: u = {} }) => {
34
+ }), z = ({ name: e, path: t, description: n, isUnsupported: i = !1, labelClassName: a = "dial-body-paragraph-text text-accent", unsupportedLabelClassName: o = "text-error", unsupportedClassName: s = "bg-error", detailsTrigger: c = "hover", onViewDetails: l, labels: u = {} }) => {
34
35
  let { viewDetailsLabel: d = "View details", unsupportedTooltipLabel: f = "Selected model does not support skills. Remove the skill or select different model to proceed." } = u, [p, m] = D(0), [g, _] = D(!1), v = c === "click", y = () => {
35
36
  _(!1), m((e) => e + 1), l(t);
36
37
  }, x = (e) => {
@@ -44,14 +45,14 @@ var P = {
44
45
  open: v ? g : void 0,
45
46
  onOpenChange: v ? _ : void 0,
46
47
  contentClassName: "max-w-[550px]",
47
- content: i ? /* @__PURE__ */ j(F, { unsupportedMessage: f }) : /* @__PURE__ */ j(F, {
48
+ content: i ? /* @__PURE__ */ j(R, { unsupportedMessage: f }) : /* @__PURE__ */ j(R, {
48
49
  description: n,
49
50
  viewDetailsLabel: d,
50
51
  onViewDetails: y
51
52
  }),
52
53
  children: /* @__PURE__ */ M("span", {
53
54
  tabIndex: 0,
54
- className: r("relative -me-1 -ms-1 inline-block cursor-pointer select-text rounded-full pe-1 ps-1", i ? s : "hover:bg-info focus-visible:bg-info active:bg-info", i ? r(a, o) : a, P.chip),
55
+ className: r("relative -me-1 -ms-1 inline-block cursor-pointer select-text rounded-full pe-1 ps-1", i ? s : "hover:bg-info focus-visible:bg-info active:bg-info", i ? r(a, o) : a, L.chip),
55
56
  "aria-label": `/${e}`,
56
57
  onClick: v ? () => _(!0) : void 0,
57
58
  onKeyDown: x,
@@ -68,7 +69,7 @@ var P = {
68
69
  })]
69
70
  })
70
71
  }, p);
71
- }, L = {
72
+ }, B = {
72
73
  row: "_row_1v431_1",
73
74
  header: "_header_1v431_8",
74
75
  emptyHint: "_emptyHint_1v431_12",
@@ -79,65 +80,65 @@ var P = {
79
80
  rowLeaving: "_rowLeaving_1v431_32",
80
81
  rowFadeOut: "_rowFadeOut_1v431_1",
81
82
  listContent: "_listContent_1v431_60"
82
- }, R = "px-3 pb-0.5 pt-2", ie = 180, z = 288, B = ({ favorites: n, onSelect: i, onToggleFavorite: a, onBrowse: o, onViewDetails: s, className: l, rowClassName: u, searchQuery: d, listboxId: m, activeOptionId: g, isMenu: _ = !1, labels: v = {}, colors: b, nameClassName: x = "dial-small-text", headerClassName: S = "dial-tiny-lead-semi-text", emptyHintClassName: T = "dial-small-text" }) => {
83
- let { myCollectionLabel: O = "My Collection", emptyHintLabel: te = "Star a skill to pin it here", browseLabel: ne = "Browse", removeFromFavoritesLabel: re = "Remove from favorites", viewDetailsLabel: A = "View details", noMatchingSkillsLabel: N = "No matching skills" } = v, I = t({
83
+ }, V = "px-3 pb-0.5 pt-2", H = 180, U = 288, W = ({ favorites: n, onSelect: i, onToggleFavorite: a, onBrowse: o, onViewDetails: s, className: l, rowClassName: u, searchQuery: d, listboxId: m, activeOptionId: g, isMenu: _ = !1, labels: v = {}, colors: b, nameClassName: x = "dial-small-text", headerClassName: S = "dial-tiny-lead-semi-text", emptyHintClassName: T = "dial-small-text" }) => {
84
+ let { myCollectionLabel: O = "My Collection", emptyHintLabel: te = "Star a skill to pin it here", browseLabel: ne = "Browse", removeFromFavoritesLabel: re = "Remove from favorites", viewDetailsLabel: A = "View details", noMatchingSkillsLabel: N = "No matching skills" } = v, P = t({
84
85
  "--fs-row-hover-bg": b?.rowHoverBackground,
85
86
  "--fs-header-text": b?.headerText,
86
87
  "--fs-empty-hint-text": b?.emptyHintText,
87
88
  "--fs-star-color": b?.starColor,
88
89
  "--fs-footer-border": b?.footerBorder
89
- }), [B, V] = D(/* @__PURE__ */ new Set()), H = E(/* @__PURE__ */ new Map());
90
+ }), [F, I] = D(/* @__PURE__ */ new Set()), z = E(/* @__PURE__ */ new Map());
90
91
  C(() => {
91
- let e = H.current;
92
+ let e = z.current;
92
93
  return () => {
93
94
  e.forEach((e) => clearTimeout(e)), e.clear();
94
95
  };
95
96
  }, []);
96
- let U = m != null, W = _ && !U, G = U || W ? "none" : void 0, K = "button";
97
- U ? K = "option" : W && (K = "menuitem");
98
- let q = ee(), J = d != null, Y = d?.toLowerCase() ?? "", X = J ? n.filter((e) => e.name.toLowerCase().includes(Y)) : n, Z = E(null), [ae, Q] = D();
97
+ let W = m != null, G = _ && !W, K = W || G ? "none" : void 0, q = "button";
98
+ W ? q = "option" : G && (q = "menuitem");
99
+ let J = ee(), Y = d != null, X = d?.toLowerCase() ?? "", Z = Y ? n.filter((e) => e.name.toLowerCase().includes(X)) : n, Q = E(null), [ie, ae] = D();
99
100
  w(() => {
100
- Z.current && Q(Math.min(Z.current.scrollHeight, z));
101
+ Q.current && ae(Math.min(Q.current.scrollHeight, U));
101
102
  }, [n, d]);
102
103
  let oe = (e, t) => {
103
104
  e.target === e.currentTarget && (e.key === "Enter" || e.key === " ") && (e.preventDefault(), i(t));
104
- }, $ = (e) => {
105
- V((t) => new Set(t).add(e));
105
+ }, se = (e) => {
106
+ I((t) => new Set(t).add(e));
106
107
  let t = setTimeout(() => {
107
- a?.(e), V((t) => {
108
+ a?.(e), I((t) => {
108
109
  let n = new Set(t);
109
110
  return n.delete(e), n;
110
- }), H.current.delete(e);
111
- }, ie);
112
- H.current.set(e, t);
111
+ }), z.current.delete(e);
112
+ }, H);
113
+ z.current.set(e, t);
113
114
  };
114
115
  return /* @__PURE__ */ M("div", {
115
- className: r("flex w-full flex-col desktop:w-[280px]", l, P.favoritesPanel),
116
- style: I,
116
+ className: r("flex w-full flex-col desktop:w-[280px]", l, L.favoritesPanel),
117
+ style: P,
117
118
  children: [
118
119
  /* @__PURE__ */ j("p", {
119
- id: q,
120
- className: r(S, R, L.header),
120
+ id: J,
121
+ className: r(S, V, B.header),
121
122
  children: O
122
123
  }),
123
124
  /* @__PURE__ */ j("div", {
124
- className: r("max-h-72 min-h-0 flex-1 overflow-y-auto", L.listContent),
125
- style: { maxHeight: ae },
125
+ className: r("max-h-72 min-h-0 flex-1 overflow-y-auto", B.listContent),
126
+ style: { maxHeight: ie },
126
127
  children: /* @__PURE__ */ j("div", {
127
- ref: Z,
128
- children: X.length > 0 ? /* @__PURE__ */ j("ul", {
128
+ ref: Q,
129
+ children: Z.length > 0 ? /* @__PURE__ */ j("ul", {
129
130
  id: m,
130
- role: U ? "listbox" : G,
131
- "aria-labelledby": U ? q : void 0,
131
+ role: W ? "listbox" : K,
132
+ "aria-labelledby": W ? J : void 0,
132
133
  className: "flex flex-col gap-1 px-1 pb-1",
133
- children: X.map((t) => {
134
- let n = U ? `${m}-${encodeURIComponent(t.id)}` : void 0, o = U ? -1 : void 0, l = /* @__PURE__ */ M("div", {
135
- role: K,
134
+ children: Z.map((t) => {
135
+ let n = W ? `${m}-${encodeURIComponent(t.id)}` : void 0, o = W ? -1 : void 0, l = /* @__PURE__ */ M("div", {
136
+ role: q,
136
137
  id: n,
137
- "aria-selected": U ? n === g : void 0,
138
+ "aria-selected": W ? n === g : void 0,
138
139
  "aria-label": t.name,
139
140
  tabIndex: 0,
140
- className: r("flex cursor-pointer items-center gap-2 rounded-lg border border-transparent px-2 py-1.5 transition-colors", L.row, u),
141
+ className: r("flex cursor-pointer items-center gap-2 rounded-lg border border-transparent px-2 py-1.5 transition-colors", B.row, u),
141
142
  onClick: () => i(t),
142
143
  onKeyDown: (e) => oe(e, t),
143
144
  children: [
@@ -157,25 +158,25 @@ var P = {
157
158
  a && /* @__PURE__ */ j(y, {
158
159
  icon: /* @__PURE__ */ j(k, {
159
160
  size: c.SM,
160
- className: L.star,
161
+ className: B.star,
161
162
  "aria-hidden": !0
162
163
  }),
163
164
  "aria-label": re,
164
165
  isSelected: !0,
165
166
  tabIndex: o,
166
167
  onClick: (e) => {
167
- e.stopPropagation(), $(t.id);
168
+ e.stopPropagation(), se(t.id);
168
169
  }
169
170
  })
170
171
  ]
171
172
  });
172
173
  return /* @__PURE__ */ j("li", {
173
- role: G,
174
- className: B.has(t.id) ? L.rowLeaving : L.rowEnter,
174
+ role: K,
175
+ className: F.has(t.id) ? B.rowLeaving : B.rowEnter,
175
176
  children: s ? /* @__PURE__ */ j(h, {
176
177
  asChild: !0,
177
178
  contentClassName: "max-w-[550px]",
178
- content: /* @__PURE__ */ j(F, {
179
+ content: /* @__PURE__ */ j(R, {
179
180
  description: t.description,
180
181
  viewDetailsLabel: A,
181
182
  onViewDetails: () => s(t),
@@ -185,21 +186,21 @@ var P = {
185
186
  }) : l
186
187
  }, t.id);
187
188
  })
188
- }) : J && Y !== "" ? /* @__PURE__ */ j("p", {
189
+ }) : Y && X !== "" ? /* @__PURE__ */ j("p", {
189
190
  role: "status",
190
191
  "aria-live": "polite",
191
- className: r(T, "px-4 py-4 text-start", L.emptyHint),
192
+ className: r(T, "px-4 py-4 text-start", B.emptyHint),
192
193
  children: N
193
194
  }) : /* @__PURE__ */ j("p", {
194
- className: r(T, "px-4 py-4 text-start", L.emptyHint),
195
+ className: r(T, "px-4 py-4 text-start", B.emptyHint),
195
196
  children: te
196
197
  })
197
198
  })
198
199
  }),
199
200
  /* @__PURE__ */ j("div", {
200
- className: r("border-t px-2 py-3", L.footer),
201
+ className: r("border-t px-2 py-3", B.footer),
201
202
  children: /* @__PURE__ */ j(f, {
202
- role: W ? "menuitem" : void 0,
203
+ role: G ? "menuitem" : void 0,
203
204
  label: ne,
204
205
  className: "w-full justify-center",
205
206
  onClick: o
@@ -207,7 +208,7 @@ var P = {
207
208
  })
208
209
  ]
209
210
  });
210
- }, V = ".zip,.md", H = ({ isOpen: e, errorText: t, accept: n = V, labels: r, onClose: i, onFilesSelected: a, onFilesRejected: o }) => {
211
+ }, G = ".zip,.md", K = ({ isOpen: e, errorText: t, accept: n = G, labels: r, onClose: i, onFilesSelected: a, onFilesRejected: o }) => {
211
212
  let { dialogTitle: s = "Upload skill", dropZoneLabel: c = "Drag and drop it or click here to upload", dropZoneMobileLabel: l = "Click here to upload", formatsLabel: u = "File formats .zip and SKILL.md", fileInputAriaLabel: f = "Upload a skill ZIP archive or a SKILL.md file", closeAriaLabel: p = "Close" } = r ?? {};
212
213
  return /* @__PURE__ */ j(g, {
213
214
  open: e,
@@ -234,7 +235,7 @@ var P = {
234
235
  })
235
236
  })
236
237
  });
237
- }, U = ({ isOpen: e, onClose: t, onSelect: n, title: r, renderContent: i }) => /* @__PURE__ */ j(g, {
238
+ }, q = ({ isOpen: e, onClose: t, onSelect: n, title: r, renderContent: i }) => /* @__PURE__ */ j(g, {
238
239
  open: e,
239
240
  header: r,
240
241
  size: _.Lg,
@@ -247,7 +248,39 @@ var P = {
247
248
  children: e && i(n, t)
248
249
  })
249
250
  })
250
- }), W = (e) => /* @__PURE__ */ j(N, { ...e }), G = (e) => e == null || /[\s/]/.test(e), K = (e, t, n) => {
251
+ }), J = (e, t = null) => e.map((e) => e.type === F.Folder ? {
252
+ path: e.id,
253
+ name: e.name,
254
+ nodeType: N.FOLDER,
255
+ parentPath: t,
256
+ folderId: e.id,
257
+ items: J(e.items, e.id)
258
+ } : {
259
+ path: e.id,
260
+ name: e.name,
261
+ nodeType: N.ITEM,
262
+ parentPath: t,
263
+ folderId: t ?? ""
264
+ }), Y = ({ nodes: e, selectedFileId: t, expandedFolderIds: n, onToggleFolder: r, onSelectFile: i, onClose: a, ariaLabel: o }) => /* @__PURE__ */ j(P, {
265
+ items: T(() => J(e), [e]),
266
+ showFiles: !0,
267
+ areHiddenFilesVisible: !0,
268
+ selectedPath: t,
269
+ expandedPaths: T(() => new Set(n), [n]),
270
+ onExpandedPathsChange: (e) => {
271
+ for (let t of e) n.has(t) || r(t);
272
+ for (let t of n) e.has(t) || r(t);
273
+ },
274
+ onItemClick: (e) => {
275
+ e.nodeType === N.ITEM && i(e.path);
276
+ },
277
+ ariaLabel: o,
278
+ autoFocus: !0,
279
+ onEscape: a
280
+ }), X = (e) => /* @__PURE__ */ j(I, {
281
+ ...e,
282
+ renderContentFileTree: (e) => /* @__PURE__ */ j(Y, { ...e })
283
+ }), Z = (e) => e == null || /[\s/]/.test(e), Q = (e, t, n) => {
251
284
  let r = [], i = 0;
252
285
  return t.forEach((t, a) => {
253
286
  let o = `/${n(t.url)}`, s = i;
@@ -255,7 +288,7 @@ var P = {
255
288
  let t = e.indexOf(o, s);
256
289
  if (t === -1) return;
257
290
  let n = t + o.length;
258
- if (G(e[n])) {
291
+ if (Z(e[n])) {
259
292
  r.push({
260
293
  skillIndex: a,
261
294
  start: t,
@@ -266,7 +299,7 @@ var P = {
266
299
  s = t + 1;
267
300
  }
268
301
  }), r;
269
- }, q = (e, t) => {
302
+ }, ie = (e, t) => {
270
303
  let n = Math.min(e.length, t.length), r = 0;
271
304
  for (; r < n && e[r] === t[r];) r += 1;
272
305
  let i = n - r, a = 0;
@@ -276,13 +309,13 @@ var P = {
276
309
  deletedLength: e.length - r - a,
277
310
  insertedLength: t.length - r - a
278
311
  };
279
- }, J = (e, t) => {
312
+ }, ae = (e, t) => {
280
313
  let n = t.start + t.deletedLength, r = t.insertedLength - t.deletedLength;
281
314
  return e.reduce((e, i) => i.start + i.length <= t.start ? (e.push(i), e) : (i.start >= n && e.push({
282
315
  ...i,
283
316
  start: i.start + r
284
317
  }), e), []);
285
- }, Y = (e, t, n, r, i) => {
318
+ }, oe = (e, t, n, r, i) => {
286
319
  let a = r.length + 1, o = a + +!!i, s = e.map((e) => e.start >= t ? {
287
320
  ...e,
288
321
  start: e.start + o
@@ -293,7 +326,7 @@ var P = {
293
326
  length: a
294
327
  };
295
328
  return [...s, c].sort((e, t) => e.start - t.start);
296
- }, X = (e, t) => e.find((e) => e.start + e.length === t), Z = () => {
329
+ }, se = (e, t) => e.find((e) => e.start + e.length === t), ce = () => {
297
330
  let [e, t] = D(""), [n, r] = D([]), i = E(e);
298
331
  i.current = e;
299
332
  let a = E(n);
@@ -301,14 +334,14 @@ var P = {
301
334
  draft: e,
302
335
  anchors: n,
303
336
  onDraftChange: S((e) => {
304
- let n = q(i.current, e);
305
- r((e) => J(e, n)), i.current = e, t(e);
337
+ let n = ie(i.current, e);
338
+ r((e) => ae(e, n)), i.current = e, t(e);
306
339
  }, []),
307
340
  insertMention: S((e, n, a) => {
308
341
  let o = i.current, s = !/^\s/.test(o.slice(a)), c = `/${n}${s ? " " : ""}`, l = o.slice(0, a) + c + o.slice(a);
309
- return i.current = l, t(l), r((t) => Y(t, a, e, n, s)), s;
342
+ return i.current = l, t(l), r((t) => oe(t, a, e, n, s)), s;
310
343
  }, []),
311
- onBackspaceAtCaret: S((e) => X(a.current, e), []),
344
+ onBackspaceAtCaret: S((e) => se(a.current, e), []),
312
345
  orderedSkills: T(() => {
313
346
  if (n.length !== 0) return n.map((e) => ({ url: e.url }));
314
347
  }, [n]),
@@ -316,7 +349,7 @@ var P = {
316
349
  t(""), r([]);
317
350
  }, []),
318
351
  seedFromMessage: S((e, n, i) => {
319
- let a = n ?? [], o = K(e, a, i);
352
+ let a = n ?? [], o = Q(e, a, i);
320
353
  t(e), r(o.map((e) => {
321
354
  let t = a[e.skillIndex];
322
355
  return {
@@ -328,15 +361,15 @@ var P = {
328
361
  }));
329
362
  }, [])
330
363
  };
331
- }, ae = (e) => ({
364
+ }, le = (e) => ({
332
365
  id: e.url,
333
366
  name: e.name,
334
367
  description: e.description
335
- }), Q = (e) => {
368
+ }), ue = (e) => {
336
369
  let t = e.split("/").filter((e) => e.length > 0);
337
370
  return t[t.length - 1] ?? e;
338
- }, oe = ({ isEnabled: e, isSkillsSupported: t, skills: n, sharedWithMe: r, publicSkills: a, favoriteIds: o, onToggleFavorite: s, labels: c, historyChipLabelClassName: u, activeMentionDetailsTrigger: d, renderCatalogContent: f, detailsPanelComponent: p }) => {
339
- let { addMenuLabel: m = "Skills", backLabel: h = "Back", catalogModalTitleLabel: g = "Use skill", emptyQueryHintLabel: _ = "Type to filter", panelLabels: v } = c ?? {}, y = e && t, [b, C] = D(!1), [ee, w] = D(null), [E, te] = D(0), [ne, k] = D(0), [re, A] = D(void 0), M = Z(), N = T(() => [
371
+ }, de = ({ isEnabled: e, isSkillsSupported: t, skills: n, sharedWithMe: r, publicSkills: a, favoriteIds: o, onToggleFavorite: s, labels: c, historyChipLabelClassName: u, activeMentionDetailsTrigger: d, renderCatalogContent: f, detailsPanelComponent: p }) => {
372
+ let { addMenuLabel: m = "Skills", backLabel: h = "Back", catalogModalTitleLabel: g = "Use skill", emptyQueryHintLabel: _ = "Type to filter", panelLabels: v } = c ?? {}, y = e && t, [b, C] = D(!1), [ee, w] = D(null), [E, te] = D(0), [ne, k] = D(0), [re, A] = D(void 0), M = ce(), N = T(() => [
340
373
  ...n,
341
374
  ...r ?? [],
342
375
  ...a ?? []
@@ -344,11 +377,11 @@ var P = {
344
377
  n,
345
378
  r,
346
379
  a
347
- ]), P = T(() => new Map(N.map((e) => [e.url, e])), [N]), F = S((e) => P.get(e)?.name ?? Q(e), [P]), L = T(() => N.filter((e) => o.has(e.url)).map((e) => ae(e)), [N, o]), R = M.anchors.length > 0 && !t, ie = T(() => M.anchors.map((e) => ({
380
+ ]), P = T(() => new Map(N.map((e) => [e.url, e])), [N]), F = S((e) => P.get(e)?.name ?? ue(e), [P]), I = T(() => N.filter((e) => o.has(e.url)).map((e) => le(e)), [N, o]), L = M.anchors.length > 0 && !t, R = T(() => M.anchors.map((e) => ({
348
381
  start: e.start,
349
382
  length: e.length,
350
383
  isUnsupported: !t,
351
- render: () => /* @__PURE__ */ j(I, {
384
+ render: () => /* @__PURE__ */ j(z, {
352
385
  name: e.name,
353
386
  path: e.url,
354
387
  labelClassName: u,
@@ -365,20 +398,20 @@ var P = {
365
398
  u,
366
399
  d,
367
400
  v
368
- ]), z = S((e, t, n) => {
401
+ ]), B = S((e, t, n) => {
369
402
  let r = M.insertMention(e, t, n);
370
403
  k((e) => e + 1), A(n + 1 + t.length + +!!r);
371
404
  }, [M]), V = S(() => {
372
405
  M.reset(), k((e) => e + 1), A(void 0);
373
406
  }, [M]), H = S((e, t) => {
374
407
  M.seedFromMessage(e, t, F), k((e) => e + 1), A(void 0);
375
- }, [M, F]), W = S((e, t) => {
408
+ }, [M, F]), U = S((e, t) => {
376
409
  if (t == null || t.length === 0) return null;
377
- let n = K(e, t, F), r = [], i = 0;
410
+ let n = Q(e, t, F), r = [], i = 0;
378
411
  return n.forEach((n) => {
379
412
  n.start > i && r.push(e.slice(i, n.start));
380
- let a = t[n.skillIndex], o = P.get(a.url), s = o?.name ?? Q(a.url);
381
- r.push(/* @__PURE__ */ j(I, {
413
+ let a = t[n.skillIndex], o = P.get(a.url), s = o?.name ?? ue(a.url);
414
+ r.push(/* @__PURE__ */ j(z, {
382
415
  name: s,
383
416
  path: a.url,
384
417
  labelClassName: u,
@@ -394,8 +427,8 @@ var P = {
394
427
  v
395
428
  ]), G = S((e) => e == null || e.length === 0 ? null : e.map((e) => {
396
429
  let t = P.get(e.url);
397
- return /* @__PURE__ */ j(I, {
398
- name: t?.name ?? Q(e.url),
430
+ return /* @__PURE__ */ j(z, {
431
+ name: t?.name ?? ue(e.url),
399
432
  path: e.url,
400
433
  labelClassName: u,
401
434
  description: t?.description,
@@ -406,11 +439,11 @@ var P = {
406
439
  P,
407
440
  u,
408
441
  v
409
- ]), q = S((e, t) => /* @__PURE__ */ j(B, {
410
- favorites: L,
442
+ ]), K = S((e, t) => /* @__PURE__ */ j(W, {
443
+ favorites: I,
411
444
  isMenu: !0,
412
445
  onSelect: (n) => {
413
- z(n.id, n.name, t), e();
446
+ B(n.id, n.name, t), e();
414
447
  },
415
448
  onToggleFavorite: s,
416
449
  onBrowse: () => {
@@ -421,8 +454,8 @@ var P = {
421
454
  },
422
455
  labels: v
423
456
  }), [
424
- L,
425
- z,
457
+ I,
458
+ B,
426
459
  s,
427
460
  v
428
461
  ]), J = T(() => y ? {
@@ -433,24 +466,24 @@ var P = {
433
466
  "aria-hidden": !0,
434
467
  stroke: l
435
468
  }),
436
- renderOverlay: q,
469
+ renderOverlay: K,
437
470
  backLabel: h
438
471
  } : void 0, [
439
472
  y,
440
473
  m,
441
474
  h,
442
- q
475
+ K
443
476
  ]), Y = T(() => y ? {
444
477
  triggerPrefix: "/",
445
478
  menuLabel: m,
446
479
  emptyQueryHint: _,
447
- renderMenu: ({ query: e, caretPosition: t, close: n, listboxId: r, activeOptionId: i }) => /* @__PURE__ */ j(B, {
448
- favorites: L,
480
+ renderMenu: ({ query: e, caretPosition: t, close: n, listboxId: r, activeOptionId: i }) => /* @__PURE__ */ j(W, {
481
+ favorites: I,
449
482
  searchQuery: e,
450
483
  listboxId: r,
451
484
  activeOptionId: i,
452
485
  onSelect: (e) => {
453
- n({ consumeQuery: !0 }), z(e.id, e.name, t);
486
+ n({ consumeQuery: !0 }), B(e.id, e.name, t);
454
487
  },
455
488
  onToggleFavorite: s,
456
489
  onBrowse: () => {
@@ -465,19 +498,19 @@ var P = {
465
498
  y,
466
499
  m,
467
500
  _,
468
- L,
469
- z,
501
+ I,
502
+ B,
470
503
  s,
471
504
  v
472
505
  ]);
473
506
  return e ? {
474
507
  skillMenuOverlay: J,
475
508
  commandMenu: Y,
476
- skillCatalogModal: /* @__PURE__ */ j(U, {
509
+ skillCatalogModal: /* @__PURE__ */ j(q, {
477
510
  isOpen: b,
478
511
  onClose: () => C(!1),
479
512
  onSelect: (e) => {
480
- z(e, F(e), E), C(!1);
513
+ B(e, F(e), E), C(!1);
481
514
  },
482
515
  title: g,
483
516
  renderContent: f
@@ -491,15 +524,15 @@ var P = {
491
524
  }),
492
525
  message: M.draft,
493
526
  messageRevision: ne,
494
- activeMentions: ie,
527
+ activeMentions: R,
495
528
  onDraftChange: M.onDraftChange,
496
529
  onBackspaceAtCaret: M.onBackspaceAtCaret,
497
530
  caretPositionOverride: re,
498
- isSkillUnsupported: R,
531
+ isSkillUnsupported: L,
499
532
  selectedSkills: M.orderedSkills,
500
533
  resetSkillMentions: V,
501
534
  seedSkillMentions: H,
502
- renderHistorySkillSegments: W,
535
+ renderHistorySkillSegments: U,
503
536
  renderHistorySkills: G
504
537
  } : {
505
538
  skillMenuOverlay: void 0,
@@ -525,18 +558,18 @@ var P = {
525
558
  value: "_value_14zdf_9",
526
559
  clear: "_clear_14zdf_13",
527
560
  invalid: "_invalid_14zdf_17"
528
- }, se = [], ce = ({ value: e, onChange: i, displayName: a, favorites: o = se, onToggleFavorite: s, onViewDetails: c, renderOverlay: d, isSkillsSupported: p, isDisabled: h = !1, isInvalid: g = !1, labelledById: _, describedById: y, labels: b, renderCatalogContent: x, className: S, styles: w }) => {
529
- let [T, O] = D(!1), [ne, k] = D(!1), [N, F] = D(""), I = E(null), L = ee(), R = E(null), ie = E(!1), z = n(e, p), V = p && !h, H = T && V, W = ne && V, G = () => {
530
- R.current && !R.current.disabled ? R.current.focus() : I.current?.querySelector("button:not(:disabled)")?.focus();
561
+ }, fe = [], pe = ({ value: e, onChange: i, displayName: a, favorites: o = fe, onToggleFavorite: s, onViewDetails: c, renderOverlay: d, isSkillsSupported: p, isDisabled: h = !1, isInvalid: g = !1, labelledById: _, describedById: y, labels: b, renderCatalogContent: x, className: S, styles: w }) => {
562
+ let [T, O] = D(!1), [ne, k] = D(!1), [N, P] = D(""), F = E(null), I = ee(), R = E(null), z = E(!1), B = n(e, p), V = p && !h, H = T && V, U = ne && V, G = () => {
563
+ R.current && !R.current.disabled ? R.current.focus() : F.current?.querySelector("button:not(:disabled)")?.focus();
531
564
  };
532
565
  C(() => {
533
- ie.current && !H && !W && ((document.activeElement === document.body || I.current?.contains(document.activeElement)) && G(), O(!1), k(!1)), ie.current = H || W;
534
- }, [H, W]);
566
+ z.current && !H && !U && ((document.activeElement === document.body || F.current?.contains(document.activeElement)) && G(), O(!1), k(!1)), z.current = H || U;
567
+ }, [H, U]);
535
568
  let K = (e) => {
536
- e && !V || (F(""), O(e));
537
- }, q = (e) => {
569
+ e && !V || (P(""), O(e));
570
+ }, J = (e) => {
538
571
  V && i(e), O(!1), k(!1);
539
- }, J = {
572
+ }, Y = {
540
573
  ...t({
541
574
  "--ssf-text": w?.colors?.text,
542
575
  "--ssf-bg": w?.colors?.background,
@@ -544,25 +577,25 @@ var P = {
544
577
  "--ssf-error": w?.colors?.error
545
578
  }),
546
579
  ...w?.cssVars
547
- }, Y = /* @__PURE__ */ M("div", {
548
- id: L,
580
+ }, X = /* @__PURE__ */ M("div", {
581
+ id: I,
549
582
  className: "w-full min-w-0",
550
583
  children: [/* @__PURE__ */ j("div", {
551
584
  className: "p-2",
552
585
  children: /* @__PURE__ */ j(v, {
553
586
  value: N,
554
- onChange: (e) => F(e ?? ""),
587
+ onChange: (e) => P(e ?? ""),
555
588
  placeholder: b.searchPlaceholder ?? "Search skills",
556
589
  "aria-label": b.searchPlaceholder ?? "Search skills",
557
590
  clearLabel: b.clearSearchLabel ?? "Clear search"
558
591
  })
559
- }), /* @__PURE__ */ j(B, {
592
+ }), /* @__PURE__ */ j(W, {
560
593
  className: "min-w-0 desktop:w-full",
561
594
  rowClassName: "min-h-11",
562
595
  favorites: o,
563
596
  searchQuery: N,
564
597
  labels: b.panelLabels,
565
- onSelect: (e) => q(e.id),
598
+ onSelect: (e) => J(e.id),
566
599
  onToggleFavorite: s,
567
600
  onViewDetails: c ? (e) => {
568
601
  O(!1), c(e);
@@ -571,24 +604,24 @@ var P = {
571
604
  O(!1), k(!0);
572
605
  }
573
606
  })]
574
- }), X = /* @__PURE__ */ j(m, {
607
+ }), Z = /* @__PURE__ */ j(m, {
575
608
  inputRef: R,
576
609
  readOnly: !0,
577
610
  role: "combobox",
578
611
  "aria-haspopup": "dialog",
579
612
  "aria-expanded": H,
580
- "aria-controls": H ? L : void 0,
613
+ "aria-controls": H ? I : void 0,
581
614
  "aria-labelledby": _,
582
615
  "aria-describedby": y,
583
- "aria-invalid": g || z,
616
+ "aria-invalid": g || B,
584
617
  disabled: !V,
585
- invalid: g || z,
618
+ invalid: g || B,
586
619
  value: e ? a || e : "",
587
620
  placeholder: b.placeholder,
588
621
  title: p ? e ? a || e : void 0 : b.unsupportedTooltipLabel,
589
622
  containerClassName: "w-full min-w-0",
590
- wrapperClassName: r("cursor-pointer", "--ssf-bg" in J && $.background, "--ssf-border" in J && $.border, (g || z) && $.invalid, w?.triggerClassName),
591
- className: r("min-w-0 cursor-pointer text-ellipsis", "--ssf-text" in J && $.value, w?.typography?.fontClassName ?? "dial-small-text"),
623
+ wrapperClassName: r("cursor-pointer", "--ssf-bg" in Y && $.background, "--ssf-border" in Y && $.border, (g || B) && $.invalid, w?.triggerClassName),
624
+ className: r("min-w-0 cursor-pointer text-ellipsis", "--ssf-text" in Y && $.value, w?.typography?.fontClassName ?? "dial-small-text"),
592
625
  onKeyDown: (e) => {
593
626
  [
594
627
  "Enter",
@@ -605,7 +638,7 @@ var P = {
605
638
  "aria-label": b.removeSkillLabel,
606
639
  onKeyDown: (e) => e.stopPropagation(),
607
640
  onClick: (e) => {
608
- e.stopPropagation(), i(void 0), O(!1), V ? R.current?.focus() : I.current?.focus();
641
+ e.stopPropagation(), i(void 0), O(!1), V ? R.current?.focus() : F.current?.focus();
609
642
  },
610
643
  iconBefore: /* @__PURE__ */ j(re, {
611
644
  "aria-hidden": !0,
@@ -621,17 +654,17 @@ var P = {
621
654
  })
622
655
  });
623
656
  return /* @__PURE__ */ M("div", {
624
- ref: I,
657
+ ref: F,
625
658
  role: "group",
626
659
  "aria-labelledby": _,
627
660
  tabIndex: -1,
628
- className: r("min-w-0", S, P.selectorField),
629
- style: J,
661
+ className: r("min-w-0", S, L.selectorField),
662
+ style: Y,
630
663
  children: [d ? /* @__PURE__ */ M(A, { children: [/* @__PURE__ */ j("div", {
631
664
  className: "w-full min-w-0",
632
665
  onClick: () => K(!H),
633
- children: X
634
- }), d(Y, H, () => K(!1))] }) : /* @__PURE__ */ j(u, {
666
+ children: Z
667
+ }), d(X, H, () => K(!1))] }) : /* @__PURE__ */ j(u, {
635
668
  open: H,
636
669
  onOpenChange: K,
637
670
  disabled: !V,
@@ -640,18 +673,18 @@ var P = {
640
673
  renderOverlay: () => /* @__PURE__ */ j("div", {
641
674
  role: "dialog",
642
675
  "aria-labelledby": _,
643
- children: Y
676
+ children: X
644
677
  }),
645
678
  initialFocus: 0,
646
- children: X
647
- }), W && /* @__PURE__ */ j(U, {
679
+ children: Z
680
+ }), U && /* @__PURE__ */ j(q, {
648
681
  isOpen: !0,
649
682
  onClose: () => k(!1),
650
683
  title: b.modalTitle,
651
- onSelect: q,
684
+ onSelect: J,
652
685
  renderContent: x
653
686
  })]
654
687
  });
655
688
  };
656
689
  //#endregion
657
- export { I as ChatSkill, B as FavoriteSkillsPanel, P as SKILLS_CLASS, H as SkillArchiveUploadDialog, U as SkillCatalogModal, W as SkillDetailsSidePanel, F as SkillInfoTooltipContent, ce as SkillSelectorField, ae as buildFavoriteSkillItem, q as diffTextChange, X as findMentionAtCaret, Q as getSkillFallbackName, Y as insertAnchor, K as matchSkillMentions, J as reconcileAnchors, Z as useSkillMentions, oe as useSkillSelectorOverlay };
690
+ export { z as ChatSkill, W as FavoriteSkillsPanel, L as SKILLS_CLASS, K as SkillArchiveUploadDialog, q as SkillCatalogModal, Y as SkillContentFileTree, X as SkillDetailsSidePanel, R as SkillInfoTooltipContent, pe as SkillSelectorField, le as buildFavoriteSkillItem, ie as diffTextChange, se as findMentionAtCaret, ue as getSkillFallbackName, oe as insertAnchor, Q as matchSkillMentions, ae as reconcileAnchors, ce as useSkillMentions, de as useSkillSelectorOverlay };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@epam/ai-dial-skills",
3
3
  "description": "Host-agnostic UI for picking a favorite skill to attach to a chat input",
4
- "version": "1.2.0-dev.174",
4
+ "version": "1.2.0-dev.181",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
7
7
  "main": "./index.js",
@@ -18,11 +18,12 @@
18
18
  },
19
19
  "dependencies": {
20
20
  "@tabler/icons-react": "^3.44.0",
21
- "@epam/ai-dial-catalog": "1.2.0-dev.174",
22
- "@epam/ai-dial-conversation-input": "1.2.0-dev.174"
21
+ "@epam/ai-dial-catalog": "1.2.0-dev.181",
22
+ "@epam/ai-dial-conversation-input": "1.2.0-dev.181"
23
23
  },
24
24
  "peerDependencies": {
25
- "@epam/ai-dial-chat-shared": "1.2.0-dev.174",
25
+ "@epam/ai-dial-chat-shared": "1.2.0-dev.181",
26
+ "@epam/ai-dial-react-file-manager": "^0.3.0-dev.15",
26
27
  "@epam/ai-dial-ui-kit": "^0.15.0-dev.21",
27
28
  "react": "^19.2.8"
28
29
  },
@@ -0,0 +1,10 @@
1
+ import { CatalogContentTreeNode } from '@epam/ai-dial-catalog';
2
+ import { DialFile } from '@epam/ai-dial-react-file-manager';
3
+ /**
4
+ * Maps the details panel's `CatalogContentTreeNode[]` onto the nested
5
+ * `DialFile[]` `DialFoldersTree` renders. A node's opaque `id` becomes the
6
+ * file's `path`, so the tree's `selectedPath` / `expandedPaths` /
7
+ * `onItemClick` speak the panel's ids unchanged — nothing is parsed.
8
+ */
9
+ export declare const mapCatalogContentTreeToDialFiles: (nodes: CatalogContentTreeNode[], parentPath?: string | null) => DialFile[];
10
+ //# sourceMappingURL=catalog-content-dial-files.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"catalog-content-dial-files.d.ts","sourceRoot":"","sources":["../../src/utils/catalog-content-dial-files.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAEpE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAEjE;;;;;GAKG;AACH,eAAO,MAAM,gCAAgC,GAC3C,OAAO,sBAAsB,EAAE,EAC/B,aAAY,MAAM,GAAG,IAAW,KAC/B,QAAQ,EAkBR,CAAC"}