Skip to content

Default setting for accepting a service #511

@DanYouCan

Description

@DanYouCan

How can you ensure that a service is accepted first by default when a website is accessed for the first time? Without having to give consent first. For example, with an embedded IFrame for Google Maps. The contextual consent should also not (yet) be displayed.

The contextual consent should only appear after consent has been explicitly declined.

I should also add that for Switzerland, for a website that only applies to Switzerland, it is currently not necessary to obtain the user's consent.

I had no success with the following code:

{
name: 'googlemaps',
title: 'Google Maps',
purposes: ['functional'],

default: true,
// required: false,
optOut: true,

onAccept: `
	console.log('klaro-google-maps-accepted');
	document.querySelectorAll('.gmap-klaro').forEach(e => e.classList.replace('gmap-klaro', 'gmap'));
`,
onDecline: `
	console.log('klaro-google-maps-notaccepted');
	document.querySelectorAll('.gmap').forEach(e => e.classList.replace('gmap', 'gmap-klaro'));
`,
}

Is there anything else to consider? Thanks in advance for any help or hint.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions