From 14f245ee0c601c104d0537cfad4e96f8cd5d064b Mon Sep 17 00:00:00 2001 From: Amauri CHAMPEAUX Date: Sat, 6 Feb 2021 10:20:54 +0100 Subject: [PATCH] Add Stonly --- tarteaucitron.services.js | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/tarteaucitron.services.js b/tarteaucitron.services.js index 7258474..4ec6173 100644 --- a/tarteaucitron.services.js +++ b/tarteaucitron.services.js @@ -973,6 +973,29 @@ tarteaucitron.services.simpleanalytics = { } }; +// stonly +tarteaucitron.services.stonly = { + "key": "stonly", + "type": "api", + "name": "Stonly", + "uri": "https://stonly.com/privacy", + "needConsent": true, + "cookies": [], + "js": function () { + "use strict"; + if (tarteaucitron.user.stonlyId === undefined) { + return; + } + + window.STONLY_WID = tarteaucitron.user.stonlyId; + window.StonlyWidget || ((window.w = window.StonlyWidget = function() { + window.w._api ? window.w._api.apply(window.w, arguments) : window.w.queue.push(arguments) + }).queue = []); + + tarteaucitron.addScript('https://stonly.com/js/widget/v2/stonly-widget.js?v=' + Date.now()); + } +}; + // stripe tarteaucitron.services.stripe = { "key": "stripe",