@duckduckgo/autoconsent 3.0.3 → 4.0.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/.eslintrc +21 -0
- package/.github/dependabot.yml +6 -0
- package/.github/workflows/checks.yml +19 -0
- package/.prettierrc +4 -0
- package/CHANGELOG.md +50 -0
- package/Jenkinsfile +2 -2
- package/dist/addon-firefox/content.bundle.js +1 -1
- package/dist/addon-firefox/manifest.json +1 -1
- package/dist/addon-firefox/rules.json +49 -4
- package/dist/addon-mv3/content.bundle.js +1 -1
- package/dist/addon-mv3/manifest.json +1 -1
- package/dist/addon-mv3/rules.json +49 -4
- package/dist/autoconsent.cjs.js +1 -1
- package/dist/autoconsent.esm.js +1 -1
- package/dist/autoconsent.playwright.js +1 -1
- package/lib/cmps/all.ts +0 -2
- package/lib/cmps/sourcepoint-frame.ts +32 -7
- package/lib/consentomatic/index.ts +12 -12
- package/lib/consentomatic/tools.ts +13 -13
- package/lib/rule-executors.ts +8 -3
- package/package.json +10 -8
- package/rules/autoconsent/affinity-serif-com.json +1 -4
- package/rules/autoconsent/cookiealert.json +48 -0
- package/rules/rules.json +49 -4
- package/tests/192.spec.ts +3 -3
- package/tests/adroll.spec.ts +7 -7
- package/tests/affinity-serif-com.spec.ts +1 -1
- package/tests/airbnb.spec.ts +3 -3
- package/tests/amazon.spec.ts +8 -8
- package/tests/arzt-auskunft.spec.ts +3 -3
- package/tests/ausopen.spec.ts +2 -2
- package/tests/aws.amazon.spec.ts +3 -3
- package/tests/axeptio.spec.ts +3 -3
- package/tests/baden-wuerttemberg.spec.ts +3 -3
- package/tests/borlabs.spec.ts +4 -4
- package/tests/bundesregierung.spec.ts +6 -6
- package/tests/ccbanner.spec.ts +4 -4
- package/tests/clickio.spec.ts +5 -5
- package/tests/complianz-banner.spec.ts +2 -2
- package/tests/complianz-categories.spec.ts +5 -5
- package/tests/complianz-notice.spec.ts +3 -3
- package/tests/complianz-optin.spec.ts +1 -1
- package/tests/consentmanager.spec.ts +8 -8
- package/tests/conversant.spec.ts +5 -5
- package/tests/cookie-notice.spec.ts +2 -2
- package/tests/cookiealert.spec.ts +9 -0
- package/tests/cookiebot.spec.ts +9 -9
- package/tests/cookieinformation.spec.ts +5 -5
- package/tests/cookielawinfo.spec.ts +3 -3
- package/tests/corona-in-zahlen.spec.ts +3 -3
- package/tests/dailymotion.spec.ts +5 -5
- package/tests/deepl.spec.ts +3 -3
- package/tests/didomi.spec.ts +8 -8
- package/tests/dmgmedia.spec.ts +7 -7
- package/tests/drupal.spec.ts +3 -3
- package/tests/dunelm.spec.ts +3 -3
- package/tests/etsy.spec.ts +2 -2
- package/tests/eu-cookie-compliance-banner.spec.ts +2 -2
- package/tests/eu-cookie-law.spec.ts +2 -2
- package/tests/evidon.spec.ts +3 -3
- package/tests/ezoic.spec.ts +3 -3
- package/tests/facebook.spec.ts +5 -5
- package/tests/fundingchoices.spec.ts +6 -6
- package/tests/google.spec.ts +2 -2
- package/tests/gov-uk.spec.ts +4 -4
- package/tests/hl-co-uk.spec.ts +3 -3
- package/tests/hubspot.spec.ts +2 -2
- package/tests/ionos.spec.ts +3 -3
- package/tests/iubenda.spec.ts +3 -3
- package/tests/johnlewis.spec.ts +3 -3
- package/tests/jquery-cookiebar.spec.ts +2 -2
- package/tests/klaro.spec.ts +5 -5
- package/tests/linkedin.spec.ts +2 -2
- package/tests/marksandspencer.spec.ts +2 -2
- package/tests/mediamarkt.spec.ts +3 -3
- package/tests/mediavine.spec.ts +3 -3
- package/tests/metoffice-gov-uk.spec.ts +3 -3
- package/tests/microsoft.spec.ts +4 -4
- package/tests/moneysavingexpert.spec.ts +3 -3
- package/tests/monzo-com.spec.ts +1 -1
- package/tests/moove.spec.ts +6 -6
- package/tests/motor-talk.spec.ts +3 -3
- package/tests/national-lottery.spec.ts +3 -3
- package/tests/netflix.spec.ts +3 -3
- package/tests/nhs.spec.ts +3 -3
- package/tests/notice-cookie.spec.ts +2 -2
- package/tests/obi.spec.ts +3 -3
- package/tests/oil.spec.ts +6 -6
- package/tests/onetrust.spec.ts +24 -24
- package/tests/osano.spec.ts +1 -1
- package/tests/otto.spec.ts +3 -3
- package/tests/paypal.spec.ts +4 -4
- package/tests/primebox.spec.ts +2 -2
- package/tests/privacymanager.spec.ts +3 -3
- package/tests/pubtech.spec.ts +9 -9
- package/tests/quantcast.spec.ts +10 -10
- package/tests/reddit.spec.ts +3 -3
- package/tests/sibbo.spec.ts +10 -10
- package/tests/sirdata.spec.ts +3 -3
- package/tests/snigel.spec.ts +3 -3
- package/tests/sourcepoint.spec.ts +17 -17
- package/tests/springer.spec.ts +6 -6
- package/tests/steampowered.spec.ts +3 -3
- package/tests/tarteaucitron.spec.ts +4 -4
- package/tests/tealium.spec.ts +2 -2
- package/tests/termly.spec.ts +4 -4
- package/tests/testcmp.spec.ts +1 -1
- package/tests/thalia.spec.ts +3 -3
- package/tests/thefreedictionary.spec.ts +3 -3
- package/tests/tiktok.spec.ts +5 -5
- package/tests/trustarc.spec.ts +15 -15
- package/tests/twitter.spec.ts +7 -7
- package/tests/uk-cookie-consent.spec.ts +3 -3
- package/tests/uniconsent.spec.ts +4 -4
- package/tests/usercentrics-api.spec.ts +5 -5
- package/tests/usercentrics-button.spec.ts +3 -3
- package/tests/uswitch.spec.ts +3 -3
- package/tests/vodafone.spec.ts +3 -3
- package/tests/waitrose.spec.ts +3 -3
- package/tests/wetransfer.spec.ts +3 -3
- package/tests/wordpressgdpr.spec.ts +3 -3
- package/tests/wp-cookie-notice.spec.ts +3 -3
- package/tests/xing.spec.ts +4 -4
- package/tests/youtube-desktop.spec.ts +2 -4
- package/tests/youtube-mobile.spec.ts +3 -3
- package/.eslintrc.cjs +0 -14
- package/lib/cmps/sourcepoint-top.ts +0 -52
package/tests/vodafone.spec.ts
CHANGED
package/tests/waitrose.spec.ts
CHANGED
package/tests/wetransfer.spec.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import generateCMPTests from "../playwright/runner";
|
|
2
2
|
|
|
3
3
|
generateCMPTests('com_wordpressgdpr', [
|
|
4
|
-
|
|
4
|
+
'https://www.yourpension.gov.uk/',
|
|
5
5
|
], {
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
testOptIn: false,
|
|
7
|
+
testSelfTest: false,
|
|
8
8
|
});
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import generateCMPTests from "../playwright/runner";
|
|
2
2
|
|
|
3
3
|
generateCMPTests('WP Cookie Notice for GDPR', [
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
'https://veryceleb.com/',
|
|
5
|
+
// 'https://nysba.org/', // cloudflare botwall
|
|
6
|
+
// 'https://www.independentsentinel.com/', // appears only on user iteraction
|
|
7
7
|
], {}
|
|
8
8
|
);
|
package/tests/xing.spec.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import generateCMPTests from "../playwright/runner";
|
|
2
2
|
|
|
3
3
|
generateCMPTests('xing.com', [
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
'https://www.xing.com/start/signup'], {
|
|
5
|
+
skipRegions: ["US", "FR", "DE"],
|
|
6
|
+
testSelfTest: false
|
|
7
|
+
}
|
|
8
8
|
);
|
package/.eslintrc.cjs
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
module.exports = {
|
|
2
|
-
root: true,
|
|
3
|
-
parser: '@typescript-eslint/parser',
|
|
4
|
-
plugins: [
|
|
5
|
-
'@typescript-eslint',
|
|
6
|
-
],
|
|
7
|
-
extends: [
|
|
8
|
-
'eslint:recommended',
|
|
9
|
-
'plugin:@typescript-eslint/recommended',
|
|
10
|
-
],
|
|
11
|
-
rules: {
|
|
12
|
-
"@typescript-eslint/no-explicit-any": 0,
|
|
13
|
-
}
|
|
14
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { doEval, elementExists, elementVisible } from "../rule-executors";
|
|
2
|
-
import { RunContext } from "../rules";
|
|
3
|
-
import AutoConsentCMPBase from "./base";
|
|
4
|
-
|
|
5
|
-
export default class SourcePoint extends AutoConsentCMPBase {
|
|
6
|
-
prehideSelectors = ["div[id^='sp_message_container_'],.message-overlay"]
|
|
7
|
-
|
|
8
|
-
constructor() {
|
|
9
|
-
super("Sourcepoint-top");
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
runContext: RunContext = {
|
|
13
|
-
main: true,
|
|
14
|
-
frame: false,
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
get hasSelfTest(): boolean {
|
|
18
|
-
return true;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
get isIntermediate(): boolean {
|
|
22
|
-
return true;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
async detectCmp() {
|
|
26
|
-
return elementExists("div[id^='sp_message_container_']");
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
async detectPopup() {
|
|
30
|
-
return elementVisible("div[id^='sp_message_container_']", 'all');
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
async optIn() {
|
|
34
|
-
return true;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
async optOut() {
|
|
38
|
-
// unblock scrolling
|
|
39
|
-
const container = document.querySelector('.sp-message-open');
|
|
40
|
-
if (container) {
|
|
41
|
-
container.classList.remove('sp-message-open');
|
|
42
|
-
}
|
|
43
|
-
return true;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
async test() {
|
|
47
|
-
await doEval("__tcfapi('getTCData', 2, r => window.__rcsResult = r)");
|
|
48
|
-
return await doEval(
|
|
49
|
-
"Object.values(window.__rcsResult.purpose.consents).every(c => !c)"
|
|
50
|
-
);
|
|
51
|
-
}
|
|
52
|
-
}
|