@duckduckgo/autoconsent 6.0.0 → 6.1.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.
@@ -80,10 +80,12 @@ export default class TrustArcFrame extends AutoConsentCMPBase {
80
80
 
81
81
  if (click("#catDetails0")) {
82
82
  click(".submit");
83
+ waitForThenClick("#gwt-debug-close_id", 5000);
83
84
  return true;
84
85
  }
85
86
 
86
87
  if (click(".required")) {
88
+ waitForThenClick("#gwt-debug-close_id", 5000);
87
89
  return true;
88
90
  }
89
91
 
@@ -94,9 +96,7 @@ export default class TrustArcFrame extends AutoConsentCMPBase {
94
96
  click(".submit");
95
97
 
96
98
  // at this point, iframe usually closes. Sometimes we need to close manually, but we don't wait for it to report success
97
- waitForElement("#gwt-debug-close_id", 300000).then(() => {
98
- click("#gwt-debug-close_id");
99
- });
99
+ waitForThenClick("#gwt-debug-close_id", 300000);
100
100
 
101
101
  return true;
102
102
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@duckduckgo/autoconsent",
3
- "version": "6.0.0",
3
+ "version": "6.1.0",
4
4
  "description": "",
5
5
  "main": "dist/autoconsent.cjs.js",
6
6
  "module": "dist/autoconsent.esm.js",
@@ -33,15 +33,15 @@
33
33
  "@playwright/test": "^1.17.1",
34
34
  "@puppeteer/replay": "^2.11.0",
35
35
  "@types/chai": "^4.3.1",
36
- "@types/chrome": "^0.0.242",
36
+ "@types/chrome": "^0.0.245",
37
37
  "@types/mocha": "^10.0.1",
38
38
  "@typescript-eslint/eslint-plugin": "^5.42.1",
39
39
  "@typescript-eslint/parser": "^5.42.1",
40
- "auto": "^10.37.6",
40
+ "auto": "^11.0.1",
41
41
  "bulma": "^0.9.4",
42
42
  "chai": "^4.2.0",
43
43
  "chokidar-cli": "^3.0.0",
44
- "esbuild": "^0.18.11",
44
+ "esbuild": "^0.19.2",
45
45
  "eslint": "^8.27.0",
46
46
  "eslint-plugin-json": "^3.1.0",
47
47
  "mocha": "^10.0.0",
@@ -0,0 +1,19 @@
1
+ {
2
+ "name": "activobank.pt",
3
+ "runContext": {
4
+ "urlPattern": "^https://(www\\.)?activobank\\.pt"
5
+ },
6
+ "prehideSelectors": ["aside#cookies,.overlay-cookies"],
7
+ "detectCmp": [
8
+ { "exists": "#cookies .cookies-btn" }
9
+ ],
10
+ "detectPopup": [
11
+ { "visible": "#cookies #submitCookies" }
12
+ ],
13
+ "optIn": [
14
+ { "waitForThenClick": "#cookies #submitCookies" }
15
+ ],
16
+ "optOut": [
17
+ { "waitForThenClick": "#cookies #rejectCookies" }
18
+ ]
19
+ }
package/rules/rules.json CHANGED
@@ -60,6 +60,35 @@
60
60
  }
61
61
  ]
62
62
  },
63
+ {
64
+ "name": "activobank.pt",
65
+ "runContext": {
66
+ "urlPattern": "^https://(www\\.)?activobank\\.pt"
67
+ },
68
+ "prehideSelectors": [
69
+ "aside#cookies,.overlay-cookies"
70
+ ],
71
+ "detectCmp": [
72
+ {
73
+ "exists": "#cookies .cookies-btn"
74
+ }
75
+ ],
76
+ "detectPopup": [
77
+ {
78
+ "visible": "#cookies #submitCookies"
79
+ }
80
+ ],
81
+ "optIn": [
82
+ {
83
+ "waitForThenClick": "#cookies #submitCookies"
84
+ }
85
+ ],
86
+ "optOut": [
87
+ {
88
+ "waitForThenClick": "#cookies #rejectCookies"
89
+ }
90
+ ]
91
+ },
63
92
  {
64
93
  "name": "Adroll",
65
94
  "prehideSelectors": [
@@ -0,0 +1,6 @@
1
+ import generateCMPTests from "../playwright/runner";
2
+
3
+ generateCMPTests('activobank.pt', [
4
+ 'https://www.activobank.pt/en/'
5
+ ], {
6
+ });