@epam/ai-dial-catalog 1.2.0-dev.288 → 1.2.0-dev.300
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/CardGrid/Card.d.ts.map +1 -1
- package/components/CardGrid/CardGrid.d.ts.map +1 -1
- package/components/CardGrid/CardRowRenderer.d.ts.map +1 -1
- package/components/Catalog/Catalog.d.ts.map +1 -1
- package/components/Details/Credentials/CredentialsManagementPanel/CredentialsManagementPanel.d.ts.map +1 -1
- package/components/Details/Credentials/CredentialsRow/CredentialsRow.d.ts +2 -0
- package/components/Details/Credentials/CredentialsRow/CredentialsRow.d.ts.map +1 -1
- package/components/Details/DetailsPanel.d.ts.map +1 -1
- package/components/Details/Header/CredentialsApiKeyOverlay/CredentialsApiKeyOverlay.d.ts +8 -1
- package/components/Details/Header/CredentialsApiKeyOverlay/CredentialsApiKeyOverlay.d.ts.map +1 -1
- package/components/Details/Header/Header.d.ts.map +1 -1
- package/components/Details/TabsContent/About.d.ts +3 -1
- package/components/Details/TabsContent/About.d.ts.map +1 -1
- package/components/Details/TabsContent/Content.d.ts +3 -1
- package/components/Details/TabsContent/Content.d.ts.map +1 -1
- package/index.css +1 -1
- package/index.js +1413 -1351
- package/models/card-props.d.ts +3 -0
- package/models/card-props.d.ts.map +1 -1
- package/models/card-row-data.d.ts +3 -0
- package/models/card-row-data.d.ts.map +1 -1
- package/models/grid-props.d.ts +3 -0
- package/models/grid-props.d.ts.map +1 -1
- package/models/item-details-props.d.ts +30 -2
- package/models/item-details-props.d.ts.map +1 -1
- package/package.json +4 -4
- package/utils/item-details-texts.d.ts +4 -0
- package/utils/item-details-texts.d.ts.map +1 -0
package/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { _ as e, a as t, b as n, c as r, d as i, f as a, g as o, h as s, i as c, l, m as u, n as d, o as f, p, r as m, s as h, t as g, u as _, v, x as y, y as b } from "./mapping-BHlCxGmC.js";
|
|
2
2
|
import { CatalogEntityType as x, ConfirmationFooter as S, ConfirmationView as C, DESKTOP_BREAKPOINT_PX as w, DeploymentIcon as T, EntityHeader as E, EntityTypeLabel as D, FeaturedChip as O, ItemHeader as ee, MarkdownCodeBlock as k, MarkdownRenderer as A, MarkdownWithPlaceholders as te, PanelEmptyState as ne, SELECT_LIST_MAX_HEIGHT_CLASS_NAME as re, buildCssVars as j, mergeClasses as M } from "@epam/ai-dial-chat-shared";
|
|
3
|
-
import { Fragment as ie, memo as
|
|
4
|
-
import { Badge as
|
|
5
|
-
import { IconAlertTriangleFilled as
|
|
3
|
+
import { Fragment as ie, memo as N, startTransition as ae, useCallback as P, useEffect as F, useId as oe, useLayoutEffect as se, useMemo as I, useRef as L, useState as R } from "react";
|
|
4
|
+
import { Badge as ce, Button as le, ButtonAppearance as ue, ButtonDropdown as de, ButtonVariant as fe, CardShell as pe, Checkbox as me, ConfirmationPopupVariant as he, DIAL_ICON_SIZE as z, DIAL_KIT_ICON_STROKE as B, DangerButton as ge, Dropdown as _e, DropdownItemType as ve, ElementSize as ye, EllipsisTooltip as be, FolderPath as xe, GhostButton as Se, GhostIconButton as V, Highlight as Ce, InlineSelect as we, InlineSelectTrigger as Te, Input as Ee, LinkButton as De, MenuItem as Oe, MenuItemMark as ke, NeutralButton as H, NeutralIconButton as U, PrimaryButton as Ae, ProgressBar as je, RadioGroup as Me, Search as Ne, SegmentedControl as Pe, SideDrawer as Fe, Skeleton as Ie, SkeletonAvatarShape as Le, Spinner as Re, Tabs as ze, ToggleIconButton as Be, Tooltip as Ve, mergeClasses as He } from "@epam/ai-dial-ui-kit";
|
|
5
|
+
import { IconAlertTriangleFilled as Ue, IconArrowRight as We, IconBuildingCommunity as Ge, IconCheck as Ke, IconChevronDown as qe, IconChevronLeft as Je, IconChevronRight as Ye, IconCircleCheckFilled as Xe, IconDots as Ze, IconDownload as Qe, IconFilter as $e, IconFolder as et, IconKey as tt, IconLayoutGrid as nt, IconLayoutList as rt, IconLogin as it, IconLogout as at, IconPencil as ot, IconPlayerPlayFilled as st, IconPlus as ct, IconShare as lt, IconStar as ut, IconStarFilled as dt, IconTrashX as W, IconUser as ft, IconUserOff as pt, IconWorldOff as mt, IconWorldShare as ht } from "@tabler/icons-react";
|
|
6
6
|
import { Fragment as gt, jsx as G, jsxs as K } from "react/jsx-runtime";
|
|
7
7
|
import { PublishFooter as _t, PublishPanel as vt, derivePublishState as yt, usePublishFlow as bt } from "@epam/ai-dial-publish-panel";
|
|
8
8
|
import { Grid as xt } from "@epam/ai-dial-ui-kit/grid";
|
|
@@ -26,8 +26,8 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
26
26
|
}({}), Q = /* @__PURE__ */ function(e) {
|
|
27
27
|
return e.Markdown = "markdown", e.Text = "text", e.Image = "image", e.Unsupported = "unsupported", e;
|
|
28
28
|
}({}), Tt = () => {
|
|
29
|
-
let [e, t] =
|
|
30
|
-
return
|
|
29
|
+
let [e, t] = R(() => window.innerWidth);
|
|
30
|
+
return F(() => {
|
|
31
31
|
let e = () => t(window.innerWidth);
|
|
32
32
|
return window.addEventListener("resize", e), () => window.removeEventListener("resize", e);
|
|
33
33
|
}, []), e >= 1024 ? 4 : e >= 640 ? 2 : 1;
|
|
@@ -37,28 +37,34 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
37
37
|
card: "dial-catalog-card",
|
|
38
38
|
favoriteCard: "dial-catalog-favorite-card",
|
|
39
39
|
listView: "dial-catalog-list-view"
|
|
40
|
-
}, Dt = (e) => {
|
|
40
|
+
}, Dt = (e) => ({
|
|
41
|
+
codeBlockCopyLabel: e?.copyCodeAriaLabel,
|
|
42
|
+
codeBlockCopiedLabel: e?.copiedCodeStatusLabel,
|
|
43
|
+
codeBlockDownloadLabel: e?.downloadCodeAriaLabel,
|
|
44
|
+
tableScrollRegionAriaLabel: e?.tableScrollRegionAriaLabel,
|
|
45
|
+
mathScrollRegionAriaLabel: e?.mathScrollRegionAriaLabel
|
|
46
|
+
}), Ot = (e) => {
|
|
41
47
|
let { colors: t } = e ?? {};
|
|
42
48
|
return j({
|
|
43
49
|
"--cat-bg": t?.background,
|
|
44
50
|
"--cat-heading-title-text": t?.headingTitleText
|
|
45
51
|
});
|
|
46
|
-
},
|
|
52
|
+
}, kt = 1180, At = (e) => e >= 1280 ? 4 : e >= 966 ? 3 : e >= 620 ? 2 : 1, jt = (e) => {
|
|
47
53
|
if (!e || e === document.body) return document.documentElement;
|
|
48
54
|
let { overflow: t, overflowY: n } = getComputedStyle(e);
|
|
49
|
-
return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e :
|
|
50
|
-
},
|
|
51
|
-
let r =
|
|
55
|
+
return t === "auto" || t === "scroll" || n === "auto" || n === "scroll" ? e : jt(e.parentElement);
|
|
56
|
+
}, Mt = 10, Nt = 10, Pt = 30, Ft = (e, t, n = Mt) => {
|
|
57
|
+
let r = L(null), [i, a] = R({
|
|
52
58
|
start: 0,
|
|
53
|
-
end:
|
|
59
|
+
end: Pt
|
|
54
60
|
});
|
|
55
|
-
|
|
61
|
+
F(() => {
|
|
56
62
|
let i = r.current;
|
|
57
63
|
if (!i) return;
|
|
58
|
-
let o =
|
|
64
|
+
let o = jt(i.parentElement), s = () => {
|
|
59
65
|
let r = o.clientHeight;
|
|
60
66
|
if (r === 0 || i.clientWidth === 0 || getComputedStyle(i).visibility === "hidden") return;
|
|
61
|
-
let s = i.getBoundingClientRect().top, c = o.getBoundingClientRect().top, l = Math.max(0, c - s), u = Math.floor(l / t), d = Math.ceil(r / t), f = Math.max(0, Math.floor((u - n) /
|
|
67
|
+
let s = i.getBoundingClientRect().top, c = o.getBoundingClientRect().top, l = Math.max(0, c - s), u = Math.floor(l / t), d = Math.ceil(r / t), f = Math.max(0, Math.floor((u - n) / Nt) * Nt), p = Math.min(e, Math.ceil((u + d + n) / Nt) * Nt);
|
|
62
68
|
a((e) => e.start === f && e.end === p ? e : {
|
|
63
69
|
start: f,
|
|
64
70
|
end: p
|
|
@@ -74,28 +80,28 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
74
80
|
t,
|
|
75
81
|
n
|
|
76
82
|
]);
|
|
77
|
-
let o = Math.max(0, Math.floor((e - 1) /
|
|
83
|
+
let o = Math.max(0, Math.floor((e - 1) / Nt) * Nt), s = Math.min(i.start, o);
|
|
78
84
|
return {
|
|
79
85
|
containerRef: r,
|
|
80
86
|
startRow: s,
|
|
81
|
-
endRow: Math.min(e, Math.max(i.end, s +
|
|
87
|
+
endRow: Math.min(e, Math.max(i.end, s + Nt))
|
|
82
88
|
};
|
|
83
|
-
},
|
|
84
|
-
let r =
|
|
85
|
-
let t = typeof window < "u" ? window.innerWidth : 1440, r = Math.max(0, t - (t >= w ? 60 : 0)), i =
|
|
89
|
+
}, It = (e, { overscan: t = 3, isFullWidth: n = !1 } = {}) => {
|
|
90
|
+
let r = L(null), [i, a] = R(() => {
|
|
91
|
+
let t = typeof window < "u" ? window.innerWidth : 1440, r = Math.max(0, t - (t >= w ? 60 : 0)), i = At((n ? r : Math.min(kt, r)) - 64), a = Math.ceil(e / i);
|
|
86
92
|
return {
|
|
87
93
|
startRow: 0,
|
|
88
94
|
endRow: Math.min(a, 12),
|
|
89
95
|
columnCount: i
|
|
90
96
|
};
|
|
91
97
|
});
|
|
92
|
-
|
|
98
|
+
F(() => {
|
|
93
99
|
let n = r.current;
|
|
94
100
|
if (!n) return;
|
|
95
|
-
let i =
|
|
101
|
+
let i = jt(n.parentElement), o = () => {
|
|
96
102
|
let r = n.clientWidth, o = i.clientHeight;
|
|
97
103
|
if (r === 0 || o === 0) return;
|
|
98
|
-
let s = n.getBoundingClientRect(), c = i.getBoundingClientRect(), l =
|
|
104
|
+
let s = n.getBoundingClientRect(), c = i.getBoundingClientRect(), l = At(r), u = Math.ceil(e / l), d = Math.max(0, c.top - s.top), f = Math.max(0, Math.floor(d / 268) - t), p = Math.min(u, f + Math.ceil(o / 268) + 2 * t);
|
|
99
105
|
a((e) => e.startRow === f && e.endRow === p && e.columnCount === l ? e : {
|
|
100
106
|
startRow: f,
|
|
101
107
|
endRow: p,
|
|
@@ -117,7 +123,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
117
123
|
rowCount: o,
|
|
118
124
|
totalHeight: o * 268
|
|
119
125
|
};
|
|
120
|
-
},
|
|
126
|
+
}, Lt = {
|
|
121
127
|
skeletonColor: "var(--cg-skeleton-color, var(--bg-control-disable-primary, #dce0e8))",
|
|
122
128
|
card: "_card_18c2b_2",
|
|
123
129
|
emptyStarHidden: "_emptyStarHidden_18c2b_2",
|
|
@@ -127,11 +133,11 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
127
133
|
selectedCard: "_selectedCard_18c2b_37",
|
|
128
134
|
checkIcon: "_checkIcon_18c2b_42",
|
|
129
135
|
footer: "_footer_18c2b_46"
|
|
130
|
-
},
|
|
136
|
+
}, Rt = {
|
|
131
137
|
name: "_name_188yo_1",
|
|
132
138
|
lastUsed: "_lastUsed_188yo_5",
|
|
133
139
|
version: "_version_188yo_9"
|
|
134
|
-
},
|
|
140
|
+
}, zt = ({ icon: e, type: t, name: n, version: r, lastUsed: i, size: a, query: o, className: s, styles: c, lastUsedTrailing: l, iconClassName: u, iconOverlay: d }) => {
|
|
135
141
|
let f = c?.colors, p = c?.typography ?? {}, m = a === Ct.LG, h = m ? "size-[52px] rounded-[14px]" : "size-[44px] rounded-lg", g = m ? 54 : 44, _ = j({
|
|
136
142
|
"--ai-name-text": f?.nameColor,
|
|
137
143
|
"--ai-last-used-text": f?.lastUsedColor,
|
|
@@ -160,27 +166,27 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
160
166
|
className: "flex min-w-0 flex-col",
|
|
161
167
|
children: [/* @__PURE__ */ K("div", {
|
|
162
168
|
className: "flex min-w-0 items-start gap-1 overflow-hidden",
|
|
163
|
-
children: [/* @__PURE__ */ G(
|
|
164
|
-
text: o ? /* @__PURE__ */ G(
|
|
169
|
+
children: [/* @__PURE__ */ G(be, {
|
|
170
|
+
text: o ? /* @__PURE__ */ G(Ce, {
|
|
165
171
|
text: n,
|
|
166
172
|
query: o
|
|
167
173
|
}) : n,
|
|
168
|
-
className: M(r ? "min-w-0 max-w-[66%] shrink-0" : "min-w-0 flex-1", p?.nameClassName ?? "dial-body-semi-text",
|
|
169
|
-
}), r && /* @__PURE__ */ G(
|
|
174
|
+
className: M(r ? "min-w-0 max-w-[66%] shrink-0" : "min-w-0 flex-1", p?.nameClassName ?? "dial-body-semi-text", Rt.name)
|
|
175
|
+
}), r && /* @__PURE__ */ G(be, {
|
|
170
176
|
text: r,
|
|
171
|
-
className: M("min-w-0 flex-1 text-end tabular-nums", p?.versionClassName ?? "dial-tiny-text",
|
|
177
|
+
className: M("min-w-0 flex-1 text-end tabular-nums", p?.versionClassName ?? "dial-tiny-text", Rt.version)
|
|
172
178
|
})]
|
|
173
179
|
}), m && i != null && /* @__PURE__ */ K("div", {
|
|
174
180
|
className: "flex items-center gap-2",
|
|
175
181
|
children: [/* @__PURE__ */ G("span", {
|
|
176
|
-
className: M("tabular-nums", p?.lastUsedClassName ?? "dial-tiny-text",
|
|
182
|
+
className: M("tabular-nums", p?.lastUsedClassName ?? "dial-tiny-text", Rt.lastUsed),
|
|
177
183
|
children: i
|
|
178
184
|
}), l]
|
|
179
185
|
})]
|
|
180
186
|
})]
|
|
181
187
|
})]
|
|
182
188
|
});
|
|
183
|
-
},
|
|
189
|
+
}, Bt = { icon: "_icon_a0p4u_1" }, Vt = ({ credentials: e, loggedOutLabel: t = "Authorize to use this toolset.", className: n, colors: r }) => e == null || d(e) == null ? null : /* @__PURE__ */ G(Ve, {
|
|
184
190
|
tooltip: t,
|
|
185
191
|
asChild: !0,
|
|
186
192
|
children: /* @__PURE__ */ G("span", {
|
|
@@ -191,33 +197,33 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
191
197
|
"--cat-cred-badge-icon": r?.icon
|
|
192
198
|
}),
|
|
193
199
|
className: M("absolute -bottom-1 -end-1 shrink-0", n),
|
|
194
|
-
children: /* @__PURE__ */ G(
|
|
195
|
-
size:
|
|
196
|
-
className:
|
|
200
|
+
children: /* @__PURE__ */ G(Ue, {
|
|
201
|
+
size: z.SM,
|
|
202
|
+
className: Bt.icon,
|
|
197
203
|
"aria-hidden": !0
|
|
198
204
|
})
|
|
199
205
|
})
|
|
200
|
-
}),
|
|
206
|
+
}), Ht = {
|
|
201
207
|
starFilledIcon: "_starFilledIcon_po6zj_1",
|
|
202
208
|
starPop: "_starPop_po6zj_1"
|
|
203
|
-
},
|
|
209
|
+
}, Ut = ({ isStarred: e, onClick: t, size: n, ariaLabel: r = "Toggle favorite", className: i, starFilledColor: a }) => /* @__PURE__ */ G(Be, {
|
|
204
210
|
size: n,
|
|
205
211
|
style: j({ "--cat-star-filled": a }),
|
|
206
212
|
className: i,
|
|
207
213
|
isSelected: e,
|
|
208
|
-
icon: /* @__PURE__ */ G(
|
|
209
|
-
size:
|
|
210
|
-
stroke:
|
|
214
|
+
icon: /* @__PURE__ */ G(ut, {
|
|
215
|
+
size: z.SM,
|
|
216
|
+
stroke: B,
|
|
211
217
|
"aria-hidden": !0
|
|
212
218
|
}),
|
|
213
219
|
selectedIcon: /* @__PURE__ */ G(dt, {
|
|
214
|
-
size:
|
|
215
|
-
className:
|
|
220
|
+
size: z.SM,
|
|
221
|
+
className: Ht.starFilledIcon,
|
|
216
222
|
"aria-hidden": !0
|
|
217
223
|
}),
|
|
218
224
|
"aria-label": r,
|
|
219
225
|
onClick: t
|
|
220
|
-
}),
|
|
226
|
+
}), Wt = { tag: "_tag_iqin5_3" }, Gt = ({ label: e, className: t, badgeClassName: n = "dial-tiny-text", colors: r }) => /* @__PURE__ */ G(ce, {
|
|
221
227
|
label: e,
|
|
222
228
|
textClassName: n,
|
|
223
229
|
style: j({
|
|
@@ -225,13 +231,13 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
225
231
|
"--cat-card-tag-text": r?.text,
|
|
226
232
|
"--cat-card-tag-border": r?.border
|
|
227
233
|
}),
|
|
228
|
-
className: M(
|
|
229
|
-
}),
|
|
234
|
+
className: M(Wt.tag, t)
|
|
235
|
+
}), Kt = ({ label: e, className: t = "dial-tiny-text", colors: n }) => /* @__PURE__ */ G(Gt, {
|
|
230
236
|
label: e,
|
|
231
237
|
badgeClassName: t,
|
|
232
238
|
colors: n
|
|
233
|
-
}),
|
|
234
|
-
let r =
|
|
239
|
+
}), qt = 8, Jt = ({ topics: e, overflowAriaLabel: t, className: n }) => {
|
|
240
|
+
let r = L(null), i = L([]), a = L([]), o = L(null), s = L(Infinity), [c, l] = R(e.length), u = e.join("\0"), d = P(() => {
|
|
235
241
|
let t = r.current;
|
|
236
242
|
if (!t || e.length === 0) return;
|
|
237
243
|
let n = t.clientWidth;
|
|
@@ -242,19 +248,19 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
242
248
|
let u = o.current?.offsetWidth ?? 0, d = 0, f = 0;
|
|
243
249
|
for (let t = 0; t < e.length; t++) {
|
|
244
250
|
let r = e.length - (t + 1) > 0;
|
|
245
|
-
if (d + (t > 0 ?
|
|
246
|
-
d += (t > 0 ?
|
|
251
|
+
if (d + (t > 0 ? qt : 0) + c[t] + (r ? qt + u : 0) > n) break;
|
|
252
|
+
d += (t > 0 ? qt : 0) + c[t], f = t + 1;
|
|
247
253
|
}
|
|
248
254
|
l(Math.min(f, s.current));
|
|
249
255
|
}, [e.length]);
|
|
250
|
-
if (
|
|
256
|
+
if (se(() => {
|
|
251
257
|
a.current = [], s.current = Infinity, l(e.length);
|
|
252
|
-
}, [u]),
|
|
258
|
+
}, [u]), se(() => {
|
|
253
259
|
d();
|
|
254
|
-
}),
|
|
260
|
+
}), se(() => {
|
|
255
261
|
let e = r.current;
|
|
256
262
|
!e || c === 0 || e.scrollWidth <= e.clientWidth || (s.current = c - 1, l(s.current));
|
|
257
|
-
}, [c]),
|
|
263
|
+
}, [c]), F(() => {
|
|
258
264
|
let e = r.current;
|
|
259
265
|
if (!e) return;
|
|
260
266
|
let t = new ResizeObserver(() => {
|
|
@@ -274,132 +280,133 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
274
280
|
ref: (e) => {
|
|
275
281
|
i.current[t] = e;
|
|
276
282
|
},
|
|
277
|
-
children: /* @__PURE__ */ G(
|
|
283
|
+
children: /* @__PURE__ */ G(Kt, { label: e })
|
|
278
284
|
}, e)),
|
|
279
|
-
f > 0 && /* @__PURE__ */ G(
|
|
285
|
+
f > 0 && /* @__PURE__ */ G(Ve, {
|
|
280
286
|
tooltip: e.slice(c).join(", "),
|
|
281
287
|
children: /* @__PURE__ */ G("span", {
|
|
282
288
|
"aria-label": t?.(f) ?? `and ${f} more topics`,
|
|
283
|
-
children: /* @__PURE__ */ G(
|
|
289
|
+
children: /* @__PURE__ */ G(Kt, { label: `+${f}` })
|
|
284
290
|
})
|
|
285
291
|
}),
|
|
286
292
|
/* @__PURE__ */ G("div", {
|
|
287
293
|
ref: o,
|
|
288
294
|
"aria-hidden": !0,
|
|
289
295
|
className: "invisible absolute start-0 top-0",
|
|
290
|
-
children: /* @__PURE__ */ G(
|
|
296
|
+
children: /* @__PURE__ */ G(Kt, { label: `+${e.length}` })
|
|
291
297
|
})
|
|
292
298
|
]
|
|
293
299
|
});
|
|
294
|
-
},
|
|
295
|
-
let [
|
|
296
|
-
|
|
297
|
-
|
|
300
|
+
}, Yt = { img: () => null }, Xt = (e) => e.target instanceof Element && e.target.closest("a") !== null, Zt = ({ item: e, query: t = "", onClick: n, initialIsStarred: r = !1, onToggle: i, isFavoriteVisible: a, featuredLabel: o = "Featured", addToFavoritesAriaLabel: s = "Add to favorites", removeFromFavoritesAriaLabel: c = "Remove from favorites", isSelected: l = !1, className: u, styles: d, credentialsBadgeLoggedOutLabel: f, isReadonly: p = !1, markdownLabels: m }) => {
|
|
301
|
+
let [h, g] = R(r);
|
|
302
|
+
F(() => {
|
|
303
|
+
g(r);
|
|
298
304
|
}, [e.id, r]);
|
|
299
|
-
let
|
|
305
|
+
let _ = d?.typography?.descriptionClassName ?? "dial-small-paragraph-text", v = d?.typography?.featuredChipClassName, y = d?.typography?.folderLabelClassName ?? "dial-tiny-text", b = d?.typography?.folderLeafClassName ?? "dial-tiny-semi-text", x = j({
|
|
300
306
|
"--cg-description-text": d?.colors?.textSecondary,
|
|
301
307
|
"--cg-selected-border": d?.colors?.selectedBorder,
|
|
302
308
|
"--cg-selected-bg": d?.colors?.selectedBackground,
|
|
303
309
|
"--cg-check-icon": d?.colors?.checkIcon,
|
|
304
310
|
"--cg-footer-border": d?.colors?.footerBorder
|
|
305
|
-
}),
|
|
306
|
-
|
|
307
|
-
} : void 0,
|
|
308
|
-
!n ||
|
|
309
|
-
}, [n, e]),
|
|
311
|
+
}), S = !p && e.isFeatured === !0, C = !p && a?.(e) !== !1, w = !p || e.folder.length > 0, T = n ? (t) => {
|
|
312
|
+
Xt(t) || n(e);
|
|
313
|
+
} : void 0, E = P((t) => {
|
|
314
|
+
!n || Xt(t) || (t.key === "Enter" || t.key === " ") && (t.preventDefault(), n(e));
|
|
315
|
+
}, [n, e]), D = P((t) => {
|
|
310
316
|
t.stopPropagation();
|
|
311
|
-
let n = !
|
|
312
|
-
|
|
317
|
+
let n = !h;
|
|
318
|
+
g(n), i?.(e.id, n);
|
|
313
319
|
}, [
|
|
314
|
-
|
|
320
|
+
h,
|
|
315
321
|
i,
|
|
316
322
|
e.id
|
|
317
323
|
]);
|
|
318
|
-
return /* @__PURE__ */ K(
|
|
324
|
+
return /* @__PURE__ */ K(pe, {
|
|
319
325
|
...n ? {
|
|
320
326
|
role: "button",
|
|
321
327
|
tabIndex: 0,
|
|
322
|
-
onClick:
|
|
323
|
-
onKeyDown:
|
|
328
|
+
onClick: T,
|
|
329
|
+
onKeyDown: E
|
|
324
330
|
} : {},
|
|
325
331
|
"aria-label": e.name,
|
|
326
|
-
style:
|
|
327
|
-
className: M("box-border cursor-pointer gap-3",
|
|
332
|
+
style: x,
|
|
333
|
+
className: M("box-border cursor-pointer gap-3", Lt.card, S ? Lt.featuredCard : void 0, l ? Lt.selectedCard : void 0, u, Et.card),
|
|
328
334
|
children: [
|
|
329
|
-
|
|
335
|
+
S && /* @__PURE__ */ G("div", {
|
|
330
336
|
className: "absolute end-[22px] top-0 -translate-y-1/2",
|
|
331
337
|
children: /* @__PURE__ */ G(O, {
|
|
332
338
|
label: o,
|
|
333
339
|
type: e.type,
|
|
334
|
-
className:
|
|
340
|
+
className: v,
|
|
335
341
|
style: d?.colors?.featuredChipStyle
|
|
336
342
|
})
|
|
337
343
|
}),
|
|
338
|
-
l && /* @__PURE__ */ G(
|
|
339
|
-
size:
|
|
340
|
-
className: M("absolute end-3 top-3 shrink-0",
|
|
344
|
+
l && /* @__PURE__ */ G(Ke, {
|
|
345
|
+
size: z.SM,
|
|
346
|
+
className: M("absolute end-3 top-3 shrink-0", Lt.checkIcon),
|
|
341
347
|
"aria-hidden": !0,
|
|
342
|
-
stroke:
|
|
348
|
+
stroke: B
|
|
343
349
|
}),
|
|
344
|
-
/* @__PURE__ */ G(
|
|
350
|
+
/* @__PURE__ */ G(zt, {
|
|
345
351
|
icon: e.iconUrl,
|
|
346
352
|
type: e.type,
|
|
347
353
|
name: e.name,
|
|
348
354
|
version: e.version,
|
|
349
355
|
size: Ct.SM,
|
|
350
356
|
query: t,
|
|
351
|
-
iconClassName:
|
|
352
|
-
iconOverlay: /* @__PURE__ */ G(
|
|
357
|
+
iconClassName: Lt.cardIcon,
|
|
358
|
+
iconOverlay: /* @__PURE__ */ G(Vt, {
|
|
353
359
|
credentials: e.credentials,
|
|
354
360
|
loggedOutLabel: f
|
|
355
361
|
})
|
|
356
362
|
}),
|
|
357
363
|
/* @__PURE__ */ G("div", {
|
|
358
|
-
className: M("line-clamp-2 min-h-[2lh] break-words",
|
|
364
|
+
className: M("line-clamp-2 min-h-[2lh] break-words", Lt.description),
|
|
359
365
|
children: e.description && /* @__PURE__ */ G(A, {
|
|
360
366
|
content: e.description,
|
|
361
367
|
classNames: {
|
|
362
|
-
p:
|
|
363
|
-
ul:
|
|
364
|
-
ol:
|
|
365
|
-
h1:
|
|
366
|
-
h2:
|
|
367
|
-
h3:
|
|
368
|
-
h4:
|
|
369
|
-
h5:
|
|
370
|
-
h6:
|
|
368
|
+
p: _,
|
|
369
|
+
ul: _,
|
|
370
|
+
ol: _,
|
|
371
|
+
h1: _,
|
|
372
|
+
h2: _,
|
|
373
|
+
h3: _,
|
|
374
|
+
h4: _,
|
|
375
|
+
h5: _,
|
|
376
|
+
h6: _
|
|
371
377
|
},
|
|
372
|
-
components:
|
|
378
|
+
components: Yt,
|
|
379
|
+
...m
|
|
373
380
|
})
|
|
374
381
|
}),
|
|
375
382
|
/* @__PURE__ */ G("div", {
|
|
376
383
|
className: "mt-auto flex items-center gap-2",
|
|
377
|
-
children: /* @__PURE__ */ G(
|
|
384
|
+
children: /* @__PURE__ */ G(Jt, { topics: e.topics })
|
|
378
385
|
}),
|
|
379
|
-
|
|
380
|
-
className: M("pt-3", !p && M("border-t",
|
|
386
|
+
w && /* @__PURE__ */ G("div", {
|
|
387
|
+
className: M("pt-3", !p && M("border-t", Lt.footer)),
|
|
381
388
|
children: /* @__PURE__ */ K("div", {
|
|
382
389
|
className: "flex items-center gap-2",
|
|
383
390
|
children: [/* @__PURE__ */ G("div", {
|
|
384
391
|
className: "min-w-0 flex-1",
|
|
385
|
-
children: e.folder.length > 0 && /* @__PURE__ */ G(
|
|
392
|
+
children: e.folder.length > 0 && /* @__PURE__ */ G(xe, {
|
|
386
393
|
segments: e.folder,
|
|
387
|
-
labelClassName:
|
|
388
|
-
leafClassName:
|
|
394
|
+
labelClassName: y,
|
|
395
|
+
leafClassName: b
|
|
389
396
|
})
|
|
390
|
-
}),
|
|
391
|
-
isStarred:
|
|
392
|
-
size:
|
|
393
|
-
onClick:
|
|
394
|
-
ariaLabel:
|
|
395
|
-
className: M(
|
|
397
|
+
}), C && /* @__PURE__ */ G(Ut, {
|
|
398
|
+
isStarred: h,
|
|
399
|
+
size: ye.Small,
|
|
400
|
+
onClick: D,
|
|
401
|
+
ariaLabel: h ? c : s,
|
|
402
|
+
className: M(Lt.starBtn, !h && Lt.emptyStarHidden)
|
|
396
403
|
})]
|
|
397
404
|
})
|
|
398
405
|
})
|
|
399
406
|
]
|
|
400
407
|
});
|
|
401
|
-
},
|
|
402
|
-
let
|
|
408
|
+
}, Qt = N(({ rowIndex: e, items: t, columnCount: n, query: r, onToggleFavorite: i, isFavoriteVisible: a, onItemClick: o, featuredLabel: s, addToFavoritesAriaLabel: c, removeFromFavoritesAriaLabel: l, selectedItemId: u, credentialsBadgeLoggedOutLabel: d, isReadonly: f, featuredChipStyle: p, markdownLabels: m }) => {
|
|
409
|
+
let h = e * n, g = t.slice(h, h + n);
|
|
403
410
|
return /* @__PURE__ */ G("div", {
|
|
404
411
|
style: {
|
|
405
412
|
top: e * 268,
|
|
@@ -407,10 +414,10 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
407
414
|
},
|
|
408
415
|
className: "absolute flex w-full gap-5 pb-5",
|
|
409
416
|
children: Array.from({ length: n }, (e, t) => {
|
|
410
|
-
let n =
|
|
417
|
+
let n = g[t];
|
|
411
418
|
return /* @__PURE__ */ G("div", {
|
|
412
419
|
className: "h-full min-w-0 flex-1",
|
|
413
|
-
children: n && /* @__PURE__ */ G(
|
|
420
|
+
children: n && /* @__PURE__ */ G(Zt, {
|
|
414
421
|
item: n,
|
|
415
422
|
query: r,
|
|
416
423
|
initialIsStarred: n.isStarred,
|
|
@@ -424,54 +431,57 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
424
431
|
className: "h-full",
|
|
425
432
|
credentialsBadgeLoggedOutLabel: d,
|
|
426
433
|
isReadonly: f,
|
|
427
|
-
styles: { colors: { featuredChipStyle: p } }
|
|
434
|
+
styles: { colors: { featuredChipStyle: p } },
|
|
435
|
+
markdownLabels: m
|
|
428
436
|
})
|
|
429
437
|
}, n?.id ?? `spacer-${t}`);
|
|
430
438
|
})
|
|
431
439
|
});
|
|
432
|
-
}),
|
|
433
|
-
let
|
|
440
|
+
}), $t = N(({ items: e, query: t = "", onToggleFavorite: n, isFavoriteVisible: r, onItemClick: i, titles: a, isLoading: o, selectedItemId: s, skeletonColor: c = Lt.skeletonColor, skeletonCardBackground: l, isReadonly: u = !1, isFullWidth: d = !1, featuredChipStyle: f, markdownLabels: p }) => {
|
|
441
|
+
let m = a?.noResultsTitle ?? "No results", h = a?.featuredLabel ?? "Featured", g = a?.addToFavoritesAriaLabel ?? "Add to favorites", _ = a?.removeFromFavoritesAriaLabel ?? "Remove from favorites", v = a?.credentialsBadgeLoggedOutLabel ?? "Authorize to use this toolset.", { containerRef: y, startRow: b, endRow: x, columnCount: S, totalHeight: C } = It(e.length, { isFullWidth: d }), w = I(() => ({
|
|
434
442
|
items: e,
|
|
435
|
-
columnCount:
|
|
443
|
+
columnCount: S,
|
|
436
444
|
query: t,
|
|
437
445
|
onToggleFavorite: n,
|
|
438
446
|
isFavoriteVisible: r,
|
|
439
447
|
onItemClick: i,
|
|
440
|
-
featuredLabel:
|
|
441
|
-
addToFavoritesAriaLabel:
|
|
442
|
-
removeFromFavoritesAriaLabel:
|
|
448
|
+
featuredLabel: h,
|
|
449
|
+
addToFavoritesAriaLabel: g,
|
|
450
|
+
removeFromFavoritesAriaLabel: _,
|
|
443
451
|
selectedItemId: s,
|
|
444
|
-
credentialsBadgeLoggedOutLabel:
|
|
452
|
+
credentialsBadgeLoggedOutLabel: v,
|
|
445
453
|
isReadonly: u,
|
|
446
|
-
featuredChipStyle: f
|
|
454
|
+
featuredChipStyle: f,
|
|
455
|
+
markdownLabels: p
|
|
447
456
|
}), [
|
|
448
457
|
e,
|
|
449
|
-
|
|
458
|
+
S,
|
|
450
459
|
t,
|
|
451
460
|
n,
|
|
452
461
|
r,
|
|
453
462
|
i,
|
|
454
|
-
m,
|
|
455
463
|
h,
|
|
456
464
|
g,
|
|
457
|
-
s,
|
|
458
465
|
_,
|
|
466
|
+
s,
|
|
467
|
+
v,
|
|
459
468
|
u,
|
|
460
|
-
f
|
|
469
|
+
f,
|
|
470
|
+
p
|
|
461
471
|
]);
|
|
462
472
|
return o ? /* @__PURE__ */ G("div", {
|
|
463
473
|
className: "grid gap-5 p-5",
|
|
464
474
|
style: {
|
|
465
|
-
gridTemplateColumns: `repeat(${
|
|
475
|
+
gridTemplateColumns: `repeat(${S}, minmax(0, 1fr))`,
|
|
466
476
|
...j({ "--cg-skeleton-card-bg": l })
|
|
467
477
|
},
|
|
468
|
-
children: Array.from({ length:
|
|
469
|
-
className: M("rounded-md border p-4",
|
|
478
|
+
children: Array.from({ length: S * 3 }, (e, t) => /* @__PURE__ */ G("div", {
|
|
479
|
+
className: M("rounded-md border p-4", Lt.skeletonCard),
|
|
470
480
|
style: { height: 248 },
|
|
471
|
-
children: /* @__PURE__ */ G(
|
|
481
|
+
children: /* @__PURE__ */ G(Ie, {
|
|
472
482
|
avatar: {
|
|
473
483
|
size: 48,
|
|
474
|
-
shape:
|
|
484
|
+
shape: Le.Square
|
|
475
485
|
},
|
|
476
486
|
showTitle: { width: `${60 + t * 17 % 30}%` },
|
|
477
487
|
paragraph: { rows: 3 },
|
|
@@ -481,33 +491,33 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
481
491
|
}, t))
|
|
482
492
|
}) : e.length === 0 ? /* @__PURE__ */ G("div", {
|
|
483
493
|
className: "flex size-full flex-col items-center justify-center",
|
|
484
|
-
children: /* @__PURE__ */ G(ne, { label:
|
|
494
|
+
children: /* @__PURE__ */ G(ne, { label: m })
|
|
485
495
|
}) : /* @__PURE__ */ G("div", {
|
|
486
|
-
ref:
|
|
496
|
+
ref: y,
|
|
487
497
|
className: "relative",
|
|
488
|
-
style: { height:
|
|
489
|
-
children: Array.from({ length:
|
|
490
|
-
let n =
|
|
491
|
-
return /* @__PURE__ */ G(
|
|
498
|
+
style: { height: C },
|
|
499
|
+
children: Array.from({ length: x - b }, (e, t) => {
|
|
500
|
+
let n = b + t;
|
|
501
|
+
return /* @__PURE__ */ G(Qt, {
|
|
492
502
|
rowIndex: n,
|
|
493
|
-
...
|
|
503
|
+
...w
|
|
494
504
|
}, n);
|
|
495
505
|
})
|
|
496
506
|
});
|
|
497
|
-
}),
|
|
507
|
+
}), en = (e) => e.reduce((e, t) => t.type === Z.File ? e + 1 : e + en(t.items), 0), tn = (e) => {
|
|
498
508
|
let t = /* @__PURE__ */ new Set(), n = (e) => {
|
|
499
509
|
for (let r of e) r.type === Z.Folder && (t.add(r.id), n(r.items));
|
|
500
510
|
};
|
|
501
511
|
return n(e), t;
|
|
502
|
-
},
|
|
512
|
+
}, nn = (e, t) => {
|
|
503
513
|
if (t != null) for (let n of e) {
|
|
504
514
|
if (n.id === t) return n.name;
|
|
505
515
|
if (n.type === Z.Folder) {
|
|
506
|
-
let e =
|
|
516
|
+
let e = nn(n.items, t);
|
|
507
517
|
if (e != null) return e;
|
|
508
518
|
}
|
|
509
519
|
}
|
|
510
|
-
},
|
|
520
|
+
}, rn = {
|
|
511
521
|
sectionHeading: "_sectionHeading_jnq93_1",
|
|
512
522
|
rowAlt: "_rowAlt_jnq93_5",
|
|
513
523
|
label: "_label_jnq93_9",
|
|
@@ -515,19 +525,19 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
515
525
|
valueTrue: "_valueTrue_jnq93_17",
|
|
516
526
|
valueFalse: "_valueFalse_jnq93_21",
|
|
517
527
|
valueText: "_valueText_jnq93_25"
|
|
518
|
-
},
|
|
519
|
-
size:
|
|
520
|
-
className: M(r,
|
|
528
|
+
}, an = ({ value: e, valueClassName: t, valueTrueClassName: n, checkIconClassName: r, yesLabel: i, noLabel: a }) => e === !0 ? /* @__PURE__ */ K(gt, { children: [/* @__PURE__ */ G(Xe, {
|
|
529
|
+
size: z.MD,
|
|
530
|
+
className: M(r, rn.checkIcon)
|
|
521
531
|
}), /* @__PURE__ */ G("span", {
|
|
522
|
-
className: M(n,
|
|
532
|
+
className: M(n, rn.valueTrue),
|
|
523
533
|
children: i
|
|
524
534
|
})] }) : e === !1 ? /* @__PURE__ */ G("span", {
|
|
525
|
-
className: M(t,
|
|
535
|
+
className: M(t, rn.valueFalse),
|
|
526
536
|
children: a
|
|
527
537
|
}) : /* @__PURE__ */ G("span", {
|
|
528
|
-
className: M("min-w-0 break-words", t,
|
|
538
|
+
className: M("min-w-0 break-words", t, rn.valueText),
|
|
529
539
|
children: e
|
|
530
|
-
}),
|
|
540
|
+
}), on = ({ sectionLabel: e = "Section", values: t, labelClassName: n = "dial-small-semi-text", valueClassName: r = "dial-small-text", valueTrueClassName: i = "dial-small-semi-text", checkIconClassName: a, sectionClassName: o = "dial-caption-text", yesLabel: s = "Yes", noLabel: c = "No", colors: l }) => /* @__PURE__ */ G("div", {
|
|
531
541
|
className: "flex flex-col",
|
|
532
542
|
style: j({
|
|
533
543
|
"--tv-section-heading": l?.sectionHeading,
|
|
@@ -539,18 +549,18 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
539
549
|
"--tv-value-text": l?.valueText
|
|
540
550
|
}),
|
|
541
551
|
children: t != null && t.length > 0 && /* @__PURE__ */ K("section", { children: [/* @__PURE__ */ G("p", {
|
|
542
|
-
className: M("mb-3 mt-0", o,
|
|
552
|
+
className: M("mb-3 mt-0", o, rn.sectionHeading),
|
|
543
553
|
children: e
|
|
544
554
|
}), /* @__PURE__ */ G("ul", {
|
|
545
555
|
className: "m-0 list-none p-0",
|
|
546
556
|
children: t.map((e, t) => /* @__PURE__ */ K("li", {
|
|
547
|
-
className: M("flex items-center rounded px-3 py-2", t % 2 == 0 ?
|
|
557
|
+
className: M("flex items-center rounded px-3 py-2", t % 2 == 0 ? rn.rowAlt : void 0),
|
|
548
558
|
children: [/* @__PURE__ */ G("span", {
|
|
549
|
-
className: M(n,
|
|
559
|
+
className: M(n, rn.label, "w-2/5 shrink-0"),
|
|
550
560
|
children: e.label
|
|
551
561
|
}), /* @__PURE__ */ G("div", {
|
|
552
562
|
className: "flex w-3/5 min-w-0 items-center gap-1",
|
|
553
|
-
children: /* @__PURE__ */ G(
|
|
563
|
+
children: /* @__PURE__ */ G(an, {
|
|
554
564
|
value: e.value,
|
|
555
565
|
valueClassName: r,
|
|
556
566
|
valueTrueClassName: i,
|
|
@@ -561,46 +571,46 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
561
571
|
})]
|
|
562
572
|
}, e.label))
|
|
563
573
|
})] })
|
|
564
|
-
}),
|
|
574
|
+
}), sn = { sectionHeading: "_sectionHeading_148lj_1" }, cn = {
|
|
565
575
|
[q.Python]: "Python",
|
|
566
576
|
[q.Curl]: "cURL",
|
|
567
577
|
[q.JavaScript]: "JavaScript"
|
|
568
|
-
},
|
|
578
|
+
}, ln = {
|
|
569
579
|
[q.Python]: "python",
|
|
570
580
|
[q.Curl]: "bash",
|
|
571
581
|
[q.JavaScript]: "javascript"
|
|
572
|
-
},
|
|
573
|
-
let [s, c] =
|
|
574
|
-
|
|
582
|
+
}, un = ({ snippets: e, sectionLabel: t, copyAriaLabel: n = "Copy", copiedStatusLabel: r = "Copied!", codeClassName: i = "dial-code-text", codeTitleClassName: a = "dial-tiny-semi-text", sectionClassName: o = "dial-caption-text" }) => {
|
|
583
|
+
let [s, c] = R(e[0]?.language ?? q.Python);
|
|
584
|
+
F(() => {
|
|
575
585
|
c(e[0]?.language ?? q.Python);
|
|
576
586
|
}, [e]);
|
|
577
|
-
let l =
|
|
587
|
+
let l = I(() => e.map((e) => ({
|
|
578
588
|
key: e.language,
|
|
579
|
-
label:
|
|
589
|
+
label: cn[e.language] ?? e.language,
|
|
580
590
|
onClick: () => c(e.language)
|
|
581
591
|
})), [e]), u = e.find((e) => e.language === s)?.code ?? "", d = e.length > 1;
|
|
582
592
|
return /* @__PURE__ */ K("section", { children: [t != null && /* @__PURE__ */ G("p", {
|
|
583
|
-
className: M("mb-3 mt-0", o,
|
|
593
|
+
className: M("mb-3 mt-0", o, sn.sectionHeading),
|
|
584
594
|
children: t
|
|
585
595
|
}), /* @__PURE__ */ G(k, {
|
|
586
|
-
language:
|
|
587
|
-
title:
|
|
596
|
+
language: ln[s] ?? s,
|
|
597
|
+
title: cn[s] ?? s,
|
|
588
598
|
value: u,
|
|
589
599
|
copyLabel: n,
|
|
590
600
|
copiedLabel: r,
|
|
591
601
|
codeClassName: i,
|
|
592
602
|
languageLabelClassName: a,
|
|
593
603
|
hideDownload: !0,
|
|
594
|
-
titleSlot: d ? /* @__PURE__ */ G(
|
|
604
|
+
titleSlot: d ? /* @__PURE__ */ G(we, {
|
|
595
605
|
items: l,
|
|
596
606
|
matchReferenceWidth: !1,
|
|
597
607
|
placement: "bottom-end",
|
|
598
|
-
size:
|
|
608
|
+
size: ye.Small,
|
|
599
609
|
selectedKey: s
|
|
600
610
|
}) : void 0
|
|
601
611
|
})] });
|
|
602
|
-
},
|
|
603
|
-
let [h, g] =
|
|
612
|
+
}, dn = ({ api: e, resourceSectionLabel: t = "Resource", endpointSectionLabel: n = "Endpoint", snippetSectionLabel: r = "Code snippet", modelIdLabel: i = "Model ID", endpointLabel: a = "Endpoint", requestExampleLabel: o = "Request example", responseSchemaLabel: s = "Response schema", copyAriaLabel: c = "Copy", copiedStatusLabel: l = "Copied!", labelClassName: u = "dial-small-semi-text", valueClassName: d = "dial-small-text", codeClassName: f = "dial-code-text", codeTitleClassName: p = "dial-tiny-semi-text", sectionClassName: m = "dial-caption-text" }) => {
|
|
613
|
+
let [h, g] = R(0), _ = I(() => e.endpoints ?? [], [e.endpoints]), v = _.length > 0, y = _[h] ?? null, b = I(() => _.map((e, t) => ({
|
|
604
614
|
key: e.url,
|
|
605
615
|
label: e.label,
|
|
606
616
|
onClick: () => g(t)
|
|
@@ -613,7 +623,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
613
623
|
return /* @__PURE__ */ K("div", {
|
|
614
624
|
className: "flex flex-col gap-6",
|
|
615
625
|
children: [
|
|
616
|
-
C && /* @__PURE__ */ G(
|
|
626
|
+
C && /* @__PURE__ */ G(on, {
|
|
617
627
|
sectionLabel: t,
|
|
618
628
|
values: x,
|
|
619
629
|
labelClassName: u,
|
|
@@ -631,7 +641,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
631
641
|
}),
|
|
632
642
|
v && /* @__PURE__ */ K("section", { children: [
|
|
633
643
|
/* @__PURE__ */ G("p", {
|
|
634
|
-
className: M("mb-3 mt-0", m,
|
|
644
|
+
className: M("mb-3 mt-0", m, sn.sectionHeading),
|
|
635
645
|
children: n
|
|
636
646
|
}),
|
|
637
647
|
y != null && /* @__PURE__ */ G(k, {
|
|
@@ -642,17 +652,17 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
642
652
|
codeClassName: f,
|
|
643
653
|
languageLabelClassName: p,
|
|
644
654
|
hideDownload: !0,
|
|
645
|
-
titleSlot: S ? /* @__PURE__ */ G(
|
|
655
|
+
titleSlot: S ? /* @__PURE__ */ G(we, {
|
|
646
656
|
items: b,
|
|
647
657
|
matchReferenceWidth: !1,
|
|
648
658
|
placement: "bottom-end",
|
|
649
|
-
size:
|
|
659
|
+
size: ye.Small,
|
|
650
660
|
selectedKey: y.url
|
|
651
661
|
}) : void 0
|
|
652
662
|
}, h),
|
|
653
663
|
y?.snippets != null && y.snippets.length > 0 && /* @__PURE__ */ G("div", {
|
|
654
664
|
className: "mt-4",
|
|
655
|
-
children: /* @__PURE__ */ G(
|
|
665
|
+
children: /* @__PURE__ */ G(un, {
|
|
656
666
|
snippets: y.snippets,
|
|
657
667
|
copyAriaLabel: c,
|
|
658
668
|
copiedStatusLabel: l,
|
|
@@ -662,7 +672,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
662
672
|
}, h)
|
|
663
673
|
})
|
|
664
674
|
] }),
|
|
665
|
-
!v && T && /* @__PURE__ */ G(
|
|
675
|
+
!v && T && /* @__PURE__ */ G(un, {
|
|
666
676
|
snippets: e.snippets ?? [],
|
|
667
677
|
sectionLabel: r,
|
|
668
678
|
copyAriaLabel: c,
|
|
@@ -672,7 +682,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
672
682
|
sectionClassName: m
|
|
673
683
|
}),
|
|
674
684
|
E && /* @__PURE__ */ K("section", { children: [/* @__PURE__ */ G("p", {
|
|
675
|
-
className: M("mb-3 mt-0", m,
|
|
685
|
+
className: M("mb-3 mt-0", m, sn.sectionHeading),
|
|
676
686
|
children: o
|
|
677
687
|
}), /* @__PURE__ */ G(k, {
|
|
678
688
|
language: "bash",
|
|
@@ -683,7 +693,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
683
693
|
hideDownload: !0
|
|
684
694
|
})] }),
|
|
685
695
|
D && /* @__PURE__ */ K("section", { children: [/* @__PURE__ */ G("p", {
|
|
686
|
-
className: M("mb-3 mt-0", m,
|
|
696
|
+
className: M("mb-3 mt-0", m, sn.sectionHeading),
|
|
687
697
|
children: s
|
|
688
698
|
}), /* @__PURE__ */ G(k, {
|
|
689
699
|
language: "json",
|
|
@@ -695,26 +705,26 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
695
705
|
})] })
|
|
696
706
|
]
|
|
697
707
|
});
|
|
698
|
-
},
|
|
708
|
+
}, fn = {
|
|
699
709
|
sunkenBox: "_sunkenBox_1lqi3_1",
|
|
700
710
|
raisedBox: "_raisedBox_1lqi3_5",
|
|
701
711
|
activeIcon: "_activeIcon_1lqi3_9"
|
|
702
|
-
},
|
|
712
|
+
}, pn = /* @__PURE__ */ function(e) {
|
|
703
713
|
return e.Sunken = "sunken", e.Raised = "raised", e;
|
|
704
|
-
}({}),
|
|
705
|
-
sunken:
|
|
706
|
-
raised:
|
|
707
|
-
},
|
|
714
|
+
}({}), mn = {
|
|
715
|
+
sunken: fn.sunkenBox,
|
|
716
|
+
raised: fn.raisedBox
|
|
717
|
+
}, hn = ({ icon: e, isActive: t = !1, surface: n = "sunken", statusLabel: r }) => /* @__PURE__ */ K("span", {
|
|
708
718
|
className: "relative inline-flex shrink-0",
|
|
709
719
|
children: [
|
|
710
720
|
/* @__PURE__ */ G("span", {
|
|
711
|
-
className: M("flex size-8 items-center justify-center rounded-lg",
|
|
721
|
+
className: M("flex size-8 items-center justify-center rounded-lg", mn[n]),
|
|
712
722
|
children: e
|
|
713
723
|
}),
|
|
714
|
-
t && /* @__PURE__ */ G(
|
|
715
|
-
size:
|
|
724
|
+
t && /* @__PURE__ */ G(Xe, {
|
|
725
|
+
size: z.MD,
|
|
716
726
|
"aria-hidden": !0,
|
|
717
|
-
className: M("absolute -end-2 -top-2",
|
|
727
|
+
className: M("absolute -end-2 -top-2", fn.activeIcon)
|
|
718
728
|
}),
|
|
719
729
|
r != null && /* @__PURE__ */ G("span", {
|
|
720
730
|
role: "status",
|
|
@@ -722,27 +732,27 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
722
732
|
children: r
|
|
723
733
|
})
|
|
724
734
|
]
|
|
725
|
-
}),
|
|
735
|
+
}), gn = {
|
|
726
736
|
card: "_card_tqnz7_1",
|
|
727
737
|
icon: "_icon_tqnz7_6",
|
|
728
738
|
title: "_title_tqnz7_10",
|
|
729
739
|
description: "_description_tqnz7_14"
|
|
730
|
-
},
|
|
740
|
+
}, _n = ({ icon: e, title: t, description: n, action: r, titleClassName: i = "dial-small-semi-text", descriptionClassName: a = "dial-small-text" }) => /* @__PURE__ */ K("div", {
|
|
731
741
|
role: "status",
|
|
732
742
|
"aria-live": "polite",
|
|
733
|
-
className: M("flex items-center gap-3 rounded-xl p-3",
|
|
743
|
+
className: M("flex items-center gap-3 rounded-xl p-3", gn.card),
|
|
734
744
|
children: [/* @__PURE__ */ G("span", {
|
|
735
|
-
className: M("shrink-0",
|
|
745
|
+
className: M("shrink-0", gn.icon, n != null && "mt-0.5"),
|
|
736
746
|
children: e
|
|
737
747
|
}), /* @__PURE__ */ K("div", {
|
|
738
748
|
className: "flex min-w-0 flex-1 items-center justify-between gap-2",
|
|
739
749
|
children: [/* @__PURE__ */ K("div", {
|
|
740
750
|
className: "flex min-w-0 flex-col gap-1",
|
|
741
751
|
children: [/* @__PURE__ */ G("span", {
|
|
742
|
-
className: M(i,
|
|
752
|
+
className: M(i, gn.title),
|
|
743
753
|
children: t
|
|
744
754
|
}), n != null && /* @__PURE__ */ G("span", {
|
|
745
|
-
className: M(a,
|
|
755
|
+
className: M(a, gn.description),
|
|
746
756
|
children: n
|
|
747
757
|
})]
|
|
748
758
|
}), r != null && /* @__PURE__ */ G("div", {
|
|
@@ -750,80 +760,80 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
750
760
|
children: r
|
|
751
761
|
})]
|
|
752
762
|
})]
|
|
753
|
-
}),
|
|
754
|
-
let r = /* @__PURE__ */ G(
|
|
755
|
-
size:
|
|
763
|
+
}), vn = (e) => e === y.ApiKey ? "You are currently using organization API key to access this toolset." : "You are currently using organization credentials to access this toolset.", yn = (e) => e === y.ApiKey ? "Configure your personal API key to have access to your data." : "Login using personal account to have access to your data.", bn = (e) => e === y.ApiKey ? "Signed in with organization API key." : "Signed in with organization credentials.", xn = (e) => e === y.ApiKey ? "Signed in with personal API key." : "Signed in with personal credentials.", Sn = 20, Cn = ({ state: e, authenticationType: t, texts: n }) => {
|
|
764
|
+
let r = /* @__PURE__ */ G(Ge, {
|
|
765
|
+
size: Sn,
|
|
756
766
|
"aria-hidden": !0,
|
|
757
|
-
stroke:
|
|
767
|
+
stroke: B
|
|
758
768
|
});
|
|
759
769
|
if (e === v.PersonalCredentialsActive) {
|
|
760
|
-
let e = (n?.personalCredentialsActiveBannerTitle ??
|
|
761
|
-
return /* @__PURE__ */ G(
|
|
762
|
-
icon: /* @__PURE__ */ G(
|
|
770
|
+
let e = (n?.personalCredentialsActiveBannerTitle ?? xn)(t);
|
|
771
|
+
return /* @__PURE__ */ G(_n, {
|
|
772
|
+
icon: /* @__PURE__ */ G(hn, {
|
|
763
773
|
icon: /* @__PURE__ */ G(ft, {
|
|
764
|
-
size:
|
|
774
|
+
size: z.SM,
|
|
765
775
|
"aria-hidden": !0,
|
|
766
|
-
stroke:
|
|
776
|
+
stroke: B
|
|
767
777
|
}),
|
|
768
778
|
isActive: !0,
|
|
769
|
-
surface:
|
|
779
|
+
surface: pn.Raised
|
|
770
780
|
}),
|
|
771
781
|
title: e
|
|
772
782
|
});
|
|
773
783
|
}
|
|
774
784
|
if (e === v.OrgCredentialsActive) {
|
|
775
|
-
let e = (n?.orgCredentialsActiveBannerTitle ??
|
|
776
|
-
return /* @__PURE__ */ G(
|
|
777
|
-
icon: /* @__PURE__ */ G(
|
|
778
|
-
icon: /* @__PURE__ */ G(
|
|
779
|
-
size:
|
|
785
|
+
let e = (n?.orgCredentialsActiveBannerTitle ?? bn)(t);
|
|
786
|
+
return /* @__PURE__ */ G(_n, {
|
|
787
|
+
icon: /* @__PURE__ */ G(hn, {
|
|
788
|
+
icon: /* @__PURE__ */ G(Ge, {
|
|
789
|
+
size: z.SM,
|
|
780
790
|
"aria-hidden": !0,
|
|
781
|
-
stroke:
|
|
791
|
+
stroke: B
|
|
782
792
|
}),
|
|
783
793
|
isActive: !0,
|
|
784
|
-
surface:
|
|
794
|
+
surface: pn.Raised
|
|
785
795
|
}),
|
|
786
796
|
title: e
|
|
787
797
|
});
|
|
788
798
|
}
|
|
789
|
-
return /* @__PURE__ */ G(
|
|
799
|
+
return /* @__PURE__ */ G(_n, {
|
|
790
800
|
icon: r,
|
|
791
|
-
title: (n?.orgFallbackBannerTitle ??
|
|
792
|
-
description: (n?.orgFallbackBannerDescription ??
|
|
801
|
+
title: (n?.orgFallbackBannerTitle ?? vn)(t),
|
|
802
|
+
description: (n?.orgFallbackBannerDescription ?? yn)(t)
|
|
793
803
|
});
|
|
794
|
-
},
|
|
795
|
-
surface: "
|
|
796
|
-
description: "
|
|
797
|
-
rowDescription: "
|
|
798
|
-
errorText: "
|
|
799
|
-
},
|
|
800
|
-
let
|
|
801
|
-
|
|
802
|
-
}, []),
|
|
803
|
-
if (
|
|
804
|
+
}, wn = {
|
|
805
|
+
surface: "_surface_1q3s8_1",
|
|
806
|
+
description: "_description_1q3s8_5",
|
|
807
|
+
rowDescription: "_rowDescription_1q3s8_9",
|
|
808
|
+
errorText: "_errorText_1q3s8_13"
|
|
809
|
+
}, Tn = ({ label: e, description: t, icon: n, status: r, isActive: i, authenticationType: a, apiKeyAddedWhen: s, apiKeyHeader: c, onLogin: l, onRequestLogout: u, onRequestDeleteApiKey: d, texts: f, labelClassName: p, descriptionClassName: m, errorClassName: h, keyCardTitleClassName: g, keyCardDescriptionClassName: _, deleteActionClassName: v, disabled: b = !1, isPending: x = !1, renderLoginOptions: S, children: C }) => {
|
|
810
|
+
let w = oe(), [T, E] = R(), [D, O] = R(""), [ee, k] = R(!1), [A, te] = R(!1), ne = r === o.SignedIn, re = P((e) => {
|
|
811
|
+
O(e ?? ""), k(!1), E(void 0);
|
|
812
|
+
}, []), j = async () => {
|
|
813
|
+
if (A || b) return;
|
|
804
814
|
let e = a === y.ApiKey;
|
|
805
|
-
if (e && !
|
|
806
|
-
|
|
815
|
+
if (e && !D.trim()) {
|
|
816
|
+
k(!0);
|
|
807
817
|
return;
|
|
808
818
|
}
|
|
809
|
-
|
|
819
|
+
te(!0), E(void 0);
|
|
810
820
|
try {
|
|
811
|
-
await
|
|
821
|
+
await l?.(e ? D : void 0) !== !1 && O("");
|
|
812
822
|
} catch (e) {
|
|
813
|
-
|
|
823
|
+
E(e instanceof Error ? e.message : String(e));
|
|
814
824
|
} finally {
|
|
815
|
-
|
|
825
|
+
te(!1);
|
|
816
826
|
}
|
|
817
|
-
},
|
|
827
|
+
}, ie = f?.loginActionLabel ?? "Log in", N = f?.logoutActionLabel ?? "Log out", ae = f?.addApiKeyActionLabel ?? "Add", F = f?.deleteActionLabel ?? "Delete", se = f?.credentialsSignedInLabel ?? "Signed in", I = f?.credentialsSignedOutLabel ?? "Signed out", L = f?.addingApiKeyStatusLabel ?? "Adding", ce = f?.apiKeyConfiguredMessage ?? "Key has been configured", le = `${w}-header-hint`, de = c ? (f?.apiKeyHeaderHint ?? ((e) => `Enter your API key value for "${e}" header`))(c) : void 0, fe = s == null ? void 0 : (f?.apiKeyAddedLabel ?? ((e) => `Added ${e}`))(s);
|
|
818
828
|
return /* @__PURE__ */ K("div", {
|
|
819
829
|
role: "group",
|
|
820
830
|
"aria-label": e,
|
|
821
|
-
"aria-busy":
|
|
831
|
+
"aria-busy": A || x,
|
|
822
832
|
className: "flex min-w-0 items-start gap-3 rounded-xl p-3",
|
|
823
|
-
children: [/* @__PURE__ */ G(
|
|
833
|
+
children: [/* @__PURE__ */ G(hn, {
|
|
824
834
|
icon: n,
|
|
825
835
|
isActive: i,
|
|
826
|
-
statusLabel: i ?
|
|
836
|
+
statusLabel: i ? se : I
|
|
827
837
|
}), /* @__PURE__ */ K("div", {
|
|
828
838
|
className: "flex min-w-0 flex-1 flex-col gap-1",
|
|
829
839
|
children: [
|
|
@@ -832,101 +842,110 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
832
842
|
children: [/* @__PURE__ */ K("div", {
|
|
833
843
|
className: "flex min-w-0 flex-1 flex-col gap-0.5 break-words",
|
|
834
844
|
children: [/* @__PURE__ */ G("span", {
|
|
835
|
-
className:
|
|
845
|
+
className: p,
|
|
836
846
|
children: e
|
|
837
847
|
}), /* @__PURE__ */ G("span", {
|
|
838
|
-
className: M(
|
|
848
|
+
className: M(m, wn.rowDescription),
|
|
839
849
|
children: t
|
|
840
850
|
})]
|
|
841
|
-
}), a === y.OAuth && (
|
|
842
|
-
appearance:
|
|
843
|
-
label:
|
|
851
|
+
}), a === y.OAuth && (ne ? u && /* @__PURE__ */ G(ge, {
|
|
852
|
+
appearance: ue.Ghost,
|
|
853
|
+
label: N,
|
|
844
854
|
className: "min-h-11 min-w-28 shrink-0 justify-center whitespace-nowrap",
|
|
845
|
-
onClick:
|
|
846
|
-
disabled:
|
|
847
|
-
}) : /* @__PURE__ */ G(
|
|
848
|
-
label:
|
|
849
|
-
"aria-label":
|
|
850
|
-
iconBefore:
|
|
851
|
-
size:
|
|
852
|
-
ariaLabel:
|
|
855
|
+
onClick: u,
|
|
856
|
+
disabled: A || b
|
|
857
|
+
}) : /* @__PURE__ */ G(H, {
|
|
858
|
+
label: A ? void 0 : ie,
|
|
859
|
+
"aria-label": ie,
|
|
860
|
+
iconBefore: A ? /* @__PURE__ */ G(Re, {
|
|
861
|
+
size: z.SM,
|
|
862
|
+
ariaLabel: ie
|
|
853
863
|
}) : void 0,
|
|
854
|
-
disabled:
|
|
864
|
+
disabled: A || b,
|
|
855
865
|
className: "min-h-11 min-w-28 shrink-0 justify-center whitespace-nowrap",
|
|
856
|
-
onClick:
|
|
866
|
+
onClick: j
|
|
857
867
|
}))]
|
|
858
868
|
}),
|
|
859
|
-
a === y.ApiKey && !
|
|
869
|
+
a === y.ApiKey && !ne && /* @__PURE__ */ K("div", {
|
|
860
870
|
className: "flex animate-fadeIn flex-col gap-1 pt-1",
|
|
861
|
-
children: [
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
871
|
+
children: [
|
|
872
|
+
/* @__PURE__ */ K("div", {
|
|
873
|
+
className: "flex items-end gap-2",
|
|
874
|
+
children: [/* @__PURE__ */ G(Ee, {
|
|
875
|
+
id: w,
|
|
876
|
+
"aria-describedby": de ? le : void 0,
|
|
877
|
+
type: "password",
|
|
878
|
+
autoComplete: "off",
|
|
879
|
+
value: D,
|
|
880
|
+
onChange: re,
|
|
881
|
+
labelProps: { label: f?.apiKeyFieldLabel ?? "API key" },
|
|
882
|
+
invalid: ee,
|
|
883
|
+
disabled: A || b,
|
|
884
|
+
containerClassName: "min-w-0 flex-1"
|
|
885
|
+
}), /* @__PURE__ */ G(H, {
|
|
886
|
+
label: A ? void 0 : ae,
|
|
887
|
+
"aria-label": A ? L : void 0,
|
|
888
|
+
iconBefore: A ? /* @__PURE__ */ G(Re, {
|
|
889
|
+
size: z.SM,
|
|
890
|
+
ariaLabel: L
|
|
891
|
+
}) : void 0,
|
|
892
|
+
className: "min-h-11 shrink-0 whitespace-nowrap",
|
|
893
|
+
onClick: j,
|
|
894
|
+
disabled: A || b
|
|
895
|
+
})]
|
|
896
|
+
}),
|
|
897
|
+
de && /* @__PURE__ */ G("span", {
|
|
898
|
+
id: le,
|
|
899
|
+
className: M(m, wn.rowDescription),
|
|
900
|
+
children: de
|
|
901
|
+
}),
|
|
902
|
+
ee && /* @__PURE__ */ G("span", {
|
|
903
|
+
role: "alert",
|
|
904
|
+
className: M(h, wn.errorText),
|
|
905
|
+
children: f?.apiKeyRequiredErrorMessage ?? "API key is required."
|
|
906
|
+
})
|
|
907
|
+
]
|
|
889
908
|
}),
|
|
890
|
-
a === y.ApiKey &&
|
|
909
|
+
a === y.ApiKey && ne && /* @__PURE__ */ G("div", {
|
|
891
910
|
className: "animate-fadeIn pt-1",
|
|
892
|
-
children: /* @__PURE__ */ G(
|
|
893
|
-
icon: /* @__PURE__ */ G(
|
|
894
|
-
size:
|
|
911
|
+
children: /* @__PURE__ */ G(_n, {
|
|
912
|
+
icon: /* @__PURE__ */ G(tt, {
|
|
913
|
+
size: z.SM,
|
|
895
914
|
"aria-hidden": !0,
|
|
896
|
-
stroke:
|
|
915
|
+
stroke: B
|
|
897
916
|
}),
|
|
898
|
-
title:
|
|
899
|
-
description:
|
|
900
|
-
titleClassName:
|
|
901
|
-
descriptionClassName:
|
|
902
|
-
action:
|
|
903
|
-
label:
|
|
904
|
-
className: M("min-h-11",
|
|
905
|
-
onClick:
|
|
906
|
-
disabled:
|
|
917
|
+
title: ce,
|
|
918
|
+
description: fe,
|
|
919
|
+
titleClassName: g,
|
|
920
|
+
descriptionClassName: _,
|
|
921
|
+
action: d && /* @__PURE__ */ G(De, {
|
|
922
|
+
label: F,
|
|
923
|
+
className: M("min-h-11", v),
|
|
924
|
+
onClick: d,
|
|
925
|
+
disabled: A || b
|
|
907
926
|
})
|
|
908
927
|
})
|
|
909
928
|
}),
|
|
910
|
-
!
|
|
911
|
-
|
|
929
|
+
!ne && S?.(A || b),
|
|
930
|
+
T && /* @__PURE__ */ G("p", {
|
|
912
931
|
role: "alert",
|
|
913
|
-
className: M(
|
|
914
|
-
children:
|
|
932
|
+
className: M(h, wn.errorText),
|
|
933
|
+
children: T
|
|
915
934
|
}),
|
|
916
|
-
|
|
935
|
+
C
|
|
917
936
|
]
|
|
918
937
|
})]
|
|
919
938
|
});
|
|
920
|
-
},
|
|
939
|
+
}, En = (e) => e === y.ApiKey ? "Select which account to use with this toolset — personal or organization. If both are configured, personal credentials will be used by default for toolset access." : "Select which account to use with this toolset — personal or organization. If both are configured, personal credentials will be used by default.", Dn = ({ item: e, onLogin: t, onRequestLogout: n, onRequestDeleteApiKey: r, texts: i, detailsStyles: a, deleteActionClassName: s = "text-error" }) => {
|
|
921
940
|
let { credentialsDescriptionClassName: c = "dial-body-paragraph-text", credentialsRowLabelClassName: l = "dial-small-semi-text", credentialsRowDescriptionClassName: u = "dial-small-text", credentialsErrorClassName: d = "dial-caption-text", credentialsKeyCardTitleClassName: f = "dial-tiny-semi-text", credentialsKeyCardDescriptionClassName: p = "dial-tiny-text" } = a?.typography ?? {}, m = e.credentials;
|
|
922
941
|
if (m == null) return null;
|
|
923
|
-
let h = (i?.credentialsManagementDescription ??
|
|
942
|
+
let h = (i?.credentialsManagementDescription ?? En)(m.authenticationType), g = m.userStatus === o.SignedIn, _ = !g && m.globalStatus === o.SignedIn;
|
|
924
943
|
return /* @__PURE__ */ K("div", {
|
|
925
944
|
className: "flex flex-col",
|
|
926
945
|
children: [/* @__PURE__ */ G("div", {
|
|
927
946
|
className: "px-6 py-4",
|
|
928
947
|
children: /* @__PURE__ */ G("div", {
|
|
929
|
-
className: M("rounded-xl p-3",
|
|
948
|
+
className: M("rounded-xl p-3", wn.surface),
|
|
930
949
|
children: /* @__PURE__ */ G(E, {
|
|
931
950
|
item: e,
|
|
932
951
|
iconSize: 40,
|
|
@@ -936,22 +955,23 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
936
955
|
}), /* @__PURE__ */ K("div", {
|
|
937
956
|
className: "flex flex-col gap-5 px-6 py-4",
|
|
938
957
|
children: [/* @__PURE__ */ G("span", {
|
|
939
|
-
className: M(c,
|
|
958
|
+
className: M(c, wn.description),
|
|
940
959
|
children: h
|
|
941
960
|
}), /* @__PURE__ */ K("div", {
|
|
942
961
|
className: "flex flex-col",
|
|
943
|
-
children: [/* @__PURE__ */ G(
|
|
962
|
+
children: [/* @__PURE__ */ G(Tn, {
|
|
944
963
|
label: i?.personalCredentialsLabel ?? "Personal credentials",
|
|
945
964
|
description: i?.personalCredentialsDescription ?? "These credentials apply only to your account.",
|
|
946
965
|
icon: /* @__PURE__ */ G(ft, {
|
|
947
|
-
size:
|
|
966
|
+
size: z.SM,
|
|
948
967
|
"aria-hidden": !0,
|
|
949
|
-
stroke:
|
|
968
|
+
stroke: B
|
|
950
969
|
}),
|
|
951
970
|
status: m.userStatus,
|
|
952
971
|
isActive: g,
|
|
953
972
|
authenticationType: m.authenticationType,
|
|
954
973
|
apiKeyAddedWhen: m.userApiKeyAddedWhen,
|
|
974
|
+
apiKeyHeader: m.apiKeyHeader,
|
|
955
975
|
onLogin: (n) => t?.(e, {
|
|
956
976
|
level: b.User,
|
|
957
977
|
...n == null ? {} : { apiKey: n }
|
|
@@ -965,18 +985,19 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
965
985
|
keyCardTitleClassName: f,
|
|
966
986
|
keyCardDescriptionClassName: p,
|
|
967
987
|
deleteActionClassName: s
|
|
968
|
-
}), /* @__PURE__ */ G(
|
|
988
|
+
}), /* @__PURE__ */ G(Tn, {
|
|
969
989
|
label: i?.organizationCredentialsLabel ?? "Organization credentials",
|
|
970
990
|
description: i?.organizationCredentialsDescription ?? "Once added, these credentials will grant all users in your organization access to this toolset.",
|
|
971
|
-
icon: /* @__PURE__ */ G(
|
|
972
|
-
size:
|
|
991
|
+
icon: /* @__PURE__ */ G(Ge, {
|
|
992
|
+
size: z.SM,
|
|
973
993
|
"aria-hidden": !0,
|
|
974
|
-
stroke:
|
|
994
|
+
stroke: B
|
|
975
995
|
}),
|
|
976
996
|
status: m.globalStatus,
|
|
977
997
|
isActive: _,
|
|
978
998
|
authenticationType: m.authenticationType,
|
|
979
999
|
apiKeyAddedWhen: m.globalApiKeyAddedWhen,
|
|
1000
|
+
apiKeyHeader: m.apiKeyHeader,
|
|
980
1001
|
onLogin: (n) => t?.(e, {
|
|
981
1002
|
level: b.Global,
|
|
982
1003
|
...n == null ? {} : { apiKey: n }
|
|
@@ -994,118 +1015,138 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
994
1015
|
})]
|
|
995
1016
|
})]
|
|
996
1017
|
});
|
|
997
|
-
},
|
|
1018
|
+
}, On = {
|
|
998
1019
|
skeletonColor: "var(--cat-details-skeleton, var(--bg-control-disable-primary, #dce0e8))",
|
|
999
1020
|
backdrop: "_backdrop_1i04q_7",
|
|
1000
1021
|
panel: "_panel_1i04q_11",
|
|
1001
1022
|
divider: "_divider_1i04q_16",
|
|
1002
1023
|
content: "_content_1i04q_20",
|
|
1003
1024
|
publishTitle: "_publishTitle_1i04q_25"
|
|
1004
|
-
},
|
|
1025
|
+
}, kn = /* @__PURE__ */ function(e) {
|
|
1005
1026
|
return e.Idle = "idle", e.Loading = "loading", e.Resolved = "resolved", e.Unknown = "unknown", e;
|
|
1006
|
-
}({}),
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1027
|
+
}({}), An = {
|
|
1028
|
+
divider: "_divider_1ae8j_1",
|
|
1029
|
+
hint: "_hint_1ae8j_5"
|
|
1030
|
+
}, jn = 16, Mn = ({ item: e, level: t, status: n, apiKeyAddedWhen: r, apiKeyHeader: i, onLogin: a, onLogout: s, onClose: c, texts: l, colors: u, deleteActionClassName: d = "text-error" }) => {
|
|
1031
|
+
let [f, p] = R(""), [m, h] = R(!1), [g, _] = R(!1), [v, y] = R(!1), b = n === o.SignedIn, x = P((e) => {
|
|
1032
|
+
p(e ?? ""), h(!1);
|
|
1033
|
+
}, []), S = P(async () => {
|
|
1034
|
+
if (f.trim().length === 0) {
|
|
1035
|
+
h(!0);
|
|
1012
1036
|
return;
|
|
1013
1037
|
}
|
|
1014
|
-
|
|
1038
|
+
_(!0);
|
|
1015
1039
|
try {
|
|
1016
|
-
await
|
|
1040
|
+
await a?.(e, {
|
|
1017
1041
|
level: t,
|
|
1018
|
-
apiKey:
|
|
1019
|
-
}),
|
|
1042
|
+
apiKey: f
|
|
1043
|
+
}), c();
|
|
1020
1044
|
} finally {
|
|
1021
|
-
|
|
1045
|
+
_(!1);
|
|
1022
1046
|
}
|
|
1023
1047
|
}, [
|
|
1024
1048
|
e,
|
|
1025
1049
|
t,
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
]),
|
|
1030
|
-
|
|
1050
|
+
f,
|
|
1051
|
+
a,
|
|
1052
|
+
c
|
|
1053
|
+
]), C = P(async () => {
|
|
1054
|
+
y(!0);
|
|
1031
1055
|
try {
|
|
1032
|
-
await
|
|
1056
|
+
await s?.(e, { level: t }), c();
|
|
1033
1057
|
} finally {
|
|
1034
|
-
|
|
1058
|
+
y(!1);
|
|
1035
1059
|
}
|
|
1036
1060
|
}, [
|
|
1037
1061
|
e,
|
|
1038
1062
|
t,
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
]),
|
|
1063
|
+
s,
|
|
1064
|
+
c
|
|
1065
|
+
]), w = l?.personalApiKeyPanelTitle ?? "Personal API key", T = l?.addApiKeyActionLabel ?? "Add", E = l?.deleteActionLabel ?? "Delete", D = l?.addingApiKeyStatusLabel ?? "Adding", O = l?.deletingStatusLabel ?? "Deleting", ee = l?.apiKeyRequiredErrorMessage ?? "API key is required.", k = l?.personalApiKeyAddedMessage ?? "Personal key has been added", A = `catalog-item-${e.id}-${t}-api-key`, te = `${A}-header-hint`, ne = i ? (l?.apiKeyHeaderHint ?? ((e) => `Enter your API key value for "${e}" header`))(i) : void 0, re = r == null ? void 0 : (l?.apiKeyAddedLabel ?? ((e) => `Added ${e}`))(r);
|
|
1042
1066
|
return /* @__PURE__ */ K("div", {
|
|
1043
1067
|
className: "flex w-[418px] flex-col",
|
|
1068
|
+
style: j({
|
|
1069
|
+
"--cat-details-divider": u?.divider,
|
|
1070
|
+
"--cat-cred-hint-text": u?.credentialsHintText,
|
|
1071
|
+
"--cat-cred-card-bg": u?.credentialsCardBackground,
|
|
1072
|
+
"--cat-cred-card-icon": u?.credentialsCardIcon,
|
|
1073
|
+
"--cat-cred-card-title-text": u?.credentialsCardTitleText,
|
|
1074
|
+
"--cat-cred-card-description-text": u?.credentialsCardDescriptionText
|
|
1075
|
+
}),
|
|
1044
1076
|
children: [
|
|
1045
1077
|
/* @__PURE__ */ G("div", {
|
|
1046
1078
|
className: "flex items-center gap-2 px-4 py-3",
|
|
1047
1079
|
children: /* @__PURE__ */ G("span", {
|
|
1048
1080
|
className: "dial-small-semi-text",
|
|
1049
|
-
children:
|
|
1081
|
+
children: w
|
|
1050
1082
|
})
|
|
1051
1083
|
}),
|
|
1052
|
-
/* @__PURE__ */ G("div", { className: M("mx-4 h-px",
|
|
1053
|
-
!
|
|
1084
|
+
/* @__PURE__ */ G("div", { className: M("mx-4 h-px", An.divider) }),
|
|
1085
|
+
!b && /* @__PURE__ */ K("div", {
|
|
1054
1086
|
className: "flex animate-fadeIn flex-col gap-1 px-4 py-3.5",
|
|
1055
|
-
children: [
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1087
|
+
children: [
|
|
1088
|
+
/* @__PURE__ */ K("div", {
|
|
1089
|
+
className: "flex items-end gap-2",
|
|
1090
|
+
children: [/* @__PURE__ */ G(Ee, {
|
|
1091
|
+
id: A,
|
|
1092
|
+
"aria-describedby": ne ? te : void 0,
|
|
1093
|
+
type: "password",
|
|
1094
|
+
autoComplete: "current-password",
|
|
1095
|
+
value: f,
|
|
1096
|
+
onChange: x,
|
|
1097
|
+
labelProps: { label: l?.apiKeyFieldLabel ?? "API key" },
|
|
1098
|
+
invalid: m,
|
|
1099
|
+
disabled: g,
|
|
1100
|
+
containerClassName: "min-w-0 flex-1"
|
|
1101
|
+
}), /* @__PURE__ */ G(H, {
|
|
1102
|
+
label: g ? void 0 : T,
|
|
1103
|
+
"aria-label": g ? D : void 0,
|
|
1104
|
+
iconBefore: g ? /* @__PURE__ */ G(Re, {
|
|
1105
|
+
size: jn,
|
|
1106
|
+
ariaLabel: D
|
|
1107
|
+
}) : void 0,
|
|
1108
|
+
onClick: S,
|
|
1109
|
+
disabled: g
|
|
1110
|
+
})]
|
|
1111
|
+
}),
|
|
1112
|
+
ne && /* @__PURE__ */ G("span", {
|
|
1113
|
+
id: te,
|
|
1114
|
+
className: M("dial-caption-text", An.hint),
|
|
1115
|
+
children: ne
|
|
1116
|
+
}),
|
|
1117
|
+
m && /* @__PURE__ */ G("span", {
|
|
1118
|
+
className: "dial-caption-text text-error",
|
|
1119
|
+
children: ee
|
|
1120
|
+
})
|
|
1121
|
+
]
|
|
1081
1122
|
}),
|
|
1082
|
-
|
|
1123
|
+
b && /* @__PURE__ */ G("div", {
|
|
1083
1124
|
className: "animate-fadeIn px-4 py-3.5",
|
|
1084
|
-
children: /* @__PURE__ */ G(
|
|
1085
|
-
icon: /* @__PURE__ */ G(
|
|
1125
|
+
children: /* @__PURE__ */ G(_n, {
|
|
1126
|
+
icon: /* @__PURE__ */ G(tt, {
|
|
1086
1127
|
size: 20,
|
|
1087
1128
|
"aria-hidden": !0,
|
|
1088
|
-
stroke:
|
|
1129
|
+
stroke: B
|
|
1089
1130
|
}),
|
|
1090
|
-
title:
|
|
1091
|
-
description:
|
|
1092
|
-
action: /* @__PURE__ */ G(
|
|
1093
|
-
label:
|
|
1094
|
-
"aria-label":
|
|
1095
|
-
iconBefore:
|
|
1096
|
-
size:
|
|
1097
|
-
ariaLabel:
|
|
1131
|
+
title: k,
|
|
1132
|
+
description: re,
|
|
1133
|
+
action: /* @__PURE__ */ G(De, {
|
|
1134
|
+
label: v ? void 0 : E,
|
|
1135
|
+
"aria-label": v ? O : void 0,
|
|
1136
|
+
iconBefore: v ? /* @__PURE__ */ G(Re, {
|
|
1137
|
+
size: jn,
|
|
1138
|
+
ariaLabel: O
|
|
1098
1139
|
}) : void 0,
|
|
1099
|
-
className:
|
|
1100
|
-
onClick:
|
|
1101
|
-
disabled:
|
|
1140
|
+
className: d,
|
|
1141
|
+
onClick: C,
|
|
1142
|
+
disabled: v
|
|
1102
1143
|
})
|
|
1103
1144
|
})
|
|
1104
1145
|
})
|
|
1105
1146
|
]
|
|
1106
1147
|
});
|
|
1107
|
-
},
|
|
1108
|
-
let [a, o] =
|
|
1148
|
+
}, Nn = { name: "_name_gfs1p_1" }, Pn = (e) => e.isMyApp === !0, Fn = ({ item: e, onShare: t, shareOverlay: n, isShareVisible: r, label: i = "Share" }) => {
|
|
1149
|
+
let [a, o] = R(!1), s = P(() => {
|
|
1109
1150
|
if (n) {
|
|
1110
1151
|
o((e) => !e);
|
|
1111
1152
|
return;
|
|
@@ -1116,22 +1157,22 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1116
1157
|
t,
|
|
1117
1158
|
n
|
|
1118
1159
|
]);
|
|
1119
|
-
if (!
|
|
1120
|
-
let c = /* @__PURE__ */ G(
|
|
1160
|
+
if (!Pn(e) || r && !r(e)) return null;
|
|
1161
|
+
let c = /* @__PURE__ */ G(H, {
|
|
1121
1162
|
label: i,
|
|
1122
|
-
iconBefore: /* @__PURE__ */ G(
|
|
1123
|
-
size:
|
|
1124
|
-
stroke:
|
|
1163
|
+
iconBefore: /* @__PURE__ */ G(lt, {
|
|
1164
|
+
size: z.MD,
|
|
1165
|
+
stroke: B
|
|
1125
1166
|
}),
|
|
1126
|
-
iconAfter: /* @__PURE__ */ G(
|
|
1127
|
-
size:
|
|
1128
|
-
stroke:
|
|
1167
|
+
iconAfter: /* @__PURE__ */ G(qe, {
|
|
1168
|
+
size: z.MD,
|
|
1169
|
+
stroke: B
|
|
1129
1170
|
}),
|
|
1130
1171
|
onClick: s,
|
|
1131
1172
|
"aria-haspopup": n ? "menu" : void 0,
|
|
1132
1173
|
"aria-expanded": n ? a : void 0
|
|
1133
1174
|
});
|
|
1134
|
-
return n ? /* @__PURE__ */ G(
|
|
1175
|
+
return n ? /* @__PURE__ */ G(_e, {
|
|
1135
1176
|
placement: "bottom-end",
|
|
1136
1177
|
matchReferenceWidth: !1,
|
|
1137
1178
|
open: a,
|
|
@@ -1141,49 +1182,49 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1141
1182
|
renderOverlay: () => n(e, () => o(!1)),
|
|
1142
1183
|
children: c
|
|
1143
1184
|
}) : c;
|
|
1144
|
-
},
|
|
1185
|
+
}, In = (e) => e === y.ApiKey ? "Manage API keys" : "Manage credentials", Ln = {
|
|
1145
1186
|
[St.LimitReached]: "bg-error text-error",
|
|
1146
1187
|
[St.RunningLow]: "bg-warning text-warning"
|
|
1147
|
-
},
|
|
1148
|
-
className: M("flex h-[24px] items-center justify-center gap-1 whitespace-nowrap rounded-2xl px-2", "dial-caption-lead-semi-text",
|
|
1188
|
+
}, Rn = ({ status: e, label: t }) => /* @__PURE__ */ G("div", {
|
|
1189
|
+
className: M("flex h-[24px] items-center justify-center gap-1 whitespace-nowrap rounded-2xl px-2", "dial-caption-lead-semi-text", Ln[e]),
|
|
1149
1190
|
children: t
|
|
1150
|
-
}),
|
|
1151
|
-
let { nameClassName:
|
|
1152
|
-
status:
|
|
1153
|
-
label:
|
|
1154
|
-
}),
|
|
1191
|
+
}), zn = ({ item: e, onUseInChat: t, isPrimaryActionVisible: r, onShare: i, shareOverlay: a, isShareVisible: o, isSharePrimary: s, onEdit: l, onDownload: u, isDownloadVisible: d, isDownloadPrimary: f, onDelete: p, onUnshare: m, isUnshareVisible: h, onRevokeShare: g, onFetchRecipientsCount: _, isRevokeShareVisible: v, onLogin: S, onLogout: C, onOpenCredentialsManagement: w, onRequestLogout: T, texts: D, detailsStyles: O, isPublishVisible: ee, isPublishPrimary: k, onOpenPublish: A, isUnpublishVisible: te, hasPublishedFolders: ne = !1, isPublishHistoryResolved: re = !0, onRequestPublishHistory: j, onOpenUnpublish: ie, isReadonly: N = !1 }) => {
|
|
1192
|
+
let { nameClassName: ae = "dial-body-semi-text", folderLabelClassName: oe = "dial-tiny-text", folderLeafClassName: se = "dial-tiny-semi-text" } = O?.typography ?? {}, ce = e.details?.limits?.status, le = ce == null ? void 0 : /* @__PURE__ */ G(Rn, {
|
|
1193
|
+
status: ce,
|
|
1194
|
+
label: ce === St.LimitReached ? D?.limitReachedLabel ?? "Limit reached" : D?.limitRunningLowLabel ?? "Running low"
|
|
1195
|
+
}), ue = P(() => {
|
|
1155
1196
|
t?.(e);
|
|
1156
|
-
}, [e, t]),
|
|
1197
|
+
}, [e, t]), de = P(() => {
|
|
1157
1198
|
l?.(e);
|
|
1158
|
-
}, [e, l]),
|
|
1199
|
+
}, [e, l]), fe = P(() => {
|
|
1159
1200
|
A?.();
|
|
1160
|
-
}, [A]),
|
|
1201
|
+
}, [A]), pe = P(() => {
|
|
1161
1202
|
ie?.();
|
|
1162
|
-
}, [ie]),
|
|
1203
|
+
}, [ie]), me = P(() => {
|
|
1163
1204
|
u?.(e);
|
|
1164
|
-
}, [e, u]), [
|
|
1165
|
-
|
|
1166
|
-
|
|
1205
|
+
}, [e, u]), [he, ve] = R(!1);
|
|
1206
|
+
F(() => {
|
|
1207
|
+
ve(!1);
|
|
1167
1208
|
}, [e.id]);
|
|
1168
|
-
let
|
|
1169
|
-
|
|
1209
|
+
let ye = P(() => {
|
|
1210
|
+
he || (ve(!0), (async () => {
|
|
1170
1211
|
try {
|
|
1171
1212
|
await u?.(e);
|
|
1172
1213
|
} catch {} finally {
|
|
1173
|
-
|
|
1214
|
+
ve(!1);
|
|
1174
1215
|
}
|
|
1175
1216
|
})());
|
|
1176
1217
|
}, [
|
|
1177
1218
|
e,
|
|
1178
1219
|
u,
|
|
1179
|
-
|
|
1180
|
-
]), [
|
|
1181
|
-
|
|
1182
|
-
|
|
1220
|
+
he
|
|
1221
|
+
]), [be, Se] = R(!1);
|
|
1222
|
+
F(() => {
|
|
1223
|
+
Se(!1);
|
|
1183
1224
|
}, [e.id]);
|
|
1184
|
-
let
|
|
1225
|
+
let V = P(() => {
|
|
1185
1226
|
if (a) {
|
|
1186
|
-
|
|
1227
|
+
Se(!0);
|
|
1187
1228
|
return;
|
|
1188
1229
|
}
|
|
1189
1230
|
i?.(e);
|
|
@@ -1191,29 +1232,29 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1191
1232
|
e,
|
|
1192
1233
|
i,
|
|
1193
1234
|
a
|
|
1194
|
-
]),
|
|
1195
|
-
|
|
1196
|
-
}, []),
|
|
1235
|
+
]), Ce = P(() => {
|
|
1236
|
+
Se(!1);
|
|
1237
|
+
}, []), we = P(() => {
|
|
1197
1238
|
m?.(e);
|
|
1198
|
-
}, [e, m]),
|
|
1239
|
+
}, [e, m]), Te = P(() => {
|
|
1199
1240
|
p?.(e);
|
|
1200
|
-
}, [e, p]),
|
|
1241
|
+
}, [e, p]), Ee = P(() => {
|
|
1201
1242
|
g?.(e);
|
|
1202
|
-
}, [e, g]), [
|
|
1203
|
-
|
|
1204
|
-
|
|
1243
|
+
}, [e, g]), [De, Oe] = R(kn.Idle), [ke, je] = R(void 0), Me = L(null);
|
|
1244
|
+
F(() => {
|
|
1245
|
+
Me.current = null, Oe(kn.Idle), je(void 0);
|
|
1205
1246
|
}, [e.id]);
|
|
1206
|
-
let
|
|
1207
|
-
if (!_ ||
|
|
1247
|
+
let Ne = P(() => {
|
|
1248
|
+
if (!_ || Me.current === e.id || !g || e.isMyApp !== !0 || v?.(e) === !1) return;
|
|
1208
1249
|
let t = e.id;
|
|
1209
|
-
|
|
1250
|
+
Me.current = t, Oe(kn.Loading), (async () => {
|
|
1210
1251
|
try {
|
|
1211
1252
|
let n = await _(e);
|
|
1212
|
-
if (
|
|
1213
|
-
|
|
1253
|
+
if (Me.current !== t) return;
|
|
1254
|
+
je(n), Oe(n == null ? kn.Unknown : kn.Resolved);
|
|
1214
1255
|
} catch {
|
|
1215
|
-
if (
|
|
1216
|
-
|
|
1256
|
+
if (Me.current !== t) return;
|
|
1257
|
+
je(void 0), Oe(kn.Unknown);
|
|
1217
1258
|
}
|
|
1218
1259
|
})();
|
|
1219
1260
|
}, [
|
|
@@ -1221,104 +1262,104 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1221
1262
|
_,
|
|
1222
1263
|
g,
|
|
1223
1264
|
v
|
|
1224
|
-
]), [
|
|
1225
|
-
|
|
1226
|
-
|
|
1265
|
+
]), [Pe, Fe] = R(!1);
|
|
1266
|
+
F(() => {
|
|
1267
|
+
Fe(!1);
|
|
1227
1268
|
}, [e.id]);
|
|
1228
|
-
let
|
|
1229
|
-
|
|
1230
|
-
}, [
|
|
1231
|
-
|
|
1232
|
-
}, [
|
|
1269
|
+
let Ie = P((e) => {
|
|
1270
|
+
Fe(e), e && (Ne(), j?.());
|
|
1271
|
+
}, [Ne, j]), Le = P(() => {
|
|
1272
|
+
Ne(), j?.();
|
|
1273
|
+
}, [Ne, j]), ze = P(() => {
|
|
1233
1274
|
j?.();
|
|
1234
|
-
}, [j]),
|
|
1275
|
+
}, [j]), Be = D?.hasPrimaryAction !== !1 && (r?.(e) ?? (e.type === x.Model || e.type === x.Agent || e.type === x.Prompt)), Ve = !N && !!ie && ne && (te?.(e) ?? !0), He = !N && !!ie && !re && te?.(e) === !0, Ue = !N && !Ve && (ee?.(e) ?? (e.type === x.Model || e.type === x.Toolset || e.type === x.Agent)), Ge = !N && !!l && !!e.isEditable, Ke = !N && e.isMyApp === !0 && (o?.(e) ?? !0), Je = s?.(e) ?? !0, Ye = k?.(e) ?? !1, Xe = e.credentials?.authenticationType ?? y.None, $e = e.credentials != null && Xe !== y.None ? c(e.credentials) : void 0, et = !N && $e != null && (!!S || !!C), nt = e.type === x.Toolset && et, rt = !!u && (d?.(e) ?? !0), ct = rt && !nt && (f?.(e) ?? (e.type === x.Skill && !Be)), ut = rt && !ct, dt = !N && e.isMyApp, ft = !N && !!m && e.isMyApp !== !0 && e.sharedWithMe === !0 && (h?.(e) ?? !0), _t = !N && !!g && e.isMyApp === !0 && (!_ || De === kn.Unknown || De === kn.Resolved && (ke ?? 0) > 0) && (v?.(e) ?? !0), vt = I(() => {
|
|
1235
1276
|
let e = [];
|
|
1236
|
-
if (!
|
|
1277
|
+
if (!Je && Ke && e.push({
|
|
1237
1278
|
key: "share",
|
|
1238
1279
|
label: D?.shareLabel ?? "Share",
|
|
1239
|
-
Icon:
|
|
1280
|
+
Icon: lt,
|
|
1240
1281
|
iconClassName: "text-secondary",
|
|
1241
|
-
onClick:
|
|
1242
|
-
}),
|
|
1282
|
+
onClick: V
|
|
1283
|
+
}), Ge && e.push({
|
|
1243
1284
|
key: "edit",
|
|
1244
1285
|
label: D?.editActionLabel ?? "Edit",
|
|
1245
|
-
Icon:
|
|
1286
|
+
Icon: ot,
|
|
1246
1287
|
iconClassName: "text-secondary",
|
|
1247
|
-
onClick:
|
|
1248
|
-
}),
|
|
1288
|
+
onClick: de
|
|
1289
|
+
}), ut && e.push({
|
|
1249
1290
|
key: "download",
|
|
1250
1291
|
label: D?.downloadActionLabel ?? "Download",
|
|
1251
|
-
Icon:
|
|
1292
|
+
Icon: Qe,
|
|
1252
1293
|
iconClassName: "text-secondary",
|
|
1253
|
-
onClick:
|
|
1254
|
-
}), !
|
|
1294
|
+
onClick: me
|
|
1295
|
+
}), !Ye && Ue && e.push({
|
|
1255
1296
|
key: "publish",
|
|
1256
1297
|
label: D?.publishLabel ?? "Publish",
|
|
1257
1298
|
Icon: ht,
|
|
1258
1299
|
iconClassName: "text-secondary",
|
|
1259
|
-
onClick:
|
|
1260
|
-
}), !
|
|
1300
|
+
onClick: fe
|
|
1301
|
+
}), !Ye && Ve && e.push({
|
|
1261
1302
|
key: "unpublish",
|
|
1262
1303
|
label: D?.unpublishLabel ?? "Unpublish",
|
|
1263
1304
|
Icon: mt,
|
|
1264
1305
|
iconClassName: "text-secondary",
|
|
1265
|
-
onClick:
|
|
1306
|
+
onClick: pe
|
|
1266
1307
|
}), _t) {
|
|
1267
1308
|
let t = D?.revokeShareLabel ?? "Revoke access", n = D?.revokeShareLabelWithCount ?? ((e) => `${t} (${e})`);
|
|
1268
1309
|
e.push({
|
|
1269
1310
|
key: "revoke-share",
|
|
1270
|
-
label:
|
|
1311
|
+
label: ke == null ? t : n(ke),
|
|
1271
1312
|
Icon: pt,
|
|
1272
1313
|
danger: !0,
|
|
1273
|
-
onClick:
|
|
1314
|
+
onClick: Ee
|
|
1274
1315
|
});
|
|
1275
1316
|
}
|
|
1276
1317
|
return ft && e.push({
|
|
1277
1318
|
key: "unshare",
|
|
1278
1319
|
label: D?.unshareLabel ?? "Remove from My List",
|
|
1279
1320
|
Icon: W,
|
|
1280
|
-
onClick:
|
|
1321
|
+
onClick: we
|
|
1281
1322
|
}), dt && e.push({
|
|
1282
1323
|
key: "delete",
|
|
1283
1324
|
label: D?.deleteActionLabel ?? "Delete",
|
|
1284
1325
|
Icon: W,
|
|
1285
1326
|
danger: !0,
|
|
1286
|
-
onClick:
|
|
1327
|
+
onClick: Te
|
|
1287
1328
|
}), e;
|
|
1288
1329
|
}, [
|
|
1289
|
-
Xe,
|
|
1290
1330
|
Je,
|
|
1291
|
-
|
|
1292
|
-
U,
|
|
1293
|
-
Ze,
|
|
1331
|
+
Ke,
|
|
1294
1332
|
Ge,
|
|
1333
|
+
ut,
|
|
1334
|
+
Ye,
|
|
1295
1335
|
Ue,
|
|
1336
|
+
Ve,
|
|
1296
1337
|
dt,
|
|
1297
1338
|
_t,
|
|
1298
|
-
|
|
1339
|
+
ke,
|
|
1299
1340
|
ft,
|
|
1300
1341
|
D,
|
|
1301
|
-
|
|
1342
|
+
V,
|
|
1343
|
+
de,
|
|
1344
|
+
me,
|
|
1302
1345
|
fe,
|
|
1303
|
-
he,
|
|
1304
1346
|
pe,
|
|
1305
|
-
|
|
1347
|
+
Te,
|
|
1306
1348
|
Ee,
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
]), yt = F(() => vt.map(({ key: e, label: t, Icon: n, iconClassName: r, danger: i, onClick: a }) => ({
|
|
1349
|
+
we
|
|
1350
|
+
]), yt = I(() => vt.map(({ key: e, label: t, Icon: n, iconClassName: r, danger: i, onClick: a }) => ({
|
|
1310
1351
|
key: e,
|
|
1311
1352
|
label: t,
|
|
1312
1353
|
icon: /* @__PURE__ */ G(n, {
|
|
1313
|
-
size:
|
|
1354
|
+
size: z.SM,
|
|
1314
1355
|
"aria-hidden": !0,
|
|
1315
1356
|
className: r,
|
|
1316
|
-
stroke:
|
|
1357
|
+
stroke: B
|
|
1317
1358
|
}),
|
|
1318
1359
|
danger: i,
|
|
1319
1360
|
onClick: a
|
|
1320
|
-
})), [vt]), bt = te?.(e), xt = !
|
|
1321
|
-
if (
|
|
1361
|
+
})), [vt]), bt = te?.(e), xt = !N && !!ie && (bt == null || bt && !re), q = !N && !!g && !!_ && e.isMyApp === !0 && (v?.(e) ?? !0), J = vt.length === 1 && !Pe && !xt && !q ? vt[0] : void 0, [Y, Ct] = R(!1), X = Xe === y.ApiKey && $e !== n.ManageCredentials, wt = Xe === y.ApiKey && $e === n.LogOut, Z = Xe !== y.ApiKey && $e !== n.ManageCredentials && $e === n.LogOut, Q = P(() => {
|
|
1362
|
+
if ($e === n.ManageCredentials) {
|
|
1322
1363
|
w?.();
|
|
1323
1364
|
return;
|
|
1324
1365
|
}
|
|
@@ -1326,34 +1367,34 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1326
1367
|
Ct((e) => !e);
|
|
1327
1368
|
return;
|
|
1328
1369
|
}
|
|
1329
|
-
if (
|
|
1370
|
+
if ($e === n.LogOut) {
|
|
1330
1371
|
T?.();
|
|
1331
1372
|
return;
|
|
1332
1373
|
}
|
|
1333
1374
|
S?.(e, { level: b.User });
|
|
1334
1375
|
}, [
|
|
1335
|
-
|
|
1376
|
+
$e,
|
|
1336
1377
|
X,
|
|
1337
1378
|
e,
|
|
1338
1379
|
S,
|
|
1339
1380
|
w,
|
|
1340
1381
|
T
|
|
1341
|
-
]), Tt =
|
|
1342
|
-
size:
|
|
1343
|
-
stroke:
|
|
1344
|
-
}) :
|
|
1345
|
-
size:
|
|
1346
|
-
stroke:
|
|
1347
|
-
}) : /* @__PURE__ */ G(
|
|
1348
|
-
size:
|
|
1349
|
-
stroke:
|
|
1350
|
-
}), Dt =
|
|
1351
|
-
size:
|
|
1382
|
+
]), Tt = $e === n.ManageCredentials ? (D?.manageCredentialsActionLabel ?? In)(Xe) : Xe === y.ApiKey ? $e === n.LogOut ? D?.changeApiKeyActionLabel ?? "Change API key" : D?.apiKeyActionLabel ?? "API key" : $e === n.LogOut ? D?.logoutActionLabel ?? "Log out" : D?.loginActionLabel ?? "Log in", Et = $e === n.ManageCredentials || Xe === y.ApiKey ? /* @__PURE__ */ G(tt, {
|
|
1383
|
+
size: z.MD,
|
|
1384
|
+
stroke: B
|
|
1385
|
+
}) : $e === n.LogOut ? /* @__PURE__ */ G(at, {
|
|
1386
|
+
size: z.MD,
|
|
1387
|
+
stroke: B
|
|
1388
|
+
}) : /* @__PURE__ */ G(it, {
|
|
1389
|
+
size: z.MD,
|
|
1390
|
+
stroke: B
|
|
1391
|
+
}), Dt = $e === n.ManageCredentials ? /* @__PURE__ */ G(We, {
|
|
1392
|
+
size: z.MD,
|
|
1352
1393
|
className: "rtl:scale-x-[-1]",
|
|
1353
|
-
stroke:
|
|
1354
|
-
}) : X ? /* @__PURE__ */ G(
|
|
1355
|
-
size:
|
|
1356
|
-
stroke:
|
|
1394
|
+
stroke: B
|
|
1395
|
+
}) : X ? /* @__PURE__ */ G(qe, {
|
|
1396
|
+
size: z.MD,
|
|
1397
|
+
stroke: B
|
|
1357
1398
|
}) : void 0, Ot = (t) => {
|
|
1358
1399
|
let n = /* @__PURE__ */ G(t, {
|
|
1359
1400
|
label: Tt,
|
|
@@ -1363,180 +1404,183 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1363
1404
|
"aria-haspopup": X ? "dialog" : void 0,
|
|
1364
1405
|
"aria-expanded": X ? Y : void 0
|
|
1365
1406
|
});
|
|
1366
|
-
return !X || e.credentials == null ? n : /* @__PURE__ */ G(
|
|
1407
|
+
return !X || e.credentials == null ? n : /* @__PURE__ */ G(_e, {
|
|
1367
1408
|
placement: "bottom-start",
|
|
1368
1409
|
matchReferenceWidth: !1,
|
|
1369
1410
|
open: Y,
|
|
1370
1411
|
onOpenChange: Ct,
|
|
1371
1412
|
trigger: [],
|
|
1372
1413
|
outsideClosable: !0,
|
|
1373
|
-
renderOverlay: () => /* @__PURE__ */ G(
|
|
1414
|
+
renderOverlay: () => /* @__PURE__ */ G(Mn, {
|
|
1374
1415
|
item: e,
|
|
1375
1416
|
level: b.User,
|
|
1376
1417
|
status: e.credentials?.userStatus,
|
|
1377
1418
|
apiKeyAddedWhen: e.credentials?.userApiKeyAddedWhen,
|
|
1419
|
+
apiKeyHeader: e.credentials?.apiKeyHeader,
|
|
1378
1420
|
onLogin: S,
|
|
1379
1421
|
onLogout: C,
|
|
1380
1422
|
onClose: () => Ct(!1),
|
|
1381
|
-
texts: D
|
|
1423
|
+
texts: D,
|
|
1424
|
+
colors: O?.colors
|
|
1382
1425
|
}),
|
|
1383
1426
|
children: n
|
|
1384
1427
|
});
|
|
1385
|
-
}, kt = ({ key: t, label: n, Icon: r, danger: s, onClick: c }) => t === "share" ? /* @__PURE__ */ G(
|
|
1428
|
+
}, kt = ({ key: t, label: n, Icon: r, danger: s, onClick: c }) => t === "share" ? /* @__PURE__ */ G(Fn, {
|
|
1386
1429
|
item: e,
|
|
1387
1430
|
onShare: i,
|
|
1388
1431
|
shareOverlay: a,
|
|
1389
1432
|
isShareVisible: o,
|
|
1390
1433
|
label: D?.shareLabel
|
|
1391
|
-
}) : /* @__PURE__ */ G(s ?
|
|
1434
|
+
}) : /* @__PURE__ */ G(s ? ge : H, {
|
|
1392
1435
|
label: n,
|
|
1393
1436
|
iconBefore: /* @__PURE__ */ G(r, {
|
|
1394
|
-
size:
|
|
1437
|
+
size: z.MD,
|
|
1395
1438
|
"aria-hidden": !0,
|
|
1396
|
-
stroke:
|
|
1439
|
+
stroke: B
|
|
1397
1440
|
}),
|
|
1398
1441
|
onClick: c
|
|
1399
1442
|
}), At = () => {
|
|
1400
|
-
let t = /* @__PURE__ */ G(
|
|
1443
|
+
let t = /* @__PURE__ */ G(_e, {
|
|
1401
1444
|
items: yt,
|
|
1402
1445
|
placement: "bottom-end",
|
|
1403
1446
|
matchReferenceWidth: !1,
|
|
1404
|
-
onOpenChange:
|
|
1405
|
-
children: /* @__PURE__ */ G(
|
|
1406
|
-
icon: /* @__PURE__ */ G(
|
|
1407
|
-
size:
|
|
1447
|
+
onOpenChange: Ie,
|
|
1448
|
+
children: /* @__PURE__ */ G(U, {
|
|
1449
|
+
icon: /* @__PURE__ */ G(Ze, {
|
|
1450
|
+
size: z.LG,
|
|
1408
1451
|
"aria-hidden": !0,
|
|
1409
|
-
stroke:
|
|
1452
|
+
stroke: B
|
|
1410
1453
|
}),
|
|
1411
1454
|
"aria-label": D?.manageActionLabel ?? "Manage",
|
|
1412
1455
|
"aria-haspopup": "menu",
|
|
1413
|
-
onMouseEnter:
|
|
1414
|
-
onFocus:
|
|
1456
|
+
onMouseEnter: Le,
|
|
1457
|
+
onFocus: Le
|
|
1415
1458
|
})
|
|
1416
1459
|
});
|
|
1417
|
-
return
|
|
1460
|
+
return Je || !a || !Ke ? t : /* @__PURE__ */ G(_e, {
|
|
1418
1461
|
placement: "bottom-end",
|
|
1419
1462
|
matchReferenceWidth: !1,
|
|
1420
|
-
open:
|
|
1421
|
-
onOpenChange:
|
|
1463
|
+
open: be,
|
|
1464
|
+
onOpenChange: Se,
|
|
1422
1465
|
trigger: [],
|
|
1423
1466
|
outsideClosable: !0,
|
|
1424
|
-
renderOverlay: () => a(e,
|
|
1467
|
+
renderOverlay: () => a(e, Ce),
|
|
1425
1468
|
children: t
|
|
1426
1469
|
});
|
|
1427
|
-
}, jt =
|
|
1470
|
+
}, jt = nt || Be || ct || Je && Ke || Ye && Ve || Ye && Ue || et && !nt || yt.length > 0 || He;
|
|
1428
1471
|
return /* @__PURE__ */ K("div", {
|
|
1429
1472
|
className: "flex flex-col gap-3 px-6 py-4",
|
|
1430
1473
|
children: [/* @__PURE__ */ G(E, {
|
|
1431
1474
|
item: e,
|
|
1432
1475
|
iconSize: 52,
|
|
1433
|
-
nameClassName: M(
|
|
1476
|
+
nameClassName: M(ae, Nn.name),
|
|
1434
1477
|
featuredLabel: D?.featuredLabel ?? "Featured",
|
|
1435
1478
|
featuredChipStyle: O?.colors?.featuredChipStyle,
|
|
1436
|
-
statusBadge:
|
|
1437
|
-
footer: e.folder.length > 0 ? /* @__PURE__ */ G(
|
|
1479
|
+
statusBadge: le,
|
|
1480
|
+
footer: e.folder.length > 0 ? /* @__PURE__ */ G(xe, {
|
|
1438
1481
|
segments: e.folder,
|
|
1439
|
-
labelClassName:
|
|
1440
|
-
leafClassName:
|
|
1482
|
+
labelClassName: oe,
|
|
1483
|
+
leafClassName: se
|
|
1441
1484
|
}) : void 0
|
|
1442
1485
|
}), jt && /* @__PURE__ */ K("div", {
|
|
1443
1486
|
className: "flex flex-wrap items-center gap-2 ps-[60px]",
|
|
1444
1487
|
children: [
|
|
1445
|
-
|
|
1446
|
-
|
|
1488
|
+
nt && Ot(wt || Z ? H : Ae),
|
|
1489
|
+
Be && /* @__PURE__ */ G(Ae, {
|
|
1447
1490
|
label: D?.primaryActionLabel ?? "Use in chat",
|
|
1448
|
-
iconBefore: /* @__PURE__ */ G(
|
|
1449
|
-
onClick:
|
|
1450
|
-
disabled:
|
|
1491
|
+
iconBefore: /* @__PURE__ */ G(st, { size: z.MD }),
|
|
1492
|
+
onClick: ue,
|
|
1493
|
+
disabled: ce === St.LimitReached
|
|
1451
1494
|
}),
|
|
1452
|
-
|
|
1495
|
+
ct && /* @__PURE__ */ K(gt, { children: [/* @__PURE__ */ G(Ae, {
|
|
1453
1496
|
label: D?.downloadActionLabel ?? "Download",
|
|
1454
|
-
iconBefore:
|
|
1455
|
-
size:
|
|
1497
|
+
iconBefore: he ? /* @__PURE__ */ G(Re, {
|
|
1498
|
+
size: z.MD,
|
|
1456
1499
|
"aria-hidden": !0
|
|
1457
|
-
}) : /* @__PURE__ */ G(
|
|
1458
|
-
size:
|
|
1500
|
+
}) : /* @__PURE__ */ G(Qe, {
|
|
1501
|
+
size: z.MD,
|
|
1459
1502
|
"aria-hidden": !0,
|
|
1460
|
-
stroke:
|
|
1503
|
+
stroke: B
|
|
1461
1504
|
}),
|
|
1462
|
-
onClick:
|
|
1463
|
-
disabled:
|
|
1464
|
-
"aria-busy":
|
|
1465
|
-
}),
|
|
1505
|
+
onClick: ye,
|
|
1506
|
+
disabled: he,
|
|
1507
|
+
"aria-busy": he
|
|
1508
|
+
}), he && /* @__PURE__ */ G("span", {
|
|
1466
1509
|
role: "status",
|
|
1467
1510
|
"aria-live": "polite",
|
|
1468
1511
|
className: "sr-only",
|
|
1469
1512
|
children: D?.downloadingStatusLabel ?? "Downloading"
|
|
1470
1513
|
})] }),
|
|
1471
|
-
|
|
1514
|
+
Je && Ke && /* @__PURE__ */ G(Fn, {
|
|
1472
1515
|
item: e,
|
|
1473
1516
|
onShare: i,
|
|
1474
1517
|
shareOverlay: a,
|
|
1475
1518
|
isShareVisible: o,
|
|
1476
1519
|
label: D?.shareLabel
|
|
1477
1520
|
}),
|
|
1478
|
-
|
|
1521
|
+
Ye && Ve && /* @__PURE__ */ G(H, {
|
|
1479
1522
|
label: D?.unpublishLabel ?? "Unpublish",
|
|
1480
1523
|
iconBefore: /* @__PURE__ */ G(mt, {
|
|
1481
|
-
size:
|
|
1524
|
+
size: z.MD,
|
|
1482
1525
|
"aria-hidden": !0,
|
|
1483
|
-
stroke:
|
|
1526
|
+
stroke: B
|
|
1484
1527
|
}),
|
|
1485
|
-
onClick:
|
|
1486
|
-
onMouseEnter:
|
|
1487
|
-
onFocus:
|
|
1528
|
+
onClick: pe,
|
|
1529
|
+
onMouseEnter: ze,
|
|
1530
|
+
onFocus: ze
|
|
1488
1531
|
}),
|
|
1489
|
-
|
|
1532
|
+
Ye && Ue && /* @__PURE__ */ G(H, {
|
|
1490
1533
|
label: D?.publishLabel ?? "Publish",
|
|
1491
1534
|
iconBefore: /* @__PURE__ */ G(ht, {
|
|
1492
|
-
size:
|
|
1535
|
+
size: z.MD,
|
|
1493
1536
|
"aria-hidden": !0,
|
|
1494
|
-
stroke:
|
|
1537
|
+
stroke: B
|
|
1495
1538
|
}),
|
|
1496
|
-
onClick:
|
|
1497
|
-
onMouseEnter:
|
|
1498
|
-
onFocus:
|
|
1539
|
+
onClick: fe,
|
|
1540
|
+
onMouseEnter: ze,
|
|
1541
|
+
onFocus: ze
|
|
1499
1542
|
}),
|
|
1500
|
-
|
|
1501
|
-
J ? kt(J) : (yt.length > 0 ||
|
|
1543
|
+
et && !nt && Ot(H),
|
|
1544
|
+
J ? kt(J) : (yt.length > 0 || He) && At()
|
|
1502
1545
|
]
|
|
1503
1546
|
})]
|
|
1504
1547
|
});
|
|
1505
|
-
},
|
|
1506
|
-
let
|
|
1548
|
+
}, Bn = ({ topics: e, content: t, detailsStyles: n, markdownLabels: r }) => {
|
|
1549
|
+
let i = n?.typography?.contentHeadingClassName ?? "dial-small-semi-text", a = n?.typography?.contentClassName ?? "dial-small-text";
|
|
1507
1550
|
return /* @__PURE__ */ K("div", {
|
|
1508
1551
|
className: "flex flex-col gap-5",
|
|
1509
1552
|
children: [/* @__PURE__ */ G(A, {
|
|
1510
1553
|
content: t,
|
|
1511
1554
|
classNames: {
|
|
1512
|
-
h1:
|
|
1513
|
-
h2:
|
|
1514
|
-
h3:
|
|
1515
|
-
h4:
|
|
1516
|
-
h5:
|
|
1517
|
-
h6:
|
|
1518
|
-
p:
|
|
1519
|
-
ul:
|
|
1520
|
-
ol:
|
|
1521
|
-
}
|
|
1555
|
+
h1: i,
|
|
1556
|
+
h2: i,
|
|
1557
|
+
h3: i,
|
|
1558
|
+
h4: i,
|
|
1559
|
+
h5: i,
|
|
1560
|
+
h6: i,
|
|
1561
|
+
p: a,
|
|
1562
|
+
ul: a,
|
|
1563
|
+
ol: a
|
|
1564
|
+
},
|
|
1565
|
+
...r
|
|
1522
1566
|
}), e && e.length > 0 && /* @__PURE__ */ G("div", {
|
|
1523
1567
|
className: "flex flex-wrap gap-2",
|
|
1524
|
-
children: e.map((e) => /* @__PURE__ */ G(
|
|
1568
|
+
children: e.map((e) => /* @__PURE__ */ G(Kt, { label: e }, e))
|
|
1525
1569
|
})]
|
|
1526
1570
|
});
|
|
1527
|
-
},
|
|
1571
|
+
}, Vn = {
|
|
1528
1572
|
divider: "_divider_1gzl9_1",
|
|
1529
1573
|
fileCount: "_fileCount_1gzl9_5",
|
|
1530
1574
|
body: "_body_1gzl9_9"
|
|
1531
|
-
},
|
|
1575
|
+
}, Hn = (e, t, n = void 0) => e.flatMap((e) => {
|
|
1532
1576
|
let r = {
|
|
1533
1577
|
node: e,
|
|
1534
1578
|
parentId: n
|
|
1535
1579
|
};
|
|
1536
|
-
return e.type === Z.File || !t.has(e.id) ? [r] : [r, ...
|
|
1537
|
-
}),
|
|
1538
|
-
let c =
|
|
1539
|
-
|
|
1580
|
+
return e.type === Z.File || !t.has(e.id) ? [r] : [r, ...Hn(e.items, t, e.id)];
|
|
1581
|
+
}), Un = ({ nodes: e, selectedFileId: t, expandedFolderIds: n, onToggleFolder: r, onSelectFile: i, onClose: a, ariaLabel: o = "Select file", rowNameClassName: s = "dial-small-text" }) => {
|
|
1582
|
+
let c = I(() => Hn(e, n), [e, n]), l = L({}), [u, d] = R(() => t ?? c[0]?.node.id);
|
|
1583
|
+
F(() => {
|
|
1540
1584
|
u != null && l.current[u]?.focus();
|
|
1541
1585
|
}, []);
|
|
1542
1586
|
let f = (e) => {
|
|
@@ -1605,21 +1649,21 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1605
1649
|
onClick: () => r(e.id),
|
|
1606
1650
|
onFocus: () => d(e.id),
|
|
1607
1651
|
children: [
|
|
1608
|
-
/* @__PURE__ */ G(
|
|
1609
|
-
size:
|
|
1652
|
+
/* @__PURE__ */ G(et, {
|
|
1653
|
+
size: z.SM,
|
|
1610
1654
|
className: "shrink-0",
|
|
1611
1655
|
"aria-hidden": !0,
|
|
1612
|
-
stroke:
|
|
1656
|
+
stroke: B
|
|
1613
1657
|
}),
|
|
1614
1658
|
/* @__PURE__ */ G("span", {
|
|
1615
1659
|
className: M("min-w-0 flex-1 truncate", s),
|
|
1616
1660
|
children: e.name
|
|
1617
1661
|
}),
|
|
1618
|
-
/* @__PURE__ */ G(
|
|
1619
|
-
size:
|
|
1662
|
+
/* @__PURE__ */ G(qe, {
|
|
1663
|
+
size: z.SM,
|
|
1620
1664
|
className: M("shrink-0 transition-transform", !o && "-rotate-90 rtl:rotate-90"),
|
|
1621
1665
|
"aria-hidden": !0,
|
|
1622
|
-
stroke:
|
|
1666
|
+
stroke: B
|
|
1623
1667
|
})
|
|
1624
1668
|
]
|
|
1625
1669
|
}), o && e.items.length > 0 && /* @__PURE__ */ G("div", {
|
|
@@ -1634,9 +1678,9 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1634
1678
|
onKeyDown: p,
|
|
1635
1679
|
children: e.map((e) => h(e))
|
|
1636
1680
|
});
|
|
1637
|
-
},
|
|
1638
|
-
let
|
|
1639
|
-
nodes:
|
|
1681
|
+
}, Wn = () => void 0, Gn = ({ content: e, description: t, files: n, selectedFileId: r, onSelectFile: i, isFileLoading: a = !1, expandedFolderIds: o = /* @__PURE__ */ new Set(), onToggleFolder: s = Wn, isFileSelectorOpen: c = !1, onFileSelectorOpenChange: l = Wn, fileSelectorAriaLabel: u = "Select file", fileCountLabel: d = (e) => `${e} files`, fileLoadingLabel: f = "Loading file", fileUnsupportedLabel: p = "Preview is not supported for this file", filePreview: m, filePreviewContent: h, renderFileTree: g, detailsStyles: _, markdownLabels: v }) => {
|
|
1682
|
+
let y = _?.typography?.contentClassName ?? "dial-small-text", b = _?.typography?.contentHeadingClassName ?? "dial-small-semi-text", x = _?.typography?.contentFileCountClassName ?? "dial-tiny-text", S = oe(), C = t != null && t !== "", w = n ?? [], T = en(w) > 1, E = nn(w, r) ?? "", D = {
|
|
1683
|
+
nodes: w,
|
|
1640
1684
|
selectedFileId: r,
|
|
1641
1685
|
expandedFolderIds: o,
|
|
1642
1686
|
onToggleFolder: s,
|
|
@@ -1645,8 +1689,8 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1645
1689
|
},
|
|
1646
1690
|
onClose: () => l(!1),
|
|
1647
1691
|
ariaLabel: u,
|
|
1648
|
-
rowNameClassName:
|
|
1649
|
-
},
|
|
1692
|
+
rowNameClassName: y
|
|
1693
|
+
}, O = a ? {
|
|
1650
1694
|
type: Q.Text,
|
|
1651
1695
|
text: ""
|
|
1652
1696
|
} : m ?? {
|
|
@@ -1656,55 +1700,58 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1656
1700
|
return /* @__PURE__ */ K("div", {
|
|
1657
1701
|
className: "flex h-full flex-col gap-4 pb-6",
|
|
1658
1702
|
children: [
|
|
1659
|
-
|
|
1703
|
+
T && /* @__PURE__ */ K("div", {
|
|
1660
1704
|
className: "flex shrink-0 items-center gap-3",
|
|
1661
|
-
children: [/* @__PURE__ */ G(
|
|
1705
|
+
children: [/* @__PURE__ */ G(_e, {
|
|
1662
1706
|
open: c,
|
|
1663
1707
|
onOpenChange: l,
|
|
1664
1708
|
trigger: [],
|
|
1665
1709
|
matchReferenceWidth: !1,
|
|
1666
1710
|
listClassName: "w-[280px] shadow-md",
|
|
1667
1711
|
placement: "bottom-start",
|
|
1668
|
-
renderOverlay: () => g ? g(
|
|
1669
|
-
children: /* @__PURE__ */ G(
|
|
1670
|
-
id:
|
|
1671
|
-
label:
|
|
1672
|
-
size:
|
|
1712
|
+
renderOverlay: () => g ? g(D) : /* @__PURE__ */ G(Un, { ...D }),
|
|
1713
|
+
children: /* @__PURE__ */ G(Te, {
|
|
1714
|
+
id: S,
|
|
1715
|
+
label: E,
|
|
1716
|
+
size: ye.Small,
|
|
1673
1717
|
isOpen: c,
|
|
1674
1718
|
onClick: () => l(!c)
|
|
1675
1719
|
})
|
|
1676
1720
|
}), /* @__PURE__ */ G("span", {
|
|
1677
|
-
className: M("shrink-0",
|
|
1678
|
-
children: d(
|
|
1721
|
+
className: M("shrink-0", x, Vn.fileCount),
|
|
1722
|
+
children: d(en(w))
|
|
1679
1723
|
})]
|
|
1680
1724
|
}),
|
|
1681
|
-
|
|
1682
|
-
className: M("m-0",
|
|
1725
|
+
C && /* @__PURE__ */ K(gt, { children: [/* @__PURE__ */ G("p", {
|
|
1726
|
+
className: M("m-0", y),
|
|
1683
1727
|
children: t
|
|
1684
|
-
}), /* @__PURE__ */ G("div", { className: M("shrink-0",
|
|
1728
|
+
}), /* @__PURE__ */ G("div", { className: M("shrink-0", Vn.divider) })] }),
|
|
1685
1729
|
/* @__PURE__ */ K("div", {
|
|
1686
|
-
role:
|
|
1687
|
-
"aria-labelledby":
|
|
1688
|
-
className: M("min-h-0 flex-1 text-start", h == null ? "overflow-auto break-words" : "overflow-hidden", h == null &&
|
|
1730
|
+
role: T ? "region" : void 0,
|
|
1731
|
+
"aria-labelledby": T ? S : void 0,
|
|
1732
|
+
className: M("min-h-0 flex-1 text-start", h == null ? "overflow-auto break-words" : "overflow-hidden", h == null && Vn.body, h == null && y),
|
|
1689
1733
|
children: [a && /* @__PURE__ */ G("span", {
|
|
1690
1734
|
role: "status",
|
|
1691
1735
|
className: "sr-only",
|
|
1692
1736
|
children: f
|
|
1693
1737
|
}), (() => {
|
|
1694
1738
|
if (h != null) return h;
|
|
1695
|
-
switch (
|
|
1739
|
+
switch (O.type) {
|
|
1696
1740
|
case Q.Markdown: return /* @__PURE__ */ G(te, {
|
|
1697
|
-
content:
|
|
1698
|
-
headingClassName:
|
|
1741
|
+
content: O.text,
|
|
1742
|
+
headingClassName: b,
|
|
1743
|
+
...v
|
|
1699
1744
|
});
|
|
1700
1745
|
case Q.Text: return /* @__PURE__ */ G(k, {
|
|
1701
|
-
language:
|
|
1702
|
-
value:
|
|
1746
|
+
language: O.language ?? "",
|
|
1747
|
+
value: O.text,
|
|
1748
|
+
copyLabel: v?.codeBlockCopyLabel,
|
|
1749
|
+
copiedLabel: v?.codeBlockCopiedLabel,
|
|
1703
1750
|
hideDownload: !0
|
|
1704
1751
|
});
|
|
1705
1752
|
case Q.Image: return /* @__PURE__ */ G("img", {
|
|
1706
|
-
src:
|
|
1707
|
-
alt:
|
|
1753
|
+
src: O.url,
|
|
1754
|
+
alt: E,
|
|
1708
1755
|
className: "max-w-full"
|
|
1709
1756
|
});
|
|
1710
1757
|
case Q.Unsupported: return /* @__PURE__ */ G("p", {
|
|
@@ -1716,28 +1763,28 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1716
1763
|
})
|
|
1717
1764
|
]
|
|
1718
1765
|
});
|
|
1719
|
-
},
|
|
1766
|
+
}, Kn = new Intl.NumberFormat(void 0, { maximumFractionDigits: 2 }), qn = /* @__PURE__ */ function(e) {
|
|
1720
1767
|
return e.Default = "default", e.Warning = "warning", e.Danger = "danger", e;
|
|
1721
|
-
}({}),
|
|
1722
|
-
let t =
|
|
1768
|
+
}({}), Jn = (e) => !Number.isFinite(e.used) || !Number.isFinite(e.total) ? 0 : Math.min(Math.max(e.used, 0), Math.max(e.total, 0)), Yn = (e) => Number.isFinite(e) && e > 0 ? e : 1, Xn = ({ used: e, total: t, valueLabel: n }) => n ?? `${Kn.format(e)} / ${Kn.format(t)}`, Zn = ({ total: e }) => Number.isFinite(e) && e > 0, Qn = (e) => e.isUnlimited !== !0 && Zn(e), $n = (e) => Zn(e) ? Math.max(e.used, 0) / e.total : 0, er = (e) => {
|
|
1769
|
+
let t = $n(e);
|
|
1723
1770
|
return t >= 1 ? "danger" : t >= .75 ? "warning" : "default";
|
|
1724
1771
|
}, $ = {
|
|
1725
|
-
sectionHeading: "
|
|
1726
|
-
label: "
|
|
1727
|
-
valuePrimary: "
|
|
1728
|
-
divider: "
|
|
1729
|
-
progressTrack: "
|
|
1730
|
-
progressFillDefault: "
|
|
1731
|
-
progressFillWarning: "
|
|
1732
|
-
progressFillDanger: "
|
|
1733
|
-
resetLabel: "
|
|
1734
|
-
valueDanger: "
|
|
1735
|
-
},
|
|
1736
|
-
let s =
|
|
1737
|
-
value:
|
|
1738
|
-
max:
|
|
1739
|
-
size:
|
|
1740
|
-
className: M("!h-1 w-full", $.progressTrack, c ===
|
|
1772
|
+
sectionHeading: "_sectionHeading_1v3yh_2",
|
|
1773
|
+
label: "_label_1v3yh_6",
|
|
1774
|
+
valuePrimary: "_valuePrimary_1v3yh_10",
|
|
1775
|
+
divider: "_divider_1v3yh_14",
|
|
1776
|
+
progressTrack: "_progressTrack_1v3yh_20",
|
|
1777
|
+
progressFillDefault: "_progressFillDefault_1v3yh_25",
|
|
1778
|
+
progressFillWarning: "_progressFillWarning_1v3yh_29",
|
|
1779
|
+
progressFillDanger: "_progressFillDanger_1v3yh_33",
|
|
1780
|
+
resetLabel: "_resetLabel_1v3yh_38",
|
|
1781
|
+
valueDanger: "_valueDanger_1v3yh_43"
|
|
1782
|
+
}, tr = ({ row: e, layout: t, labelClassName: n, captionClassName: r, valueClassName: i, noteValueClassName: a, noteClassName: o }) => {
|
|
1783
|
+
let s = Xn(e), c = er(e), l = /* @__PURE__ */ G(je, {
|
|
1784
|
+
value: Jn(e),
|
|
1785
|
+
max: Yn(e.total),
|
|
1786
|
+
size: ye.Small,
|
|
1787
|
+
className: M("!h-1 w-full", $.progressTrack, c === qn.Default && $.progressFillDefault, c === qn.Warning && $.progressFillWarning, c === qn.Danger && $.progressFillDanger),
|
|
1741
1788
|
"aria-label": e.label,
|
|
1742
1789
|
"aria-valuetext": e.ariaLabel ?? s
|
|
1743
1790
|
}), u = e.captionLabel != null && /* @__PURE__ */ G("span", {
|
|
@@ -1761,12 +1808,12 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1761
1808
|
className: M("min-w-0 break-words", n, $.valuePrimary),
|
|
1762
1809
|
children: e.label
|
|
1763
1810
|
}), /* @__PURE__ */ G("span", {
|
|
1764
|
-
className: M("shrink-0", i, c ===
|
|
1811
|
+
className: M("shrink-0", i, c === qn.Danger ? $.valueDanger : $.valuePrimary),
|
|
1765
1812
|
children: s
|
|
1766
1813
|
})]
|
|
1767
1814
|
}),
|
|
1768
1815
|
u,
|
|
1769
|
-
|
|
1816
|
+
Qn(e) ? l : e.noteLabel != null && /* @__PURE__ */ G("span", {
|
|
1770
1817
|
className: M(o, $.label),
|
|
1771
1818
|
children: e.noteLabel
|
|
1772
1819
|
}),
|
|
@@ -1784,7 +1831,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1784
1831
|
u,
|
|
1785
1832
|
d
|
|
1786
1833
|
]
|
|
1787
|
-
}),
|
|
1834
|
+
}), Qn(e) ? /* @__PURE__ */ K("div", {
|
|
1788
1835
|
className: "flex w-32 shrink-0 flex-col items-end gap-2",
|
|
1789
1836
|
children: [/* @__PURE__ */ G("div", {
|
|
1790
1837
|
className: M("flex gap-1", i),
|
|
@@ -1810,12 +1857,12 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1810
1857
|
})]
|
|
1811
1858
|
})]
|
|
1812
1859
|
});
|
|
1813
|
-
},
|
|
1860
|
+
}, nr = ({ group: e, sectionClassName: t, layout: n, labelClassName: r, captionClassName: i, valueClassName: a, noteValueClassName: o, noteClassName: s }) => /* @__PURE__ */ K("section", { children: [/* @__PURE__ */ G("p", {
|
|
1814
1861
|
className: M("mb-3 mt-0", t, $.sectionHeading),
|
|
1815
1862
|
children: e.label
|
|
1816
1863
|
}), /* @__PURE__ */ G("ul", {
|
|
1817
1864
|
className: "m-0 flex list-none flex-col p-0",
|
|
1818
|
-
children: e.rows.map((e) => /* @__PURE__ */ G(
|
|
1865
|
+
children: e.rows.map((e) => /* @__PURE__ */ G(tr, {
|
|
1819
1866
|
row: e,
|
|
1820
1867
|
layout: n,
|
|
1821
1868
|
labelClassName: r,
|
|
@@ -1824,7 +1871,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1824
1871
|
noteValueClassName: o,
|
|
1825
1872
|
noteClassName: s
|
|
1826
1873
|
}, e.label))
|
|
1827
|
-
})] }),
|
|
1874
|
+
})] }), rr = ({ limits: e, layout: t = wt.Inline, labelClassName: n = "dial-small-semi-text", captionClassName: r = "dial-caption-text", valueClassName: i = "dial-tiny-text", noteValueClassName: a = "dial-tiny-semi-text", noteClassName: o = "dial-caption-text", sectionClassName: s = "dial-caption-text", footerClassName: c = "dial-caption-text", footerNote: l, colors: u }) => {
|
|
1828
1875
|
let d = e?.groups.filter((e) => e.rows.length > 0);
|
|
1829
1876
|
return d == null || d.length === 0 ? null : /* @__PURE__ */ K("div", {
|
|
1830
1877
|
className: "flex flex-col gap-6",
|
|
@@ -1839,7 +1886,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1839
1886
|
"--lt-progress-fill-warning": u?.progressFillWarning,
|
|
1840
1887
|
"--lt-progress-fill-danger": u?.progressFillDanger
|
|
1841
1888
|
}),
|
|
1842
|
-
children: [d.map((e) => /* @__PURE__ */ G(
|
|
1889
|
+
children: [d.map((e) => /* @__PURE__ */ G(nr, {
|
|
1843
1890
|
group: e,
|
|
1844
1891
|
layout: t,
|
|
1845
1892
|
sectionClassName: s,
|
|
@@ -1853,13 +1900,13 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1853
1900
|
children: l
|
|
1854
1901
|
})]
|
|
1855
1902
|
});
|
|
1856
|
-
},
|
|
1903
|
+
}, ir = ({ sections: e, sectionClassName: t, labelClassName: n, valueClassName: r, valueTrueClassName: i, yesLabel: a, noLabel: o }) => e ? /* @__PURE__ */ G("div", {
|
|
1857
1904
|
className: "flex flex-col gap-4",
|
|
1858
1905
|
children: e.map((e, s) => /* @__PURE__ */ K("div", {
|
|
1859
1906
|
className: "flex flex-col gap-4",
|
|
1860
|
-
children: [s > 0 && /* @__PURE__ */ G("div", { className: M("shrink-0 border-b",
|
|
1907
|
+
children: [s > 0 && /* @__PURE__ */ G("div", { className: M("shrink-0 border-b", On.divider) }), /* @__PURE__ */ G("div", {
|
|
1861
1908
|
className: "px-6",
|
|
1862
|
-
children: /* @__PURE__ */ G(
|
|
1909
|
+
children: /* @__PURE__ */ G(on, {
|
|
1863
1910
|
sectionLabel: e.title,
|
|
1864
1911
|
values: e.specs,
|
|
1865
1912
|
sectionClassName: t,
|
|
@@ -1871,7 +1918,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1871
1918
|
})
|
|
1872
1919
|
})]
|
|
1873
1920
|
}, s))
|
|
1874
|
-
}) : null,
|
|
1921
|
+
}) : null, ar = ({ pricing: e, pricesSectionLabel: t = "Token pricing", limitsSectionLabel: n = "Usage limits", labelClassName: r = "dial-small-semi-text", valueClassName: i = "dial-small-text", sectionClassName: a = "dial-caption-text" }) => {
|
|
1875
1922
|
if (e == null) return null;
|
|
1876
1923
|
let o = e.prices?.map((e) => ({
|
|
1877
1924
|
label: e.label,
|
|
@@ -1882,13 +1929,13 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1882
1929
|
}));
|
|
1883
1930
|
return /* @__PURE__ */ K("div", {
|
|
1884
1931
|
className: "flex flex-col gap-4",
|
|
1885
|
-
children: [/* @__PURE__ */ G(
|
|
1932
|
+
children: [/* @__PURE__ */ G(on, {
|
|
1886
1933
|
sectionLabel: t,
|
|
1887
1934
|
values: o ?? [],
|
|
1888
1935
|
labelClassName: r,
|
|
1889
1936
|
valueClassName: i,
|
|
1890
1937
|
sectionClassName: a
|
|
1891
|
-
}), /* @__PURE__ */ G(
|
|
1938
|
+
}), /* @__PURE__ */ G(on, {
|
|
1892
1939
|
sectionLabel: n,
|
|
1893
1940
|
values: s ?? [],
|
|
1894
1941
|
labelClassName: r,
|
|
@@ -1896,32 +1943,32 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1896
1943
|
sectionClassName: a
|
|
1897
1944
|
})]
|
|
1898
1945
|
});
|
|
1899
|
-
},
|
|
1946
|
+
}, or = {
|
|
1900
1947
|
container: "_container_ddi3i_1",
|
|
1901
1948
|
header: "_header_ddi3i_5",
|
|
1902
1949
|
cell: "_cell_ddi3i_10",
|
|
1903
1950
|
evenRow: "_evenRow_ddi3i_17"
|
|
1904
|
-
},
|
|
1951
|
+
}, sr = ({ columns: e, rows: t, columnsTemplate: n, headingClassName: r = "dial-caption-lead-semi-text", cellClassName: i = "dial-tiny-text" }) => {
|
|
1905
1952
|
let a = n ?? `repeat(${e.length}, 1fr)`;
|
|
1906
1953
|
return /* @__PURE__ */ K("div", {
|
|
1907
|
-
className: M(
|
|
1954
|
+
className: M(or.container, "grid overflow-hidden rounded-md"),
|
|
1908
1955
|
style: { gridTemplateColumns: a },
|
|
1909
1956
|
children: [e.map((e) => /* @__PURE__ */ G("div", {
|
|
1910
|
-
className: M("px-2 py-1 text-start", r,
|
|
1957
|
+
className: M("px-2 py-1 text-start", r, or.header),
|
|
1911
1958
|
children: e
|
|
1912
1959
|
}, e)), t.map((e, t) => /* @__PURE__ */ G(ie, { children: e.map((e, n) => /* @__PURE__ */ G("div", {
|
|
1913
|
-
className: M("px-2 py-1.5", i,
|
|
1960
|
+
className: M("px-2 py-1.5", i, or.cell, t % 2 == 1 ? or.evenRow : void 0),
|
|
1914
1961
|
children: e
|
|
1915
1962
|
}, n)) }, t))]
|
|
1916
1963
|
});
|
|
1917
|
-
},
|
|
1964
|
+
}, cr = {
|
|
1918
1965
|
divider: "_divider_1f796_1",
|
|
1919
1966
|
description: "_description_1f796_5",
|
|
1920
1967
|
code: "_code_1f796_9"
|
|
1921
|
-
},
|
|
1968
|
+
}, lr = ({ tools: e, toolNameClassName: t = "dial-small-semi-text", descriptionClassName: n = "dial-small-text", tableHeadingClassName: r = "dial-caption-text", tableCellClassName: i = "dial-tiny-text" }) => e == null ? null : /* @__PURE__ */ G("div", {
|
|
1922
1969
|
className: "flex flex-col",
|
|
1923
1970
|
children: e.tools.map((e, a) => /* @__PURE__ */ K("div", {
|
|
1924
|
-
className: M("flex flex-col gap-3 px-[22px] py-4", a > 0 ?
|
|
1971
|
+
className: M("flex flex-col gap-3 px-[22px] py-4", a > 0 ? cr.divider : void 0),
|
|
1925
1972
|
children: [
|
|
1926
1973
|
/* @__PURE__ */ K("div", {
|
|
1927
1974
|
className: "flex flex-col gap-1",
|
|
@@ -1929,11 +1976,11 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1929
1976
|
className: t,
|
|
1930
1977
|
children: e.name
|
|
1931
1978
|
}), e.description != null && /* @__PURE__ */ G("p", {
|
|
1932
|
-
className: M("m-0", n,
|
|
1979
|
+
className: M("m-0", n, cr.description),
|
|
1933
1980
|
children: e.description
|
|
1934
1981
|
})]
|
|
1935
1982
|
}),
|
|
1936
|
-
e.inputParams != null && e.inputParams.length > 0 && /* @__PURE__ */ G(
|
|
1983
|
+
e.inputParams != null && e.inputParams.length > 0 && /* @__PURE__ */ G(sr, {
|
|
1937
1984
|
columns: [
|
|
1938
1985
|
"Name",
|
|
1939
1986
|
"Type",
|
|
@@ -1942,11 +1989,11 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1942
1989
|
columnsTemplate: "1fr 1fr auto",
|
|
1943
1990
|
rows: e.inputParams.map((e) => [
|
|
1944
1991
|
/* @__PURE__ */ G("code", {
|
|
1945
|
-
className: M("text-inherit border-none bg-transparent p-0",
|
|
1992
|
+
className: M("text-inherit border-none bg-transparent p-0", cr.code),
|
|
1946
1993
|
children: e.name
|
|
1947
1994
|
}, "name"),
|
|
1948
1995
|
/* @__PURE__ */ G("code", {
|
|
1949
|
-
className: M("text-inherit border-none bg-transparent p-0",
|
|
1996
|
+
className: M("text-inherit border-none bg-transparent p-0", cr.code),
|
|
1950
1997
|
children: e.type
|
|
1951
1998
|
}, "type"),
|
|
1952
1999
|
e.isRequired ? "✓" : "—"
|
|
@@ -1954,10 +2001,10 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1954
2001
|
headingClassName: r,
|
|
1955
2002
|
cellClassName: i
|
|
1956
2003
|
}),
|
|
1957
|
-
e.annotations != null && e.annotations.length > 0 && /* @__PURE__ */ G(
|
|
2004
|
+
e.annotations != null && e.annotations.length > 0 && /* @__PURE__ */ G(sr, {
|
|
1958
2005
|
columns: ["Key", "Value"],
|
|
1959
2006
|
rows: e.annotations.map((e) => [/* @__PURE__ */ G("code", {
|
|
1960
|
-
className: M("text-inherit border-none bg-transparent p-0",
|
|
2007
|
+
className: M("text-inherit border-none bg-transparent p-0", cr.code),
|
|
1961
2008
|
children: e.key
|
|
1962
2009
|
}, "key"), e.value]),
|
|
1963
2010
|
headingClassName: r,
|
|
@@ -1965,149 +2012,149 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
1965
2012
|
})
|
|
1966
2013
|
]
|
|
1967
2014
|
}, e.name))
|
|
1968
|
-
}),
|
|
2015
|
+
}), ur = new Set([x.Prompt, x.Skill]), dr = (e) => e?.resource?.endpointUrl != null || (e?.endpoints?.length ?? 0) > 0, fr = (e, t) => t == null ? e.length === 1 ? e[0] : void 0 : e.find((e) => e.key === t), pr = async () => void 0, mr = [], hr = [], gr = [
|
|
1969
2016
|
"All shared configurations will be lost",
|
|
1970
2017
|
"Users who rely on it will lose access",
|
|
1971
2018
|
"Cannot be undone"
|
|
1972
|
-
],
|
|
2019
|
+
], _r = [
|
|
1973
2020
|
"You will lose access to this item",
|
|
1974
2021
|
"Other people keep their access",
|
|
1975
2022
|
"You will need a new invitation to get it back"
|
|
1976
|
-
],
|
|
2023
|
+
], vr = [
|
|
1977
2024
|
"Everyone loses access to the published copy",
|
|
1978
2025
|
"Your own copy is not deleted",
|
|
1979
2026
|
"You can publish it again later"
|
|
1980
|
-
],
|
|
2027
|
+
], yr = [
|
|
1981
2028
|
"Everyone you shared it with loses access",
|
|
1982
2029
|
"Existing share links stop working",
|
|
1983
2030
|
"You keep full access — nothing is deleted"
|
|
1984
|
-
],
|
|
1985
|
-
let { subViewTitleClassName:
|
|
1986
|
-
"--cat-details-backdrop":
|
|
1987
|
-
"--cat-details-bg":
|
|
1988
|
-
"--cat-details-border":
|
|
1989
|
-
"--cat-details-divider":
|
|
1990
|
-
"--cat-details-scrollbar":
|
|
1991
|
-
"--cat-details-skeleton":
|
|
1992
|
-
"--cat-details-name-text":
|
|
1993
|
-
"--cat-details-publish-title-text":
|
|
1994
|
-
"--cat-details-content-text":
|
|
1995
|
-
"--cat-details-variable-text":
|
|
1996
|
-
"--cat-details-file-count-text":
|
|
1997
|
-
"--cat-api-heading-text":
|
|
1998
|
-
"--cat-tools-divider":
|
|
1999
|
-
"--cat-tools-description-text":
|
|
2000
|
-
"--cat-grid-border":
|
|
2001
|
-
"--cat-grid-header-text":
|
|
2002
|
-
"--cat-grid-header-bg":
|
|
2003
|
-
"--cat-grid-cell-text":
|
|
2004
|
-
"--cat-grid-cell-divider":
|
|
2005
|
-
"--cat-grid-row-even-bg":
|
|
2006
|
-
"--cat-cred-surface-bg":
|
|
2007
|
-
"--cat-cred-active-icon":
|
|
2008
|
-
"--cat-cred-banner-icon-bg":
|
|
2009
|
-
"--cat-cred-description-text":
|
|
2010
|
-
"--cat-cred-row-description-text":
|
|
2011
|
-
"--cat-cred-error-text":
|
|
2012
|
-
"--cat-cred-card-bg":
|
|
2013
|
-
"--cat-cred-card-icon":
|
|
2014
|
-
"--cat-cred-card-title-text":
|
|
2015
|
-
"--cat-cred-card-description-text":
|
|
2016
|
-
}), [
|
|
2017
|
-
let t =
|
|
2018
|
-
t != null && t !== n && t.startsWith("blob:") && URL.revokeObjectURL(t),
|
|
2031
|
+
], br = (e) => e === y.ApiKey ? "Toolset API keys" : "Toolset credentials", xr = (e) => e === b.Global ? "Are you sure you want to delete the organization API key?" : "Are you sure you want to delete your personal API key?", Sr = new Set([Y.Delete, Y.Unshare]), Cr = ({ item: e, isOpen: n, isStarred: r = !1, isDetailsLoading: i = !1, isReadonly: a = !1, onClose: o, onToggleFavorite: s, isFavoriteVisible: c, onUseInChat: l, isPrimaryActionVisible: u, onShare: d, isPublishVisible: f, isPublishPrimary: p, getPublishHistory: h, publishFolderItems: _ = mr, publishExpandedPaths: v, onPublishExpandedPathsChange: y, publishLoadingPaths: w, hasPublishWriteAccess: T, publishDefaultAuthor: E, onPublish: D, onPublishSuccess: O, onPublishError: ee, onCreatePublishFolder: k, publishLabels: A, ruleSourceOptions: te = hr, onFetchExistingRules: ne, shareOverlay: re, isShareVisible: ie, isSharePrimary: N, onEdit: ae, onDownload: oe, isDownloadVisible: se, isDownloadPrimary: ce, onLoadContentFile: le, onLoadContentFilePreview: ue, renderContentFilePreview: de, renderContentFileTree: fe, renderCredentials: pe, onDelete: me, onUnshare: z, isUnshareVisible: B, onRevokeShare: ge, onFetchRecipientsCount: _e, isRevokeShareVisible: ve, onUnpublish: ye, isUnpublishVisible: be, onLogin: xe, onLogout: Se, texts: V, styles: Ce, limitsFooterNote: we }) => {
|
|
2032
|
+
let { subViewTitleClassName: Te = "dial-body-semi-text", overviewSectionClassName: Ee = "dial-caption-text", overviewLabelClassName: De = "dial-small-semi-text", overviewValueClassName: Oe = "dial-small-text", overviewValueTrueClassName: ke = "dial-small-text", confirmMessageClassName: H = "dial-small-text" } = Ce?.typography ?? {}, U = Ce?.colors, Ae = j({
|
|
2033
|
+
"--cat-details-backdrop": U?.backdrop,
|
|
2034
|
+
"--cat-details-bg": U?.background,
|
|
2035
|
+
"--cat-details-border": U?.border,
|
|
2036
|
+
"--cat-details-divider": U?.divider,
|
|
2037
|
+
"--cat-details-scrollbar": U?.scrollbar,
|
|
2038
|
+
"--cat-details-skeleton": U?.skeleton,
|
|
2039
|
+
"--cat-details-name-text": U?.nameText,
|
|
2040
|
+
"--cat-details-publish-title-text": U?.publishTitleText,
|
|
2041
|
+
"--cat-details-content-text": U?.contentText,
|
|
2042
|
+
"--cat-details-variable-text": U?.variableText,
|
|
2043
|
+
"--cat-details-file-count-text": U?.contentFileCountText,
|
|
2044
|
+
"--cat-api-heading-text": U?.apiHeadingText,
|
|
2045
|
+
"--cat-tools-divider": U?.toolsDivider,
|
|
2046
|
+
"--cat-tools-description-text": U?.toolsDescriptionText,
|
|
2047
|
+
"--cat-grid-border": U?.gridBorder,
|
|
2048
|
+
"--cat-grid-header-text": U?.gridHeaderText,
|
|
2049
|
+
"--cat-grid-header-bg": U?.gridHeaderBackground,
|
|
2050
|
+
"--cat-grid-cell-text": U?.gridCellText,
|
|
2051
|
+
"--cat-grid-cell-divider": U?.gridCellDivider,
|
|
2052
|
+
"--cat-grid-row-even-bg": U?.gridRowEvenBackground,
|
|
2053
|
+
"--cat-cred-surface-bg": U?.credentialsSurfaceBackground,
|
|
2054
|
+
"--cat-cred-active-icon": U?.credentialsActiveIcon,
|
|
2055
|
+
"--cat-cred-banner-icon-bg": U?.credentialsBannerIconBackground,
|
|
2056
|
+
"--cat-cred-description-text": U?.credentialsDescriptionText,
|
|
2057
|
+
"--cat-cred-row-description-text": U?.credentialsRowDescriptionText,
|
|
2058
|
+
"--cat-cred-error-text": U?.credentialsErrorText,
|
|
2059
|
+
"--cat-cred-card-bg": U?.credentialsCardBackground,
|
|
2060
|
+
"--cat-cred-card-icon": U?.credentialsCardIcon,
|
|
2061
|
+
"--cat-cred-card-title-text": U?.credentialsCardTitleText,
|
|
2062
|
+
"--cat-cred-card-description-text": U?.credentialsCardDescriptionText
|
|
2063
|
+
}), [je, Ne] = R(r), [Pe, Le] = R(""), [Re, Be] = R(!1), [Ve, He] = R([]), [Ue, We] = R(!1), Ge = L(null), Ke = e.details?.promptContent, qe = Ke?.selectedFileId, [Je, Ye] = R(null), [Xe, Ze] = R(!1), [Qe, $e] = R(/* @__PURE__ */ new Set()), [et, tt] = R(!1), nt = L(null), rt = L(0), it = P((e) => {
|
|
2064
|
+
let t = nt.current, n = e?.preview?.type === Q.Image ? e.preview.url : null;
|
|
2065
|
+
t != null && t !== n && t.startsWith("blob:") && URL.revokeObjectURL(t), nt.current = n, Ye(e);
|
|
2019
2066
|
}, []);
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
}, [e.id,
|
|
2023
|
-
let e =
|
|
2067
|
+
F(() => {
|
|
2068
|
+
rt.current += 1, it(null), Ze(!1), $e(tn(Ke?.files ?? [])), tt(!1);
|
|
2069
|
+
}, [e.id, qe]), F(() => () => {
|
|
2070
|
+
let e = nt.current;
|
|
2024
2071
|
e != null && e.startsWith("blob:") && URL.revokeObjectURL(e);
|
|
2025
2072
|
}, []);
|
|
2026
|
-
let
|
|
2027
|
-
|
|
2073
|
+
let at = P((e) => {
|
|
2074
|
+
$e((t) => {
|
|
2028
2075
|
let n = new Set(t);
|
|
2029
2076
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
2030
2077
|
});
|
|
2031
|
-
}, []),
|
|
2032
|
-
if (e ===
|
|
2033
|
-
|
|
2078
|
+
}, []), ot = P(async (e) => {
|
|
2079
|
+
if (e === qe) {
|
|
2080
|
+
rt.current += 1, it(null), Ze(!1);
|
|
2034
2081
|
return;
|
|
2035
2082
|
}
|
|
2036
|
-
if (
|
|
2037
|
-
if (
|
|
2038
|
-
|
|
2083
|
+
if (de == null && le == null && ue == null) return;
|
|
2084
|
+
if (de != null) {
|
|
2085
|
+
rt.current += 1, it({
|
|
2039
2086
|
id: e,
|
|
2040
2087
|
preview: null
|
|
2041
|
-
}),
|
|
2088
|
+
}), Ze(!1);
|
|
2042
2089
|
return;
|
|
2043
2090
|
}
|
|
2044
|
-
let t = ++
|
|
2045
|
-
|
|
2091
|
+
let t = ++rt.current;
|
|
2092
|
+
it({
|
|
2046
2093
|
id: e,
|
|
2047
2094
|
preview: null
|
|
2048
|
-
}),
|
|
2095
|
+
}), Ze(!0);
|
|
2049
2096
|
try {
|
|
2050
|
-
let n =
|
|
2097
|
+
let n = ue == null ? await le?.(e).then((e) => e == null ? void 0 : {
|
|
2051
2098
|
type: Q.Markdown,
|
|
2052
2099
|
text: e
|
|
2053
|
-
}) : await
|
|
2054
|
-
if (
|
|
2100
|
+
}) : await ue(e);
|
|
2101
|
+
if (rt.current !== t) {
|
|
2055
2102
|
n?.type === Q.Image && n.url.startsWith("blob:") && URL.revokeObjectURL(n.url);
|
|
2056
2103
|
return;
|
|
2057
2104
|
}
|
|
2058
|
-
|
|
2105
|
+
it({
|
|
2059
2106
|
id: e,
|
|
2060
2107
|
preview: n ?? null
|
|
2061
2108
|
});
|
|
2062
2109
|
} catch {
|
|
2063
|
-
if (
|
|
2064
|
-
|
|
2110
|
+
if (rt.current !== t) return;
|
|
2111
|
+
it({
|
|
2065
2112
|
id: e,
|
|
2066
2113
|
preview: null
|
|
2067
2114
|
});
|
|
2068
2115
|
} finally {
|
|
2069
|
-
|
|
2116
|
+
rt.current === t && Ze(!1);
|
|
2070
2117
|
}
|
|
2071
2118
|
}, [
|
|
2072
|
-
|
|
2119
|
+
qe,
|
|
2120
|
+
le,
|
|
2073
2121
|
ue,
|
|
2074
2122
|
de,
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
]), ct = Xe?.id ?? Ye, lt = () => Xe == null ? null : Xe.preview == null ? {
|
|
2123
|
+
it
|
|
2124
|
+
]), st = Je?.id ?? qe, ct = () => Je == null ? null : Je.preview == null ? {
|
|
2078
2125
|
type: Q.Text,
|
|
2079
|
-
text:
|
|
2080
|
-
} :
|
|
2081
|
-
if (!h ||
|
|
2126
|
+
text: V?.contentFileErrorLabel ?? "Failed to load this file."
|
|
2127
|
+
} : Je.preview, lt = Je != null && de != null ? de(Je.id, nn(Ke?.files ?? [], Je.id) ?? "") : void 0, ut = P(() => {
|
|
2128
|
+
if (!h || Ge.current === e.id) return;
|
|
2082
2129
|
let t = e.id;
|
|
2083
|
-
|
|
2130
|
+
Ge.current = t, (async () => {
|
|
2084
2131
|
try {
|
|
2085
2132
|
let n = await h(e);
|
|
2086
|
-
if (
|
|
2087
|
-
|
|
2133
|
+
if (Ge.current !== t) return;
|
|
2134
|
+
He(n), We(!0);
|
|
2088
2135
|
} catch {
|
|
2089
|
-
if (
|
|
2090
|
-
|
|
2136
|
+
if (Ge.current !== t) return;
|
|
2137
|
+
Ge.current = null;
|
|
2091
2138
|
}
|
|
2092
2139
|
})();
|
|
2093
2140
|
}, [h, e]);
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
}, [
|
|
2097
|
-
let dt =
|
|
2098
|
-
|
|
2099
|
-
}, [
|
|
2141
|
+
F(() => {
|
|
2142
|
+
Re && ut();
|
|
2143
|
+
}, [Re, ut]);
|
|
2144
|
+
let dt = P((e, t) => {
|
|
2145
|
+
Ge.current = null, We(!1), ut(), O?.(e, t);
|
|
2146
|
+
}, [ut, O]), W = bt({
|
|
2100
2147
|
item: e,
|
|
2101
|
-
history:
|
|
2148
|
+
history: Ve,
|
|
2102
2149
|
folderItems: _,
|
|
2103
2150
|
hasWriteAccess: T,
|
|
2104
2151
|
defaultAuthor: E,
|
|
2105
2152
|
onCreateFolder: k,
|
|
2106
|
-
onPublish: D ??
|
|
2153
|
+
onPublish: D ?? pr,
|
|
2107
2154
|
onPublishSuccess: dt,
|
|
2108
2155
|
onPublishError: ee,
|
|
2109
2156
|
onFetchExistingRules: ne
|
|
2110
|
-
}), ft = e.type === x.Toolset && g(e.credentials), pt =
|
|
2157
|
+
}), ft = e.type === x.Toolset && g(e.credentials), pt = I(() => yt({
|
|
2111
2158
|
hasSelectedFolder: W.selectedFolderPath != null,
|
|
2112
2159
|
hasExistingPublicationInFolder: W.hasExistingPublicationInFolder,
|
|
2113
2160
|
hasWriteAccess: W.hasWriteAccess,
|
|
@@ -2119,27 +2166,27 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2119
2166
|
W.hasWriteAccess,
|
|
2120
2167
|
W.isSubmitting,
|
|
2121
2168
|
W.hasSubmitError
|
|
2122
|
-
]), [mt, ht] =
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
}, [e.id, r]),
|
|
2126
|
-
|
|
2169
|
+
]), [mt, ht] = R(!1), [xt, q] = R(null), [St, Ct] = R(!1), [X, wt] = R(null), [Z, Tt] = R(null), [Et, Ot] = R(null);
|
|
2170
|
+
F(() => {
|
|
2171
|
+
Ne(r);
|
|
2172
|
+
}, [e.id, r]), F(() => {
|
|
2173
|
+
Le(""), Be(!1), W.reset(), He([]), We(!1), Ge.current = null, Ot(null), ht(!1), q(null), Ct(!1), wt(null), Tt(null);
|
|
2127
2174
|
}, [e.id]);
|
|
2128
|
-
let
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
}, [
|
|
2132
|
-
let
|
|
2175
|
+
let kt = !a && !!ye && be?.(e) === !0;
|
|
2176
|
+
F(() => {
|
|
2177
|
+
kt && ut();
|
|
2178
|
+
}, [kt, ut]);
|
|
2179
|
+
let At = P(() => ht(!0), []), jt = P(() => ht(!1), []), Mt = P(() => {
|
|
2133
2180
|
q(Y.Delete);
|
|
2134
|
-
}, []),
|
|
2181
|
+
}, []), Nt = P((n) => {
|
|
2135
2182
|
Tt(n ?? (e.credentials == null ? null : t(e.credentials))), q(Y.Logout);
|
|
2136
|
-
}, [e.credentials]),
|
|
2183
|
+
}, [e.credentials]), Pt = P(() => {
|
|
2137
2184
|
q(Y.Unshare);
|
|
2138
|
-
}, []),
|
|
2185
|
+
}, []), Ft = P(() => {
|
|
2139
2186
|
q(Y.RevokeAccess);
|
|
2140
|
-
}, []),
|
|
2187
|
+
}, []), It = I(() => {
|
|
2141
2188
|
let e = /* @__PURE__ */ new Set(), t = [];
|
|
2142
|
-
for (let n of
|
|
2189
|
+
for (let n of Ve) {
|
|
2143
2190
|
let r = n.folderPath.join("/");
|
|
2144
2191
|
e.has(r) || (e.add(r), t.push({
|
|
2145
2192
|
key: r,
|
|
@@ -2147,41 +2194,41 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2147
2194
|
}));
|
|
2148
2195
|
}
|
|
2149
2196
|
return t;
|
|
2150
|
-
}, [
|
|
2197
|
+
}, [Ve]), Lt = Ue && It.length > 0, Rt = P((e) => e || (A?.rootFolderLabel ?? "Organization"), [A]), zt = P(() => {
|
|
2151
2198
|
q(Y.Unpublish);
|
|
2152
|
-
}, []),
|
|
2199
|
+
}, []), Bt = P((e) => {
|
|
2153
2200
|
wt(e), q(Y.DeleteApiKey);
|
|
2154
|
-
}, []),
|
|
2155
|
-
St || (q(null), wt(null), Tt(null),
|
|
2156
|
-
}, [St]),
|
|
2201
|
+
}, []), Vt = P(() => {
|
|
2202
|
+
St || (q(null), wt(null), Tt(null), Ot(null));
|
|
2203
|
+
}, [St]), Ht = P(async () => {
|
|
2157
2204
|
if (!(St || xt == null)) {
|
|
2158
2205
|
Ct(!0);
|
|
2159
2206
|
try {
|
|
2160
2207
|
switch (xt) {
|
|
2161
2208
|
case Y.Delete:
|
|
2162
|
-
await
|
|
2209
|
+
await me?.(e);
|
|
2163
2210
|
break;
|
|
2164
2211
|
case Y.Unshare:
|
|
2165
|
-
await
|
|
2212
|
+
await z?.(e);
|
|
2166
2213
|
break;
|
|
2167
2214
|
case Y.RevokeAccess:
|
|
2168
|
-
await
|
|
2215
|
+
await ge?.(e);
|
|
2169
2216
|
break;
|
|
2170
2217
|
case Y.Logout:
|
|
2171
|
-
Z != null && await
|
|
2218
|
+
Z != null && await Se?.(e, { level: Z });
|
|
2172
2219
|
break;
|
|
2173
2220
|
case Y.DeleteApiKey:
|
|
2174
|
-
X != null && await
|
|
2221
|
+
X != null && await Se?.(e, { level: X });
|
|
2175
2222
|
break;
|
|
2176
2223
|
case Y.Unpublish: {
|
|
2177
|
-
let t =
|
|
2178
|
-
t != null && await
|
|
2224
|
+
let t = fr(It, Et);
|
|
2225
|
+
t != null && await ye?.(e, t.segments);
|
|
2179
2226
|
break;
|
|
2180
2227
|
}
|
|
2181
2228
|
}
|
|
2182
|
-
q(null), wt(null), Tt(null),
|
|
2229
|
+
q(null), wt(null), Tt(null), Ot(null), Sr.has(xt) && o();
|
|
2183
2230
|
} catch {
|
|
2184
|
-
q(null), wt(null), Tt(null),
|
|
2231
|
+
q(null), wt(null), Tt(null), Ot(null);
|
|
2185
2232
|
} finally {
|
|
2186
2233
|
Ct(!1);
|
|
2187
2234
|
}
|
|
@@ -2192,159 +2239,159 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2192
2239
|
X,
|
|
2193
2240
|
Z,
|
|
2194
2241
|
e,
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2242
|
+
me,
|
|
2243
|
+
z,
|
|
2244
|
+
ge,
|
|
2245
|
+
ye,
|
|
2199
2246
|
Et,
|
|
2200
|
-
|
|
2201
|
-
|
|
2247
|
+
It,
|
|
2248
|
+
Se,
|
|
2202
2249
|
o
|
|
2203
2250
|
]);
|
|
2204
|
-
|
|
2251
|
+
F(() => {
|
|
2205
2252
|
if (!n || xt == null) return;
|
|
2206
2253
|
let e = (e) => {
|
|
2207
|
-
e.key === "Escape" && (e.stopPropagation(),
|
|
2254
|
+
e.key === "Escape" && (e.stopPropagation(), Vt());
|
|
2208
2255
|
};
|
|
2209
2256
|
return document.addEventListener("keydown", e, !0), () => document.removeEventListener("keydown", e, !0);
|
|
2210
2257
|
}, [
|
|
2211
2258
|
n,
|
|
2212
2259
|
xt,
|
|
2213
|
-
|
|
2260
|
+
Vt
|
|
2214
2261
|
]);
|
|
2215
|
-
let
|
|
2216
|
-
|
|
2217
|
-
}, [W]),
|
|
2218
|
-
await W.handleSubmit() &&
|
|
2219
|
-
}, [W,
|
|
2220
|
-
let t = !
|
|
2221
|
-
|
|
2262
|
+
let Wt = P(() => Be(!0), []), Gt = P(() => {
|
|
2263
|
+
Be(!1), W.reset();
|
|
2264
|
+
}, [W]), Kt = P(async () => {
|
|
2265
|
+
await W.handleSubmit() && Gt();
|
|
2266
|
+
}, [W, Gt]), qt = P(() => {
|
|
2267
|
+
let t = !je;
|
|
2268
|
+
Ne(t), s?.(e.id, t);
|
|
2222
2269
|
}, [
|
|
2223
|
-
|
|
2270
|
+
je,
|
|
2224
2271
|
e.id,
|
|
2225
2272
|
s
|
|
2226
|
-
]),
|
|
2227
|
-
let t = [], n =
|
|
2273
|
+
]), Jt = I(() => {
|
|
2274
|
+
let t = [], n = ur.has(e.type);
|
|
2228
2275
|
return n || t.push({
|
|
2229
2276
|
id: J.About,
|
|
2230
|
-
label:
|
|
2277
|
+
label: V?.tabAboutLabel ?? "About"
|
|
2231
2278
|
}), (n || e.details?.promptContent != null) && t.push({
|
|
2232
2279
|
id: J.Content,
|
|
2233
|
-
label:
|
|
2280
|
+
label: V?.tabContentLabel ?? "Details"
|
|
2234
2281
|
}), e.details?.overview != null && t.push({
|
|
2235
2282
|
id: J.Overview,
|
|
2236
|
-
label:
|
|
2283
|
+
label: V?.tabOverviewLabel ?? "Overview"
|
|
2237
2284
|
}), e.details?.pricing != null && t.push({
|
|
2238
2285
|
id: J.Pricing,
|
|
2239
|
-
label:
|
|
2286
|
+
label: V?.tabPricingLabel ?? "Pricing"
|
|
2240
2287
|
}), e.details?.limits != null && t.push({
|
|
2241
2288
|
id: J.Limits,
|
|
2242
|
-
label:
|
|
2289
|
+
label: V?.tabLimitsLabel ?? "Limits"
|
|
2243
2290
|
}), e.details?.tools != null && t.push({
|
|
2244
2291
|
id: J.Tools,
|
|
2245
|
-
label:
|
|
2246
|
-
}),
|
|
2292
|
+
label: V?.tabToolsLabel ?? "Tools"
|
|
2293
|
+
}), dr(e.details?.api) && t.push({
|
|
2247
2294
|
id: J.Api,
|
|
2248
|
-
label:
|
|
2295
|
+
label: V?.tabConnectLabel ?? "Connect"
|
|
2249
2296
|
}), t;
|
|
2250
|
-
}, [e,
|
|
2251
|
-
|
|
2252
|
-
let t =
|
|
2253
|
-
|
|
2297
|
+
}, [e, V]), Yt = L(null);
|
|
2298
|
+
F(() => {
|
|
2299
|
+
let t = Yt.current !== e.id;
|
|
2300
|
+
Yt.current = e.id, (t || !Jt.some((e) => e.id === Pe)) && Le(Jt[0]?.id ?? "");
|
|
2254
2301
|
}, [
|
|
2255
2302
|
e.id,
|
|
2256
|
-
|
|
2257
|
-
|
|
2303
|
+
Jt,
|
|
2304
|
+
Pe
|
|
2258
2305
|
]);
|
|
2259
|
-
let
|
|
2306
|
+
let Xt = I(() => Dt(V), [V]), Zt = V?.overviewYesLabel ?? "Yes", Qt = V?.overviewNoLabel ?? "No", $t = V?.ariaLabel ?? "Item details", en = V?.closeAriaLabel ?? "Close", rn = je ? V?.removeFromFavoritesAriaLabel ?? "Remove from favorites" : V?.addToFavoritesAriaLabel ?? "Add to favorites", an = V?.publishTitle ?? "Publish", on = V?.backToDetailsAriaLabel ?? "Back", sn = V?.cancelLabel ?? "Cancel", cn = I(() => {
|
|
2260
2307
|
switch (xt) {
|
|
2261
2308
|
case Y.Delete: {
|
|
2262
|
-
let t =
|
|
2309
|
+
let t = V?.deleteActionLabel ?? "Delete";
|
|
2263
2310
|
return {
|
|
2264
|
-
title:
|
|
2265
|
-
message:
|
|
2311
|
+
title: V?.deleteConfirmTitle ?? t,
|
|
2312
|
+
message: V?.deleteConfirmMessage?.(e.name) ?? /* @__PURE__ */ K(gt, { children: [
|
|
2266
2313
|
"Are you sure you want to delete ",
|
|
2267
2314
|
/* @__PURE__ */ G("strong", { children: e.name }),
|
|
2268
2315
|
"? This action is permanent and cannot be undone."
|
|
2269
2316
|
] }),
|
|
2270
|
-
consequences:
|
|
2317
|
+
consequences: V?.deleteConfirmConsequences ?? gr,
|
|
2271
2318
|
confirmLabel: t,
|
|
2272
|
-
loadingStatusLabel:
|
|
2273
|
-
variant:
|
|
2319
|
+
loadingStatusLabel: V?.deletingStatusLabel ?? "Deleting",
|
|
2320
|
+
variant: he.Danger
|
|
2274
2321
|
};
|
|
2275
2322
|
}
|
|
2276
2323
|
case Y.Unshare: {
|
|
2277
|
-
let t =
|
|
2324
|
+
let t = V?.unshareLabel ?? "Remove from My List";
|
|
2278
2325
|
return {
|
|
2279
|
-
title:
|
|
2280
|
-
message:
|
|
2326
|
+
title: V?.unshareConfirmTitle ?? t,
|
|
2327
|
+
message: V?.unshareConfirmMessage?.(e.name) ?? /* @__PURE__ */ K(gt, { children: [
|
|
2281
2328
|
"Remove ",
|
|
2282
2329
|
/* @__PURE__ */ G("strong", { children: e.name }),
|
|
2283
2330
|
" from your list? You'll need a new invitation to access it again."
|
|
2284
2331
|
] }),
|
|
2285
|
-
consequences:
|
|
2332
|
+
consequences: V?.unshareConfirmConsequences ?? _r,
|
|
2286
2333
|
confirmLabel: t,
|
|
2287
|
-
loadingStatusLabel:
|
|
2288
|
-
variant:
|
|
2334
|
+
loadingStatusLabel: V?.unsharingStatusLabel ?? "Removing",
|
|
2335
|
+
variant: he.Info
|
|
2289
2336
|
};
|
|
2290
2337
|
}
|
|
2291
2338
|
case Y.RevokeAccess: {
|
|
2292
|
-
let t =
|
|
2339
|
+
let t = V?.revokeShareLabel ?? "Revoke access";
|
|
2293
2340
|
return {
|
|
2294
|
-
title:
|
|
2295
|
-
message:
|
|
2341
|
+
title: V?.revokeShareConfirmTitle ?? t,
|
|
2342
|
+
message: V?.revokeShareConfirmMessage?.(e.name) ?? /* @__PURE__ */ K(gt, { children: [
|
|
2296
2343
|
"Revoke shared access to ",
|
|
2297
2344
|
/* @__PURE__ */ G("strong", { children: e.name }),
|
|
2298
2345
|
"? Anyone you shared it with will lose access."
|
|
2299
2346
|
] }),
|
|
2300
|
-
consequences:
|
|
2347
|
+
consequences: V?.revokeShareConfirmConsequences ?? yr,
|
|
2301
2348
|
confirmLabel: t,
|
|
2302
|
-
loadingStatusLabel:
|
|
2303
|
-
variant:
|
|
2349
|
+
loadingStatusLabel: V?.revokingShareStatusLabel ?? "Revoking access",
|
|
2350
|
+
variant: he.Danger
|
|
2304
2351
|
};
|
|
2305
2352
|
}
|
|
2306
2353
|
case Y.Unpublish: {
|
|
2307
|
-
let t =
|
|
2354
|
+
let t = V?.unpublishLabel ?? "Unpublish", n = It.length === 1, r = n ? Rt(It[0].key) : "", i = V?.unpublishConfirmMessage?.(e.name, r) ?? /* @__PURE__ */ K(gt, { children: [
|
|
2308
2355
|
"Unpublish ",
|
|
2309
2356
|
/* @__PURE__ */ G("strong", { children: e.name }),
|
|
2310
2357
|
" from \"",
|
|
2311
2358
|
r,
|
|
2312
2359
|
"\"? The request is submitted for admin approval."
|
|
2313
|
-
] }), a =
|
|
2360
|
+
] }), a = V?.unpublishSelectFolderMessage?.(e.name) ?? /* @__PURE__ */ K(gt, { children: [
|
|
2314
2361
|
"Choose which folder to unpublish ",
|
|
2315
2362
|
/* @__PURE__ */ G("strong", { children: e.name }),
|
|
2316
2363
|
" from. The request is submitted for admin approval."
|
|
2317
2364
|
] });
|
|
2318
2365
|
return {
|
|
2319
|
-
title:
|
|
2366
|
+
title: V?.unpublishConfirmTitle ?? t,
|
|
2320
2367
|
message: n ? i : a,
|
|
2321
|
-
consequences:
|
|
2368
|
+
consequences: V?.unpublishConfirmConsequences ?? vr,
|
|
2322
2369
|
confirmLabel: t,
|
|
2323
|
-
loadingStatusLabel:
|
|
2324
|
-
variant:
|
|
2370
|
+
loadingStatusLabel: V?.unpublishingStatusLabel ?? "Requesting unpublish",
|
|
2371
|
+
variant: he.Danger
|
|
2325
2372
|
};
|
|
2326
2373
|
}
|
|
2327
2374
|
case Y.Logout: {
|
|
2328
|
-
let e =
|
|
2375
|
+
let e = V?.logoutActionLabel ?? "Log out";
|
|
2329
2376
|
return {
|
|
2330
2377
|
title: e,
|
|
2331
|
-
message:
|
|
2378
|
+
message: V?.logoutConfirmMessage ?? "Are you sure you want to log out?",
|
|
2332
2379
|
consequences: void 0,
|
|
2333
2380
|
confirmLabel: e,
|
|
2334
|
-
loadingStatusLabel:
|
|
2335
|
-
variant:
|
|
2381
|
+
loadingStatusLabel: V?.loggingOutStatusLabel ?? "Logging out",
|
|
2382
|
+
variant: he.Info
|
|
2336
2383
|
};
|
|
2337
2384
|
}
|
|
2338
2385
|
case Y.DeleteApiKey: {
|
|
2339
|
-
let e =
|
|
2386
|
+
let e = V?.deleteActionLabel ?? "Delete", t = X ?? b.User;
|
|
2340
2387
|
return {
|
|
2341
2388
|
title: e,
|
|
2342
|
-
message: (
|
|
2389
|
+
message: (V?.deleteApiKeyConfirmMessage ?? xr)(t),
|
|
2343
2390
|
consequences: void 0,
|
|
2344
2391
|
confirmLabel: e,
|
|
2345
|
-
loadingStatusLabel:
|
|
2346
|
-
variant:
|
|
2347
|
-
cardVariant:
|
|
2392
|
+
loadingStatusLabel: V?.deletingStatusLabel ?? "Deleting",
|
|
2393
|
+
variant: he.Danger,
|
|
2394
|
+
cardVariant: he.Info
|
|
2348
2395
|
};
|
|
2349
2396
|
}
|
|
2350
2397
|
default: return null;
|
|
@@ -2353,81 +2400,81 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2353
2400
|
xt,
|
|
2354
2401
|
e.name,
|
|
2355
2402
|
X,
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
]),
|
|
2360
|
-
title:
|
|
2403
|
+
V,
|
|
2404
|
+
It,
|
|
2405
|
+
Rt
|
|
2406
|
+
]), ln = cn != null, un = xt === Y.Unpublish && fr(It, Et) == null, fn = ln || Re || mt, pn = e.credentials == null ? "" : (V?.credentialsManagementTitle ?? br)(e.credentials.authenticationType), mn = ln ? {
|
|
2407
|
+
title: cn.title,
|
|
2361
2408
|
isBackDisabled: St,
|
|
2362
|
-
onBack:
|
|
2363
|
-
} :
|
|
2364
|
-
title:
|
|
2409
|
+
onBack: Vt
|
|
2410
|
+
} : Re ? {
|
|
2411
|
+
title: an,
|
|
2365
2412
|
isBackDisabled: W.isSubmitting,
|
|
2366
|
-
onBack:
|
|
2413
|
+
onBack: Gt
|
|
2367
2414
|
} : mt ? {
|
|
2368
|
-
title:
|
|
2415
|
+
title: pn,
|
|
2369
2416
|
isBackDisabled: !1,
|
|
2370
|
-
onBack:
|
|
2371
|
-
} : null,
|
|
2372
|
-
return /* @__PURE__ */ K(
|
|
2417
|
+
onBack: jt
|
|
2418
|
+
} : null, hn = mn?.title ?? $t;
|
|
2419
|
+
return /* @__PURE__ */ K(Fe, {
|
|
2373
2420
|
open: n,
|
|
2374
2421
|
onClose: o,
|
|
2375
|
-
header:
|
|
2376
|
-
ariaLabel:
|
|
2377
|
-
onBack:
|
|
2378
|
-
backAriaLabel:
|
|
2379
|
-
backDisabled:
|
|
2380
|
-
hideClose:
|
|
2381
|
-
closeAriaLabel:
|
|
2382
|
-
headerActions:
|
|
2383
|
-
isStarred:
|
|
2384
|
-
ariaLabel:
|
|
2385
|
-
onClick:
|
|
2422
|
+
header: mn?.title,
|
|
2423
|
+
ariaLabel: hn,
|
|
2424
|
+
onBack: mn?.onBack,
|
|
2425
|
+
backAriaLabel: on,
|
|
2426
|
+
backDisabled: mn?.isBackDisabled,
|
|
2427
|
+
hideClose: mn != null,
|
|
2428
|
+
closeAriaLabel: en,
|
|
2429
|
+
headerActions: mn == null && !a && c?.(e) !== !1 ? /* @__PURE__ */ G(Ut, {
|
|
2430
|
+
isStarred: je,
|
|
2431
|
+
ariaLabel: rn,
|
|
2432
|
+
onClick: qt
|
|
2386
2433
|
}) : void 0,
|
|
2387
|
-
style:
|
|
2388
|
-
overlayStyle:
|
|
2389
|
-
className:
|
|
2390
|
-
overlayClassName:
|
|
2391
|
-
headerClassName:
|
|
2392
|
-
titleClassName: M(
|
|
2434
|
+
style: Ae,
|
|
2435
|
+
overlayStyle: Ae,
|
|
2436
|
+
className: On.panel,
|
|
2437
|
+
overlayClassName: On.backdrop,
|
|
2438
|
+
headerClassName: On.divider,
|
|
2439
|
+
titleClassName: M(Te, On.publishTitle),
|
|
2393
2440
|
bodyClassName: "flex flex-col overflow-hidden",
|
|
2394
2441
|
children: [
|
|
2395
2442
|
/* @__PURE__ */ K("div", {
|
|
2396
|
-
className: M("flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto",
|
|
2443
|
+
className: M("flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto", On.content),
|
|
2397
2444
|
children: [
|
|
2398
|
-
|
|
2445
|
+
ln && /* @__PURE__ */ G(C, {
|
|
2399
2446
|
item: e,
|
|
2400
|
-
message:
|
|
2401
|
-
consequences:
|
|
2402
|
-
variant:
|
|
2403
|
-
messageClassName:
|
|
2447
|
+
message: cn.message,
|
|
2448
|
+
consequences: cn.consequences,
|
|
2449
|
+
variant: cn.cardVariant ?? cn.variant,
|
|
2450
|
+
messageClassName: H,
|
|
2404
2451
|
styles: { colors: {
|
|
2405
|
-
messageText:
|
|
2406
|
-
consequenceText:
|
|
2407
|
-
cardBackground:
|
|
2408
|
-
cardDangerBackground:
|
|
2452
|
+
messageText: U?.confirmMessageText,
|
|
2453
|
+
consequenceText: U?.confirmConsequenceText,
|
|
2454
|
+
cardBackground: U?.infoCardBackground,
|
|
2455
|
+
cardDangerBackground: U?.infoCardDangerBackground
|
|
2409
2456
|
} },
|
|
2410
|
-
children: xt === Y.Unpublish &&
|
|
2411
|
-
ariaLabel:
|
|
2457
|
+
children: xt === Y.Unpublish && It.length > 1 && /* @__PURE__ */ G(Me, {
|
|
2458
|
+
ariaLabel: V?.unpublishFolderGroupAriaLabel ?? "Published folders",
|
|
2412
2459
|
value: Et ?? void 0,
|
|
2413
|
-
onChange:
|
|
2460
|
+
onChange: Ot,
|
|
2414
2461
|
disabled: St,
|
|
2415
|
-
items:
|
|
2462
|
+
items: It.map((e) => ({
|
|
2416
2463
|
value: e.key,
|
|
2417
|
-
label:
|
|
2464
|
+
label: Rt(e.key)
|
|
2418
2465
|
})),
|
|
2419
|
-
radioClassName:
|
|
2466
|
+
radioClassName: H
|
|
2420
2467
|
})
|
|
2421
2468
|
}),
|
|
2422
|
-
!
|
|
2469
|
+
!ln && !Re && mt && /* @__PURE__ */ G(Dn, {
|
|
2423
2470
|
item: e,
|
|
2424
|
-
onLogin:
|
|
2425
|
-
onRequestLogout:
|
|
2426
|
-
onRequestDeleteApiKey:
|
|
2427
|
-
texts:
|
|
2428
|
-
detailsStyles:
|
|
2471
|
+
onLogin: xe,
|
|
2472
|
+
onRequestLogout: Nt,
|
|
2473
|
+
onRequestDeleteApiKey: Bt,
|
|
2474
|
+
texts: V,
|
|
2475
|
+
detailsStyles: Ce
|
|
2429
2476
|
}),
|
|
2430
|
-
!
|
|
2477
|
+
!ln && Re && /* @__PURE__ */ G("div", {
|
|
2431
2478
|
className: "p-[22px]",
|
|
2432
2479
|
children: /* @__PURE__ */ G(vt, {
|
|
2433
2480
|
resource: {
|
|
@@ -2458,167 +2505,169 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2458
2505
|
hasRulesLoadError: W.hasRulesLoadError,
|
|
2459
2506
|
labels: A,
|
|
2460
2507
|
styles: { colors: {
|
|
2461
|
-
summaryVersionTagBorder:
|
|
2462
|
-
summaryVersionTagBackground:
|
|
2463
|
-
summaryVersionTagText:
|
|
2508
|
+
summaryVersionTagBorder: U?.versionTagBorder,
|
|
2509
|
+
summaryVersionTagBackground: U?.versionTagBackground,
|
|
2510
|
+
summaryVersionTagText: U?.versionTagText
|
|
2464
2511
|
} }
|
|
2465
2512
|
})
|
|
2466
2513
|
}),
|
|
2467
|
-
!
|
|
2468
|
-
/* @__PURE__ */ G(
|
|
2514
|
+
!fn && /* @__PURE__ */ K(gt, { children: [
|
|
2515
|
+
/* @__PURE__ */ G(zn, {
|
|
2469
2516
|
item: e,
|
|
2470
2517
|
onUseInChat: l,
|
|
2471
2518
|
isPrimaryActionVisible: u,
|
|
2472
2519
|
onShare: d,
|
|
2473
2520
|
shareOverlay: re,
|
|
2474
2521
|
isShareVisible: ie,
|
|
2475
|
-
isSharePrimary:
|
|
2522
|
+
isSharePrimary: N,
|
|
2476
2523
|
isPublishVisible: f,
|
|
2477
2524
|
isPublishPrimary: p,
|
|
2478
|
-
onOpenPublish:
|
|
2479
|
-
isUnpublishVisible:
|
|
2480
|
-
hasPublishedFolders:
|
|
2481
|
-
isPublishHistoryResolved: h == null ||
|
|
2482
|
-
onRequestPublishHistory:
|
|
2483
|
-
onOpenUnpublish:
|
|
2484
|
-
onEdit:
|
|
2485
|
-
onDownload:
|
|
2486
|
-
isDownloadVisible:
|
|
2487
|
-
isDownloadPrimary:
|
|
2488
|
-
onDelete:
|
|
2489
|
-
onUnshare:
|
|
2490
|
-
isUnshareVisible:
|
|
2491
|
-
onRevokeShare:
|
|
2492
|
-
onFetchRecipientsCount:
|
|
2493
|
-
isRevokeShareVisible:
|
|
2494
|
-
onLogin:
|
|
2495
|
-
onLogout:
|
|
2496
|
-
onOpenCredentialsManagement:
|
|
2497
|
-
onRequestLogout:
|
|
2498
|
-
texts:
|
|
2499
|
-
detailsStyles:
|
|
2525
|
+
onOpenPublish: Wt,
|
|
2526
|
+
isUnpublishVisible: be,
|
|
2527
|
+
hasPublishedFolders: Lt,
|
|
2528
|
+
isPublishHistoryResolved: h == null || Ue,
|
|
2529
|
+
onRequestPublishHistory: ut,
|
|
2530
|
+
onOpenUnpublish: ye ? zt : void 0,
|
|
2531
|
+
onEdit: ae,
|
|
2532
|
+
onDownload: oe,
|
|
2533
|
+
isDownloadVisible: se,
|
|
2534
|
+
isDownloadPrimary: ce,
|
|
2535
|
+
onDelete: me ? Mt : void 0,
|
|
2536
|
+
onUnshare: z ? Pt : void 0,
|
|
2537
|
+
isUnshareVisible: B,
|
|
2538
|
+
onRevokeShare: ge ? Ft : void 0,
|
|
2539
|
+
onFetchRecipientsCount: _e,
|
|
2540
|
+
isRevokeShareVisible: ve,
|
|
2541
|
+
onLogin: xe,
|
|
2542
|
+
onLogout: Se,
|
|
2543
|
+
onOpenCredentialsManagement: At,
|
|
2544
|
+
onRequestLogout: Nt,
|
|
2545
|
+
texts: V,
|
|
2546
|
+
detailsStyles: Ce,
|
|
2500
2547
|
isReadonly: a
|
|
2501
2548
|
}),
|
|
2502
2549
|
e.credentials != null && (() => {
|
|
2503
2550
|
let t = m(e.credentials);
|
|
2504
2551
|
return t != null && /* @__PURE__ */ G("div", {
|
|
2505
2552
|
className: "px-6",
|
|
2506
|
-
children: /* @__PURE__ */ G(
|
|
2553
|
+
children: /* @__PURE__ */ G(Cn, {
|
|
2507
2554
|
state: t,
|
|
2508
2555
|
authenticationType: e.credentials.authenticationType,
|
|
2509
|
-
texts:
|
|
2556
|
+
texts: V
|
|
2510
2557
|
})
|
|
2511
2558
|
});
|
|
2512
2559
|
})(),
|
|
2513
|
-
!a && n &&
|
|
2560
|
+
!a && n && pe?.(e),
|
|
2514
2561
|
/* @__PURE__ */ K("div", {
|
|
2515
2562
|
className: "flex items-center px-6",
|
|
2516
|
-
children: [/* @__PURE__ */ G(
|
|
2517
|
-
tabs:
|
|
2518
|
-
activeTabId:
|
|
2519
|
-
onTabChange:
|
|
2563
|
+
children: [/* @__PURE__ */ G(ze, {
|
|
2564
|
+
tabs: Jt,
|
|
2565
|
+
activeTabId: Pe,
|
|
2566
|
+
onTabChange: Le
|
|
2520
2567
|
}), i && /* @__PURE__ */ G("div", {
|
|
2521
2568
|
role: "status",
|
|
2522
|
-
"aria-label":
|
|
2569
|
+
"aria-label": V?.detailsLoadingAriaLabel ?? "Loading details",
|
|
2523
2570
|
className: "shrink-0",
|
|
2524
|
-
children: /* @__PURE__ */ G(
|
|
2571
|
+
children: /* @__PURE__ */ G(Ie, {
|
|
2525
2572
|
showTitle: !1,
|
|
2526
2573
|
paragraph: {
|
|
2527
2574
|
rows: 1,
|
|
2528
2575
|
width: "72px"
|
|
2529
2576
|
},
|
|
2530
2577
|
active: !0,
|
|
2531
|
-
color:
|
|
2578
|
+
color: On.skeletonColor
|
|
2532
2579
|
})
|
|
2533
2580
|
})]
|
|
2534
2581
|
}),
|
|
2535
2582
|
/* @__PURE__ */ K("div", {
|
|
2536
|
-
className: M("min-h-0 flex-1 overflow-y-auto",
|
|
2583
|
+
className: M("min-h-0 flex-1 overflow-y-auto", Pe !== J.Overview && "px-6"),
|
|
2537
2584
|
children: [
|
|
2538
|
-
|
|
2585
|
+
Pe === J.About && /* @__PURE__ */ G(Bn, {
|
|
2539
2586
|
content: e.description,
|
|
2540
2587
|
topics: e.topics,
|
|
2541
|
-
detailsStyles:
|
|
2588
|
+
detailsStyles: Ce,
|
|
2589
|
+
markdownLabels: Xt
|
|
2542
2590
|
}),
|
|
2543
|
-
|
|
2544
|
-
content:
|
|
2545
|
-
filePreview:
|
|
2546
|
-
filePreviewContent:
|
|
2547
|
-
renderFileTree:
|
|
2548
|
-
description:
|
|
2549
|
-
files:
|
|
2550
|
-
selectedFileId:
|
|
2551
|
-
onSelectFile: (e) => void
|
|
2552
|
-
isFileLoading:
|
|
2553
|
-
expandedFolderIds:
|
|
2554
|
-
onToggleFolder:
|
|
2555
|
-
isFileSelectorOpen:
|
|
2556
|
-
onFileSelectorOpenChange:
|
|
2557
|
-
fileSelectorAriaLabel:
|
|
2558
|
-
fileCountLabel:
|
|
2559
|
-
fileLoadingLabel:
|
|
2560
|
-
fileUnsupportedLabel:
|
|
2561
|
-
detailsStyles:
|
|
2591
|
+
Pe === J.Content && /* @__PURE__ */ G(Gn, {
|
|
2592
|
+
content: Ke?.content ?? "",
|
|
2593
|
+
filePreview: ct(),
|
|
2594
|
+
filePreviewContent: lt,
|
|
2595
|
+
renderFileTree: fe,
|
|
2596
|
+
description: Ke?.description ?? e.description,
|
|
2597
|
+
files: Ke?.files,
|
|
2598
|
+
selectedFileId: st,
|
|
2599
|
+
onSelectFile: (e) => void ot(e),
|
|
2600
|
+
isFileLoading: Xe,
|
|
2601
|
+
expandedFolderIds: Qe,
|
|
2602
|
+
onToggleFolder: at,
|
|
2603
|
+
isFileSelectorOpen: et,
|
|
2604
|
+
onFileSelectorOpenChange: tt,
|
|
2605
|
+
fileSelectorAriaLabel: V?.contentFileSelectorAriaLabel,
|
|
2606
|
+
fileCountLabel: V?.contentFileCountLabel,
|
|
2607
|
+
fileLoadingLabel: V?.contentFileLoadingLabel,
|
|
2608
|
+
fileUnsupportedLabel: V?.contentFileUnsupportedLabel,
|
|
2609
|
+
detailsStyles: Ce,
|
|
2610
|
+
markdownLabels: Xt
|
|
2562
2611
|
}),
|
|
2563
|
-
|
|
2612
|
+
Pe === J.Overview && /* @__PURE__ */ G(ir, {
|
|
2564
2613
|
sections: e.details?.overview?.sections,
|
|
2565
|
-
sectionClassName:
|
|
2566
|
-
labelClassName:
|
|
2567
|
-
valueClassName:
|
|
2568
|
-
valueTrueClassName:
|
|
2569
|
-
yesLabel:
|
|
2570
|
-
noLabel:
|
|
2614
|
+
sectionClassName: Ee,
|
|
2615
|
+
labelClassName: De,
|
|
2616
|
+
valueClassName: Oe,
|
|
2617
|
+
valueTrueClassName: ke,
|
|
2618
|
+
yesLabel: Zt,
|
|
2619
|
+
noLabel: Qt
|
|
2571
2620
|
}),
|
|
2572
|
-
|
|
2621
|
+
Pe === J.Pricing && /* @__PURE__ */ G(ar, {
|
|
2573
2622
|
pricing: e.details?.pricing,
|
|
2574
|
-
pricesSectionLabel:
|
|
2575
|
-
limitsSectionLabel:
|
|
2623
|
+
pricesSectionLabel: V?.pricingPricesSectionLabel,
|
|
2624
|
+
limitsSectionLabel: V?.pricingLimitsSectionLabel
|
|
2576
2625
|
}),
|
|
2577
|
-
|
|
2626
|
+
Pe === J.Limits && /* @__PURE__ */ G(rr, {
|
|
2578
2627
|
limits: e.details?.limits,
|
|
2579
|
-
footerNote:
|
|
2628
|
+
footerNote: we
|
|
2580
2629
|
}),
|
|
2581
|
-
|
|
2630
|
+
Pe === J.Api && dr(e.details?.api) && /* @__PURE__ */ G(dn, {
|
|
2582
2631
|
api: e.details?.api,
|
|
2583
|
-
resourceSectionLabel:
|
|
2584
|
-
snippetSectionLabel:
|
|
2585
|
-
modelIdLabel:
|
|
2586
|
-
endpointLabel:
|
|
2587
|
-
endpointSectionLabel:
|
|
2588
|
-
requestExampleLabel:
|
|
2589
|
-
responseSchemaLabel:
|
|
2590
|
-
copyAriaLabel:
|
|
2591
|
-
copiedStatusLabel:
|
|
2632
|
+
resourceSectionLabel: V?.apiResourceSectionLabel,
|
|
2633
|
+
snippetSectionLabel: V?.apiSnippetSectionLabel,
|
|
2634
|
+
modelIdLabel: V?.apiModelIdLabel,
|
|
2635
|
+
endpointLabel: V?.apiEndpointLabel,
|
|
2636
|
+
endpointSectionLabel: V?.apiEndpointSectionLabel,
|
|
2637
|
+
requestExampleLabel: V?.apiRequestExampleLabel,
|
|
2638
|
+
responseSchemaLabel: V?.apiResponseSchemaLabel,
|
|
2639
|
+
copyAriaLabel: V?.copyCodeAriaLabel,
|
|
2640
|
+
copiedStatusLabel: V?.copiedCodeStatusLabel
|
|
2592
2641
|
}),
|
|
2593
|
-
|
|
2642
|
+
Pe === J.Tools && /* @__PURE__ */ G(lr, { tools: e.details?.tools })
|
|
2594
2643
|
]
|
|
2595
2644
|
})
|
|
2596
2645
|
] })
|
|
2597
2646
|
]
|
|
2598
2647
|
}),
|
|
2599
|
-
|
|
2600
|
-
confirmLabel:
|
|
2601
|
-
cancelLabel:
|
|
2602
|
-
variant:
|
|
2648
|
+
ln && /* @__PURE__ */ G(S, {
|
|
2649
|
+
confirmLabel: cn.confirmLabel,
|
|
2650
|
+
cancelLabel: sn,
|
|
2651
|
+
variant: cn.variant,
|
|
2603
2652
|
isLoading: St,
|
|
2604
|
-
isConfirmDisabled:
|
|
2605
|
-
loadingStatusLabel:
|
|
2606
|
-
styles: { colors: { border:
|
|
2607
|
-
onConfirm:
|
|
2608
|
-
onCancel:
|
|
2653
|
+
isConfirmDisabled: un,
|
|
2654
|
+
loadingStatusLabel: cn.loadingStatusLabel,
|
|
2655
|
+
styles: { colors: { border: U?.confirmFooterBorder } },
|
|
2656
|
+
onConfirm: Ht,
|
|
2657
|
+
onCancel: Vt
|
|
2609
2658
|
}),
|
|
2610
|
-
!
|
|
2659
|
+
!ln && Re && /* @__PURE__ */ G(_t, {
|
|
2611
2660
|
version: e.version,
|
|
2612
2661
|
hasExistingPublicationInFolder: W.hasExistingPublicationInFolder,
|
|
2613
2662
|
isSubmitDisabled: pt.isSubmitDisabled,
|
|
2614
2663
|
isSubmitLoading: pt.isSubmitLoading,
|
|
2615
|
-
onCancel:
|
|
2616
|
-
onSubmit:
|
|
2664
|
+
onCancel: Gt,
|
|
2665
|
+
onSubmit: Kt,
|
|
2617
2666
|
labels: A
|
|
2618
2667
|
})
|
|
2619
2668
|
]
|
|
2620
2669
|
});
|
|
2621
|
-
},
|
|
2670
|
+
}, wr = {
|
|
2622
2671
|
pageNav: "_pageNav_14qfn_1",
|
|
2623
2672
|
navBtn: "_navBtn_14qfn_6",
|
|
2624
2673
|
titleText: "_titleText_14qfn_23",
|
|
@@ -2633,39 +2682,39 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2633
2682
|
favFadeIn: "_favFadeIn_14qfn_1",
|
|
2634
2683
|
cardLeaving: "_cardLeaving_14qfn_54",
|
|
2635
2684
|
cardFadeOut: "_cardFadeOut_14qfn_1"
|
|
2636
|
-
},
|
|
2637
|
-
let [m, h] =
|
|
2685
|
+
}, Tr = ({ item: e, initialIsStarred: t = !0, onToggle: n, isFavoriteVisible: r, onClick: i, nameClassName: a, colors: o, versionClassName: s, lastUsedClassName: c, query: l, addToFavoritesAriaLabel: u = "Add to favorites", removeFromFavoritesAriaLabel: d = "Remove from favorites", isSelected: f = !1, credentialsBadgeLoggedOutLabel: p }) => {
|
|
2686
|
+
let [m, h] = R(t), [g, _] = R(!1), v = (t) => {
|
|
2638
2687
|
t.stopPropagation();
|
|
2639
2688
|
let r = !m;
|
|
2640
2689
|
h(r), r ? n?.(e.id, r) : _(!0);
|
|
2641
|
-
}, y = i && !g ? () => i(e) : void 0, b =
|
|
2690
|
+
}, y = i && !g ? () => i(e) : void 0, b = P((t) => {
|
|
2642
2691
|
!i || g || (t.key === "Enter" || t.key === " ") && (t.preventDefault(), i(e));
|
|
2643
2692
|
}, [
|
|
2644
2693
|
i,
|
|
2645
2694
|
e,
|
|
2646
2695
|
g
|
|
2647
2696
|
]);
|
|
2648
|
-
return /* @__PURE__ */ K(
|
|
2697
|
+
return /* @__PURE__ */ K(pe, {
|
|
2649
2698
|
"data-card-id": e.id,
|
|
2650
2699
|
role: y == null ? void 0 : "button",
|
|
2651
2700
|
tabIndex: y == null ? void 0 : 0,
|
|
2652
2701
|
"aria-label": e.name,
|
|
2653
|
-
className: M("box-border min-w-0 cursor-pointer flex-row items-start gap-1 text-start", g &&
|
|
2702
|
+
className: M("box-border min-w-0 cursor-pointer flex-row items-start gap-1 text-start", g && wr.cardLeaving, f && wr.selectedCard, Et.favoriteCard),
|
|
2654
2703
|
onClick: y,
|
|
2655
2704
|
onKeyDown: b,
|
|
2656
2705
|
onAnimationEnd: g ? (t) => {
|
|
2657
2706
|
t.currentTarget === t.target && n?.(e.id, !1);
|
|
2658
2707
|
} : void 0,
|
|
2659
2708
|
children: [
|
|
2660
|
-
f && /* @__PURE__ */ G(
|
|
2661
|
-
size:
|
|
2662
|
-
className: M("absolute end-3 top-3 shrink-0",
|
|
2709
|
+
f && /* @__PURE__ */ G(Ke, {
|
|
2710
|
+
size: z.SM,
|
|
2711
|
+
className: M("absolute end-3 top-3 shrink-0", wr.selectedCheck),
|
|
2663
2712
|
"aria-hidden": !0,
|
|
2664
|
-
stroke:
|
|
2713
|
+
stroke: B
|
|
2665
2714
|
}),
|
|
2666
2715
|
/* @__PURE__ */ G("div", {
|
|
2667
2716
|
className: "flex min-w-0 flex-1 flex-col items-start gap-1",
|
|
2668
|
-
children: /* @__PURE__ */ G(
|
|
2717
|
+
children: /* @__PURE__ */ G(zt, {
|
|
2669
2718
|
icon: e.iconUrl,
|
|
2670
2719
|
type: e.type,
|
|
2671
2720
|
name: e.name,
|
|
@@ -2682,22 +2731,22 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2682
2731
|
lastUsedClassName: c
|
|
2683
2732
|
}
|
|
2684
2733
|
},
|
|
2685
|
-
iconOverlay: /* @__PURE__ */ G(
|
|
2734
|
+
iconOverlay: /* @__PURE__ */ G(Vt, {
|
|
2686
2735
|
credentials: e.credentials,
|
|
2687
2736
|
loggedOutLabel: p
|
|
2688
2737
|
})
|
|
2689
2738
|
})
|
|
2690
2739
|
}),
|
|
2691
|
-
r?.(e) !== !1 && /* @__PURE__ */ G(
|
|
2740
|
+
r?.(e) !== !1 && /* @__PURE__ */ G(Ut, {
|
|
2692
2741
|
isStarred: m,
|
|
2693
|
-
size:
|
|
2742
|
+
size: ye.Small,
|
|
2694
2743
|
onClick: v,
|
|
2695
2744
|
ariaLabel: m ? d : u,
|
|
2696
2745
|
className: "self-end"
|
|
2697
2746
|
})
|
|
2698
2747
|
]
|
|
2699
2748
|
});
|
|
2700
|
-
},
|
|
2749
|
+
}, Er = 2, Dr = (e) => {
|
|
2701
2750
|
let t = e.getBoundingClientRect(), n = window.scrollX, r = window.scrollY, i = window.getComputedStyle(e).transform;
|
|
2702
2751
|
if (!i || i === "none") return new DOMRect(t.x + n, t.y + r, t.width, t.height);
|
|
2703
2752
|
try {
|
|
@@ -2706,7 +2755,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2706
2755
|
} catch {
|
|
2707
2756
|
return new DOMRect(t.x + n, t.y + r, t.width, t.height);
|
|
2708
2757
|
}
|
|
2709
|
-
},
|
|
2758
|
+
}, Or = ({ items: e, totalCount: t, title: n = "Your Favorites", onToggleFavorite: r, isFavoriteVisible: i, onItemClick: a, styles: o, isLeaving: s, onExitComplete: c, prevPageAriaLabel: l = "Previous page", nextPageAriaLabel: u = "Next page", addToFavoritesAriaLabel: d, removeFromFavoritesAriaLabel: f, selectedItemId: p, credentialsBadgeLoggedOutLabel: m }) => {
|
|
2710
2759
|
let h = o?.typography?.titleClassName ?? "dial-body-semi-text", g = o?.typography?.countClassName ?? "dial-tiny-semi-text", _ = j({
|
|
2711
2760
|
"--cat-fav-title-text": o?.colors?.titleText,
|
|
2712
2761
|
"--cat-fav-count-text": o?.colors?.countText,
|
|
@@ -2719,49 +2768,49 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2719
2768
|
"--cat-fav-nav-btn-active-bg": o?.colors?.navButtonActiveBackground,
|
|
2720
2769
|
"--cat-fav-page-nav-border": o?.colors?.pageNavBorder,
|
|
2721
2770
|
"--cat-fav-page-nav-bg": o?.colors?.pageNavBackground
|
|
2722
|
-
}), v =
|
|
2771
|
+
}), v = I(() => [...e].sort((e, t) => (new Date(t.updatedAt || "").getTime() ?? 0) - (new Date(e.updatedAt || "").getTime() ?? 0)), [e]), [y, b] = R(1), x = Tt(), S = x * Er, C = (y - 1) * S, w = I(() => v.slice(C, C + S), [
|
|
2723
2772
|
v,
|
|
2724
2773
|
C,
|
|
2725
2774
|
S
|
|
2726
|
-
]), T = Math.ceil(v.length / S), E = t ?? e.length, D =
|
|
2727
|
-
|
|
2775
|
+
]), T = Math.ceil(v.length / S), E = t ?? e.length, D = L(null), O = L(null), k = L(null), [A, te] = R(), [ne, re] = R(), ie = L(x);
|
|
2776
|
+
F(() => {
|
|
2728
2777
|
ie.current !== x && (ie.current = x, b(1), te(void 0), re(void 0));
|
|
2729
|
-
}, [x]),
|
|
2778
|
+
}, [x]), F(() => {
|
|
2730
2779
|
y > T && T > 0 && b(T);
|
|
2731
|
-
}, [y, T]),
|
|
2780
|
+
}, [y, T]), F(() => {
|
|
2732
2781
|
T <= 1 && (A !== void 0 || ne !== void 0) && (te(void 0), re(void 0));
|
|
2733
2782
|
}, [
|
|
2734
2783
|
T,
|
|
2735
2784
|
A,
|
|
2736
2785
|
ne
|
|
2737
|
-
]),
|
|
2786
|
+
]), se(() => {
|
|
2738
2787
|
!k.current || !O.current || T <= 1 || y !== 1 || A !== void 0 || (te(k.current.offsetHeight), re(O.current.offsetHeight));
|
|
2739
2788
|
}, [
|
|
2740
2789
|
T,
|
|
2741
2790
|
y,
|
|
2742
2791
|
A
|
|
2743
2792
|
]);
|
|
2744
|
-
let
|
|
2745
|
-
return
|
|
2793
|
+
let N = L(/* @__PURE__ */ new Map()), ae = L(y), P = L(x), oe = L(0), ce = L(!1);
|
|
2794
|
+
return se(() => {
|
|
2746
2795
|
if (!k.current || s) return;
|
|
2747
|
-
if (D.current && !
|
|
2796
|
+
if (D.current && !ce.current) {
|
|
2748
2797
|
let e = D.current;
|
|
2749
2798
|
e.style.height = "", e.style.transition = "";
|
|
2750
2799
|
}
|
|
2751
|
-
let e =
|
|
2752
|
-
|
|
2800
|
+
let e = ae.current !== y, t = P.current !== x;
|
|
2801
|
+
ae.current = y, P.current = x;
|
|
2753
2802
|
let n = k.current.querySelectorAll("[data-card-id]"), r = /* @__PURE__ */ new Map();
|
|
2754
2803
|
if (n.forEach((e) => {
|
|
2755
|
-
r.set(e.dataset.cardId,
|
|
2804
|
+
r.set(e.dataset.cardId, Dr(e));
|
|
2756
2805
|
}), !e && !t) {
|
|
2757
|
-
let e = O.current, t =
|
|
2806
|
+
let e = O.current, t = oe.current, i = 0;
|
|
2758
2807
|
if (e) {
|
|
2759
2808
|
let t = e.style.height;
|
|
2760
2809
|
t && (e.style.height = ""), i = e.offsetHeight, t && (e.style.height = t);
|
|
2761
2810
|
}
|
|
2762
2811
|
let a = e != null && t > 0 && Math.abs(i - t) > 2, o = i > t ? 280 : 220, s = [];
|
|
2763
2812
|
if (n.forEach((e) => {
|
|
2764
|
-
let t = e.dataset.cardId, n =
|
|
2813
|
+
let t = e.dataset.cardId, n = N.current.get(t), i = r.get(t);
|
|
2765
2814
|
if (!n || !i) return;
|
|
2766
2815
|
let o = n.left - i.left, c = n.top - i.top;
|
|
2767
2816
|
!a && Math.abs(c) > .5 || Math.abs(o) < .5 && Math.abs(c) < .5 || (e.style.transition = "none", e.style.transform = `translate(${o}px, ${c}px)`, s.push(e));
|
|
@@ -2777,30 +2826,30 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2777
2826
|
e.addEventListener("transitionend", t);
|
|
2778
2827
|
}
|
|
2779
2828
|
}
|
|
2780
|
-
if (
|
|
2829
|
+
if (N.current = r, O.current) {
|
|
2781
2830
|
let e = O.current, t = e.style.height ? parseFloat(e.style.height) : NaN;
|
|
2782
|
-
|
|
2831
|
+
oe.current = Number.isNaN(t) ? e.offsetHeight : t;
|
|
2783
2832
|
}
|
|
2784
2833
|
}, [
|
|
2785
2834
|
w,
|
|
2786
2835
|
y,
|
|
2787
2836
|
x,
|
|
2788
2837
|
s
|
|
2789
|
-
]),
|
|
2838
|
+
]), se(() => {
|
|
2790
2839
|
let e = D.current;
|
|
2791
2840
|
if (!e) return;
|
|
2792
2841
|
let t = e.offsetHeight;
|
|
2793
2842
|
if (t === 0) return;
|
|
2794
|
-
|
|
2843
|
+
ce.current = !0, e.style.height = "0px", e.offsetHeight, e.style.transition = "height 300ms cubic-bezier(0, 0, 0.2, 1)", e.style.height = `${t}px`;
|
|
2795
2844
|
let n = (t) => {
|
|
2796
2845
|
t.target !== e || t.propertyName !== "height" || r();
|
|
2797
2846
|
}, r = () => {
|
|
2798
|
-
|
|
2847
|
+
ce.current = !1, parseFloat(e.style.height || "0") > 0 && (e.style.height = "", e.style.transition = ""), clearTimeout(i), e.removeEventListener("transitionend", n);
|
|
2799
2848
|
}, i = setTimeout(r, 400);
|
|
2800
2849
|
return e.addEventListener("transitionend", n), () => {
|
|
2801
2850
|
clearTimeout(i), e.removeEventListener("transitionend", n);
|
|
2802
2851
|
};
|
|
2803
|
-
}, []),
|
|
2852
|
+
}, []), se(() => {
|
|
2804
2853
|
if (!s || !D.current) return;
|
|
2805
2854
|
let e = D.current, t = e.offsetHeight;
|
|
2806
2855
|
t !== 0 && (e.style.height = `${t}px`, e.offsetHeight, e.style.transition = "height 260ms ease-in", e.style.height = "0px");
|
|
@@ -2808,7 +2857,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2808
2857
|
ref: D,
|
|
2809
2858
|
children: /* @__PURE__ */ K("section", {
|
|
2810
2859
|
ref: O,
|
|
2811
|
-
className: M("flex flex-shrink-0 flex-col gap-4 pb-2 pt-2",
|
|
2860
|
+
className: M("flex flex-shrink-0 flex-col gap-4 pb-2 pt-2", wr.section, s && wr.sectionLeaving),
|
|
2812
2861
|
style: {
|
|
2813
2862
|
..._,
|
|
2814
2863
|
minHeight: ne
|
|
@@ -2819,55 +2868,55 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2819
2868
|
children: [/* @__PURE__ */ G(ee, {
|
|
2820
2869
|
title: n,
|
|
2821
2870
|
postfix: E,
|
|
2822
|
-
titleClassName: M(h,
|
|
2823
|
-
postfixClassName: M(g,
|
|
2871
|
+
titleClassName: M(h, wr.titleText),
|
|
2872
|
+
postfixClassName: M(g, wr.countText),
|
|
2824
2873
|
trailing: T > 1 ? /* @__PURE__ */ K("div", {
|
|
2825
|
-
className: M("inline-flex items-center gap-[2px] rounded-full px-[6px] py-[3px]",
|
|
2874
|
+
className: M("inline-flex items-center gap-[2px] rounded-full px-[6px] py-[3px]", wr.pageNav),
|
|
2826
2875
|
children: [
|
|
2827
|
-
/* @__PURE__ */ G(
|
|
2828
|
-
size:
|
|
2876
|
+
/* @__PURE__ */ G(V, {
|
|
2877
|
+
size: ye.Small,
|
|
2829
2878
|
"aria-label": l,
|
|
2830
2879
|
disabled: y === 1,
|
|
2831
2880
|
onClick: () => b((e) => e - 1),
|
|
2832
|
-
className: M("rounded-full",
|
|
2833
|
-
icon: /* @__PURE__ */ G(
|
|
2881
|
+
className: M("rounded-full", wr.navBtn),
|
|
2882
|
+
icon: /* @__PURE__ */ G(Je, {
|
|
2834
2883
|
size: 14,
|
|
2835
2884
|
"aria-hidden": !0,
|
|
2836
2885
|
className: "rtl:scale-x-[-1]",
|
|
2837
|
-
stroke:
|
|
2886
|
+
stroke: B
|
|
2838
2887
|
})
|
|
2839
2888
|
}),
|
|
2840
2889
|
/* @__PURE__ */ K("span", {
|
|
2841
|
-
className: M("min-w-[32px] select-none px-1 text-center", g,
|
|
2890
|
+
className: M("min-w-[32px] select-none px-1 text-center", g, wr.countText),
|
|
2842
2891
|
children: [
|
|
2843
2892
|
y,
|
|
2844
2893
|
" / ",
|
|
2845
2894
|
T
|
|
2846
2895
|
]
|
|
2847
2896
|
}),
|
|
2848
|
-
/* @__PURE__ */ G(
|
|
2849
|
-
size:
|
|
2897
|
+
/* @__PURE__ */ G(V, {
|
|
2898
|
+
size: ye.Small,
|
|
2850
2899
|
"aria-label": u,
|
|
2851
2900
|
disabled: y === T,
|
|
2852
2901
|
onClick: () => b((e) => e + 1),
|
|
2853
|
-
className: M("rounded-full",
|
|
2854
|
-
icon: /* @__PURE__ */ G(
|
|
2902
|
+
className: M("rounded-full", wr.navBtn),
|
|
2903
|
+
icon: /* @__PURE__ */ G(Ye, {
|
|
2855
2904
|
size: 14,
|
|
2856
2905
|
"aria-hidden": !0,
|
|
2857
2906
|
className: "rtl:scale-x-[-1]",
|
|
2858
|
-
stroke:
|
|
2907
|
+
stroke: B
|
|
2859
2908
|
})
|
|
2860
2909
|
})
|
|
2861
2910
|
]
|
|
2862
2911
|
}) : void 0
|
|
2863
2912
|
}), /* @__PURE__ */ G("div", {
|
|
2864
2913
|
ref: k,
|
|
2865
|
-
className: M("grid content-start gap-5",
|
|
2914
|
+
className: M("grid content-start gap-5", wr.gridPage),
|
|
2866
2915
|
style: {
|
|
2867
2916
|
gridTemplateColumns: `repeat(${x}, minmax(0, 1fr))`,
|
|
2868
2917
|
minHeight: A
|
|
2869
2918
|
},
|
|
2870
|
-
children: w.map((e) => /* @__PURE__ */ G(
|
|
2919
|
+
children: w.map((e) => /* @__PURE__ */ G(Tr, {
|
|
2871
2920
|
item: e,
|
|
2872
2921
|
onToggle: r,
|
|
2873
2922
|
isFavoriteVisible: i,
|
|
@@ -2880,7 +2929,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2880
2929
|
})]
|
|
2881
2930
|
})
|
|
2882
2931
|
});
|
|
2883
|
-
},
|
|
2932
|
+
}, kr = {
|
|
2884
2933
|
listContainer: "_listContainer_lksnp_1",
|
|
2885
2934
|
gridClip: "_gridClip_lksnp_6",
|
|
2886
2935
|
favHeader: "_favHeader_lksnp_35",
|
|
@@ -2889,29 +2938,29 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2889
2938
|
selectedCheck: "_selectedCheck_lksnp_47",
|
|
2890
2939
|
starToggleOff: "_starToggleOff_lksnp_51",
|
|
2891
2940
|
selectedRow: "_selectedRow_lksnp_64"
|
|
2892
|
-
},
|
|
2941
|
+
}, Ar = ({ data: e }) => e ? /* @__PURE__ */ G("div", {
|
|
2893
2942
|
className: "flex h-full items-center",
|
|
2894
2943
|
children: /* @__PURE__ */ G(D, { type: e.type })
|
|
2895
|
-
}) : null,
|
|
2944
|
+
}) : null, jr = " / ", Mr = ({ data: e, context: t }) => {
|
|
2896
2945
|
if (!e || e.folder.length === 0) return null;
|
|
2897
|
-
let n = e.folder.join(
|
|
2946
|
+
let n = e.folder.join(jr), r = e.folder[e.folder.length - 1], i = e.folder.length > 1, a = t?.typography?.folderClassName ?? "dial-small-text", o = t?.typography?.folderLastSegmentClassName ?? "dial-small-semi-text";
|
|
2898
2947
|
return /* @__PURE__ */ K("div", {
|
|
2899
2948
|
className: "flex h-full w-full min-w-0 items-center gap-1.5",
|
|
2900
2949
|
children: [
|
|
2901
|
-
/* @__PURE__ */ G(
|
|
2902
|
-
size:
|
|
2903
|
-
stroke:
|
|
2904
|
-
className: M("shrink-0",
|
|
2950
|
+
/* @__PURE__ */ G(et, {
|
|
2951
|
+
size: z.SM,
|
|
2952
|
+
stroke: B,
|
|
2953
|
+
className: M("shrink-0", kr.folderIcon),
|
|
2905
2954
|
"aria-hidden": !0
|
|
2906
2955
|
}),
|
|
2907
|
-
/* @__PURE__ */ G(
|
|
2956
|
+
/* @__PURE__ */ G(Ve, {
|
|
2908
2957
|
tooltip: /* @__PURE__ */ G("span", {
|
|
2909
2958
|
className: a,
|
|
2910
2959
|
children: n
|
|
2911
2960
|
}),
|
|
2912
2961
|
hideTooltip: !i,
|
|
2913
2962
|
triggerClassName: "min-w-0 flex-1",
|
|
2914
|
-
children: /* @__PURE__ */ G(
|
|
2963
|
+
children: /* @__PURE__ */ G(be, {
|
|
2915
2964
|
text: r,
|
|
2916
2965
|
className: o,
|
|
2917
2966
|
hideTooltip: i
|
|
@@ -2923,7 +2972,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2923
2972
|
})
|
|
2924
2973
|
]
|
|
2925
2974
|
});
|
|
2926
|
-
},
|
|
2975
|
+
}, Nr = ({ data: e, context: t }) => {
|
|
2927
2976
|
let n = t?.searchQuery ?? "", r = t?.typography, i = r?.nameClassName ?? "dial-small-semi-text", a = r?.versionClassName ?? "dial-tiny-text", o = e != null && e.id === t?.selectedItemId;
|
|
2928
2977
|
return e ? /* @__PURE__ */ K("div", {
|
|
2929
2978
|
className: "flex h-full w-full min-w-0 items-center gap-2.5",
|
|
@@ -2934,7 +2983,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2934
2983
|
size: 36,
|
|
2935
2984
|
initialsName: e.name,
|
|
2936
2985
|
styles: { badgeClassName: "rounded-[10px]" }
|
|
2937
|
-
}), /* @__PURE__ */ G(
|
|
2986
|
+
}), /* @__PURE__ */ G(Vt, {
|
|
2938
2987
|
credentials: e.credentials,
|
|
2939
2988
|
loggedOutLabel: t?.credentialsBadgeLoggedOutLabel
|
|
2940
2989
|
})]
|
|
@@ -2945,43 +2994,43 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2945
2994
|
query: n,
|
|
2946
2995
|
titleClassName: i,
|
|
2947
2996
|
className: "min-w-0 flex-1 items-baseline gap-1.5",
|
|
2948
|
-
trailing: o ? /* @__PURE__ */ G(
|
|
2949
|
-
size:
|
|
2950
|
-
className: M("shrink-0",
|
|
2997
|
+
trailing: o ? /* @__PURE__ */ G(Ke, {
|
|
2998
|
+
size: z.SM,
|
|
2999
|
+
className: M("shrink-0", kr.selectedCheck),
|
|
2951
3000
|
"aria-hidden": !0,
|
|
2952
|
-
stroke:
|
|
3001
|
+
stroke: B
|
|
2953
3002
|
}) : void 0
|
|
2954
3003
|
})]
|
|
2955
3004
|
}) : null;
|
|
2956
|
-
},
|
|
2957
|
-
let [n, r] =
|
|
2958
|
-
return
|
|
3005
|
+
}, Pr = ({ data: e, context: t }) => {
|
|
3006
|
+
let [n, r] = R(e?.isStarred ?? !1);
|
|
3007
|
+
return F(() => {
|
|
2959
3008
|
r(e?.isStarred ?? !1);
|
|
2960
3009
|
}, [e?.id, e?.isStarred]), !e || t?.isFavoriteVisible?.(e) === !1 ? null : /* @__PURE__ */ G("div", {
|
|
2961
3010
|
className: "flex size-full items-center justify-end",
|
|
2962
|
-
children: /* @__PURE__ */ G(
|
|
3011
|
+
children: /* @__PURE__ */ G(Ut, {
|
|
2963
3012
|
isStarred: n,
|
|
2964
3013
|
onClick: (i) => {
|
|
2965
3014
|
i.stopPropagation();
|
|
2966
3015
|
let a = !n;
|
|
2967
3016
|
r(a), t?.onToggleFavorite?.(e.id, a);
|
|
2968
3017
|
},
|
|
2969
|
-
className: n ? void 0 :
|
|
3018
|
+
className: n ? void 0 : kr.starToggleOff
|
|
2970
3019
|
})
|
|
2971
3020
|
});
|
|
2972
|
-
},
|
|
3021
|
+
}, Fr = ({ data: e }) => !e || e.topics.length === 0 ? null : /* @__PURE__ */ G("div", {
|
|
2973
3022
|
className: "flex h-full w-full min-w-0 items-center",
|
|
2974
|
-
children: /* @__PURE__ */ G(
|
|
2975
|
-
}),
|
|
3023
|
+
children: /* @__PURE__ */ G(Jt, { topics: e.topics })
|
|
3024
|
+
}), Ir = {
|
|
2976
3025
|
folder: (e) => e !== x.Model,
|
|
2977
3026
|
tags: () => !0,
|
|
2978
3027
|
favorite: () => !0
|
|
2979
|
-
},
|
|
3028
|
+
}, Lr = (e, t) => Object.fromEntries([
|
|
2980
3029
|
"folder",
|
|
2981
3030
|
"tags",
|
|
2982
3031
|
"favorite"
|
|
2983
|
-
].map((n) => [n, (t?.[n] ??
|
|
2984
|
-
let r =
|
|
3032
|
+
].map((n) => [n, (t?.[n] ?? Ir[n])(e)])), Rr = (e, t = !1, n) => {
|
|
3033
|
+
let r = Lr(e, n);
|
|
2985
3034
|
return [
|
|
2986
3035
|
{
|
|
2987
3036
|
headerName: "Name",
|
|
@@ -2989,7 +3038,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2989
3038
|
minWidth: 220,
|
|
2990
3039
|
field: "name",
|
|
2991
3040
|
filter: !1,
|
|
2992
|
-
cellRenderer:
|
|
3041
|
+
cellRenderer: Nr,
|
|
2993
3042
|
valueGetter: (e) => e.data?.name
|
|
2994
3043
|
},
|
|
2995
3044
|
{
|
|
@@ -2999,7 +3048,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
2999
3048
|
field: "type",
|
|
3000
3049
|
filter: !1,
|
|
3001
3050
|
sortable: !1,
|
|
3002
|
-
cellRenderer:
|
|
3051
|
+
cellRenderer: Ar,
|
|
3003
3052
|
valueGetter: (e) => e.data?.type
|
|
3004
3053
|
},
|
|
3005
3054
|
{
|
|
@@ -3009,7 +3058,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3009
3058
|
minWidth: 170,
|
|
3010
3059
|
filter: !1,
|
|
3011
3060
|
hide: !r.folder,
|
|
3012
|
-
cellRenderer:
|
|
3061
|
+
cellRenderer: Mr,
|
|
3013
3062
|
valueGetter: (e) => e.data?.folder
|
|
3014
3063
|
},
|
|
3015
3064
|
{
|
|
@@ -3020,7 +3069,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3020
3069
|
filter: !1,
|
|
3021
3070
|
sortable: !1,
|
|
3022
3071
|
hide: !r.tags,
|
|
3023
|
-
cellRenderer:
|
|
3072
|
+
cellRenderer: Fr,
|
|
3024
3073
|
valueGetter: (e) => e.data?.topics
|
|
3025
3074
|
},
|
|
3026
3075
|
{
|
|
@@ -3032,15 +3081,15 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3032
3081
|
sortable: !1,
|
|
3033
3082
|
resizable: !1,
|
|
3034
3083
|
hide: t || !r.favorite,
|
|
3035
|
-
headerClass:
|
|
3036
|
-
cellRenderer:
|
|
3084
|
+
headerClass: kr.favHeader,
|
|
3085
|
+
cellRenderer: Pr
|
|
3037
3086
|
}
|
|
3038
3087
|
];
|
|
3039
|
-
},
|
|
3040
|
-
className:
|
|
3088
|
+
}, zr = 60, Br = {}, Vr = (e) => e.id, Hr = (e) => e.items.length === 0 ? /* @__PURE__ */ G("div", {
|
|
3089
|
+
className: He("flex size-full flex-col items-center justify-center", Et.listView),
|
|
3041
3090
|
children: /* @__PURE__ */ G(ne, { label: e.emptyStateTitle ?? "No results" })
|
|
3042
|
-
}) : /* @__PURE__ */ G(
|
|
3043
|
-
let m = a?.typography ??
|
|
3091
|
+
}) : /* @__PURE__ */ G(Ur, { ...e }), Ur = ({ items: e, type: t, query: n = "", ariaLabel: r = "Catalog", emptyStateTitle: i, styles: a, onToggleFavorite: o, isFavoriteVisible: s, onItemClick: c, stickyHeaderTop: l, selectedItemId: u, credentialsBadgeLoggedOutLabel: d, isReadonly: f = !1, columnVisibility: p }) => {
|
|
3092
|
+
let m = a?.typography ?? Br, h = a?.colors, g = {
|
|
3044
3093
|
"--cat-list-bg": h?.background,
|
|
3045
3094
|
"--cat-list-border": h?.border,
|
|
3046
3095
|
"--cat-list-header-bg": h?.headerBackground,
|
|
@@ -3052,15 +3101,15 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3052
3101
|
"--cat-list-selected-bg": h?.selectedRowBackground,
|
|
3053
3102
|
"--cat-list-selected-check": h?.selectedRowCheckIcon,
|
|
3054
3103
|
...l == null ? {} : { "--list-header-sticky-top": `${l}px` }
|
|
3055
|
-
}, _ =
|
|
3104
|
+
}, _ = L(null), v = P((e) => {
|
|
3056
3105
|
_.current = e;
|
|
3057
|
-
}, []), y =
|
|
3106
|
+
}, []), y = I(() => Rr(t, f, p), [
|
|
3058
3107
|
t,
|
|
3059
3108
|
f,
|
|
3060
3109
|
p
|
|
3061
|
-
]), b =
|
|
3110
|
+
]), b = I(() => ({
|
|
3062
3111
|
domLayout: "autoHeight",
|
|
3063
|
-
rowHeight:
|
|
3112
|
+
rowHeight: zr,
|
|
3064
3113
|
animateRows: !1,
|
|
3065
3114
|
suppressAnimationFrame: !0,
|
|
3066
3115
|
suppressScrollOnNewData: !0,
|
|
@@ -3081,7 +3130,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3081
3130
|
e.column.getColDef().field !== "isStarred" && e.data && c(e.data);
|
|
3082
3131
|
} : void 0,
|
|
3083
3132
|
rowClass: c ? "cursor-pointer" : void 0,
|
|
3084
|
-
getRowClass: (e) => e.data?.id === u ?
|
|
3133
|
+
getRowClass: (e) => e.data?.id === u ? kr.selectedRow : void 0
|
|
3085
3134
|
}), [
|
|
3086
3135
|
n,
|
|
3087
3136
|
m,
|
|
@@ -3091,30 +3140,30 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3091
3140
|
d,
|
|
3092
3141
|
f,
|
|
3093
3142
|
c
|
|
3094
|
-
]), { containerRef: x, startRow: S, endRow: C } =
|
|
3143
|
+
]), { containerRef: x, startRow: S, endRow: C } = Ft(e.length, zr), w = I(() => e.slice(S, C), [
|
|
3095
3144
|
e,
|
|
3096
3145
|
S,
|
|
3097
3146
|
C
|
|
3098
3147
|
]);
|
|
3099
|
-
return
|
|
3148
|
+
return F(() => {
|
|
3100
3149
|
_.current?.refreshCells({ force: !0 });
|
|
3101
|
-
}, [n]),
|
|
3150
|
+
}, [n]), F(() => {
|
|
3102
3151
|
_.current?.redrawRows();
|
|
3103
3152
|
}, [u]), /* @__PURE__ */ G("div", {
|
|
3104
3153
|
style: g,
|
|
3105
|
-
className:
|
|
3154
|
+
className: He("w-full rounded-xl border", kr.listContainer, Et.listView),
|
|
3106
3155
|
children: /* @__PURE__ */ K("div", {
|
|
3107
3156
|
ref: x,
|
|
3108
|
-
className:
|
|
3157
|
+
className: He("rounded-xl [&_.ag-cell.ag-column-first]:ps-4 [&_.ag-cell.ag-column-last]:pe-4 [&_.ag-header-cell.ag-column-first]:ps-4 [&_.ag-header-cell.ag-column-last]:pe-4", kr.gridClip),
|
|
3109
3158
|
children: [
|
|
3110
3159
|
S > 0 && /* @__PURE__ */ G("div", {
|
|
3111
|
-
style: { height: S *
|
|
3160
|
+
style: { height: S * zr },
|
|
3112
3161
|
"aria-hidden": !0
|
|
3113
3162
|
}),
|
|
3114
3163
|
/* @__PURE__ */ G(xt, {
|
|
3115
3164
|
columnDefs: y,
|
|
3116
3165
|
rowData: w,
|
|
3117
|
-
getRowId:
|
|
3166
|
+
getRowId: Vr,
|
|
3118
3167
|
withoutHeaderBorders: !0,
|
|
3119
3168
|
wrapCustomCellRenderers: !1,
|
|
3120
3169
|
onGridApiChange: v,
|
|
@@ -3123,13 +3172,13 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3123
3172
|
ariaLabel: r
|
|
3124
3173
|
}),
|
|
3125
3174
|
C < e.length && /* @__PURE__ */ G("div", {
|
|
3126
|
-
style: { height: (e.length - C) *
|
|
3175
|
+
style: { height: (e.length - C) * zr },
|
|
3127
3176
|
"aria-hidden": !0
|
|
3128
3177
|
})
|
|
3129
3178
|
]
|
|
3130
3179
|
})
|
|
3131
3180
|
});
|
|
3132
|
-
},
|
|
3181
|
+
}, Wr = {
|
|
3133
3182
|
filterBtn: "_filterBtn_5r8a5_7",
|
|
3134
3183
|
filterBtnActive: "_filterBtnActive_5r8a5_24",
|
|
3135
3184
|
filterBtnOpen: "_filterBtnOpen_5r8a5_28",
|
|
@@ -3141,14 +3190,14 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3141
3190
|
divider: "_divider_5r8a5_63",
|
|
3142
3191
|
sectionLabel: "_sectionLabel_5r8a5_67",
|
|
3143
3192
|
footer: "_footer_5r8a5_71"
|
|
3144
|
-
},
|
|
3193
|
+
}, Gr = (e, t, n, r, i) => {
|
|
3145
3194
|
let a = e.size > 0;
|
|
3146
3195
|
return n && a ? `${r} · ${e.size}` : n ? r : a ? p(e, t, i) : i;
|
|
3147
|
-
},
|
|
3196
|
+
}, Kr = (e, t) => {
|
|
3148
3197
|
let n = new Set(t);
|
|
3149
3198
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
3150
|
-
},
|
|
3151
|
-
let f = (r ?? !1) || e.size > 0, [p, m] =
|
|
3199
|
+
}, qr = ({ checked: e, onChange: t, values: n, isMyAppsActive: r, onMyAppsChange: i, myAppsLabel: a = "My", topicsLabel: o = "Topics", defaultLabel: s = "From", clearLabel: c = "Clear", applyLabel: l = "Apply", typography: u, colors: d }) => {
|
|
3200
|
+
let f = (r ?? !1) || e.size > 0, [p, m] = R(!1), h = j({
|
|
3152
3201
|
"--cat-filter-btn-bg": d?.buttonBackground,
|
|
3153
3202
|
"--cat-filter-btn-border": d?.buttonBorder,
|
|
3154
3203
|
"--cat-filter-btn-border-hover": d?.buttonBorderHover,
|
|
@@ -3164,19 +3213,19 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3164
3213
|
"--cat-filter-section-label": d?.sectionLabel,
|
|
3165
3214
|
"--cat-filter-divider": d?.divider,
|
|
3166
3215
|
"--cat-filter-footer-border": d?.footerBorder
|
|
3167
|
-
}), g =
|
|
3168
|
-
|
|
3216
|
+
}), g = I(() => n == null ? [] : [...n].sort(), [n]), _ = Gr(e, n, r, a, s), [v, y] = R(() => new Set(e)), [b, x] = R(r ?? !1);
|
|
3217
|
+
F(() => {
|
|
3169
3218
|
p && (y(new Set(e)), x(r ?? !1));
|
|
3170
3219
|
}, [
|
|
3171
3220
|
p,
|
|
3172
3221
|
e,
|
|
3173
3222
|
r
|
|
3174
3223
|
]);
|
|
3175
|
-
let S = g.length + 1, [C, w] =
|
|
3224
|
+
let S = g.length + 1, [C, w] = R(-1), T = L([]), E = L(null), D = P((e) => {
|
|
3176
3225
|
let t = (e + S) % S;
|
|
3177
3226
|
w(t), T.current[t]?.focus();
|
|
3178
3227
|
}, [S]);
|
|
3179
|
-
|
|
3228
|
+
F(() => {
|
|
3180
3229
|
if (!p) {
|
|
3181
3230
|
w(-1);
|
|
3182
3231
|
return;
|
|
@@ -3195,7 +3244,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3195
3244
|
}, te = () => {
|
|
3196
3245
|
t(/* @__PURE__ */ new Set()), i?.(!1), O(!1);
|
|
3197
3246
|
};
|
|
3198
|
-
return /* @__PURE__ */ G(
|
|
3247
|
+
return /* @__PURE__ */ G(_e, {
|
|
3199
3248
|
matchReferenceWidth: !1,
|
|
3200
3249
|
placement: "bottom-start",
|
|
3201
3250
|
open: p,
|
|
@@ -3209,16 +3258,16 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3209
3258
|
...h,
|
|
3210
3259
|
maxHeight: "calc(var(--fui-available-height, 9999px) - 8px)"
|
|
3211
3260
|
},
|
|
3212
|
-
className: M("flex min-w-[360px] flex-col rounded-xl p-[6px]",
|
|
3261
|
+
className: M("flex min-w-[360px] flex-col rounded-xl p-[6px]", Wr.overlay),
|
|
3213
3262
|
onKeyDown: k,
|
|
3214
3263
|
children: [
|
|
3215
|
-
/* @__PURE__ */ G(
|
|
3264
|
+
/* @__PURE__ */ G(Oe, {
|
|
3216
3265
|
role: "menuitemcheckbox",
|
|
3217
3266
|
"aria-checked": b,
|
|
3218
|
-
mark:
|
|
3267
|
+
mark: ke.Checkbox,
|
|
3219
3268
|
selected: b,
|
|
3220
3269
|
label: a,
|
|
3221
|
-
labelClassName: M(
|
|
3270
|
+
labelClassName: M(Wr.rowLabel, u?.filterButtonClassName ?? "dial-small-semi-text"),
|
|
3222
3271
|
className: "shrink-0",
|
|
3223
3272
|
tabIndex: C === 0 ? 0 : -1,
|
|
3224
3273
|
ref: (e) => {
|
|
@@ -3229,11 +3278,11 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3229
3278
|
g.length > 0 && /* @__PURE__ */ K(gt, { children: [
|
|
3230
3279
|
/* @__PURE__ */ G("div", {
|
|
3231
3280
|
role: "separator",
|
|
3232
|
-
className: M("my-1 h-px",
|
|
3281
|
+
className: M("my-1 h-px", Wr.divider),
|
|
3233
3282
|
"aria-hidden": !0
|
|
3234
3283
|
}),
|
|
3235
3284
|
/* @__PURE__ */ G("div", {
|
|
3236
|
-
className: M("px-[10px] pb-1 pt-[10px]", u?.filterSectionLabelClassName ?? "dial-tiny-lead-semi-text",
|
|
3285
|
+
className: M("px-[10px] pb-1 pt-[10px]", u?.filterSectionLabelClassName ?? "dial-tiny-lead-semi-text", Wr.sectionLabel),
|
|
3237
3286
|
"aria-hidden": !0,
|
|
3238
3287
|
children: o
|
|
3239
3288
|
}),
|
|
@@ -3241,32 +3290,32 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3241
3290
|
className: M(re, "flex min-h-0 flex-col gap-1 overflow-y-auto"),
|
|
3242
3291
|
children: g.map((e, t) => {
|
|
3243
3292
|
let n = v.has(e), r = t + 1;
|
|
3244
|
-
return /* @__PURE__ */ G(
|
|
3293
|
+
return /* @__PURE__ */ G(Oe, {
|
|
3245
3294
|
role: "menuitemcheckbox",
|
|
3246
3295
|
"aria-checked": n,
|
|
3247
|
-
mark:
|
|
3296
|
+
mark: ke.Checkbox,
|
|
3248
3297
|
selected: n,
|
|
3249
3298
|
label: e,
|
|
3250
|
-
labelClassName:
|
|
3299
|
+
labelClassName: Wr.rowLabel,
|
|
3251
3300
|
className: "shrink-0",
|
|
3252
3301
|
tabIndex: C === r ? 0 : -1,
|
|
3253
3302
|
ref: (e) => {
|
|
3254
3303
|
T.current[r] = e;
|
|
3255
3304
|
},
|
|
3256
|
-
onClick: () => y(
|
|
3305
|
+
onClick: () => y(Kr(e, v))
|
|
3257
3306
|
}, e);
|
|
3258
3307
|
})
|
|
3259
3308
|
})
|
|
3260
3309
|
] }),
|
|
3261
3310
|
/* @__PURE__ */ K("div", {
|
|
3262
|
-
className: M("mt-1 flex shrink-0 items-center px-1 py-3",
|
|
3311
|
+
className: M("mt-1 flex shrink-0 items-center px-1 py-3", Wr.footer),
|
|
3263
3312
|
onKeyDown: (e) => {
|
|
3264
3313
|
(e.key === "ArrowUp" || e.key === "ArrowDown") && e.stopPropagation();
|
|
3265
3314
|
},
|
|
3266
|
-
children: [/* @__PURE__ */ G(
|
|
3315
|
+
children: [/* @__PURE__ */ G(Se, {
|
|
3267
3316
|
label: c,
|
|
3268
3317
|
onClick: te
|
|
3269
|
-
}), /* @__PURE__ */ G(
|
|
3318
|
+
}), /* @__PURE__ */ G(Ae, {
|
|
3270
3319
|
label: l,
|
|
3271
3320
|
className: "ms-auto",
|
|
3272
3321
|
onClick: A
|
|
@@ -3274,55 +3323,55 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3274
3323
|
})
|
|
3275
3324
|
]
|
|
3276
3325
|
}),
|
|
3277
|
-
children: /* @__PURE__ */ G(
|
|
3326
|
+
children: /* @__PURE__ */ G(le, {
|
|
3278
3327
|
ref: E,
|
|
3279
3328
|
"aria-haspopup": "menu",
|
|
3280
3329
|
"aria-expanded": p,
|
|
3281
3330
|
onKeyDown: ee,
|
|
3282
3331
|
style: h,
|
|
3283
|
-
iconBefore: /* @__PURE__ */ G(
|
|
3284
|
-
size:
|
|
3285
|
-
stroke:
|
|
3286
|
-
className: M("shrink-0",
|
|
3332
|
+
iconBefore: /* @__PURE__ */ G($e, {
|
|
3333
|
+
size: z.SM,
|
|
3334
|
+
stroke: B,
|
|
3335
|
+
className: M("shrink-0", Wr.filterBtnFunnel),
|
|
3287
3336
|
"aria-hidden": !0
|
|
3288
3337
|
}),
|
|
3289
3338
|
label: _,
|
|
3290
|
-
textClassName: M(
|
|
3291
|
-
iconAfter: /* @__PURE__ */ G(
|
|
3339
|
+
textClassName: M(Wr.filterBtnLabel, u?.filterButtonClassName ?? "dial-small-semi-text"),
|
|
3340
|
+
iconAfter: /* @__PURE__ */ G(qe, {
|
|
3292
3341
|
size: 14,
|
|
3293
|
-
stroke:
|
|
3294
|
-
className: M("shrink-0 transition-transform duration-150",
|
|
3342
|
+
stroke: B,
|
|
3343
|
+
className: M("shrink-0 transition-transform duration-150", Wr.filterBtnChevron, p && "rotate-180"),
|
|
3295
3344
|
"aria-hidden": !0
|
|
3296
3345
|
}),
|
|
3297
|
-
className: M("h-12 shrink-0 gap-[7px] whitespace-nowrap !rounded-lg px-[18px]",
|
|
3346
|
+
className: M("h-12 shrink-0 gap-[7px] whitespace-nowrap !rounded-lg px-[18px]", Wr.filterBtn, f && Wr.filterBtnActive, p && Wr.filterBtnOpen)
|
|
3298
3347
|
})
|
|
3299
3348
|
});
|
|
3300
|
-
},
|
|
3349
|
+
}, Jr = {
|
|
3301
3350
|
section: "_section_mh952_1",
|
|
3302
3351
|
divider: "_divider_mh952_5"
|
|
3303
|
-
},
|
|
3304
|
-
let w = a?.typography?.titleClassName ?? "dial-body-semi-text", T = a?.typography?.countClassName ?? "dial-tiny-semi-text", E =
|
|
3352
|
+
}, Yr = ({ totalCount: e, viewMode: t, onViewModeChange: n, title: r = "Browse", browseHeaderRenderer: i, styles: a, query: o, onQueryChange: s, searchPlaceholder: c, gridViewLabel: l = "Grid view", listViewLabel: u = "List view", viewToggleLabel: d = "View mode", sortKey: f, sortOptions: p, onSortChange: m, sortLabel: h = "Sort", filters: g, onFiltersChange: _, filterValues: v, isMyAppsActive: y, onMyAppsChange: b, filterFromLabel: x, filterMyAppsLabel: S, filterTopicsLabel: C }) => {
|
|
3353
|
+
let w = a?.typography?.titleClassName ?? "dial-body-semi-text", T = a?.typography?.countClassName ?? "dial-tiny-semi-text", E = I(() => [{
|
|
3305
3354
|
value: X.Grid,
|
|
3306
|
-
icon: /* @__PURE__ */ G(
|
|
3307
|
-
size:
|
|
3355
|
+
icon: /* @__PURE__ */ G(nt, {
|
|
3356
|
+
size: z.SM,
|
|
3308
3357
|
"aria-hidden": !0,
|
|
3309
|
-
stroke:
|
|
3358
|
+
stroke: B
|
|
3310
3359
|
}),
|
|
3311
3360
|
"aria-label": l
|
|
3312
3361
|
}, {
|
|
3313
3362
|
value: X.Cards,
|
|
3314
|
-
icon: /* @__PURE__ */ G(
|
|
3315
|
-
size:
|
|
3363
|
+
icon: /* @__PURE__ */ G(rt, {
|
|
3364
|
+
size: z.SM,
|
|
3316
3365
|
"aria-hidden": !0,
|
|
3317
|
-
stroke:
|
|
3366
|
+
stroke: B
|
|
3318
3367
|
}),
|
|
3319
3368
|
"aria-label": u
|
|
3320
3369
|
}], [l, u]), D = (e) => {
|
|
3321
3370
|
s(e ?? "");
|
|
3322
|
-
}, O = p?.find((e) => e.value === f)?.label ?? h, k =
|
|
3371
|
+
}, O = p?.find((e) => e.value === f)?.label ?? h, k = I(() => (p ?? []).map((e) => ({
|
|
3323
3372
|
key: e.value,
|
|
3324
3373
|
label: e.label,
|
|
3325
|
-
mark:
|
|
3374
|
+
mark: ke.Check,
|
|
3326
3375
|
checked: e.value === f,
|
|
3327
3376
|
onClick: () => m?.(e.value)
|
|
3328
3377
|
})), [
|
|
@@ -3347,16 +3396,16 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3347
3396
|
}
|
|
3348
3397
|
}), /* @__PURE__ */ K("div", {
|
|
3349
3398
|
className: "ms-auto flex shrink-0 items-center gap-2",
|
|
3350
|
-
children: [/* @__PURE__ */ G(
|
|
3399
|
+
children: [/* @__PURE__ */ G(Pe, {
|
|
3351
3400
|
"aria-label": d,
|
|
3352
3401
|
value: t,
|
|
3353
3402
|
onChange: n,
|
|
3354
3403
|
items: E
|
|
3355
|
-
}), p != null && p.length > 0 && /* @__PURE__ */ K(gt, { children: [/* @__PURE__ */ G("div", { className: M("h-4 w-px shrink-0",
|
|
3404
|
+
}), p != null && p.length > 0 && /* @__PURE__ */ K(gt, { children: [/* @__PURE__ */ G("div", { className: M("h-4 w-px shrink-0", Jr.divider) }), /* @__PURE__ */ G(de, {
|
|
3356
3405
|
items: k,
|
|
3357
3406
|
label: O,
|
|
3358
|
-
variant:
|
|
3359
|
-
appearance:
|
|
3407
|
+
variant: fe.Primary,
|
|
3408
|
+
appearance: ue.Ghost
|
|
3360
3409
|
})] })]
|
|
3361
3410
|
})]
|
|
3362
3411
|
}), /* @__PURE__ */ K("div", {
|
|
@@ -3364,15 +3413,15 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3364
3413
|
children: [/* @__PURE__ */ G("div", {
|
|
3365
3414
|
role: "search",
|
|
3366
3415
|
className: "flex-1",
|
|
3367
|
-
children: /* @__PURE__ */ G(
|
|
3416
|
+
children: /* @__PURE__ */ G(Ne, {
|
|
3368
3417
|
value: o,
|
|
3369
3418
|
onChange: D,
|
|
3370
|
-
size:
|
|
3419
|
+
size: ye.Large,
|
|
3371
3420
|
wrapperClassName: "dial-kit-input-large",
|
|
3372
3421
|
placeholder: c,
|
|
3373
3422
|
"aria-label": c
|
|
3374
3423
|
})
|
|
3375
|
-
}), /* @__PURE__ */ G(
|
|
3424
|
+
}), /* @__PURE__ */ G(qr, {
|
|
3376
3425
|
checked: g ?? /* @__PURE__ */ new Set(),
|
|
3377
3426
|
onChange: _ ?? (() => void 0),
|
|
3378
3427
|
values: v,
|
|
@@ -3385,12 +3434,12 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3385
3434
|
})]
|
|
3386
3435
|
})]
|
|
3387
3436
|
});
|
|
3388
|
-
},
|
|
3437
|
+
}, Xr = ({ query: e, onQueryChange: t, searchPlaceholder: n = "Search models, tools, agents…", styles: r, filters: i, onFiltersChange: a, filterValues: o, isMyAppsActive: s, onMyAppsChange: c, filterFromLabel: l, filterMyAppsLabel: u, filterTopicsLabel: d, gridViewLabel: f, listViewLabel: p, viewToggleLabel: m, sortKey: h, sortOptions: g, onSortChange: _, sortLabel: v, ...y }) => {
|
|
3389
3438
|
let b = { "--cat-browse-divider": r?.colors?.divider };
|
|
3390
3439
|
return /* @__PURE__ */ G("section", {
|
|
3391
|
-
className: M("flex-shrink-0 px-4",
|
|
3440
|
+
className: M("flex-shrink-0 px-4", Jr.section, Et.toolbar),
|
|
3392
3441
|
style: b,
|
|
3393
|
-
children: /* @__PURE__ */ G(
|
|
3442
|
+
children: /* @__PURE__ */ G(Yr, {
|
|
3394
3443
|
styles: r,
|
|
3395
3444
|
query: e,
|
|
3396
3445
|
onQueryChange: t,
|
|
@@ -3413,26 +3462,26 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3413
3462
|
...y
|
|
3414
3463
|
})
|
|
3415
3464
|
});
|
|
3416
|
-
},
|
|
3465
|
+
}, Zr = {
|
|
3417
3466
|
root: "_root_1h83l_1",
|
|
3418
3467
|
heading: "_heading_1h83l_5",
|
|
3419
3468
|
headingTitle: "_headingTitle_1h83l_9"
|
|
3420
|
-
},
|
|
3469
|
+
}, Qr = "w-[320px]", $r = (e, t) => e.map((e) => ({
|
|
3421
3470
|
...e,
|
|
3422
|
-
label: typeof e.label == "string" ? /* @__PURE__ */ G(
|
|
3471
|
+
label: typeof e.label == "string" ? /* @__PURE__ */ G(Ce, {
|
|
3423
3472
|
text: e.label,
|
|
3424
3473
|
query: t,
|
|
3425
3474
|
maxLines: 1
|
|
3426
3475
|
}) : e.label,
|
|
3427
|
-
children: e.children ?
|
|
3428
|
-
})),
|
|
3429
|
-
let s =
|
|
3476
|
+
children: e.children ? $r(e.children, t) : void 0
|
|
3477
|
+
})), ei = ({ label: e, options: t, onClick: n, search: r, searchPlaceholder: i = "Search", searchClearLabel: a = "Clear search", noResultsLabel: o = "No results found" }) => {
|
|
3478
|
+
let s = L(null), [c, l] = R(!1);
|
|
3430
3479
|
return r ? /* @__PURE__ */ G("div", {
|
|
3431
3480
|
ref: s,
|
|
3432
|
-
children: /* @__PURE__ */ G(
|
|
3433
|
-
items: t?.length ?
|
|
3481
|
+
children: /* @__PURE__ */ G(_e, {
|
|
3482
|
+
items: t?.length ? $r(t, r.value) : [{
|
|
3434
3483
|
key: "no-results",
|
|
3435
|
-
type:
|
|
3484
|
+
type: ve.PlainText,
|
|
3436
3485
|
label: /* @__PURE__ */ G("span", {
|
|
3437
3486
|
role: "status",
|
|
3438
3487
|
children: o
|
|
@@ -3441,28 +3490,28 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3441
3490
|
maxDropdownHeight: 344,
|
|
3442
3491
|
placement: "bottom-end",
|
|
3443
3492
|
matchReferenceWidth: !1,
|
|
3444
|
-
listClassName:
|
|
3493
|
+
listClassName: Qr,
|
|
3445
3494
|
menuHeader: /* @__PURE__ */ G("div", {
|
|
3446
3495
|
className: "sticky -top-1 z-10 bg-layer-raised px-2 pb-1 pt-2",
|
|
3447
|
-
children: /* @__PURE__ */ G(
|
|
3496
|
+
children: /* @__PURE__ */ G(Ne, {
|
|
3448
3497
|
value: r.value,
|
|
3449
3498
|
placeholder: i,
|
|
3450
3499
|
"aria-label": i,
|
|
3451
3500
|
clearLabel: a,
|
|
3452
|
-
size:
|
|
3501
|
+
size: ye.Small,
|
|
3453
3502
|
onChange: (e) => r.onChange(e ?? "")
|
|
3454
3503
|
})
|
|
3455
3504
|
}),
|
|
3456
3505
|
onOpenChange: (e) => {
|
|
3457
3506
|
l(e), e || r.onChange("");
|
|
3458
3507
|
},
|
|
3459
|
-
children: /* @__PURE__ */ G(
|
|
3508
|
+
children: /* @__PURE__ */ G(le, {
|
|
3460
3509
|
label: e,
|
|
3461
|
-
variant:
|
|
3462
|
-
appearance:
|
|
3463
|
-
iconAfter: /* @__PURE__ */ G(
|
|
3464
|
-
size:
|
|
3465
|
-
stroke:
|
|
3510
|
+
variant: fe.Primary,
|
|
3511
|
+
appearance: ue.Solid,
|
|
3512
|
+
iconAfter: /* @__PURE__ */ G(qe, {
|
|
3513
|
+
size: z.SM,
|
|
3514
|
+
stroke: B,
|
|
3466
3515
|
"aria-hidden": !0,
|
|
3467
3516
|
className: M("transition-transform", c && "rotate-180")
|
|
3468
3517
|
}),
|
|
@@ -3472,22 +3521,22 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3472
3521
|
})
|
|
3473
3522
|
}) : t?.length ? /* @__PURE__ */ G("div", {
|
|
3474
3523
|
ref: s,
|
|
3475
|
-
children: /* @__PURE__ */ G(
|
|
3476
|
-
appearance:
|
|
3524
|
+
children: /* @__PURE__ */ G(de, {
|
|
3525
|
+
appearance: ue.Solid,
|
|
3477
3526
|
label: e,
|
|
3478
|
-
variant:
|
|
3527
|
+
variant: fe.Primary,
|
|
3479
3528
|
items: t
|
|
3480
3529
|
})
|
|
3481
|
-
}) : /* @__PURE__ */ G(
|
|
3530
|
+
}) : /* @__PURE__ */ G(Ae, {
|
|
3482
3531
|
label: e,
|
|
3483
|
-
iconBefore: /* @__PURE__ */ G(
|
|
3484
|
-
size:
|
|
3485
|
-
stroke:
|
|
3532
|
+
iconBefore: /* @__PURE__ */ G(ct, {
|
|
3533
|
+
size: z.SM,
|
|
3534
|
+
stroke: B
|
|
3486
3535
|
}),
|
|
3487
3536
|
onClick: n
|
|
3488
3537
|
});
|
|
3489
|
-
},
|
|
3490
|
-
let { typography:
|
|
3538
|
+
}, ti = 3, ni = 300, ri = ({ items: e, tabs: t, topicOptions: n, favorites: o, titles: c, browseHeaderRenderer: d, onToggleFavorite: p, isFavoriteVisible: m, columnVisibility: g, onUseInChat: v, isPrimaryActionVisible: y, onShare: b, isPublishVisible: x, isPublishPrimary: S, getPublishHistory: C, publishFolderItems: w, publishExpandedPaths: T, onPublishExpandedPathsChange: E, publishLoadingPaths: D, hasPublishWriteAccess: O, publishDefaultAuthor: ee, onPublish: k, onPublishSuccess: A, onPublishError: te, onCreatePublishFolder: ne, publishLabels: re, ruleSourceOptions: j, onFetchExistingRules: ie, shareOverlay: N, isShareVisible: oe, isSharePrimary: se, onFetchDetails: ce, renderCredentials: le, onEdit: ue, onDownload: de, isDownloadVisible: fe, isDownloadPrimary: pe, onLoadContentFile: me, onLoadContentFilePreview: he, renderContentFilePreview: z, renderContentFileTree: B, onDelete: ge, onUnshare: _e, isUnshareVisible: ve, onRevokeShare: ye, onFetchRecipientsCount: be, isRevokeShareVisible: xe, onUnpublish: Se, isUnpublishVisible: V, onLogin: Ce, onLogout: we, onCreateClick: Te, createOptions: Ee, createSearch: De, hideCreateButton: Oe = !1, hidePageTitle: ke = !1, isReadonly: H = !1, initialViewMode: U = X.Grid, isFullWidth: Ae = !1, selectedItemId: je, onCardClick: Me, isLoading: Ne, styles: Pe, detailsTexts: Fe, detailsLimitsFooterNote: Ie, initialDetailsItemId: Le, sortKey: Be, onSortChange: Ve, filterTopics: He, onFilterTopicsChange: Ue, isMyAppsActive: We, onMyAppsActiveChange: Ge, activeTab: Ke, onActiveTabChange: qe, renderEmptyState: Je }) => {
|
|
3539
|
+
let { typography: Ye } = Pe ?? {}, Xe = Ot(Pe), Ze = c?.pageTitle ?? "Catalog", Qe = c?.createLabel ?? "Create", $e = c?.favoritesTitle ?? "Your favorites", et = c?.browseTitle ?? "Browse", tt = c?.searchPlaceholder ?? "Search models, tools, agents…", nt = c?.noResultsTitle ?? ((e) => `No results for "${e}"`), rt = c?.featuredLabel ?? "Featured", it = c?.gridViewLabel ?? "Grid view", at = c?.listViewLabel ?? "List view", ot = c?.viewToggleLabel ?? "View mode", st = c?.ariaLabel ?? "Catalog", ct = c?.sortLabel ?? "Sort", lt = [
|
|
3491
3540
|
{
|
|
3492
3541
|
value: s.RecentlyUpdated,
|
|
3493
3542
|
label: c?.sortRecentlyUpdatedLabel ?? "Recently Updated"
|
|
@@ -3500,94 +3549,94 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3500
3549
|
value: s.NameAZ,
|
|
3501
3550
|
label: c?.sortNameAZLabel ?? "Name A-Z"
|
|
3502
3551
|
}
|
|
3503
|
-
], [
|
|
3552
|
+
], [ut, dt] = R(""), [W, ft] = R(U), [pt, mt] = R(U === X.Cards ? "shown" : "unmounted"), [ht, _t] = R(s.RecentlyUpdated), [vt, yt] = R(/* @__PURE__ */ new Set()), [bt, xt] = R(!1), q = Be ?? ht, J = He ?? vt, St = We ?? bt, Y = P((e) => {
|
|
3504
3553
|
let t = e;
|
|
3505
|
-
_t(t),
|
|
3506
|
-
}, [
|
|
3507
|
-
yt(e),
|
|
3508
|
-
}, [
|
|
3509
|
-
xt(e),
|
|
3510
|
-
}, [
|
|
3554
|
+
_t(t), Ve?.(t);
|
|
3555
|
+
}, [Ve]), Ct = P((e) => {
|
|
3556
|
+
yt(e), Ue?.(e);
|
|
3557
|
+
}, [Ue]), wt = P((e) => {
|
|
3558
|
+
xt(e), Ge?.(e);
|
|
3559
|
+
}, [Ge]), Z = I(() => e.filter((e) => !e.isHidden), [e]), Q = I(() => o.filter((e) => !e.isHidden), [o]), Tt = I(() => n ?? u(Z), [n, Z]), kt = I(() => t ?? r(Z, c?.tabLabels), [
|
|
3511
3560
|
t,
|
|
3512
3561
|
Z,
|
|
3513
3562
|
c?.tabLabels
|
|
3514
|
-
]),
|
|
3515
|
-
|
|
3516
|
-
|
|
3517
|
-
}, [
|
|
3518
|
-
let
|
|
3519
|
-
|
|
3520
|
-
}, [
|
|
3521
|
-
|
|
3522
|
-
Q.length > 0 && !
|
|
3523
|
-
}, [Q.length,
|
|
3524
|
-
let
|
|
3525
|
-
|
|
3526
|
-
}, []),
|
|
3527
|
-
|
|
3528
|
-
let t = ++
|
|
3529
|
-
if (
|
|
3530
|
-
|
|
3563
|
+
]), At = kt[0]?.id ?? "", [jt, Mt] = R(At);
|
|
3564
|
+
F(() => {
|
|
3565
|
+
Mt((e) => e || At);
|
|
3566
|
+
}, [At]);
|
|
3567
|
+
let Nt = Ke ?? jt, Pt = P((e) => {
|
|
3568
|
+
Mt(e), qe?.(e);
|
|
3569
|
+
}, [qe]), [Ft, It] = R(Q.length > 0);
|
|
3570
|
+
F(() => {
|
|
3571
|
+
Q.length > 0 && !Ft && It(!0);
|
|
3572
|
+
}, [Q.length, Ft]);
|
|
3573
|
+
let Lt = P(() => {
|
|
3574
|
+
It(!1);
|
|
3575
|
+
}, []), Rt = Ft && Q.length === 0, [zt, Bt] = R(null), [Vt, Ht] = R(!1), [Ut, Wt] = R(void 0), [Gt, Kt] = R(!1), qt = L(null), Jt = L(0), Yt = P(async (e) => {
|
|
3576
|
+
qt.current = e.id;
|
|
3577
|
+
let t = ++Jt.current;
|
|
3578
|
+
if (ce) {
|
|
3579
|
+
Kt(!0);
|
|
3531
3580
|
try {
|
|
3532
|
-
let n = await
|
|
3533
|
-
return
|
|
3581
|
+
let n = await ce(e);
|
|
3582
|
+
return Jt.current === t && Wt(n), n;
|
|
3534
3583
|
} finally {
|
|
3535
|
-
|
|
3584
|
+
Jt.current === t && Kt(!1);
|
|
3536
3585
|
}
|
|
3537
3586
|
}
|
|
3538
|
-
}, [
|
|
3539
|
-
for (let n = 0; n <
|
|
3540
|
-
if (
|
|
3541
|
-
n <
|
|
3587
|
+
}, [ce]), Xt = P(async (e) => (Bt(e), Wt(void 0), Yt(e)), [Yt]), Zt = P(async (e, t) => {
|
|
3588
|
+
for (let n = 0; n < ti; n++) {
|
|
3589
|
+
if (qt.current !== e.id || t(await Yt(e))) return;
|
|
3590
|
+
n < ti - 1 && await h(ni);
|
|
3542
3591
|
}
|
|
3543
|
-
}, [
|
|
3544
|
-
|
|
3545
|
-
if (!
|
|
3546
|
-
|
|
3592
|
+
}, [Yt]), Qt = L(null);
|
|
3593
|
+
F(() => {
|
|
3594
|
+
if (!Le) {
|
|
3595
|
+
Qt.current = null;
|
|
3547
3596
|
return;
|
|
3548
3597
|
}
|
|
3549
|
-
if (
|
|
3550
|
-
let t = e.find((e) => e.id ===
|
|
3551
|
-
t && (
|
|
3598
|
+
if (Qt.current === Le) return;
|
|
3599
|
+
let t = e.find((e) => e.id === Le);
|
|
3600
|
+
t && (Qt.current = Le, Xt(t));
|
|
3552
3601
|
}, [
|
|
3553
|
-
|
|
3602
|
+
Le,
|
|
3554
3603
|
e,
|
|
3555
|
-
Yt
|
|
3556
|
-
]), P(() => {
|
|
3557
|
-
if (Rt == null) return;
|
|
3558
|
-
let t = e.find((e) => e.id === Rt.id);
|
|
3559
|
-
t && t !== Rt && zt(t);
|
|
3560
|
-
}, [e, Rt]);
|
|
3561
|
-
let $t = N(async (e, t) => {
|
|
3562
|
-
await we?.(e, t), le && await Xt(e, (e) => f(e?.credentials, t.level));
|
|
3563
|
-
}, [
|
|
3564
|
-
we,
|
|
3565
|
-
le,
|
|
3566
3604
|
Xt
|
|
3567
|
-
]),
|
|
3568
|
-
|
|
3605
|
+
]), F(() => {
|
|
3606
|
+
if (zt == null) return;
|
|
3607
|
+
let t = e.find((e) => e.id === zt.id);
|
|
3608
|
+
t && t !== zt && Bt(t);
|
|
3609
|
+
}, [e, zt]);
|
|
3610
|
+
let en = P(async (e, t) => {
|
|
3611
|
+
await Ce?.(e, t), ce && await Zt(e, (e) => f(e?.credentials, t.level));
|
|
3569
3612
|
}, [
|
|
3570
|
-
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
]), tn =
|
|
3574
|
-
|
|
3575
|
-
|
|
3613
|
+
Ce,
|
|
3614
|
+
ce,
|
|
3615
|
+
Zt
|
|
3616
|
+
]), tn = P(async (e, t) => {
|
|
3617
|
+
await we?.(e, t), ce && await Zt(e, (e) => !f(e?.credentials, t.level));
|
|
3618
|
+
}, [
|
|
3619
|
+
we,
|
|
3620
|
+
ce,
|
|
3621
|
+
Zt
|
|
3622
|
+
]), nn = P(() => {
|
|
3623
|
+
Ht(!1), qt.current = null, Jt.current += 1, setTimeout(() => {
|
|
3624
|
+
Bt(null), Wt(void 0), Kt(!1);
|
|
3576
3625
|
}, 300);
|
|
3577
|
-
}, []),
|
|
3578
|
-
if (
|
|
3579
|
-
if (
|
|
3580
|
-
let { credentials: e, ...t } =
|
|
3626
|
+
}, []), rn = I(() => {
|
|
3627
|
+
if (zt == null) return null;
|
|
3628
|
+
if (Ut == null) return zt;
|
|
3629
|
+
let { credentials: e, ...t } = Ut;
|
|
3581
3630
|
return {
|
|
3582
|
-
...
|
|
3631
|
+
...zt,
|
|
3583
3632
|
details: t,
|
|
3584
|
-
credentials: e ??
|
|
3633
|
+
credentials: e ?? zt.credentials
|
|
3585
3634
|
};
|
|
3586
|
-
}, [
|
|
3587
|
-
|
|
3588
|
-
if (pt !== "unmounted" ||
|
|
3635
|
+
}, [zt, Ut]), an = I(() => l(Z, q), [Z, q]), on = I(() => a(an, ut), [an, ut]), sn = I(() => J.size > 0 ? i(on, J) : on, [on, J]), cn = I(() => St ? _(sn) : sn, [sn, St]), ln = I(() => Nt ? cn.filter((e) => e.type === Nt) : cn, [cn, Nt]);
|
|
3636
|
+
F(() => {
|
|
3637
|
+
if (pt !== "unmounted" || Ne || ln.length === 0) return;
|
|
3589
3638
|
let e = () => {
|
|
3590
|
-
|
|
3639
|
+
ae(() => {
|
|
3591
3640
|
mt((e) => e === "unmounted" ? "prepared" : e);
|
|
3592
3641
|
});
|
|
3593
3642
|
};
|
|
@@ -3599,51 +3648,63 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3599
3648
|
return () => window.clearTimeout(t);
|
|
3600
3649
|
}, [
|
|
3601
3650
|
pt,
|
|
3602
|
-
|
|
3603
|
-
|
|
3651
|
+
Ne,
|
|
3652
|
+
ln.length
|
|
3604
3653
|
]);
|
|
3605
|
-
let
|
|
3606
|
-
|
|
3607
|
-
if (
|
|
3608
|
-
let e = requestAnimationFrame(() =>
|
|
3654
|
+
let un = zt != null && Q.some((e) => e.id === zt.id);
|
|
3655
|
+
F(() => {
|
|
3656
|
+
if (zt == null) return;
|
|
3657
|
+
let e = requestAnimationFrame(() => Ht(!0));
|
|
3609
3658
|
return () => cancelAnimationFrame(e);
|
|
3610
|
-
}, [
|
|
3611
|
-
let
|
|
3659
|
+
}, [zt]);
|
|
3660
|
+
let dn = P((e) => {
|
|
3612
3661
|
e === X.Cards && mt("shown"), ft(e);
|
|
3613
|
-
}, []),
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3662
|
+
}, []), fn = !Oe && !H, pn = Ft && !H, mn = ut ? nt(ut) : "No items", { copyCodeAriaLabel: hn, copiedCodeStatusLabel: gn, downloadCodeAriaLabel: _n, tableScrollRegionAriaLabel: vn, mathScrollRegionAriaLabel: yn } = Fe ?? {}, bn = I(() => Dt({
|
|
3663
|
+
copyCodeAriaLabel: hn,
|
|
3664
|
+
copiedCodeStatusLabel: gn,
|
|
3665
|
+
downloadCodeAriaLabel: _n,
|
|
3666
|
+
tableScrollRegionAriaLabel: vn,
|
|
3667
|
+
mathScrollRegionAriaLabel: yn
|
|
3668
|
+
}), [
|
|
3669
|
+
hn,
|
|
3670
|
+
gn,
|
|
3671
|
+
_n,
|
|
3672
|
+
vn,
|
|
3673
|
+
yn
|
|
3674
|
+
]), xn = I(() => ({
|
|
3675
|
+
noResultsTitle: mn,
|
|
3676
|
+
featuredLabel: rt,
|
|
3677
|
+
credentialsBadgeLoggedOutLabel: Fe?.credentialsBadgeLoggedOutLabel
|
|
3617
3678
|
}), [
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
]),
|
|
3622
|
-
query:
|
|
3623
|
-
activeTab:
|
|
3679
|
+
mn,
|
|
3680
|
+
rt,
|
|
3681
|
+
Fe?.credentialsBadgeLoggedOutLabel
|
|
3682
|
+
]), Sn = !Ne && ln.length === 0 ? Je?.({
|
|
3683
|
+
query: ut,
|
|
3684
|
+
activeTab: Nt,
|
|
3624
3685
|
hasTopicFilters: J.size > 0,
|
|
3625
3686
|
isMyAppsActive: St
|
|
3626
3687
|
}) : void 0;
|
|
3627
|
-
return
|
|
3688
|
+
return Ne ? /* @__PURE__ */ G("div", {
|
|
3628
3689
|
className: "flex size-full min-h-0 flex-1 items-center justify-center",
|
|
3629
|
-
children: /* @__PURE__ */ G(
|
|
3690
|
+
children: /* @__PURE__ */ G(Re, {})
|
|
3630
3691
|
}) : /* @__PURE__ */ K("section", {
|
|
3631
|
-
"aria-label":
|
|
3632
|
-
className: M("flex size-full min-h-0 flex-1 flex-col",
|
|
3633
|
-
style:
|
|
3692
|
+
"aria-label": st,
|
|
3693
|
+
className: M("flex size-full min-h-0 flex-1 flex-col", Zr.root, Et.root),
|
|
3694
|
+
style: Xe,
|
|
3634
3695
|
children: [
|
|
3635
|
-
(!
|
|
3636
|
-
className: M("shrink-0",
|
|
3696
|
+
(!ke || fn) && /* @__PURE__ */ G("div", {
|
|
3697
|
+
className: M("shrink-0", Zr.heading),
|
|
3637
3698
|
children: /* @__PURE__ */ K("div", {
|
|
3638
3699
|
className: "flex h-[64px] w-full items-center justify-between px-8",
|
|
3639
|
-
children: [!
|
|
3640
|
-
className: M(
|
|
3641
|
-
children:
|
|
3642
|
-
}),
|
|
3643
|
-
label:
|
|
3644
|
-
options:
|
|
3645
|
-
onClick:
|
|
3646
|
-
search:
|
|
3700
|
+
children: [!ke && /* @__PURE__ */ G("h1", {
|
|
3701
|
+
className: M(Ye?.pageHeadingFontClassName ?? "dial-display2-text", Zr.headingTitle),
|
|
3702
|
+
children: Ze
|
|
3703
|
+
}), fn && /* @__PURE__ */ G(ei, {
|
|
3704
|
+
label: Qe,
|
|
3705
|
+
options: Ee,
|
|
3706
|
+
onClick: Te,
|
|
3707
|
+
search: De,
|
|
3647
3708
|
searchPlaceholder: c?.createSearchPlaceholder,
|
|
3648
3709
|
searchClearLabel: c?.createSearchClearLabel,
|
|
3649
3710
|
noResultsLabel: c?.createNoResultsLabel
|
|
@@ -3653,39 +3714,39 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3653
3714
|
/* @__PURE__ */ K("div", {
|
|
3654
3715
|
className: "flex min-h-0 min-w-0 flex-1 flex-col overflow-y-auto overflow-x-hidden",
|
|
3655
3716
|
children: [
|
|
3656
|
-
|
|
3717
|
+
pn && /* @__PURE__ */ G("div", {
|
|
3657
3718
|
className: "w-full px-8",
|
|
3658
|
-
children: /* @__PURE__ */ G(
|
|
3719
|
+
children: /* @__PURE__ */ G(Or, {
|
|
3659
3720
|
items: Q,
|
|
3660
3721
|
totalCount: Q.length,
|
|
3661
|
-
title:
|
|
3722
|
+
title: $e,
|
|
3662
3723
|
onToggleFavorite: p,
|
|
3663
3724
|
isFavoriteVisible: m,
|
|
3664
|
-
onItemClick:
|
|
3665
|
-
isLeaving:
|
|
3666
|
-
onExitComplete:
|
|
3667
|
-
selectedItemId:
|
|
3668
|
-
credentialsBadgeLoggedOutLabel:
|
|
3725
|
+
onItemClick: Me ?? Xt,
|
|
3726
|
+
isLeaving: Rt,
|
|
3727
|
+
onExitComplete: Lt,
|
|
3728
|
+
selectedItemId: je,
|
|
3729
|
+
credentialsBadgeLoggedOutLabel: Fe?.credentialsBadgeLoggedOutLabel
|
|
3669
3730
|
})
|
|
3670
3731
|
}),
|
|
3671
3732
|
/* @__PURE__ */ G("div", {
|
|
3672
3733
|
className: "w-full px-4 pt-6",
|
|
3673
|
-
children: /* @__PURE__ */ G(
|
|
3674
|
-
totalCount:
|
|
3734
|
+
children: /* @__PURE__ */ G(Xr, {
|
|
3735
|
+
totalCount: cn.length,
|
|
3675
3736
|
viewMode: W,
|
|
3676
|
-
onViewModeChange:
|
|
3737
|
+
onViewModeChange: dn,
|
|
3677
3738
|
sortKey: q,
|
|
3678
|
-
query:
|
|
3739
|
+
query: ut,
|
|
3679
3740
|
onQueryChange: dt,
|
|
3680
|
-
title:
|
|
3741
|
+
title: et,
|
|
3681
3742
|
browseHeaderRenderer: d,
|
|
3682
|
-
searchPlaceholder:
|
|
3683
|
-
gridViewLabel:
|
|
3684
|
-
listViewLabel:
|
|
3685
|
-
viewToggleLabel:
|
|
3686
|
-
sortOptions:
|
|
3743
|
+
searchPlaceholder: tt,
|
|
3744
|
+
gridViewLabel: it,
|
|
3745
|
+
listViewLabel: at,
|
|
3746
|
+
viewToggleLabel: ot,
|
|
3747
|
+
sortOptions: lt,
|
|
3687
3748
|
onSortChange: Y,
|
|
3688
|
-
sortLabel:
|
|
3749
|
+
sortLabel: ct,
|
|
3689
3750
|
filters: J,
|
|
3690
3751
|
onFiltersChange: Ct,
|
|
3691
3752
|
filterValues: Tt,
|
|
@@ -3696,65 +3757,66 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3696
3757
|
filterTopicsLabel: c?.filterTopicsLabel
|
|
3697
3758
|
})
|
|
3698
3759
|
}),
|
|
3699
|
-
|
|
3760
|
+
kt.length > 1 && /* @__PURE__ */ G("div", {
|
|
3700
3761
|
className: "min-w-0 shrink-0 overflow-x-auto px-8",
|
|
3701
|
-
children: /* @__PURE__ */ G(
|
|
3702
|
-
tabs:
|
|
3762
|
+
children: /* @__PURE__ */ G(ze, {
|
|
3763
|
+
tabs: kt.map((e) => ({
|
|
3703
3764
|
id: e.id,
|
|
3704
3765
|
label: typeof e.label == "string" ? e.label : String(e.label),
|
|
3705
|
-
count:
|
|
3766
|
+
count: cn.filter((t) => t.type === e.id).length
|
|
3706
3767
|
})),
|
|
3707
|
-
activeTabId:
|
|
3708
|
-
onTabChange:
|
|
3768
|
+
activeTabId: Nt,
|
|
3769
|
+
onTabChange: Pt
|
|
3709
3770
|
})
|
|
3710
3771
|
}),
|
|
3711
3772
|
/* @__PURE__ */ G("div", {
|
|
3712
|
-
className: M(
|
|
3713
|
-
children:
|
|
3773
|
+
className: M(ln.length > 0 ? ["min-h-full w-full px-8 py-6", !Ae && "mx-auto max-w-[1180px]"] : "min-h-[180px] flex-1", ln.length === 0 && "px-8 py-6"),
|
|
3774
|
+
children: Sn ?? /* @__PURE__ */ K(gt, { children: [/* @__PURE__ */ G("div", {
|
|
3714
3775
|
inert: W !== X.Grid,
|
|
3715
|
-
className: M(
|
|
3716
|
-
children: /* @__PURE__ */ G(
|
|
3717
|
-
items:
|
|
3718
|
-
query:
|
|
3776
|
+
className: M(ln.length > 0 ? "pb-8" : "size-full flex-1", W !== X.Grid && "hidden"),
|
|
3777
|
+
children: /* @__PURE__ */ G($t, {
|
|
3778
|
+
items: ln,
|
|
3779
|
+
query: ut,
|
|
3719
3780
|
onToggleFavorite: p,
|
|
3720
3781
|
isFavoriteVisible: m,
|
|
3721
|
-
onItemClick:
|
|
3722
|
-
titles:
|
|
3723
|
-
selectedItemId:
|
|
3724
|
-
isReadonly:
|
|
3725
|
-
isFullWidth:
|
|
3726
|
-
featuredChipStyle:
|
|
3782
|
+
onItemClick: Me ?? Xt,
|
|
3783
|
+
titles: xn,
|
|
3784
|
+
selectedItemId: je,
|
|
3785
|
+
isReadonly: H,
|
|
3786
|
+
isFullWidth: Ae,
|
|
3787
|
+
featuredChipStyle: Pe?.colors?.featuredChipStyle,
|
|
3788
|
+
markdownLabels: bn
|
|
3727
3789
|
})
|
|
3728
3790
|
}), pt !== "unmounted" && /* @__PURE__ */ G("div", {
|
|
3729
3791
|
inert: W !== X.Cards,
|
|
3730
|
-
className: M("pb-8", W !== X.Cards && (pt === "prepared" ? "invisible h-0 overflow-hidden p-0" : "hidden"),
|
|
3731
|
-
children: /* @__PURE__ */ G(
|
|
3732
|
-
type:
|
|
3733
|
-
items:
|
|
3734
|
-
query:
|
|
3735
|
-
ariaLabel:
|
|
3736
|
-
emptyStateTitle:
|
|
3792
|
+
className: M("pb-8", W !== X.Cards && (pt === "prepared" ? "invisible h-0 overflow-hidden p-0" : "hidden"), ln.length === 0 && W === X.Cards && "h-full"),
|
|
3793
|
+
children: /* @__PURE__ */ G(Hr, {
|
|
3794
|
+
type: Nt,
|
|
3795
|
+
items: ln,
|
|
3796
|
+
query: ut,
|
|
3797
|
+
ariaLabel: st,
|
|
3798
|
+
emptyStateTitle: mn,
|
|
3737
3799
|
onToggleFavorite: p,
|
|
3738
3800
|
isFavoriteVisible: m,
|
|
3739
3801
|
columnVisibility: g,
|
|
3740
|
-
onItemClick:
|
|
3802
|
+
onItemClick: Me ?? Xt,
|
|
3741
3803
|
stickyHeaderTop: 0,
|
|
3742
|
-
selectedItemId:
|
|
3743
|
-
credentialsBadgeLoggedOutLabel:
|
|
3744
|
-
isReadonly:
|
|
3804
|
+
selectedItemId: je,
|
|
3805
|
+
credentialsBadgeLoggedOutLabel: Fe?.credentialsBadgeLoggedOutLabel,
|
|
3806
|
+
isReadonly: H
|
|
3745
3807
|
})
|
|
3746
3808
|
})] })
|
|
3747
3809
|
})
|
|
3748
3810
|
]
|
|
3749
3811
|
}),
|
|
3750
|
-
|
|
3751
|
-
renderCredentials:
|
|
3752
|
-
item:
|
|
3753
|
-
isOpen:
|
|
3754
|
-
isStarred:
|
|
3755
|
-
isDetailsLoading:
|
|
3756
|
-
isReadonly:
|
|
3757
|
-
onClose:
|
|
3812
|
+
rn != null && /* @__PURE__ */ G(Cr, {
|
|
3813
|
+
renderCredentials: le,
|
|
3814
|
+
item: rn,
|
|
3815
|
+
isOpen: Vt,
|
|
3816
|
+
isStarred: un,
|
|
3817
|
+
isDetailsLoading: Gt,
|
|
3818
|
+
isReadonly: H,
|
|
3819
|
+
onClose: nn,
|
|
3758
3820
|
onToggleFavorite: p,
|
|
3759
3821
|
isFavoriteVisible: m,
|
|
3760
3822
|
onUseInChat: v,
|
|
@@ -3776,37 +3838,37 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3776
3838
|
publishLabels: re,
|
|
3777
3839
|
ruleSourceOptions: j,
|
|
3778
3840
|
onFetchExistingRules: ie,
|
|
3779
|
-
shareOverlay:
|
|
3780
|
-
isShareVisible:
|
|
3781
|
-
isSharePrimary:
|
|
3782
|
-
onEdit:
|
|
3783
|
-
onDownload:
|
|
3784
|
-
isDownloadVisible:
|
|
3785
|
-
isDownloadPrimary:
|
|
3786
|
-
onLoadContentFile:
|
|
3787
|
-
onLoadContentFilePreview:
|
|
3788
|
-
renderContentFilePreview:
|
|
3789
|
-
renderContentFileTree:
|
|
3790
|
-
onDelete:
|
|
3791
|
-
onUnshare:
|
|
3792
|
-
isUnshareVisible:
|
|
3793
|
-
onRevokeShare:
|
|
3794
|
-
onFetchRecipientsCount:
|
|
3795
|
-
isRevokeShareVisible:
|
|
3796
|
-
onUnpublish:
|
|
3797
|
-
isUnpublishVisible:
|
|
3798
|
-
onLogin:
|
|
3799
|
-
onLogout:
|
|
3800
|
-
texts:
|
|
3801
|
-
limitsFooterNote:
|
|
3802
|
-
styles: { colors: { featuredChipStyle:
|
|
3841
|
+
shareOverlay: N,
|
|
3842
|
+
isShareVisible: oe,
|
|
3843
|
+
isSharePrimary: se,
|
|
3844
|
+
onEdit: ue,
|
|
3845
|
+
onDownload: de,
|
|
3846
|
+
isDownloadVisible: fe,
|
|
3847
|
+
isDownloadPrimary: pe,
|
|
3848
|
+
onLoadContentFile: me,
|
|
3849
|
+
onLoadContentFilePreview: he,
|
|
3850
|
+
renderContentFilePreview: z,
|
|
3851
|
+
renderContentFileTree: B,
|
|
3852
|
+
onDelete: ge,
|
|
3853
|
+
onUnshare: _e,
|
|
3854
|
+
isUnshareVisible: ve,
|
|
3855
|
+
onRevokeShare: ye,
|
|
3856
|
+
onFetchRecipientsCount: be,
|
|
3857
|
+
isRevokeShareVisible: xe,
|
|
3858
|
+
onUnpublish: Se,
|
|
3859
|
+
isUnpublishVisible: V,
|
|
3860
|
+
onLogin: en,
|
|
3861
|
+
onLogout: tn,
|
|
3862
|
+
texts: Fe,
|
|
3863
|
+
limitsFooterNote: Ie,
|
|
3864
|
+
styles: { colors: { featuredChipStyle: Pe?.colors?.featuredChipStyle } }
|
|
3803
3865
|
})
|
|
3804
3866
|
]
|
|
3805
3867
|
});
|
|
3806
|
-
},
|
|
3807
|
-
let [x, S] =
|
|
3868
|
+
}, ii = ({ selectedId: e, records: t, selectedLabel: n, placeholder: r, labels: i, onSelect: a, onBrowse: o, extraOptions: s = [], isLoading: c = !1, error: l, isDisabled: u = !1, isInvalid: d = !1, labelledById: f, ariaHasPopup: p = "listbox", className: m, panelClassName: h, iconAfter: g, renderPanel: _, open: v, onOpenChange: y, renderOverlay: b }) => {
|
|
3869
|
+
let [x, S] = R(!1), C = v ?? x, w = (e) => {
|
|
3808
3870
|
e && u || (v === void 0 && S(e), y?.(e));
|
|
3809
|
-
}, [T, E] =
|
|
3871
|
+
}, [T, E] = R(""), D = L(null), O = I(() => [...s, ...t].filter((e) => e.label.toLocaleLowerCase().includes(T.toLocaleLowerCase())), [
|
|
3810
3872
|
s,
|
|
3811
3873
|
t,
|
|
3812
3874
|
T
|
|
@@ -3817,7 +3879,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3817
3879
|
}, A = _ ? _(ee) : /* @__PURE__ */ K("div", {
|
|
3818
3880
|
className: M("w-full min-w-0 max-w-full p-3", h),
|
|
3819
3881
|
children: [
|
|
3820
|
-
/* @__PURE__ */ G(
|
|
3882
|
+
/* @__PURE__ */ G(Ne, {
|
|
3821
3883
|
value: T,
|
|
3822
3884
|
onChange: (e) => E(e ?? ""),
|
|
3823
3885
|
placeholder: i.searchPlaceholder,
|
|
@@ -3835,7 +3897,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3835
3897
|
}) : O.length === 0 ? /* @__PURE__ */ G("span", {
|
|
3836
3898
|
role: "status",
|
|
3837
3899
|
children: i.emptyLabel
|
|
3838
|
-
}) : O.map((t) => /* @__PURE__ */ G(
|
|
3900
|
+
}) : O.map((t) => /* @__PURE__ */ G(Oe, {
|
|
3839
3901
|
role: "option",
|
|
3840
3902
|
"aria-selected": t.id === e,
|
|
3841
3903
|
selected: t.id === e,
|
|
@@ -3846,7 +3908,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3846
3908
|
children: t.icon
|
|
3847
3909
|
}), /* @__PURE__ */ K("span", {
|
|
3848
3910
|
className: "flex min-w-0 flex-col",
|
|
3849
|
-
children: [/* @__PURE__ */ G(
|
|
3911
|
+
children: [/* @__PURE__ */ G(Ce, {
|
|
3850
3912
|
text: t.label,
|
|
3851
3913
|
query: T,
|
|
3852
3914
|
maxLines: 2
|
|
@@ -3857,7 +3919,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3857
3919
|
className: "h-auto max-w-full py-2"
|
|
3858
3920
|
}, t.id))
|
|
3859
3921
|
}),
|
|
3860
|
-
o && /* @__PURE__ */ G(
|
|
3922
|
+
o && /* @__PURE__ */ G(Se, {
|
|
3861
3923
|
className: "mt-2 min-h-11 max-w-full",
|
|
3862
3924
|
label: i.browseLabel ?? "",
|
|
3863
3925
|
onClick: () => {
|
|
@@ -3865,7 +3927,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3865
3927
|
}
|
|
3866
3928
|
})
|
|
3867
3929
|
]
|
|
3868
|
-
}), te = /* @__PURE__ */ G(
|
|
3930
|
+
}), te = /* @__PURE__ */ G(Ee, {
|
|
3869
3931
|
onFocus: (e) => {
|
|
3870
3932
|
D.current = e.currentTarget;
|
|
3871
3933
|
},
|
|
@@ -3894,7 +3956,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3894
3956
|
className: "w-full min-w-0",
|
|
3895
3957
|
onClick: () => w(!C),
|
|
3896
3958
|
children: te
|
|
3897
|
-
}), b(A, C, ee)] }) : /* @__PURE__ */ G(
|
|
3959
|
+
}), b(A, C, ee)] }) : /* @__PURE__ */ G(_e, {
|
|
3898
3960
|
open: C,
|
|
3899
3961
|
onOpenChange: w,
|
|
3900
3962
|
disabled: u,
|
|
@@ -3903,15 +3965,15 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3903
3965
|
renderOverlay: () => A,
|
|
3904
3966
|
children: te
|
|
3905
3967
|
});
|
|
3906
|
-
},
|
|
3907
|
-
let [i, a] =
|
|
3908
|
-
return /* @__PURE__ */ K(
|
|
3968
|
+
}, ai = ({ service: e, texts: t, onLogin: n, onLogout: r }) => {
|
|
3969
|
+
let [i, a] = R(!1), [s, c] = R(!1), [l, u] = R(!1), [d, f] = R(), p = e.authenticationType === y.ApiKey, m = p ? t?.deleteActionLabel ?? "Delete" : t?.logoutActionLabel ?? "Log out", h = p ? t?.deleteApiKeyConfirmMessage?.(b.User) ?? "Are you sure you want to delete your personal API key?" : t?.logoutConfirmMessage ?? "Are you sure you want to log out?";
|
|
3970
|
+
return /* @__PURE__ */ K(Tn, {
|
|
3909
3971
|
label: e.name,
|
|
3910
3972
|
description: e.description,
|
|
3911
3973
|
icon: /* @__PURE__ */ G(ft, {
|
|
3912
|
-
size:
|
|
3974
|
+
size: z.SM,
|
|
3913
3975
|
"aria-hidden": !0,
|
|
3914
|
-
stroke:
|
|
3976
|
+
stroke: B
|
|
3915
3977
|
}),
|
|
3916
3978
|
status: e.status,
|
|
3917
3979
|
isActive: e.status === o.SignedIn,
|
|
@@ -3930,8 +3992,8 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3930
3992
|
errorClassName: "dial-caption-text",
|
|
3931
3993
|
keyCardTitleClassName: "dial-tiny-semi-text",
|
|
3932
3994
|
keyCardDescriptionClassName: "dial-tiny-text",
|
|
3933
|
-
deleteActionClassName:
|
|
3934
|
-
renderLoginOptions: e.canConsentToOfflineUsage ? (e) => /* @__PURE__ */ G(
|
|
3995
|
+
deleteActionClassName: wn.errorText,
|
|
3996
|
+
renderLoginOptions: e.canConsentToOfflineUsage ? (e) => /* @__PURE__ */ G(me, {
|
|
3935
3997
|
isSelected: i,
|
|
3936
3998
|
onChange: a,
|
|
3937
3999
|
disabled: e,
|
|
@@ -3940,14 +4002,14 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3940
4002
|
}) : void 0,
|
|
3941
4003
|
children: [
|
|
3942
4004
|
e.hint && /* @__PURE__ */ G("p", {
|
|
3943
|
-
className: M("dial-small-text break-words",
|
|
4005
|
+
className: M("dial-small-text break-words", wn.description),
|
|
3944
4006
|
children: e.hint
|
|
3945
4007
|
}),
|
|
3946
|
-
e.hasSharedCredentials && /* @__PURE__ */ G(
|
|
3947
|
-
icon: /* @__PURE__ */ G(
|
|
3948
|
-
size:
|
|
4008
|
+
e.hasSharedCredentials && /* @__PURE__ */ G(_n, {
|
|
4009
|
+
icon: /* @__PURE__ */ G(Ge, {
|
|
4010
|
+
size: z.SM,
|
|
3949
4011
|
"aria-hidden": !0,
|
|
3950
|
-
stroke:
|
|
4012
|
+
stroke: B
|
|
3951
4013
|
}),
|
|
3952
4014
|
title: t?.sharedCredentials ?? "Shared credentials are available for this service."
|
|
3953
4015
|
}),
|
|
@@ -3957,19 +4019,19 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3957
4019
|
/* @__PURE__ */ G("p", { children: h }),
|
|
3958
4020
|
d && /* @__PURE__ */ G("p", {
|
|
3959
4021
|
role: "alert",
|
|
3960
|
-
className:
|
|
4022
|
+
className: wn.errorText,
|
|
3961
4023
|
children: d
|
|
3962
4024
|
}),
|
|
3963
4025
|
/* @__PURE__ */ K("div", {
|
|
3964
4026
|
className: "flex flex-wrap justify-end gap-2",
|
|
3965
|
-
children: [/* @__PURE__ */ G(
|
|
4027
|
+
children: [/* @__PURE__ */ G(H, {
|
|
3966
4028
|
className: "min-h-11",
|
|
3967
4029
|
label: t?.cancelLabel ?? "Cancel",
|
|
3968
4030
|
disabled: l,
|
|
3969
4031
|
onClick: () => {
|
|
3970
4032
|
c(!1), f(void 0);
|
|
3971
4033
|
}
|
|
3972
|
-
}), /* @__PURE__ */ G(
|
|
4034
|
+
}), /* @__PURE__ */ G(ge, {
|
|
3973
4035
|
className: "min-h-11",
|
|
3974
4036
|
label: m,
|
|
3975
4037
|
disabled: l,
|
|
@@ -3991,7 +4053,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
3991
4053
|
})
|
|
3992
4054
|
]
|
|
3993
4055
|
});
|
|
3994
|
-
},
|
|
4056
|
+
}, oi = ({ services: e, isLoading: t = !1, hasError: n = !1, showEmptyState: r = !1, onRetry: i, onLogin: a, onLogout: o, texts: s }) => t && !e.length ? /* @__PURE__ */ G("p", {
|
|
3995
4057
|
role: "status",
|
|
3996
4058
|
className: "px-6 py-3",
|
|
3997
4059
|
children: s?.loading ?? "Loading…"
|
|
@@ -4000,7 +4062,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
4000
4062
|
children: [/* @__PURE__ */ G("p", {
|
|
4001
4063
|
role: "alert",
|
|
4002
4064
|
children: s?.loadError ?? "Unable to load credentials"
|
|
4003
|
-
}), /* @__PURE__ */ G(
|
|
4065
|
+
}), /* @__PURE__ */ G(H, {
|
|
4004
4066
|
className: "min-h-11 self-start",
|
|
4005
4067
|
label: s?.retry ?? "Retry",
|
|
4006
4068
|
onClick: i
|
|
@@ -4013,7 +4075,7 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
4013
4075
|
children: s?.title ?? "Credentials"
|
|
4014
4076
|
}), /* @__PURE__ */ G("div", {
|
|
4015
4077
|
className: "flex min-w-0 flex-col",
|
|
4016
|
-
children: e.map((e) => /* @__PURE__ */ G(
|
|
4078
|
+
children: e.map((e) => /* @__PURE__ */ G(ai, {
|
|
4017
4079
|
service: e,
|
|
4018
4080
|
texts: s,
|
|
4019
4081
|
onLogin: a,
|
|
@@ -4026,4 +4088,4 @@ var q = /* @__PURE__ */ function(e) {
|
|
|
4026
4088
|
children: s?.empty ?? "No credentials required"
|
|
4027
4089
|
}) : null;
|
|
4028
4090
|
//#endregion
|
|
4029
|
-
export {
|
|
4091
|
+
export { zt as AppIdentity, oi as ApplicationCredentials, Et as CATALOG_CLASS, Zt as Card, $t as CardGrid, Qt as CardRowRenderer, ri as Catalog, Z as CatalogContentNodeType, Q as CatalogContentPreviewType, J as CatalogDetailsTab, St as CatalogLimitStatus, s as CatalogSortKey, X as CatalogViewMode, q as CodeLanguage, Gn as ContentTab, o as CredentialStatus, Vt as CredentialsBadge, e as CredentialsBadgeState, b as CredentialsLevel, n as CredentialsUiState, ii as DeploymentSelectorField, Ct as DeploymentSize, Y as DetailsConfirmationKind, Cr as DetailsPanel, Tr as FavoriteCard, Or as Favorites, qr as Filter, wt as LimitRowLayout, rr as LimitsTab, Hr as ListView, Xr as Toolbar, y as ToolsetAuthenticationType, Kt as TopicTag, r as buildCatalogTabs, a as filterCatalogItems, d as getCredentialsBadgeState, c as getCredentialsUiState, t as getSignedInLevel, u as getTopicOptions, l as sortCatalogItems, Tt as useFavColumns, It as useScrollVirtualizer };
|