@yak-io/nuxt 0.1.2 → 0.3.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/README.md +155 -0
- package/dist/index.d.ts +3 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/plugin.d.ts +9 -33
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js +22 -27
- package/package.json +4 -4
package/README.md
ADDED
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
# @yak-io/nuxt
|
|
2
|
+
|
|
3
|
+
Nuxt 3 integration for the Yak embeddable chat widget. Provides a plugin-compatible factory that auto-mounts on `app:mounted` and provides the widget API via Nuxt's plugin system.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
pnpm add @yak-io/nuxt
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Quickstart
|
|
12
|
+
|
|
13
|
+
### 1. Create a Nuxt plugin
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
// plugins/yak.client.ts
|
|
17
|
+
import { defineNuxtPlugin } from "#app";
|
|
18
|
+
import { createYakProvider, enableYakLogging, disableYakLogging, isYakLoggingEnabled } from "@yak-io/nuxt";
|
|
19
|
+
|
|
20
|
+
export default defineNuxtPlugin((nuxtApp) => {
|
|
21
|
+
const runtimeConfig = useRuntimeConfig();
|
|
22
|
+
|
|
23
|
+
const yak = createYakProvider({
|
|
24
|
+
appId: runtimeConfig.public.yakAppId,
|
|
25
|
+
theme: { position: "bottom-right", colorMode: "system" },
|
|
26
|
+
trigger: { label: "Ask with AI" },
|
|
27
|
+
getConfig: async () => {
|
|
28
|
+
const res = await fetch("/api/yak");
|
|
29
|
+
return res.json();
|
|
30
|
+
},
|
|
31
|
+
onToolCall: async (name, args) => {
|
|
32
|
+
const res = await fetch("/api/yak", {
|
|
33
|
+
method: "POST",
|
|
34
|
+
headers: { "Content-Type": "application/json" },
|
|
35
|
+
body: JSON.stringify({ name, args }),
|
|
36
|
+
});
|
|
37
|
+
const data = await res.json();
|
|
38
|
+
if (!data.ok) throw new Error(data.error);
|
|
39
|
+
return data.result;
|
|
40
|
+
},
|
|
41
|
+
onRedirect: (path) => {
|
|
42
|
+
navigateTo(path);
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
// Mount on client, clean up on HMR
|
|
47
|
+
nuxtApp.hook("app:mounted", () => yak.mount());
|
|
48
|
+
if (import.meta.hot) {
|
|
49
|
+
import.meta.hot.dispose(() => yak.destroy());
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
return {
|
|
53
|
+
provide: {
|
|
54
|
+
yak,
|
|
55
|
+
yakLogging: { enableYakLogging, disableYakLogging, isYakLoggingEnabled },
|
|
56
|
+
},
|
|
57
|
+
};
|
|
58
|
+
});
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### 2. Access in components
|
|
62
|
+
|
|
63
|
+
```ts
|
|
64
|
+
// Any component <script setup>
|
|
65
|
+
const { $yak } = useNuxtApp();
|
|
66
|
+
const { open, openWithPrompt, isOpen, isReady } = $yak;
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
`isOpen` and `isReady` are Vue `readonly` refs:
|
|
70
|
+
|
|
71
|
+
```html
|
|
72
|
+
<template>
|
|
73
|
+
<button @click="open">Open Chat</button>
|
|
74
|
+
<span v-if="isOpen">Chat is open</span>
|
|
75
|
+
</template>
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
### 3. Subscribe to tool events
|
|
79
|
+
|
|
80
|
+
```ts
|
|
81
|
+
const { $yak } = useNuxtApp();
|
|
82
|
+
|
|
83
|
+
$yak.subscribeToToolEvents((event) => {
|
|
84
|
+
if (event.ok && event.name.startsWith("tasks.")) {
|
|
85
|
+
refreshTasks();
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## API Reference
|
|
91
|
+
|
|
92
|
+
### `createYakProvider(options)`
|
|
93
|
+
|
|
94
|
+
Creates a Yak widget instance. Returns a `YakApi` with Vue-reactive refs for reactive state.
|
|
95
|
+
|
|
96
|
+
You must call `yak.mount()` on the client side (e.g., in the `app:mounted` hook) and `yak.destroy()` when cleaning up.
|
|
97
|
+
|
|
98
|
+
**Options:**
|
|
99
|
+
|
|
100
|
+
| Option | Type | Description |
|
|
101
|
+
|--------|------|-------------|
|
|
102
|
+
| `appId` | `string` | Your Yak app ID |
|
|
103
|
+
| `getConfig` | `ChatConfigProvider` | Async function returning routes + tools. Called on first open. |
|
|
104
|
+
| `onToolCall` | `ToolCallHandler` | Handle tool invocations from the assistant |
|
|
105
|
+
| `onGraphQLSchemaCall` | `GraphQLSchemaHandler` | Handle GraphQL schema tool calls |
|
|
106
|
+
| `onRESTSchemaCall` | `RESTSchemaHandler` | Handle REST/OpenAPI schema tool calls |
|
|
107
|
+
| `theme` | `Theme` | Position, color mode, and custom colors |
|
|
108
|
+
| `onRedirect` | `(path: string) => void` | Navigation handler (defaults to `window.location.assign`) |
|
|
109
|
+
| `disableRestartButton` | `boolean` | Hide the restart session button |
|
|
110
|
+
| `trigger` | `boolean \| TriggerButtonConfig` | Built-in trigger button |
|
|
111
|
+
|
|
112
|
+
### `YakApi`
|
|
113
|
+
|
|
114
|
+
```ts
|
|
115
|
+
type YakApi = {
|
|
116
|
+
isOpen: DeepReadonly<Ref<boolean>>; // Vue readonly ref
|
|
117
|
+
isReady: DeepReadonly<Ref<boolean>>; // Vue readonly ref
|
|
118
|
+
open: () => void;
|
|
119
|
+
close: () => void;
|
|
120
|
+
openWithPrompt: (prompt: string) => void;
|
|
121
|
+
subscribeToToolEvents: (handler: ToolCallEventHandler) => () => void;
|
|
122
|
+
mount: () => void; // Call in app:mounted hook
|
|
123
|
+
destroy: () => void; // Call on HMR dispose / cleanup
|
|
124
|
+
};
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
## Logging
|
|
128
|
+
|
|
129
|
+
```ts
|
|
130
|
+
import { enableYakLogging, disableYakLogging, isYakLoggingEnabled } from "@yak-io/nuxt";
|
|
131
|
+
|
|
132
|
+
enableYakLogging(); // Enable verbose SDK logs
|
|
133
|
+
disableYakLogging(); // Disable SDK logs
|
|
134
|
+
isYakLoggingEnabled(); // → boolean
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
## Types
|
|
138
|
+
|
|
139
|
+
```ts
|
|
140
|
+
import type {
|
|
141
|
+
YakProviderOptions,
|
|
142
|
+
YakApi,
|
|
143
|
+
ToolCallEventHandler,
|
|
144
|
+
ChatConfigProvider,
|
|
145
|
+
ToolCallHandler,
|
|
146
|
+
ToolCallEvent,
|
|
147
|
+
Theme,
|
|
148
|
+
TriggerButtonConfig,
|
|
149
|
+
WidgetPosition,
|
|
150
|
+
} from "@yak-io/nuxt";
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
## License
|
|
154
|
+
|
|
155
|
+
Proprietary — see LICENSE file.
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
export type { ChatConfigProvider, GraphQLRequest, GraphQLSchemaHandler, GraphQLSchemaSource, OpenAPISchemaSource, RESTRequest, RESTSchemaHandler, SchemaSource, Theme, ThemeColors, ToolCallEvent, ToolCallHandler, TriggerButtonConfig, VoiceMachine, VoiceState, WidgetMode, WidgetPosition, } from "@yak-io/javascript";
|
|
2
|
+
export { disableYakLogging, enableYakLogging, isYakLoggingEnabled } from "@yak-io/javascript";
|
|
3
|
+
export type { ToolCallEventHandler, YakApi, YakProviderOptions } from "./plugin.js";
|
|
1
4
|
export { createYakProvider } from "./plugin.js";
|
|
2
|
-
export type { YakProviderOptions, YakApi, ToolCallEventHandler } from "./plugin.js";
|
|
3
|
-
export { enableYakLogging, disableYakLogging, isYakLoggingEnabled } from "@yak-io/javascript";
|
|
4
|
-
export type { GraphQLSchemaHandler, RESTSchemaHandler, GraphQLRequest, RESTRequest, ToolCallHandler, ToolCallEvent, SchemaSource, GraphQLSchemaSource, OpenAPISchemaSource, Theme, ThemeColors, TriggerButtonConfig, WidgetPosition, ChatConfigProvider, } from "@yak-io/javascript";
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA,YAAY,EACV,kBAAkB,EAClB,cAAc,EACd,oBAAoB,EACpB,mBAAmB,EACnB,mBAAmB,EACnB,WAAW,EACX,iBAAiB,EACjB,YAAY,EACZ,KAAK,EACL,WAAW,EACX,aAAa,EACb,eAAe,EACf,mBAAmB,EACnB,YAAY,EACZ,UAAU,EACV,UAAU,EACV,cAAc,GACf,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAC9F,YAAY,EAAE,oBAAoB,EAAE,MAAM,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACpF,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// Public API
|
|
2
|
-
export { createYakProvider } from "./plugin.js";
|
|
3
2
|
// Re-export logging utilities
|
|
4
|
-
export {
|
|
3
|
+
export { disableYakLogging, enableYakLogging, isYakLoggingEnabled } from "@yak-io/javascript";
|
|
4
|
+
export { createYakProvider } from "./plugin.js";
|
package/dist/plugin.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import { type
|
|
1
|
+
import { type ChatConfigProvider, type GraphQLSchemaHandler, type RESTSchemaHandler, type Theme, type ToolCallEvent, type ToolCallHandler, type TriggerButtonConfig, type VoiceMachine, type WidgetMode } from "@yak-io/javascript";
|
|
2
|
+
import { type DeepReadonly, type Ref } from "vue";
|
|
3
3
|
export type ToolCallEventHandler = (event: ToolCallEvent) => void;
|
|
4
4
|
export type YakProviderOptions = {
|
|
5
5
|
appId: string;
|
|
6
|
+
mode?: WidgetMode;
|
|
6
7
|
getConfig?: ChatConfigProvider;
|
|
7
8
|
onToolCall?: ToolCallHandler;
|
|
8
9
|
onGraphQLSchemaCall?: GraphQLSchemaHandler;
|
|
@@ -13,47 +14,22 @@ export type YakProviderOptions = {
|
|
|
13
14
|
trigger?: boolean | TriggerButtonConfig;
|
|
14
15
|
};
|
|
15
16
|
export type YakApi = {
|
|
16
|
-
/** Readonly ref — whether the chat widget is open */
|
|
17
17
|
isOpen: DeepReadonly<Ref<boolean>>;
|
|
18
|
-
/** Readonly ref — whether the iframe is ready */
|
|
19
18
|
isReady: DeepReadonly<Ref<boolean>>;
|
|
20
|
-
/** Open the chat widget */
|
|
21
19
|
open: () => void;
|
|
22
|
-
/** Close the chat widget */
|
|
23
20
|
close: () => void;
|
|
24
|
-
/** Open the chat widget and send a prompt */
|
|
25
21
|
openWithPrompt: (prompt: string) => void;
|
|
26
|
-
/** Subscribe to tool call completion events. Returns an unsubscribe function. */
|
|
27
22
|
subscribeToToolEvents: (handler: ToolCallEventHandler) => () => void;
|
|
28
|
-
|
|
23
|
+
voiceMachine: DeepReadonly<Ref<VoiceMachine>>;
|
|
24
|
+
voiceStart: () => Promise<void>;
|
|
25
|
+
voiceStop: () => Promise<void>;
|
|
26
|
+
voiceToggle: () => Promise<void>;
|
|
29
27
|
mount: () => void;
|
|
30
|
-
/** Destroy the widget DOM */
|
|
31
28
|
destroy: () => void;
|
|
32
29
|
};
|
|
33
30
|
/**
|
|
34
|
-
* Creates a yak chat
|
|
35
|
-
* SSR-safe: call `mount()` only on the client side
|
|
36
|
-
* or inside `onMounted`).
|
|
37
|
-
*
|
|
38
|
-
* @example
|
|
39
|
-
* ```ts
|
|
40
|
-
* // plugins/yak.client.ts
|
|
41
|
-
* import { createYakProvider } from "@yak-io/nuxt";
|
|
42
|
-
*
|
|
43
|
-
* export default defineNuxtPlugin((nuxtApp) => {
|
|
44
|
-
* const yak = createYakProvider({ appId: "my-app" });
|
|
45
|
-
*
|
|
46
|
-
* nuxtApp.hook("app:mounted", () => yak.mount());
|
|
47
|
-
* nuxtApp.hook("app:beforeMount", () => {});
|
|
48
|
-
*
|
|
49
|
-
* nuxtApp.provide("yak", yak);
|
|
50
|
-
*
|
|
51
|
-
* // Cleanup on HMR
|
|
52
|
-
* if (import.meta.hot) {
|
|
53
|
-
* import.meta.hot.dispose(() => yak.destroy());
|
|
54
|
-
* }
|
|
55
|
-
* });
|
|
56
|
-
* ```
|
|
31
|
+
* Creates a yak widget (chat + voice) for Nuxt.
|
|
32
|
+
* SSR-safe: call `mount()` only on the client side.
|
|
57
33
|
*/
|
|
58
34
|
export declare function createYakProvider(options: YakProviderOptions): YakApi;
|
|
59
35
|
//# sourceMappingURL=plugin.d.ts.map
|
package/dist/plugin.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAGzB,KAAK,iBAAiB,EACtB,KAAK,KAAK,EACV,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,YAAY,EACjB,KAAK,UAAU,EAEhB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,GAAG,EAAiB,MAAM,KAAK,CAAC;AAIjE,MAAM,MAAM,oBAAoB,GAAG,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;AAElE,MAAM,MAAM,kBAAkB,GAAG;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,SAAS,CAAC,EAAE,kBAAkB,CAAC;IAC/B,UAAU,CAAC,EAAE,eAAe,CAAC;IAC7B,mBAAmB,CAAC,EAAE,oBAAoB,CAAC;IAC3C,gBAAgB,CAAC,EAAE,iBAAiB,CAAC;IACrC,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,OAAO,CAAC,EAAE,OAAO,GAAG,mBAAmB,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,MAAM,GAAG;IACnB,MAAM,EAAE,YAAY,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC;IACnC,OAAO,EAAE,YAAY,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC;IACpC,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,KAAK,EAAE,MAAM,IAAI,CAAC;IAClB,cAAc,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,qBAAqB,EAAE,CAAC,OAAO,EAAE,oBAAoB,KAAK,MAAM,IAAI,CAAC;IACrE,YAAY,EAAE,YAAY,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC;IAC9C,UAAU,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAChC,SAAS,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC/B,WAAW,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IACjC,KAAK,EAAE,MAAM,IAAI,CAAC;IAClB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAIF;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,kBAAkB,GAAG,MAAM,CAmGrE"}
|
package/dist/plugin.js
CHANGED
|
@@ -1,35 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { logger } from "@yak-io/javascript";
|
|
1
|
+
import { INITIAL_VOICE_MACHINE, logger, YakEmbed, } from "@yak-io/javascript";
|
|
2
|
+
import { readonly, ref } from "vue";
|
|
4
3
|
// ── Provider factory ────────────────────────────────────────────────────────
|
|
5
4
|
/**
|
|
6
|
-
* Creates a yak chat
|
|
7
|
-
* SSR-safe: call `mount()` only on the client side
|
|
8
|
-
* or inside `onMounted`).
|
|
9
|
-
*
|
|
10
|
-
* @example
|
|
11
|
-
* ```ts
|
|
12
|
-
* // plugins/yak.client.ts
|
|
13
|
-
* import { createYakProvider } from "@yak-io/nuxt";
|
|
14
|
-
*
|
|
15
|
-
* export default defineNuxtPlugin((nuxtApp) => {
|
|
16
|
-
* const yak = createYakProvider({ appId: "my-app" });
|
|
17
|
-
*
|
|
18
|
-
* nuxtApp.hook("app:mounted", () => yak.mount());
|
|
19
|
-
* nuxtApp.hook("app:beforeMount", () => {});
|
|
20
|
-
*
|
|
21
|
-
* nuxtApp.provide("yak", yak);
|
|
22
|
-
*
|
|
23
|
-
* // Cleanup on HMR
|
|
24
|
-
* if (import.meta.hot) {
|
|
25
|
-
* import.meta.hot.dispose(() => yak.destroy());
|
|
26
|
-
* }
|
|
27
|
-
* });
|
|
28
|
-
* ```
|
|
5
|
+
* Creates a yak widget (chat + voice) for Nuxt.
|
|
6
|
+
* SSR-safe: call `mount()` only on the client side.
|
|
29
7
|
*/
|
|
30
8
|
export function createYakProvider(options) {
|
|
31
9
|
const isOpen = ref(false);
|
|
32
10
|
const isReady = ref(false);
|
|
11
|
+
const voiceMachine = ref(INITIAL_VOICE_MACHINE);
|
|
33
12
|
const toolEventSubscribers = new Set();
|
|
34
13
|
const handleToolCallComplete = (event) => {
|
|
35
14
|
logger.debug("Tool call completed, notifying subscribers:", {
|
|
@@ -50,8 +29,10 @@ export function createYakProvider(options) {
|
|
|
50
29
|
(typeof window !== "undefined" ? (path) => window.location.assign(path) : undefined);
|
|
51
30
|
const embed = new YakEmbed({
|
|
52
31
|
appId: options.appId,
|
|
32
|
+
mode: options.mode,
|
|
53
33
|
theme: options.theme,
|
|
54
34
|
trigger: options.trigger ?? false,
|
|
35
|
+
getConfig: options.getConfig,
|
|
55
36
|
onToolCall: options.onToolCall,
|
|
56
37
|
onGraphQLSchemaCall: options.onGraphQLSchemaCall,
|
|
57
38
|
onRESTSchemaCall: options.onRESTSchemaCall,
|
|
@@ -59,11 +40,13 @@ export function createYakProvider(options) {
|
|
|
59
40
|
options: { disableRestartButton: options.disableRestartButton },
|
|
60
41
|
onToolCallComplete: handleToolCallComplete,
|
|
61
42
|
});
|
|
62
|
-
// Sync embed state → refs
|
|
63
43
|
embed.onStateChange((state) => {
|
|
64
44
|
isOpen.value = state.isOpen;
|
|
65
45
|
isReady.value = state.isReady;
|
|
66
46
|
});
|
|
47
|
+
embed.onVoiceStateChange((m) => {
|
|
48
|
+
voiceMachine.value = m;
|
|
49
|
+
});
|
|
67
50
|
// Fetch chat config on first open
|
|
68
51
|
if (options.getConfig) {
|
|
69
52
|
const getConfig = options.getConfig;
|
|
@@ -84,6 +67,14 @@ export function createYakProvider(options) {
|
|
|
84
67
|
}
|
|
85
68
|
});
|
|
86
69
|
}
|
|
70
|
+
const voiceStart = async () => {
|
|
71
|
+
try {
|
|
72
|
+
await embed.voiceStart();
|
|
73
|
+
}
|
|
74
|
+
catch (err) {
|
|
75
|
+
logger.warn("Voice start failed", err);
|
|
76
|
+
}
|
|
77
|
+
};
|
|
87
78
|
return {
|
|
88
79
|
isOpen: readonly(isOpen),
|
|
89
80
|
isReady: readonly(isReady),
|
|
@@ -96,6 +87,10 @@ export function createYakProvider(options) {
|
|
|
96
87
|
toolEventSubscribers.delete(handler);
|
|
97
88
|
};
|
|
98
89
|
},
|
|
90
|
+
voiceMachine: readonly(voiceMachine),
|
|
91
|
+
voiceStart,
|
|
92
|
+
voiceStop: () => embed.voiceStop(),
|
|
93
|
+
voiceToggle: () => embed.voiceToggle(),
|
|
99
94
|
mount: () => embed.mount(),
|
|
100
95
|
destroy: () => embed.destroy(),
|
|
101
96
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yak-io/nuxt",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Nuxt 3 module for embedding yak chatbot",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -41,16 +41,16 @@
|
|
|
41
41
|
"./package.json": "./package.json"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@yak-io/javascript": "0.
|
|
44
|
+
"@yak-io/javascript": "0.8.0"
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"nuxt": "^3.0.0",
|
|
48
48
|
"vue": "^3.3.0"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@types/node": "^24.12.
|
|
51
|
+
"@types/node": "^24.12.4",
|
|
52
52
|
"typescript": "^5.3.0",
|
|
53
|
-
"vue": "^3.5.
|
|
53
|
+
"vue": "^3.5.34",
|
|
54
54
|
"@repo/typescript-config": "0.0.0"
|
|
55
55
|
},
|
|
56
56
|
"scripts": {
|