@duckduckgo/autoconsent 7.0.0 → 8.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/CHANGELOG.md +37 -0
- package/build.sh +1 -1
- package/data/coverage.json +1014 -937
- package/dist/addon-firefox/background.bundle.js +3 -0
- package/dist/addon-firefox/content.bundle.js +13 -12
- package/dist/addon-firefox/manifest.json +1 -1
- package/dist/addon-firefox/rules.json +111 -187
- package/dist/addon-mv3/background.bundle.js +3 -0
- package/dist/addon-mv3/content.bundle.js +13 -12
- package/dist/addon-mv3/manifest.json +1 -1
- package/dist/addon-mv3/rules.json +111 -187
- package/dist/autoconsent.cjs.js +13 -12
- package/dist/autoconsent.esm.js +13 -12
- package/dist/autoconsent.playwright.js +1 -1
- package/lib/cmps/evidon.ts +1 -1
- package/lib/cmps/trustarc-top.ts +1 -1
- package/lib/eval-snippets.ts +3 -0
- package/lib/rule-executors.ts +4 -4
- package/lib/rules.ts +1 -6
- package/lib/utils.ts +3 -5
- package/lib/web.ts +1 -1
- package/package.json +2 -2
- package/readme.md +37 -28
- package/rules/autoconsent/1password-com.json +1 -1
- package/rules/autoconsent/agolde-com.json +1 -1
- package/rules/autoconsent/altium-com.json +1 -1
- package/rules/autoconsent/aquasana-com.json +1 -1
- package/rules/autoconsent/athlinks-com.json +1 -1
- package/rules/autoconsent/ausopen.json +1 -1
- package/rules/autoconsent/baden-wuerttemberg-de.json +1 -1
- package/rules/autoconsent/bbb.json +1 -1
- package/rules/autoconsent/burpee-com.json +1 -1
- package/rules/autoconsent/cc-banner.json +1 -1
- package/rules/autoconsent/clustrmaps-com.json +1 -1
- package/rules/autoconsent/complianz-notice.json +1 -1
- package/rules/autoconsent/cookie-law-info.json +1 -1
- package/rules/autoconsent/cookie-notice.json +1 -1
- package/rules/autoconsent/cookieinformation.json +1 -1
- package/rules/autoconsent/cookieyes.json +1 -1
- package/rules/autoconsent/crossfit-com.json +1 -1
- package/rules/autoconsent/dailymotion-us.json +1 -1
- package/rules/autoconsent/delta-com.json +1 -1
- package/rules/autoconsent/dsgvo.json +1 -1
- package/rules/autoconsent/eu-cookie-compliance.json +1 -1
- package/rules/autoconsent/eu-cookie-law.json +1 -1
- package/rules/autoconsent/geeks-for-geeks.json +1 -1
- package/rules/autoconsent/generic-cosmetic.json +1 -1
- package/rules/autoconsent/hl-co-uk.json +1 -1
- package/rules/autoconsent/indeed-com.json +1 -1
- package/rules/autoconsent/itopvpn-com.json +1 -1
- package/rules/autoconsent/iwink.json +19 -0
- package/rules/autoconsent/jquery-cookiebar.json +1 -1
- package/rules/autoconsent/macpaw-com.json +1 -1
- package/rules/autoconsent/marksandspencer.json +1 -1
- package/rules/autoconsent/midway-usa.json +1 -1
- package/rules/autoconsent/moove.json +1 -1
- package/rules/autoconsent/nba-com.json +1 -1
- package/rules/autoconsent/netflix-de.json +1 -1
- package/rules/autoconsent/notice-cookie.json +1 -1
- package/rules/autoconsent/nrk-no.json +1 -1
- package/rules/autoconsent/osano.json +1 -1
- package/rules/autoconsent/pinetools-com.json +1 -1
- package/rules/autoconsent/pmc-cmp.json +1 -1
- package/rules/autoconsent/pornhub.json +1 -1
- package/rules/autoconsent/pornpics.json +1 -1
- package/rules/autoconsent/primebox.json +1 -1
- package/rules/autoconsent/samsung-com.json +1 -1
- package/rules/autoconsent/similarweb-com.json +1 -1
- package/rules/autoconsent/takealot-com.json +1 -1
- package/rules/autoconsent/tealium.json +19 -6
- package/rules/autoconsent/testcmp-cosmetic.json +1 -1
- package/rules/autoconsent/tidbits-com.json +1 -1
- package/rules/autoconsent/tractor-supply.json +1 -1
- package/rules/autoconsent/trader-joes-com.json +1 -1
- package/rules/autoconsent/true-car.json +1 -1
- package/rules/autoconsent/tumblr-com.json +1 -1
- package/rules/autoconsent/twitch.json +1 -1
- package/rules/autoconsent/uk-cookie-consent.json +1 -1
- package/rules/autoconsent/urbanarmorgear-com.json +1 -1
- package/rules/autoconsent/whitepages.json +1 -1
- package/rules/autoconsent/wpcc.json +1 -1
- package/rules/autoconsent/xhamster-us.json +1 -1
- package/rules/autoconsent/xnxx-com.json +1 -1
- package/rules/autoconsent/youporn.json +1 -1
- package/rules/rules.json +111 -187
- package/tests/iwink.spec.ts +8 -0
- package/tests/tealium.spec.ts +6 -0
package/lib/cmps/evidon.ts
CHANGED
|
@@ -30,7 +30,7 @@ export default class Evidon extends AutoConsentCMPBase {
|
|
|
30
30
|
return true;
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
-
hideElements(getStyleElement(),
|
|
33
|
+
hideElements(getStyleElement(), "#evidon-prefdiag-overlay,#evidon-prefdiag-background");
|
|
34
34
|
click("#_evidon-option-button");
|
|
35
35
|
|
|
36
36
|
await waitForElement("#evidon-prefdiag-overlay", 5000);
|
package/lib/cmps/trustarc-top.ts
CHANGED
|
@@ -73,7 +73,7 @@ export default class TrustArcTop extends AutoConsentCMPBase {
|
|
|
73
73
|
// hide elements permanently, so user doesn't see the popup
|
|
74
74
|
hideElements(
|
|
75
75
|
getStyleElement(),
|
|
76
|
-
|
|
76
|
+
`.truste_popframe, .truste_overlay, .truste_box_overlay, ${bannerContainer}`,
|
|
77
77
|
);
|
|
78
78
|
click(cookieSettingsButton);
|
|
79
79
|
|
package/lib/eval-snippets.ts
CHANGED
|
@@ -59,6 +59,7 @@ export const snippets = {
|
|
|
59
59
|
EVAL_GOOGLE_0: () => !!document.cookie.match(/SOCS=CAE/),
|
|
60
60
|
EVAL_IUBENDA_0: () => document.querySelectorAll('.purposes-item input[type=checkbox]:not([disabled])').forEach(x => {if(x.checked) x.click()}) || true,
|
|
61
61
|
EVAL_IUBENDA_1: () => !!document.cookie.match(/_iub_cs-\d+=/),
|
|
62
|
+
EVAL_IWINK_TEST: () => document.cookie.includes('cookie_permission_granted=no'),
|
|
62
63
|
EVAL_JQUERY_COOKIEBAR_0: () => !document.cookie.includes('cookies-state=accepted'),
|
|
63
64
|
EVAL_MEDIAVINE_0: () => document.querySelectorAll("[data-name=\"mediavine-gdpr-cmp\"] input[type=checkbox]").forEach(x => x.checked && x.click()) || true,
|
|
64
65
|
EVAL_MICROSOFT_0: () => Array.from(document.querySelectorAll('div > button')).filter(el => el.innerText.match('Reject|Ablehnen'))[0].click() || true,
|
|
@@ -81,8 +82,10 @@ export const snippets = {
|
|
|
81
82
|
EVAL_TARTEAUCITRON_2: () => document.cookie.match(/tarteaucitron=[^;]*/)[0].includes('false'),
|
|
82
83
|
EVAL_TEALIUM_0: () => typeof window.utag !== 'undefined' && typeof utag.gdpr === 'object',
|
|
83
84
|
EVAL_TEALIUM_1: () => utag.gdpr.setConsentValue(false) || true,
|
|
85
|
+
EVAL_TEALIUM_DONOTSELL: () => utag.gdpr.dns?.setDnsState(false) || true,
|
|
84
86
|
EVAL_TEALIUM_2: () => utag.gdpr.setConsentValue(true) || true,
|
|
85
87
|
EVAL_TEALIUM_3: () => utag.gdpr.getConsentState() !== 1,
|
|
88
|
+
EVAL_TEALIUM_DONOTSELL_CHECK: () => utag.gdpr.dns?.getDnsState() !== 1,
|
|
86
89
|
EVAL_TESTCMP_0: () => window.results.results[0] === 'button_clicked',
|
|
87
90
|
EVAL_TESTCMP_COSMETIC_0: () => window.results.results[0] === 'banner_hidden',
|
|
88
91
|
EVAL_THEFREEDICTIONARY_0: () => cmpUi.showPurposes() || cmpUi.rejectAll() || true,
|
package/lib/rule-executors.ts
CHANGED
|
@@ -78,16 +78,16 @@ export function wait(ms: number): Promise<true> {
|
|
|
78
78
|
});
|
|
79
79
|
}
|
|
80
80
|
|
|
81
|
-
export function hide(
|
|
81
|
+
export function hide(selector: string, method: HideMethod): boolean {
|
|
82
82
|
// enableLogs && console.log("[hide]", ruleStep.hide, ruleStep.method);
|
|
83
83
|
const styleEl = getStyleElement();
|
|
84
|
-
return hideElements(styleEl,
|
|
84
|
+
return hideElements(styleEl, selector, method);
|
|
85
85
|
}
|
|
86
86
|
|
|
87
|
-
export function prehide(
|
|
87
|
+
export function prehide(selector: string): boolean {
|
|
88
88
|
const styleEl = getStyleElement('autoconsent-prehide');
|
|
89
89
|
enableLogs && console.log("[prehide]", styleEl, location.href);
|
|
90
|
-
return hideElements(styleEl,
|
|
90
|
+
return hideElements(styleEl, selector, "opacity");
|
|
91
91
|
}
|
|
92
92
|
|
|
93
93
|
export function undoPrehide(): boolean {
|
package/lib/rules.ts
CHANGED
|
@@ -32,7 +32,6 @@ export type AutoConsentRuleStep = { optional?: boolean } &
|
|
|
32
32
|
Partial<ClickRule> &
|
|
33
33
|
Partial<WaitForThenClickRule> &
|
|
34
34
|
Partial<WaitRule> &
|
|
35
|
-
Partial<UrlRule> &
|
|
36
35
|
Partial<HideRule> &
|
|
37
36
|
Partial<IfRule> &
|
|
38
37
|
Partial<AnyRule>
|
|
@@ -78,14 +77,10 @@ export type WaitRule = {
|
|
|
78
77
|
wait: number;
|
|
79
78
|
};
|
|
80
79
|
|
|
81
|
-
export type UrlRule = {
|
|
82
|
-
url: string;
|
|
83
|
-
};
|
|
84
|
-
|
|
85
80
|
export type HideMethod = 'display' | 'opacity';
|
|
86
81
|
|
|
87
82
|
export type HideRule = {
|
|
88
|
-
hide: string
|
|
83
|
+
hide: string;
|
|
89
84
|
method?: HideMethod;
|
|
90
85
|
};
|
|
91
86
|
|
package/lib/utils.ts
CHANGED
|
@@ -21,17 +21,15 @@ export function getStyleElement(styleOverrideElementId = "autoconsent-css-rules"
|
|
|
21
21
|
// hide elements with a CSS rule
|
|
22
22
|
export function hideElements(
|
|
23
23
|
styleEl: HTMLStyleElement,
|
|
24
|
-
|
|
24
|
+
selector: string,
|
|
25
25
|
method: HideMethod = 'display',
|
|
26
26
|
): boolean {
|
|
27
27
|
const hidingSnippet = method === "opacity" ? `opacity: 0` : `display: none`; // use display by default
|
|
28
|
-
const rule = `${
|
|
29
|
-
","
|
|
30
|
-
)} { ${hidingSnippet} !important; z-index: -1 !important; pointer-events: none !important; } `;
|
|
28
|
+
const rule = `${selector} { ${hidingSnippet} !important; z-index: -1 !important; pointer-events: none !important; } `;
|
|
31
29
|
|
|
32
30
|
if (styleEl instanceof HTMLStyleElement) {
|
|
33
31
|
styleEl.innerText += rule;
|
|
34
|
-
return
|
|
32
|
+
return selector.length > 0;
|
|
35
33
|
}
|
|
36
34
|
return false;
|
|
37
35
|
}
|
package/lib/web.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@duckduckgo/autoconsent",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "8.0.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/autoconsent.cjs.js",
|
|
6
6
|
"module": "dist/autoconsent.esm.js",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"@typescript-eslint/parser": "^6.12.0",
|
|
40
40
|
"auto": "^11.0.1",
|
|
41
41
|
"bulma": "^0.9.4",
|
|
42
|
-
"chai": "^
|
|
42
|
+
"chai": "^5.0.0",
|
|
43
43
|
"chokidar-cli": "^3.0.0",
|
|
44
44
|
"esbuild": "^0.19.2",
|
|
45
45
|
"eslint": "^8.27.0",
|
package/readme.md
CHANGED
|
@@ -37,7 +37,7 @@ that are installed on multiple sites. Each CMP ruleset defines:
|
|
|
37
37
|
|
|
38
38
|
There are currently three ways of implementing a CMP:
|
|
39
39
|
|
|
40
|
-
1. As a [JSON ruleset](./rules/autoconsent/), intepreted by the `AutoConsent` class.
|
|
40
|
+
1. As a [JSON ruleset](./rules/autoconsent/), intepreted by the `AutoConsent` class.
|
|
41
41
|
1. As a class implementing the `AutoCMP` interface. This enables more complex logic than the linear AutoConsent
|
|
42
42
|
rulesets allow.
|
|
43
43
|
3. As a [Consent-O-Matic](https://github.com/cavi-au/Consent-O-Matic) rule. The `ConsentOMaticCMP` class implements
|
|
@@ -79,36 +79,45 @@ Both JSON and class implementations have the following components:
|
|
|
79
79
|
|
|
80
80
|
### Element selectors
|
|
81
81
|
|
|
82
|
-
|
|
82
|
+
Many rules use `ElementSelector` to locate elements in a page. `ElementSelector` can be a string, or array of strings, which are used to locate elements as follows:
|
|
83
83
|
- By default, strings are treated as [CSS Selectors](https://developer.mozilla.org/en-US/docs/Web/API/Document_object_model/Locating_DOM_elements_using_selectors) via the `querySelector` API. e.g. `#reject-cookies` to find an element whose `id` is 'reject-cookies'.
|
|
84
|
-
-
|
|
85
|
-
- If an array of
|
|
86
|
-
|
|
84
|
+
- Strings prefixed with `xpath/` are [Xpath](https://developer.mozilla.org/en-US/docs/Web/XPath) selectors which can locate elements in the page via [`document.evaluate`](https://developer.mozilla.org/en-US/docs/Web/XPath/Introduction_to_using_XPath_in_JavaScript#document.evaluate). e.g. `xpath///*[@id="reject-cookies"]` can find an element whose `id` is 'reject-cookies'.
|
|
85
|
+
- If an array of strings is given, the selectors are applied in array order, with the search scope constrained each time but the first match of the previous selector. e.g. `['#reject-cookies', 'button']` first looks for an element with `id="reject-cookies"`, then looks for a match for `button` _that is a descendant_ of that element.
|
|
86
|
+
**If one of the selectors returns an element that has a `shadowRoot` property, the next selector will run within that element's shadow DOM.** This is the main difference from nested CSS selectors, which do not cross shadow DOM boundaries.
|
|
87
|
+
|
|
88
|
+
For example, consider the following DOM fragment:
|
|
89
|
+
```html
|
|
90
|
+
<open-shadow-root-element>
|
|
91
|
+
<button>X</button>
|
|
92
|
+
</open-shadow-root-element>
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
Then `['open-shadow-root-element', 'button']` will find the button, but a usual CSS selector `'open-shadow-root-element button'` will not.
|
|
87
96
|
|
|
88
97
|
### Element exists
|
|
89
98
|
|
|
90
|
-
```
|
|
99
|
+
```javascript
|
|
91
100
|
{
|
|
92
|
-
"exists":
|
|
101
|
+
"exists": ElementSelector
|
|
93
102
|
}
|
|
94
103
|
```
|
|
95
104
|
Returns true if the given selector matches one or more elements.
|
|
96
105
|
|
|
97
106
|
### Element visible
|
|
98
107
|
|
|
99
|
-
```
|
|
108
|
+
```javascript
|
|
100
109
|
{
|
|
101
|
-
"visible":
|
|
110
|
+
"visible": ElementSelector,
|
|
102
111
|
"check": "any" | "all" | "none"
|
|
103
112
|
}
|
|
104
113
|
```
|
|
105
|
-
Returns true if elements
|
|
114
|
+
Returns true if elements matched by ElementSelector are currently visible on the page. If `check` is `all`, every element must be visible. If `check` is `none`, no element should be visible. Visibility check is a CSS-based heuristic.
|
|
106
115
|
|
|
107
116
|
### Wait for element
|
|
108
117
|
|
|
109
|
-
```
|
|
118
|
+
```javascript
|
|
110
119
|
{
|
|
111
|
-
"waitFor":
|
|
120
|
+
"waitFor": ElementSelector,
|
|
112
121
|
"timeout": 1000
|
|
113
122
|
}
|
|
114
123
|
```
|
|
@@ -116,9 +125,9 @@ Waits until `selector` exists in the page. After `timeout` ms the step fails.
|
|
|
116
125
|
|
|
117
126
|
### Wait for visibility
|
|
118
127
|
|
|
119
|
-
```
|
|
128
|
+
```javascript
|
|
120
129
|
{
|
|
121
|
-
"waitForVisible":
|
|
130
|
+
"waitForVisible": ElementSelector,
|
|
122
131
|
"timeout": 1000,
|
|
123
132
|
"check": "any" | "all" | "none"
|
|
124
133
|
}
|
|
@@ -126,18 +135,18 @@ Waits until `selector` exists in the page. After `timeout` ms the step fails.
|
|
|
126
135
|
Waits until element is visible in the page. After `timeout` ms the step fails.
|
|
127
136
|
|
|
128
137
|
### Click an element
|
|
129
|
-
```
|
|
138
|
+
```javascript
|
|
130
139
|
{
|
|
131
|
-
"click":
|
|
140
|
+
"click": ElementSelector,
|
|
132
141
|
"all": true | false,
|
|
133
142
|
}
|
|
134
143
|
```
|
|
135
144
|
Click on an element returned by `selector`. If `all` is `true`, all matching elements are clicked. If `all` is `false`, only the first returned value is clicked.
|
|
136
145
|
|
|
137
146
|
### Wait for then click
|
|
138
|
-
```
|
|
147
|
+
```javascript
|
|
139
148
|
{
|
|
140
|
-
"waitForThenClick":
|
|
149
|
+
"waitForThenClick": ElementSelector,
|
|
141
150
|
"timeout": 1000,
|
|
142
151
|
"all": true | false
|
|
143
152
|
}
|
|
@@ -145,7 +154,7 @@ Click on an element returned by `selector`. If `all` is `true`, all matching ele
|
|
|
145
154
|
Combines `waitFor` and `click`.
|
|
146
155
|
|
|
147
156
|
### Unconditional wait
|
|
148
|
-
```
|
|
157
|
+
```javascript
|
|
149
158
|
{
|
|
150
159
|
"wait": 1000,
|
|
151
160
|
}
|
|
@@ -153,17 +162,17 @@ Combines `waitFor` and `click`.
|
|
|
153
162
|
Wait for the specified number of milliseconds.
|
|
154
163
|
|
|
155
164
|
### Hide
|
|
156
|
-
```
|
|
165
|
+
```javascript
|
|
157
166
|
{
|
|
158
|
-
"hide":
|
|
167
|
+
"hide": "CSS selector",
|
|
159
168
|
"method": "display" | "opacity"
|
|
160
169
|
}
|
|
161
170
|
```
|
|
162
|
-
Hide the elements matched by the selectors. `method` defines how elements are hidden: "display" sets `display: none`, "opacity" sets `opacity: 0`. Method is "display" by default.
|
|
171
|
+
Hide the elements matched by the selectors. `method` defines how elements are hidden: "display" sets `display: none`, "opacity" sets `opacity: 0`. Method is "display" by default. Note that only a single string CSS selector is supported here, not an array.
|
|
163
172
|
|
|
164
173
|
### Eval
|
|
165
174
|
|
|
166
|
-
```
|
|
175
|
+
```javascript
|
|
167
176
|
{
|
|
168
177
|
"eval": "SNIPPET_ID"
|
|
169
178
|
}
|
|
@@ -173,9 +182,9 @@ Eval rules are not 100% reliable because they can be affected by the page script
|
|
|
173
182
|
|
|
174
183
|
### Conditionals
|
|
175
184
|
|
|
176
|
-
```
|
|
185
|
+
```javascript
|
|
177
186
|
{
|
|
178
|
-
"if": { "exists":
|
|
187
|
+
"if": { "exists": ElementSelector },
|
|
179
188
|
"then": [
|
|
180
189
|
{ "click": ".button1" },
|
|
181
190
|
{ "click": ".button3" }
|
|
@@ -191,7 +200,7 @@ The "if" rule is considered successful as long as all rules inside the chosen br
|
|
|
191
200
|
|
|
192
201
|
### Any
|
|
193
202
|
|
|
194
|
-
```
|
|
203
|
+
```javascript
|
|
195
204
|
{
|
|
196
205
|
"any": [
|
|
197
206
|
{ "exists": ".button1" },
|
|
@@ -200,11 +209,11 @@ The "if" rule is considered successful as long as all rules inside the chosen br
|
|
|
200
209
|
}
|
|
201
210
|
```
|
|
202
211
|
|
|
203
|
-
Evaluates a list of steps in order. If any return true (success), then the step
|
|
212
|
+
Evaluates a list of steps in order. If any return true (success), then the step returns true. If all steps return false, the `any` step returns false.
|
|
204
213
|
|
|
205
214
|
### Optional actions
|
|
206
215
|
|
|
207
|
-
|
|
216
|
+
All rules can include the `"optional": true` to ignore failure.
|
|
208
217
|
|
|
209
218
|
## API
|
|
210
219
|
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
"detectPopup": [{ "visible": "footer #footer-root [aria-label=\"Cookie Consent\"]" }],
|
|
7
7
|
"optIn":
|
|
8
8
|
[{"click": "footer #footer-root [aria-label=\"Cookie Consent\"] button" }],
|
|
9
|
-
"optOut": [{ "hide":
|
|
9
|
+
"optOut": [{ "hide": "footer #footer-root [aria-label=\"Cookie Consent\"]" }]
|
|
10
10
|
}
|
|
11
11
|
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"detectCmp": [{ "exists": "#footer-container ~ div" }],
|
|
9
9
|
"detectPopup": [{ "visible": "#footer-container > div" }],
|
|
10
10
|
"optIn": [{"click": "#footer-container ~ div button" }],
|
|
11
|
-
"optOut": [{ "hide":
|
|
11
|
+
"optOut": [{ "hide": "#footer-container ~ div" }]
|
|
12
12
|
}
|
|
@@ -3,6 +3,6 @@
|
|
|
3
3
|
"cosmetic": true,
|
|
4
4
|
"detectCmp": [{ "exists": ".gdpr-popup__message" }],
|
|
5
5
|
"detectPopup": [{ "visible": ".gdpr-popup__message" }],
|
|
6
|
-
"optOut": [{ "hide":
|
|
6
|
+
"optOut": [{ "hide": ".gdpr-popup__message"}],
|
|
7
7
|
"optIn": [{ "click": ".gdpr-popup__message button"}]
|
|
8
8
|
}
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"detectCmp": [{ "exists": "div[aria-label=\"use of cookies on bbb.org\"]" }],
|
|
9
9
|
"detectPopup": [{ "visible": "div[aria-label=\"use of cookies on bbb.org\"]" }],
|
|
10
10
|
"optIn": [{ "click": "div[aria-label=\"use of cookies on bbb.org\"] button.bds-button-unstyled span.visually-hidden" }],
|
|
11
|
-
"optOut": [{ "hide":
|
|
11
|
+
"optOut": [{ "hide": "div[aria-label=\"use of cookies on bbb.org\"]" }]
|
|
12
12
|
}
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"detectCmp": [{ "exists": "#gdpr-cookie-message" }],
|
|
9
9
|
"detectPopup": [{ "visible": "#gdpr-cookie-message" }],
|
|
10
10
|
"optIn": [{ "click": "button#gdpr-cookie-accept" }],
|
|
11
|
-
"optOut": [{ "hide":
|
|
11
|
+
"optOut": [{ "hide": "#gdpr-cookie-message" }]
|
|
12
12
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"detectPopup": [{ "visible": "#cookie-information-template-wrapper" }],
|
|
6
6
|
"optIn": [ { "eval": "EVAL_COOKIEINFORMATION_1"} ],
|
|
7
7
|
"optOut": [
|
|
8
|
-
{ "hide":
|
|
8
|
+
{ "hide": "#cookie-information-template-wrapper", "comment": "some templates don't hide the banner automatically" },
|
|
9
9
|
{ "eval": "EVAL_COOKIEINFORMATION_0"}
|
|
10
10
|
],
|
|
11
11
|
"test": [
|
|
@@ -5,6 +5,6 @@
|
|
|
5
5
|
"detectCmp": [{ "exists": "body #modal > div > div[class^=\"_wrapper_\"]" }],
|
|
6
6
|
"detectPopup": [{ "visible": "body #modal > div > div[class^=\"_wrapper_\"]" }],
|
|
7
7
|
"optIn": [{"click": "button[aria-label=\"accept cookie policy\"]" }],
|
|
8
|
-
"optOut": [{ "hide":
|
|
8
|
+
"optOut": [{ "hide": "body #modal > div > div[class^=\"_wrapper_\"]" }]
|
|
9
9
|
}
|
|
10
10
|
|
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
"detectCmp": [{ "exists": "div[class*=\"CookiePopup__desktopContainer\"]" }],
|
|
6
6
|
"detectPopup": [{ "visible": "div[class*=\"CookiePopup__desktopContainer\"]" }],
|
|
7
7
|
"optIn": [{ "click": "div[class*=\"CookiePopup__desktopContainer\"] > button > span" }],
|
|
8
|
-
"optOut": [{ "hide":
|
|
8
|
+
"optOut": [{ "hide": "div[class*=\"CookiePopup__desktopContainer\"]" }]
|
|
9
9
|
}
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"detectCmp": [{ "exists": "div.cookie-footer-container" }],
|
|
9
9
|
"detectPopup": [{ "visible": "div.cookie-footer-container" }],
|
|
10
10
|
"optIn": [{ "click": " button.cookie-close-icon" }],
|
|
11
|
-
"optOut": [{ "hide":
|
|
11
|
+
"optOut": [{ "hide": "div.cookie-footer-container" }]
|
|
12
12
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"optIn": [{ "click": ".agree-button" }],
|
|
6
6
|
"optOut": [
|
|
7
7
|
{ "click": ".decline-button,.eu-cookie-compliance-save-preferences-button", "optional": true },
|
|
8
|
-
{ "hide":
|
|
8
|
+
{ "hide": ".eu-cookie-compliance-banner-info, #sliding-popup" }
|
|
9
9
|
],
|
|
10
10
|
"test": [
|
|
11
11
|
{ "eval": "EVAL_EU_COOKIE_COMPLIANCE_0" }
|
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
"detectCmp": [{ "exists": "#js-cookie-banner,.js-cookie-banner,.cookie-banner,#cookie-banner" }],
|
|
6
6
|
"detectPopup": [{ "visible": "#js-cookie-banner,.js-cookie-banner,.cookie-banner,#cookie-banner" }],
|
|
7
7
|
"optIn": [],
|
|
8
|
-
"optOut": [{ "hide":
|
|
8
|
+
"optOut": [{ "hide": "#js-cookie-banner,.js-cookie-banner,.cookie-banner,#cookie-banner" }]
|
|
9
9
|
}
|
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
"detectCmp": [{ "exists": "#CookiePrivacyNotice" }],
|
|
6
6
|
"detectPopup": [{ "visible": "#CookiePrivacyNotice" }],
|
|
7
7
|
"optIn": [{ "click": "#CookiePrivacyNotice button[data-gnav-element-name=CookiePrivacyNoticeOk]" }],
|
|
8
|
-
"optOut": [{ "hide":
|
|
8
|
+
"optOut": [{ "hide": "#CookiePrivacyNotice" }]
|
|
9
9
|
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "iWink",
|
|
3
|
+
"prehideSelectors": ["body.cookies-request #cookie-bar"],
|
|
4
|
+
"detectCmp": [
|
|
5
|
+
{ "exists": "body.cookies-request #cookie-bar" }
|
|
6
|
+
],
|
|
7
|
+
"detectPopup": [
|
|
8
|
+
{ "visible": "body.cookies-request #cookie-bar" }
|
|
9
|
+
],
|
|
10
|
+
"optIn": [
|
|
11
|
+
{ "waitForThenClick": "body.cookies-request #cookie-bar .allow-cookies" }
|
|
12
|
+
],
|
|
13
|
+
"optOut": [
|
|
14
|
+
{ "waitForThenClick": "body.cookies-request #cookie-bar .disallow-cookies" }
|
|
15
|
+
],
|
|
16
|
+
"test": [
|
|
17
|
+
{"eval": "EVAL_IWINK_TEST"}
|
|
18
|
+
]
|
|
19
|
+
}
|
|
@@ -3,6 +3,6 @@
|
|
|
3
3
|
"cosmetic": true,
|
|
4
4
|
"detectCmp": [{ "exists": ".navigation-cookiebbanner" }],
|
|
5
5
|
"detectPopup": [{ "visible": ".navigation-cookiebbanner" }],
|
|
6
|
-
"optOut": [{ "hide":
|
|
6
|
+
"optOut": [{ "hide": ".navigation-cookiebbanner"}],
|
|
7
7
|
"optIn": [{ "click": ".navigation-cookiebbanner__submit"}]
|
|
8
8
|
}
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"detectCmp": [{ "exists": ["div[aria-label=\"Cookie Policy Banner\"]"] }],
|
|
9
9
|
"detectPopup": [{ "visible": "#cookie-container" }],
|
|
10
10
|
"optIn": [{ "click": "button#cookie-btn" }],
|
|
11
|
-
"optOut": [{ "hide":
|
|
11
|
+
"optOut": [{ "hide": "div[aria-label=\"Cookie Policy Banner\"]" }]
|
|
12
12
|
}
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
"detectCmp": [{ "exists": "#onetrust-banner-sdk" }],
|
|
9
9
|
"detectPopup": [{ "visible": "#onetrust-banner-sdk" }],
|
|
10
10
|
"optIn": [{ "click": "#onetrust-accept-btn-handler" }],
|
|
11
|
-
"optOut": [{ "hide":
|
|
11
|
+
"optOut": [{ "hide": "#onetrust-banner-sdk"}]
|
|
12
12
|
}
|
|
@@ -3,5 +3,5 @@
|
|
|
3
3
|
"detectCmp": [{ "exists": "#cookie-disclosure" }],
|
|
4
4
|
"detectPopup": [{ "visible": ".cookie-disclosure-message", "check": "any" }],
|
|
5
5
|
"optIn": [{ "click": ".btn-accept" }],
|
|
6
|
-
"optOut": [{"hide":
|
|
6
|
+
"optOut": [{"hide": "#cookie-disclosure"}, {"click": ".btn-reject"}]
|
|
7
7
|
}
|