@alan-ai/alan-sdk-web
Version:
Alan Web SDK: a lightweight JavaScript library for adding a voice experience to your website or web application
41 lines • 1.24 kB
TypeScript
export interface AlanButtonOptions {
key: string;
rootEl?: HTMLElement | undefined;
chatEl?: HTMLElement | undefined;
right?: number | string;
bottom?: number | string;
left?: number | string;
top?: number | string;
position?: string;
pinned?: boolean;
keepDialogSession?: boolean;
showOverlayOnMicPermissionPrompt?: boolean;
zIndex?: number;
host?: string;
mode?: 'inlined' | 'docked-left' | 'docked-right' | undefined;
onCommand?: (commandData: object) => void;
onEvent?: (event: object) => void;
onButtonState?: (state: string) => void;
onConnectionStatus?: (status: string, event: object) => void;
textChat?: {
closeDelay?: number;
showBtnIfChatOpen?: boolean;
openByDefault?: boolean;
onClose?: () => void;
onMinimize?: () => void;
onOpen?: () => void;
headerElement?: HTMLDivElement;
footerInfoElement?: HTMLDivElement;
resources?: {
css?: string[];
};
markdownStyles?: {
mode?: 'default' | 'custom';
},
timestampFormat?: {
today: string;
yesterday: string;
other: string;
}
}
}