From Bright Pattern Documentation
< 5.19:AgentDesktop-client-side-javascript-api-specification
Revision as of 04:01, 29 May 2024 by BpDeeplTranslateMaintenance (talk | contribs) (Updated via BpDeleteTranslateTags script)
• 5.19
onWidgetMinimizedChange
This callback is invoked when the Agent Desktop Communicator widget changes its state (i.e., it is minimized or maximized).
Request
Syntax
on('ON_WIDGET_MINIMIZED_CHANGE', handler: OnWidgetMinimizedChangeHandler): void
|
Parameters
Parameter | Parameter Values | Data Type | Optional/Required | Description |
minimized | Boolean | Required | If set to true, the widget is minimized; if set to false, the widget is maximized |
Example Request
function widgetMinimizedStateChangeCallback(isMinimized: boolean) {
if (isMinimized) {
console.log("Widget is minimized");
} else {
console.log("Widget is returned to the expanded mode");
}
}
adApi.on("ON_WIDGET_MINIMIZED_CHANGE", widgetMinimizedStateChangeCallback);
Return Value
(None)