/************************************************************************** * IMPORTS ***************************************************************************/ import { CrispClass as Crisp } from "./index"; /************************************************************************** * CLASS ***************************************************************************/ /** * Crisp chat management */ export default class CrispChat { private parent; /** * Constructor */ constructor(crisp: Crisp); /** * Shows the chat widget */ show(): void; /** * Hides the chat widget */ hide(): void; /** * Opens the chat widget */ open(): void; /** * Closes the chat widget */ close(): void; /** * Sets an overlay view with a custom callback */ setOverlayView(callback: () => void): void; /** * Sets the helpdesk view */ setHelpdeskView(): void; /** * Opens a helpdesk article */ openHelpdeskArticle(locale: string, slug: string, title?: string, category?: string): void; /** * Queries the helpdesk */ queryHelpdesk(query: string): void; /** * Gets the unread message count */ unreadCount(): number; /** * Checks if the chat is opened */ isChatOpened(): boolean; /** * Checks if the chat is visible */ isVisible(): boolean; /** * Registers a callback for chat initiated event */ onChatInitiated(callback: () => void): void; /** * Unregisters the chat initiated callback */ offChatInitiated(): void; /** * Registers a callback for chat opened event */ onChatOpened(callback: () => void): void; /** * Unregisters the chat opened callback */ offChatOpened(): void; /** * Registers a callback for chat closed event */ onChatClosed(callback: () => void): void; /** * Unregisters the chat closed callback */ offChatClosed(): void; /** * Registers a callback for helpdesk queried event */ onHelpdeskQueried(callback: Function): void; /** * Unregisters the helpdesk queried callback */ offHelpdeskQueried(): void; }