@duckduckgo/autoconsent 14.66.0 → 14.68.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/CHANGELOG.md +41 -0
- package/data/coverage.json +5846 -2663
- package/dist/addon-firefox/background.bundle.js +20 -8
- package/dist/addon-firefox/compact-rules.json +1 -1
- package/dist/addon-firefox/content.bundle.js +0 -2
- package/dist/addon-firefox/manifest.json +1 -1
- package/dist/addon-firefox/rules.json +1 -1
- package/dist/addon-mv3/background.bundle.js +20 -8
- package/dist/addon-mv3/compact-rules.json +1 -1
- package/dist/addon-mv3/content.bundle.js +0 -2
- package/dist/addon-mv3/manifest.json +1 -1
- package/dist/addon-mv3/rules.json +1 -1
- package/dist/autoconsent.cjs.js +0 -2
- package/dist/autoconsent.esm.js +0 -2
- package/dist/autoconsent.extra.cjs.js +0 -2
- package/dist/autoconsent.extra.esm.js +0 -2
- package/dist/autoconsent.playwright.js +0 -2
- package/dist/types/eval-snippets.d.ts +0 -2
- package/lib/eval-snippets.ts +0 -3
- package/package.json +1 -1
- package/playwright/runner.ts +9 -1
- package/rules/autoconsent/elsevier-pure.json +31 -0
- package/rules/autoconsent/ensighten.json +50 -0
- package/rules/autoconsent/facebook.json +21 -7
- package/rules/autoconsent/fullertonhotels.com.json +37 -0
- package/rules/autoconsent/geni.com.json +8 -5
- package/rules/autoconsent/remarkable.com.json +6 -27
- package/rules/autoconsent/unicourt.json +5 -5
- package/rules/compact-rules.json +1 -1
- package/rules/generated/auto_AU_flysaa.com_qsm.json +10 -9
- package/rules/generated/auto_DE_immobilien.sparkasse.de_zj7.json +10 -10
- package/rules/rules.json +1 -1
- package/tests/elsevier-pure.spec.ts +11 -0
- package/tests/ensighten.spec.ts +9 -0
- package/tests/fullertonhotels.com.spec.ts +6 -0
- package/rules/autoconsent/ens-modal.json +0 -13
- package/rules/autoconsent/ens-notify-banner.json +0 -12
- package/rules/autoconsent/mediavine.json +0 -17
- package/rules/autoconsent/national-lottery-co-uk.json +0 -11
- package/rules/autoconsent/ouraring.json +0 -36
- package/rules/generated/auto_AU_discover.utas.edu.au_k2n.json +0 -37
- package/rules/generated/auto_AU_experts.deakin.edu.au_0kw.json +0 -40
- package/rules/generated/auto_AU_experts.griffith.edu.au_oi0.json +0 -37
- package/rules/generated/auto_AU_fullertonhotels.com_y46.json +0 -40
- package/rules/generated/auto_AU_profiles.uts.edu.au_ouv.json +0 -37
- package/rules/generated/auto_AU_scholars.latrobe.edu.au_li6.json +0 -40
- package/rules/generated/auto_CA_discover.research.utoronto.ca_vtf.json +0 -40
- package/rules/generated/auto_CA_remarkable.com_kt9.json +0 -40
- package/rules/generated/auto_GB_profiles.ucl.ac.uk_lpo.json +0 -40
- package/tests/generated/auto_AU_discover.utas.edu.au_k2n.spec.ts +0 -6
- package/tests/generated/auto_AU_experts.deakin.edu.au_0kw.spec.ts +0 -6
- package/tests/generated/auto_AU_experts.griffith.edu.au_oi0.spec.ts +0 -6
- package/tests/generated/auto_AU_fullertonhotels.com_y46.spec.ts +0 -6
- package/tests/generated/auto_AU_profiles.uts.edu.au_ouv.spec.ts +0 -6
- package/tests/generated/auto_AU_scholars.latrobe.edu.au_li6.spec.ts +0 -6
- package/tests/generated/auto_CA_discover.research.utoronto.ca_vtf.spec.ts +0 -6
- package/tests/generated/auto_CA_remarkable.com_kt9.spec.ts +0 -2
- package/tests/generated/auto_GB_profiles.ucl.ac.uk_lpo.spec.ts +0 -6
- package/tests/mediavine.spec.ts +0 -5
- package/tests/national-lottery.spec.ts +0 -5
- package/tests/ouraring.spec.ts +0 -3
|
@@ -100,7 +100,6 @@
|
|
|
100
100
|
if (x.checked) x.click();
|
|
101
101
|
}) || true,
|
|
102
102
|
EVAL_IUBENDA_1: () => !!document.cookie.match(/_iub_cs-\d+=/),
|
|
103
|
-
EVAL_MEDIAVINE_0: () => document.querySelectorAll('[data-name="mediavine-gdpr-cmp"] input[type=checkbox]').forEach((x) => x.checked && x.click()) || true,
|
|
104
103
|
EVAL_MICROSOFT_0: () => Array.from(document.querySelectorAll("div > button")).filter((el) => el.innerText.match("Reject|Ablehnen"))[0].click() || true,
|
|
105
104
|
EVAL_MICROSOFT_1: () => Array.from(document.querySelectorAll("div > button")).filter((el) => el.innerText.match("Accept|Annehmen"))[0].click() || true,
|
|
106
105
|
EVAL_MICROSOFT_2: () => !!document.cookie.match("MSCC|GHCC"),
|
|
@@ -116,7 +115,6 @@
|
|
|
116
115
|
).status === "deny",
|
|
117
116
|
EVAL_POVR_GOBACK: () => window.history.back() || true,
|
|
118
117
|
EVAL_PUBTECH_0: () => document.cookie.includes("euconsent-v2") && (document.cookie.match(/.YAAAAAAAAAAA/) || document.cookie.match(/.aAAAAAAAAAAA/) || document.cookie.match(/.YAAACFgAAAAA/)),
|
|
119
|
-
EVAL_REMARKABLE_TEST: () => !!localStorage.getItem("rmCookieConsent"),
|
|
120
118
|
EVAL_SHOPIFY_TEST: () => document.cookie.includes("gdpr_cookie_consent=0") || document.cookie.includes("_tracking_consent=") && JSON.parse(
|
|
121
119
|
decodeURIComponent(
|
|
122
120
|
document.cookie.split(";").find((s) => s.trim().startsWith("_tracking_consent")).split("=")[1]
|
|
@@ -884,6 +882,11 @@
|
|
|
884
882
|
storageSet({
|
|
885
883
|
rules: await res.json()
|
|
886
884
|
});
|
|
885
|
+
const fullRes = await fetch("./rules.json");
|
|
886
|
+
const fullRules = await fullRes.json();
|
|
887
|
+
storageSet({
|
|
888
|
+
fullRules: fullRules.autoconsent
|
|
889
|
+
});
|
|
887
890
|
}
|
|
888
891
|
async function evalInTab(tabId, frameId, code, snippetId) {
|
|
889
892
|
return chrome.scripting.executeScript({
|
|
@@ -929,12 +932,21 @@
|
|
|
929
932
|
if (frameId === 0) {
|
|
930
933
|
await showOptOutStatus(tabId, "idle");
|
|
931
934
|
}
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
935
|
+
let rules;
|
|
936
|
+
if (autoconsentConfig.autoAction === "optIn") {
|
|
937
|
+
const fullRules = await storageGet("fullRules") || [];
|
|
938
|
+
rules = {
|
|
939
|
+
autoconsent: fullRules,
|
|
940
|
+
consentomatic
|
|
941
|
+
};
|
|
942
|
+
} else {
|
|
943
|
+
rules = {
|
|
944
|
+
autoconsent: [],
|
|
945
|
+
consentomatic,
|
|
946
|
+
compact: filterCompactRules(await storageGet("rules"), { url: senderUrl, mainFrame: frameId === 0 })
|
|
947
|
+
};
|
|
948
|
+
}
|
|
949
|
+
console.log("filtered rules:", rules.compact || rules.autoconsent?.length, JSON.stringify(rules).length);
|
|
938
950
|
chrome.tabs.sendMessage(
|
|
939
951
|
tabId,
|
|
940
952
|
{
|