botman / web-widget

MIT License
39 stars 69 forks source link

How do you remove the background svg #54

Closed roarkmccolgan closed 4 years ago

roarkmccolgan commented 4 years ago

Hi! Is there a way to remove the background svg in the chat window using the api?

image

Thanks!

roarkmccolgan commented 4 years ago

I just overrode the the css, thanks

Zeeshan-H commented 2 years ago

How to override the chat.css file?

Ochegbinu commented 1 year ago

How to override the chat.css file?

Just comment it out

4nd114 commented 8 months ago
$(document).on('click', '.desktop-closed-message-avatar img', function() {
    var iframe = document.getElementById("chatBotManFrame");
    iframe.addEventListener('load', function () {
        var htmlFrame = this.contentWindow.document.getElementsByTagName("html")[0];
        var bodyFrame = this.contentWindow.document.getElementsByTagName("body")[0];
        var headFrame = this.contentWindow.document.getElementsByTagName("head")[0];

        var image = "https://images.unsplash.com/photo-1501597301489-8b75b675ba0a?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=crop&w=1349&q=80"

        htmlFrame.style.backgroundImage = "url("+image+")";
        bodyFrame.style.backgroundImage = "url("+image+")";
    });
});
4nd114 commented 8 months ago

For mobile update .desktop-closed-message-avatar img to .mobile-closed-message-avatar img