cookie-though
Version:
Easy to use, minimal footprint application that manages cookie preferences. <br> So delicious, you'll never need another library again 😄
1 lines • 38.6 kB
JavaScript
(function () {function pb(a){return a&&a.__esModule?{d:a.default}:{d:a}}var U=this;var k={};var C={};var ka,b,qb,a,la,rb,sb,c,V={},za=[],tb=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function q(r,o){for(var e in o)r[e]=o[e];return r}function Aa(r){var o=r.parentNode;o&&o.removeChild(r)}function g(r,o,e){var t,$,n,a={};for(n in o)"key"==n?t=o[n]:"ref"==n?$=o[n]:a[n]=o[n];if(arguments.length>2&&(a.children=arguments.length>3?ka.call(arguments,2):e),"function"==typeof r&&null!=r.defaultProps)for(n in r.defaultProps)void 0===a[n]&&(a[n]=r.defaultProps[n]);return W(r,a,t,$,null)}function W(r,o,e,t,$){var n={type:r,props:o,key:e,ref:t,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==$?++qb:$};return null==$&&null!=b.vnode&&b.vnode(n),n}function J(r){return r.children}function X(r,o){this.props=r,this.context=o}function E(r,o){if(null==o)return r.__?E(r.__,r.__.__k.indexOf(r)+1):null;for(var e;o<r.__k.length;o++)if(null!=(e=r.__k[o])&&null!=e.__e)return e.__e;return"function"==typeof r.type?E(r):null}function Ba(r){var o,e;if(null!=(r=r.__)&&null!=r.__c){for(r.__e=r.__c.base=null,o=0;o<r.__k.length;o++)if(null!=(e=r.__k[o])&&null!=e.__e){r.__e=r.__c.base=e.__e;break}return Ba(r)}}function Ca(r){(!r.__d&&(r.__d=!0)&&la.push(r)&&!Y.__r++||sb!==b.debounceRendering)&&((sb=b.debounceRendering)||rb)(Y)}function Y(){for(var r;Y.__r=la.length;)r=la.sort(function(r,o){return r.__v.__b-o.__v.__b}),la=[],r.some(function(r){var o,e,t,$,n,a;r.__d&&(n=($=(o=r).__v).__e,(a=o.__P)&&(e=[],(t=q({},$)).__v=$.__v+1,ma(a,$,t,o.__n,void 0!==a.ownerSVGElement,null!=$.__h?[n]:null,e,null==n?E($):n,$.__h),Ja(e,$),$.__e!=n&&Ba($)))})}function Da(r,o,e,t,$,n,a,_,l,i){var p,u,s,v,S,c,f,d=t&&t.__k||za,h=d.length;for(e.__k=[],p=0;p<o.length;p++)if(null!=(v=e.__k[p]=null==(v=o[p])||"boolean"==typeof v?null:"string"==typeof v||"number"==typeof v||"bigint"==typeof v?W(null,v,null,null,v):Array.isArray(v)?W(J,{children:v},null,null,null):v.__b>0?W(v.type,v.props,v.key,null,v.__v):v)){if(v.__=e,v.__b=e.__b+1,null===(s=d[p])||s&&v.key==s.key&&v.type===s.type)d[p]=void 0;else for(u=0;u<h;u++){if((s=d[u])&&v.key==s.key&&v.type===s.type){d[u]=void 0;break}s=null}ma(r,v,s=s||V,$,n,a,_,l,i),S=v.__e,(u=v.ref)&&s.ref!=u&&(f||(f=[]),s.ref&&f.push(s.ref,null,v),f.push(u,v.__c||S,v)),null!=S?(null==c&&(c=S),"function"==typeof v.type&&v.__k===s.__k?v.__d=l=Ea(v,l,r):l=Fa(r,v,s,d,S,l),"function"==typeof e.type&&(e.__d=l)):l&&s.__e==l&&l.parentNode!=r&&(l=E(s))}for(e.__e=c,p=h;p--;)null!=d[p]&&("function"==typeof e.type&&null!=d[p].__e&&d[p].__e==e.__d&&(e.__d=E(t,p+1)),La(d[p],d[p]));if(f)for(p=0;p<f.length;p++)Ka(f[p],f[++p],f[++p])}function Ea(r,o,e){for(var t,$=r.__k,n=0;$&&n<$.length;n++)(t=$[n])&&(t.__=r,o="function"==typeof t.type?Ea(t,o,e):Fa(e,t,t,$,t.__e,o));return o}function ub(r,o){return o=o||[],null==r||"boolean"==typeof r||(Array.isArray(r)?r.some(function(r){ub(r,o)}):o.push(r)),o}function Fa(r,o,e,t,$,n){var a,_,l;if(void 0!==o.__d)a=o.__d,o.__d=void 0;else if(null==e||$!=n||null==$.parentNode)r:if(null==n||n.parentNode!==r)r.appendChild($),a=null;else{for(_=n,l=0;(_=_.nextSibling)&&l<t.length;l+=2)if(_==$)break r;r.insertBefore($,n),a=n}return void 0!==a?a:$.nextSibling}function vb(r,o,e,t,$){var n;for(n in e)"children"===n||"key"===n||n in o||Z(r,n,null,e[n],t);for(n in o)$&&"function"!=typeof o[n]||"children"===n||"key"===n||"value"===n||"checked"===n||e[n]===o[n]||Z(r,n,o[n],e[n],t)}function Ga(r,o,e){"-"===o[0]?r.setProperty(o,e):r[o]=null==e?"":"number"!=typeof e||tb.test(o)?e:e+"px"}function Z(r,o,e,t,$){var n;r:if("style"===o){if("string"==typeof e)r.style.cssText=e;else{if("string"==typeof t&&(r.style.cssText=t=""),t)for(o in t)e&&o in e||Ga(r.style,o,"");if(e)for(o in e)t&&e[o]===t[o]||Ga(r.style,o,e[o])}}else if("o"===o[0]&&"n"===o[1])n=o!==(o=o.replace(/Capture$/,"")),o=o.toLowerCase()in r?o.toLowerCase().slice(2):o.slice(2),r.l||(r.l={}),r.l[o+n]=e,e?t||r.addEventListener(o,n?Ia:Ha,n):r.removeEventListener(o,n?Ia:Ha,n);else if("dangerouslySetInnerHTML"!==o){if($)o=o.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("href"!==o&&"list"!==o&&"form"!==o&&"tabIndex"!==o&&"download"!==o&&o in r)try{r[o]=null==e?"":e;break r}catch(r){}"function"==typeof e||(null!=e&&(!1!==e||"a"===o[0]&&"r"===o[1])?r.setAttribute(o,e):r.removeAttribute(o))}}function Ha(r){this.l[r.type+!1](b.event?b.event(r):r)}function Ia(r){this.l[r.type+!0](b.event?b.event(r):r)}function ma(r,o,e,t,$,n,a,_,l){var i,p,u,s,v,S,c,f,d,h,x,y=o.type;if(void 0!==o.constructor)return null;null!=e.__h&&(l=e.__h,_=o.__e=e.__e,o.__h=null,n=[_]),(i=b.__b)&&i(o);try{r:if("function"==typeof y){if(f=o.props,d=(i=y.contextType)&&t[i.__c],h=i?d?d.props.value:i.__:t,e.__c?c=(p=o.__c=e.__c).__=p.__E:("prototype"in y&&y.prototype.render?o.__c=p=new y(f,h):(o.__c=p=new X(f,h),p.constructor=y,p.render=xb),d&&d.sub(p),p.props=f,p.state||(p.state={}),p.context=h,p.__n=t,u=p.__d=!0,p.__h=[]),null==p.__s&&(p.__s=p.state),null!=y.getDerivedStateFromProps&&(p.__s==p.state&&(p.__s=q({},p.__s)),q(p.__s,y.getDerivedStateFromProps(f,p.__s))),s=p.props,v=p.state,u)null==y.getDerivedStateFromProps&&null!=p.componentWillMount&&p.componentWillMount(),null!=p.componentDidMount&&p.__h.push(p.componentDidMount);else{if(null==y.getDerivedStateFromProps&&f!==s&&null!=p.componentWillReceiveProps&&p.componentWillReceiveProps(f,h),!p.__e&&null!=p.shouldComponentUpdate&&!1===p.shouldComponentUpdate(f,p.__s,h)||o.__v===e.__v){p.props=f,p.state=p.__s,o.__v!==e.__v&&(p.__d=!1),p.__v=o,o.__e=e.__e,o.__k=e.__k,o.__k.forEach(function(r){r&&(r.__=o)}),p.__h.length&&a.push(p);break r}null!=p.componentWillUpdate&&p.componentWillUpdate(f,p.__s,h),null!=p.componentDidUpdate&&p.__h.push(function(){p.componentDidUpdate(s,v,S)})}p.context=h,p.props=f,p.state=p.__s,(i=b.__r)&&i(o),p.__d=!1,p.__v=o,p.__P=r,i=p.render(p.props,p.state,p.context),p.state=p.__s,null!=p.getChildContext&&(t=q(q({},t),p.getChildContext())),u||null==p.getSnapshotBeforeUpdate||(S=p.getSnapshotBeforeUpdate(s,v)),x=null!=i&&i.type===J&&null==i.key?i.props.children:i,Da(r,Array.isArray(x)?x:[x],o,e,t,$,n,a,_,l),p.base=o.__e,o.__h=null,p.__h.length&&a.push(p),c&&(p.__E=p.__=null),p.__e=!1}else null==n&&o.__v===e.__v?(o.__k=e.__k,o.__e=e.__e):o.__e=wb(e.__e,o,e,t,$,n,a,l);(i=b.diffed)&&i(o)}catch(r){o.__v=null,(l||null!=n)&&(o.__e=_,o.__h=!!l,n[n.indexOf(_)]=null),b.__e(r,o,e)}}function Ja(r,o){b.__c&&b.__c(o,r),r.some(function(o){try{r=o.__h,o.__h=[],r.some(function(r){r.call(o)})}catch(r){b.__e(r,o.__v)}})}function wb(r,o,e,t,$,n,a,_){var l,i,p,u=e.props,s=o.props,v=o.type,S=0;if("svg"===v&&($=!0),null!=n)for(;S<n.length;S++)if((l=n[S])&&"setAttribute"in l==!!v&&(v?l.localName===v:3===l.nodeType)){r=l,n[S]=null;break}if(null==r){if(null===v)return document.createTextNode(s);r=$?document.createElementNS("http://www.w3.org/2000/svg",v):document.createElement(v,s.is&&s),n=null,_=!1}if(null===v)u===s||_&&r.data===s||(r.data=s);else{if(n=n&&ka.call(r.childNodes),i=(u=e.props||V).dangerouslySetInnerHTML,p=s.dangerouslySetInnerHTML,!_){if(null!=n)for(u={},S=0;S<r.attributes.length;S++)u[r.attributes[S].name]=r.attributes[S].value;(p||i)&&(p&&(i&&p.__html==i.__html||p.__html===r.innerHTML)||(r.innerHTML=p&&p.__html||""))}if(vb(r,s,u,$,_),p)o.__k=[];else if(S=o.props.children,Da(r,Array.isArray(S)?S:[S],o,e,t,$&&"foreignObject"!==v,n,a,n?n[0]:e.__k&&E(e,0),_),null!=n)for(S=n.length;S--;)null!=n[S]&&Aa(n[S]);_||("value"in s&&void 0!==(S=s.value)&&(S!==r.value||"progress"===v&&!S||"option"===v&&S!==u.value)&&Z(r,"value",S,u.value,!1),"checked"in s&&void 0!==(S=s.checked)&&S!==r.checked&&Z(r,"checked",S,u.checked,!1))}return r}function Ka(r,o,e){try{"function"==typeof r?r(o):r.current=o}catch(r){b.__e(r,e)}}function La(r,o,e){var t,$;if(b.unmount&&b.unmount(r),(t=r.ref)&&(t.current&&t.current!==r.__e||Ka(t,null,o)),null!=(t=r.__c)){if(t.componentWillUnmount)try{t.componentWillUnmount()}catch(r){b.__e(r,o)}t.base=t.__P=null}if(t=r.__k)for($=0;$<t.length;$++)t[$]&&La(t[$],o,"function"!=typeof r.type);e||null==r.__e||Aa(r.__e),r.__e=r.__d=void 0}function xb(r,o,e){return this.constructor(r,e)}function na(r,o,e){var t,$,n;b.__&&b.__(r,o),$=(t="function"==typeof e)?null:e&&e.__k||o.__k,n=[],ma(o,r=(!t&&e||o).__k=g(J,null,[r]),$||V,V,void 0!==o.ownerSVGElement,!t&&e?[e]:$?null:o.firstChild?ka.call(o.childNodes):null,n,!t&&e?e:$?$.__e:o.firstChild,t),Ja(n,r)}function yb(r,o){na(r,o,yb)}ka=za.slice,b={__e:function(r,o,e,t){for(var $,n,a;o=o.__;)if(($=o.__c)&&!$.__)try{if((n=$.constructor)&&null!=n.getDerivedStateFromError&&($.setState(n.getDerivedStateFromError(r)),a=$.__d),null!=$.componentDidCatch&&($.componentDidCatch(r,t||{}),a=$.__d),a)return $.__E=$}catch(o){r=o}throw r}},qb=0,a=function(r){return null!=r&&void 0===r.constructor},X.prototype.setState=function(r,o){var e;e=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=q({},this.state),"function"==typeof r&&(r=r(q({},e),this.props)),r&&q(e,r),null!=r&&this.__v&&(o&&this.__h.push(o),Ca(this))},X.prototype.forceUpdate=function(r){this.__v&&(this.__e=!0,r&&this.__h.push(r),Ca(this))},X.prototype.render=J,la=[],rb="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Y.__r=0,c=0;var zb=function(e){var t=e.header,$=function(e){return e in t},r=function(e){return t[e]};return g("div",{className:"ct-banner"},g("div",{className:"ct-banner-intro"},g("div",{className:"ct-banner-header"},$("subTitle")&&g("p",null,r("subTitle")),$("title")&&g("h1",null,r("title"))),g("div",{className:"ct-banner-logo"},g("svg",{width:"33",height:"33",viewBox:"0 0 26 26",fill:"none",xmlns:"http://www.w3.org/2000/svg"},g("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M20.5 14C21.4008 14 22.251 13.7834 23.0014 13.3996C23.0005 13.4329 23 13.4664 23 13.5C23 15.0583 24.0184 16.3788 25.426 16.8321C23.7905 22.1414 18.8459 26 13 26C5.8203 26 0 20.1797 0 13C0 5.8203 5.8203 0 13 0C13.954 0 14.884 0.102758 15.7795 0.29781C15.292 0.899245 15 1.66552 15 2.5C15 3.53742 15.4514 4.46941 16.1684 5.11034C15.4364 6.04443 15 7.22125 15 8.5C15 11.5376 17.4624 14 20.5 14ZM11 7C11 7.55228 10.5523 8 10 8C9.44772 8 9 7.55228 9 7C9 6.44772 9.44772 6 10 6C10.5523 6 11 6.44772 11 7ZM12 13C12 14.1046 11.1046 15 10 15C8.89543 15 8 14.1046 8 13C8 11.8954 8.89543 11 10 11C11.1046 11 12 11.8954 12 13ZM17 20C17.5523 20 18 19.5523 18 19C18 18.4477 17.5523 18 17 18C16.4477 18 16 18.4477 16 19C16 19.5523 16.4477 20 17 20ZM10 19.5C10 20.3284 9.32843 21 8.5 21C7.67157 21 7 20.3284 7 19.5C7 18.6716 7.67157 18 8.5 18C9.32843 18 10 18.6716 10 19.5Z",fill:"#000099"})))),g("div",{className:"ct-banner-explanation"},r("description")))};var L={};var Ab=function(t){var o=t.label,e=t.isActive,$=t.toggleCustomization;return g("button",{className:"ct-customization-button ".concat(e?"ct-active":""),onClick:function(){$()}},o," ",g("svg",{width:"9",height:"6",viewBox:"0 0 9 6",fill:"none",xmlns:"http://www.w3.org/2000/svg"},g("path",{d:"M0.747437 0.757812L4.28297 4.29335L7.8185 0.757811"})))};var aa,z,Bb,Cb=0,Ma=[],Na=b.__b,Oa=b.__r,Pa=b.diffed,Qa=b.__c,Ra=b.unmount;function ba($,r){b.__h&&b.__h(z,$,Cb||r),Cb=0;var t=z.__H||(z.__H={__:[],__h:[]});return $>=t.__.length&&t.__.push({}),t.__[$]}function Sa($){return Cb=1,Db(Ua,$)}function Db($,r,t){var e=ba(aa++,2);return e.t=$,e.__c||(e.__=[t?t(r):Ua(void 0,r),function($){var r=e.t(e.__[0],$);e.__[0]!==r&&(e.__=[r,e.__[1]],e.__c.setState({}))}],e.__c=z),e.__}function oa($,r){var t=ba(aa++,3);!b.__s&&ra(t.__H,r)&&(t.__=$,t.__H=r,z.__H.__h.push(t))}function Eb($,r){var t=ba(aa++,4);!b.__s&&ra(t.__H,r)&&(t.__=$,t.__H=r,z.__h.push(t))}function Fb($){return Cb=5,pa(function(){return{current:$}},[])}function pa($,r){var t=ba(aa++,7);return ra(t.__H,r)&&(t.__=$(),t.__H=r,t.__h=$),t.__}function Gb($,r){return Cb=8,pa(function(){return $},r)}function Hb(){for(var $;$=Ma.shift();)if($.__P)try{$.__H.__h.forEach(ca),$.__H.__h.forEach(qa),$.__H.__h=[]}catch(r){$.__H.__h=[],b.__e(r,$.__v)}}b.__b=function($){z=null,Na&&Na($)},b.__r=function($){Oa&&Oa($),aa=0;var r=(z=$.__c).__H;r&&(r.__h.forEach(ca),r.__h.forEach(qa),r.__h=[])},b.diffed=function($){Pa&&Pa($);var r=$.__c;r&&r.__H&&r.__H.__h.length&&(1!==Ma.push(r)&&Bb===b.requestAnimationFrame||((Bb=b.requestAnimationFrame)||function($){var r,t=function(){clearTimeout(e),Ta&&cancelAnimationFrame(r),setTimeout($)},e=setTimeout(t,100);Ta&&(r=requestAnimationFrame(t))})(Hb)),z=null},b.__c=function($,r){r.some(function($){try{$.__h.forEach(ca),$.__h=$.__h.filter(function($){return!$.__||qa($)})}catch(t){r.some(function($){$.__h&&($.__h=[])}),r=[],b.__e(t,$.__v)}}),Qa&&Qa($,r)},b.unmount=function($){Ra&&Ra($);var r,t=$.__c;t&&t.__H&&(t.__H.__.forEach(function($){try{ca($)}catch($){r=$}}),r&&b.__e(r,t.__v))};var Ta="function"==typeof requestAnimationFrame;function ca($){var r=z,t=$.__c;"function"==typeof t&&($.__c=void 0,t()),z=r}function qa($){var r=z;$.__c=$.__(),z=r}function ra($,r){return!$||$.length!==r.length||r.some(function(r,t){return r!==$[t]})}function Ua($,r){return"function"==typeof r?r($):r}var M=function(s){return"essential"===s};var P=function(e){var t=document.querySelector(".cookie-though");if(e)return t.style.display="block",t.setAttribute("aria-hidden","false"),t.classList.add("visible");t.setAttribute("aria-hidden","true"),t.classList.remove("visible"),setTimeout(function(){return t.style.display="none"},250)};var Ib=function(e){var i=e.isOpen,o=e.option,t=e.essentialLabel,r=e.onToggle,$=M(o.category);return g("div",{className:"ct-option ".concat(o.isEnabled?"ct-enabled":""," ").concat($?"ct-essential":"")},g("input",{type:"checkbox",id:o.id,name:o.id,disabled:$,checked:o.isEnabled,onClick:r,onFocus:function(e){return e.currentTarget.parentElement.scrollIntoView()},tabIndex:i?0:-1,"aria-hidden":!i}),g("label",{htmlFor:o.id,className:"ct-option-info"},g("p",null,g("strong",null,o.label),o.description),g("span",{className:"ct-slider"},$&&t)))};var Jb=function(e){var n=e.isOpen,r=e.options,o=e.cookiePolicy,$=e.essentialLabel,t=e.onToggle,i=r.map(function(e,r){return g(Ib,{key:r,isOpen:n,option:e,essentialLabel:$,onToggle:function(){return t(r)}})});return g("div",{className:"ct-policies"},i,o&&g("div",{className:"ct-declaration"},g("a",{tabIndex:0,href:o.url,role:"link"},o.label)))};var Kb={},Va="Expected a function",Wa=NaN,Lb="[object Symbol]",Mb=/^\s+|\s+$/g,Nb=/^[-+]0x[0-9a-f]+$/i,Ob=/^0b[01]+$/i,Pb=/^0o[0-7]+$/i,Qb=parseInt,Rb="object"==typeof U&&U&&U.Object===Object&&U,Sb="object"==typeof self&&self&&self.Object===Object&&self,Tb=Rb||Sb||Function("return this")(),Ub=Object.prototype,Vb=Ub.toString,Wb=Math.max,Xb=Math.min,sa=function(){return Tb.Date.now()};function Yb($,r,e){var t,a,n,i,o,v,y=0,O=!1,N=!1,c=!0;if("function"!=typeof $)throw new TypeError(Va);function F(r){var e=t,n=a;return t=a=void 0,y=r,i=$.apply(n,e)}function f($){var e=$-v;return void 0===v||e>=r||e<0||N&&$-y>=n}function u(){var $=sa();if(f($))return l($);o=setTimeout(u,function($){var e=r-($-v);return N?Xb(e,n-($-y)):e}($))}function l($){return o=void 0,c&&t?F($):(t=a=void 0,i)}function s(){var $=sa(),e=f($);if(t=arguments,a=this,v=$,e){if(void 0===o)return function($){return y=$,o=setTimeout(u,r),O?F($):i}(v);if(N)return o=setTimeout(u,r),F(v)}return void 0===o&&(o=setTimeout(u,r)),i}return r=Xa(r)||0,da(e)&&(O=!!e.leading,n=(N="maxWait"in e)?Wb(Xa(e.maxWait)||0,r):n,c="trailing"in e?!!e.trailing:c),s.cancel=function(){void 0!==o&&clearTimeout(o),y=0,t=v=a=o=void 0},s.flush=function(){return void 0===o?i:l(sa())},s}function Zb($,r,e){var t=!0,a=!0;if("function"!=typeof $)throw new TypeError(Va);return da(e)&&(t="leading"in e?!!e.leading:t,a="trailing"in e?!!e.trailing:a),Yb($,r,{leading:t,maxWait:r,trailing:a})}function da($){var r=typeof $;return!!$&&("object"==r||"function"==r)}function $b($){return!!$&&"object"==typeof $}function _b($){return"symbol"==typeof $||$b($)&&Vb.call($)==Lb}function Xa($){if("number"==typeof $)return $;if(_b($))return Wa;if(da($)){var r="function"==typeof $.valueOf?$.valueOf():$;$=da(r)?r+"":r}if("string"!=typeof $)return 0===$?$:+$;$=$.replace(Mb,"");var e=Ob.test($);return e||Pb.test($)?Qb($.slice(2),e?2:8):Nb.test($)?Wa:+$}Kb=Zb;var ac=function(e){Eb(function(){var $FNyO$$interop$default=pb(Kb);var r=$FNyO$$interop$default.d(e,100);return window.addEventListener("resize",r),function(){return window.removeEventListener("resize",r)}},[e])};var bc=function(){var e=document.querySelector(".cookie-though").shadowRoot,t=e.querySelector(".ct-banner"),o=e.querySelector(".ct-customization-button"),d=e.querySelector(".ct-acceptance"),c=[],p=window.getComputedStyle(t);c.push(p.height,p.paddingTop,p.paddingTop);var r=window.getComputedStyle(o);c.push(r.height);var u=window.getComputedStyle(d);return c.push(u.height,u.paddingTop,u.paddingTop),c.push(p.paddingTop),{collapsedHeight:c.reduce(function(e,t){return e+Number(t.slice(0,-2))},0),containerOffset:2*+p.paddingBottom.slice(0,-2)}};var cc=function(e){var t=e.isOpen,r=e.children,i=e.onWindowResize,o=Fb(null),s=Gb(function(e){void 0===e&&(e=!1);var t=bc(),r=t.collapsedHeight,i=t.containerOffset,s=window.innerHeight,n=o.current,l=n.querySelector(".ct-policies").scrollHeight;e&&(n.style.transition="height 0ms ease-out");var a=s-r-i;a<l?(n.style.height="".concat(a,"px"),n.style.overflow="scroll",n.style.scrollBehavior="auto",n.scrollTop=0):n.style.height="".concat(l,"px"),e&&setTimeout(function(){return n.style.transition="height 250ms ease-out"},100),setTimeout(function(){return n.style.removeProperty("scroll-behavior")},250)},[]);return ac(function(){if(i(),t)return s(!0)}),oa(function(){if(t)return s();o.current.style.height="0px"},[t]),g("div",{className:"ct-collapse",ref:o,"aria-expanded":t,tabIndex:-1},r)};var Ya=function(t){var e=t.label,r=t.className,$=void 0===r?"":r,a=t.onClick;return g("button",{className:"ct-button ".concat($),onClick:a},e)};var A=L&&L.__assign||function(){return(A=Object.assign||function($){for(var e,r=1,t=arguments.length;r<t;r++)for(var i in e=arguments[r])Object.prototype.hasOwnProperty.call(e,i)&&($[i]=e[i]);return $}).apply(this,arguments)},dc=L&&L.__spreadArray||function($,e,r){if(r||2===arguments.length)for(var t,i=0,n=e.length;i<n;i++)!t&&i in e||(t||(t=Array.prototype.slice.call(e,0,i)),t[i]=e[i]);return $.concat(t||Array.prototype.slice.call(e))},Za=function($){return $.some(function($){return!M($.category)&&!0===$.isEnabled})},$a=function($){return{cookieOptions:$.map(function($){return{id:$.id,isEnabled:$.isEnabled}}),isCustomised:!0}},_a=function($){var e=$.cookieOptions,r=$.customizeLabel,t=$.permissionLabels,i=$.cookiePolicy,n=$.essentialLabel,o=$.setCookiePreferences,a=$.onWindowResize,R=Sa(function(){return e}),s=R[0],p=R[1],c=Sa(!1),l=c[0],u=c[1],w=pa(function(){return l||Za(s)?t.accept:t.acceptAll},[l,s,t.accept,t.acceptAll]);oa(function(){p(e)},[e]);return g("div",null,g(Ab,{label:r,isActive:l,toggleCustomization:function(){return u(function($){return!$})}}),g(cc,{isOpen:l,onWindowResize:a},g(Jb,{isOpen:l,options:s,cookiePolicy:i,essentialLabel:n,onToggle:function($){s[$]=A(A({},s[$]),{isEnabled:!s[$].isEnabled}),p(dc([],s,!0))}})),g("div",{className:"ct-acceptance"},g(Ya,{label:t.decline,className:"ct-button-secondary",onClick:function(){var $=s.map(function($){return A(A({},$),{isEnabled:!!M($.category)})});p($),u(!1),P(!1),o($a($))}}),g(Ya,{label:w,onClick:function(){var $=s.map(function($){return A(A({},$),{isEnabled:$.isEnabled})});l||Za(s)||($=$.map(function($){return A(A({},$),{isEnabled:!0})}),p($)),u(!1),P(!1),o($a($))}})))};L.default=_a;var m={},ab=m&&m.__assign||function(){return(ab=Object.assign||function(e){for(var o,t=1,r=arguments.length;t<r;t++)for(var n in o=arguments[t])Object.prototype.hasOwnProperty.call(o,n)&&(e[n]=o[n]);return e}).apply(this,arguments)},ta="cookie-preferences";m.COOKIE_PREFERENCES_KEY=ta;var ua="preferences_changed";m.COOKIE_PREFERENCES_CHANGED_EVENT=ua;var bb=function(e){var o=decodeURIComponent(document.cookie).split(";").reduce(function(o,t){if(o)return o;var r=t.split("="),n=r[0],i=r[1];return n.trim()===e?i.split("|"):void 0},void 0);if(o){if(!o[0].includes("cookieOptions"))return{isCustomised:!0,cookieOptions:o.map(function(e){var o=e.split(":");return{id:o[0],isEnabled:!!+o[1]}})};document.cookie="".concat(e,"= ; expires= Thu, 01 Jan 1970 00:00:00 GMT; path=/")}};m.getCookie=bb;var cb=function(){var e=new Date;return new Date(e.setFullYear(e.getFullYear()+1)).toUTCString()};m.getNextYear=cb;var ec=function(e,o){return e.some(function(o){return!e.includes(o)})||e.length!==o.length},fc=function(e,o){return e.map(function(e){var t=o.reduce(function(o,t){return t.id===e.id?t.isEnabled:o},!1);return ab(ab({},e),{isEnabled:t})})},va=function(e,o){var t={cookieOptions:e,isCustomised:!1},r=bb(o);if(!r)return t;var n=t.cookieOptions.map(function(e){return e.id}),i=r.cookieOptions.map(function(e){return e.id});return ec(n,i)?{cookieOptions:fc(t.cookieOptions,r.cookieOptions),isCustomised:!1}:r};m.getCookiePreferences=va;var db=function(e){return e.reduce(function(e,o,t){return"".concat(e).concat(0!==t?"|":"").concat(o.id,":").concat(o.isEnabled?"1":"0")},"")};m.formatToCookie=db;var eb=function(e){var o=e.cookieOptions,t=e.domain,r=e.cookiePreferenceKey,n=void 0===r?ta:r,i=e.ee;return{getCookiePreferences:function(){return va(o,n)},setCookiePreferences:function(e){var o=cb();return document.cookie="".concat(n,"=").concat(db(e.cookieOptions),"; expires=").concat(o,"; path=/; SameSite=Strict;").concat(t?"Domain=".concat(t):""),i&&i.emit(ua,e),e}}};m.default=eb;var ea=C&&C.__assign||function(){return(ea=Object.assign||function(e){for(var $,t=1,s=arguments.length;t<s;t++)for(var o in $=arguments[t])Object.prototype.hasOwnProperty.call($,o)&&(e[o]=$[o]);return e}).apply(this,arguments)},G=["360px","380px","425px","500px"];C.CONTAINER_WIDTHS=G;var H=["-300px","-350px","-400px","-500px"];C.CONTAINER_BOTTOMS=H;var fa=["-400px","-500px","-650px"];C.MOBILE_CONTAINER_BOTTOMS=fa;var fb=function(){var e=document.querySelector(".cookie-though"),$=e.shadowRoot.querySelector(".ct-banner-explanation"),t=+window.getComputedStyle($).fontSize.slice(0,-2),s=window.innerWidth<768;s&&e.style.removeProperty("width"),e.style.bottom=H[0],13<t&&t<=14&&(s||(e.style.width=G[0])),14<t&&t<=16&&(s||(e.style.width=G[1]),e.style.bottom=H[1]),16<t&&t<=18&&(s?e.style.bottom=fa[0]:(e.style.bottom=H[1],e.style.width=G[2])),18<t&&t<=22&&(s?e.style.bottom=fa[1]:(e.style.bottom=H[2],e.style.width=G[3])),t>22&&(s?e.style.bottom=fa[2]:(e.style.bottom=H[3],e.style.width=G[3]))},wa=function(e){var $,t,s=e.policies,o=e.cookiePreferenceKey,r=e.header,i=e.customizeLabel,p=e.domain,a=e.cookiePolicy,n=e.permissionLabels,O=e.essentialLabel,D=e.ee,T=eb({cookieOptions:s.map(function(e){return{id:e.id,isEnabled:M(e.category)}}),ee:D,cookiePreferenceKey:o,domain:p}),K=T.getCookiePreferences,Q=T.setCookiePreferences,l=($=K(),t=$.cookieOptions.map(function(e){var $=s.find(function($){return $.id===e.id});return ea(ea({},$),e)}),ea(ea({},$),{cookieOptions:t}));return oa(function(){fb(),l.isCustomised||P(!0)},[l]),g(J,null,g(zb,{header:r}),g(_a,{cookieOptions:l.cookieOptions,cookiePolicy:a,customizeLabel:i,permissionLabels:n,essentialLabel:O,setCookiePreferences:Q,onWindowResize:fb}))};C.default=wa;var gc,hc={},I="object"==typeof Reflect?Reflect:null,gb=I&&"function"==typeof I.apply?I.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};function ic(e){console&&console.warn&&console.warn(e)}gc=I&&"function"==typeof I.ownKeys?I.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var hb=Number.isNaN||function(e){return e!=e};function j(){j.init.call(this)}(hc=j).once=nc,j.EventEmitter=j,j.prototype._events=void 0,j.prototype._eventsCount=0,j.prototype._maxListeners=void 0;var jc=10;function ga(e){if("function"!=typeof e)throw new TypeError("The \"listener\" argument must be of type Function. Received type "+typeof e)}function ib(e){return void 0===e._maxListeners?j.defaultMaxListeners:e._maxListeners}function jb(e,t,r,n){var i,o,$;if(ga(r),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),o=e._events),$=o[t]),void 0===$)$=o[t]=r,++e._eventsCount;else if("function"==typeof $?$=o[t]=n?[r,$]:[$,r]:n?$.unshift(r):$.push(r),(i=ib(e))>0&&$.length>i&&!$.warned){$.warned=!0;var s=new Error("Possible EventEmitter memory leak detected. "+$.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");s.name="MaxListenersExceededWarning",s.emitter=e,s.type=t,s.count=$.length,ic(s)}return e}function kc(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function kb(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=kc.bind(n);return i.listener=r,n.wrapFn=i,i}function lb(e,t,r){var n=e._events;if(void 0===n)return[];var i=n[t];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?mc(i):nb(i,i.length)}function mb(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function nb(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function lc(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function mc(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}function nc(e,t){return new Promise(function(r,n){function i(r){e.removeListener(t,o),n(r)}function o(){"function"==typeof e.removeListener&&e.removeListener("error",i),r([].slice.call(arguments))}ob(e,t,o,{once:!0}),"error"!==t&&oc(e,i,{once:!0})})}function oc(e,t,r){"function"==typeof e.on&&ob(e,"error",t,r)}function ob(e,t,r,n){if("function"==typeof e.on)n.once?e.once(t,r):e.on(t,r);else{if("function"!=typeof e.addEventListener)throw new TypeError("The \"emitter\" argument must be of type EventEmitter. Received type "+typeof e);e.addEventListener(t,function i(o){n.once&&e.removeEventListener(t,i),r(o)})}}Object.defineProperty(j,"defaultMaxListeners",{enumerable:!0,get:function(){return jc},set:function(e){if("number"!=typeof e||e<0||hb(e))throw new RangeError("The value of \"defaultMaxListeners\" is out of range. It must be a non-negative number. Received "+e+".");jc=e}}),j.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},j.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||hb(e))throw new RangeError("The value of \"n\" is out of range. It must be a non-negative number. Received "+e+".");return this._maxListeners=e,this},j.prototype.getMaxListeners=function(){return ib(this)},j.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n="error"===e,i=this._events;if(void 0!==i)n=n&&void 0===i.error;else if(!n)return!1;if(n){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var $=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw $.context=o,$}var s=i[e];if(void 0===s)return!1;if("function"==typeof s)gb(s,this,t);else{var v=s.length,a=nb(s,v);for(r=0;r<v;++r)gb(a[r],this,t)}return!0},j.prototype.addListener=function(e,t){return jb(this,e,t,!1)},j.prototype.on=j.prototype.addListener,j.prototype.prependListener=function(e,t){return jb(this,e,t,!0)},j.prototype.once=function(e,t){return ga(t),this.on(e,kb(this,e,t)),this},j.prototype.prependOnceListener=function(e,t){return ga(t),this.prependListener(e,kb(this,e,t)),this},j.prototype.removeListener=function(e,t){var r,n,i,o,$;if(ga(t),void 0===(n=this._events))return this;if(void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(i=-1,o=r.length-1;o>=0;o--)if(r[o]===t||r[o].listener===t){$=r[o].listener,i=o;break}if(i<0)return this;0===i?r.shift():lc(r,i),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,$||t)}return this},j.prototype.off=j.prototype.removeListener,j.prototype.removeAllListeners=function(e){var t,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0===arguments.length){var i,o=Object.keys(r);for(n=0;n<o.length;++n)"removeListener"!==(i=o[n])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this},j.prototype.listeners=function(e){return lb(this,e,!0)},j.prototype.rawListeners=function(e){return lb(this,e,!1)},j.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):mb.call(e,t)},j.prototype.listenerCount=mb,j.prototype.eventNames=function(){return this._eventsCount>0?gc(this._events):[]};var pc=[{id:"essential",label:"Strictly necessary cookies",description:"These cookies are required to run the site.",category:"essential"},{id:"functional",label:"Functional cookies",description:"We\u2019ll remember the basics such as language.",category:"functional"},{id:"statistics",label:"Statistics",description:"We\u2019ll know where we should improve your experience.",category:"statistics"},{id:"marketing",label:"Marketing",description:"We'll only show you ads you're interested in.",category:"marketing"},{id:"social",label:"Social",description:"This allows us to track your social activity",category:"social"},{id:"personalisation",label:"Personalisation",description:"We\u2019ll only show you content that interests you.",category:"personalisation"}];var ha={policies:pc,essentialLabel:"Always on",header:{subTitle:"You're probably fed up with these banners...",title:"cookie though?",description:"Everybody wants to show his best side - and so do we. That's why we use cookies to guarantee you a better experience."},permissionLabels:{accept:"Accept",acceptAll:"Accept all",decline:"Decline"},customizeLabel:"Customize"};var B,ia=k&&k.__assign||function(){return(ia=Object.assign||function($){for(var t,e=1,r=arguments.length;e<r;e++)for(var o in t=arguments[e])Object.prototype.hasOwnProperty.call(t,o)&&($[o]=t[o]);return $}).apply(this,arguments)},xa=new hc.EventEmitter,ya=function($){B=$;var t=document.createElement("aside");t.className="cookie-though",t.style.bottom="-600px",t.style.display="none";var e,r=t.attachShadow({mode:"open"});(e=document.createElement("style")).textContent=".ct-banner{font-size:var(--ct-text-font-size);padding:var(--ct-default-padding)}.ct-banner-header{max-width:85%}.ct-banner h1,.ct-banner p{margin-top:0;margin-bottom:var(--ct-text-margin)}.ct-banner h1{font-size:var(--ct-heading-font-size);font-weight:700;color:var(--ct-title)}.ct-banner p{font-weight:500}.ct-banner-intro{display:flex;align-items:center;margin-bottom:calc(.5rem - var(--ct-text-margin))}.ct-banner-intro p{font-size:var(--ct-sub-heading-font-size);color:var(--ct-subtitle)}.ct-banner-logo{margin-left:auto;align-self:flex-start}.ct-banner-logo path{fill-rule:evenodd;clip-rule:evenodd;fill:var(--ct-cookie);stroke:var(--ct-white);stroke-width:0}.ct-banner-explanation{font-family:var(--ct-secondary-font),Arial,Helvetica,sans-serif;color:var(--ct-text);font-weight:var(--ct-secondary-font-weight)}.ct-customization-button{font-family:inherit;font-size:var(--ct-button-font-size);border:none;outline:none;background-color:inherit;padding:.125rem;color:var(--ct-text);display:flex;align-items:baseline;cursor:pointer;margin-left:calc(var(--ct-default-padding) - .125rem)}.ct-customization-button:focus-visible{border-radius:2px;box-shadow:0 0 0 3px var(--ct-primary-200)}.ct-customization-button svg{margin-left:.25rem;transition:all .25s linear}@media(prefers-reduced-motion){.ct-customization-button svg{transition:none}}.ct-customization-button svg path{stroke:var(--ct-text);stroke-width:1.4;stroke-linecap:round}.ct-active{margin-bottom:var(--ct-default-padding)}.ct-active svg{transform:rotate(-180deg)}.ct-acceptance{padding:var(--ct-default-padding)}.ct-acceptance button:not(:first-child){margin-left:var(--ct-seperator-padding)}.ct-option{border:1px solid var(--ct-primary-200);border-radius:5px;margin-bottom:var(--ct-seperator-padding);display:flex;font-size:var(--ct-text-font-size);font-family:var(--ct-secondary-font),Arial,Helvetica,sans-serif;font-weight:var(--ct-secondary-font-weight);transition:background-color .25s linear,color .25s linear,border-color .25s linear}[aria-expanded=true] .ct-option:not(.ct-essential){scroll-margin-top:2px}.ct-enabled{background-color:var(--ct-policy-enabled);border-color:var(--ct-policy-enabled)}.ct-essential{color:var(--ct-policy-enabled);background-color:var(--ct-policy-essential);border-color:var(--ct-policy-essential)}.ct-essential .ct-slider{color:var(--ct-text)}.ct-enabled:not(.ct-essential) .ct-option-info p{color:var(--ct-policy-text-enabled)}.ct-option input[type=checkbox]{position:absolute;height:1px;width:1px;overflow:hidden;clip:rect(1px,1px,1px,1px)}.ct-option-info{width:100%;padding:.75rem;display:flex;align-items:center;cursor:pointer;user-select:none}.ct-essential .ct-option-info{cursor:default}.ct-essential strong,.ct-option-info p{color:var(--ct-policy-text)}.ct-option-info p{margin:0;max-width:70%}.ct-option-info strong{display:block}input[type=checkbox]+.ct-option-info strong{margin-bottom:var(--ct-text-margin)}input[type=checkbox]:not(:disabled):focus-visible+.ct-option-info{border-radius:2px;box-shadow:0 0 0 3px var(--ct-primary-200)}.ct-slider{margin-left:auto}input[type=checkbox]:not(:disabled)+label .ct-slider{appearance:none;-webkit-appearance:none;position:relative;background:var(--ct-slider-secondary);width:1.625rem;height:.5rem;border-radius:9999px;transition:background .25s ease-in;outline:0;cursor:pointer}input[type=checkbox]:not(:disabled)+label .ct-slider:after{content:'';position:absolute;top:-.25rem;left:0;width:1rem;height:1rem;background:var(--ct-slider-primary);border-radius:2rem;transition:background .25s ease-out,left .25s ease-out}input[type=checkbox]:not(:disabled):checked+label .ct-slider{background-color:var(--ct-slider-enabled-primary)}input[type=checkbox]:not(:disabled):checked+label .ct-slider:after{background:var(--ct-slider-enabled-secondary);left:50%}@media(prefers-reduced-motion){.ct-option,input[type=checkbox]:not(:disabled)+label .ct-slider,input[type=checkbox]:not(:disabled)+label .ct-slider:after{transition:none}}.ct-declaration{width:100%;text-align:center;padding-top:var(--ct-seperator-padding);font-size:var(--ct-text-font-size)}.ct-declaration a{color:var(--ct-text);outline:0}.ct-declaration a:focus-visible{border-radius:2px;box-shadow:0 0 0 3px var(--ct-primary-200)}.ct-options-hidden{display:none}.ct-collapse{overflow:hidden;transition:height .25s ease-out;height:0;padding:0 var(--ct-default-padding);scroll-behavior:smooth;outline:none}@media(prefers-reduced-motion){.ct-collapse{transition:none;scroll-behavior:auto}}.ct-button{font-family:inherit;font-size:var(--ct-button-font-size);background:var(--ct-button);color:var(--ct-button-color);padding:var(--ct-button-padding);appearance:none;cursor:pointer;border:var(--ct-button-border);border-radius:var(--ct-button-radius);outline:0}.ct-button:focus-visible{box-shadow:0 0 0 3px var(--ct-primary-200)}.ct-button-secondary{background:var(--ct-button-secondary);color:var(--ct-button-secondary-color);border:var(--ct-button-secondary-border)}:host(.cookie-though){display:block!important;position:fixed;left:var(--ct-default-padding);width:343px;max-height:calc(100% - var(--ct-default-padding)*2);border-radius:20px;box-shadow:0 2px 19px -4px rgba(1,1,63,.1);background:var(--ct-white);transition:bottom .25s linear;box-sizing:content-box!important;z-index:var(--ct-z-index)}@media only screen and (max-width:480px){:host(.cookie-though){width:calc(100vw - var(--ct-default-padding)*2)}}@media (prefers-reduced-motion){:host(.cookie-though){transition:none}}:host(.cookie-though.visible){bottom:var(--ct-default-padding)!important}:host(.cookie-though){font-family:var(--ct-primary-font),Arial,Helvetica,sans-serif;font-weight:var(--ct-primary-font-weight);font-size:var(--ct-text-font-size)}:host{--ct-primary-400:#009;--ct-primary-300:#6161e8;--ct-primary-200:#e0e0ff;--ct-primary-100:#f0f0ff;--ct-text:#6b7280;--ct-title:var(--ct-primary-400);--ct-subtitle:var(--ct-primary-300);--ct-cookie:var(--ct-primary-400);--ct-policy:var(--ct-white);--ct-policy-enabled:var(--ct-primary-400);--ct-policy-text:var(--ct-primary-400);--ct-policy-text-enabled:var(--ct-white);--ct-policy-essential:var(--ct-primary-100);--ct-slider-primary:var(--ct-text);--ct-slider-secondary:#d1d5db;--ct-slider-enabled-primary:#4c4cff;--ct-slider-enabled-secondary:#b3b3ff;--ct-white:#fff;--ct-text-margin:0.25rem;--ct-default-padding:1rem;--ct-seperator-padding:0.5rem;--ct-heading-font-size:1.25rem;--ct-sub-heading-font-size:0.875rem;--ct-text-font-size:0.75rem;--ct-button-font-size:0.8125rem;--ct-button-radius:2px;--ct-button-border:0;--ct-button-padding:0.5rem;--ct-button:var(--ct-primary-400);--ct-button-color:var(--ct-white);--ct-button-secondary-border:0;--ct-button-secondary:var(--ct-primary-300);--ct-button-secondary-color:var(--ct-white);--ct-primary-font:Geneva,sans-serif;--ct-primary-font-weight:400;--ct-secondary-font:Geneva,sans-serif;--ct-secondary-font-weight:400;--ct-z-index:9999}",r.appendChild(e);var o=document.querySelector(".cookie-though");o&&o.shadowRoot?na(g(wa,ia(ia({},B),{ee:xa})),o.shadowRoot):(document.body.prepend(t),na(g(wa,ia(ia({},B),{ee:xa})),r))};k.configure=ya;var ja=ya;k.init=ja;var qc=function($){B||ja(ha),xa.on(ua,$)};k.onPreferencesChanged=qc;var rc=function(){var $;return B||ya(ha),va(B.policies.map(function($){return{id:$.id,isEnabled:M($.category)}}),null!==($=B.cookiePreferenceKey)&&void 0!==$?$:ta)};k.getPreferences=rc;var sc=function(){return B||ja(ha),P(!0)};k.show=sc;var tc=function(){return B||ja(ha),P(!1)};k.hide=tc;if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=k}else if(typeof define==="function"&&define.amd){define(function(){return k})}else{this["CookieThough"]=k}})();