diff --git a/plugins/support-resources/src/support.ts b/plugins/support-resources/src/support.ts index f375d5ea4f..972ffa4674 100644 --- a/plugins/support-resources/src/support.ts +++ b/plugins/support-resources/src/support.ts @@ -79,15 +79,15 @@ class SupportClientImpl implements SupportClient { } async showWidget (): Promise { - await this.getWidget().then((widget) => widget.showWidget()) + await this.getWidget().then(async (widget) => await widget.showWidget()) } async hideWidget (): Promise { - this.widget?.hideWidget() + await this.widget?.hideWidget() } async toggleWidget (): Promise { - await this.getWidget().then((widget) => widget.toggleWidget()) + await this.getWidget().then(async (widget) => await widget.toggleWidget()) } private updateWidgetConfig (config: SupportWidgetConfig): void { diff --git a/plugins/support/src/types.ts b/plugins/support/src/types.ts index fc2de19554..2e27848e3b 100644 --- a/plugins/support/src/types.ts +++ b/plugins/support/src/types.ts @@ -48,9 +48,9 @@ export interface SupportClient { export interface SupportWidget { configure: (config: SupportWidgetConfig) => void - showWidget: () => void - hideWidget: () => void - toggleWidget: () => void + showWidget: () => Promise + hideWidget: () => Promise + toggleWidget: () => Promise destroy: () => void }