/plugins/consent

The module exports method to display and store configurable user consent.

Requires

Methods

(async, inner) consent(plugin, mapview)

The method will shortcircuit without a mapp.user{} object.

The method will shortcircuit without a consent text being defined in the plugin configuration.

The method awaits the confirm dialog promise to resolve and stores the response as the user.consent property in the userIndexedDB user store.

The confirm dialog will not be displayed if consent has been provided previously.

"consent": {
  "text": "Please confirm you consent to user 3rd party cookies."
}
Parameters:
NameTypeDescription
pluginObject

The consent configuration.

mapviewmapview
Properties
NameTypeAttributesDefaultDescription
plugin.textstring

The text shown in the consent dialog.

plugin.titlestring<optional>
"mapp.user.consent"

The title for the consent confirmation dialog.