Skip to content

Commit

Permalink
fix: updated style of livechat wrapper when whatsapp is removed
Browse files Browse the repository at this point in the history
  • Loading branch information
moiz-deriv committed Oct 9, 2024
1 parent a815c43 commit 7ef2c10
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/js/footer/liveChatFeatureFlag/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ let is_whatapp_visible = false;

function fetchChatData() {
const liveChatWrapper = document.getElementById("live_chat-wrapper");

try {
const dataRef = ref(db, "remote_config/deriv-com/chat");
onValue(
Expand Down Expand Up @@ -34,6 +35,7 @@ function fetchChatData() {
const isPrime = window.location.pathname.includes("/deriv-prime");

if (isPrime) {
liveChatWrapper.style.flexDirection = "column-reverse";
const whatappChatBtns = document.querySelectorAll(".whatsapp_chat");
whatappChatBtns.forEach((btn) => {
btn.style.visibility = "hidden";
Expand Down

0 comments on commit 7ef2c10

Please sign in to comment.