diff --git a/tracker/tracker-assist/src/Assist.ts b/tracker/tracker-assist/src/Assist.ts index e29d6f574..0e6093edd 100644 --- a/tracker/tracker-assist/src/Assist.ts +++ b/tracker/tracker-assist/src/Assist.ts @@ -489,8 +489,9 @@ export default class Assist { } // UI + console.log(callUI) if (!callUI) { - callUI = new CallWindow(app.debug.error, this.options.callUITemplate) + callUI = new CallWindow(console.log, this.options.callUITemplate) callUI.setVideoToggleCallback(updateVideoFeed) } callUI.showControls(initiateCallEnd) @@ -539,6 +540,7 @@ export default class Assist { sessionStorage.setItem(this.options.session_calling_peer_key, JSON.stringify(callingPeerIds)) this.emit('UPDATE_SESSION', { agentIds: callingPeerIds, isCallActive: true, }) }).catch(reason => { // in case of Confirm.remove() without user answer (not a error) + console.log(reason) app.debug.log(reason) }) }) diff --git a/tracker/tracker-assist/src/CallWindow.ts b/tracker/tracker-assist/src/CallWindow.ts index aff1517f3..74c6392b1 100644 --- a/tracker/tracker-assist/src/CallWindow.ts +++ b/tracker/tracker-assist/src/CallWindow.ts @@ -54,7 +54,9 @@ export default class CallWindow { .then((text) => { iframe.onload = () => { const assistSection = doc.getElementById('or-assist') - assistSection?.classList.remove('status-connecting') + setTimeout(() => { + assistSection?.classList.remove('status-connecting') + }, 0) //iframe.style.height = doc.body.scrollHeight + 'px'; //iframe.style.width = doc.body.scrollWidth + 'px'; this.adjustIframeSize() @@ -110,6 +112,11 @@ export default class CallWindow { // TODO: save coordinates on the new page attachDND(iframe, dragArea, doc.documentElement) } + setTimeout(() => { + const assistSection = doc.getElementById('or-assist') + assistSection?.classList.remove('status-connecting') + this.adjustIframeSize() + }, 250) }) //this.toggleVideoUI(false)