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AC,oCAAiD,OAAbF,EAAEG,QAAQ,IAC5D,CACA,OAAO,CACT,EAAC","sources":["webpack://_N_E/?e87f","webpack://_N_E/./src/helpers/GoogleTag.js","webpack://_N_E/./src/components/ConsentDialog/index.jsx","webpack://_N_E/./src/providers/ConsoleErrorLoggerProvider.jsx","webpack://_N_E/./src/providers/DowndorProvider.jsx","webpack://_N_E/./src/providers/I18nProvider.jsx","webpack://_N_E/./src/providers/ReactQuery.jsx","webpack://_N_E/./src/assets/main.css","webpack://_N_E/./src/constants/general.js","webpack://_N_E/./src/helpers/Clarity.js"],"sourcesContent":["import(/* webpackMode: \"eager\", webpackExports: [\"default\"] */ \"/codebuild/output/src1503684179/src/downfor-webapp/node_modules/@ant-design/nextjs-registry/es/AntdRegistry.js\");\n;\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src1503684179/src/downfor-webapp/node_modules/next/font/google/target.css?{\\\"path\\\":\\\"src/app/layout.js\\\",\\\"import\\\":\\\"Roboto\\\",\\\"arguments\\\":[{\\\"weight\\\":[\\\"400\\\",\\\"700\\\"],\\\"style\\\":[\\\"normal\\\"],\\\"variable\\\":\\\"--font-roboto\\\",\\\"subsets\\\":[\\\"latin\\\"],\\\"display\\\":\\\"swap\\\"}],\\\"variableName\\\":\\\"roboto\\\"}\");\n;\nimport(/* webpackMode: \"eager\" */ \"/codebuild/output/src1503684179/src/downfor-webapp/src/assets/main.css\");\n;\nimport(/* webpackMode: \"eager\", webpackExports: [\"default\"] */ \"/codebuild/output/src1503684179/src/downfor-webapp/src/components/ConsentDialog/index.jsx\");\n;\nimport(/* webpackMode: \"eager\", webpackExports: [\"ConsoleErrorLoggerProvider\"] */ \"/codebuild/output/src1503684179/src/downfor-webapp/src/providers/ConsoleErrorLoggerProvider.jsx\");\n;\nimport(/* webpackMode: \"eager\", webpackExports: [\"default\"] */ \"/codebuild/output/src1503684179/src/downfor-webapp/src/providers/DowndorProvider.jsx\");\n;\nimport(/* webpackMode: \"eager\", webpackExports: [\"I18nProvider\"] */ \"/codebuild/output/src1503684179/src/downfor-webapp/src/providers/I18nProvider.jsx\");\n;\nimport(/* webpackMode: \"eager\", webpackExports: [\"ReactQuery\"] */ \"/codebuild/output/src1503684179/src/downfor-webapp/src/providers/ReactQuery.jsx\");\n","import { trackingID } from '@/constants/general';\n\nconst loadGoogleTagScript = () => new Promise((resolve, reject) => {\n const buildGoogleTagScript = (w, d, s, l, i) => {\n w[l] = w[l] || [];\n w[l].push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' });\n\n // Initialize gtag before loading GTM\n w.gtag = function () {\n w[l].push(arguments);\n };\n\n var f = d.getElementsByTagName(s)[0],\n j = d.createElement(s),\n dl = l !== 'dataLayer' ? '&l=' + l : '';\n j.async = true;\n j.src = 'https://www.googletagmanager.com/gtm.js?id=' + i + dl;\n f.parentNode.insertBefore(j, f);\n\n j.onload = () => resolve();\n j.onerror = () => reject(new Error('Failed to load Google Tag script'));\n };\n\n buildGoogleTagScript(window, document, 'script', 'dataLayer', trackingID);\n});\n\nexport const initGoogleTag = async () => {\n try {\n if (!window.gtag) {\n await loadGoogleTagScript();\n const awaitTimes = 10;\n let iterationCount = 0;\n\n const verifyGoogleTag = setInterval(() => {\n if (window.gtag) {\n window.gtagReady = true;\n clearInterval(verifyGoogleTag);\n // 🔹 Initialize Google Ads Conversion Tracking\n window.gtag('config', trackingID);\n } else {\n if (iterationCount === awaitTimes) {\n clearInterval(verifyGoogleTag);\n window.gtagReady = false;\n }\n }\n iterationCount += 1;\n }, 500);\n }\n return true;\n } catch (e) {\n console.log(`Error on Google Tag initialization: ${e.toString()}`);\n }\n return false;\n};\n\n\nexport default initGoogleTag;\n","\"use client\";\n\nimport { useState, useEffect } from 'react';\nimport { FormattedMessage } from \"react-intl\";\nimport Cookies from \"js-cookie\";\nimport { useSession } from \"next-auth/react\";\n\nimport { initClarity } from \"@/helpers/Clarity\";\nimport { initGoogleTag } from \"@/helpers/GoogleTag\";\n\nconst ConsentDialog = () => {\n const { data: session } = useSession();\n const currentUser = session?.user || null;\n\n const [showDialog, setShowDialog] = useState(false);\n\n const handleAccept = () => {\n Cookies.set(\"clarityConsent\", true, {\n expires: 365,\n domain: \".downfor.life\"\n });\n initClarity();\n initGoogleTag();\n setShowDialog(false);\n };\n\n const handleDecline = () => {\n Cookies.set(\"clarityConsent\", false, {\n expires: 365,\n domain: \".downfor.life\"\n });\n setShowDialog(false);\n };\n\n useEffect(() => {\n const consentGiven = Cookies.get(\"clarityConsent\");\n\n if (!consentGiven && !currentUser) {\n setShowDialog(true);\n } else if (consentGiven === \"true\" || !!currentUser) {\n initClarity();\n initGoogleTag();\n }\n }, [currentUser]);\n\n return (\n showDialog && (\n
\n