Skip to content

Releases: 68publishers/cookie-consent

v0.3.6

07 Feb 06:41
Compare
Choose a tag to compare

❗ Don't forget to update the template in your GTM.

Added

  • Added fields Show the modal again if storage is denied for each storage in the GTM template. The settings modal can be opened again after the specified number of days if the storage is denied.

v0.3.5

08 Jan 00:08
Compare
Choose a tag to compare

Added

  • Added the section How the GTM integration works in README
  • Added the section How to update already published container in README

Changed

  • The original plugin is initialized directly if the DOM is loaded or inside a callback attached to an event document.DOMContentLoaded instead of window.load.

v0.3.4

05 Jan 21:11
Compare
Choose a tag to compare

❗ Possible BC break if you are using an event CookieConsentWrapper.on('init', ...)

Removed

  • Removed argument wrapper for an event init. Callbacks for the event now have no arguments now, please use directly CookieConsentWrapper inside a callback function.

Why?

Internally event callbacks are stored in a "temporary" CookieConsentWrapper object if the wrapper is not currently available e.g. the script cookie-consent.min.js is not fully downloaded by a browser but you attaching some event callback.
At this point, the GTM can't provide the argument wrapper into your callback because Template's code is sandboxed JavaScript, and custom objects like CookieConsentWrapper instance are not supported by this sandbox so undefined is passed as the argument instead of the wrapper.

How to modify your events

Simply call the wrapper directly inside a callback function. So instead of this:

CookieConsentWrapper.on('init', function (wrapper) {
    # the wrapper argument is now undefined
    wrapper.unwrap();
});

Use this:

CookieConsentWrapper.on('init', function () {
    CookieConsentWrapper.unwrap();
});

v0.3.3

05 Jan 17:59
Compare
Choose a tag to compare

Changed

  • Default translations are now loaded also for locales that are consist of an ISO 639-1 language code and an ISO 3166-1 country code e.g. en-US.

v0.3.2

03 Jan 08:53
Compare
Choose a tag to compare

Added

  • Added the section Accessing the wrapper in the JavaScript in the README
  • Added the section Cookies options in the README
  • Added the field Enable cookies auto-clear in GTM template under the section Cookies options.
  • Added the field Cookies auto-clear strategy in GTM template under the section Cookies options.
  • Added the field Cookie names in GTM template under the section Cookies options.
  • Added implementation of cookies auto-clear based on mentioned fields.

Changed

  • Updated a code in the GTM template - temporary object window.CookieConsentWrapper is created before the real wrapper is created by an external script. This allows attaching events through the method CookieConsentWrapper.on() before the script is downloaded by a browser.
  • Moved fields Cookie name and Cookie expiration under the new section Cookies options.
  • Moved the field Settings modal trigger selector under the section Settings modal options.

v0.3.1

31 Dec 18:20
Compare
Choose a tag to compare

Fixed

  • Fixed initialization of the original plugin when a page is too small and DOM is already loaded before an event window.addEventListener('load', ...) is attached.

v0.3.0

28 Dec 22:26
Compare
Choose a tag to compare

❗ GTM template is not back-compatible with previous versions including a beta version (0.3.0-beta.x), the template must be updated in your container.

Added

  • Added param table Event triggers in a new section Composite consent in GTM template. Event triggers for composite consent can be defined here. For more information look into the section Event triggers based on composite consent in README.

Changed

  • Options for the wrapper are now accessible under a single global variable window.cc_wrapper_config instead of multiple smaller variables (GTM template must be updated).
  • Modified regex validation rule for GTM field Package version. The regex now allows beta and alpha versions.

v0.2.7

22 Dec 22:41
Compare
Choose a tag to compare

Changed

  • Changed descriptions of the security storage in translations.
  • Unified translations for buttons in the consent modal.
  • Removed emojis from translations.

v0.2.6

21 Dec 23:03
Compare
Choose a tag to compare

Added

  • Added options consent_modal_secondary_btn_settings and consent_modal_secondary_btn_accept_necessary for GTM field Translations - Key.

v0.2.5

21 Dec 23:03
Compare
Choose a tag to compare

Added

  • Added default translations for Slovak (sk) language.

Changed

  • Changed default translations for English (en) and Czech (cs) languages.