From 9dcb7306daff6d876b626651301a4a1c434f19cf Mon Sep 17 00:00:00 2001 From: Noel Quiles <3746694+EnMod@users.noreply.github.com> Date: Fri, 28 Jan 2022 14:37:35 -0500 Subject: [PATCH] website: Add Demandbase tag to consent manager (#11941) * chore: Add Demandbase tag to consent manager * fix: Add services to manager options --- website/lib/consent-manager-services/index.ts | 15 +++++++++++++++ website/pages/_app.js | 2 ++ 2 files changed, 17 insertions(+) create mode 100644 website/lib/consent-manager-services/index.ts diff --git a/website/lib/consent-manager-services/index.ts b/website/lib/consent-manager-services/index.ts new file mode 100644 index 000000000..3a1a65171 --- /dev/null +++ b/website/lib/consent-manager-services/index.ts @@ -0,0 +1,15 @@ +import { ConsentManagerService } from '@hashicorp/react-consent-manager/types' + +const localConsentManagerServices: ConsentManagerService[] = [ + { + name: 'Demandbase Tag', + description: + 'The Demandbase tag is a tracking service to identify website visitors and measure interest on our website.', + category: 'Analytics', + url: 'https://tag.demandbase.com/960ab0a0f20fb102.min.js', + async: true, + }, +] + +export default localConsentManagerServices + diff --git a/website/pages/_app.js b/website/pages/_app.js index fc7707aac..431a48ddd 100644 --- a/website/pages/_app.js +++ b/website/pages/_app.js @@ -6,6 +6,7 @@ import Head from 'next/head' import NProgress from '@hashicorp/platform-util/nprogress' import { ErrorBoundary } from '@hashicorp/platform-runtime-error-monitoring' import createConsentManager from '@hashicorp/react-consent-manager/loader' +import localConsentManagerServices from 'lib/consent-manager-services' import useFathomAnalytics from '@hashicorp/platform-analytics' import useAnchorLinkAnalytics from '@hashicorp/platform-util/anchor-link-analytics' import HashiStackMenu from '@hashicorp/react-hashi-stack-menu' @@ -19,6 +20,7 @@ import alertBannerData, { ALERT_BANNER_ACTIVE } from 'data/alert-banner' NProgress({ Router }) const { ConsentManager, openConsentManager } = createConsentManager({ preset: 'oss', + otherServices: [...localConsentManagerServices], }) export default function App({ Component, pageProps }) {