diff --git a/CHANGELOG.md b/CHANGELOG.md
index 6e67280..a237826 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
## [Unreleased]
+### Added
+- Admin settings that enable and configure default consent for cookies
+- Admin setting that switches Cookiebot CDN between .com and .eu [Cookiebot European CDN solution](https://support.cookiebot.com/hc/en-us/articles/4530208762396-Cookiebot-CMP-European-CDN-solution)
+
## [2.0.8] - 2022-08-18
diff --git a/manifest.json b/manifest.json
index e803f94..6fa1fc4 100644
--- a/manifest.json
+++ b/manifest.json
@@ -11,9 +11,7 @@
},
"free": true,
"type": "free",
- "availableCountries": [
- "*"
- ]
+ "availableCountries": ["*"]
},
"builders": {
"pixel": "0.x",
@@ -36,15 +34,70 @@
"gcm": {
"title": "Google Consent Mode",
"type": "string",
- "default": "enabled",
- "enum": [
- "enabled",
- "disabled"
- ],
- "enumNames": [
- "enabled",
- "disabled"
- ]
+ "enum": ["enabled", "disabled"],
+ "default": "enabled"
+ },
+ "cbm": {
+ "title": "Cookie blocking mode",
+ "description": "Choose between automatic or manual cookie blocking. !!! WARNING !!! Automatic cookie blocking may break your store. Use with caution!",
+ "type": "string",
+ "enum": ["auto", "manual"],
+ "default": "manual"
+ },
+ "cdn": {
+ "title": "CDN Region",
+ "description": "Choose the region where the Cookiebot script is hosted. Mind that changing the default region .com may affect functionality if you also employ CSP. Make sure to update your CSP policy accordingly (permit *.cookiebot.eu or *.cookiebot.com).",
+ "type": "string",
+ "enum": ["com", "eu"],
+ "default": "com"
+ },
+ "edc": {
+ "title": "Enable Default Consent",
+ "description": "Enable or disable the default consent mode, activating the options below",
+ "type": "boolean",
+ "default": false
+ },
+ "defaultConsent": {
+ "title": "Default Consent",
+ "type": "object",
+ "properties": {
+ "ad_storage": {
+ "title": "ad_storage",
+ "description": "Sets consent for storing and processing personal data for advertising purposes",
+ "type": "boolean",
+ "default": false
+ },
+ "analytics_storage": {
+ "title": "analytics_storage",
+ "description": "Sets consent for storing and processing personal data for analytics purposes",
+ "type": "boolean",
+ "default": false
+ },
+ "ad_user_data": {
+ "title": "ad_user_data",
+ "description": "Sets consent for sending user data related to advertising to Google",
+ "type": "boolean",
+ "default": false
+ },
+ "ad_personalization": {
+ "title": "ad_personalization",
+ "description": "Sets consent for personalized advertising",
+ "type": "boolean",
+ "default": false
+ },
+ "functionality_storage": {
+ "title": "functionality_storage",
+ "description": "Sets consent for storing and processing personal data for functionality purposes",
+ "type": "boolean",
+ "default": false
+ },
+ "personalization_storage": {
+ "title": "personalization_storage",
+ "description": "Sets consent for storing and processing personal data for personalization purposes",
+ "type": "boolean",
+ "default": false
+ }
+ }
}
}
},
diff --git a/pixel/body.html b/pixel/body.html
index 4780f37..7596e46 100644
--- a/pixel/body.html
+++ b/pixel/body.html
@@ -1 +1 @@
-
+
diff --git a/pixel/head-start.html b/pixel/head-start.html
index 3c82e58..d56dd13 100644
--- a/pixel/head-start.html
+++ b/pixel/head-start.html
@@ -1 +1,34 @@
-
+
+
+
diff --git a/pixel/head.html b/pixel/head.html
new file mode 100644
index 0000000..efd1b0a
--- /dev/null
+++ b/pixel/head.html
@@ -0,0 +1,17 @@
+
diff --git a/react/CookieDeclaration.tsx b/react/CookieDeclaration.tsx
index c296340..97f58a9 100644
--- a/react/CookieDeclaration.tsx
+++ b/react/CookieDeclaration.tsx
@@ -9,11 +9,12 @@ const CookieDeclaration: FC = () => {
return
}
const cbid = window.__cookiebot_id
+ const cdn = window.__cookiebot_cdn
const script = document.createElement('script')
script.id = 'CookieDeclaration'
script.type = 'text/javascript'
script.async = true
- script.src = `https://consent.cookiebot.com/${cbid}/cd.js`
+ script.src = `https://consent.cookiebot.${cdn}/${cbid}/cd.js`
node.appendChild(script)
}, [])
diff --git a/react/typings/global.d.ts b/react/typings/global.d.ts
index d6ac54b..1311240 100644
--- a/react/typings/global.d.ts
+++ b/react/typings/global.d.ts
@@ -1,5 +1,6 @@
interface Window extends Window {
__cookiebot_id: string
+ __cookiebot_cdn: string
Cookiebot: Cookiebot
}