@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
|
@@ -222,11 +222,24 @@
|
|
|
222
222
|
const disabled = window.Didomi?.getUserConsentStatusForAll?.()?.purposes?.disabled;
|
|
223
223
|
return Array.isArray(disabled) && disabled.length > 0;
|
|
224
224
|
},
|
|
225
|
-
EVAL_CONSENTMANAGER_1: () =>
|
|
226
|
-
|
|
225
|
+
EVAL_CONSENTMANAGER_1: () => {
|
|
226
|
+
const cmpData = window.__cmp?.("getCMPData");
|
|
227
|
+
return !!cmpData && typeof cmpData === "object";
|
|
228
|
+
},
|
|
229
|
+
EVAL_CONSENTMANAGER_2: () => window.__cmp?.("consentStatus")?.userChoiceExists === false,
|
|
227
230
|
EVAL_CONSENTMANAGER_3: () => __cmp("setConsent", 0),
|
|
228
231
|
EVAL_CONSENTMANAGER_4: () => __cmp("setConsent", 1),
|
|
229
232
|
EVAL_CONSENTMANAGER_5: () => __cmp("consentStatus").userChoiceExists,
|
|
233
|
+
EVAL_CONSENTMANAGER_NCMP_REJECT: () => {
|
|
234
|
+
if (typeof window.__npcmp !== "function") return false;
|
|
235
|
+
window.__npcmp("reject");
|
|
236
|
+
return true;
|
|
237
|
+
},
|
|
238
|
+
EVAL_CONSENTMANAGER_NCMP_ACCEPT: () => {
|
|
239
|
+
if (typeof window.__npcmp !== "function") return false;
|
|
240
|
+
window.__npcmp("save");
|
|
241
|
+
return true;
|
|
242
|
+
},
|
|
230
243
|
EVAL_COOKIEBOT_1: () => !!window.Cookiebot,
|
|
231
244
|
EVAL_COOKIEBOT_2: () => !window.Cookiebot.hasResponse && window.Cookiebot.dialog?.visible === true,
|
|
232
245
|
EVAL_COOKIEBOT_3: () => window.Cookiebot.withdraw() || true,
|
|
@@ -274,6 +287,7 @@
|
|
|
274
287
|
// declarative rules
|
|
275
288
|
EVAL_ADOPT_TEST: () => !!localStorage.getItem("adoptConsentMode"),
|
|
276
289
|
EVAL_ADULTFRIENDFINDER_TEST: () => !!localStorage.getItem("cookieConsent"),
|
|
290
|
+
EVAL_AYLO_COOKIE_MANAGER_READY: () => !!(window.wl_cookie_consent_manager || window._Cookie_Consent_Manager_brand),
|
|
277
291
|
EVAL_BAHN_TEST: () => utag.gdpr.getSelectedCategories().length === 1,
|
|
278
292
|
EVAL_BIGCOMMERCE_CONSENT_MANAGER_DETECT: () => !!(window.consentManager && window.consentManager.version),
|
|
279
293
|
EVAL_BORLABS_0: () => !JSON.parse(
|
|
@@ -318,6 +332,7 @@
|
|
|
318
332
|
if (x.checked) x.click();
|
|
319
333
|
}) || true,
|
|
320
334
|
EVAL_IUBENDA_1: () => !!document.cookie.match(/_iub_cs-\d+=/),
|
|
335
|
+
EVAL_KROWN_COOKIE_BANNER_TEST: () => localStorage.getItem("krown-cookie-banner") === "true",
|
|
321
336
|
EVAL_MICROSOFT_0: () => Array.from(document.querySelectorAll("div > button")).filter((el) => el.innerText.match("Reject|Ablehnen"))[0].click() || true,
|
|
322
337
|
EVAL_MICROSOFT_1: () => Array.from(document.querySelectorAll("div > button")).filter((el) => el.innerText.match("Accept|Annehmen"))[0].click() || true,
|
|
323
338
|
EVAL_MICROSOFT_2: () => !!document.cookie.match("MSCC|GHCC"),
|