@duckduckgo/autoconsent 16.37.0 → 16.38.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.
Files changed (38) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/addon-firefox/compact-rules.json +1 -1
  3. package/dist/addon-firefox/manifest.json +1 -1
  4. package/dist/addon-firefox/rule-index.json +1 -1
  5. package/dist/addon-firefox/rules.json +1 -1
  6. package/dist/addon-mv3/compact-rules.json +1 -1
  7. package/dist/addon-mv3/manifest.json +1 -1
  8. package/dist/addon-mv3/rule-index.json +1 -1
  9. package/dist/addon-mv3/rules.json +1 -1
  10. package/dist/autoconsent.standalone.js +1 -1
  11. package/package.json +1 -1
  12. package/rules/autoconsent/consent-flo.json +24 -0
  13. package/rules/autoconsent/cookiebot-be.json +9 -0
  14. package/rules/autoconsent/cookieyes.json +36 -8
  15. package/rules/autoconsent/drouot-rgpd.json +9 -0
  16. package/rules/autoconsent/fever-cookie-advice.json +51 -0
  17. package/rules/autoconsent/idxrcookies.json +8 -0
  18. package/rules/autoconsent/infomaniak-rgpd.json +9 -0
  19. package/rules/autoconsent/mco-consent.json +14 -0
  20. package/rules/autoconsent/mkdocs-material.json +30 -0
  21. package/rules/autoconsent/setupad.json +57 -0
  22. package/rules/autoconsent/socialfunders.json +8 -0
  23. package/rules/autoconsent/workday.json +30 -0
  24. package/rules/compact-rules.json +1 -1
  25. package/rules/rule-index.json +1 -1
  26. package/rules/rules.json +1 -1
  27. package/tests/consent-flo.spec.ts +5 -0
  28. package/tests/cookiebot-be.spec.ts +6 -0
  29. package/tests/cookieyes.spec.ts +3 -0
  30. package/tests/drouot-rgpd.spec.ts +8 -0
  31. package/tests/fever-cookie-advice.spec.ts +3 -0
  32. package/tests/idxrcookies.spec.ts +3 -0
  33. package/tests/infomaniak-rgpd.spec.ts +3 -0
  34. package/tests/mco-consent.spec.ts +12 -0
  35. package/tests/mkdocs-material.spec.ts +7 -0
  36. package/tests/setupad.spec.ts +10 -0
  37. package/tests/socialfunders.spec.ts +3 -0
  38. package/tests/workday.spec.ts +9 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@duckduckgo/autoconsent",
3
- "version": "16.37.0",
3
+ "version": "16.38.0",
4
4
  "description": "",
5
5
  "types": "./dist/types/web.d.ts",
