Commit 3cfec37e by heheer Committed by GitHub

fix embed chatbot default open (#3774)

parent d3641c87
...@@ -114,7 +114,6 @@ function embedChatbot() { ...@@ -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() { ...@@ -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);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment