-
Notifications
You must be signed in to change notification settings - Fork 1
/
options.ts
46 lines (43 loc) · 998 Bytes
/
options.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import type { LangType } from "../locales";
import type { ComponentType } from "./components";
export type UserObject = {
external_id?: string;
name?: string;
email?: string;
phone?: string;
customData?: Record<string, string>;
avatarUrl?: string;
};
export interface WidgetThemeOptions {
primaryColor: string;
triggerOffset: string;
}
export type WidgetOptions = {
token: string;
headers?: Record<string, string>;
queryParams?: Record<string, string>;
pathParams?: Record<string, string>;
initialMessages: string[];
apiUrl?: string;
theme?: Partial<WidgetThemeOptions>;
settings?: {
persistSession?: boolean;
useSoundEffects?: boolean;
};
collectUserData?: boolean;
soundEffectFiles?: {
messageArrived?: string;
};
socketUrl?: string;
debug?: boolean;
language?: LangType;
user?: UserObject;
assets?: {
organizationLogo?: string;
};
bot?: {
name?: string;
avatarUrl?: string;
};
components?: ComponentType[];
};