ampproject / ampproject/amphtml

amp-consent: discourage developers from leaving granular consent purposes in an unresolved state

Open
#33,882 1 comment 0 reactions 1 assignee Claimed by @micajuine-ho View on GitHub
Component: amp-consent Stale Type: Feature Request WG: components
Dominant language
JavaScript
Stars
14.9k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

Here's my concern. Typically, when making granular consent choices, the user will see a form-like area with checkboxes, like this:

```html




Marketing cookies



Analytics


Save


Dismiss


```

Let's say the user checks one of the boxes, leaves the other blank, and taps "Save". They may well think that they've accepted one consent choice but denied the others. However, this is not really a ``. `siteConsent.setPurpose()` has only been called on one consent choice, leaving the rest of the consent choices unresolved.

If the developer understands the component better, they'll probably change this:

```html

```

to this:

```html

```

which will do what the user expects.

I wanted to propose that we make the `accept` action default to including `(purposeConsentDefault=false)`. The problem there is that this consent UI might involve multiple tabs of choices, and the site developer might want to leave some of those in an unresolved state unless the user interacts with them in some way. On the other hand, if a user discovers that they think they've denied a consent type, but their PII is still being collected, the site owner could be in trouble with regulators.

Thus, instead, I'm putting this out there and hoping someone else has a more clever solution 😎

/cc @micajuine-ho

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.