@voxket-ai/voxket-live 1.0.35 → 1.0.37
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/chat-view.d.ts +13 -0
- package/dist/components/compound/index.d.ts +11 -0
- package/dist/components/compound/session-content.d.ts +8 -0
- package/dist/components/compound/session-controls.d.ts +10 -0
- package/dist/components/compound/session-footer.d.ts +9 -0
- package/dist/components/compound/session-header.d.ts +11 -0
- package/dist/components/compound/types.d.ts +28 -0
- package/dist/components/compound/voxket-session.d.ts +12 -0
- package/dist/components/interactive-component.d.ts +11 -0
- package/dist/components/livekit/agent-control-bar/agent-control-bar.d.ts +2 -1
- package/dist/components/livekit/agent-control-bar/hooks/use-agent-control-bar.d.ts +17 -4
- package/dist/components/livekit/agent-control-bar/hooks/use-publish-permissions.d.ts +1 -1
- package/dist/components/livekit/device-select.d.ts +2 -1
- package/dist/components/livekit/track-toggle.d.ts +2 -2
- package/dist/components/session-view.d.ts +5 -1
- package/dist/components/video/index.d.ts +8 -0
- package/dist/components/video/video-controls.d.ts +2 -0
- package/dist/components/video/video-grid.d.ts +2 -0
- package/dist/components/video/video-tile.d.ts +2 -0
- package/dist/components/video-view.d.ts +13 -0
- package/dist/components/welcome.d.ts +5 -1
- package/dist/components/widget.d.ts +11 -0
- package/dist/core/client.d.ts +187 -0
- package/dist/core/event-emitter.d.ts +35 -0
- package/dist/core/index.d.ts +9 -0
- package/dist/core/rpc-manager.d.ts +46 -0
- package/dist/core/sdk.d.ts +0 -0
- package/dist/examples/agent-rpc-example.d.ts +38 -0
- package/dist/examples/assignment-view.d.ts +11 -0
- package/dist/examples/refactored-usage-examples.d.ts +0 -0
- package/dist/examples/rpc-examples.d.ts +5 -0
- package/dist/hooks/sdk/index.d.ts +10 -0
- package/dist/hooks/sdk/use-chat.d.ts +24 -0
- package/dist/hooks/sdk/use-connection.d.ts +24 -0
- package/dist/hooks/sdk/use-media.d.ts +33 -0
- package/dist/hooks/sdk/use-session.d.ts +26 -0
- package/dist/hooks/sdk/use-video.d.ts +2 -0
- package/dist/hooks/useVoxketClient.d.ts +59 -0
- package/dist/index.cjs +394 -132
- package/dist/index.css +1 -1
- package/dist/index.d.ts +19 -3
- package/dist/index.js +46236 -33965
- package/dist/plugins/index.d.ts +7 -0
- package/dist/plugins/modalities/chat-plugin.d.ts +31 -0
- package/dist/plugins/modalities/voice-plugin.d.ts +8 -0
- package/dist/plugins/plugin-system.d.ts +64 -0
- package/dist/providers/voxket-provider.d.ts +33 -0
- package/dist/styles.d.ts +36 -1
- package/dist/themes/index.d.ts +5 -0
- package/dist/themes/theme-system.d.ts +89 -0
- package/dist/types/chat.d.ts +0 -0
- package/dist/types/client.d.ts +0 -0
- package/dist/types/connection.d.ts +0 -0
- package/dist/types/core.d.ts +186 -0
- package/dist/types/events.d.ts +0 -0
- package/dist/types/media.d.ts +0 -0
- package/dist/types/recording.d.ts +0 -0
- package/dist/types/rpc.d.ts +143 -0
- package/dist/types/session.d.ts +0 -0
- package/dist/types/ui.d.ts +0 -0
- package/dist/types/video.d.ts +92 -0
- package/package.json +19 -9
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Voxket SDK Hooks
|
|
3
|
+
* Re-exports all hooks for easy importing
|
|
4
|
+
*/
|
|
5
|
+
export { useVoxketSession, useVoxketMetrics } from './use-session';
|
|
6
|
+
export { useVoxketMicrophone, useVoxketCamera, useVoxketScreenShare } from './use-media';
|
|
7
|
+
export { useVoxketVideo } from './use-video';
|
|
8
|
+
export { useVoxketChat, useVoxketChatInput } from './use-chat';
|
|
9
|
+
export { useVoxketConnection, useVoxketParticipants } from './use-connection';
|
|
10
|
+
export { useVoxket } from '../../providers/voxket-provider';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ChatMessage } from '../../types/core';
|
|
2
|
+
/**
|
|
3
|
+
* Hook for chat functionality
|
|
4
|
+
*/
|
|
5
|
+
export declare function useVoxketChat(): {
|
|
6
|
+
messages: ChatMessage[];
|
|
7
|
+
userMessages: ChatMessage[];
|
|
8
|
+
agentMessages: ChatMessage[];
|
|
9
|
+
messageCount: number;
|
|
10
|
+
isSending: boolean;
|
|
11
|
+
canSend: boolean;
|
|
12
|
+
send: (message: string) => Promise<void>;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Hook for chat input with common functionality
|
|
16
|
+
*/
|
|
17
|
+
export declare function useVoxketChatInput(): {
|
|
18
|
+
value: string;
|
|
19
|
+
setValue: import('react').Dispatch<import('react').SetStateAction<string>>;
|
|
20
|
+
send: () => Promise<void>;
|
|
21
|
+
handleKeyPress: (event: React.KeyboardEvent) => void;
|
|
22
|
+
isSending: boolean;
|
|
23
|
+
canSend: boolean;
|
|
24
|
+
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Connection management hooks for Voxket SDK
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Hook for connection management
|
|
6
|
+
*/
|
|
7
|
+
export declare function useVoxketConnection(): {
|
|
8
|
+
isConnected: boolean;
|
|
9
|
+
isConnecting: boolean;
|
|
10
|
+
isDisconnected: boolean;
|
|
11
|
+
error: import('../..').VoxketError | null;
|
|
12
|
+
hasError: boolean;
|
|
13
|
+
connect: () => Promise<void>;
|
|
14
|
+
disconnect: () => Promise<void>;
|
|
15
|
+
};
|
|
16
|
+
/**
|
|
17
|
+
* Hook for participants management
|
|
18
|
+
*/
|
|
19
|
+
export declare function useVoxketParticipants(): {
|
|
20
|
+
participants: import('../..').ParticipantInfo[];
|
|
21
|
+
count: number;
|
|
22
|
+
localParticipant: import('../..').ParticipantInfo | undefined;
|
|
23
|
+
remoteParticipants: import('../..').ParticipantInfo[];
|
|
24
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Media control hooks for Voxket SDK
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Hook for microphone control
|
|
6
|
+
*/
|
|
7
|
+
export declare function useVoxketMicrophone(): {
|
|
8
|
+
isEnabled: boolean;
|
|
9
|
+
isLoading: boolean;
|
|
10
|
+
toggle: () => Promise<void>;
|
|
11
|
+
enable: () => Promise<void>;
|
|
12
|
+
disable: () => Promise<void>;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Hook for camera control
|
|
16
|
+
*/
|
|
17
|
+
export declare function useVoxketCamera(): {
|
|
18
|
+
isEnabled: boolean;
|
|
19
|
+
isLoading: boolean;
|
|
20
|
+
toggle: () => Promise<void>;
|
|
21
|
+
enable: () => Promise<void>;
|
|
22
|
+
disable: () => Promise<void>;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Hook for screen sharing control
|
|
26
|
+
*/
|
|
27
|
+
export declare function useVoxketScreenShare(): {
|
|
28
|
+
isSharing: boolean;
|
|
29
|
+
isLoading: boolean;
|
|
30
|
+
start: () => Promise<void>;
|
|
31
|
+
stop: () => Promise<void>;
|
|
32
|
+
toggle: () => Promise<void>;
|
|
33
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { SessionConfig, SessionMetrics } from '../../types/core';
|
|
2
|
+
/**
|
|
3
|
+
* Hook for session management
|
|
4
|
+
*/
|
|
5
|
+
export declare function useVoxketSession(): {
|
|
6
|
+
session: import('../../types/core').VoxketSession | null;
|
|
7
|
+
state: import('../../types/core').SessionState;
|
|
8
|
+
metrics: SessionMetrics | null;
|
|
9
|
+
isActive: boolean;
|
|
10
|
+
isConnecting: boolean;
|
|
11
|
+
isConnected: boolean;
|
|
12
|
+
start: (agentId: string, options?: Partial<SessionConfig>) => Promise<import('../../types/core').VoxketSession>;
|
|
13
|
+
stop: () => Promise<SessionMetrics | null>;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Hook for session metrics and analytics
|
|
17
|
+
*/
|
|
18
|
+
export declare function useVoxketMetrics(): {
|
|
19
|
+
metrics: SessionMetrics | null;
|
|
20
|
+
sessionId: string | undefined;
|
|
21
|
+
duration: number | undefined;
|
|
22
|
+
participantCount: number | undefined;
|
|
23
|
+
messageCount: number | undefined;
|
|
24
|
+
audioQuality: import('../../types/core').QualityMetrics | undefined;
|
|
25
|
+
networkStats: import('../../types/core').NetworkStats | undefined;
|
|
26
|
+
};
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { VoxketClient } from '../core/client';
|
|
2
|
+
export interface UseVoxketClientProps {
|
|
3
|
+
client: VoxketClient;
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Hook to get publish permissions
|
|
7
|
+
* Replaces usePublishPermissions from LiveKit
|
|
8
|
+
*/
|
|
9
|
+
export declare function useVoxketPublishPermissions(client: VoxketClient): {
|
|
10
|
+
camera: boolean;
|
|
11
|
+
microphone: boolean;
|
|
12
|
+
screenShare: boolean;
|
|
13
|
+
data: boolean;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Hook to get local participant
|
|
17
|
+
* Replaces useLocalParticipant from LiveKit
|
|
18
|
+
*/
|
|
19
|
+
export declare function useVoxketLocalParticipant(client: VoxketClient): {
|
|
20
|
+
localParticipant: import('livekit-client').LocalParticipant | null;
|
|
21
|
+
microphoneTrack: import('livekit-client').LocalTrack<import("livekit-client").Track.Kind> | null | undefined;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Hook for track toggle functionality
|
|
25
|
+
* Replaces useTrackToggle from LiveKit
|
|
26
|
+
*/
|
|
27
|
+
export declare function useVoxketTrackToggle(client: VoxketClient, source: 'microphone' | 'camera' | 'screenShare', options?: {
|
|
28
|
+
onDeviceError?: (error: Error) => void;
|
|
29
|
+
}): {
|
|
30
|
+
enabled: boolean;
|
|
31
|
+
pending: boolean;
|
|
32
|
+
toggle: (forceEnabled?: boolean) => Promise<void>;
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* Hook for room context
|
|
36
|
+
* Replaces useRoomContext from LiveKit
|
|
37
|
+
*/
|
|
38
|
+
export declare function useVoxketRoom(client: VoxketClient): import('livekit-client').Room | null;
|
|
39
|
+
/**
|
|
40
|
+
* Hook for device selection
|
|
41
|
+
* Replaces useMediaDeviceSelect from LiveKit
|
|
42
|
+
*/
|
|
43
|
+
export declare function useVoxketMediaDeviceSelect(client: VoxketClient, kind: 'audioinput' | 'videoinput'): {
|
|
44
|
+
devices: MediaDeviceInfo[];
|
|
45
|
+
activeDeviceId: string;
|
|
46
|
+
setActiveMediaDevice: (deviceId: string) => Promise<void>;
|
|
47
|
+
};
|
|
48
|
+
/**
|
|
49
|
+
* Hook for persistent user choices
|
|
50
|
+
* Replaces usePersistentUserChoices from LiveKit
|
|
51
|
+
*/
|
|
52
|
+
export declare function useVoxketPersistentUserChoices(options?: {
|
|
53
|
+
preventSave?: boolean;
|
|
54
|
+
}): {
|
|
55
|
+
saveAudioInputEnabled: (enabled: boolean) => void;
|
|
56
|
+
saveAudioInputDeviceId: (deviceId: string) => void;
|
|
57
|
+
saveVideoInputEnabled: (enabled: boolean) => void;
|
|
58
|
+
saveVideoInputDeviceId: (deviceId: string) => void;
|
|
59
|
+
};
|