@duckduckgo/autoconsent 4.0.0 → 4.1.1

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.
Files changed (92) hide show
  1. package/.github/ISSUE_TEMPLATE/broken-site-issue.md +29 -0
  2. package/CHANGELOG.md +39 -0
  3. package/Jenkinsfile +2 -2
  4. package/api.md +10 -1
  5. package/dist/addon-firefox/background.bundle.js +312 -1
  6. package/dist/addon-firefox/content.bundle.js +1912 -1
  7. package/dist/addon-firefox/manifest.json +1 -1
  8. package/dist/addon-firefox/rules.json +174 -38
  9. package/dist/addon-mv3/background.bundle.js +312 -1
  10. package/dist/addon-mv3/content.bundle.js +1912 -1
  11. package/dist/addon-mv3/devtools/background.html +10 -0
  12. package/dist/addon-mv3/devtools/bulma.min.css +1 -0
  13. package/dist/addon-mv3/devtools/loader.js +2 -0
  14. package/dist/addon-mv3/devtools/panel.html +88 -0
  15. package/dist/addon-mv3/devtools/panel.js +148 -0
  16. package/dist/addon-mv3/devtools/panel.ts +145 -0
  17. package/dist/addon-mv3/manifest.json +5 -3
  18. package/dist/addon-mv3/popup.bundle.js +173 -1
  19. package/dist/addon-mv3/popup.html +14 -0
  20. package/dist/addon-mv3/rules.json +174 -38
  21. package/dist/autoconsent.cjs.js +1 -1
  22. package/dist/autoconsent.esm.js +1 -1
  23. package/dist/autoconsent.playwright.js +1 -1
  24. package/lib/cmps/airbnb.ts +4 -0
  25. package/lib/cmps/base.ts +8 -0
  26. package/lib/cmps/consentmanager.ts +4 -0
  27. package/lib/cmps/consentomatic.ts +1 -0
  28. package/lib/cmps/conversant.ts +4 -0
  29. package/lib/cmps/cookiebot.ts +4 -0
  30. package/lib/cmps/evidon.ts +4 -0
  31. package/lib/cmps/klaro.ts +4 -0
  32. package/lib/cmps/onetrust.ts +4 -0
  33. package/lib/cmps/sourcepoint-frame.ts +4 -0
  34. package/lib/cmps/tiktok.ts +4 -0
  35. package/lib/cmps/trustarc-frame.ts +4 -0
  36. package/lib/cmps/trustarc-top.ts +4 -0
  37. package/lib/cmps/uniconsent.ts +4 -0
  38. package/lib/eval-handler.ts +2 -6
  39. package/lib/messages.ts +44 -13
  40. package/lib/random.ts +6 -0
  41. package/lib/rules.ts +2 -1
  42. package/lib/types.ts +27 -0
  43. package/lib/web.ts +127 -82
  44. package/package.json +4 -3
  45. package/playwright/runner.ts +1 -0
  46. package/rollup.config.js +18 -5
  47. package/rules/autoconsent/ausopen.json +2 -2
  48. package/rules/autoconsent/baden-wuerttemberg-de.json +1 -0
  49. package/rules/autoconsent/cc-banner.json +1 -0
  50. package/rules/autoconsent/complianz-notice.json +1 -0
  51. package/rules/autoconsent/cookie-notice.json +2 -1
  52. package/rules/autoconsent/dsgvo.json +1 -0
  53. package/rules/autoconsent/eu-cookie-compliance.json +1 -1
  54. package/rules/autoconsent/eu-cookie-law.json +1 -0
  55. package/rules/autoconsent/ezoic.json +1 -0
  56. package/rules/autoconsent/generic-cosmetic.json +9 -0
  57. package/rules/autoconsent/indeed-com.json +9 -0
  58. package/rules/autoconsent/jquery-cookiebar.json +1 -0
  59. package/rules/autoconsent/marksandspencer.json +2 -2
  60. package/rules/autoconsent/notice-cookie.json +1 -0
  61. package/rules/autoconsent/osano.json +1 -0
  62. package/rules/autoconsent/pornhub.json +12 -0
  63. package/rules/autoconsent/testcmp-cosmetic.json +18 -0
  64. package/rules/autoconsent/uk-cookie-consent.json +1 -0
  65. package/rules/autoconsent/xnxx-com.json +9 -0
  66. package/rules/rules.json +174 -38
  67. package/tests/borlabs.spec.ts +1 -1
  68. package/tests/complianz-optin.spec.ts +4 -4
  69. package/tests/cookie-notice.spec.ts +3 -1
  70. package/tests/cookiebot.spec.ts +0 -4
  71. package/tests/cookieinformation.spec.ts +0 -1
  72. package/tests/dsgvo.spec.ts +4 -1
  73. package/tests/evidon.spec.ts +2 -4
  74. package/tests/ezoic.spec.ts +0 -1
  75. package/tests/fundingchoices.spec.ts +0 -1
  76. package/tests/generic-cosmetic.spec.ts +11 -0
  77. package/tests/indeed.spec.ts +7 -0
  78. package/tests/moove.spec.ts +0 -6
  79. package/tests/pornhub.spec.ts +7 -0
  80. package/tests/pubtech.spec.ts +0 -1
  81. package/tests/reddit.spec.ts +1 -1
  82. package/tests/sibbo.spec.ts +0 -1
  83. package/tests/sirdata.spec.ts +0 -1
  84. package/tests/testcmp-banner.spec.ts +5 -0
  85. package/tests/trustarc.spec.ts +0 -2
  86. package/tests/uniconsent.spec.ts +1 -1
  87. package/tests/usercentrics-api.spec.ts +1 -0
  88. package/tests/usercentrics-button.spec.ts +0 -1
  89. package/tests/xnxx.spec.ts +8 -0
  90. package/tsconfig.json +2 -1
  91. package/rules/autoconsent/motor-talk-de.json +0 -24
  92. package/tests/motor-talk.spec.ts +0 -7
@@ -3,4 +3,6 @@ import generateCMPTests from "../playwright/runner";
3
3
  generateCMPTests('cookie-notice', [
4
4
  'https://electricbikereview.com/',
5
5
  'https://osxdaily.com/',
6
- ]);
6
+ ], {
7
+ skipRegions: ['US']
8
+ });
@@ -5,12 +5,8 @@ generateCMPTests('Cybotcookiebot', [
5
5
  'https://www.zwilling.com/de/',
6
6
  'https://forums.cpanel.net/',
7
7
  'https://tfl.gov.uk',
8
-
9
8
  // "https://www.ab-in-den-urlaub.de/", // often blocked by botwall
10
-
11
- "https://www.centralpoint.nl/",
12
9
  "https://www.vatera.hu/",
13
- "https://www.smartsheet.com/",
14
10
  ], {
15
11
  skipRegions: ['US']
16
12
  });
@@ -1,7 +1,6 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('Cookie Information Banner', [
4
- 'https://water.org/',
5
4
  // 'https://www.phaseone.com/', // appears only on user iteraction
6
5
  'https://www.georgjensen.com/',
7
6
  'https://www.power.no/',
@@ -3,4 +3,7 @@ import generateCMPTests from "../playwright/runner";
3
3
  generateCMPTests('WP DSGVO Tools', [
4
4
  'https://ccmedia.ch/',
5
5
  'https://rlalpbsl.web.belwue.de/',
6
- ], {});
6
+ // 'https://www.mathe-lerntipps.de/', // https://github.com/duckduckgo/autoconsent/issues/80
7
+ ], {
8
+ skipRegions: ['US']
9
+ });
@@ -1,11 +1,9 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('Evidon', [
4
- 'https://www.fujitsu.com/global/'
5
- ]);
6
-
7
- generateCMPTests('Evidon', [
4
+ 'https://www.crunchyroll.com/',
8
5
  'https://www.kia.com/us/en', // "I agree" button is actually a decline button
9
6
  ], {
10
7
  testOptIn: false,
8
+ skipRegions: ['US']
11
9
  });
