Skip to content

Commit

Permalink
BB2-3390: Implement privacy modal (#386)
Browse files Browse the repository at this point in the history
* Implement privacy modal

* Improve tealium handling

* Fixed staging tealium url

* Fixed urls

* Fixed typo

* Moved to async load in body

* Add to top of body
  • Loading branch information
loganbertram authored Nov 26, 2024
1 parent 599a708 commit ec7a107
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 2 deletions.
3 changes: 3 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,6 @@ codebooks:
rda_api:
layout: rda_api_variable.html
csv_file_key: rda_api_data_dictionary

tealium_env: "development"
tealium_url: "https://tealium-tags.cms.gov/cms-bluebutton/dev/utag.sync.js"
21 changes: 21 additions & 0 deletions _includes/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,30 @@ <h6 class="ds-h4">Additional resources</h6>
<li><a href="https://www.medicare.gov/about-us/plain-writing" target="_blank">Plain Writing</a></li>
<li><a href="https://www.usa.gov/" target="_blank">USA.gov</a></li>
<li><a href="https://www.cms.gov/About-CMS/Agency-Information/Aboutwebsite/Privacy-Policy.html" target="_blank">CMS Privacy Policy</a></li>
<li><a target="_blank" data-privacy-policy="modal-trigger-footer" onclick="utag.gdpr.showConsentPreferences()">Privacy Settings</a></li>
<li><a href="https://www.cms.gov/vulnerability-disclosure-policy" target="_blank">CMS/HHS Vulnerability Disclosure Policy</a></li>
</ul>
</div>
</div>
</div>
<script src="{{ site.tealium_url }}"></script>
{% if site.tealium_env == "prod" %}
<script type="text/javascript">
(function(a,b,c,d)
{ a='https://tealium-tags.cms.gov/cms-bluebutton/prod/utag.js'; b=document;c='script';d=b.createElement(c);d.src=a;d.type='text/java'+c;d.async=true;e=document.body.insertBefore(d,document.body.firstChild);f=document.createElement('script');f.text="utag_data = {}";e.parentNode.insertBefore(f,e); }
)();
</script>
{% elsif site.tealium_env == "staging" %}
<script type="text/javascript">
(function(a,b,c,d)
{ a='https://tealium-tags.cms.gov/cms-bluebutton/qa/utag.js'; b=document;c='script';d=b.createElement(c);d.src=a;d.type='text/java'+c;d.async=true;e=document.body.insertBefore(d,document.body.firstChild);f=document.createElement('script');f.text="utag_data = {}";e.parentNode.insertBefore(f,e); }
)();
</script>
{% else %}
<script type="text/javascript">
(function(a,b,c,d)
{ a='https://tealium-tags.cms.gov/cms-bluebutton/dev/utag.js'; b=document;c='script';d=b.createElement(c);d.src=a;d.type='text/java'+c;d.async=true;e=document.body.insertBefore(d,document.body.firstChild);f=document.createElement('script');f.text="utag_data = {}";e.parentNode.insertBefore(f,e); }
)();
</script>
{% endif %}
</footer>
2 changes: 0 additions & 2 deletions _includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,4 @@
<script>
window.tealiumEnvironment = "{{ site.tealium_env }}";
</script>

<script src="{{ site.tealium_url }}"></script>
</head>

0 comments on commit ec7a107

Please sign in to comment.