@speakeasy-api/moonshine 1.24.0 → 1.25.0
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/dist/components/AIChat/AIChatContainer.d.ts +2 -1
- package/dist/components/AIChat/types.d.ts +1 -0
- package/dist/{createCustomLucideIcon-DicpPrDi.mjs → createCustomLucideIcon-CtMrMlIb.mjs} +2 -2
- package/dist/{createCustomLucideIcon-DicpPrDi.mjs.map → createCustomLucideIcon-CtMrMlIb.mjs.map} +1 -1
- package/dist/{gems-D9TiRpWq.mjs → gems-BqbsNvE3.mjs} +2 -2
- package/dist/{gems-D9TiRpWq.mjs.map → gems-BqbsNvE3.mjs.map} +1 -1
- package/dist/{go-CVrf6x53.mjs → go-BRTGJ9EL.mjs} +2 -2
- package/dist/{go-CVrf6x53.mjs.map → go-BRTGJ9EL.mjs.map} +1 -1
- package/dist/{index-Ab0aOTL5.mjs → index-FZdko-VH.mjs} +44 -33
- package/dist/{index-Ab0aOTL5.mjs.map → index-FZdko-VH.mjs.map} +1 -1
- package/dist/{maven-3GlMLqxN.mjs → maven-DpTADN0y.mjs} +2 -2
- package/dist/{maven-3GlMLqxN.mjs.map → maven-DpTADN0y.mjs.map} +1 -1
- package/dist/moonshine.es.js +1 -1
- package/dist/{npm-DNO2Kwwj.mjs → npm-CnzLBNzz.mjs} +2 -2
- package/dist/{npm-DNO2Kwwj.mjs.map → npm-CnzLBNzz.mjs.map} +1 -1
- package/dist/{nuget-C-8Yltu-.mjs → nuget-340SDuBk.mjs} +2 -2
- package/dist/{nuget-C-8Yltu-.mjs.map → nuget-340SDuBk.mjs.map} +1 -1
- package/dist/{packagist-DYnOAUhG.mjs → packagist-q-cRPs9g.mjs} +2 -2
- package/dist/{packagist-DYnOAUhG.mjs.map → packagist-q-cRPs9g.mjs.map} +1 -1
- package/dist/{pypi-BJhnv1c7.mjs → pypi-RhiCRzmw.mjs} +2 -2
- package/dist/{pypi-BJhnv1c7.mjs.map → pypi-RhiCRzmw.mjs.map} +1 -1
- package/package.json +1 -1
- package/types/utilities.d.ts +1 -1
|
@@ -16,10 +16,11 @@ export interface AIChatContainerProps extends Omit<AIChatContextValue, 'model' |
|
|
|
16
16
|
components?: Partial<AIChatComponents>;
|
|
17
17
|
toolCallApproval?: ToolCallApprovalProps;
|
|
18
18
|
children?: ReactNode;
|
|
19
|
+
initialInput?: string;
|
|
19
20
|
}
|
|
20
21
|
interface AIChatComponents {
|
|
21
22
|
composer: Partial<AIChatMessageComposerComponents>;
|
|
22
23
|
message: Partial<AIChatMessageComponents>;
|
|
23
24
|
}
|
|
24
|
-
export declare function AIChatContainer({ messages, isLoading, onSendMessage, modelSelector, className, components, toolCallApproval, children, }: AIChatContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export declare function AIChatContainer({ messages, isLoading, onSendMessage, modelSelector, className, components, toolCallApproval, children, initialInput, }: AIChatContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
25
26
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as s, t as n } from "./index-
|
|
1
|
+
import { c as s, t as n } from "./index-FZdko-VH.mjs";
|
|
2
2
|
import { Icon as p } from "lucide-react";
|
|
3
3
|
import { forwardRef as f, createElement as i } from "react";
|
|
4
4
|
const C = (e, t, r) => {
|
|
@@ -16,4 +16,4 @@ const C = (e, t, r) => {
|
|
|
16
16
|
export {
|
|
17
17
|
C as c
|
|
18
18
|
};
|
|
19
|
-
//# sourceMappingURL=createCustomLucideIcon-
|
|
19
|
+
//# sourceMappingURL=createCustomLucideIcon-CtMrMlIb.mjs.map
|
package/dist/{createCustomLucideIcon-DicpPrDi.mjs.map → createCustomLucideIcon-CtMrMlIb.mjs.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createCustomLucideIcon-
|
|
1
|
+
{"version":3,"file":"createCustomLucideIcon-CtMrMlIb.mjs","sources":["../src/components/Icon/customIcons/createCustomLucideIcon.ts"],"sourcesContent":["import { cn, toKebabCase } from '@/lib/utils'\nimport { Icon, IconNode, LucideProps } from 'lucide-react'\nimport { createElement, forwardRef } from 'react'\n\nconst createCustomLucideIcon = (\n iconName: string,\n iconNode: IconNode,\n lucideProps?: Partial<LucideProps>\n) => {\n const Component = forwardRef<SVGSVGElement, LucideProps>(\n ({ className, ...props }, ref) =>\n createElement(Icon, {\n ref,\n iconNode,\n className: cn(`lucide-${toKebabCase(iconName)}`, className),\n ...{ ...(lucideProps ?? {}), ...props },\n })\n )\n\n Component.displayName = `${iconName}`\n\n return Component\n}\n\nexport default createCustomLucideIcon\n"],"names":["createCustomLucideIcon","iconName","iconNode","lucideProps","Component","forwardRef","className","props","ref","createElement","Icon","cn","toKebabCase"],"mappings":";;;AAIA,MAAMA,IAAyB,CAC7BC,GACAC,GACAC,MACG;AACH,QAAMC,IAAYC;AAAA,IAChB,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAS,GAAAC,MACxBC,EAAcC,GAAM;AAAA,MAClB,KAAAF;AAAA,MACA,UAAAN;AAAA,MACA,WAAWS,EAAG,UAAUC,EAAYX,CAAQ,CAAC,IAAIK,CAAS;AAAA,MACrD,GAAIH,KAAe,CAAC;AAAA,MAAI,GAAGI;AAAA,IACjC,CAAA;AAAA,EACL;AAEU,SAAAH,EAAA,cAAc,GAAGH,CAAQ,IAE5BG;AACT;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as L } from "./createCustomLucideIcon-
|
|
1
|
+
import { c as L } from "./createCustomLucideIcon-CtMrMlIb.mjs";
|
|
2
2
|
const o = [
|
|
3
3
|
[
|
|
4
4
|
"path",
|
|
@@ -21,4 +21,4 @@ const o = [
|
|
|
21
21
|
export {
|
|
22
22
|
e as default
|
|
23
23
|
};
|
|
24
|
-
//# sourceMappingURL=gems-
|
|
24
|
+
//# sourceMappingURL=gems-BqbsNvE3.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gems-
|
|
1
|
+
{"version":3,"file":"gems-BqbsNvE3.mjs","sources":["../src/components/Icon/customIcons/gems.ts"],"sourcesContent":["import { IconNode } from 'lucide-react'\nimport createCustomLucideIcon from './createCustomLucideIcon'\n\nconst iconNode: IconNode = [\n [\n 'path',\n {\n d: 'M156.139 157.469L196.307 117.301L168.177 89.1397V89.0126H88.2885L88.4113 89.2582L88.2885 89.1354L60.6496 117.296L128.5 184.929',\n key: 'path-1',\n },\n ],\n [\n 'path',\n {\n d: 'M128.5 14L29 71.0835V185.25L128.5 242.333L228 185.25V71.0829L128.5 14ZM208.96 174.341L128.5 220.767L48.0401 174.34V81.7386L128.5 35.3114L208.96 81.3762',\n key: 'path-2',\n },\n ],\n]\n\nconst icon = createCustomLucideIcon('gems', iconNode, {\n viewBox: '0 0 256 256',\n fill: 'currentColor',\n})\n\nexport { icon as default }\n"],"names":["iconNode","icon","createCustomLucideIcon"],"mappings":";AAGA,MAAMA,IAAqB;AAAA,EACzB;AAAA,IACE;AAAA,IACA;AAAA,MACE,GAAG;AAAA,MACH,KAAK;AAAA,IAAA;AAAA,EAET;AAAA,EACA;AAAA,IACE;AAAA,IACA;AAAA,MACE,GAAG;AAAA,MACH,KAAK;AAAA,IAAA;AAAA,EACP;AAEJ,GAEMC,IAAOC,EAAuB,QAAQF,GAAU;AAAA,EACpD,SAAS;AAAA,EACT,MAAM;AACR,CAAC;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c } from "./createCustomLucideIcon-
|
|
1
|
+
import { c } from "./createCustomLucideIcon-CtMrMlIb.mjs";
|
|
2
2
|
const o = [
|
|
3
3
|
[
|
|
4
4
|
"path",
|
|
@@ -21,4 +21,4 @@ const o = [
|
|
|
21
21
|
export {
|
|
22
22
|
e as default
|
|
23
23
|
};
|
|
24
|
-
//# sourceMappingURL=go-
|
|
24
|
+
//# sourceMappingURL=go-BRTGJ9EL.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"go-
|
|
1
|
+
{"version":3,"file":"go-BRTGJ9EL.mjs","sources":["../src/components/Icon/customIcons/go.ts"],"sourcesContent":["import { IconNode } from 'lucide-react'\nimport createCustomLucideIcon from './createCustomLucideIcon'\n\nconst iconNode: IconNode = [\n [\n 'path',\n {\n d: 'M11.156 54.829c-.243 0-.303-.122-.182-.303l1.273-1.637c.12-.182.424-.303.666-.303H34.55c.243 0 .303.182.182.364l-1.03 1.576c-.121.181-.424.363-.606.363zM2.004 60.404c-.242 0-.303-.12-.182-.303l1.273-1.636c.121-.182.424-.303.667-.303h27.636c.242 0 .364.182.303.364l-.485 1.454c-.06.243-.303.364-.545.364zM16.67 65.98c-.242 0-.302-.182-.181-.364l.848-1.515c.122-.182.364-.363.607-.363h12.12c.243 0 .364.181.364.424l-.12 1.454c0 .243-.243.425-.425.425zM79.58 53.738c-3.819.97-6.425 1.697-10.182 2.666-.91.243-.97.303-1.758-.606-.909-1.03-1.576-1.697-2.848-2.303-3.819-1.878-7.516-1.333-10.97.91-4.121 2.666-6.242 6.605-6.182 11.514.06 4.849 3.394 8.849 8.182 9.516 4.121.545 7.576-.91 10.303-4 .545-.667 1.03-1.394 1.636-2.243H56.064c-1.272 0-1.575-.788-1.151-1.818.788-1.879 2.242-5.03 3.09-6.606.183-.364.607-.97 1.516-.97h22.06c-.12 1.637-.12 3.273-.363 4.91-.667 4.363-2.303 8.363-4.97 11.878-4.364 5.758-10.06 9.333-17.273 10.303-5.939.788-11.454-.364-16.302-4-4.485-3.394-7.03-7.879-7.697-13.454-.788-6.606 1.151-12.546 5.151-17.758 4.303-5.636 10-9.212 16.97-10.485 5.697-1.03 11.151-.363 16.06 2.97 3.212 2.121 5.515 5.03 7.03 8.545.364.546.122.849-.606 1.03z',\n key: 'path-1',\n },\n ],\n [\n 'path',\n {\n d: 'M99.64 87.253c-5.515-.122-10.546-1.697-14.788-5.334-3.576-3.09-5.818-7.03-6.545-11.697-1.091-6.848.787-12.909 4.909-18.302 4.424-5.819 9.757-8.849 16.97-10.122 6.181-1.09 12-.484 17.272 3.091 4.788 3.273 7.757 7.697 8.545 13.515 1.03 8.182-1.333 14.849-6.97 20.546-4 4.06-8.909 6.606-14.545 7.757-1.636.303-3.273.364-4.848.546zm14.424-24.485c-.06-.788-.06-1.394-.182-2-1.09-6-6.606-9.394-12.363-8.06-5.637 1.272-9.273 4.848-10.606 10.545-1.091 4.727 1.212 9.515 5.575 11.454 3.334 1.455 6.667 1.273 9.879-.363 4.788-2.485 7.394-6.364 7.697-11.576z',\n key: 'path-2',\n },\n ],\n]\n\nconst icon = createCustomLucideIcon('go', iconNode, {\n viewBox: '0 0 128 128',\n fill: 'currentColor',\n})\n\nexport { icon as default }\n"],"names":["iconNode","icon","createCustomLucideIcon"],"mappings":";AAGA,MAAMA,IAAqB;AAAA,EACzB;AAAA,IACE;AAAA,IACA;AAAA,MACE,GAAG;AAAA,MACH,KAAK;AAAA,IAAA;AAAA,EAET;AAAA,EACA;AAAA,IACE;AAAA,IACA;AAAA,MACE,GAAG;AAAA,MACH,KAAK;AAAA,IAAA;AAAA,EACP;AAEJ,GAEMC,IAAOC,EAAuB,MAAMF,GAAU;AAAA,EAClD,SAAS;AAAA,EACT,MAAM;AACR,CAAC;"}
|
|
@@ -2929,13 +2929,13 @@ const K4 = {
|
|
|
2929
2929
|
}
|
|
2930
2930
|
return t;
|
|
2931
2931
|
}, Qu = {
|
|
2932
|
-
npm: () => import("./npm-
|
|
2933
|
-
pypi: () => import("./pypi-
|
|
2934
|
-
nuget: () => import("./nuget-
|
|
2935
|
-
go: () => import("./go-
|
|
2936
|
-
gems: () => import("./gems-
|
|
2937
|
-
maven: () => import("./maven-
|
|
2938
|
-
packagist: () => import("./packagist-
|
|
2932
|
+
npm: () => import("./npm-CnzLBNzz.mjs"),
|
|
2933
|
+
pypi: () => import("./pypi-RhiCRzmw.mjs"),
|
|
2934
|
+
nuget: () => import("./nuget-340SDuBk.mjs"),
|
|
2935
|
+
go: () => import("./go-BRTGJ9EL.mjs"),
|
|
2936
|
+
gems: () => import("./gems-BqbsNvE3.mjs"),
|
|
2937
|
+
maven: () => import("./maven-DpTADN0y.mjs"),
|
|
2938
|
+
packagist: () => import("./packagist-q-cRPs9g.mjs")
|
|
2939
2939
|
};
|
|
2940
2940
|
function Y4() {
|
|
2941
2941
|
return /* @__PURE__ */ u("div", {});
|
|
@@ -40187,35 +40187,44 @@ function $Z({
|
|
|
40187
40187
|
className: A,
|
|
40188
40188
|
components: e
|
|
40189
40189
|
}) {
|
|
40190
|
-
const
|
|
40191
|
-
|
|
40192
|
-
|
|
40190
|
+
const {
|
|
40191
|
+
onSendMessage: t,
|
|
40192
|
+
isLoading: n,
|
|
40193
|
+
model: o,
|
|
40194
|
+
onModelChange: r,
|
|
40195
|
+
availableModels: i,
|
|
40196
|
+
initialInput: s
|
|
40197
|
+
} = Sd(), [a, g] = vA(s || ""), [c, l] = vA(!1), Q = LA(null), B = () => {
|
|
40198
|
+
const h = Q.current;
|
|
40199
|
+
h && (h.style.height = "auto", h.style.height = `${h.scrollHeight}px`);
|
|
40193
40200
|
};
|
|
40194
40201
|
GA(() => {
|
|
40195
|
-
|
|
40196
|
-
}, [
|
|
40197
|
-
|
|
40198
|
-
|
|
40199
|
-
|
|
40200
|
-
|
|
40202
|
+
B();
|
|
40203
|
+
}, [a]), GA(() => {
|
|
40204
|
+
s && g(s);
|
|
40205
|
+
}, []);
|
|
40206
|
+
const E = (h) => {
|
|
40207
|
+
h?.preventDefault(), a.trim() && t && !n && (t(a), g(""), Q.current && (Q.current.style.height = "auto"));
|
|
40208
|
+
}, C = (h) => {
|
|
40209
|
+
h.key === "Enter" && !h.shiftKey && (h.preventDefault(), E());
|
|
40201
40210
|
};
|
|
40202
|
-
return /* @__PURE__ */ u("form", { onSubmit:
|
|
40211
|
+
return /* @__PURE__ */ u("form", { onSubmit: E, className: nA("mt-auto p-4", A), children: /* @__PURE__ */ u("div", { className: "flex flex-col", children: /* @__PURE__ */ eA(
|
|
40203
40212
|
"div",
|
|
40204
40213
|
{
|
|
40205
40214
|
className: nA(
|
|
40206
40215
|
"flex flex-col overflow-hidden rounded-lg border transition-shadow",
|
|
40207
|
-
|
|
40216
|
+
c && "ring-1 ring-offset-1"
|
|
40208
40217
|
),
|
|
40209
40218
|
children: [
|
|
40210
40219
|
/* @__PURE__ */ u(
|
|
40211
40220
|
"textarea",
|
|
40212
40221
|
{
|
|
40213
|
-
ref:
|
|
40214
|
-
value:
|
|
40215
|
-
onChange: (
|
|
40216
|
-
onKeyDown:
|
|
40217
|
-
onFocus: () =>
|
|
40218
|
-
onBlur: () =>
|
|
40222
|
+
ref: Q,
|
|
40223
|
+
value: a,
|
|
40224
|
+
onChange: (h) => g(h.target.value),
|
|
40225
|
+
onKeyDown: C,
|
|
40226
|
+
onFocus: () => l(!0),
|
|
40227
|
+
onBlur: () => l(!1),
|
|
40219
40228
|
placeholder: "Send a message...",
|
|
40220
40229
|
rows: 1,
|
|
40221
40230
|
className: nA(
|
|
@@ -40224,25 +40233,25 @@ function $Z({
|
|
|
40224
40233
|
"focus:outline-none",
|
|
40225
40234
|
"text-sm"
|
|
40226
40235
|
),
|
|
40227
|
-
disabled:
|
|
40236
|
+
disabled: n
|
|
40228
40237
|
}
|
|
40229
40238
|
),
|
|
40230
40239
|
/* @__PURE__ */ eA("div", { className: "flex items-center justify-between p-3 pt-2", children: [
|
|
40231
40240
|
/* @__PURE__ */ eA("div", { className: "flex items-center gap-2", children: [
|
|
40232
|
-
|
|
40241
|
+
i && o && r && Pr(
|
|
40233
40242
|
pm,
|
|
40234
40243
|
e,
|
|
40235
40244
|
"modelSelector",
|
|
40236
40245
|
{
|
|
40237
|
-
model:
|
|
40238
|
-
onModelChange:
|
|
40239
|
-
availableModels:
|
|
40246
|
+
model: o,
|
|
40247
|
+
onModelChange: r,
|
|
40248
|
+
availableModels: i
|
|
40240
40249
|
}
|
|
40241
40250
|
),
|
|
40242
40251
|
e?.additionalActions
|
|
40243
40252
|
] }),
|
|
40244
40253
|
Pr(pm, e, "submitButton", {
|
|
40245
|
-
disabled: !
|
|
40254
|
+
disabled: !a.trim() || n,
|
|
40246
40255
|
type: "submit"
|
|
40247
40256
|
})
|
|
40248
40257
|
] })
|
|
@@ -49545,7 +49554,8 @@ function LiA({
|
|
|
49545
49554
|
className: o,
|
|
49546
49555
|
components: r,
|
|
49547
49556
|
toolCallApproval: i,
|
|
49548
|
-
children: s
|
|
49557
|
+
children: s,
|
|
49558
|
+
initialInput: a
|
|
49549
49559
|
}) {
|
|
49550
49560
|
return /* @__PURE__ */ u(
|
|
49551
49561
|
Lb.Provider,
|
|
@@ -49557,7 +49567,8 @@ function LiA({
|
|
|
49557
49567
|
model: n?.model,
|
|
49558
49568
|
onModelChange: n?.onModelChange,
|
|
49559
49569
|
availableModels: n?.availableModels,
|
|
49560
|
-
toolCallApproval: i
|
|
49570
|
+
toolCallApproval: i,
|
|
49571
|
+
initialInput: a
|
|
49561
49572
|
},
|
|
49562
49573
|
children: /* @__PURE__ */ eA("div", { className: nA("flex h-full min-h-0 max-w-3xl flex-col", o), children: [
|
|
49563
49574
|
/* @__PURE__ */ u("div", { className: "flex-1 overflow-hidden", children: /* @__PURE__ */ u(_oA, { components: r?.message }) }),
|
|
@@ -49687,4 +49698,4 @@ export {
|
|
|
49687
49698
|
FL as y,
|
|
49688
49699
|
orA as z
|
|
49689
49700
|
};
|
|
49690
|
-
//# sourceMappingURL=index-
|
|
49701
|
+
//# sourceMappingURL=index-FZdko-VH.mjs.map
|