fix embed chatbot default open (#3774)
This commit is contained in:
parent
d3641c877c
commit
3cfec37e9d
@ -114,7 +114,6 @@ function embedChatbot() {
|
|||||||
if (!chatWindow) return;
|
if (!chatWindow) return;
|
||||||
const visibilityVal = chatWindow.style.visibility;
|
const visibilityVal = chatWindow.style.visibility;
|
||||||
if (visibilityVal === 'hidden') {
|
if (visibilityVal === 'hidden') {
|
||||||
updateChatWindowPosition();
|
|
||||||
chatWindow.style.visibility = 'unset';
|
chatWindow.style.visibility = 'unset';
|
||||||
ChatBtnDiv.src = CloseIcon;
|
ChatBtnDiv.src = CloseIcon;
|
||||||
} else {
|
} else {
|
||||||
@ -157,5 +156,6 @@ function embedChatbot() {
|
|||||||
|
|
||||||
ChatBtn.appendChild(ChatBtnDiv);
|
ChatBtn.appendChild(ChatBtnDiv);
|
||||||
document.body.appendChild(ChatBtn);
|
document.body.appendChild(ChatBtn);
|
||||||
|
updateChatWindowPosition();
|
||||||
}
|
}
|
||||||
window.addEventListener('load', embedChatbot);
|
window.addEventListener('load', embedChatbot);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user