6
6
  "exports": {
@@ -0,0 +1,24 @@
1
+ {
2
+ "name": "consent-flo",
3
+ "prehideSelectors": ["._flo-consent-root"],
4
+ "detectCmp": [{ "exists": "._flo-consent-root ._flo-consent-modal-contextual ._flo-consent-button--accept-selected" }],
5
+ "detectPopup": [{ "visible": "._flo-consent-root ._flo-consent-modal:not(._flo-consent-modal-contextual)" }],
6
+ "optIn": [{ "waitForThenClick": "._flo-consent-modal:not(._flo-consent-modal-contextual) ._flo-consent-button--accept" }],
7
+ "optOut": [
8
+ {
9
+ "if": { "exists": "._flo-consent-modal:not(._flo-consent-modal-contextual) ._flo-consent-button--reject" },
10
+ "then": [{ "waitForThenClick": "._flo-consent-modal:not(._flo-consent-modal-contextual) ._flo-consent-button--reject" }],
11
+ "else": [
12
+ { "waitForThenClick": "._flo-consent-button--settings" },
13
+ { "waitForVisible": "._flo-consent-modal-contextual ._flo-consent-button--accept-selected" },
14
+ {
15
+ "click": "._flo-consent-modal-contextual ._flo-consent-checkbox:checked:not(._flo-consent-checkbox--necessary)",
16
+ "all": true,
17
+ "optional": true
18
+ },
19
+ { "waitForThenClick": "._flo-consent-modal-contextual ._flo-consent-button--accept-selected" }
20
+ ]
21
+ }
22
+ ],
23
+ "test": [{ "exists": "._flo-consent-root._flo-consent-hide" }]
24
+ }
@@ -0,0 +1,9 @@
1
+ {
2
+ "name": "cookiebot.be",
3
+ "prehideSelectors": ["#cbPopupWrap.cb-popup--open"],
4
+ "detectCmp": [{ "exists": "#cbPopupWrap #cbRefuseTrigger" }],
5
+ "detectPopup": [{ "visible": "#cbPopupWrap.cb-popup--open" }],
6
+ "optIn": [{ "waitForThenClick": "#cbPopupWrap #cbAcceptTrigger" }],
7
+ "optOut": [{ "waitForThenClick": "#cbPopupWrap #cbRefuseTrigger" }],
8
+ "test": [{ "cookieContains": "cbDataAccepted=1" }]
9
+ }
@@ -3,27 +3,55 @@
3
3
  "prehideSelectors": [".cky-overlay,.cky-consent-container"],
4
4
  "detectCmp": [{ "exists": ".cky-consent-container" }],
5
5
  "detectPopup": [{ "visible": ".cky-consent-container" }],
6
- "optIn": [{ "waitForThenClick": ".cky-consent-container [data-cky-tag=accept-button]" }],
6
+ "optIn": [
7
+ {
8
+ "if": { "exists": ".cky-consent-container [data-cky-tag=accept-button]" },
9
+ "then": [{ "waitForThenClick": ".cky-consent-container [data-cky-tag=accept-button]" }],
10
+ "else": [
11
+ {
12
+ "if": { "exists": ".cky-consent-container [data-cky-tag=donotsell-button]" },
13
+ "then": [{ "waitForThenClick": ".cky-consent-container [data-cky-tag=close-button]" }]
14
+ }
15
+ ]
16
+ }
17
+ ],
7
18
  "optOut": [
8
19
  {
9
20
  "if": { "exists": ".cky-consent-container [data-cky-tag=reject-button]" },
10
21
  "then": [{ "waitForThenClick": ".cky-consent-container [data-cky-tag=reject-button]" }],
11
22
  "else": [
12
23
  {
13
- "if": { "exists": ".cky-consent-container [data-cky-tag=settings-button]" },
24
+ "if": { "exists": ".cky-consent-container [data-cky-tag=donotsell-button]" },
14
25
  "then": [
15
- { "click": ".cky-consent-container [data-cky-tag=settings-button]" },
16
- { "waitFor": ".cky-modal-open input[type=checkbox],.cky-consent-bar-expand input[type=checkbox]" },
26
+ { "waitForThenClick": ".cky-consent-container [data-cky-tag=donotsell-button]" },
27
+ { "waitFor": ".cky-modal [data-cky-tag=optout-option-toggle]" },
17
28
  {
18
- "click": ".cky-modal-open input[type=checkbox]:checked,.cky-consent-bar-expand input[type=checkbox]:checked",
29
+ "click": ".cky-modal [data-cky-tag=optout-option-toggle]:not(:checked)",
19
30
  "all": true,
20
31
  "optional": true
21
32
  },
33
+ { "waitForThenClick": ".cky-modal [data-cky-tag=optout-confirm-button]" },
34
+ { "waitForVisible": ".cky-modal [data-cky-tag=optout-success]", "optional": true },
35
+ { "waitForThenClick": ".cky-modal [data-cky-tag=optout-close]", "optional": true }
36
+ ],
37
+ "else": [
22
38
  {
23
- "waitForThenClick": ".cky-modal [data-cky-tag=detail-save-button],.cky-consent-bar-expand [data-cky-tag=detail-save-button]"
39
+ "if": { "exists": ".cky-consent-container [data-cky-tag=settings-button]" },
40
+ "then": [
41
+ { "click": ".cky-consent-container [data-cky-tag=settings-button]" },
42
+ { "waitFor": ".cky-modal-open input[type=checkbox],.cky-consent-bar-expand input[type=checkbox]" },
43
+ {
44
+ "click": ".cky-modal-open input[type=checkbox]:checked,.cky-consent-bar-expand input[type=checkbox]:checked",
45
+ "all": true,
46
+ "optional": true
47
+ },
48
+ {
49
+ "waitForThenClick": ".cky-modal [data-cky-tag=detail-save-button],.cky-consent-bar-expand [data-cky-tag=detail-save-button]"
50
+ }
51
+ ],
52
+ "else": [{ "hide": ".cky-consent-container,.cky-overlay,.cky-consent-bar-expand" }]
24
53
  }
25
- ],
26
- "else": [{ "hide": ".cky-consent-container,.cky-overlay,.cky-consent-bar-expand" }]
54
+ ]
27
55
  }
28
56
  ]
29
57
  }
@@ -0,0 +1,9 @@
1
+ {
2
+ "name": "drouot-rgpd",
3
+ "prehideSelectors": ["#rgpd-popup", "#rgpd-custom-popup"],
4
+ "detectCmp": [{ "exists": "#rgpd-popup #rgpd-continue-without-accepting" }],
5
+ "detectPopup": [{ "visible": "#rgpd-popup" }],
6
+ "optIn": [{ "waitForThenClick": "#rgpd-popup .rgpd-buttons button:last-child" }],
7
+ "optOut": [{ "waitForThenClick": "#rgpd-continue-without-accepting" }],
8
+ "test": [{ "cookieContains": "consentLevel=none" }]
9
+ }
@@ -0,0 +1,51 @@
1
+ {
2
+ "name": "fever-cookie-advice",
3
+ "vendorUrl": "https://feverup.com/",
4
+ "prehideSelectors": ["#cookie-advice.fv-cookie-advice"],
5
+ "detectCmp": [
6
+ {
7
+ "exists": "#cookie-advice.fv-cookie-advice"
8
+ }
9
+ ],
10
+ "detectPopup": [
11
+ {
12
+ "visible": "#cookie-advice.fv-cookie-advice"
13
+ }
14
+ ],
15
+ "optIn": [
16
+ {
17
+ "if": {
18
+ "exists": "#cookie-advice [data-testid=\"accept-cookies-button\"]"
19
+ },
20
+ "then": [
21
+ {
22
+ "waitForThenClick": "#cookie-advice [data-testid=\"accept-cookies-button\"]"
23
+ }
24
+ ],
25
+ "else": [
26
+ {
27
+ "waitForThenClick": "#cookie-advice .fv-cookie-advice__close"
28
+ }
29
+ ]
30
+ }
31
+ ],
32
+ "optOut": [
33
+ {
34
+ "waitForThenClick": "#cookie-advice .fv-cookie-advice__message a:not([href]), #cookie-advice .fv-cookie-advice__message button"
35
+ },
36
+ {
37
+ "waitForVisible": ".fv-cookies-management"
38
+ },
39
+ {
40
+ "waitForThenClick": ":is(fv-cookies-management-sheet, .modal-content):has(.fv-cookies-management) button[class*=\"--primary\"]"
41
+ }
42
+ ],
43
+ "test": [
44
+ {
45
+ "wait": 500
46
+ },
47
+ {
48
+ "cookieContains": "fever_cookies_configuration"
49
+ }
50
+ ]
51
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "name": "idxrcookies",
3
+ "prehideSelectors": ["body > #idxrcookies"],
4
+ "detectCmp": [{ "exists": "body > #idxrcookies #idxrcookiesKO" }],
5
+ "detectPopup": [{ "visible": "body > #idxrcookies #idxrcookiesKO" }],
6
+ "optIn": [{ "waitForThenClick": "body > #idxrcookies #idxrcookiesOK" }],
7
+ "optOut": [{ "waitForThenClick": "body > #idxrcookies #idxrcookiesKO" }]
8
+ }
@@ -0,0 +1,9 @@
1
+ {
2
+ "name": "infomaniak-rgpd",
3
+ "prehideSelectors": ["module-rgpd-component"],
4
+ "detectCmp": [{ "exists": "module-rgpd-component" }],
5
+ "detectPopup": [{ "visible": ["module-rgpd-component", ".modal"] }],
6
+ "optIn": [{ "waitForThenClick": ["module-rgpd-component", ".buttons > button:nth-of-type(1)"] }],
7
+ "optOut": [{ "waitForThenClick": ["module-rgpd-component", ".buttons > button:nth-of-type(2)"], "retry": 3 }],
8
+ "test": [{ "cookieContains": "cookieConsent=consent_1" }]
9
+ }
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "mco-consent",
3
+ "prehideSelectors": [
4
+ ".mco-consent-pop-up",
5
+ ".mco-consent-slide-up",
6
+ ".mco-consent-slide-up__backdrop",
7
+ ".mco-overlay:has(.mco-consent)"
8
+ ],
9
+ "detectCmp": [{ "exists": "#mco-consent" }],
10
+ "detectPopup": [{ "visible": "[class*=\"mco-consent-\"][class*=\"__button-decline\"]" }],
11
+ "optIn": [{ "waitForThenClick": "[class*=\"mco-consent-\"][class*=\"__button-confirm\"]" }],
12
+ "optOut": [{ "waitForThenClick": "[class*=\"mco-consent-\"][class*=\"__button-decline\"]" }],
13
+ "test": [{ "cookieContains": "\"acceptedAll\":false" }]
14
+ }
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "mkdocs-material",
3
+ "vendorUrl": "https://squidfunk.github.io/mkdocs-material/setup/ensuring-data-privacy/",
4
+ "prehideSelectors": ["#__consent .md-consent__inner", "#__consent .md-consent__overlay"],
5
+ "detectCmp": [
6
+ {
7
+ "exists": "#__consent form[name='consent'] .md-consent__settings input[type='checkbox']"
8
+ }
9
+ ],
10
+ "detectPopup": [
11
+ {
12
+ "visible": "#__consent:not([hidden]) .md-consent__inner"
13
+ }
14
+ ],
15
+ "optIn": [
16
+ {
17
+ "waitForThenClick": "#__consent .md-consent__controls button.md-button--primary"
18
+ }
19
+ ],
20
+ "optOut": [
21
+ {
22
+ "click": "#__consent .md-consent__settings input[type='checkbox']:checked",
23
+ "all": true,
24
+ "optional": true
25
+ },
26
+ {
27
+ "waitForThenClick": "#__consent .md-consent__controls button.md-button--primary"
28
+ }
29
+ ]
30
+ }
@@ -0,0 +1,57 @@
1
+ {
2
+ "name": "setupad",
3
+ "vendorUrl": "https://setupad.com/cmp/",
4
+ "prehideSelectors": [".stpd_cmp_wrapper"],
5
+ "detectCmp": [
6
+ {
7
+ "exists": ".stpd_cmp_wrapper .stpd_cmp_form"
8
+ }
9
+ ],
10
+ "detectPopup": [
11
+ {
12
+ "visible": ".stpd_cmp_wrapper .stpd_cmp_form"
13
+ }
14
+ ],
15
+ "optIn": [
16
+ {
17
+ "waitForThenClick": ".stpd_cmp_wrapper .stpd_cta_btn"
18
+ }
19
+ ],
20
+ "optOut": [
21
+ {
22
+ "if": {
23
+ "exists": ".stpd_cmp_wrapper .stpd_flexed_btns button[type=\"submit\"]"
24
+ },
25
+ "then": [
26
+ {
27
+ "waitForThenClick": ".stpd_cmp_wrapper .stpd_flexed_btns button[type=\"submit\"]"
28
+ }
29
+ ],
30
+ "else": [
31
+ {
32
+ "waitForThenClick": ".stpd_cmp_wrapper .stpd_flexed_btns button[type=\"button\"]:not(.withdraw_consent)"
33
+ },
34
+ {
35
+ "waitForVisible": ".stpd_cmp_wrapper .stpd_purposes_list"
36
+ },
37
+ {
38
+ "click": ".stpd_cmp_wrapper input[type=\"checkbox\"]:checked",
39
+ "all": true,
40
+ "optional": true
41
+ },
42
+ {
43
+ "waitForThenClick": ".stpd_cmp_wrapper .stpd_flexed_btns button[type=\"submit\"]"
44
+ }
45
+ ]
46
+ },
47
+ {
48
+ "waitForVisible": ".stpd_cmp_wrapper",
49
+ "check": "none"
50
+ }
51
+ ],
52
+ "test": [
53
+ {
54
+ "cookieContains": "euconsent-v2="
55
+ }
56
+ ]
57
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "name": "socialfunders",
3
+ "prehideSelectors": ["#cookie_modal"],
4
+ "detectCmp": [{ "exists": "#cookie_modal #id_cookies_necessary" }, { "exists": "#cookie_modal #id_cookies_all" }],
5
+ "detectPopup": [{ "visible": "#cookie_modal" }],
6
+ "optIn": [{ "waitForThenClick": "#cookie_modal #id_cookies_all" }],
7
+ "optOut": [{ "waitForThenClick": "#cookie_modal #id_cookies_necessary" }]
8
+ }
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "workday",
3
+ "vendorUrl": "https://www.workday.com/",
4
+ "prehideSelectors": ["[data-automation-id=\"legalNotice\"]"],
5
+ "detectCmp": [
6
+ {
7
+ "exists": "[data-automation-id=\"legalNoticeDeclineButton\"]"
8
+ }
9
+ ],
10
+ "detectPopup": [
11
+ {
12
+ "visible": "[data-automation-id=\"legalNotice\"]"
13
+ }
14
+ ],
15
+ "optIn": [
16
+ {
17
+ "waitForThenClick": "[data-automation-id=\"legalNoticeAcceptButton\"]"
18
+ }
19
+ ],
20
+ "optOut": [
21
+ {
22
+ "waitForThenClick": "[data-automation-id=\"legalNoticeDeclineButton\"]"
23
+ }
24
+ ],
25
+ "test": [
26
+ {
27
+ "cookieContains": "enablePrivacyTracking=false"
28
+ }
29
+ ]
30
+ }