@nlxai/touchpoint-ui 1.0.5-alpha.1 → 1.0.5-alpha.2
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/docs/.nojekyll +1 -0
- package/docs/README.md +341 -0
- package/docs/interfaces/CustomCardProps.md +47 -0
- package/docs/interfaces/CustomCardRowProps.md +39 -0
- package/docs/interfaces/DateInputProps.md +29 -0
- package/docs/interfaces/IconButtonProps.md +71 -0
- package/docs/interfaces/Icons.IconProps.md +29 -0
- package/docs/interfaces/TextButtonProps.md +72 -0
- package/docs/interfaces/Theme.md +303 -0
- package/docs/interfaces/TouchpointConfiguration.md +89 -0
- package/docs/interfaces/TouchpointInstance.md +47 -0
- package/docs/modules/Icons.md +857 -0
- package/index.html +1 -0
- package/lib/App.d.ts +2 -1
- package/lib/components/Input.d.ts +1 -0
- package/lib/components/ui/IconButton.d.ts +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +21835 -6360
- package/lib/index.umd.js +113 -76
- package/lib/types.d.ts +15 -1
- package/lib/voice.d.ts +11 -0
- package/package.json +4 -3
package/lib/types.d.ts
CHANGED
|
@@ -27,7 +27,7 @@ export interface ChoiceMessage {
|
|
|
27
27
|
}
|
|
28
28
|
/**
|
|
29
29
|
* Custom Modalities allow rendering of rich components from nodes.
|
|
30
|
-
* See: https://docs.studio.nlx.ai/
|
|
30
|
+
* See: https://docs.studio.nlx.ai/build/resources/modalities
|
|
31
31
|
*/
|
|
32
32
|
export type CustomModalityComponent<Data> = FC<{
|
|
33
33
|
/**
|
|
@@ -150,6 +150,11 @@ export interface Theme {
|
|
|
150
150
|
*/
|
|
151
151
|
outerBorderRadius: string;
|
|
152
152
|
}
|
|
153
|
+
/**
|
|
154
|
+
* Custom conversation init method. Defaults to sending the welcome intent
|
|
155
|
+
* @param handler - the conversation handler.
|
|
156
|
+
*/
|
|
157
|
+
export type InitializeConversation = (handler: ConversationHandler) => void;
|
|
153
158
|
/**
|
|
154
159
|
* Main Touchpoint creation properties object
|
|
155
160
|
*/
|
|
@@ -184,4 +189,13 @@ export interface TouchpointConfiguration {
|
|
|
184
189
|
* Optional custom modality components to render in Touchpoint
|
|
185
190
|
*/
|
|
186
191
|
customModalities?: Record<string, CustomModalityComponent<any>>;
|
|
192
|
+
/**
|
|
193
|
+
* Custom conversation init method. Defaults to sending the welcome intent
|
|
194
|
+
* @param handler - the conversation handler.
|
|
195
|
+
*/
|
|
196
|
+
initializeConversation?: InitializeConversation;
|
|
197
|
+
/**
|
|
198
|
+
* Controls the ways in which the user can communicate with the application. Defaults to `"text"`
|
|
199
|
+
*/
|
|
200
|
+
input?: "text" | "textAndVoice";
|
|
187
201
|
}
|
package/lib/voice.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ConversationHandler } from '@nlxai/chat-core';
|
|
2
|
+
type VoiceRoomState = "inactive" | "pending" | "active" | "error";
|
|
3
|
+
interface VoiceHookReturn {
|
|
4
|
+
roomState: VoiceRoomState;
|
|
5
|
+
isUserSpeaking: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare const useVoice: ({ active, handler, }: {
|
|
8
|
+
active: boolean;
|
|
9
|
+
handler: ConversationHandler;
|
|
10
|
+
}) => VoiceHookReturn;
|
|
11
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nlxai/touchpoint-ui",
|
|
3
|
-
"version": "1.0.5-alpha.
|
|
3
|
+
"version": "1.0.5-alpha.2",
|
|
4
4
|
"description": "Web UI for Touchpoint",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -24,11 +24,12 @@
|
|
|
24
24
|
"tsc": "tsc"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@nlxai/chat-core": "^1.0.5-alpha.
|
|
27
|
+
"@nlxai/chat-core": "^1.0.5-alpha.2",
|
|
28
28
|
"@react-hookz/web": "^25.0.1",
|
|
29
29
|
"@react-input/mask": "^2.0.4",
|
|
30
30
|
"clsx": "^2.1.1",
|
|
31
31
|
"htm": "^3.1.1",
|
|
32
|
+
"livekit-client": "^2.9.9",
|
|
32
33
|
"marked": "^15.0.4",
|
|
33
34
|
"ramda": "^0.30.1",
|
|
34
35
|
"react": "^18.3.1",
|
|
@@ -56,5 +57,5 @@
|
|
|
56
57
|
"publishConfig": {
|
|
57
58
|
"access": "public"
|
|
58
59
|
},
|
|
59
|
-
"gitHead": "
|
|
60
|
+
"gitHead": "af2fea91300ecfab6c3ca8832dc3b13971ba5f46"
|
|
60
61
|
}
|