diff --git a/build/cookieconsent.js b/build/cookieconsent.js index 64da519..e402037 100644 --- a/build/cookieconsent.js +++ b/build/cookieconsent.js @@ -1515,8 +1515,8 @@ var Interface = /*#__PURE__*/function () { buttonSettings.setAttribute('aria-hidden', 'false'); buttonConsentGive.setAttribute('tabindex', '0'); buttonConsentGive.setAttribute('aria-hidden', 'false'); - (_ref = buttonConsentDecline && buttonConsentDecline.length > 0) !== null && _ref !== void 0 ? _ref : buttonConsentDecline.setAttribute('tabindex', '0'); - (_ref2 = buttonConsentDecline && buttonConsentDecline.length > 0) !== null && _ref2 !== void 0 ? _ref2 : buttonConsentDecline.setAttribute('aria-hidden', 'false'); + (_ref = buttonConsentDecline !== null) !== null && _ref !== void 0 ? _ref : buttonConsentDecline.setAttribute('tabindex', '0'); + (_ref2 = buttonConsentDecline !== null) !== null && _ref2 !== void 0 ? _ref2 : buttonConsentDecline.setAttribute('aria-hidden', 'false'); }, window.CookieConsent.config.barTimeout); } }); @@ -1573,8 +1573,8 @@ var Interface = /*#__PURE__*/function () { button.setAttribute('aria-hidden', 'true'); buttonSettings.setAttribute('tabindex', '-1'); buttonSettings.setAttribute('aria-hidden', 'true'); - (_ref5 = buttonConsentDecline && buttonConsentDecline.length > 0) !== null && _ref5 !== void 0 ? _ref5 : buttonConsentDecline.setAttribute('tabindex', '-1'); - (_ref6 = buttonConsentDecline && buttonConsentDecline.length > 0) !== null && _ref6 !== void 0 ? _ref6 : buttonConsentDecline.setAttribute('aria-hidden', 'true'); + (_ref5 = buttonConsentDecline !== null) !== null && _ref5 !== void 0 ? _ref5 : buttonConsentDecline.setAttribute('tabindex', '-1'); + (_ref6 = buttonConsentDecline !== null) !== null && _ref6 !== void 0 ? _ref6 : buttonConsentDecline.setAttribute('aria-hidden', 'true'); focusTarget.focus(); modalOpen = false; @@ -1769,8 +1769,8 @@ var Interface = /*#__PURE__*/function () { buttonSettings.setAttribute('aria-hidden', 'true'); buttonConsentGive.setAttribute('tabindex', '-1'); buttonConsentGive.setAttribute('aria-hidden', 'true'); - (_ref3 = buttonConsentDecline && buttonConsentDecline.length > 0) !== null && _ref3 !== void 0 ? _ref3 : buttonConsentDecline.setAttribute('tabindex', '-1'); - (_ref4 = buttonConsentDecline && buttonConsentDecline.length > 0) !== null && _ref4 !== void 0 ? _ref4 : buttonConsentDecline.setAttribute('aria-hidden', 'true'); + (_ref3 = buttonConsentDecline !== null) !== null && _ref3 !== void 0 ? _ref3 : buttonConsentDecline.setAttribute('tabindex', '-1'); + (_ref4 = buttonConsentDecline !== null) !== null && _ref4 !== void 0 ? _ref4 : buttonConsentDecline.setAttribute('aria-hidden', 'true'); focusTarget.focus(); modalOpen = false; }); diff --git a/build/cookieconsent.min.js b/build/cookieconsent.min.js index 2c8e31d..8bc2a45 100644 --- a/build/cookieconsent.min.js +++ b/build/cookieconsent.min.js @@ -1 +1 @@ -(()=>{"use strict";function e(e,t){for(var n=0;n>16)+t;i>255?i=255:i<0&&(i=0);var r=(o>>8&255)+t;r>255?r=255:r<0&&(r=0);var c=(255&o)+t;return c>255?c=255:c<0&&(c=0),(n?"#":"")+(c|r<<8|i<<16).toString(16)}},{key:"removeCookie",value:function(){document.cookie="cconsent=; expires=Thu, 01 Jan 1980 00:00:00 UTC; path=/;"}},{key:"listGlobalServices",value:function(e){var t=[];if(void 0===window.CookieConsent)return t;if(void 0===e)for(var n in window.CookieConsent.config.services)t.push(n);else for(var o in window.CookieConsent.config.services)window.CookieConsent.config.services[o].category===e&&t.push(o);return t}},{key:"dispatchEvent",value:function(e,t){"function"==typeof Event?t=new Event(t):(t=document.createEvent("Event")).initEvent(t,!0,!0),e.dispatchEvent(t)}}],(o=null)&&e(n.prototype,o),i&&e(n,i),Object.defineProperty(n,"prototype",{writable:!1}),t}();function n(e,t){for(var n=0;n=0&&!1===window.CookieConsent.config.categories[window.CookieConsent.config.services[t].category].wanted)return void window.CookieConsent.buffer.appendChild.push({this:this,category:window.CookieConsent.config.services[t].category,arguments});return Node.prototype.appendChild.apply(this,arguments)}}},{key:"overrideInsertBefore",value:function(){Element.prototype.insertBefore=function(e){if("SCRIPT"===arguments[0].tagName)for(var t in window.CookieConsent.config.services)if("dynamic-script"===window.CookieConsent.config.services[t].type&&arguments[0].outerHTML.indexOf(window.CookieConsent.config.services[t].search)>=0&&!1===window.CookieConsent.config.categories[window.CookieConsent.config.services[t].category].wanted)return void window.CookieConsent.buffer.insertBefore.push({this:this,category:window.CookieConsent.config.services[t].category,arguments});return Node.prototype.insertBefore.apply(this,arguments)}}}],n&&r(t.prototype,n),o&&r(t,o),Object.defineProperty(t,"prototype",{writable:!1}),s}(o);function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function f(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return _(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,c=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return c=e.done,e},e:function(e){a=!0,r=e},f:function(){try{c||null==n.return||n.return()}finally{if(a)throw r}}}}function _(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1?arguments[1]:void 0;e.indexOf(t)<0&&n()}}}],n&&C(t.prototype,n),o&&C(t,o),Object.defineProperty(t,"prototype",{writable:!1}),r}(o);function B(e){return B="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},B(e)}function L(e,t){for(var n=0;n0;)n[o]=arguments[o+1];var i=typeof e;if("string"===i)t=ae(e).cloneNode(!1);else if(oe(e))t=e.cloneNode(!1);else{if("function"!==i)throw new Error("At least one argument required");var r=e;t=new(Function.prototype.bind.apply(r,[null].concat(n)))}return ee(ne(t),n,!0),t}var ce=re;function ae(e){return ie[e]||(ie[e]=F(e))}function se(e){for(var t=[],n=arguments.length-1;n-- >0;)t[n]=arguments[n+1];for(var o=ne(e),i=le(e,t,o.firstChild);i;){var r=i.nextSibling;I(e,i),i=r}}function le(e,t,n){for(var o=n,i=new Array(t.length),r=0;r0;)t[n]=arguments[n+1];var o=ae(e);return re.bind.apply(re,[this,o].concat(t))};var ue=function(e,t,n){this.View=e,this.initData=n,this.oldLookup={},this.lookup={},this.oldViews=[],this.views=[],null!=t&&(this.key="function"==typeof t?t:function(e){return function(t){return t[e]}}(t))};ue.prototype.update=function(e,t){for(var n=this,o=n.View,i=n.key,r=n.initData,c=null!=i,a=this.lookup,s={},l=new Array(e.length),u=this.views,d=0;d0;)n[o]=arguments[o+1];var i=typeof e;if("string"===i)t=ge(e).cloneNode(!1);else if(oe(e))t=e.cloneNode(!1);else{if("function"!==i)throw new Error("At least one argument required");var r=e;t=new(Function.prototype.bind.apply(r,[null].concat(n)))}return ee(ne(t),n,!0),t}function ge(e){return be[e]||(be[e]=F(e,me))}function he(e,t){for(var n=0;n=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,c=!0,a=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return c=e.done,e},e:function(e){a=!0,r=e},f:function(){try{c||null==n.return||n.return()}finally{if(a)throw r}}}}function ve(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n