@duckduckgo/autoconsent 16.2.0 → 16.4.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/proxy-testing/scripts/regional-proxy.mjs +4 -1
- package/.github/PULL_REQUEST_TEMPLATE.md +2 -2
- package/.github/dependabot.yml +1 -1
- package/.github/labeler.yml +6 -6
- package/CHANGELOG.md +41 -0
- package/dist/addon-firefox/compact-rules.json +1 -1
- package/dist/addon-firefox/devtools/panel.html +5 -0
- package/dist/addon-firefox/devtools/panel.ts +18 -1
- 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/compact-rules.json +1 -1
- package/dist/addon-mv3/devtools/panel.html +5 -0
- package/dist/addon-mv3/devtools/panel.js +12 -0
- package/dist/addon-mv3/devtools/panel.ts +18 -1
- 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.standalone.js +2 -2
- package/docs/puppeteer.md +1 -1
- package/docs/release-notes.md +12 -43
- package/package.json +15 -15
- package/rules/autoconsent/ketch.json +58 -19
- package/rules/autoconsent/msn.json +18 -0
- package/rules/compact-rules.json +1 -1
- package/rules/rule-index.json +1 -1
- package/rules/rules.json +1 -1
- package/scripts/check-pr-release-labels.ts +24 -24
- package/standalone/content.ts +1 -1
- package/tests/ketch.spec.ts +33 -19
- package/tests/msn.spec.ts +5 -0
- package/tests-wtr/lifecycle/find-cmp.ts +2 -2
- package/tests-wtr/web/do-opt-in.test.ts +1 -1
- package/tests-wtr/web/do-opt-out.test.ts +1 -1
- package/tests-wtr/web/do-self-test.test.ts +1 -1
- package/tests-wtr/web/filter-cmps.test.ts +1 -1
- package/tests-wtr/web/receive-message-callback.test.ts +1 -1
- package/tests-wtr/web/update-state.test.ts +1 -1
- package/rules/autoconsent/theverge.json +0 -36
- package/tests/theverge.spec.ts +0 -3
package/docs/puppeteer.md
CHANGED
package/docs/release-notes.md
CHANGED
|
@@ -3,54 +3,19 @@
|
|
|
3
3
|
Release notes are generated by `auto` from merged PR labels. Each PR that should
|
|
4
4
|
appear in release notes needs two release-related decisions before merge:
|
|
5
5
|
|
|
6
|
-
1. Exactly one
|
|
7
|
-
2. Exactly one primary release-note category label.
|
|
6
|
+
1. Exactly one version label using the `version:` prefix.
|
|
7
|
+
2. Exactly one primary release-note category label using the `category:` prefix.
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
do not fit another category.
|
|
9
|
+
## Version labels
|
|
11
10
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Choose exactly one:
|
|
15
|
-
|
|
16
|
-
| Label | Use when |
|
|
17
|
-
| --- | --- |
|
|
18
|
-
| `major` | The change is breaking for consumers or downstream app integration. |
|
|
19
|
-
| `minor` | The change adds new behavior, rule coverage, or capabilities. |
|
|
20
|
-
| `patch` | The change fixes existing behavior or makes a non-breaking maintenance update. |
|
|
11
|
+
Use the `version:` prefix for labels that control the release impact, for
|
|
12
|
+
example `version: patch`.
|
|
21
13
|
|
|
22
14
|
## Release-note category labels
|
|
23
15
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
| --- | --- |
|
|
28
|
-
| `rules` | Adding, updating, or regenerating autoconsent rules. |
|
|
29
|
-
| `bug` | Fixing broken behavior, including rule fixes and race-condition fixes. |
|
|
30
|
-
| `enhancement` | Adding or improving non-rule functionality. |
|
|
31
|
-
| `performance` | Improving runtime performance or measurement overhead. |
|
|
32
|
-
| `dependencies` | Updating package dependencies. |
|
|
33
|
-
| `ci` | Changing CI, release automation, or scripts used by automation. |
|
|
34
|
-
| `ai` | Changing agent instructions, workflows, or skills. |
|
|
35
|
-
| `documentation` | Documentation-only changes. |
|
|
36
|
-
| `tests` | Changing test harnesses, fixtures, or test infrastructure. Do not use this for ordinary tests added with feature or rule work. |
|
|
37
|
-
| `internal` | Internal-only maintenance that does not fit the categories above. |
|
|
38
|
-
| `other` | Changes that should appear in release notes but do not fit another category. |
|
|
39
|
-
|
|
40
|
-
## Common examples
|
|
41
|
-
|
|
42
|
-
| PR type | Labels |
|
|
43
|
-
| --- | --- |
|
|
44
|
-
| New CMP rule or new site-specific rule | `minor`, `rules` |
|
|
45
|
-
| Existing rule fix | `patch`, `bug` |
|
|
46
|
-
| Generated rule update | `minor` or `patch`, `rules` |
|
|
47
|
-
| Core API or integration breaking change | `major`, `enhancement` |
|
|
48
|
-
| CI workflow or release script update | `patch`, `ci` |
|
|
49
|
-
| Dependency update | `patch`, `dependencies` |
|
|
50
|
-
| Agent skill or instruction update | `patch`, `ai` |
|
|
51
|
-
| Documentation-only update | `patch`, `documentation` |
|
|
52
|
-
| Test runner, fixture, or harness update | `patch`, `tests` |
|
|
53
|
-
| Miscellaneous repo maintenance | `patch`, `other` |
|
|
16
|
+
Use the `category:` prefix for labels that group the release note, for example
|
|
17
|
+
`category: rules`. Use `category: other` for changes that should appear in
|
|
18
|
+
release notes but do not fit another category.
|
|
54
19
|
|
|
55
20
|
If a PR spans multiple categories, choose the category that best describes the
|
|
56
21
|
user-visible release note. Mention secondary details in the PR description.
|
|
@@ -63,3 +28,7 @@ labels are missing or descriptions/colors drift, sync them with:
|
|
|
63
28
|
```bash
|
|
64
29
|
npx auto create-labels
|
|
65
30
|
```
|
|
31
|
+
|
|
32
|
+
`auto create-labels` creates or updates labels from the config, but it does not
|
|
33
|
+
remove labels that are no longer listed. After syncing, remove or rename the old
|
|
34
|
+
unprefixed required labels in the GitHub labels UI if they are no longer needed.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@duckduckgo/autoconsent",
|
|
3
|
-
"version": "16.
|
|
3
|
+
"version": "16.4.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"types": "./dist/types/web.d.ts",
|
|
6
6
|
"exports": {
|
|
@@ -81,19 +81,19 @@
|
|
|
81
81
|
"noDefaultLabels": true,
|
|
82
82
|
"labels": [
|
|
83
83
|
{
|
|
84
|
-
"name": "major",
|
|
84
|
+
"name": "version: major",
|
|
85
85
|
"description": "Increment the major version when merged",
|
|
86
86
|
"releaseType": "major",
|
|
87
87
|
"color": "#C5000B"
|
|
88
88
|
},
|
|
89
89
|
{
|
|
90
|
-
"name": "minor",
|
|
90
|
+
"name": "version: minor",
|
|
91
91
|
"description": "Increment the minor version when merged",
|
|
92
92
|
"releaseType": "minor",
|
|
93
93
|
"color": "#F1A60E"
|
|
94
94
|
},
|
|
95
95
|
{
|
|
96
|
-
"name": "patch",
|
|
96
|
+
"name": "version: patch",
|
|
97
97
|
"description": "Increment the patch version when merged",
|
|
98
98
|
"releaseType": "patch",
|
|
99
99
|
"default": true,
|
|
@@ -106,77 +106,77 @@
|
|
|
106
106
|
"color": "#007f70"
|
|
107
107
|
},
|
|
108
108
|
{
|
|
109
|
-
"name": "rules",
|
|
109
|
+
"name": "category: rules",
|
|
110
110
|
"changelogTitle": "Rules",
|
|
111
111
|
"description": "Autoconsent rule additions, updates, and generated rule changes",
|
|
112
112
|
"releaseType": "none",
|
|
113
113
|
"color": "#bfdadc"
|
|
114
114
|
},
|
|
115
115
|
{
|
|
116
|
-
"name": "bug",
|
|
116
|
+
"name": "category: bug",
|
|
117
117
|
"changelogTitle": "Bug Fixes",
|
|
118
118
|
"description": "Something isn't working",
|
|
119
119
|
"releaseType": "none",
|
|
120
120
|
"color": "#d73a4a"
|
|
121
121
|
},
|
|
122
122
|
{
|
|
123
|
-
"name": "enhancement",
|
|
123
|
+
"name": "category: enhancement",
|
|
124
124
|
"changelogTitle": "Enhancements",
|
|
125
125
|
"description": "New feature or request",
|
|
126
126
|
"releaseType": "none",
|
|
127
127
|
"color": "#a2eeef"
|
|
128
128
|
},
|
|
129
129
|
{
|
|
130
|
-
"name": "performance",
|
|
130
|
+
"name": "category: performance",
|
|
131
131
|
"changelogTitle": "Performance",
|
|
132
132
|
"description": "Improve performance of an existing feature",
|
|
133
133
|
"releaseType": "none",
|
|
134
134
|
"color": "#f4b2d8"
|
|
135
135
|
},
|
|
136
136
|
{
|
|
137
|
-
"name": "dependencies",
|
|
137
|
+
"name": "category: dependencies",
|
|
138
138
|
"changelogTitle": "Dependencies",
|
|
139
139
|
"description": "Update one or more dependencies version",
|
|
140
140
|
"releaseType": "none",
|
|
141
141
|
"color": "#8732bc"
|
|
142
142
|
},
|
|
143
143
|
{
|
|
144
|
-
"name": "ci",
|
|
144
|
+
"name": "category: ci",
|
|
145
145
|
"changelogTitle": "CI / Release Automation",
|
|
146
146
|
"description": "Automation scripts and release infrastructure",
|
|
147
147
|
"releaseType": "none",
|
|
148
148
|
"color": "#2612BF"
|
|
149
149
|
},
|
|
150
150
|
{
|
|
151
|
-
"name": "ai",
|
|
151
|
+
"name": "category: ai",
|
|
152
152
|
"changelogTitle": "AI / Agent Workflow",
|
|
153
153
|
"description": "Changes to agent workflows and skills",
|
|
154
154
|
"releaseType": "none",
|
|
155
155
|
"color": "#df4f06"
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
|
-
"name": "documentation",
|
|
158
|
+
"name": "category: documentation",
|
|
159
159
|
"changelogTitle": "Documentation",
|
|
160
160
|
"description": "Changes only affect the documentation",
|
|
161
161
|
"releaseType": "none",
|
|
162
162
|
"color": "#cfd3d7"
|
|
163
163
|
},
|
|
164
164
|
{
|
|
165
|
-
"name": "tests",
|
|
165
|
+
"name": "category: tests",
|
|
166
166
|
"changelogTitle": "Test Infrastructure",
|
|
167
167
|
"description": "Changes to test harnesses, fixtures, or test infrastructure",
|
|
168
168
|
"releaseType": "none",
|
|
169
169
|
"color": "#ffd3cc"
|
|
170
170
|
},
|
|
171
171
|
{
|
|
172
|
-
"name": "internal",
|
|
172
|
+
"name": "category: internal",
|
|
173
173
|
"changelogTitle": "Internal",
|
|
174
174
|
"description": "Changes only affect internal implementation details",
|
|
175
175
|
"releaseType": "none",
|
|
176
176
|
"color": "#696969"
|
|
177
177
|
},
|
|
178
178
|
{
|
|
179
|
-
"name": "other",
|
|
179
|
+
"name": "category: other",
|
|
180
180
|
"changelogTitle": "Other",
|
|
181
181
|
"description": "Changes that should appear in release notes but do not fit another category",
|
|
182
182
|
"releaseType": "none",
|
|
@@ -40,37 +40,61 @@
|
|
|
40
40
|
],
|
|
41
41
|
"optOut": [
|
|
42
42
|
{
|
|
43
|
-
"comment": "
|
|
43
|
+
"comment": "Banner phase: pick one banner action.",
|
|
44
44
|
"if": {
|
|
45
|
-
"exists": "#ketch-banner
|
|
46
|
-
},
|
|
47
|
-
"then": [{ "waitForThenClick": "#ketch-banner-button-tertiary" }]
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
"comment": "Older banner variant exposed via aria-describedby=banner-description: open settings/reject (same button class)",
|
|
51
|
-
"if": {
|
|
52
|
-
"exists": "#lanyard_root [aria-describedby=banner-description]"
|
|
45
|
+
"exists": "#lanyard_root button[aria-label^='Reject' i], #ketch-banner button[aria-label^='Reject' i]"
|
|
53
46
|
},
|
|
54
47
|
"then": [
|
|
55
48
|
{
|
|
49
|
+
"waitForThenClick": "#lanyard_root button[aria-label^='Reject' i], #ketch-banner button[aria-label^='Reject' i]"
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"comment": "Submit if the preferences modal is still open (Reject All only toggled switches).",
|
|
56
53
|
"if": {
|
|
57
|
-
"
|
|
54
|
+
"visible": "#lanyard_root [aria-describedby=preference-description], #lanyard_root [aria-describedby=modal-description], #ketch-modal, #ketch-purposes-modal, #ketch-preferences"
|
|
58
55
|
},
|
|
59
56
|
"then": [
|
|
60
57
|
{
|
|
61
|
-
"
|
|
62
|
-
"comment": "can be either settings or reject button"
|
|
58
|
+
"click": "#lanyard_root button[class*=confirmButton], #lanyard_root div[class*=actions_] > button:nth-child(1), #lanyard_root button[class*=actionButton], #ketch-modal button[aria-label='Confirm'], #ketch-purposes-modal button[aria-label='Confirm'], #ketch-modal button[aria-label='Save Settings'], #ketch-purposes-modal button[aria-label='Save Settings']"
|
|
63
59
|
}
|
|
64
|
-
]
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
],
|
|
63
|
+
"else": [
|
|
64
|
+
{
|
|
65
|
+
"comment": "Reject button without aria-label match.",
|
|
66
|
+
"if": {
|
|
67
|
+
"exists": "#ketch-banner-button-tertiary"
|
|
68
|
+
},
|
|
69
|
+
"then": [{ "waitForThenClick": "#ketch-banner-button-tertiary" }],
|
|
65
70
|
"else": [
|
|
66
71
|
{
|
|
72
|
+
"comment": "Open settings from banner, or dismiss disclosure-only banner.",
|
|
67
73
|
"if": {
|
|
68
|
-
"exists": "#lanyard_root [
|
|
74
|
+
"exists": "#lanyard_root [aria-describedby=banner-description]"
|
|
69
75
|
},
|
|
70
76
|
"then": [
|
|
71
77
|
{
|
|
72
|
-
"
|
|
73
|
-
|
|
78
|
+
"if": {
|
|
79
|
+
"exists": "#lanyard_root div[class*=buttons] > button[class*=secondaryButton], #lanyard_root button[class*=buttons-secondary], #ketch-banner-button-secondary"
|
|
80
|
+
},
|
|
81
|
+
"then": [
|
|
82
|
+
{
|
|
83
|
+
"waitForThenClick": "#lanyard_root div[class*=buttons] > button[class*=secondaryButton], #lanyard_root button[class*=buttons-secondary], #ketch-banner-button-secondary"
|
|
84
|
+
}
|
|
85
|
+
],
|
|
86
|
+
"else": [
|
|
87
|
+
{
|
|
88
|
+
"if": {
|
|
89
|
+
"exists": "#lanyard_root [id^='ketch-banner-buttons-container'] > button:only-child"
|
|
90
|
+
},
|
|
91
|
+
"then": [
|
|
92
|
+
{
|
|
93
|
+
"click": "#lanyard_root [id^='ketch-banner-buttons-container'] > button:only-child"
|
|
94
|
+
}
|
|
95
|
+
]
|
|
96
|
+
}
|
|
97
|
+
]
|
|
74
98
|
}
|
|
75
99
|
]
|
|
76
100
|
}
|
|
@@ -84,16 +108,31 @@
|
|
|
84
108
|
"optional": true
|
|
85
109
|
},
|
|
86
110
|
{
|
|
87
|
-
"comment": "Preferences
|
|
111
|
+
"comment": "Preferences modal handling.",
|
|
88
112
|
"if": {
|
|
89
113
|
"exists": "#lanyard_root [aria-describedby=preference-description],#lanyard_root [aria-describedby=modal-description], #ketch-preferences, #ketch-purposes-modal"
|
|
90
114
|
},
|
|
91
115
|
"then": [
|
|
92
116
|
{
|
|
93
|
-
"
|
|
117
|
+
"if": {
|
|
118
|
+
"exists": "#lanyard_root button[class*=rejectButton], #lanyard_root button[class*=rejectAllButton], #ketch-modal button[aria-label='Reject All'], #ketch-purposes-modal button[aria-label='Reject All']"
|
|
119
|
+
},
|
|
120
|
+
"then": [
|
|
121
|
+
{
|
|
122
|
+
"waitForThenClick": "#lanyard_root button[class*=rejectButton], #lanyard_root button[class*=rejectAllButton], #ketch-modal button[aria-label='Reject All'], #ketch-purposes-modal button[aria-label='Reject All']"
|
|
123
|
+
}
|
|
124
|
+
],
|
|
125
|
+
"else": [
|
|
126
|
+
{
|
|
127
|
+
"comment": "No Reject All: uncheck every enabled purpose switch.",
|
|
128
|
+
"click": "#lanyard_root input[type=checkbox][role=switch][aria-checked=true]:not(:disabled)",
|
|
129
|
+
"all": true,
|
|
130
|
+
"optional": true
|
|
131
|
+
}
|
|
132
|
+
]
|
|
94
133
|
},
|
|
95
134
|
{
|
|
96
|
-
"click": "#lanyard_root button[class*=confirmButton], #lanyard_root div[class*=actions_] > button:nth-child(1), #lanyard_root button[class*=actionButton], #ketch-modal button[aria-label='Confirm'], #ketch-purposes-modal button[aria-label='Confirm']"
|
|
135
|
+
"click": "#lanyard_root button[class*=confirmButton], #lanyard_root div[class*=actions_] > button:nth-child(1), #lanyard_root button[class*=actionButton], #ketch-modal button[aria-label='Confirm'], #ketch-purposes-modal button[aria-label='Confirm'], #ketch-modal button[aria-label='Save Settings'], #ketch-purposes-modal button[aria-label='Save Settings']"
|
|
97
136
|
}
|
|
98
137
|
]
|
|
99
138
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "msn",
|
|
3
|
+
"_metadata": {
|
|
4
|
+
"vendorUrl": "https://www.msn.com"
|
|
5
|
+
},
|
|
6
|
+
"cosmetic": false,
|
|
7
|
+
"runContext": {
|
|
8
|
+
"main": true,
|
|
9
|
+
"frame": false,
|
|
10
|
+
"urlPattern": "^https?://(www\\.)?msn\\.com/"
|
|
11
|
+
},
|
|
12
|
+
"prehideSelectors": ["#cmp-banner-sdk", ".cmp-sdk-container"],
|
|
13
|
+
"detectCmp": [{ "exists": "#cmp-banner-sdk" }],
|
|
14
|
+
"detectPopup": [{ "visible": "#cmp-banner-sdk" }],
|
|
15
|
+
"optIn": [{ "waitForThenClick": "#cmp-accept-btn-handler" }],
|
|
16
|
+
"optOut": [{ "waitForThenClick": "#cmp-reject-all-handler" }],
|
|
17
|
+
"test": [{ "cookieContains": "OptanonAlertBoxClosed" }]
|
|
18
|
+
}
|