Skip to content

Commit

Permalink
testing changes
Browse files Browse the repository at this point in the history
  • Loading branch information
TalBenAvi committed Mar 5, 2024
1 parent e30bb93 commit 7657726
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ const ProvisionsPopup = () => {
"isProvisionsPopupOpen",
!isSsr
);
const click = (target: string) =>
window?.dataLayer.push({ event: "click", target });

const gtmEvent = (event: string) => window?.dataLayer.push({ event });
const gtmEventClickReadMore = () => gtmEvent("Provisions_popup_click");
Expand All @@ -21,12 +23,14 @@ const ProvisionsPopup = () => {
const onClose = (event: React.MouseEvent) => {
event.stopPropagation();
gtmEventClickClose();
click("Provisions_popup_close");
setIsOpenStorage(false);
};

const onReadMore = (event: React.MouseEvent) => {
event.stopPropagation();
gtmEventClickReadMore();
click("Provisions_popup_click");
setIsOpenStorage(false);
};

Expand Down

0 comments on commit 7657726

Please sign in to comment.