Skip to content

Commit

Permalink
Merge pull request #171 from moiz-deriv/moiz/update-livechat-wrapper-…
Browse files Browse the repository at this point in the history
…prime

fix: updated style of livechat wrapper when whatsapp is removed
  • Loading branch information
moiz-deriv authored Oct 9, 2024
2 parents a815c43 + 7ef2c10 commit 7d4e0a7
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 7d4e0a7

Please sign in to comment.