@duckduckgo/autoconsent 16.20.1 → 16.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/asana-sync.yml +2 -1
- package/CHANGELOG.md +46 -0
- package/data/coverage.json +1362 -1255
- package/dist/addon-firefox/background.bundle.js +17 -2
- package/dist/addon-firefox/compact-rules.json +1 -1
- package/dist/addon-firefox/content.bundle.js +17 -2
- package/dist/addon-firefox/manifest.json +1 -1
- package/dist/addon-firefox/rule-index.json +1 -1
- package/dist/addon-firefox/rules.json +1 -1
- package/dist/addon-mv3/background.bundle.js +17 -2
- package/dist/addon-mv3/compact-rules.json +1 -1
- package/dist/addon-mv3/content.bundle.js +17 -2
- package/dist/addon-mv3/manifest.json +1 -1
- package/dist/addon-mv3/rule-index.json +1 -1
- package/dist/addon-mv3/rules.json +1 -1
- package/dist/autoconsent.cjs.js +17 -2
- package/dist/autoconsent.esm.js +17 -2
- package/dist/autoconsent.playwright.js +17 -2
- package/dist/autoconsent.standalone.js +18 -3
- package/dist/types/eval-snippets.d.ts +5 -1
- package/lib/eval-snippets.ts +17 -2
- package/package.json +1 -1
- package/rules/autoconsent/appconsent-legacy.json +31 -0
- package/rules/autoconsent/appconsent.json +31 -0
- package/rules/autoconsent/aylo-cookie-banner.json +59 -4
- package/rules/autoconsent/consentmanager-ncmp.json +34 -0
- package/rules/autoconsent/cookie-banner-element.json +8 -0
- package/rules/autoconsent/ctv-disneyonice.json +12 -0
- package/rules/autoconsent/fever.json +42 -0
- package/rules/autoconsent/ibanez.json +13 -0
- package/rules/autoconsent/krown-cookie-banner.json +34 -0
- package/rules/autoconsent/pornpics-de.json +13 -0
- package/rules/autoconsent/simplehuman-com.json +33 -0
- package/rules/autoconsent/toho-one.json +50 -0
- package/rules/autoconsent/tohotheater-jp.json +20 -0
- package/rules/compact-rules.json +1 -1
- package/rules/rule-index.json +1 -1
- package/rules/rules.json +1 -1
- package/tests/appconsent-legacy.spec.ts +7 -0
- package/tests/appconsent.spec.ts +7 -0
- package/tests/consentmanager-ncmp.spec.ts +5 -0
- package/tests/cookie-banner-element.spec.ts +7 -0
- package/tests/ctv-disneyonice.spec.ts +5 -0
- package/tests/fever.spec.ts +3 -0
- package/tests/ibanez.spec.ts +3 -0
- package/tests/krown-cookie-banner.spec.ts +3 -0
- package/tests/pornpics-de.spec.ts +3 -0
- package/tests/simplehuman-com.spec.ts +3 -0
- package/tests/toho-one.spec.ts +3 -0
- package/tests/tohotheater-jp.spec.ts +3 -0
|
@@ -19,11 +19,24 @@
|
|
|
19
19
|
const disabled = window.Didomi?.getUserConsentStatusForAll?.()?.purposes?.disabled;
|
|
20
20
|
return Array.isArray(disabled) && disabled.length > 0;
|
|
21
21
|
},
|
|
22
|
-
EVAL_CONSENTMANAGER_1: () =>
|
|
23
|
-
|
|
22
|
+
EVAL_CONSENTMANAGER_1: () => {
|
|
23
|
+
const cmpData = window.__cmp?.("getCMPData");
|
|
24
|
+
return !!cmpData && typeof cmpData === "object";
|
|
25
|
+
},
|
|
26
|
+
EVAL_CONSENTMANAGER_2: () => window.__cmp?.("consentStatus")?.userChoiceExists === false,
|
|
24
27
|
EVAL_CONSENTMANAGER_3: () => __cmp("setConsent", 0),
|
|
25
28
|
EVAL_CONSENTMANAGER_4: () => __cmp("setConsent", 1),
|
|
26
29
|
EVAL_CONSENTMANAGER_5: () => __cmp("consentStatus").userChoiceExists,
|
|
30
|
+
EVAL_CONSENTMANAGER_NCMP_REJECT: () => {
|
|
31
|
+
if (typeof window.__npcmp !== "function") return false;
|
|
32
|
+
window.__npcmp("reject");
|
|
33
|
+
return true;
|
|
34
|
+
},
|
|
35
|
+
EVAL_CONSENTMANAGER_NCMP_ACCEPT: () => {
|
|
36
|
+
if (typeof window.__npcmp !== "function") return false;
|
|
37
|
+
window.__npcmp("save");
|
|
38
|
+
return true;
|
|
39
|
+
},
|
|
27
40
|
EVAL_COOKIEBOT_1: () => !!window.Cookiebot,
|
|
28
41
|
EVAL_COOKIEBOT_2: () => !window.Cookiebot.hasResponse && window.Cookiebot.dialog?.visible === true,
|
|
29
42
|
EVAL_COOKIEBOT_3: () => window.Cookiebot.withdraw() || true,
|
|
@@ -71,6 +84,7 @@
|
|
|
71
84
|
// declarative rules
|
|
72
85
|
EVAL_ADOPT_TEST: () => !!localStorage.getItem("adoptConsentMode"),
|
|
73
86
|
EVAL_ADULTFRIENDFINDER_TEST: () => !!localStorage.getItem("cookieConsent"),
|
|
87
|
+
EVAL_AYLO_COOKIE_MANAGER_READY: () => !!(window.wl_cookie_consent_manager || window._Cookie_Consent_Manager_brand),
|
|
74
88
|
EVAL_BAHN_TEST: () => utag.gdpr.getSelectedCategories().length === 1,
|
|
75
89
|
EVAL_BIGCOMMERCE_CONSENT_MANAGER_DETECT: () => !!(window.consentManager && window.consentManager.version),
|
|
76
90
|
EVAL_BORLABS_0: () => !JSON.parse(
|
|
@@ -115,6 +129,7 @@
|
|
|
115
129
|
if (x.checked) x.click();
|
|
116
130
|
}) || true,
|
|
117
131
|
EVAL_IUBENDA_1: () => !!document.cookie.match(/_iub_cs-\d+=/),
|
|
132
|
+
EVAL_KROWN_COOKIE_BANNER_TEST: () => localStorage.getItem("krown-cookie-banner") === "true",
|
|
118
133
|
EVAL_MICROSOFT_0: () => Array.from(document.querySelectorAll("div > button")).filter((el) => el.innerText.match("Reject|Ablehnen"))[0].click() || true,
|
|
119
134
|
EVAL_MICROSOFT_1: () => Array.from(document.querySelectorAll("div > button")).filter((el) => el.innerText.match("Accept|Annehmen"))[0].click() || true,
|
|
120
135
|
EVAL_MICROSOFT_2: () => !!document.cookie.match("MSCC|GHCC"),
|