|
78 | 78 | <environment exclude="Development"> |
79 | 79 | <script type="importmap" asp-importmap="@prodMap"></script> |
80 | 80 | </environment> |
| 81 | + <!-- Cookie Consent Manager - Load before analytics --> |
| 82 | + <script src="~/js/consent-manager.js" asp-append-version="true"></script> |
| 83 | + |
| 84 | + <!-- Microsoft Clarity - Will be activated based on consent --> |
81 | 85 | <script type="text/javascript"> |
82 | 86 | (function (c, l, a, r, i, t, y) { |
83 | 87 | c[a] = c[a] || function () { (c[a].q = c[a].q || []).push(arguments) }; |
84 | 88 | t = l.createElement(r); t.async = 1; t.src = "https://www.clarity.ms/tag/" + i; |
85 | 89 | y = l.getElementsByTagName(r)[0]; y.parentNode.insertBefore(t, y); |
86 | 90 | })(window, document, "clarity", "script", "g4keetzd2o"); |
87 | 91 | </script> |
| 92 | + |
88 | 93 | <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.0/css/all.min.css"> |
89 | 94 | <!-- Markdown and sanitization libraries --> |
90 | 95 | <script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"></script> |
91 | 96 | <script src="https://cdn.jsdelivr.net/npm/dompurify@3.0.5/dist/purify.min.js"></script> |
92 | | - <!-- Google tag (gtag.js) --> |
| 97 | + |
| 98 | + <!-- Google tag (gtag.js) - Will be activated based on consent --> |
93 | 99 | <script async src="https://www.googletagmanager.com/gtag/js?id=G-761B4BMK2R"></script> |
94 | 100 | <script> |
95 | 101 | window.dataLayer = window.dataLayer || []; |
96 | 102 | function gtag() { dataLayer.push(arguments); } |
| 103 | + |
| 104 | + // Initialize gtag but don't configure until consent is given |
97 | 105 | gtag('js', new Date()); |
98 | | - gtag('config', 'G-761B4BMK2R'); |
| 106 | + |
| 107 | + // Configuration will be handled by consent manager |
| 108 | + // Listen for consent manager initialization event |
| 109 | + document.addEventListener('consentManagerReady', function(event) { |
| 110 | + if (event.detail.hasAnalyticsConsent || !event.detail.requiresConsent) { |
| 111 | + gtag('config', 'G-761B4BMK2R'); |
| 112 | + } |
| 113 | + }); |
99 | 114 | </script> |
100 | 115 | <style> |
101 | 116 | [v-cloak] { |
|
506 | 521 | <div class="col-12 col-md-auto align-self-end p-2"> |
507 | 522 | <a target="_blank" rel="noreferrer noopener" href="https://intellitect.com/about/privacy-policy/">Privacy</a> |
508 | 523 | </div> |
| 524 | + <div class="col-12 col-md-auto align-self-end p-2"> |
| 525 | + <a href="javascript:void(0)" onclick="openConsentPreferences()">Cookie Preferences</a> |
| 526 | + </div> |
509 | 527 | <div class="col-12 col-md-auto align-self-end p-2"><a asp-route="TermsOfService">Terms Of Service</a></div> |
510 | 528 | </div> |
511 | 529 | </footer> |
|
0 commit comments