diff --git a/website/package.json b/website/package.json index fe6aeffb..32d95556 100755 --- a/website/package.json +++ b/website/package.json @@ -18,7 +18,8 @@ "classnames": "^2.2.6", "react": "^16.12.0", "react-dom": "^16.12.0", - "react-script-loader-hoc": "^1.2.2" + "react-script-loader-hoc": "^1.2.2", + "react-cookie-consent": "^6.2.2" }, "browserslist": { "production": [ diff --git a/website/src/theme/Footer/index.js b/website/src/theme/Footer/index.js index 11684cec..181abd95 100644 --- a/website/src/theme/Footer/index.js +++ b/website/src/theme/Footer/index.js @@ -4,21 +4,21 @@ import React from "react"; import ScriptLoader from "react-script-loader-hoc"; - -function createMarkup() { - return { - __html: window.startCookieControl.load({ - apiKey: "bd100834001edf98bd5458ce61e48ca552418f9c", - footerSelector: "#foot-boi" - }) - }; -} +import CookieConsent, { Cookie } from "react-cookie-consent"; const MLFooter = ({ scriptsLoadedSuccessfully }) => { - if (!scriptsLoadedSuccessfully) return null; - return
; + return + Magic Leap uses cookies to enhance your user experience, improve our websites, and deliver ads that may interest you. +
+ Learn More + }; -export default ScriptLoader( - "https://magicleap.com/assets/js/cookie-control-js/cookie-control-vanilla.min.js" -)(MLFooter); \ No newline at end of file +export default ScriptLoader()(MLFooter); \ No newline at end of file