@@ -1,7 +1,6 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('EZoic', [
4
- 'https://singletrackworld.com/',
5
4
  'https://www.diyphotography.net/',
6
5
  ], {
7
6
  skipRegions: ['US'],
@@ -1,7 +1,6 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('funding-choices', [
4
- 'https://www.schulferien.org/',
5
4
  'https://www.bbc.com/',
6
5
  'https://www.accuweather.com/',
7
6
  'https://hbr.org/',
@@ -0,0 +1,11 @@
1
+ import generateCMPTests from "../playwright/runner";
2
+
3
+ generateCMPTests('generic-cosmetic', [
4
+ 'https://www.ama.org/',
5
+ 'https://www.migros.ch/de',
6
+ 'https://www.android.com/',
7
+ 'https://www.google.com/chrome/index.html',
8
+ ], {
9
+ testOptIn: false,
10
+ onlyRegions: ['US'],
11
+ });
@@ -0,0 +1,7 @@
1
+ import generateCMPTests from "../playwright/runner";
2
+
3
+ generateCMPTests('indeed.com', [
4
+ 'https://indeed.com',
5
+ ], {
6
+ onlyRegions: ['US'],
7
+ });
@@ -6,9 +6,3 @@ generateCMPTests('Moove', [
6
6
  'https://www.phorest.com/',
7
7
  'https://theposterclub.com/',
8
8
  ], {});
9
-
10
- generateCMPTests('Moove', [
11
- 'https://www.yourcloudlibrary.com/',
12
- ], {
13
- skipRegions: ['US', 'GB']
14
- });
@@ -0,0 +1,7 @@
1
+ import generateCMPTests from "../playwright/runner";
2
+
3
+ generateCMPTests('pornhub.com', [
4
+ 'https://pornhub.com/',
5
+ ], {
6
+ onlyRegions: ['US'],
7
+ });
@@ -1,7 +1,6 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('pubtech', [
4
- 'https://www.lefonti.tv/',
5
4
  'https://www.liberoquotidiano.it/',
6
5
  'https://www.telefonino.net/',
7
6
  'https://www.fattoincasadabenedetta.it/',
@@ -4,5 +4,5 @@ generateCMPTests('reddit.com', [
4
4
  'https://www.reddit.com/r/AskReddit/',
5
5
  ],{
6
6
  mobile: false,
7
- skipRegions: ['US'],
7
+ skipRegions: ['US', 'DE', 'FR', 'GB'], // https://github.com/duckduckgo/autoconsent/issues/82
8
8
  });
@@ -10,6 +10,5 @@ generateCMPTests('sibbo', [
10
10
  'https://www.atresplayer.com/',
11
11
  'https://www.antena3.com/',
12
12
  'https://www.lasexta.com/',
13
- 'https://www.atresmedia.com/'
14
13
  ]
15
14
  );
@@ -1,7 +1,6 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('Sirdata', [
4
- 'https://www.futura-sciences.com/',
5
4
  'https://www.comment-economiser.fr/',
6
5
  ], {
7
6
  skipRegions: ['US']
@@ -0,0 +1,5 @@
1
+ import generateCMPTests from "../playwright/runner";
2
+
3
+ generateCMPTests('Test page cosmetic CMP', [
4
+ 'https://privacy-test-pages.glitch.me/features/autoconsent/banner.html'
5
+ ]);
@@ -18,8 +18,6 @@ generateCMPTests('TrustArc-top', [
18
18
 
19
19
  generateCMPTests('TrustArc-frame', [
20
20
  'https://www.wish.com/',
21
- 'https://www.forbes.com/',
22
- 'https://www.starbucks.com/',
23
21
  ], {
24
22
  testOptOut: true,
25
23
  testSelfTest: false,
@@ -1,7 +1,7 @@
1
1
  import generateCMPTests from "../playwright/runner";
2
2
 
3
3
  generateCMPTests('Uniconsent', [
4
- 'https://sport-stimme.de/',
4
+ // 'https://sport-stimme.de/', // see https://github.com/duckduckgo/autoconsent/issues/81
5
5
  'https://www.sharethrough.com/',
6
6
  ], {});
7
7
 
@@ -4,6 +4,7 @@ generateCMPTests('usercentrics-api', [
4
4
  'https://hornbach.de',
5
5
  'https://dm.de',
6
6
  'https://usercentrics.com/',
7
+ 'https://shopbetreiber-blog.de/',
7
8
  ], {
8
9
  skipRegions: ["US", "GB", "FR"]
9
10
  }
@@ -3,6 +3,5 @@ import generateCMPTests from "../playwright/runner";
3
3
  generateCMPTests('usercentrics-button', [
4
4
  'https://www.commerzbank.de/',
5
5
  'https://www.nkd.com/',
6
- 'https://shopbetreiber-blog.de/',
7
6
  ], {}
8
7
  );
@@ -0,0 +1,8 @@
1
+ import generateCMPTests from "../playwright/runner";
2
+
3
+ generateCMPTests('xnxx-com', [
4
+ 'https://xnxx.com/',
5
+ 'https://xvideos.com/'
6
+ ], {
7
+ onlyRegions: ['US'],
8
+ });
package/tsconfig.json CHANGED
@@ -9,6 +9,7 @@
9
9
  "exclude": [
10
10
  "node_modules/*",
11
11
  "playwright.config.ts",
12
- "tests/*"
12
+ "tests/*",
13
+ "dist/*"
13
14
  ]
14
15
  }
@@ -1,24 +0,0 @@
1
- {
2
- "name": "motor-talk.de",
3
- "prehideSelectors": [".mt-cc-bnnr__wrapper"],
4
- "detectCmp": [
5
- {
6
- "exists": ".mt-cc-bnnr"
7
- }
8
- ],
9
- "detectPopup": [
10
- {
11
- "visible": ".mt-cc-bnnr__wrapper"
12
- }
13
- ],
14
- "optIn": [
15
- {
16
- "click": ".mt-cc-bnnr__button-main"
17
- }
18
- ],
19
- "optOut": [
20
- {
21
- "click": ".mt-cc-bnnr__decline-link"
22
- }
23
- ]
24
- }
@@ -1,7 +0,0 @@
1
- import generateCMPTests from "../playwright/runner";
2
-
3
- generateCMPTests('motor-talk.de', [
4
- 'https://motor-talk.de'], {
5
- skipRegions: ["US", "FR", "GB"]
6
- }
7
- );