@duckduckgo/autoconsent 16.47.0 → 16.49.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/.agents/skills/optimize-button-patterns/SKILL.md +145 -0
- package/.agents/skills/oxylabs-testing/SKILL.md +1 -1
- package/.claude/skills/optimize-button-patterns/SKILL.md +7 -0
- package/AGENTS.md +5 -0
- package/CHANGELOG.md +56 -0
- package/data/Readme.md +6 -0
- package/data/labelled-button-texts.csv +7006 -0
- package/dist/addon-firefox/background.bundle.js +2 -0
- package/dist/addon-firefox/compact-rules.json +1 -1
- package/dist/addon-firefox/content.bundle.js +6 -7
- package/dist/addon-firefox/manifest.json +1 -1
- package/dist/addon-firefox/rule-index.json +1 -1
- package/dist/addon-firefox/rules.json +1 -1
- package/dist/addon-mv3/background.bundle.js +2 -0
- package/dist/addon-mv3/compact-rules.json +1 -1
- package/dist/addon-mv3/content.bundle.js +6 -7
- package/dist/addon-mv3/manifest.json +1 -1
- package/dist/addon-mv3/rule-index.json +1 -1
- package/dist/addon-mv3/rules.json +1 -1
- package/dist/autoconsent.cjs.js +6 -7
- package/dist/autoconsent.esm.js +6 -7
- package/dist/autoconsent.playwright.js +6 -7
- package/dist/autoconsent.standalone.js +7 -8
- package/dist/types/eval-snippets.d.ts +1 -0
- package/lib/eval-snippets.ts +3 -0
- package/lib/heuristic-patterns.ts +4 -8
- package/package.json +3 -1
- package/rules/autoconsent/borlabs.json +5 -0
- package/rules/autoconsent/burpee-com.json +13 -7
- package/rules/autoconsent/consentmo.json +51 -7
- package/rules/autoconsent/cookie-popup-close-cookies.json +37 -0
- package/rules/autoconsent/cookieconsent2.json +6 -1
- package/rules/autoconsent/costco.json +27 -0
- package/rules/autoconsent/datasign.json +85 -0
- package/rules/autoconsent/ensembleartsphilly.json +33 -0
- package/rules/autoconsent/evium.de.json +33 -0
- package/rules/autoconsent/iubenda.json +13 -7
- package/rules/autoconsent/pandectes.json +48 -15
- package/rules/autoconsent/passle.json +32 -0
- package/rules/autoconsent/pmc-privacy-banner.json +9 -0
- package/rules/autoconsent/primeconsent.json +39 -0
- package/rules/autoconsent/shinden.pl.json +34 -0
- package/rules/autoconsent/tealium.json +1 -1
- package/rules/autoconsent/tri-table.json +14 -0
- package/rules/autoconsent/truevault-polaris.json +63 -0
- package/rules/autoconsent/webflow.json +1 -1
- package/rules/autoconsent/wix.json +90 -8
- package/rules/compact-rules.json +1 -1
- package/rules/rule-index.json +1 -1
- package/rules/rules.json +1 -1
- package/scripts/benchmark-button-classification.ts +75 -0
- package/scripts/button-text-benchmark.ts +102 -0
- package/tests/borlabs.spec.ts +7 -3
- package/tests/burpee-com.spec.ts +10 -4
- package/tests/consentmo.spec.ts +1 -0
- package/tests/cookie-popup-close-cookies.spec.ts +10 -0
- package/tests/cookieconsent2.spec.ts +6 -1
- package/tests/costco.spec.ts +5 -0
- package/tests/datasign.spec.ts +8 -0
- package/tests/ensembleartsphilly.spec.ts +6 -0
- package/tests/evium.de.spec.ts +5 -0
- package/tests/iubenda.spec.ts +6 -0
- package/tests/pandectes.spec.ts +20 -1
- package/tests/passle.spec.ts +8 -0
- package/tests/pmc-privacy-banner.spec.ts +8 -0
- package/tests/primeconsent.spec.ts +11 -0
- package/tests/shinden.pl.spec.ts +5 -0
- package/tests/tealium.spec.ts +8 -6
- package/tests/tri-table.spec.ts +5 -0
- package/tests/truevault-polaris.spec.ts +9 -0
- package/tests/webflow.spec.ts +7 -1
- package/tests/wix.spec.ts +8 -1
- package/tests-wtr/heuristics/button-classification-accuracy.test.ts +41 -0
- package/tests-wtr/heuristics/heuristics-utils.test.ts +9 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "shinden.pl",
|
|
3
|
+
"vendorUrl": "https://shinden.pl/",
|
|
4
|
+
"runContext": {
|
|
5
|
+
"urlPattern": "^https?://(www\\.)?shinden\\.pl/"
|
|
6
|
+
},
|
|
7
|
+
"prehideSelectors": ["#cookie-bar"],
|
|
8
|
+
"detectCmp": [{ "exists": "#cookie-bar .cb-enable,[class^=\"app_gdpr--\"] button" }],
|
|
9
|
+
"detectPopup": [{ "visible": "#cookie-bar .cb-enable,[class^=\"app_gdpr--\"] button", "check": "any" }],
|
|
10
|
+
"optIn": [
|
|
11
|
+
{ "click": "#cookie-bar .cb-enable", "optional": true },
|
|
12
|
+
{ "waitForVisible": "[class^=\"app_gdpr--\"] button", "timeout": 10000, "optional": true },
|
|
13
|
+
{
|
|
14
|
+
"if": { "visible": "[class^=\"app_gdpr--\"] button" },
|
|
15
|
+
"then": [{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:last-of-type:nth-of-type(2)" }]
|
|
16
|
+
}
|
|
17
|
+
],
|
|
18
|
+
"optOut": [
|
|
19
|
+
{ "hide": "#cookie-bar" },
|
|
20
|
+
{ "waitForVisible": "[class^=\"app_gdpr--\"] button", "timeout": 10000, "optional": true },
|
|
21
|
+
{
|
|
22
|
+
"if": { "visible": "[class^=\"app_gdpr--\"] button" },
|
|
23
|
+
"then": [
|
|
24
|
+
{
|
|
25
|
+
"waitForThenClick": "[class^=\"app_gdpr--\"] div > button:first-of-type:nth-last-of-type(2)",
|
|
26
|
+
"retry": 2,
|
|
27
|
+
"retryInterval": 500
|
|
28
|
+
},
|
|
29
|
+
{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:nth-of-type(2):nth-last-of-type(2)" },
|
|
30
|
+
{ "waitForVisible": "[class^=\"app_gdpr--\"] button", "check": "none" }
|
|
31
|
+
]
|
|
32
|
+
}
|
|
33
|
+
]
|
|
34
|
+
}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
{ "eval": "EVAL_TEALIUM_DONOTSELL" },
|
|
9
9
|
{ "hide": "#__tealiumGDPRecModal,#__tealiumGDPRcpPrefs,#__tealiumImplicitmodal" },
|
|
10
10
|
{
|
|
11
|
-
"waitForThenClick": "#cm-acceptNone,.js-accept-essential-cookies,#continueWithoutAccepting,#no_consent,#consent_prompt_decline",
|
|
11
|
+
"waitForThenClick": "#cm-acceptNone,.js-accept-essential-cookies,#continueWithoutAccepting,#no_consent,#consent_prompt_decline,#teal-decline-consent",
|
|
12
12
|
"timeout": 1000,
|
|
13
13
|
"optional": true
|
|
14
14
|
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tri-table",
|
|
3
|
+
"vendorUrl": "https://tri-table.com/",
|
|
4
|
+
"prehideSelectors": [],
|
|
5
|
+
"detectCmp": [{ "exists": "[class^=\"app_gdpr--\"] button" }],
|
|
6
|
+
"detectPopup": [{ "visible": "[class^=\"app_gdpr--\"] button" }],
|
|
7
|
+
"optIn": [{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:last-of-type:nth-of-type(2)" }],
|
|
8
|
+
"optOut": [
|
|
9
|
+
{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:first-of-type:nth-last-of-type(2)", "retry": 2, "retryInterval": 500 },
|
|
10
|
+
{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:nth-of-type(2):nth-last-of-type(2)" },
|
|
11
|
+
{ "waitForVisible": "[class^=\"app_gdpr--\"] button", "check": "none" }
|
|
12
|
+
],
|
|
13
|
+
"test": [{ "cookieContains": "tt_cons_addtl=" }]
|
|
14
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "truevault-polaris",
|
|
3
|
+
"vendorUrl": "https://www.truevault.com/",
|
|
4
|
+
"cosmetic": false,
|
|
5
|
+
"prehideSelectors": [],
|
|
6
|
+
"detectCmp": [
|
|
7
|
+
{
|
|
8
|
+
"exists": ["#polaris-css-lockdown-container", "#polaris-consent-widgets .polaris-consent-widget"]
|
|
9
|
+
}
|
|
10
|
+
],
|
|
11
|
+
"detectPopup": [
|
|
12
|
+
{
|
|
13
|
+
"visible": ["#polaris-css-lockdown-container", "#polaris-consent-widgets .polaris-consent-widget"]
|
|
14
|
+
}
|
|
15
|
+
],
|
|
16
|
+
"optIn": [
|
|
17
|
+
{
|
|
18
|
+
"waitForThenClick": ["#polaris-css-lockdown-container", ".polaris-consent-widget__actions button:last-child"]
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
"optOut": [
|
|
22
|
+
{
|
|
23
|
+
"if": {
|
|
24
|
+
"exists": ["#polaris-css-lockdown-container", ".polaris-consent-widget__actions button:nth-child(2):not(:last-child)"]
|
|
25
|
+
},
|
|
26
|
+
"then": [
|
|
27
|
+
{
|
|
28
|
+
"click": ["#polaris-css-lockdown-container", ".polaris-consent-widget__actions button:nth-child(2):not(:last-child)"]
|
|
29
|
+
}
|
|
30
|
+
],
|
|
31
|
+
"else": [
|
|
32
|
+
{
|
|
33
|
+
"click": ["#polaris-css-lockdown-container", ".polaris-consent-widget__actions button:first-child"]
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"waitFor": ["#polaris-css-lockdown-container", ".polaris-preferences-widget__save_button"],
|
|
37
|
+
"timeout": 2000
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"click": [
|
|
41
|
+
"#polaris-css-lockdown-container",
|
|
42
|
+
".polaris-preferences-widget input[type=checkbox]:checked:not([disabled])"
|
|
43
|
+
],
|
|
44
|
+
"all": true,
|
|
45
|
+
"optional": true
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"click": ["#polaris-css-lockdown-container", ".polaris-preferences-widget__save_button"]
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
],
|
|
53
|
+
"test": [
|
|
54
|
+
{
|
|
55
|
+
"waitForVisible": ["#polaris-css-lockdown-container", "#polaris-consent-widgets .polaris-consent-widget"],
|
|
56
|
+
"check": "none",
|
|
57
|
+
"timeout": 2000
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"cookieContains": "\"adsPermitted\":false"
|
|
61
|
+
}
|
|
62
|
+
]
|
|
63
|
+
}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"prehideSelectors": [".fs-cc-components,[fs-cc=banner]"],
|
|
5
5
|
"detectCmp": [
|
|
6
6
|
{
|
|
7
|
-
"visible": ".fs-cc-components,[fs-cc=banner]"
|
|
7
|
+
"any": [{ "visible": ".fs-cc-components,[fs-cc=banner]" }, { "exists": "script[src*=\"@finsweet/cookie-consent\"]" }]
|
|
8
8
|
}
|
|
9
9
|
],
|
|
10
10
|
"detectPopup": [
|
|
@@ -5,26 +5,108 @@
|
|
|
5
5
|
"prehideSelectors": [],
|
|
6
6
|
"detectCmp": [
|
|
7
7
|
{
|
|
8
|
-
"exists": "[data-comp-type=cookie-banner-root-wix],[data-hook=ccsu-banner-wrapper]"
|
|
8
|
+
"exists": "[data-comp-type=cookie-banner-root-wix],[data-hook=ccsu-banner-wrapper],[data-comp-type=cookie-banner-root-uou]"
|
|
9
9
|
}
|
|
10
10
|
],
|
|
11
11
|
"detectPopup": [
|
|
12
12
|
{
|
|
13
|
-
"visible": "[data-comp-type=cookie-banner-root-wix],[data-hook=ccsu-banner-wrapper]"
|
|
13
|
+
"visible": "[data-comp-type=cookie-banner-root-wix],[data-hook=ccsu-banner-wrapper],[data-comp-type=cookie-banner-root-uou]"
|
|
14
14
|
}
|
|
15
15
|
],
|
|
16
16
|
"optIn": [
|
|
17
17
|
{
|
|
18
|
-
"if": {
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
"if": {
|
|
19
|
+
"exists": "[data-hook=consent-banner-apply-button]"
|
|
20
|
+
},
|
|
21
|
+
"then": [
|
|
22
|
+
{
|
|
23
|
+
"click": "[data-hook=consent-banner-apply-button]"
|
|
24
|
+
}
|
|
25
|
+
],
|
|
26
|
+
"else": [
|
|
27
|
+
{
|
|
28
|
+
"if": {
|
|
29
|
+
"exists": "[data-hook=ccsu-banner-accept]"
|
|
30
|
+
},
|
|
31
|
+
"then": [
|
|
32
|
+
{
|
|
33
|
+
"click": "[data-hook=ccsu-banner-accept]"
|
|
34
|
+
}
|
|
35
|
+
],
|
|
36
|
+
"else": [
|
|
37
|
+
{
|
|
38
|
+
"click": "[data-hook=ccsu-banner-decline]"
|
|
39
|
+
}
|
|
40
|
+
]
|
|
41
|
+
}
|
|
42
|
+
]
|
|
21
43
|
}
|
|
22
44
|
],
|
|
23
45
|
"optOut": [
|
|
24
46
|
{
|
|
25
|
-
"if": {
|
|
26
|
-
|
|
27
|
-
|
|
47
|
+
"if": {
|
|
48
|
+
"exists": "[data-comp-type=cookie-banner-root-uou]"
|
|
49
|
+
},
|
|
50
|
+
"then": [
|
|
51
|
+
{
|
|
52
|
+
"wait": 1000
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"if": {
|
|
56
|
+
"exists": "[data-hook=consent-banner-decline-all-button]"
|
|
57
|
+
},
|
|
58
|
+
"then": [
|
|
59
|
+
{
|
|
60
|
+
"click": "[data-hook=consent-banner-decline-all-button]"
|
|
61
|
+
}
|
|
62
|
+
],
|
|
63
|
+
"else": [
|
|
64
|
+
{
|
|
65
|
+
"click": "[data-hook=consent-banner-settings-button]"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"waitForVisible": "[data-hook=consent-banner-settings-save-button]"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"click": "[data-hook=consent-banner-section-toggle-input]:checked:not(:disabled)",
|
|
72
|
+
"all": true,
|
|
73
|
+
"optional": true
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"click": "[data-hook=consent-banner-settings-save-button]"
|
|
77
|
+
}
|
|
78
|
+
]
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"any": [
|
|
82
|
+
{
|
|
83
|
+
"waitForVisible": "[data-comp-type=cookie-banner-root-uou]",
|
|
84
|
+
"check": "none",
|
|
85
|
+
"timeout": 2000
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"hide": "[data-comp-type=cookie-banner-root-uou]"
|
|
89
|
+
}
|
|
90
|
+
]
|
|
91
|
+
}
|
|
92
|
+
],
|
|
93
|
+
"else": [
|
|
94
|
+
{
|
|
95
|
+
"if": {
|
|
96
|
+
"exists": "[data-hook=ccsu-banner-decline-all]"
|
|
97
|
+
},
|
|
98
|
+
"then": [
|
|
99
|
+
{
|
|
100
|
+
"click": "[data-hook=ccsu-banner-decline-all]"
|
|
101
|
+
}
|
|
102
|
+
],
|
|
103
|
+
"else": [
|
|
104
|
+
{
|
|
105
|
+
"hide": "[data-hook=ccsu-banner-wrapper]"
|
|
106
|
+
}
|
|
107
|
+
]
|
|
108
|
+
}
|
|
109
|
+
]
|
|
28
110
|
}
|
|
29
111
|
]
|
|
30
112
|
}
|