@cuekit-ai/react 1.6.6 → 1.6.8
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/{chunk-JVYSFKMO.mjs → chunk-ZP7AXODE.mjs} +673 -993
- package/dist/index.d.mts +32 -10
- package/dist/index.d.ts +32 -10
- package/dist/index.js +810 -951
- package/dist/index.mjs +260 -82
- package/dist/{webrtc-service-KN5SEJKS.mjs → webrtc-service-IMARTHNM.mjs} +1 -1
- package/package.json +6 -4
package/dist/index.d.mts
CHANGED
|
@@ -3,6 +3,29 @@ import React__default, { ReactNode } from 'react';
|
|
|
3
3
|
import * as livekit_client from 'livekit-client';
|
|
4
4
|
import { ConnectionState, Room } from 'livekit-client';
|
|
5
5
|
|
|
6
|
+
type InteractiveElement = {
|
|
7
|
+
[btnId: string]: string[];
|
|
8
|
+
};
|
|
9
|
+
interface DOMStructurePayload {
|
|
10
|
+
components: InteractiveElement;
|
|
11
|
+
}
|
|
12
|
+
interface ThemeColors {
|
|
13
|
+
primary: string;
|
|
14
|
+
background: string;
|
|
15
|
+
text: string;
|
|
16
|
+
surface?: string;
|
|
17
|
+
border?: string;
|
|
18
|
+
textMuted?: string;
|
|
19
|
+
userBubble?: string;
|
|
20
|
+
userText?: string;
|
|
21
|
+
aiBubble?: string;
|
|
22
|
+
aiText?: string;
|
|
23
|
+
}
|
|
24
|
+
interface ThemeConfig {
|
|
25
|
+
light: ThemeColors;
|
|
26
|
+
dark: ThemeColors;
|
|
27
|
+
}
|
|
28
|
+
|
|
6
29
|
declare global {
|
|
7
30
|
interface AnsyrGlobalStore {
|
|
8
31
|
intent: string | null;
|
|
@@ -22,6 +45,8 @@ type AnsyrCtx = {
|
|
|
22
45
|
showLogo: boolean;
|
|
23
46
|
showAIIcon: boolean;
|
|
24
47
|
showUserIcon: boolean;
|
|
48
|
+
theme?: ThemeConfig;
|
|
49
|
+
emptyStateMessage?: string;
|
|
25
50
|
};
|
|
26
51
|
declare const useAnsyrContext: () => AnsyrCtx;
|
|
27
52
|
interface Props {
|
|
@@ -37,6 +62,8 @@ interface Props {
|
|
|
37
62
|
showLogo?: boolean;
|
|
38
63
|
showAIIcon?: boolean;
|
|
39
64
|
showUserIcon?: boolean;
|
|
65
|
+
theme: ThemeConfig;
|
|
66
|
+
emptyStateMessage?: string;
|
|
40
67
|
}
|
|
41
68
|
declare const AnsyrProvider: React__default.FC<Props>;
|
|
42
69
|
|
|
@@ -183,7 +210,7 @@ declare const useCuekit: (options?: {
|
|
|
183
210
|
sendScreenStatus: typeof sendScreenStatus;
|
|
184
211
|
sendUserCommand: typeof sendUserCommand;
|
|
185
212
|
sendStaticData: typeof sendStaticData;
|
|
186
|
-
audioContainerRef: React.RefObject<HTMLDivElement>;
|
|
213
|
+
audioContainerRef: React.RefObject<HTMLDivElement | null>;
|
|
187
214
|
};
|
|
188
215
|
|
|
189
216
|
interface Position {
|
|
@@ -246,6 +273,8 @@ interface ChatPopupProps {
|
|
|
246
273
|
persistPosition?: boolean;
|
|
247
274
|
persistSize?: boolean;
|
|
248
275
|
storageKey?: string;
|
|
276
|
+
theme?: ThemeConfig;
|
|
277
|
+
emptyStateMessage?: string;
|
|
249
278
|
}
|
|
250
279
|
declare const ChatPopup: React__default.FC<ChatPopupProps>;
|
|
251
280
|
|
|
@@ -332,7 +361,7 @@ declare const useWebRTC: (options?: {
|
|
|
332
361
|
sendScreenStatus: typeof sendScreenStatus;
|
|
333
362
|
sendUserCommand: typeof sendUserCommand;
|
|
334
363
|
sendStaticData: typeof sendStaticData;
|
|
335
|
-
audioContainerRef: React.RefObject<HTMLDivElement>;
|
|
364
|
+
audioContainerRef: React.RefObject<HTMLDivElement | null>;
|
|
336
365
|
};
|
|
337
366
|
|
|
338
367
|
interface WebRTCServerConfig {
|
|
@@ -364,13 +393,6 @@ declare const initWebRTCWithDeployedBackend: (apiKey: string, customConfig?: Par
|
|
|
364
393
|
*/
|
|
365
394
|
declare const initWebRTC: (apiKey: string) => WebRTCServerConfig;
|
|
366
395
|
|
|
367
|
-
type InteractiveElement = {
|
|
368
|
-
[btnId: string]: string[];
|
|
369
|
-
};
|
|
370
|
-
interface DOMStructurePayload {
|
|
371
|
-
components: InteractiveElement;
|
|
372
|
-
}
|
|
373
|
-
|
|
374
396
|
interface ElementAction {
|
|
375
397
|
action_type: 'click' | 'navigate' | 'input' | 'focus' | 'toggle';
|
|
376
398
|
target_element?: string;
|
|
@@ -419,4 +441,4 @@ declare function getCurrentPathParams(): Record<string, string>;
|
|
|
419
441
|
*/
|
|
420
442
|
declare function resolveRoutePath(routePath: string, params: Record<string, string>): string;
|
|
421
443
|
|
|
422
|
-
export { AnsyrProvider, BorderGlow, type Bounds, ChatPopup, type ChatPopupProps, type Props as CuekitProviderProps, type DOMStructurePayload, DraggableResizableContainer, type DraggableResizableContainerProps, type ElementAction, InitCuekit, type InteractiveElement, type Language, LanguageSelector, type LanguageSelectorProps, MicButton, type MicButtonProps, type MicState$1 as MicState, type MuteState, type NavigationCommand, type Position, type ResizeDirection, ResizeHandle, type ResizeHandleProps, ResizeHandles, type ResizeHandlesProps, type ServerConfig, type Size, type TokenRequest, type TokenResponse, VoiceIntensityVisualizer, type WebRTCServerConfig, captureAllInteractiveElements, clearElementCache, configureWebRTCServer, executeAction, generateDynamicId, getCurrentPathParams, getWebRTCServerConfig, initWebRTC, initWebRTCWithDeployedBackend, resolveRoutePath, useAnsyrContext, useCuekit, useDraggableResizableContainer, useWebRTC, validateDynamicElements };
|
|
444
|
+
export { AnsyrProvider, BorderGlow, type Bounds, ChatPopup, type ChatPopupProps, type Props as CuekitProviderProps, type DOMStructurePayload, DraggableResizableContainer, type DraggableResizableContainerProps, type ElementAction, InitCuekit, type InteractiveElement, type Language, LanguageSelector, type LanguageSelectorProps, MicButton, type MicButtonProps, type MicState$1 as MicState, type MuteState, type NavigationCommand, type Position, type ResizeDirection, ResizeHandle, type ResizeHandleProps, ResizeHandles, type ResizeHandlesProps, type ServerConfig, type Size, type ThemeColors, type ThemeConfig, type TokenRequest, type TokenResponse, VoiceIntensityVisualizer, type WebRTCServerConfig, captureAllInteractiveElements, clearElementCache, configureWebRTCServer, executeAction, generateDynamicId, getCurrentPathParams, getWebRTCServerConfig, initWebRTC, initWebRTCWithDeployedBackend, resolveRoutePath, useAnsyrContext, useCuekit, useDraggableResizableContainer, useWebRTC, validateDynamicElements };
|
package/dist/index.d.ts
CHANGED
|
@@ -3,6 +3,29 @@ import React__default, { ReactNode } from 'react';
|
|
|
3
3
|
import * as livekit_client from 'livekit-client';
|
|
4
4
|
import { ConnectionState, Room } from 'livekit-client';
|
|
5
5
|
|
|
6
|
+
type InteractiveElement = {
|
|
7
|
+
[btnId: string]: string[];
|
|
8
|
+
};
|
|
9
|
+
interface DOMStructurePayload {
|
|
10
|
+
components: InteractiveElement;
|
|
11
|
+
}
|
|
12
|
+
interface ThemeColors {
|
|
13
|
+
primary: string;
|
|
14
|
+
background: string;
|
|
15
|
+
text: string;
|
|
16
|
+
surface?: string;
|
|
17
|
+
border?: string;
|
|
18
|
+
textMuted?: string;
|
|
19
|
+
userBubble?: string;
|
|
20
|
+
userText?: string;
|
|
21
|
+
aiBubble?: string;
|
|
22
|
+
aiText?: string;
|
|
23
|
+
}
|
|
24
|
+
interface ThemeConfig {
|
|
25
|
+
light: ThemeColors;
|
|
26
|
+
dark: ThemeColors;
|
|
27
|
+
}
|
|
28
|
+
|
|
6
29
|
declare global {
|
|
7
30
|
interface AnsyrGlobalStore {
|
|
8
31
|
intent: string | null;
|
|
@@ -22,6 +45,8 @@ type AnsyrCtx = {
|
|
|
22
45
|
showLogo: boolean;
|
|
23
46
|
showAIIcon: boolean;
|
|
24
47
|
showUserIcon: boolean;
|
|
48
|
+
theme?: ThemeConfig;
|
|
49
|
+
emptyStateMessage?: string;
|
|
25
50
|
};
|
|
26
51
|
declare const useAnsyrContext: () => AnsyrCtx;
|
|
27
52
|
interface Props {
|
|
@@ -37,6 +62,8 @@ interface Props {
|
|
|
37
62
|
showLogo?: boolean;
|
|
38
63
|
showAIIcon?: boolean;
|
|
39
64
|
showUserIcon?: boolean;
|
|
65
|
+
theme: ThemeConfig;
|
|
66
|
+
emptyStateMessage?: string;
|
|
40
67
|
}
|
|
41
68
|
declare const AnsyrProvider: React__default.FC<Props>;
|
|
42
69
|
|
|
@@ -183,7 +210,7 @@ declare const useCuekit: (options?: {
|
|
|
183
210
|
sendScreenStatus: typeof sendScreenStatus;
|
|
184
211
|
sendUserCommand: typeof sendUserCommand;
|
|
185
212
|
sendStaticData: typeof sendStaticData;
|
|
186
|
-
audioContainerRef: React.RefObject<HTMLDivElement>;
|
|
213
|
+
audioContainerRef: React.RefObject<HTMLDivElement | null>;
|
|
187
214
|
};
|
|
188
215
|
|
|
189
216
|
interface Position {
|
|
@@ -246,6 +273,8 @@ interface ChatPopupProps {
|
|
|
246
273
|
persistPosition?: boolean;
|
|
247
274
|
persistSize?: boolean;
|
|
248
275
|
storageKey?: string;
|
|
276
|
+
theme?: ThemeConfig;
|
|
277
|
+
emptyStateMessage?: string;
|
|
249
278
|
}
|
|
250
279
|
declare const ChatPopup: React__default.FC<ChatPopupProps>;
|
|
251
280
|
|
|
@@ -332,7 +361,7 @@ declare const useWebRTC: (options?: {
|
|
|
332
361
|
sendScreenStatus: typeof sendScreenStatus;
|
|
333
362
|
sendUserCommand: typeof sendUserCommand;
|
|
334
363
|
sendStaticData: typeof sendStaticData;
|
|
335
|
-
audioContainerRef: React.RefObject<HTMLDivElement>;
|
|
364
|
+
audioContainerRef: React.RefObject<HTMLDivElement | null>;
|
|
336
365
|
};
|
|
337
366
|
|
|
338
367
|
interface WebRTCServerConfig {
|
|
@@ -364,13 +393,6 @@ declare const initWebRTCWithDeployedBackend: (apiKey: string, customConfig?: Par
|
|
|
364
393
|
*/
|
|
365
394
|
declare const initWebRTC: (apiKey: string) => WebRTCServerConfig;
|
|
366
395
|
|
|
367
|
-
type InteractiveElement = {
|
|
368
|
-
[btnId: string]: string[];
|
|
369
|
-
};
|
|
370
|
-
interface DOMStructurePayload {
|
|
371
|
-
components: InteractiveElement;
|
|
372
|
-
}
|
|
373
|
-
|
|
374
396
|
interface ElementAction {
|
|
375
397
|
action_type: 'click' | 'navigate' | 'input' | 'focus' | 'toggle';
|
|
376
398
|
target_element?: string;
|
|
@@ -419,4 +441,4 @@ declare function getCurrentPathParams(): Record<string, string>;
|
|
|
419
441
|
*/
|
|
420
442
|
declare function resolveRoutePath(routePath: string, params: Record<string, string>): string;
|
|
421
443
|
|
|
422
|
-
export { AnsyrProvider, BorderGlow, type Bounds, ChatPopup, type ChatPopupProps, type Props as CuekitProviderProps, type DOMStructurePayload, DraggableResizableContainer, type DraggableResizableContainerProps, type ElementAction, InitCuekit, type InteractiveElement, type Language, LanguageSelector, type LanguageSelectorProps, MicButton, type MicButtonProps, type MicState$1 as MicState, type MuteState, type NavigationCommand, type Position, type ResizeDirection, ResizeHandle, type ResizeHandleProps, ResizeHandles, type ResizeHandlesProps, type ServerConfig, type Size, type TokenRequest, type TokenResponse, VoiceIntensityVisualizer, type WebRTCServerConfig, captureAllInteractiveElements, clearElementCache, configureWebRTCServer, executeAction, generateDynamicId, getCurrentPathParams, getWebRTCServerConfig, initWebRTC, initWebRTCWithDeployedBackend, resolveRoutePath, useAnsyrContext, useCuekit, useDraggableResizableContainer, useWebRTC, validateDynamicElements };
|
|
444
|
+
export { AnsyrProvider, BorderGlow, type Bounds, ChatPopup, type ChatPopupProps, type Props as CuekitProviderProps, type DOMStructurePayload, DraggableResizableContainer, type DraggableResizableContainerProps, type ElementAction, InitCuekit, type InteractiveElement, type Language, LanguageSelector, type LanguageSelectorProps, MicButton, type MicButtonProps, type MicState$1 as MicState, type MuteState, type NavigationCommand, type Position, type ResizeDirection, ResizeHandle, type ResizeHandleProps, ResizeHandles, type ResizeHandlesProps, type ServerConfig, type Size, type ThemeColors, type ThemeConfig, type TokenRequest, type TokenResponse, VoiceIntensityVisualizer, type WebRTCServerConfig, captureAllInteractiveElements, clearElementCache, configureWebRTCServer, executeAction, generateDynamicId, getCurrentPathParams, getWebRTCServerConfig, initWebRTC, initWebRTCWithDeployedBackend, resolveRoutePath, useAnsyrContext, useCuekit, useDraggableResizableContainer, useWebRTC, validateDynamicElements };
|