Cookie consent
The values of `data-action` inside `smootify-consent`.
On this page
At a glance
is-required
The visitor has to answer
- Banner
- Shows.
- Body
cookie-banner-visible- Preferences button
- Hidden.
is-open
The preferences are open
- Panels
consent-panel="banner"hides,consent-panel="preferences"shows.- Body
cookie-banner-visible
No class
The visitor has answered
- Banner
- Hidden.
- Preferences button
- Shows. A click opens the preferences.
No class
No consent needed in the region
- Banner
- Never shows.
- Preferences button
- Shows, and opens the preferences, for example to refuse the sale of data.
More in the guide.
Where it can go
- Inside
smootify-consent.
Values
| Attribute and value | What it is | Notes |
|---|---|---|
data-action="accept" | Accept all | on button, link |
data-action="decline" | Decline all | on button, link |
data-action="save" | Save the choices | on button, link |
data-action="preferences" | Open the preferences | on button, link |
data-action="close" | Close | on button, link |
name="marketing" | Marketing | A checkbox; on input |
name="analytics" | Analytics | A checkbox; on input |
name="preferences" | Preferences | A checkbox; on input |
name="sale_of_data" | Sale of data | A checkbox; on input |
consent-panel="banner" | Banner panel | on container |
consent-panel="preferences" | Preferences panel | on container |