Changeset 3305665
- Timestamp:
- 06/03/2025 11:37:18 AM (10 months ago)
- Location:
- beautiful-and-responsive-cookie-consent
- Files:
-
- 63 added
- 8 edited
-
tags/4.6.2 (added)
-
tags/4.6.2/admin (added)
-
tags/4.6.2/admin/css (added)
-
tags/4.6.2/admin/css/bootstrap.min.css (added)
-
tags/4.6.2/admin/css/nsc_bar_admin.css (added)
-
tags/4.6.2/admin/img (added)
-
tags/4.6.2/admin/img/banner1.png (added)
-
tags/4.6.2/admin/img/banner2.png (added)
-
tags/4.6.2/admin/img/banner3.png (added)
-
tags/4.6.2/admin/img/icon-96x96.png (added)
-
tags/4.6.2/admin/img/rating-stars.png (added)
-
tags/4.6.2/admin/js (added)
-
tags/4.6.2/admin/js/admin.cookie-banner.min.js (added)
-
tags/4.6.2/admin/js/bootstrap.bundle.min.js (added)
-
tags/4.6.2/admin/js/cookietypes.v2.js (added)
-
tags/4.6.2/admin/js/iframeResizer (added)
-
tags/4.6.2/admin/js/iframeResizer/LICENSE (added)
-
tags/4.6.2/admin/js/iframeResizer/iframeResizer.contentWindow.min.js (added)
-
tags/4.6.2/admin/js/iframeResizer/iframeResizer.min.js (added)
-
tags/4.6.2/admin/new-banner (added)
-
tags/4.6.2/admin/new-banner/LICENSE (added)
-
tags/4.6.2/admin/new-banner/_astro (added)
-
tags/4.6.2/admin/new-banner/_astro/index.css (added)
-
tags/4.6.2/admin/new-banner/_astro/index.js (added)
-
tags/4.6.2/admin/new-banner/favicon.svg (added)
-
tags/4.6.2/admin/new-banner/index.html (added)
-
tags/4.6.2/admin/tpl (added)
-
tags/4.6.2/admin/tpl/admin.php (added)
-
tags/4.6.2/admin/tpl/legacy.php (added)
-
tags/4.6.2/admin/tpl/premium_addon_desc.html (added)
-
tags/4.6.2/admin/tpl/premium_addon_desc_consent_apis.html (added)
-
tags/4.6.2/admin/tpl/sidebar.php (added)
-
tags/4.6.2/admin/tpl/tab_block_services_no_license.html (added)
-
tags/4.6.2/admin/tpl/tab_compliance_and_behaviour.html (added)
-
tags/4.6.2/admin/tpl/tab_jsonconfig_description.html (added)
-
tags/4.6.2/admin/tpl/tab_jsonconfig_tipps.html (added)
-
tags/4.6.2/admin/tpl/tab_revoke_description.html (added)
-
tags/4.6.2/class (added)
-
tags/4.6.2/class/class-nsc_bar_admin_error.php (added)
-
tags/4.6.2/class/class-nsc_bar_admin_settings.php (added)
-
tags/4.6.2/class/class-nsc_bar_banner_configs.php (added)
-
tags/4.6.2/class/class-nsc_bar_cookie_handler.php (added)
-
tags/4.6.2/class/class-nsc_bar_db_upgrader.php (added)
-
tags/4.6.2/class/class-nsc_bar_frontend.php (added)
-
tags/4.6.2/class/class-nsc_bar_html_formfields.php (added)
-
tags/4.6.2/class/class-nsc_bar_input_validation.php (added)
-
tags/4.6.2/class/class-nsc_bar_integrations.php (added)
-
tags/4.6.2/class/class-nsc_bar_plugin_configs.php (added)
-
tags/4.6.2/class/class-nsc_bar_rest_api.php (added)
-
tags/4.6.2/class/class-nsc_bar_return_filter.php (added)
-
tags/4.6.2/class/class-nsc_bar_save_form_fields.php (added)
-
tags/4.6.2/class/class-nsc_bar_uninstall.php (added)
-
tags/4.6.2/licence.txt (added)
-
tags/4.6.2/nsc_bar-cookie-consent.php (added)
-
tags/4.6.2/plugin-configs.json (added)
-
tags/4.6.2/public (added)
-
tags/4.6.2/public/config-default.json (added)
-
tags/4.6.2/public/cookieNSCconsent.min.css (added)
-
tags/4.6.2/public/cookieNSCconsent.min.js (added)
-
tags/4.6.2/public/license.txt (added)
-
tags/4.6.2/public/revoke_shortcode.js (added)
-
tags/4.6.2/readme.txt (added)
-
tags/4.6.2/uninstall.php (added)
-
trunk/admin/css/nsc_bar_admin.css (modified) (1 diff)
-
trunk/admin/js/iframeResizer/iframeResizer.min.js (modified) (1 diff)
-
trunk/admin/new-banner/_astro/index.js (modified) (1 diff)
-
trunk/admin/new-banner/index.html (modified) (1 diff)
-
trunk/admin/tpl/admin.php (modified) (4 diffs)
-
trunk/admin/tpl/legacy.php (modified) (1 diff)
-
trunk/nsc_bar-cookie-consent.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
beautiful-and-responsive-cookie-consent/trunk/admin/css/nsc_bar_admin.css
r3261487 r3305665 22 22 box-shadow: 0 1px 1px rgb(0 0 0 / 4%); 23 23 border-left: 4px solid #dba617; 24 } 25 26 .nsc_bar_notice_error { 27 background: #fff; 28 border: 1px solid #c3c4c7; 29 border-left-width: 4px; 30 box-shadow: 0 1px 1px rgb(0 0 0 / 4%); 31 border-left: 4px solid #ee2314; 24 32 } 25 33 -
beautiful-and-responsive-cookie-consent/trunk/admin/js/iframeResizer/iframeResizer.min.js
r3057846 r3305665 738 738 } 739 739 })(); 740 //# sourceMappingURL=iframeResizer.map741 742 iFrameResize({ log: false, minHeight: 500 }, '#nsc_bara_admin_app_block_services'); -
beautiful-and-responsive-cookie-consent/trunk/admin/new-banner/_astro/index.js
r3130577 r3305665 1 const An="opt-in", Ue="opt-out",Rt="show--consent",$t="show--preferences",_t="disable--interaction",ct="data-category",T="div",se="button",ae="aria-hidden",Ge="btn-group",q="click",Pe="data-role",Nt="consentModal",Pt="preferencesModal";class Dn{constructor(){this.t={mode:An,revision:0,autoShow:!0,lazyHtmlGeneration:!0,autoClearCookies:!0,manageScriptTags:!0,hideFromBots:!0,cookie:{name:"cc_cookie",expiresAfterDays:182,domain:"",path:"/",sameSite:"Lax"}},this.o={i:{},l:"",_:{},u:{},p:{},m:[],v:!1,h:null,C:null,S:null,M:"",D:!0,T:!1,k:!1,A:!1,N:!1,H:[],V:!1,I:!0,L:[],j:!1,F:"",P:!1,O:[],R:[],B:[],G:[],J:!1,U:!1,$:!1,q:[],K:[],W:[],X:{},Y:{},Z:{},ee:{},te:{},ne:[]},this.oe={se:{},ae:{}},this.ce={},this.re={ie:"cc:onFirstConsent",le:"cc:onConsent",de:"cc:onChange",fe:"cc:onModalShow",_e:"cc:onModalHide",ue:"cc:onModalReady"}}}const c=new Dn,xn=(e,t)=>e.indexOf(t),A=(e,t)=>-1!==xn(e,t),He=e=>Array.isArray(e),he=e=>"string"==typeof e,rt=e=>!!e&&"object"==typeof e&&!He(e),pe=e=>"function"==typeof e,ce=e=>Object.keys(e),Ft=e=>Array.from(new Set(e)),lt=()=>document.activeElement,$e=e=>e.preventDefault(),Ht=(e,t)=>e.querySelectorAll(t),nt=e=>e.dispatchEvent(new Event("change")),m=e=>{const t=document.createElement(e);return e===se&&(t.type=e),t},y=(e,t,n)=>e.setAttribute(t,n),yt=(e,t,n)=>{e.removeAttribute(n?"data-"+t:t)},ot=(e,t,n)=>e.getAttribute(n?"data-"+t:t),h=(e,t)=>e.appendChild(t),B=(e,t)=>e.classList.add(t),W=(e,t)=>B(e,"cm__"+t),S=(e,t)=>B(e,"pm__"+t),ke=(e,t)=>e.classList.remove(t),ge=e=>{if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let n in e){let o=e[n];t[n]=ge(o)}return t},Do=()=>{const e={},{O:t,X:n,Y:o}=c.o;for(const s of t)e[s]=st(o[s],ce(n[s]));return e},dn=(e,t)=>dispatchEvent(new CustomEvent(e,{detail:t})),R=(e,t,n,o)=>{e.addEventListener(t,n),o&&c.o.m.push({pe:e,me:t,ge:n})},fn=()=>{const e=c.t.cookie.expiresAfterDays;return pe(e)?e(c.o.F):e},st=(e,t)=>{const n=e||[],o=t||[];return n.filter((e=>!A(o,e))).concat(o.filter((e=>!A(n,e))))},Bn=e=>{c.o.R=Ft(e),c.o.F=(()=>{let e="custom";const{R:t,O:n,B:o}=c.o,s=t.length;return s===n.length?e="all":s===o.length&&(e="necessary"),e})()},Mn=(e,t,n,o)=>{const s="accept-",{show:a,showPreferences:i,hide:r,hidePreferences:l,acceptCategory:d}=t,u=e||document,h=e=>Ht(u,`[data-cc="${e}"]`),f=(e,t)=>{$e(e),d(t),l(),r()},m=h("show-preferencesModal"),p=h("show-consentModal"),g=h(s+"all"),b=h(s+"necessary"),v=h(s+"custom"),C=c.t.lazyHtmlGeneration;for(const e of m)y(e,"aria-haspopup","dialog"),R(e,q,(e=>{$e(e),i()})),C&&(R(e,"mouseenter",(e=>{$e(e),c.o.N||n(t,o)}),!0),R(e,"focus",(()=>{c.o.N||n(t,o)})));for(let e of p)y(e,"aria-haspopup","dialog"),R(e,q,(e=>{$e(e),a(!0)}),!0);for(let e of g)R(e,q,(e=>{f(e,"all")}),!0);for(let e of v)R(e,q,(e=>{f(e)}),!0);for(let e of b)R(e,q,(e=>{f(e,[])}),!0)},re=(e,t)=>{e&&(t&&(e.tabIndex=-1),e.focus(),t&&e.removeAttribute("tabindex"))},On=(e,t)=>{const n=o=>{o.target.removeEventListener("transitionend",n),"opacity"===o.propertyName&&"1"===getComputedStyle(e).opacity&&re(1===t?c.oe.be:c.oe.ve)};R(e,"transitionend",n)};let pn;const In=e=>{clearTimeout(pn),e?B(c.oe.ye,_t):pn=setTimeout((()=>{ke(c.oe.ye,_t)}),500)},xo=["M 19.5 4.5 L 4.5 19.5 M 4.5 4.501 L 19.5 19.5","M 3.572 13.406 L 8.281 18.115 L 20.428 5.885","M 21.999 6.94 L 11.639 17.18 L 2.001 6.82 "],Je=(e=0,t=1.5)=>`<svg viewBox="0 0 24 24" stroke-width="${t}"><path d="${xo[e]}"/></svg>`,Rn=e=>{const t=c.oe,n=c.o;(e=>{const o=e===t.he,s=n.i.disablePageInteraction?t.ye:o?t.Ce:t.ye;R(s,"keydown",(t=>{if("Tab"!==t.key||!(o?n.k&&!n.A:n.A))return;const s=lt(),c=o?n.q:n.K;0!==c.length&&(t.shiftKey?s!==c[0]&&e.contains(s)||($e(t),re(c[1])):s!==c[1]&&e.contains(s)||($e(t),re(c[0])))}),!0)})(e)},Bo=["[href]",se,"input","details","[tabindex]"].map((e=>e+':not([tabindex="-1"])')).join(","),$n=e=>{const{o:t,oe:n}=c,o=(e,t)=>{const n=Ht(e,Bo);t[0]=n[0],t[1]=n[n.length-1]};1===e&&t.T&&o(n.he,t.q),2===e&&t.N&&o(n.we,t.K)},le=(e,t,n)=>{const{de:o,le:s,ie:a,_e:i,ue:r,fe:l}=c.ce,d=c.re;if(t){const o={modalName:t};return e===d.fe?pe(l)&&l(o):e===d._e?pe(i)&&i(o):(o.modal=n,pe(r)&&r(o)),dn(e,o)}const u={cookie:c.o.p};e===d.ie?pe(a)&&a(ge(u)):e===d.le?pe(s)&&s(ge(u)):(u.changedCategories=c.o.L,u.changedServices=c.o.ee,pe(o)&&o(ge(u))),dn(e,ge(u))},Xe=(e,t)=>{try{return e()}catch(e){return!t&&console.warn("CookieConsent:",e),!1}},Et=e=>{const{Y:t,ee:n,O:o,X:s,ne:a,p:i,L:r}=c.o;for(const e of o){const o=n[e]||t[e]||[];for(const n of o){const o=s[e][n];if(!o)continue;const{onAccept:c,onReject:a}=o;!o.Se&&A(t[e],n)&&pe(c)?(o.Se=!0,c()):o.Se&&!A(t[e],n)&&pe(a)&&(o.Se=!1,a())}}if(!c.t.manageScriptTags)return;const l=a,d=e||i.categories||[],u=(e,o)=>{if(o>=e.length)return;const s=a[o];if(s.xe)return u(e,o+1);const c=s.Me,i=s.De,l=s.Te,h=A(d,i),f=!!l&&A(t[i],l);if(!l&&!s.ke&&h||!l&&s.ke&&!h&&A(r,i)||l&&!s.ke&&f||l&&s.ke&&!f&&A(n[i]||[],l)){s.xe=!0;const t=ot(c,"type",!0);yt(c,"type",!!t),yt(c,ct);let n=ot(c,"src",!0);n&&yt(c,"src",!0);const a=m("script");a.textContent=c.innerHTML;for(const{nodeName:e}of c.attributes)y(a,e,c[e]||ot(c,e));t&&(a.type=t),n?a.src=n:n=c.src;const i=!!n&&(!t||["text/javascript","module"].includes(t));if(i&&(a.onload=a.onerror=()=>{u(e,++o)}),c.replaceWith(a),i)return}u(e,++o)};u(l,0)},at="bottom",St="left",Nn="center",jt="right",vt="inline",Pn="wide",Fn="pm--",kt=["middle","top",at],gn=[St,Nn,jt],Mo={box:{Ae:[Pn,vt],Ee:kt,Ne:gn,He:at,Ve:jt},cloud:{Ae:[vt],Ee:kt,Ne:gn,He:at,Ve:Nn},bar:{Ae:[vt],Ee:kt.slice(1),Ne:[],He:at,Ve:""}},Oo={box:{Ae:[],Ee:[],Ne:[],He:"",Ve:""},bar:{Ae:[Pn],Ee:[],Ne:[St,jt],He:"",Ve:St}},Hn=e=>{const t=c.o.i.guiOptions,n=t&&t.consentModal,o=t&&t.preferencesModal;0===e&&hn(c.oe.he,Mo,n,"cm--","box","cm"),1===e&&hn(c.oe.we,Oo,o,Fn,"box","pm")},hn=(e,t,n,o,s,a)=>{e.className=a;const i=n&&n.layout,r=n&&n.position,l=n&&n.flipButtons,d=!n||!1!==n.equalWeightButtons,u=i&&i.split(" ")||[],h=u[0],f=u[1],m=h in t?h:s,p=t[m],g=A(p.Ae,f)&&f,b=r&&r.split(" ")||[],y=b[0],v=o===Fn?b[0]:b[1],C=A(p.Ee,y)?y:p.He,w=A(p.Ne,v)?v:p.Ve,k=t=>{t&&B(e,o+t)};k(m),k(g),k(C),k(w),l&&k("flip");const _=a+"__btn--secondary";if("cm"===a){const{Ie:e,Le:t}=c.oe;e&&(d?ke(e,_):B(e,_)),t&&(d?ke(t,_):B(t,_))}else{const{je:e}=c.oe;e&&(d?ke(e,_):B(e,_))}},Fe=(e,t)=>{const n=c.o,o=c.oe,{hide:s,hidePreferences:a,acceptCategory:i}=e,r=e=>{i(e),a(),s()},l=n.u&&n.u.preferencesModal;if(!l)return;const d=l.title,u=l.closeIconLabel,f=l.acceptAllBtn,p=l.acceptNecessaryBtn,g=l.savePreferencesBtn,b=l.sections||[],v=f||p||g;if(o.Fe)o.Pe=m(T),S(o.Pe,"body");else{o.Fe=m(T),B(o.Fe,"pm-wrapper");const e=m("div");B(e,"pm-overlay"),h(o.Fe,e),R(e,q,a),o.we=m(T),B(o.we,"pm"),y(o.we,"role","dialog"),y(o.we,ae,!0),y(o.we,"aria-modal",!0),y(o.we,"aria-labelledby","pm__title"),R(o.ye,"keydown",(e=>{27===e.keyCode&&a()}),!0),o.Oe=m(T),S(o.Oe,"header"),o.Re=m("h2"),S(o.Re,"title"),o.Re.id="pm__title",o.Be=m(se),S(o.Be,"close-btn"),y(o.Be,"aria-label",l.closeIconLabel||""),R(o.Be,q,a),o.Ge=m("span"),o.Ge.innerHTML=Je(),h(o.Be,o.Ge),o.Je=m(T),S(o.Je,"body"),o.Ue=m(T),S(o.Ue,"footer");var C=m(T);B(C,"btns");var w=m(T),k=m(T);S(w,Ge),S(k,Ge),h(o.Ue,w),h(o.Ue,k),h(o.Oe,o.Re),h(o.Oe,o.Be),o.ve=m(T),y(o.ve,"tabIndex",-1),h(o.we,o.ve),h(o.we,o.Oe),h(o.we,o.Je),v&&h(o.we,o.Ue),h(o.Fe,o.we)}let _;d&&(o.Re.innerHTML=d,u&&y(o.Be,"aria-label",u)),b.forEach(((e,t)=>{const s=e.title,c=e.description,a=e.linkedCategory,i=a&&n.P[a],r=e.cookieTable,d=r&&r.body,u=r&&r.caption,f=d&&d.length>0,p=!!i,g=p&&n.X[a],b=rt(g)&&ce(g)||[],v=p&&(!!c||!!f||ce(g).length>0);var C=m(T);if(S(C,"section"),v||c){var w=m(T);S(w,"section-desc-wrapper")}let k=b.length;if(v&&k>0){const e=m(T);S(e,"section-services");for(const t of b){const n=g[t],o=n&&n.label||t,s=m(T),c=m(T),r=m(T),l=m(T);S(s,"service"),S(l,"service-title"),S(c,"service-header"),S(r,"service-icon");const d=mn(o,t,i,!0,a);l.innerHTML=o,h(c,r),h(c,l),h(s,c),h(s,d),h(e,s)}h(w,e)}if(s){var A=m(T),x=m(p?se:T);if(S(A,"section-title-wrapper"),S(x,"section-title"),x.innerHTML=s,h(A,x),p){const e=m("span");e.innerHTML=Je(2,3.5),S(e,"section-arrow"),h(A,e),C.className+="--toggle";const t=mn(s,a,i);let n=l.serviceCounterLabel;if(k>0&&he(n)){let e=m("span");S(e,"badge"),S(e,"service-counter"),y(e,ae,!0),y(e,"data-servicecounter",k),n&&(n=n.split("|"),n=n.length>1&&k>1?n[1]:n[0],y(e,"data-counterlabel",n)),e.innerHTML=k+(n?" "+n:""),h(x,e)}if(v){S(C,"section--expandable");var E=a+"-desc";y(x,"aria-expanded",!1),y(x,"aria-controls",E)}h(A,t)}else y(x,"role","heading"),y(x,"aria-level","3");h(C,A)}if(c){var D=m("p");S(D,"section-desc"),D.innerHTML=c,h(w,D)}if(v&&(y(w,ae,"true"),w.id=E,N=w,L=C,I=x,R(x,q,(()=>{L.classList.contains("is-expanded")?(ke(L,"is-expanded"),y(I,"aria-expanded","false"),y(N,ae,"true")):(B(L,"is-expanded"),y(I,"aria-expanded","true"),y(N,ae,"false"))})),f)){const e=m("table"),n=m("thead"),s=m("tbody");if(u){const t=m("caption");S(t,"table-caption"),t.innerHTML=u,e.appendChild(t)}S(e,"section-table"),S(n,"table-head"),S(s,"table-body");const c=r.headers,a=ce(c),i=o.$e.createDocumentFragment(),l=m("tr");for(const e of a){const n=c[e],o=m("th");o.id="cc__row-"+n+t,y(o,"scope","col"),S(o,"table-th"),o.innerHTML=n,h(i,o)}h(l,i),h(n,l);const f=o.$e.createDocumentFragment();for(const e of d){const n=m("tr");S(n,"table-tr");for(const o of a){const s=c[o],a=e[o],i=m("td"),r=m(T);S(i,"table-td"),y(i,"data-column",s),y(i,"headers","cc__row-"+s+t),r.insertAdjacentHTML("beforeend",a),h(i,r),h(n,i)}h(f,n)}h(s,f),h(e,n),h(e,s),h(w,e)}var N,L,I;(v||c)&&h(C,w);const $=o.Pe||o.Je;p?(_||(_=m(T),S(_,"section-toggles")),_.appendChild(C)):_=null,h($,_||C)})),f&&(o.ze||(o.ze=m(se),S(o.ze,"btn"),y(o.ze,Pe,"all"),h(w,o.ze),R(o.ze,q,(()=>r("all")))),o.ze.innerHTML=f),p&&(o.je||(o.je=m(se),S(o.je,"btn"),y(o.je,Pe,"necessary"),h(w,o.je),R(o.je,q,(()=>r([])))),o.je.innerHTML=p),g&&(o.qe||(o.qe=m(se),S(o.qe,"btn"),S(o.qe,"btn--secondary"),y(o.qe,Pe,"save"),h(k,o.qe),R(o.qe,q,(()=>r()))),o.qe.innerHTML=g),o.Pe&&(o.we.replaceChild(o.Pe,o.Je),o.Je=o.Pe),Hn(1),n.N||(n.N=!0,le(c.re.ue,Pt,o.we),t(e),h(o.Ce,o.Fe),Rn(o.we),setTimeout((()=>B(o.Fe,"cc--anim")),100)),$n(2)};function mn(e,t,n,o,s){const a=c.o,i=c.oe,r=m("label"),l=m("input"),d=m("span"),u=m("span"),f=m("span"),p=m("span"),g=m("span");if(p.innerHTML=Je(1,3),g.innerHTML=Je(0,3),l.type="checkbox",B(r,"section__toggle-wrapper"),B(l,"section__toggle"),B(p,"toggle__icon-on"),B(g,"toggle__icon-off"),B(d,"toggle__icon"),B(u,"toggle__icon-circle"),B(f,"toggle__label"),y(d,ae,"true"),o?(B(r,"toggle-service"),y(l,ct,s),i.ae[s][t]=l):i.se[t]=l,o?(b=s,R(l,"change",(()=>{const e=i.ae[b],t=i.se[b];a.Z[b]=[];for(let t in e){const n=e[t];n.checked&&a.Z[b].push(n.value)}t.checked=a.Z[b].length>0}))):(e=>{R(l,q,(()=>{const t=i.ae[e],n=l.checked;a.Z[e]=[];for(let o in t)t[o].checked=n,n&&a.Z[e].push(o)}))})(t),l.value=t,f.textContent=e.replace(/<.*>.*<\/.*>/gm,""),h(u,g),h(u,p),h(d,u),a.D)(n.readOnly||n.enabled)&&(l.checked=!0);else if(o){const e=a.Y[s];l.checked=n.readOnly||A(e,t)}else A(a.R,t)&&(l.checked=!0);var b;return n.readOnly&&(l.disabled=!0),h(r,l),h(r,d),h(r,f),r}const wt=()=>{const e=m("span");return c.oe.Ke||(c.oe.Ke=e),e},Yt=(e,t)=>{const n=c.o,o=c.oe,{hide:s,showPreferences:a,acceptCategory:i}=e,r=n.u&&n.u.consentModal;if(!r)return;const l=r.acceptAllBtn,d=r.acceptNecessaryBtn,u=r.showPreferencesBtn,f=r.closeIconLabel,p=r.footer,g=r.label,b=r.title,v=e=>{s(),i(e)};if(!o.Qe){o.Qe=m(T),o.he=m(T),o.We=m(T),o.Xe=m(T),o.Ye=m(T),B(o.Qe,"cm-wrapper"),B(o.he,"cm"),W(o.We,"body"),W(o.Xe,"texts"),W(o.Ye,"btns"),y(o.he,"role","dialog"),y(o.he,"aria-modal","true"),y(o.he,ae,"false"),y(o.he,"aria-describedby","cm__desc"),g?y(o.he,"aria-label",g):b&&y(o.he,"aria-labelledby","cm__title");const e="box",t=n.i.guiOptions,s=t&&t.consentModal,c=(s&&s.layout||e).split(" ")[0]===e;b&&f&&c&&(o.Le||(o.Le=m(se),o.Le.innerHTML=Je(),W(o.Le,"btn"),W(o.Le,"btn--close"),R(o.Le,q,(()=>{v([])})),h(o.We,o.Le)),y(o.Le,"aria-label",f)),h(o.We,o.Xe),(l||d||u)&&h(o.We,o.Ye),o.be=m(T),y(o.be,"tabIndex",-1),h(o.he,o.be),h(o.he,o.We),h(o.Qe,o.he)}b&&(o.Ze||(o.Ze=m("h2"),o.Ze.className=o.Ze.id="cm__title",h(o.Xe,o.Ze)),o.Ze.innerHTML=b);let C=r.description;if(C&&(n.V&&(C=C.replace("{{revisionMessage}}",n.I?"":r.revisionMessage||"")),o.et||(o.et=m("p"),o.et.className=o.et.id="cm__desc",h(o.Xe,o.et)),o.et.innerHTML=C),l&&(o.tt||(o.tt=m(se),h(o.tt,wt()),W(o.tt,"btn"),y(o.tt,Pe,"all"),R(o.tt,q,(()=>{v("all")}))),o.tt.firstElementChild.innerHTML=l),d&&(o.Ie||(o.Ie=m(se),h(o.Ie,wt()),W(o.Ie,"btn"),y(o.Ie,Pe,"necessary"),R(o.Ie,q,(()=>{v([])}))),o.Ie.firstElementChild.innerHTML=d),u&&(o.nt||(o.nt=m(se),h(o.nt,wt()),W(o.nt,"btn"),W(o.nt,"btn--secondary"),y(o.nt,Pe,"show"),R(o.nt,"mouseenter",(()=>{n.N||Fe(e,t)})),R(o.nt,q,a)),o.nt.firstElementChild.innerHTML=u),o.ot||(o.ot=m(T),W(o.ot,Ge),l&&h(o.ot,o.tt),d&&h(o.ot,o.Ie),(l||d)&&h(o.We,o.ot),h(o.Ye,o.ot)),o.nt&&!o.st&&(o.st=m(T),o.Ie&&o.tt?(W(o.st,Ge),h(o.st,o.nt),h(o.Ye,o.st)):(h(o.ot,o.nt),W(o.ot,Ge+"--uneven"))),p){if(!o.ct){let e=m(T),t=m(T);o.ct=m(T),W(e,"footer"),W(t,"links"),W(o.ct,"link-group"),h(t,o.ct),h(e,t),h(o.he,e)}o.ct.innerHTML=p}Hn(0),n.T||(n.T=!0,le(c.re.ue,Nt,o.he),t(e),h(o.Ce,o.Qe),Rn(o.he),setTimeout((()=>B(o.Qe,"cc--anim")),100)),$n(1),Mn(o.We,e,Fe,t)},qt=e=>{if(!he(e))return null;if(e in c.o._)return e;let t=e.slice(0,2);return t in c.o._?t:null},Ut=()=>c.o.l||c.o.i.language.default,Gt=e=>{e&&(c.o.l=e)},jn=async e=>{const t=c.o;let n=qt(e)?e:Ut(),o=t._[n];if(!o)return!1;if(he(o)){const e=await(async e=>{try{return await(await fetch(e)).json()}catch(e){return console.error(e),!1}})(o);if(!e)return!1;o=e}return t.u=o,Gt(n),!0},Yn=()=>{let e=c.o.i.language.rtl,t=c.oe.Ce;e&&t&&(He(e)||(e=[e]),A(e,c.o.l)?B(t,"cc--rtl"):ke(t,"cc--rtl"))},Ae=()=>{const e=c.oe;if(e.Ce)return;e.Ce=m(T),e.Ce.id="cc-main",e.Ce.setAttribute("data-nosnippet",""),Yn();let t=c.o.i.root;t&&he(t)&&(t=document.querySelector(t)),(t||e.$e.body).appendChild(e.Ce)},qn=e=>Xe((()=>localStorage.removeItem(e))),bn=(e,t)=>{if(t instanceof RegExp)return e.filter((e=>t.test(e)));{const n=xn(e,t);return n>-1?[e[n]]:[]}},Un=e=>{const{hostname:t,protocol:n}=location,{name:o,path:s,domain:a,sameSite:i,useLocalStorage:r}=c.t.cookie,l=e?(()=>{const e=c.o.S,t=e?new Date-e:0;return 864e5*fn()-t})():864e5*fn(),d=new Date;d.setTime(d.getTime()+l),c.o.p.expirationTime=d.getTime();const u=JSON.stringify(c.o.p);let h=o+"="+encodeURIComponent(u)+(0!==l?"; expires="+d.toUTCString():"")+"; Path="+s+"; SameSite="+i;var f,m;A(t,".")&&(h+="; Domain="+a),"https:"===n&&(h+="; Secure"),r?(f=o,m=u,Xe((()=>localStorage.setItem(f,m)))):document.cookie=h,c.o.p},Lt=(e,t,n)=>{if(0===e.length)return;const o=n||c.t.cookie.domain,s=t||c.t.cookie.path,a="www."===o.slice(0,4),i=a&&o.substring(4),r=(e,t)=>{document.cookie=e+"=; path="+s+(t?"; domain=."+t:"")+"; expires=Thu, 01 Jan 1970 00:00:01 GMT;"};for(const t of e)r(t),r(t,o),a&&r(t,i)},Gn=e=>{const t=e||c.t.cookie.name,n=c.t.cookie.useLocalStorage;return((e,t)=>{let n;return n=Xe((()=>JSON.parse(t?e:decodeURIComponent(e))),!0)||{},n})(n?(o=t,Xe((()=>localStorage.getItem(o)))||""):Wt(t,!0),n);var o},Wt=(e,t)=>{const n=document.cookie.match("(^|;)\\s*"+e+"\\s*=\\s*([^;]+)");return n?t?n.pop():e:""},Wn=e=>{const t=document.cookie.split(/;\s*/),n=[];for(const o of t){let t=o.split("=")[0];e?Xe((()=>{e.test(t)&&n.push(t)})):n.push(t)}return n},Vt=(e,t=[])=>{((e,t)=>{const{O:n,R:o,B:s,N:a,Z:i,X:r}=c.o;let l=[];if(e){He(e)?l.push(...e):he(e)&&(l="all"===e?n:[e]);for(const e of n)i[e]=A(l,e)?ce(r[e]):[]}else l=o,a&&(l=(()=>{const e=c.oe.se;if(!e)return[];let t=[];for(let n in e)e[n].checked&&t.push(n);return t})());l=l.filter((e=>!A(n,e)||!A(t,e))),l.push(...s),Bn(l)})(e,t),(e=>{const t=c.o,{Z:n,B:o,Y:s,X:a,O:i}=t,r=i;t.te=ge(s);for(const e of r){const t=a[e],c=ce(t),i=n[e]&&n[e].length>0,r=A(o,e);if(0!==c.length){if(s[e]=[],r)s[e].push(...c);else if(i){const t=n[e];s[e].push(...t)}else s[e]=[];s[e]=Ft(s[e])}}})(),(()=>{const e=c.o;e.L=c.t.mode===Ue&&e.D?st(e.G,e.R):st(e.R,e.p.categories);let t=e.L.length>0,n=!1;for(const t of e.O)e.ee[t]=st(e.Y[t],e.te[t]),e.ee[t].length>0&&(n=!0);const o=c.oe.se;for(const t in o)o[t].checked=A(e.R,t);for(const t of e.O){const n=c.oe.ae[t],o=e.Y[t];for(const e in n)n[e].checked=A(o,e)}e.C||(e.C=new Date),e.M||(e.M="10000000-1000-4000-8000-100000000000".replace(/[018]/g,(e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16)))),e.p={categories:ge(e.R),revision:c.t.revision,data:e.h,consentTimestamp:e.C.toISOString(),consentId:e.M,services:ge(e.Y)};let s=!1;const a=t||n;(e.D||a)&&(e.D&&(e.D=!1,s=!0),e.S=e.S?new Date:e.C,e.p.lastConsentTimestamp=e.S.toISOString(),Un(),c.t.autoClearCookies&&(s||a)&&(e=>{const t=c.o,n=Wn(),o=(e=>{const t=c.o;return(e?t.O:t.L).filter((e=>{const n=t.P[e];return!!n&&!n.readOnly&&!!n.autoClear}))})(e);for(const e in t.ee)for(const o of t.ee[e]){const s=t.X[e][o].cookies;if(!A(t.Y[e],o)&&s)for(const e of s){const t=bn(n,e.name);Lt(t,e.path,e.domain)}}for(const s of o){const o=t.P[s].autoClear,c=o&&o.cookies||[],a=A(t.L,s),i=!A(t.R,s),r=a&&i;if(e?i:r){o.reloadPage&&r&&(t.j=!0);for(const e of c){const t=bn(n,e.name);Lt(t,e.path,e.domain)}}}})(s),Et()),s&&(le(c.re.ie),le(c.re.le),c.t.mode===An)||(a&&le(c.re.de),e.j&&(e.j=!1,location.reload()))})()},Vn=e=>{const t=c.o.D?[]:c.o.R;return A(t,e)},Io=(e,t)=>{const{O:n,X:o}=c.o;if(!(e&&t&&he(t)&&A(n,t)&&0!==ce(o[t]).length))return!1;((e,t)=>{const n=c.o,{X:o,Z:s,N:a}=n,i=c.oe.ae[t]||{},r=c.oe.se[t]||{},l=ce(o[t]);if(s[t]=[],he(e)){if("all"===e){if(s[t].push(...l),a)for(let e in i)i[e].checked=!0,nt(i[e])}else if(A(l,e)&&s[t].push(e),a)for(let t in i)i[t].checked=e===t,nt(i[t])}else if(He(e))for(let n of l){const o=A(e,n);o&&s[t].push(n),a&&(i[n].checked=o,nt(i[n]))}const d=0===s[t].length;n.R=d?n.R.filter((e=>e!==t)):Ft([...n.R,t]),a&&(r.checked=!d,nt(r))})(e,t),Vt()},Jn=(e,t)=>{const n=c.o.D?[]:c.o.Y[t];return A(n,e)},Ro=e=>""!==Wt(e,!0),Xn=(e,t,n)=>{let o=[];const s=e=>{if(he(e)){let t=Wt(e);""!==t&&o.push(t)}else o.push(...Wn(e))};if(He(e))for(let t of e)s(t);else s(e);Lt(o,t,n)},Jt=e=>{const{oe:t,o:n}=c;if(!n.k){if(!n.T){if(!e)return;Yt(Ke,Ae)}n.k=!0,n.U=lt(),n.v&&In(!0),On(t.he,1),B(t.ye,Rt),y(t.he,ae,"false"),setTimeout((()=>{re(c.oe.be)}),100),le(c.re.fe,Nt)}},Kn=()=>{const{oe:e,o:t,re:n}=c;t.k&&(t.k=!1,t.v&&In(),re(e.Ke,!0),ke(e.ye,Rt),y(e.he,ae,"true"),re(t.U),t.U=null,le(n._e,Nt))},Zn=()=>{const e=c.o;e.A||(e.N||Fe(Ke,Ae),e.A=!0,e.k?e.$=lt():e.U=lt(),On(c.oe.we,2),B(c.oe.ye,$t),y(c.oe.we,ae,"false"),setTimeout((()=>{re(c.oe.ve)}),100),le(c.re.fe,Pt))},zn=()=>{const e=c.o;e.A&&(e.A=!1,(()=>{const e=Xt(),t=c.o.P,n=c.oe.se,o=c.oe.ae,s=e=>A(c.o.G,e);for(const c in n){const a=!!t[c].readOnly;n[c].checked=a||(e?Vn(c):s(c));for(const t in o[c])o[c][t].checked=a||(e?Jn(t,c):s(c))}})(),re(c.oe.Ge,!0),ke(c.oe.ye,$t),y(c.oe.we,ae,"true"),e.k?(re(e.$),e.$=null):(re(e.U),e.U=null),le(c.re._e,Pt))};var Ke={show:Jt,hide:Kn,showPreferences:Zn,hidePreferences:zn,acceptCategory:Vt};const $o=async(e,t)=>{if(!qt(e))return!1;const n=c.o;return!(e===Ut()&&!0!==t||!await jn(e)||(Gt(e),n.T&&Yt(Ke,Ae),n.N&&Fe(Ke,Ae),Yn(),0))},No=()=>{const{F:e,Y:t}=c.o,{accepted:n,rejected:o}=(()=>{const{D:e,R:t,O:n}=c.o;return{accepted:t,rejected:e?[]:n.filter((e=>!A(t,e)))}})();return ge({acceptType:e,acceptedCategories:n,rejectedCategories:o,acceptedServices:t,rejectedServices:Do()})},Po=(e,t)=>{let n=document.querySelector('script[src="'+e+'"]');return new Promise((o=>{if(n)return o(!0);if(n=m("script"),rt(t))for(const e in t)y(n,e,t[e]);n.onload=()=>o(!0),n.onerror=()=>{n.remove(),o(!1)},n.src=e,h(document.head,n)}))},Fo=e=>{let t,n=e.value,o=e.mode,s=!1;const a=c.o;if("update"===o){a.h=t=Qn("data");const e=typeof t==typeof n;if(e&&"object"==typeof t){!t&&(t={});for(let e in n)t[e]!==n[e]&&(t[e]=n[e],s=!0)}else!e&&t||t===n||(t=n,s=!0)}else t=n,s=!0;return s&&(a.h=t,a.p.data=t,Un(!0)),s},Qn=(e,t)=>{const n=Gn(t);return e?n[e]:n},Ho=e=>{const t=c.t,n=c.o.i;return e?t[e]||n[e]:{...t,...n,cookie:{...t.cookie}}},Xt=()=>!c.o.D,eo=async e=>{const{o:t,t:n,re:o}=c,s=window;if(!s._ccRun){if(s._ccRun=!0,(e=>{const{oe:t,t:n,o:o}=c,s=n,a=o,{cookie:i}=s,r=c.ce,l=e.cookie,d=e.categories,u=ce(d)||[],h=navigator,f=document;t.$e=f,t.ye=f.documentElement,i.domain=location.hostname,a.i=e,a.P=d,a.O=u,a._=e.language.translations,a.v=!!e.disablePageInteraction,r.ie=e.onFirstConsent,r.le=e.onConsent,r.de=e.onChange,r._e=e.onModalHide,r.fe=e.onModalShow,r.ue=e.onModalReady;const{mode:m,autoShow:p,lazyHtmlGeneration:g,autoClearCookies:b,revision:y,manageScriptTags:v,hideFromBots:C}=e;m===Ue&&(s.mode=m),"boolean"==typeof b&&(s.autoClearCookies=b),"boolean"==typeof v&&(s.manageScriptTags=v),"number"==typeof y&&y>=0&&(s.revision=y,a.V=!0),"boolean"==typeof p&&(s.autoShow=p),"boolean"==typeof g&&(s.lazyHtmlGeneration=g),!1===C&&(s.hideFromBots=!1),!0===s.hideFromBots&&h&&(a.J=h.userAgent&&/bot|crawl|spider|slurp|teoma/i.test(h.userAgent)||h.webdriver),rt(l)&&(s.cookie={...i,...l}),s.autoClearCookies,a.V,s.manageScriptTags,(e=>{const{P:t,X:n,Y:o,Z:s,B:a}=c.o;for(let i of e){const e=t[i],r=e.services||{},l=rt(r)&&ce(r)||[];n[i]={},o[i]=[],s[i]=[],e.readOnly&&(a.push(i),o[i]=l),c.oe.ae[i]={};for(let e of l){const t=r[e];t.Se=!1,n[i][e]=t}}})(u),(()=>{if(!c.t.manageScriptTags)return;const e=c.o,t=Ht(document,"script["+ct+"]");for(const n of t){let t=ot(n,ct),o=n.dataset.service||"",s=!1;if(t&&"!"===t.charAt(0)&&(t=t.slice(1),s=!0),"!"===o.charAt(0)&&(o=o.slice(1),s=!0),A(e.O,t)&&(e.ne.push({Me:n,xe:!1,ke:s,De:t,Te:o}),o)){const n=e.X[t];n[o]||(n[o]={Se:!1})}}})(),Gt((()=>{const e=c.o.i.language.autoDetect;if(e){const t={browser:navigator.language,document:document.documentElement.lang},n=qt(t[e]);if(n)return n}return Ut()})())})(e),t.J)return;(()=>{const e=c.o,t=c.t,n=Gn(),{categories:o,services:s,consentId:a,consentTimestamp:i,lastConsentTimestamp:r,data:l,revision:d}=n,u=He(o);e.p=n,e.M=a;const h=!!a&&he(a);e.C=i,e.C&&(e.C=new Date(i)),e.S=r,e.S&&(e.S=new Date(r)),e.h=void 0!==l?l:null,e.V&&h&&d!==t.revision&&(e.I=!1),e.D=!(h&&e.I&&e.C&&e.S&&u),t.cookie.useLocalStorage&&!e.D&&(e.D=(new Date).getTime()>(n.expirationTime||0),e.D&&qn(t.cookie.name)),e.D,(()=>{const e=c.o;for(const t of e.O){const n=e.P[t];if(n.readOnly||n.enabled&&e.i.mode===Ue){e.G.push(t);const n=e.X[t]||{};for(let o in n)e.Y[t].push(o)}}})(),e.D?t.mode===Ue&&(e.R=[...e.G]):(e.Y={...e.Y,...s},Bn([...e.B,...o])),e.Z={...e.Y}})();const i=Xt();if(!await jn())return!1;if(Mn(null,a=Ke,Fe,Ae),c.o.D&&Yt(a,Ae),c.t.lazyHtmlGeneration||Fe(a,Ae),n.autoShow&&!i&&Jt(!0),i)return Et(),le(o.le);n.mode===Ue&&Et(t.G)}var a},jo=e=>{const{Ce:t,ye:n}=c.oe,{name:o,path:s,domain:a,useLocalStorage:i}=c.t.cookie;e&&(i?qn(o):Xn(o,s,a));for(const{pe:e,me:t,ge:n}of c.o.m)e.removeEventListener(t,n);t&&t.remove(),n&&n.classList.remove(_t,$t,Rt);const r=new Dn;for(const e in c)c[e]=r[e];window._ccRun=!1},Yo=Object.freeze(Object.defineProperty({__proto__:null,acceptCategory:Vt,acceptService:Io,acceptedCategory:Vn,acceptedService:Jn,eraseCookies:Xn,getConfig:Ho,getCookie:Qn,getUserPreferences:No,hide:Kn,hidePreferences:zn,loadScript:Po,reset:jo,run:eo,setCookieData:Fo,setLanguage:$o,show:Jt,showPreferences:Zn,validConsent:Xt,validCookie:Ro},Symbol.toStringTag,{value:"Module"})),qo={root:"main",guiOptions:{consentModal:{layout:"box",position:"top right",equalWeightButtons:!0,flipButtons:!1},preferencesModal:{layout:"box",position:"right",equalWeightButtons:!0,flipButtons:!1}},categories:{necessary:{readOnly:!0},functionality:{},analytics:{},marketing:{}},language:{default:"en",autoDetect:"browser",rtl:"ar",translations:{}}},De=to(qo);function to(e){if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let n in e){let o=e[n];t[n]=to(o)}return t}const Kt=e=>{if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let n in e){let o=e[n];t[n]=Kt(o)}return t},N={_PLAYGROUND_READY:"pg:ready",_INIT:"cc:onInit",_RESET:"cc:reset",_ON_CONSENT:"cc:onConsent",_ON_CHANGE:"cc:onChange",_ON_MODAL_SHOW:"cc:onModalShow"},Zt=e=>{window.dispatchEvent(new CustomEvent(e))},G=(e,t)=>{window.addEventListener(e,t)},I=(e,t,n)=>{e.addEventListener(t,n)},v=e=>document.getElementById(e),mt="nscBaraCookieBannerState",V={_cookieConsentConfig:De,_currLanguage:De.language.default,_enabledTranslations:["en"],_enabledCategories:["necessary","analytics"],_disableTransitions:!1,_theme:"default-light",_lastNonBarPosition:"",_lastBarPosition:"",_demoRevision:34},x=()=>{const e=localStorage.getItem(mt);if(e)try{return JSON.parse(e)}catch{}return Kt(V)},Uo=()=>{const e=window.CookieConsent;e.validConsent()&&e.acceptCategory([]),e.eraseCookies(e.getConfig("cookie").name)},We=()=>{Uo(),localStorage.removeItem(mt),window.CookieConsent.reset(!0),window.CookieConsent.run(De),Zt(N._RESET)},ie=e=>{try{e&&localStorage.setItem(mt,JSON.stringify(e))}catch(e){console.error("Failed to save state:",e)}};function Go(){let e=localStorage.getItem(mt);if(e)try{e=JSON.parse(e);for(let t in V)if(typeof e[t]!=typeof V[t])return console.warn(`Beautiful Cookie Banner - RESETTING banner state because of key: ${t}: typeof savedState[key] !== typeof defaultState[key]. ${typeof e[t]} vs. ${typeof V[t]}`),We();if(e._demoRevision!==V._demoRevision)return console.warn(`Beautiful Cookie Banner - RESETTING banner state because of: savedState._demoRevision !== defaultState._demoRevision. ${e._demoRevision} vs. ${V._demoRevision}`),We()}catch(e){return console.warn(`Beautiful Cookie Banner - RESETTING banner state because of error : ${e.message}`),We()}}const zt=e=>{const t=Kt(e._cookieConsentConfig),n=t.language.translations;delete t.root,delete t.cookie,t.disablePageInteraction||delete t.disablePageInteraction;for(const t in n)if(e._enabledTranslations.includes(t)){const o=n[t];delete o.consentModal.label;const s=o.preferencesModal,c=s.sections.filter((t=>(delete t.cookieTable,!t.linkedCategory||e._enabledCategories.includes(t.linkedCategory))));s.sections=c}else delete n[t];"ar"in n||delete t.language.rtl;for(const n in t.categories)e._enabledCategories.includes(n)||delete t.categories[n];return t},xe=(e,t)=>{const n=window.CookieConsent;n.reset();const o=zt(e);n.run(o).then((()=>{1===t&&n.show(!0),2===t&&n.showPreferences()}))};function Wo(e,t){const n=document.getElementById(e);t.forEach((e=>{const t=document.createElement("option");t.value=e,t.textContent=e,n.appendChild(t)}))}function Vo(e){const t=document.getElementById(e),n=x()._cookieConsentConfig.language;Object.keys(n.translations).forEach((e=>{const n=document.createElement("label"),o=document.createElement("input"),s=document.createElement("span"),c=document.createElement("span");o.setAttribute("class","custom-input"),o.setAttribute("type","checkbox"),o.setAttribute("name","language-code"),o.setAttribute("value",e),s.setAttribute("class","label"),s.textContent=Jo(e),c.setAttribute("class","tick"),s.appendChild(c),n.appendChild(o),n.appendChild(s),t.appendChild(n)}))}function Jo(e){const t=new Intl.DisplayNames("en-US",{type:"language"}).of(e);return t.charAt(0).toUpperCase()+t.slice(1)}function Xo(){const e=document.getElementById("bannerCategoriesSelect"),t=x()._cookieConsentConfig.categories;Object.keys(t).forEach((n=>{const o=document.createElement("label"),s=document.createElement("input"),c=document.createElement("span"),a=document.createElement("span");s.setAttribute("class","custom-input category-input"),s.setAttribute("type","checkbox"),s.setAttribute("value",n),t[n].readOnly&&s.setAttribute("checked","checked"),s.setAttribute("disabled","disabled"),c.setAttribute("class","label"),c.textContent=n,a.setAttribute("class","tick"),t[n].readOnly&&a.appendChild(Cn("M16.5 11V8h0c0-2.8-.5-5-4.5-5S7.5 5.2 7.5 8h0v3")),t[n].enabled&&a.appendChild(Cn("M5 12l5 5l10 -10")),c.appendChild(a),o.appendChild(s),o.appendChild(c),e.appendChild(o)}))}function Cn(e){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("height","16"),t.setAttribute("viewBox","0 0 24 24"),t.setAttribute("width","16");var n=document.createElementNS("http://www.w3.org/2000/svg","g");n.setAttribute("fill","none"),n.setAttribute("stroke","#000"),n.setAttribute("stroke-linecap","round"),n.setAttribute("stroke-linejoin","round"),n.setAttribute("stroke-width","2");var o=document.createElementNS("http://www.w3.org/2000/svg","rect");o.setAttribute("height","10"),o.setAttribute("rx","2"),o.setAttribute("ry","2"),o.setAttribute("width","16"),o.setAttribute("x","4"),o.setAttribute("y","11"),n.appendChild(o);var s=document.createElementNS("http://www.w3.org/2000/svg","path");return s.setAttribute("d",e),n.appendChild(s),t.appendChild(n),t}G(N._PLAYGROUND_READY,(()=>{const e=document.querySelectorAll(".category-input"),t=x();no(t._enabledCategories);for(const t of e)I(t,"change",Ko)}));const Ko=e=>{const t=e.target,n=t.checked,o=t.value,s=x();s._enabledCategories=[...new Set(n?[...s._enabledCategories,o]:s._enabledCategories.filter((e=>e!==o)))],ie(s),xe(s,1)},no=e=>{const t=document.querySelectorAll(".category-input");for(const n of t)n.checked=e.includes(n.value)};G(N._RESET,(()=>{no(V._enabledCategories)}));let Tt=document.querySelectorAll('input[name="language-code"]'),Zo=v("translations-section"),At=v("edit-translations-btn"),zo=At.textContent;function oo(e){for(const t of Tt)t.checked=e.includes(t.value)}function yn(e){const t=0===e.length;Zo.classList[t?"add":"remove"]("no-translations-error"),At.disabled=t,At.textContent=t?"Translation required":zo}function ue(e,t){return(t||x())._enabledTranslations.includes(e)}G(N._PLAYGROUND_READY,(()=>{Tt=document.querySelectorAll('input[name="language-code"]');let e=x();(!e||!e._enabledTranslations||!Array.isArray(e._enabledTranslations))&&(console.error("invalid state for banner 2. Resetting it."),We(),e=x());const t=e._enabledTranslations;oo(t),yn(t),Tt.forEach((e=>{I(e,"change",(()=>{const t=e.value,n=e.checked,o=x(),s=o._enabledTranslations,c=o._cookieConsentConfig.language,a=s.includes(t);n?!a&&s.push(t):a&&(o._enabledTranslations=o._enabledTranslations.filter((e=>e!==t))),yn(o._enabledTranslations),en(o._enabledTranslations);const i=et(c.autoDetect),r=i?tt(c.autoDetect):"",l=ue(r,o)&&r||ue(c.default,o)&&c.default||o._enabledTranslations[0]||"";i&&io(l===r),ue(c.default,o)||(c.default=l,Qt(l)),Be(l,o),ie(o)}))}))})),G(N._RESET,(()=>{oo(V._enabledTranslations)}));const Qo=["document","browser"];let Dt=[];const es=v("current-active-language"),xt=v("auto-language"),vn=v("detected-language"),so=v("translation-found"),ut=v("autodetect-mode"),Ze=v("default-language");function ze(e,t){if(e&&"string"==typeof e){return io(ue(e,t||x())),void(vn.textContent=e)}vn.textContent="-",so.textContent="-"}function ao(e){xt.checked=e}function Qe(e){const t=et(e);t&&(ut.value=e),ut.disabled=!t}function Qt(e){e||(Ze.value="disabled"),Dt.includes(e)&&(Ze.value=e)}function en(e){const t=Ze.children;for(const n of t)n.style.display=e.includes(n.value)?"":"none"}function io(e){so.textContent=e?"true":"false"}function et(e){return Qo.includes(e)}function ts(){return navigator.language.slice(0,2)}function ns(){return document.documentElement.lang.slice(0,2)}function tt(e){return"browser"===e?ts():"document"===e?ns():""}function Be(e,t){const n=t||x(),o=ue(e,n)?e:"-";es.textContent=o,"-"!==o?!1!==t&&(v("cc-main")?xe(n,1):setTimeout((()=>{xe(n,1)}),100)):window.CookieConsent&&window.CookieConsent.reset()}G(N._PLAYGROUND_READY,(async()=>{const e=x(),t=e._cookieConsentConfig.language;Dt=Object.keys(t.translations),Wo("default-language",Dt);const n=t.autoDetect,o=et(n),s=tt(n),c=o&&ue(s,e)?s:t.default;o?(Qe(n),ze(s,e)):Qe(""),ao(o),en(e._enabledTranslations),Qt(t.default),Be(c,!1)})),G(N._RESET,(()=>{const e=De.language,t=De.language.default;Qt(t),Qe(e.autoDetect),ze(t,V),ao(!0),en(V._enabledTranslations),Be(t,V)})),I(xt,"change",(()=>{const e=x(),t=e._cookieConsentConfig.language;if(xt.checked){t.autoDetect=t.autoDetect||De.language.autoDetect;const n=tt(t.autoDetect);ze(n,e),ue(n,e)&&Be(n,e),Qe(t.autoDetect)}else t.autoDetect=void 0,ze("",e),Qe(""),Be(t.default,e);ie(e)})),I(ut,"change",(()=>{const e=ut.value;if(et(e)){const t=x();t._cookieConsentConfig.language.autoDetect=e;const n=tt(e);ze(n),ue(n,t)&&Be(n,t),ie(t)}})),I(Ze,"change",(()=>{const e=Ze.value,t=x(),n=t._cookieConsentConfig.language;ue(e,t)&&(n.default=e,(!et(n.autoDetect)||!ue(tt(n.autoDetect),t))&&Be(e,t),ie(t))}));const D={inert:":not([inert]):not([inert] *)",negTabIndex:':not([tabindex^="-"])',disabled:":not(:disabled)"};var os=[`a[href]${D.inert}${D.negTabIndex}`,`area[href]${D.inert}${D.negTabIndex}`,`input:not([type="hidden"]):not([type="radio"])${D.inert}${D.negTabIndex}${D.disabled}`,`input[type="radio"]${D.inert}${D.negTabIndex}${D.disabled}`,`select${D.inert}${D.negTabIndex}${D.disabled}`,`textarea${D.inert}${D.negTabIndex}${D.disabled}`,`button${D.inert}${D.negTabIndex}${D.disabled}`,`details${D.inert} > summary:first-of-type${D.negTabIndex}`,`iframe${D.inert}${D.negTabIndex}`,`audio[controls]${D.inert}${D.negTabIndex}`,`video[controls]${D.inert}${D.negTabIndex}`,`[contenteditable]${D.inert}${D.negTabIndex}`,`[tabindex]${D.inert}${D.negTabIndex}`];function kn(e){(e.querySelector("[autofocus]")||e).focus()}function ss(e){const t=Ve(e,!0);return[t,t?Ve(e,!1)||t:null]}function Ve(e,t){if(t&&En(e))return e;if(is(e))if(e.shadowRoot){let n=wn(e.shadowRoot,t);for(;n;){const e=Ve(n,t);if(e)return e;n=_n(n,t)}}else if("slot"===e.localName){const n=e.assignedElements({flatten:!0});t||n.reverse();for(const e of n){const n=Ve(e,t);if(n)return n}}else{let n=wn(e,t);for(;n;){const e=Ve(n,t);if(e)return e;n=_n(n,t)}}return!t&&En(e)?e:null}function wn(e,t){return t?e.firstElementChild:e.lastElementChild}function _n(e,t){return t?e.nextElementSibling:e.previousElementSibling}const as=e=>!(!e.matches("details:not([open]) *")||e.matches("details>summary:first-of-type"))||!(e.offsetWidth||e.offsetHeight||e.getClientRects().length),En=e=>!e.shadowRoot?.delegatesFocus&&(e.matches(os.join(","))&&!as(e));function is(e){return(!e.shadowRoot||"-1"!==e.getAttribute("tabindex"))&&!e.matches(":disabled,[hidden],[inert]")}function tn(e=document){const t=e.activeElement;return t?t.shadowRoot?tn(t.shadowRoot)||document.activeElement:t:null}function cs(e,t){const[n,o]=ss(e);if(!n)return t.preventDefault();const s=tn();t.shiftKey&&s===n?(o.focus(),t.preventDefault()):!t.shiftKey&&s===o&&(n.focus(),t.preventDefault())}class co{$el;id;previouslyFocused;shown;constructor(e){this.$el=e,this.id=this.$el.getAttribute("data-a11y-dialog")||this.$el.id,this.previouslyFocused=null,this.shown=!1,this.maintainFocus=this.maintainFocus.bind(this),this.bindKeypress=this.bindKeypress.bind(this),this.handleTriggerClicks=this.handleTriggerClicks.bind(this),this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.$el.setAttribute("aria-hidden","true"),this.$el.setAttribute("aria-modal","true"),this.$el.setAttribute("tabindex","-1"),this.$el.hasAttribute("role")||this.$el.setAttribute("role","dialog"),document.addEventListener("click",this.handleTriggerClicks,!0)}destroy(){return this.hide(),document.removeEventListener("click",this.handleTriggerClicks,!0),this.$el.replaceWith(this.$el.cloneNode(!0)),this.fire("destroy"),this}show(e){return this.shown||(this.shown=!0,this.$el.removeAttribute("aria-hidden"),this.previouslyFocused=tn(),"BODY"===this.previouslyFocused?.tagName&&e?.target&&(this.previouslyFocused=e.target),"focus"===e?.type?this.maintainFocus(e):kn(this.$el),document.body.addEventListener("focus",this.maintainFocus,!0),this.$el.addEventListener("keydown",this.bindKeypress,!0),this.fire("show",e)),this}hide(e){return this.shown?(this.shown=!1,this.$el.setAttribute("aria-hidden","true"),this.previouslyFocused?.focus?.(),document.body.removeEventListener("focus",this.maintainFocus,!0),this.$el.removeEventListener("keydown",this.bindKeypress,!0),this.fire("hide",e),this):this}on(e,t,n){return this.$el.addEventListener(e,t,n),this}off(e,t,n){return this.$el.removeEventListener(e,t,n),this}fire(e,t){this.$el.dispatchEvent(new CustomEvent(e,{detail:t,cancelable:!0}))}handleTriggerClicks(e){const t=e.target;t.closest(`[data-a11y-dialog-show="${this.id}"]`)&&this.show(e),(t.closest(`[data-a11y-dialog-hide="${this.id}"]`)||t.closest("[data-a11y-dialog-hide]")&&t.closest('[aria-modal="true"]')===this.$el)&&this.hide(e)}bindKeypress(e){if(document.activeElement?.closest('[aria-modal="true"]')!==this.$el)return;let t=!1;try{t=!!this.$el.querySelector('[popover]:not([popover="manual"]):popover-open')}catch{}"Escape"===e.key&&"alertdialog"!==this.$el.getAttribute("role")&&!t&&(e.preventDefault(),this.hide(e)),"Tab"===e.key&&cs(this.$el,e)}maintainFocus(e){e.target.closest('[aria-modal="true"], [data-a11y-dialog-ignore-focus-trap]')||kn(this.$el)}}function Sn(){for(const e of document.querySelectorAll("[data-a11y-dialog]"))new co(e)}async function ro(){const e=v("nscBarErrorMessage");e.style.display="none";const t=v("downloadConfigBtn");t.classList.add("nscbutton--loading");const n=window.location.search,o=new URLSearchParams(n);window.restURL=o.get("rest_url_encoded"),window.nonce=o.get("wp_nonce");const s=x(),c={config:zt(s),localState:s},a=await fetch(`${window.restURL}beautiful-and-responsive-cookie-consent/v1/newBanner/save`,{method:"POST",mode:"cors",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json",_wpnonce:window.nonce,"X-WP-Nonce":window.nonce},redirect:"follow",referrerPolicy:"no-referrer",body:JSON.stringify(c)});if(t.classList.remove("nscbutton--loading"),a.status>204){let t;try{t=await a.json()}catch(e){t={message:`response not json: ${e.message}`,error:[]}}let n=`${a.status}: ${t.message}`;Array.isArray(t.error)&&t.error.forEach((e=>{n=`${n}: ${e}, `})),e.innerText=`${n}`,e.style.display=""}}typeof document<"u"&&("loading"===document.readyState?document.addEventListener("DOMContentLoaded",Sn):Sn());const rs=v("edit-translations-dialog"),ls=new co(rs),Me=v("editor-language-codes"),lo=v("consent-modal-title"),uo=v("consent-modal-description"),fo=v("consent-modal-accept-btn"),po=v("close-icon-label"),go=v("consent-modal-reject-btn"),ho=v("consent-modal-manage-btn"),mo=v("editing"),bo=v("pm-title"),Co=v("pm-close-icon-label"),yo=v("pm-accept-btn"),vo=v("pm-reject-btn"),ko=v("pm-save-btn"),wo=v("pm-service-counter-label"),Ln=v("edit-translations-btn"),us=v("save-translation-config-btn"),ds=v("add-section-btn"),nn=v("pm-sections"),fs=v("sections-counter");let ps=[],de="",Ne=0,Bt=null;I(Ln,"click",(()=>{Ln.disabled||(Bt=x(),!1!==hs()&&(ls.show(),de=Me.value))})),I(ds,"click",(()=>{Cs(So())})),I(us,"click",(()=>{const e=Me.value,t=x();t._cookieConsentConfig.language.translations[e]=ys(),ie(t),xe(t,1),window.CookieConsent.setLanguage(e),ro()})),I(Me,"change",(()=>{de=Me.value,Eo(de),_o(),gs()&&window.CookieConsent.setLanguage(de)}));const gs=()=>document.documentElement.classList.contains("show--consent");function hs(e){const t=x();if(0===(e=e||t._enabledTranslations).length)return!1;bs(ps,e)||(e.includes(de)||(de=e[0],Eo(de)),ms(e),_o(t))}function _o(e){const t=e||x(),n=t._cookieConsentConfig.language.translations[de],{consentModal:o,preferencesModal:s}=n;lo.value=o.title||"",uo.value=o.description||"",fo.value=o.acceptAllBtn||"",po.value=o.closeIconLabel||"",go.value=o.acceptNecessaryBtn||"",ho.value=o.showPreferencesBtn||"",mo.value=o.footer||"",bo.value=s.title||"",Co.value=s.closeIconLabel||"",yo.value=s.acceptAllBtn||"",vo.value=s.acceptNecessaryBtn||"",ko.value=s.savePreferencesBtn||"",wo.value=s.serviceCounterLabel||"";const c=s.sections||[],a=[];for(const e of c)(!e.linkedCategory||t._enabledCategories.includes(e.linkedCategory))&&a.push(So(e));Ne=a.length,Mt(Ne),nn.replaceChildren(...a)}function ms(e){const t=[];for(const n of e){const e=document.createElement("option");e.value=n,e.textContent=n,e.className=`translation-btn--${n}`,t.push(e)}Me.replaceChildren(...t),Me.value=de}function Eo(e){de=e,Me.setAttribute("data-current-translation",e)}function bs(e,t){return JSON.stringify(e.sort())===JSON.stringify(t.sort())}function Cs(e){nn.appendChild(e)}function So(e){const t=document.createElement("li");t.className="pm-section";const n=document.createElement("textarea");n.value=e?.title||"",n.placeholder="Title",n.className="pm-section-title small-textarea",t.appendChild(n);const o=document.createElement("textarea");o.value=e?.description||"",o.placeholder="Description",o.className="pm-section-description",t.appendChild(o);const s=document.createElement("div");s.className="pm-section-label-btn-container";const c=document.createElement("label"),a=document.createElement("span"),i=document.createElement("span"),r=document.createElement("span"),l=document.createElement("select");c.className="select-label",l.className="pm-section-linked-category",r.className="arrow-icon",a.textContent="Linked category",i.className="select-input";const d=e?.linkedCategory,u=["",...Bt._enabledCategories];for(const e of u){const t=document.createElement("option");t.value=e,t.textContent=e,e===d&&Bt._enabledCategories.includes(d)?(t.selected=!0,t.textContent=d):e||(t.selected=!0,t.textContent="—"),l.appendChild(t)}i.appendChild(l),i.appendChild(r),c.appendChild(a),c.appendChild(i),s.appendChild(c);const h=document.createElement("button");return h.textContent="Delete section",h.className="styled-btn pm-section__delete-btn",I(h,"click",(()=>{Ne-=1,t.remove(),Mt(Ne)})),s.appendChild(h),t.appendChild(s),Ne+=1,Mt(Ne),t}function Mt(e){fs.textContent=e}function ys(){const e={};e.title=lo.value,e.description=uo.value,e.closeIconLabel=po.value,e.acceptAllBtn=fo.value,e.acceptNecessaryBtn=go.value,e.showPreferencesBtn=ho.value,e.footer=mo.value;const t={};t.title=bo.value,t.closeIconLabel=Co.value,t.acceptAllBtn=yo.value,t.acceptNecessaryBtn=vo.value,t.savePreferencesBtn=ko.value,t.serviceCounterLabel=wo.value,t.sections=[];for(const e of nn.children){const n=e.querySelector(".pm-section-title").value,o=e.querySelector(".pm-section-description").value,s=e.querySelector(".pm-section-linked-category").value,c={title:n,description:o};s&&(c.linkedCategory=s),t.sections.push(c)}return{consentModal:e,preferencesModal:t}}const we="change",U="consentModal",ne="preferencesModal",H={consentModal:{layout:v("cm-layout"),position:v("cm-position"),flipButtons:v("cm-flip"),equalWeightButtons:v("cm-weight")},preferencesModal:{layout:v("pm-layout"),position:v("pm-position"),flipButtons:v("pm-flip"),equalWeightButtons:v("pm-weight")}},vs=["top","middle","bottom"],ks=["left","center","right"];let Ot="",It="";const qe=e=>"top"===e||"bottom"===e;let on=!1;function _e(e,t,n){const o=x();if(e===U){if("layout"===t){const e=Ot.startsWith("bar"),t=o._cookieConsentConfig.guiOptions.consentModal,n=t.position;qe(n)?o._lastBarPosition=n:o._lastNonBarPosition=n,(!e&&qe(n)||e&&!qe(n))&&(Lo(!e),e?qe(n)||(t.position=H[U].position.value=o._lastBarPosition||"bottom"):t.position=H[U].position.value=o._lastNonBarPosition||De.guiOptions.consentModal.position)}if("position"===t){const e=o._cookieConsentConfig.guiOptions.consentModal.position;qe(e)?o._lastBarPosition=e:o._lastNonBarPosition=e}}else"layout"===t&&("box"===It?ft(!0):on&&ft(!1));o._cookieConsentConfig.guiOptions[e][t]=n,ie(o),xe(o,"consentModal"===e?1:2)}function dt(e){const t=window.CookieConsent.getConfig("guiOptions")[e];ws(e,t.layout,t.position),Es(e,t.flipButtons),Ss(e,t.equalWeightButtons)}function ws(e,t,n){H[e].layout.value=t,_s(e,n,t)}function _s(e,t,n){e===ne&&("box"===n?ft(!0):on&&ft(!1)),e===U&&Lo(!n.startsWith("bar")),H[e].position.value=t}function ft(e){on=e,H[ne].position.disabled=e}function Es(e,t){H[e].flipButtons.checked=t}function Ss(e,t){H[e].equalWeightButtons.checked=t}function Tn(e,t){const n=document.createDocumentFragment();function o(e){let t=document.createElement("option");t.text=t.value=e,n.appendChild(t)}return e.forEach((e=>{let n=e;t?t.forEach((t=>{n=e+" "+t,o(n)})):o(n)})),n}function Lo(e){let t;t=e?Tn(vs,ks):Tn(["top","bottom"]),H[U].position.textContent="",H[U].position.appendChild(t)}I(H[U].layout,we,(function(){Ot=this.value,_e(U,"layout",Ot)})),I(H[U].position,we,(function(){_e(U,"position",this.value)})),I(H[U].flipButtons,we,(function(){_e(U,"flipButtons",this.checked)})),I(H[U].equalWeightButtons,we,(function(){_e(U,"equalWeightButtons",this.checked)})),I(H[ne].layout,we,(function(){It=this.value,_e(ne,"layout",It)})),I(H[ne].position,we,(function(){_e(ne,"position",this.value)})),I(H[ne].flipButtons,we,(function(){_e(ne,"flipButtons",this.checked)})),I(H[ne].equalWeightButtons,we,(function(){_e(ne,"equalWeightButtons",this.checked)})),G(N._INIT,(()=>{dt(U),dt(ne)})),G(N._RESET,(()=>{dt(U),dt(ne)}));const Ls=document.querySelectorAll('input[name="theme"]');let Te="";G(N._PLAYGROUND_READY,(()=>{Te=x()._theme,pt(Te);for(const e of Ls)I(e,"change",(()=>{const t=x(),n=e.id;Te=t._theme;const o="cc--darkmode"===n;t._theme=n,ie(t),pt(n),bt(o),window.CookieConsent.show(!0)}))}));const pt=e=>{v(e).checked=!0;const{classList:t}=document.documentElement;t.add(e),Te&&Te!==e&&t.remove(Te),Te=e};G(N._RESET,(()=>pt(V._theme)));const sn="cc--darkmode",Ts="default-light",it=v("darkmode-checkbox");function bt(e){const t=e?"add":"remove";it.checked=e,document.documentElement.classList[t]("cc--darkmode")}G(N._PLAYGROUND_READY,(()=>{bt(x()._theme===sn)})),I(it,"change",(()=>{const e=x(),t=e._theme;document.documentElement.classList.remove(t),e._theme=it.checked?sn:Ts,bt(it.checked),pt(e._theme),ie(e),window.CookieConsent.show(!0)})),G(N._RESET,(()=>{bt(V._theme===sn)}));const gt=v("disablePageInteraction-checkbox");I(gt,"change",(()=>{const e=x();e._cookieConsentConfig.disablePageInteraction=gt.checked,ie(e),xe(e,1)})),G(N._PLAYGROUND_READY,(()=>{gt.checked=!!x()._cookieConsentConfig.disablePageInteraction})),G(N._RESET,(()=>{gt.checked=V._cookieConsentConfig.disablePageInteraction}));const As=v("reset-btn");I(As,"click",(()=>We()));const ht=v("disableTransitions-checkbox"),an="cc--disable-transitions";I(ht,"change",(()=>{const e=x(),t=ht.checked;e._disableTransitions=t,cn(an,t),ie(e),xe(e,1)})),G(N._PLAYGROUND_READY,(()=>{const e=x()._disableTransitions;ht.checked=e,cn(an,e)})),G(N._RESET,(()=>{const e=V._disableTransitions;ht.checked=e,cn(an,e)}));const cn=(e,t)=>{document.body.classList[t?"add":"remove"](e)},Ds=v("downloadConfigBtn");I(Ds,"click",ro),Vo("langInputs"),Xo(),window.CookieConsent=Yo,Go(),Zt(N._PLAYGROUND_READY),eo(zt(x())).then((()=>{Zt(N._INIT)}));1 const An="opt-in",Ge="opt-out",Nt="show--consent",$t="show--preferences",_t="disable--interaction",ct="data-category",T="div",se="button",ae="aria-hidden",Ue="btn-group",q="click",Pe="data-role",Rt="consentModal",Pt="preferencesModal";class Dn{constructor(){this.t={mode:An,revision:0,autoShow:!0,lazyHtmlGeneration:!0,autoClearCookies:!0,manageScriptTags:!0,hideFromBots:!0,cookie:{name:"cc_cookie",expiresAfterDays:182,domain:"",path:"/",sameSite:"Lax"}},this.o={i:{},l:"",_:{},u:{},p:{},m:[],v:!1,h:null,C:null,S:null,M:"",D:!0,T:!1,k:!1,A:!1,N:!1,H:[],V:!1,I:!0,L:[],j:!1,F:"",P:!1,O:[],R:[],B:[],G:[],J:!1,U:!1,$:!1,q:[],K:[],W:[],X:{},Y:{},Z:{},ee:{},te:{},ne:[]},this.oe={se:{},ae:{}},this.ce={},this.re={ie:"cc:onFirstConsent",le:"cc:onConsent",de:"cc:onChange",fe:"cc:onModalShow",_e:"cc:onModalHide",ue:"cc:onModalReady"}}}const c=new Dn,Bn=(e,t)=>e.indexOf(t),A=(e,t)=>-1!==Bn(e,t),He=e=>Array.isArray(e),he=e=>"string"==typeof e,rt=e=>!!e&&"object"==typeof e&&!He(e),pe=e=>"function"==typeof e,ce=e=>Object.keys(e),Ft=e=>Array.from(new Set(e)),lt=()=>document.activeElement,$e=e=>e.preventDefault(),Ht=(e,t)=>e.querySelectorAll(t),nt=e=>e.dispatchEvent(new Event("change")),m=e=>{const t=document.createElement(e);return e===se&&(t.type=e),t},y=(e,t,n)=>e.setAttribute(t,n),yt=(e,t,n)=>{e.removeAttribute(n?"data-"+t:t)},ot=(e,t,n)=>e.getAttribute(n?"data-"+t:t),h=(e,t)=>e.appendChild(t),x=(e,t)=>e.classList.add(t),W=(e,t)=>x(e,"cm__"+t),S=(e,t)=>x(e,"pm__"+t),ke=(e,t)=>e.classList.remove(t),ge=e=>{if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let n in e){let o=e[n];t[n]=ge(o)}return t},Do=()=>{const e={},{O:t,X:n,Y:o}=c.o;for(const s of t)e[s]=st(o[s],ce(n[s]));return e},dn=(e,t)=>dispatchEvent(new CustomEvent(e,{detail:t})),N=(e,t,n,o)=>{e.addEventListener(t,n),o&&c.o.m.push({pe:e,me:t,ge:n})},fn=()=>{const e=c.t.cookie.expiresAfterDays;return pe(e)?e(c.o.F):e},st=(e,t)=>{const n=e||[],o=t||[];return n.filter((e=>!A(o,e))).concat(o.filter((e=>!A(n,e))))},xn=e=>{c.o.R=Ft(e),c.o.F=(()=>{let e="custom";const{R:t,O:n,B:o}=c.o,s=t.length;return s===n.length?e="all":s===o.length&&(e="necessary"),e})()},Mn=(e,t,n,o)=>{const s="accept-",{show:a,showPreferences:i,hide:r,hidePreferences:l,acceptCategory:d}=t,u=e||document,h=e=>Ht(u,`[data-cc="${e}"]`),f=(e,t)=>{$e(e),d(t),l(),r()},m=h("show-preferencesModal"),p=h("show-consentModal"),g=h(s+"all"),b=h(s+"necessary"),v=h(s+"custom"),C=c.t.lazyHtmlGeneration;for(const e of m)y(e,"aria-haspopup","dialog"),N(e,q,(e=>{$e(e),i()})),C&&(N(e,"mouseenter",(e=>{$e(e),c.o.N||n(t,o)}),!0),N(e,"focus",(()=>{c.o.N||n(t,o)})));for(let e of p)y(e,"aria-haspopup","dialog"),N(e,q,(e=>{$e(e),a(!0)}),!0);for(let e of g)N(e,q,(e=>{f(e,"all")}),!0);for(let e of v)N(e,q,(e=>{f(e)}),!0);for(let e of b)N(e,q,(e=>{f(e,[])}),!0)},re=(e,t)=>{e&&(t&&(e.tabIndex=-1),e.focus(),t&&e.removeAttribute("tabindex"))},On=(e,t)=>{const n=o=>{o.target.removeEventListener("transitionend",n),"opacity"===o.propertyName&&"1"===getComputedStyle(e).opacity&&re(1===t?c.oe.be:c.oe.ve)};N(e,"transitionend",n)};let pn;const In=e=>{clearTimeout(pn),e?x(c.oe.ye,_t):pn=setTimeout((()=>{ke(c.oe.ye,_t)}),500)},Bo=["M 19.5 4.5 L 4.5 19.5 M 4.5 4.501 L 19.5 19.5","M 3.572 13.406 L 8.281 18.115 L 20.428 5.885","M 21.999 6.94 L 11.639 17.18 L 2.001 6.82 "],Je=(e=0,t=1.5)=>`<svg viewBox="0 0 24 24" stroke-width="${t}"><path d="${Bo[e]}"/></svg>`,Nn=e=>{const t=c.oe,n=c.o;(e=>{const o=e===t.he,s=n.i.disablePageInteraction?t.ye:o?t.Ce:t.ye;N(s,"keydown",(t=>{if("Tab"!==t.key||!(o?n.k&&!n.A:n.A))return;const s=lt(),c=o?n.q:n.K;0!==c.length&&(t.shiftKey?s!==c[0]&&e.contains(s)||($e(t),re(c[1])):s!==c[1]&&e.contains(s)||($e(t),re(c[0])))}),!0)})(e)},xo=["[href]",se,"input","details","[tabindex]"].map((e=>e+':not([tabindex="-1"])')).join(","),$n=e=>{const{o:t,oe:n}=c,o=(e,t)=>{const n=Ht(e,xo);t[0]=n[0],t[1]=n[n.length-1]};1===e&&t.T&&o(n.he,t.q),2===e&&t.N&&o(n.we,t.K)},le=(e,t,n)=>{const{de:o,le:s,ie:a,_e:i,ue:r,fe:l}=c.ce,d=c.re;if(t){const o={modalName:t};return e===d.fe?pe(l)&&l(o):e===d._e?pe(i)&&i(o):(o.modal=n,pe(r)&&r(o)),dn(e,o)}const u={cookie:c.o.p};e===d.ie?pe(a)&&a(ge(u)):e===d.le?pe(s)&&s(ge(u)):(u.changedCategories=c.o.L,u.changedServices=c.o.ee,pe(o)&&o(ge(u))),dn(e,ge(u))},Xe=(e,t)=>{try{return e()}catch(e){return!t&&console.warn("CookieConsent:",e),!1}},Et=e=>{const{Y:t,ee:n,O:o,X:s,ne:a,p:i,L:r}=c.o;for(const e of o){const o=n[e]||t[e]||[];for(const n of o){const o=s[e][n];if(!o)continue;const{onAccept:c,onReject:a}=o;!o.Se&&A(t[e],n)&&pe(c)?(o.Se=!0,c()):o.Se&&!A(t[e],n)&&pe(a)&&(o.Se=!1,a())}}if(!c.t.manageScriptTags)return;const l=a,d=e||i.categories||[],u=(e,o)=>{if(o>=e.length)return;const s=a[o];if(s.xe)return u(e,o+1);const c=s.Me,i=s.De,l=s.Te,h=A(d,i),f=!!l&&A(t[i],l);if(!l&&!s.ke&&h||!l&&s.ke&&!h&&A(r,i)||l&&!s.ke&&f||l&&s.ke&&!f&&A(n[i]||[],l)){s.xe=!0;const t=ot(c,"type",!0);yt(c,"type",!!t),yt(c,ct);let n=ot(c,"src",!0);n&&yt(c,"src",!0);const a=m("script");a.textContent=c.innerHTML;for(const{nodeName:e}of c.attributes)y(a,e,c[e]||ot(c,e));t&&(a.type=t),n?a.src=n:n=c.src;const i=!!n&&(!t||["text/javascript","module"].includes(t));if(i&&(a.onload=a.onerror=()=>{u(e,++o)}),c.replaceWith(a),i)return}u(e,++o)};u(l,0)},at="bottom",St="left",Rn="center",jt="right",vt="inline",Pn="wide",Fn="pm--",kt=["middle","top",at],gn=[St,Rn,jt],Mo={box:{Ae:[Pn,vt],Ee:kt,Ne:gn,He:at,Ve:jt},cloud:{Ae:[vt],Ee:kt,Ne:gn,He:at,Ve:Rn},bar:{Ae:[vt],Ee:kt.slice(1),Ne:[],He:at,Ve:""}},Oo={box:{Ae:[],Ee:[],Ne:[],He:"",Ve:""},bar:{Ae:[Pn],Ee:[],Ne:[St,jt],He:"",Ve:St}},Hn=e=>{const t=c.o.i.guiOptions,n=t&&t.consentModal,o=t&&t.preferencesModal;0===e&&hn(c.oe.he,Mo,n,"cm--","box","cm"),1===e&&hn(c.oe.we,Oo,o,Fn,"box","pm")},hn=(e,t,n,o,s,a)=>{e.className=a;const i=n&&n.layout,r=n&&n.position,l=n&&n.flipButtons,d=!n||!1!==n.equalWeightButtons,u=i&&i.split(" ")||[],h=u[0],f=u[1],m=h in t?h:s,p=t[m],g=A(p.Ae,f)&&f,b=r&&r.split(" ")||[],y=b[0],v=o===Fn?b[0]:b[1],C=A(p.Ee,y)?y:p.He,w=A(p.Ne,v)?v:p.Ve,k=t=>{t&&x(e,o+t)};k(m),k(g),k(C),k(w),l&&k("flip");const _=a+"__btn--secondary";if("cm"===a){const{Ie:e,Le:t}=c.oe;e&&(d?ke(e,_):x(e,_)),t&&(d?ke(t,_):x(t,_))}else{const{je:e}=c.oe;e&&(d?ke(e,_):x(e,_))}},Fe=(e,t)=>{const n=c.o,o=c.oe,{hide:s,hidePreferences:a,acceptCategory:i}=e,r=e=>{i(e),a(),s()},l=n.u&&n.u.preferencesModal;if(!l)return;const d=l.title,u=l.closeIconLabel,f=l.acceptAllBtn,p=l.acceptNecessaryBtn,g=l.savePreferencesBtn,b=l.sections||[],v=f||p||g;if(o.Fe)o.Pe=m(T),S(o.Pe,"body");else{o.Fe=m(T),x(o.Fe,"pm-wrapper");const e=m("div");x(e,"pm-overlay"),h(o.Fe,e),N(e,q,a),o.we=m(T),x(o.we,"pm"),y(o.we,"role","dialog"),y(o.we,ae,!0),y(o.we,"aria-modal",!0),y(o.we,"aria-labelledby","pm__title"),N(o.ye,"keydown",(e=>{27===e.keyCode&&a()}),!0),o.Oe=m(T),S(o.Oe,"header"),o.Re=m("h2"),S(o.Re,"title"),o.Re.id="pm__title",o.Be=m(se),S(o.Be,"close-btn"),y(o.Be,"aria-label",l.closeIconLabel||""),N(o.Be,q,a),o.Ge=m("span"),o.Ge.innerHTML=Je(),h(o.Be,o.Ge),o.Je=m(T),S(o.Je,"body"),o.Ue=m(T),S(o.Ue,"footer");var C=m(T);x(C,"btns");var w=m(T),k=m(T);S(w,Ue),S(k,Ue),h(o.Ue,w),h(o.Ue,k),h(o.Oe,o.Re),h(o.Oe,o.Be),o.ve=m(T),y(o.ve,"tabIndex",-1),h(o.we,o.ve),h(o.we,o.Oe),h(o.we,o.Je),v&&h(o.we,o.Ue),h(o.Fe,o.we)}let _;d&&(o.Re.innerHTML=d,u&&y(o.Be,"aria-label",u)),b.forEach(((e,t)=>{const s=e.title,c=e.description,a=e.linkedCategory,i=a&&n.P[a],r=e.cookieTable,d=r&&r.body,u=r&&r.caption,f=d&&d.length>0,p=!!i,g=p&&n.X[a],b=rt(g)&&ce(g)||[],v=p&&(!!c||!!f||ce(g).length>0);var C=m(T);if(S(C,"section"),v||c){var w=m(T);S(w,"section-desc-wrapper")}let k=b.length;if(v&&k>0){const e=m(T);S(e,"section-services");for(const t of b){const n=g[t],o=n&&n.label||t,s=m(T),c=m(T),r=m(T),l=m(T);S(s,"service"),S(l,"service-title"),S(c,"service-header"),S(r,"service-icon");const d=mn(o,t,i,!0,a);l.innerHTML=o,h(c,r),h(c,l),h(s,c),h(s,d),h(e,s)}h(w,e)}if(s){var A=m(T),E=m(p?se:T);if(S(A,"section-title-wrapper"),S(E,"section-title"),E.innerHTML=s,h(A,E),p){const e=m("span");e.innerHTML=Je(2,3.5),S(e,"section-arrow"),h(A,e),C.className+="--toggle";const t=mn(s,a,i);let n=l.serviceCounterLabel;if(k>0&&he(n)){let e=m("span");S(e,"badge"),S(e,"service-counter"),y(e,ae,!0),y(e,"data-servicecounter",k),n&&(n=n.split("|"),n=n.length>1&&k>1?n[1]:n[0],y(e,"data-counterlabel",n)),e.innerHTML=k+(n?" "+n:""),h(E,e)}if(v){S(C,"section--expandable");var B=a+"-desc";y(E,"aria-expanded",!1),y(E,"aria-controls",B)}h(A,t)}else y(E,"role","heading"),y(E,"aria-level","3");h(C,A)}if(c){var D=m("p");S(D,"section-desc"),D.innerHTML=c,h(w,D)}if(v&&(y(w,ae,"true"),w.id=B,L=w,R=C,I=E,N(E,q,(()=>{R.classList.contains("is-expanded")?(ke(R,"is-expanded"),y(I,"aria-expanded","false"),y(L,ae,"true")):(x(R,"is-expanded"),y(I,"aria-expanded","true"),y(L,ae,"false"))})),f)){const e=m("table"),n=m("thead"),s=m("tbody");if(u){const t=m("caption");S(t,"table-caption"),t.innerHTML=u,e.appendChild(t)}S(e,"section-table"),S(n,"table-head"),S(s,"table-body");const c=r.headers,a=ce(c),i=o.$e.createDocumentFragment(),l=m("tr");for(const e of a){const n=c[e],o=m("th");o.id="cc__row-"+n+t,y(o,"scope","col"),S(o,"table-th"),o.innerHTML=n,h(i,o)}h(l,i),h(n,l);const f=o.$e.createDocumentFragment();for(const e of d){const n=m("tr");S(n,"table-tr");for(const o of a){const s=c[o],a=e[o],i=m("td"),r=m(T);S(i,"table-td"),y(i,"data-column",s),y(i,"headers","cc__row-"+s+t),r.insertAdjacentHTML("beforeend",a),h(i,r),h(n,i)}h(f,n)}h(s,f),h(e,n),h(e,s),h(w,e)}var L,R,I;(v||c)&&h(C,w);const $=o.Pe||o.Je;p?(_||(_=m(T),S(_,"section-toggles")),_.appendChild(C)):_=null,h($,_||C)})),f&&(o.ze||(o.ze=m(se),S(o.ze,"btn"),y(o.ze,Pe,"all"),h(w,o.ze),N(o.ze,q,(()=>r("all")))),o.ze.innerHTML=f),p&&(o.je||(o.je=m(se),S(o.je,"btn"),y(o.je,Pe,"necessary"),h(w,o.je),N(o.je,q,(()=>r([])))),o.je.innerHTML=p),g&&(o.qe||(o.qe=m(se),S(o.qe,"btn"),S(o.qe,"btn--secondary"),y(o.qe,Pe,"save"),h(k,o.qe),N(o.qe,q,(()=>r()))),o.qe.innerHTML=g),o.Pe&&(o.we.replaceChild(o.Pe,o.Je),o.Je=o.Pe),Hn(1),n.N||(n.N=!0,le(c.re.ue,Pt,o.we),t(e),h(o.Ce,o.Fe),Nn(o.we),setTimeout((()=>x(o.Fe,"cc--anim")),100)),$n(2)};function mn(e,t,n,o,s){const a=c.o,i=c.oe,r=m("label"),l=m("input"),d=m("span"),u=m("span"),f=m("span"),p=m("span"),g=m("span");if(p.innerHTML=Je(1,3),g.innerHTML=Je(0,3),l.type="checkbox",x(r,"section__toggle-wrapper"),x(l,"section__toggle"),x(p,"toggle__icon-on"),x(g,"toggle__icon-off"),x(d,"toggle__icon"),x(u,"toggle__icon-circle"),x(f,"toggle__label"),y(d,ae,"true"),o?(x(r,"toggle-service"),y(l,ct,s),i.ae[s][t]=l):i.se[t]=l,o?(b=s,N(l,"change",(()=>{const e=i.ae[b],t=i.se[b];a.Z[b]=[];for(let t in e){const n=e[t];n.checked&&a.Z[b].push(n.value)}t.checked=a.Z[b].length>0}))):(e=>{N(l,q,(()=>{const t=i.ae[e],n=l.checked;a.Z[e]=[];for(let o in t)t[o].checked=n,n&&a.Z[e].push(o)}))})(t),l.value=t,f.textContent=e.replace(/<.*>.*<\/.*>/gm,""),h(u,g),h(u,p),h(d,u),a.D)(n.readOnly||n.enabled)&&(l.checked=!0);else if(o){const e=a.Y[s];l.checked=n.readOnly||A(e,t)}else A(a.R,t)&&(l.checked=!0);var b;return n.readOnly&&(l.disabled=!0),h(r,l),h(r,d),h(r,f),r}const wt=()=>{const e=m("span");return c.oe.Ke||(c.oe.Ke=e),e},Yt=(e,t)=>{const n=c.o,o=c.oe,{hide:s,showPreferences:a,acceptCategory:i}=e,r=n.u&&n.u.consentModal;if(!r)return;const l=r.acceptAllBtn,d=r.acceptNecessaryBtn,u=r.showPreferencesBtn,f=r.closeIconLabel,p=r.footer,g=r.label,b=r.title,v=e=>{s(),i(e)};if(!o.Qe){o.Qe=m(T),o.he=m(T),o.We=m(T),o.Xe=m(T),o.Ye=m(T),x(o.Qe,"cm-wrapper"),x(o.he,"cm"),W(o.We,"body"),W(o.Xe,"texts"),W(o.Ye,"btns"),y(o.he,"role","dialog"),y(o.he,"aria-modal","true"),y(o.he,ae,"false"),y(o.he,"aria-describedby","cm__desc"),g?y(o.he,"aria-label",g):b&&y(o.he,"aria-labelledby","cm__title");const e="box",t=n.i.guiOptions,s=t&&t.consentModal,c=(s&&s.layout||e).split(" ")[0]===e;b&&f&&c&&(o.Le||(o.Le=m(se),o.Le.innerHTML=Je(),W(o.Le,"btn"),W(o.Le,"btn--close"),N(o.Le,q,(()=>{v([])})),h(o.We,o.Le)),y(o.Le,"aria-label",f)),h(o.We,o.Xe),(l||d||u)&&h(o.We,o.Ye),o.be=m(T),y(o.be,"tabIndex",-1),h(o.he,o.be),h(o.he,o.We),h(o.Qe,o.he)}b&&(o.Ze||(o.Ze=m("h2"),o.Ze.className=o.Ze.id="cm__title",h(o.Xe,o.Ze)),o.Ze.innerHTML=b);let C=r.description;if(C&&(n.V&&(C=C.replace("{{revisionMessage}}",n.I?"":r.revisionMessage||"")),o.et||(o.et=m("p"),o.et.className=o.et.id="cm__desc",h(o.Xe,o.et)),o.et.innerHTML=C),l&&(o.tt||(o.tt=m(se),h(o.tt,wt()),W(o.tt,"btn"),y(o.tt,Pe,"all"),N(o.tt,q,(()=>{v("all")}))),o.tt.firstElementChild.innerHTML=l),d&&(o.Ie||(o.Ie=m(se),h(o.Ie,wt()),W(o.Ie,"btn"),y(o.Ie,Pe,"necessary"),N(o.Ie,q,(()=>{v([])}))),o.Ie.firstElementChild.innerHTML=d),u&&(o.nt||(o.nt=m(se),h(o.nt,wt()),W(o.nt,"btn"),W(o.nt,"btn--secondary"),y(o.nt,Pe,"show"),N(o.nt,"mouseenter",(()=>{n.N||Fe(e,t)})),N(o.nt,q,a)),o.nt.firstElementChild.innerHTML=u),o.ot||(o.ot=m(T),W(o.ot,Ue),l&&h(o.ot,o.tt),d&&h(o.ot,o.Ie),(l||d)&&h(o.We,o.ot),h(o.Ye,o.ot)),o.nt&&!o.st&&(o.st=m(T),o.Ie&&o.tt?(W(o.st,Ue),h(o.st,o.nt),h(o.Ye,o.st)):(h(o.ot,o.nt),W(o.ot,Ue+"--uneven"))),p){if(!o.ct){let e=m(T),t=m(T);o.ct=m(T),W(e,"footer"),W(t,"links"),W(o.ct,"link-group"),h(t,o.ct),h(e,t),h(o.he,e)}o.ct.innerHTML=p}Hn(0),n.T||(n.T=!0,le(c.re.ue,Rt,o.he),t(e),h(o.Ce,o.Qe),Nn(o.he),setTimeout((()=>x(o.Qe,"cc--anim")),100)),$n(1),Mn(o.We,e,Fe,t)},qt=e=>{if(!he(e))return null;if(e in c.o._)return e;let t=e.slice(0,2);return t in c.o._?t:null},Gt=()=>c.o.l||c.o.i.language.default,Ut=e=>{e&&(c.o.l=e)},jn=async e=>{const t=c.o;let n=qt(e)?e:Gt(),o=t._[n];if(!o)return!1;if(he(o)){const e=await(async e=>{try{return await(await fetch(e)).json()}catch(e){return console.error(e),!1}})(o);if(!e)return!1;o=e}return t.u=o,Ut(n),!0},Yn=()=>{let e=c.o.i.language.rtl,t=c.oe.Ce;e&&t&&(He(e)||(e=[e]),A(e,c.o.l)?x(t,"cc--rtl"):ke(t,"cc--rtl"))},Ae=()=>{const e=c.oe;if(e.Ce)return;e.Ce=m(T),e.Ce.id="cc-main",e.Ce.setAttribute("data-nosnippet",""),Yn();let t=c.o.i.root;t&&he(t)&&(t=document.querySelector(t)),(t||e.$e.body).appendChild(e.Ce)},qn=e=>Xe((()=>localStorage.removeItem(e))),bn=(e,t)=>{if(t instanceof RegExp)return e.filter((e=>t.test(e)));{const n=Bn(e,t);return n>-1?[e[n]]:[]}},Gn=e=>{const{hostname:t,protocol:n}=location,{name:o,path:s,domain:a,sameSite:i,useLocalStorage:r}=c.t.cookie,l=e?(()=>{const e=c.o.S,t=e?new Date-e:0;return 864e5*fn()-t})():864e5*fn(),d=new Date;d.setTime(d.getTime()+l),c.o.p.expirationTime=d.getTime();const u=JSON.stringify(c.o.p);let h=o+"="+encodeURIComponent(u)+(0!==l?"; expires="+d.toUTCString():"")+"; Path="+s+"; SameSite="+i;var f,m;A(t,".")&&(h+="; Domain="+a),"https:"===n&&(h+="; Secure"),r?(f=o,m=u,Xe((()=>localStorage.setItem(f,m)))):document.cookie=h,c.o.p},Lt=(e,t,n)=>{if(0===e.length)return;const o=n||c.t.cookie.domain,s=t||c.t.cookie.path,a="www."===o.slice(0,4),i=a&&o.substring(4),r=(e,t)=>{document.cookie=e+"=; path="+s+(t?"; domain=."+t:"")+"; expires=Thu, 01 Jan 1970 00:00:01 GMT;"};for(const t of e)r(t),r(t,o),a&&r(t,i)},Un=e=>{const t=e||c.t.cookie.name,n=c.t.cookie.useLocalStorage;return((e,t)=>{let n;return n=Xe((()=>JSON.parse(t?e:decodeURIComponent(e))),!0)||{},n})(n?(o=t,Xe((()=>localStorage.getItem(o)))||""):Wt(t,!0),n);var o},Wt=(e,t)=>{const n=document.cookie.match("(^|;)\\s*"+e+"\\s*=\\s*([^;]+)");return n?t?n.pop():e:""},Wn=e=>{const t=document.cookie.split(/;\s*/),n=[];for(const o of t){let t=o.split("=")[0];e?Xe((()=>{e.test(t)&&n.push(t)})):n.push(t)}return n},Vt=(e,t=[])=>{((e,t)=>{const{O:n,R:o,B:s,N:a,Z:i,X:r}=c.o;let l=[];if(e){He(e)?l.push(...e):he(e)&&(l="all"===e?n:[e]);for(const e of n)i[e]=A(l,e)?ce(r[e]):[]}else l=o,a&&(l=(()=>{const e=c.oe.se;if(!e)return[];let t=[];for(let n in e)e[n].checked&&t.push(n);return t})());l=l.filter((e=>!A(n,e)||!A(t,e))),l.push(...s),xn(l)})(e,t),(e=>{const t=c.o,{Z:n,B:o,Y:s,X:a,O:i}=t,r=i;t.te=ge(s);for(const e of r){const t=a[e],c=ce(t),i=n[e]&&n[e].length>0,r=A(o,e);if(0!==c.length){if(s[e]=[],r)s[e].push(...c);else if(i){const t=n[e];s[e].push(...t)}else s[e]=[];s[e]=Ft(s[e])}}})(),(()=>{const e=c.o;e.L=c.t.mode===Ge&&e.D?st(e.G,e.R):st(e.R,e.p.categories);let t=e.L.length>0,n=!1;for(const t of e.O)e.ee[t]=st(e.Y[t],e.te[t]),e.ee[t].length>0&&(n=!0);const o=c.oe.se;for(const t in o)o[t].checked=A(e.R,t);for(const t of e.O){const n=c.oe.ae[t],o=e.Y[t];for(const e in n)n[e].checked=A(o,e)}e.C||(e.C=new Date),e.M||(e.M="10000000-1000-4000-8000-100000000000".replace(/[018]/g,(e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16)))),e.p={categories:ge(e.R),revision:c.t.revision,data:e.h,consentTimestamp:e.C.toISOString(),consentId:e.M,services:ge(e.Y)};let s=!1;const a=t||n;(e.D||a)&&(e.D&&(e.D=!1,s=!0),e.S=e.S?new Date:e.C,e.p.lastConsentTimestamp=e.S.toISOString(),Gn(),c.t.autoClearCookies&&(s||a)&&(e=>{const t=c.o,n=Wn(),o=(e=>{const t=c.o;return(e?t.O:t.L).filter((e=>{const n=t.P[e];return!!n&&!n.readOnly&&!!n.autoClear}))})(e);for(const e in t.ee)for(const o of t.ee[e]){const s=t.X[e][o].cookies;if(!A(t.Y[e],o)&&s)for(const e of s){const t=bn(n,e.name);Lt(t,e.path,e.domain)}}for(const s of o){const o=t.P[s].autoClear,c=o&&o.cookies||[],a=A(t.L,s),i=!A(t.R,s),r=a&&i;if(e?i:r){o.reloadPage&&r&&(t.j=!0);for(const e of c){const t=bn(n,e.name);Lt(t,e.path,e.domain)}}}})(s),Et()),s&&(le(c.re.ie),le(c.re.le),c.t.mode===An)||(a&&le(c.re.de),e.j&&(e.j=!1,location.reload()))})()},Vn=e=>{const t=c.o.D?[]:c.o.R;return A(t,e)},Io=(e,t)=>{const{O:n,X:o}=c.o;if(!(e&&t&&he(t)&&A(n,t)&&0!==ce(o[t]).length))return!1;((e,t)=>{const n=c.o,{X:o,Z:s,N:a}=n,i=c.oe.ae[t]||{},r=c.oe.se[t]||{},l=ce(o[t]);if(s[t]=[],he(e)){if("all"===e){if(s[t].push(...l),a)for(let e in i)i[e].checked=!0,nt(i[e])}else if(A(l,e)&&s[t].push(e),a)for(let t in i)i[t].checked=e===t,nt(i[t])}else if(He(e))for(let n of l){const o=A(e,n);o&&s[t].push(n),a&&(i[n].checked=o,nt(i[n]))}const d=0===s[t].length;n.R=d?n.R.filter((e=>e!==t)):Ft([...n.R,t]),a&&(r.checked=!d,nt(r))})(e,t),Vt()},Jn=(e,t)=>{const n=c.o.D?[]:c.o.Y[t];return A(n,e)},No=e=>""!==Wt(e,!0),Xn=(e,t,n)=>{let o=[];const s=e=>{if(he(e)){let t=Wt(e);""!==t&&o.push(t)}else o.push(...Wn(e))};if(He(e))for(let t of e)s(t);else s(e);Lt(o,t,n)},Jt=e=>{const{oe:t,o:n}=c;if(!n.k){if(!n.T){if(!e)return;Yt(Ke,Ae)}n.k=!0,n.U=lt(),n.v&&In(!0),On(t.he,1),x(t.ye,Nt),y(t.he,ae,"false"),setTimeout((()=>{re(c.oe.be)}),100),le(c.re.fe,Rt)}},Kn=()=>{const{oe:e,o:t,re:n}=c;t.k&&(t.k=!1,t.v&&In(),re(e.Ke,!0),ke(e.ye,Nt),y(e.he,ae,"true"),re(t.U),t.U=null,le(n._e,Rt))},Zn=()=>{const e=c.o;e.A||(e.N||Fe(Ke,Ae),e.A=!0,e.k?e.$=lt():e.U=lt(),On(c.oe.we,2),x(c.oe.ye,$t),y(c.oe.we,ae,"false"),setTimeout((()=>{re(c.oe.ve)}),100),le(c.re.fe,Pt))},zn=()=>{const e=c.o;e.A&&(e.A=!1,(()=>{const e=Xt(),t=c.o.P,n=c.oe.se,o=c.oe.ae,s=e=>A(c.o.G,e);for(const c in n){const a=!!t[c].readOnly;n[c].checked=a||(e?Vn(c):s(c));for(const t in o[c])o[c][t].checked=a||(e?Jn(t,c):s(c))}})(),re(c.oe.Ge,!0),ke(c.oe.ye,$t),y(c.oe.we,ae,"true"),e.k?(re(e.$),e.$=null):(re(e.U),e.U=null),le(c.re._e,Pt))};var Ke={show:Jt,hide:Kn,showPreferences:Zn,hidePreferences:zn,acceptCategory:Vt};const $o=async(e,t)=>{if(!qt(e))return!1;const n=c.o;return!(e===Gt()&&!0!==t||!await jn(e)||(Ut(e),n.T&&Yt(Ke,Ae),n.N&&Fe(Ke,Ae),Yn(),0))},Ro=()=>{const{F:e,Y:t}=c.o,{accepted:n,rejected:o}=(()=>{const{D:e,R:t,O:n}=c.o;return{accepted:t,rejected:e?[]:n.filter((e=>!A(t,e)))}})();return ge({acceptType:e,acceptedCategories:n,rejectedCategories:o,acceptedServices:t,rejectedServices:Do()})},Po=(e,t)=>{let n=document.querySelector('script[src="'+e+'"]');return new Promise((o=>{if(n)return o(!0);if(n=m("script"),rt(t))for(const e in t)y(n,e,t[e]);n.onload=()=>o(!0),n.onerror=()=>{n.remove(),o(!1)},n.src=e,h(document.head,n)}))},Fo=e=>{let t,n=e.value,o=e.mode,s=!1;const a=c.o;if("update"===o){a.h=t=Qn("data");const e=typeof t==typeof n;if(e&&"object"==typeof t){!t&&(t={});for(let e in n)t[e]!==n[e]&&(t[e]=n[e],s=!0)}else!e&&t||t===n||(t=n,s=!0)}else t=n,s=!0;return s&&(a.h=t,a.p.data=t,Gn(!0)),s},Qn=(e,t)=>{const n=Un(t);return e?n[e]:n},Ho=e=>{const t=c.t,n=c.o.i;return e?t[e]||n[e]:{...t,...n,cookie:{...t.cookie}}},Xt=()=>!c.o.D,eo=async e=>{const{o:t,t:n,re:o}=c,s=window;if(!s._ccRun){if(s._ccRun=!0,(e=>{const{oe:t,t:n,o:o}=c,s=n,a=o,{cookie:i}=s,r=c.ce,l=e.cookie,d=e.categories,u=ce(d)||[],h=navigator,f=document;t.$e=f,t.ye=f.documentElement,i.domain=location.hostname,a.i=e,a.P=d,a.O=u,a._=e.language.translations,a.v=!!e.disablePageInteraction,r.ie=e.onFirstConsent,r.le=e.onConsent,r.de=e.onChange,r._e=e.onModalHide,r.fe=e.onModalShow,r.ue=e.onModalReady;const{mode:m,autoShow:p,lazyHtmlGeneration:g,autoClearCookies:b,revision:y,manageScriptTags:v,hideFromBots:C}=e;m===Ge&&(s.mode=m),"boolean"==typeof b&&(s.autoClearCookies=b),"boolean"==typeof v&&(s.manageScriptTags=v),"number"==typeof y&&y>=0&&(s.revision=y,a.V=!0),"boolean"==typeof p&&(s.autoShow=p),"boolean"==typeof g&&(s.lazyHtmlGeneration=g),!1===C&&(s.hideFromBots=!1),!0===s.hideFromBots&&h&&(a.J=h.userAgent&&/bot|crawl|spider|slurp|teoma/i.test(h.userAgent)||h.webdriver),rt(l)&&(s.cookie={...i,...l}),s.autoClearCookies,a.V,s.manageScriptTags,(e=>{const{P:t,X:n,Y:o,Z:s,B:a}=c.o;for(let i of e){const e=t[i],r=e.services||{},l=rt(r)&&ce(r)||[];n[i]={},o[i]=[],s[i]=[],e.readOnly&&(a.push(i),o[i]=l),c.oe.ae[i]={};for(let e of l){const t=r[e];t.Se=!1,n[i][e]=t}}})(u),(()=>{if(!c.t.manageScriptTags)return;const e=c.o,t=Ht(document,"script["+ct+"]");for(const n of t){let t=ot(n,ct),o=n.dataset.service||"",s=!1;if(t&&"!"===t.charAt(0)&&(t=t.slice(1),s=!0),"!"===o.charAt(0)&&(o=o.slice(1),s=!0),A(e.O,t)&&(e.ne.push({Me:n,xe:!1,ke:s,De:t,Te:o}),o)){const n=e.X[t];n[o]||(n[o]={Se:!1})}}})(),Ut((()=>{const e=c.o.i.language.autoDetect;if(e){const t={browser:navigator.language,document:document.documentElement.lang},n=qt(t[e]);if(n)return n}return Gt()})())})(e),t.J)return;(()=>{const e=c.o,t=c.t,n=Un(),{categories:o,services:s,consentId:a,consentTimestamp:i,lastConsentTimestamp:r,data:l,revision:d}=n,u=He(o);e.p=n,e.M=a;const h=!!a&&he(a);e.C=i,e.C&&(e.C=new Date(i)),e.S=r,e.S&&(e.S=new Date(r)),e.h=void 0!==l?l:null,e.V&&h&&d!==t.revision&&(e.I=!1),e.D=!(h&&e.I&&e.C&&e.S&&u),t.cookie.useLocalStorage&&!e.D&&(e.D=(new Date).getTime()>(n.expirationTime||0),e.D&&qn(t.cookie.name)),e.D,(()=>{const e=c.o;for(const t of e.O){const n=e.P[t];if(n.readOnly||n.enabled&&e.i.mode===Ge){e.G.push(t);const n=e.X[t]||{};for(let o in n)e.Y[t].push(o)}}})(),e.D?t.mode===Ge&&(e.R=[...e.G]):(e.Y={...e.Y,...s},xn([...e.B,...o])),e.Z={...e.Y}})();const i=Xt();if(!await jn())return!1;if(Mn(null,a=Ke,Fe,Ae),c.o.D&&Yt(a,Ae),c.t.lazyHtmlGeneration||Fe(a,Ae),n.autoShow&&!i&&Jt(!0),i)return Et(),le(o.le);n.mode===Ge&&Et(t.G)}var a},jo=e=>{const{Ce:t,ye:n}=c.oe,{name:o,path:s,domain:a,useLocalStorage:i}=c.t.cookie;e&&(i?qn(o):Xn(o,s,a));for(const{pe:e,me:t,ge:n}of c.o.m)e.removeEventListener(t,n);t&&t.remove(),n&&n.classList.remove(_t,$t,Nt);const r=new Dn;for(const e in c)c[e]=r[e];window._ccRun=!1},Yo=Object.freeze(Object.defineProperty({__proto__:null,acceptCategory:Vt,acceptService:Io,acceptedCategory:Vn,acceptedService:Jn,eraseCookies:Xn,getConfig:Ho,getCookie:Qn,getUserPreferences:Ro,hide:Kn,hidePreferences:zn,loadScript:Po,reset:jo,run:eo,setCookieData:Fo,setLanguage:$o,show:Jt,showPreferences:Zn,validConsent:Xt,validCookie:No},Symbol.toStringTag,{value:"Module"})),qo={root:"main",guiOptions:{consentModal:{layout:"box",position:"top right",equalWeightButtons:!0,flipButtons:!1},preferencesModal:{layout:"box",position:"right",equalWeightButtons:!0,flipButtons:!1}},categories:{necessary:{readOnly:!0},functionality:{},analytics:{},marketing:{}},language:{default:"en",autoDetect:"browser",rtl:"ar",translations:{}}},De=to(qo);function to(e){if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let n in e){let o=e[n];t[n]=to(o)}return t}const Kt=e=>{if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let n in e){let o=e[n];t[n]=Kt(o)}return t},R={_PLAYGROUND_READY:"pg:ready",_INIT:"cc:onInit",_RESET:"cc:reset",_ON_CONSENT:"cc:onConsent",_ON_CHANGE:"cc:onChange",_ON_MODAL_SHOW:"cc:onModalShow"},Zt=e=>{window.dispatchEvent(new CustomEvent(e))},U=(e,t)=>{window.addEventListener(e,t)},I=(e,t,n)=>{e.addEventListener(t,n)},v=e=>document.getElementById(e),mt="nscBaraCookieBannerState",V={_cookieConsentConfig:De,_currLanguage:De.language.default,_enabledTranslations:["en"],_enabledCategories:["necessary","analytics"],_disableTransitions:!1,_theme:"default-light",_lastNonBarPosition:"",_lastBarPosition:"",_demoRevision:34},B=()=>{const e=localStorage.getItem(mt);if(e)try{return JSON.parse(e)}catch{}return Kt(V)},Go=()=>{const e=window.CookieConsent;e.validConsent()&&e.acceptCategory([]),e.eraseCookies(e.getConfig("cookie").name)},We=()=>{Go(),localStorage.removeItem(mt),window.CookieConsent.reset(!0),window.CookieConsent.run(De),Zt(R._RESET)},ie=e=>{try{e&&localStorage.setItem(mt,JSON.stringify(e))}catch(e){console.error("Failed to save state:",e)}};function Uo(){let e=localStorage.getItem(mt);if(e)try{e=JSON.parse(e);for(let t in V)if(typeof e[t]!=typeof V[t])return console.warn(`Beautiful Cookie Banner - RESETTING banner state because of key: ${t}: typeof savedState[key] !== typeof defaultState[key]. ${typeof e[t]} vs. ${typeof V[t]}`),We();if(e._demoRevision!==V._demoRevision)return console.warn(`Beautiful Cookie Banner - RESETTING banner state because of: savedState._demoRevision !== defaultState._demoRevision. ${e._demoRevision} vs. ${V._demoRevision}`),We()}catch(e){return console.warn(`Beautiful Cookie Banner - RESETTING banner state because of error : ${e.message}`),We()}}const zt=e=>{const t=Kt(e._cookieConsentConfig),n=t.language.translations;delete t.root,delete t.cookie,t.disablePageInteraction||delete t.disablePageInteraction;for(const t in n)if(e._enabledTranslations.includes(t)){const o=n[t];delete o.consentModal.label;const s=o.preferencesModal,c=s.sections.filter((t=>(delete t.cookieTable,!t.linkedCategory||e._enabledCategories.includes(t.linkedCategory))));s.sections=c}else delete n[t];"ar"in n||delete t.language.rtl;for(const n in t.categories)e._enabledCategories.includes(n)||delete t.categories[n];return t},Be=(e,t)=>{const n=window.CookieConsent;n.reset();const o=zt(e);n.run(o).then((()=>{1===t&&n.show(!0),2===t&&n.showPreferences()}))};function Wo(e,t){const n=document.getElementById(e);t.forEach((e=>{const t=document.createElement("option");t.value=e,t.textContent=e,n.appendChild(t)}))}function Vo(e){const t=document.getElementById(e),n=B()._cookieConsentConfig.language;Object.keys(n.translations).forEach((e=>{const n=document.createElement("label"),o=document.createElement("input"),s=document.createElement("span"),c=document.createElement("span");o.setAttribute("class","custom-input"),o.setAttribute("type","checkbox"),o.setAttribute("name","language-code"),o.setAttribute("value",e),s.setAttribute("class","label"),s.textContent=Jo(e),c.setAttribute("class","tick"),s.appendChild(c),n.appendChild(o),n.appendChild(s),t.appendChild(n)}))}function Jo(e){const t=new Intl.DisplayNames("en-US",{type:"language"}).of(e);return t.charAt(0).toUpperCase()+t.slice(1)}function Xo(){const e=document.getElementById("bannerCategoriesSelect"),t=B()._cookieConsentConfig.categories;Object.keys(t).forEach((n=>{const o=document.createElement("label"),s=document.createElement("input"),c=document.createElement("span"),a=document.createElement("span");s.setAttribute("class","custom-input category-input"),s.setAttribute("type","checkbox"),s.setAttribute("value",n),t[n].readOnly&&s.setAttribute("checked","checked"),s.setAttribute("disabled","disabled"),c.setAttribute("class","label"),c.textContent=n,a.setAttribute("class","tick"),t[n].readOnly&&a.appendChild(Cn("M16.5 11V8h0c0-2.8-.5-5-4.5-5S7.5 5.2 7.5 8h0v3")),t[n].enabled&&a.appendChild(Cn("M5 12l5 5l10 -10")),c.appendChild(a),o.appendChild(s),o.appendChild(c),e.appendChild(o)}))}function Cn(e){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("height","16"),t.setAttribute("viewBox","0 0 24 24"),t.setAttribute("width","16");var n=document.createElementNS("http://www.w3.org/2000/svg","g");n.setAttribute("fill","none"),n.setAttribute("stroke","#000"),n.setAttribute("stroke-linecap","round"),n.setAttribute("stroke-linejoin","round"),n.setAttribute("stroke-width","2");var o=document.createElementNS("http://www.w3.org/2000/svg","rect");o.setAttribute("height","10"),o.setAttribute("rx","2"),o.setAttribute("ry","2"),o.setAttribute("width","16"),o.setAttribute("x","4"),o.setAttribute("y","11"),n.appendChild(o);var s=document.createElementNS("http://www.w3.org/2000/svg","path");return s.setAttribute("d",e),n.appendChild(s),t.appendChild(n),t}U(R._PLAYGROUND_READY,(()=>{const e=document.querySelectorAll(".category-input"),t=B();no(t._enabledCategories);for(const t of e)I(t,"change",Ko)}));const Ko=e=>{const t=e.target,n=t.checked,o=t.value,s=B();s._enabledCategories=[...new Set(n?[...s._enabledCategories,o]:s._enabledCategories.filter((e=>e!==o)))],ie(s),Be(s,1)},no=e=>{const t=document.querySelectorAll(".category-input");for(const n of t)n.checked=e.includes(n.value)};U(R._RESET,(()=>{no(V._enabledCategories)}));let Tt=document.querySelectorAll('input[name="language-code"]'),Zo=v("translations-section"),At=v("edit-translations-btn"),zo=At.textContent;function oo(e){for(const t of Tt)t.checked=e.includes(t.value)}function yn(e){const t=0===e.length;Zo.classList[t?"add":"remove"]("no-translations-error"),At.disabled=t,At.textContent=t?"Translation required":zo}function ue(e,t){return(t||B())._enabledTranslations.includes(e)}U(R._PLAYGROUND_READY,(()=>{Tt=document.querySelectorAll('input[name="language-code"]');let e=B();(!e||!e._enabledTranslations||!Array.isArray(e._enabledTranslations))&&(console.error("invalid state for banner 2. Resetting it."),We(),e=B());const t=e._enabledTranslations;oo(t),yn(t),Tt.forEach((e=>{I(e,"change",(()=>{const t=e.value,n=e.checked,o=B(),s=o._enabledTranslations,c=o._cookieConsentConfig.language,a=s.includes(t);n?!a&&s.push(t):a&&(o._enabledTranslations=o._enabledTranslations.filter((e=>e!==t))),yn(o._enabledTranslations),en(o._enabledTranslations);const i=et(c.autoDetect),r=i?tt(c.autoDetect):"",l=ue(r,o)&&r||ue(c.default,o)&&c.default||o._enabledTranslations[0]||"";i&&io(l===r),ue(c.default,o)||(c.default=l,Qt(l)),xe(l,o),ie(o)}))}))})),U(R._RESET,(()=>{oo(V._enabledTranslations)}));const Qo=["document","browser"];let Dt=[];const es=v("current-active-language"),Bt=v("auto-language"),vn=v("detected-language"),so=v("translation-found"),ut=v("autodetect-mode"),Ze=v("default-language");function ze(e,t){if(e&&"string"==typeof e){return io(ue(e,t||B())),void(vn.textContent=e)}vn.textContent="-",so.textContent="-"}function ao(e){Bt.checked=e}function Qe(e){const t=et(e);t&&(ut.value=e),ut.disabled=!t}function Qt(e){e||(Ze.value="disabled"),Dt.includes(e)&&(Ze.value=e)}function en(e){const t=Ze.children;for(const n of t)n.style.display=e.includes(n.value)?"":"none"}function io(e){so.textContent=e?"true":"false"}function et(e){return Qo.includes(e)}function ts(){return navigator.language.slice(0,2)}function ns(){return document.documentElement.lang.slice(0,2)}function tt(e){return"browser"===e?ts():"document"===e?ns():""}function xe(e,t){const n=t||B(),o=ue(e,n)?e:"-";es.textContent=o,"-"!==o?!1!==t&&(v("cc-main")?Be(n,1):setTimeout((()=>{Be(n,1)}),100)):window.CookieConsent&&window.CookieConsent.reset()}U(R._PLAYGROUND_READY,(async()=>{const e=B(),t=e._cookieConsentConfig.language;Dt=Object.keys(t.translations),Wo("default-language",Dt);const n=t.autoDetect,o=et(n),s=tt(n),c=o&&ue(s,e)?s:t.default;o?(Qe(n),ze(s,e)):Qe(""),ao(o),en(e._enabledTranslations),Qt(t.default),xe(c,!1)})),U(R._RESET,(()=>{const e=De.language,t=De.language.default;Qt(t),Qe(e.autoDetect),ze(t,V),ao(!0),en(V._enabledTranslations),xe(t,V)})),I(Bt,"change",(()=>{const e=B(),t=e._cookieConsentConfig.language;if(Bt.checked){t.autoDetect=t.autoDetect||De.language.autoDetect;const n=tt(t.autoDetect);ze(n,e),ue(n,e)&&xe(n,e),Qe(t.autoDetect)}else t.autoDetect=void 0,ze("",e),Qe(""),xe(t.default,e);ie(e)})),I(ut,"change",(()=>{const e=ut.value;if(et(e)){const t=B();t._cookieConsentConfig.language.autoDetect=e;const n=tt(e);ze(n),ue(n,t)&&xe(n,t),ie(t)}})),I(Ze,"change",(()=>{const e=Ze.value,t=B(),n=t._cookieConsentConfig.language;ue(e,t)&&(n.default=e,(!et(n.autoDetect)||!ue(tt(n.autoDetect),t))&&xe(e,t),ie(t))}));const D={inert:":not([inert]):not([inert] *)",negTabIndex:':not([tabindex^="-"])',disabled:":not(:disabled)"};var os=[`a[href]${D.inert}${D.negTabIndex}`,`area[href]${D.inert}${D.negTabIndex}`,`input:not([type="hidden"]):not([type="radio"])${D.inert}${D.negTabIndex}${D.disabled}`,`input[type="radio"]${D.inert}${D.negTabIndex}${D.disabled}`,`select${D.inert}${D.negTabIndex}${D.disabled}`,`textarea${D.inert}${D.negTabIndex}${D.disabled}`,`button${D.inert}${D.negTabIndex}${D.disabled}`,`details${D.inert} > summary:first-of-type${D.negTabIndex}`,`iframe${D.inert}${D.negTabIndex}`,`audio[controls]${D.inert}${D.negTabIndex}`,`video[controls]${D.inert}${D.negTabIndex}`,`[contenteditable]${D.inert}${D.negTabIndex}`,`[tabindex]${D.inert}${D.negTabIndex}`];function kn(e){(e.querySelector("[autofocus]")||e).focus()}function ss(e){const t=Ve(e,!0);return[t,t?Ve(e,!1)||t:null]}function Ve(e,t){if(t&&En(e))return e;if(is(e))if(e.shadowRoot){let n=wn(e.shadowRoot,t);for(;n;){const e=Ve(n,t);if(e)return e;n=_n(n,t)}}else if("slot"===e.localName){const n=e.assignedElements({flatten:!0});t||n.reverse();for(const e of n){const n=Ve(e,t);if(n)return n}}else{let n=wn(e,t);for(;n;){const e=Ve(n,t);if(e)return e;n=_n(n,t)}}return!t&&En(e)?e:null}function wn(e,t){return t?e.firstElementChild:e.lastElementChild}function _n(e,t){return t?e.nextElementSibling:e.previousElementSibling}const as=e=>!(!e.matches("details:not([open]) *")||e.matches("details>summary:first-of-type"))||!(e.offsetWidth||e.offsetHeight||e.getClientRects().length),En=e=>!e.shadowRoot?.delegatesFocus&&(e.matches(os.join(","))&&!as(e));function is(e){return(!e.shadowRoot||"-1"!==e.getAttribute("tabindex"))&&!e.matches(":disabled,[hidden],[inert]")}function tn(e=document){const t=e.activeElement;return t?t.shadowRoot?tn(t.shadowRoot)||document.activeElement:t:null}function cs(e,t){const[n,o]=ss(e);if(!n)return t.preventDefault();const s=tn();t.shiftKey&&s===n?(o.focus(),t.preventDefault()):!t.shiftKey&&s===o&&(n.focus(),t.preventDefault())}class co{$el;id;previouslyFocused;shown;constructor(e){this.$el=e,this.id=this.$el.getAttribute("data-a11y-dialog")||this.$el.id,this.previouslyFocused=null,this.shown=!1,this.maintainFocus=this.maintainFocus.bind(this),this.bindKeypress=this.bindKeypress.bind(this),this.handleTriggerClicks=this.handleTriggerClicks.bind(this),this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.$el.setAttribute("aria-hidden","true"),this.$el.setAttribute("aria-modal","true"),this.$el.setAttribute("tabindex","-1"),this.$el.hasAttribute("role")||this.$el.setAttribute("role","dialog"),document.addEventListener("click",this.handleTriggerClicks,!0)}destroy(){return this.hide(),document.removeEventListener("click",this.handleTriggerClicks,!0),this.$el.replaceWith(this.$el.cloneNode(!0)),this.fire("destroy"),this}show(e){return this.shown||(this.shown=!0,this.$el.removeAttribute("aria-hidden"),this.previouslyFocused=tn(),"BODY"===this.previouslyFocused?.tagName&&e?.target&&(this.previouslyFocused=e.target),"focus"===e?.type?this.maintainFocus(e):kn(this.$el),document.body.addEventListener("focus",this.maintainFocus,!0),this.$el.addEventListener("keydown",this.bindKeypress,!0),this.fire("show",e)),this}hide(e){return this.shown?(this.shown=!1,this.$el.setAttribute("aria-hidden","true"),this.previouslyFocused?.focus?.(),document.body.removeEventListener("focus",this.maintainFocus,!0),this.$el.removeEventListener("keydown",this.bindKeypress,!0),this.fire("hide",e),this):this}on(e,t,n){return this.$el.addEventListener(e,t,n),this}off(e,t,n){return this.$el.removeEventListener(e,t,n),this}fire(e,t){this.$el.dispatchEvent(new CustomEvent(e,{detail:t,cancelable:!0}))}handleTriggerClicks(e){const t=e.target;t.closest(`[data-a11y-dialog-show="${this.id}"]`)&&this.show(e),(t.closest(`[data-a11y-dialog-hide="${this.id}"]`)||t.closest("[data-a11y-dialog-hide]")&&t.closest('[aria-modal="true"]')===this.$el)&&this.hide(e)}bindKeypress(e){if(document.activeElement?.closest('[aria-modal="true"]')!==this.$el)return;let t=!1;try{t=!!this.$el.querySelector('[popover]:not([popover="manual"]):popover-open')}catch{}"Escape"===e.key&&"alertdialog"!==this.$el.getAttribute("role")&&!t&&(e.preventDefault(),this.hide(e)),"Tab"===e.key&&cs(this.$el,e)}maintainFocus(e){e.target.closest('[aria-modal="true"], [data-a11y-dialog-ignore-focus-trap]')||kn(this.$el)}}function Sn(){for(const e of document.querySelectorAll("[data-a11y-dialog]"))new co(e)}async function ro(){const e=v("nscBarErrorMessage");e.style.display="none";const t=v("downloadConfigBtn");t.classList.add("nscbutton--loading");const n=B(),o=zt(n);"true"===localStorage.getItem("nscDebugLog")&&console.log("BCB: SAVING DEBUG message",window.restURL,window.nonce,n,o);const s={config:o,localState:n},c=await fetch(`${window.restURL}beautiful-and-responsive-cookie-consent/v1/newBanner/save`,{method:"POST",mode:"cors",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json",_wpnonce:window.nonce,"X-WP-Nonce":window.nonce},redirect:"follow",referrerPolicy:"no-referrer",body:JSON.stringify(s)});if(t.classList.remove("nscbutton--loading"),c.status>204){let t;try{t=await c.json()}catch(e){console.error("BCB: Error parsing response as JSON:",e),t={message:`response not json: ${e.message}`,error:[]}}let n=`${c.status}: ${t.message}`;Array.isArray(t.error)&&t.error.forEach((e=>{n=`${n}: ${e}, `})),e.innerText=`${n}`,e.style.display=""}}typeof document<"u"&&("loading"===document.readyState?document.addEventListener("DOMContentLoaded",Sn):Sn());const rs=v("edit-translations-dialog"),ls=new co(rs),Me=v("editor-language-codes"),lo=v("consent-modal-title"),uo=v("consent-modal-description"),fo=v("consent-modal-accept-btn"),po=v("close-icon-label"),go=v("consent-modal-reject-btn"),ho=v("consent-modal-manage-btn"),mo=v("editing"),bo=v("pm-title"),Co=v("pm-close-icon-label"),yo=v("pm-accept-btn"),vo=v("pm-reject-btn"),ko=v("pm-save-btn"),wo=v("pm-service-counter-label"),Ln=v("edit-translations-btn"),us=v("save-translation-config-btn"),ds=v("add-section-btn"),nn=v("pm-sections"),fs=v("sections-counter");let ps=[],de="",Re=0,xt=null;I(Ln,"click",(()=>{Ln.disabled||(xt=B(),!1!==hs()&&(ls.show(),de=Me.value))})),I(ds,"click",(()=>{Cs(So())})),I(us,"click",(()=>{const e=Me.value,t=B();t._cookieConsentConfig.language.translations[e]=ys(),ie(t),Be(t,1),window.CookieConsent.setLanguage(e),ro()})),I(Me,"change",(()=>{de=Me.value,Eo(de),_o(),gs()&&window.CookieConsent.setLanguage(de)}));const gs=()=>document.documentElement.classList.contains("show--consent");function hs(e){const t=B();if(0===(e=e||t._enabledTranslations).length)return!1;bs(ps,e)||(e.includes(de)||(de=e[0],Eo(de)),ms(e),_o(t))}function _o(e){const t=e||B(),n=t._cookieConsentConfig.language.translations[de],{consentModal:o,preferencesModal:s}=n;lo.value=o.title||"",uo.value=o.description||"",fo.value=o.acceptAllBtn||"",po.value=o.closeIconLabel||"",go.value=o.acceptNecessaryBtn||"",ho.value=o.showPreferencesBtn||"",mo.value=o.footer||"",bo.value=s.title||"",Co.value=s.closeIconLabel||"",yo.value=s.acceptAllBtn||"",vo.value=s.acceptNecessaryBtn||"",ko.value=s.savePreferencesBtn||"",wo.value=s.serviceCounterLabel||"";const c=s.sections||[],a=[];for(const e of c)(!e.linkedCategory||t._enabledCategories.includes(e.linkedCategory))&&a.push(So(e));Re=a.length,Mt(Re),nn.replaceChildren(...a)}function ms(e){const t=[];for(const n of e){const e=document.createElement("option");e.value=n,e.textContent=n,e.className=`translation-btn--${n}`,t.push(e)}Me.replaceChildren(...t),Me.value=de}function Eo(e){de=e,Me.setAttribute("data-current-translation",e)}function bs(e,t){return JSON.stringify(e.sort())===JSON.stringify(t.sort())}function Cs(e){nn.appendChild(e)}function So(e){const t=document.createElement("li");t.className="pm-section";const n=document.createElement("textarea");n.value=e?.title||"",n.placeholder="Title",n.className="pm-section-title small-textarea",t.appendChild(n);const o=document.createElement("textarea");o.value=e?.description||"",o.placeholder="Description",o.className="pm-section-description",t.appendChild(o);const s=document.createElement("div");s.className="pm-section-label-btn-container";const c=document.createElement("label"),a=document.createElement("span"),i=document.createElement("span"),r=document.createElement("span"),l=document.createElement("select");c.className="select-label",l.className="pm-section-linked-category",r.className="arrow-icon",a.textContent="Linked category",i.className="select-input";const d=e?.linkedCategory,u=["",...xt._enabledCategories];for(const e of u){const t=document.createElement("option");t.value=e,t.textContent=e,e===d&&xt._enabledCategories.includes(d)?(t.selected=!0,t.textContent=d):e||(t.selected=!0,t.textContent="—"),l.appendChild(t)}i.appendChild(l),i.appendChild(r),c.appendChild(a),c.appendChild(i),s.appendChild(c);const h=document.createElement("button");return h.textContent="Delete section",h.className="styled-btn pm-section__delete-btn",I(h,"click",(()=>{Re-=1,t.remove(),Mt(Re)})),s.appendChild(h),t.appendChild(s),Re+=1,Mt(Re),t}function Mt(e){fs.textContent=e}function ys(){const e={};e.title=lo.value,e.description=uo.value,e.closeIconLabel=po.value,e.acceptAllBtn=fo.value,e.acceptNecessaryBtn=go.value,e.showPreferencesBtn=ho.value,e.footer=mo.value;const t={};t.title=bo.value,t.closeIconLabel=Co.value,t.acceptAllBtn=yo.value,t.acceptNecessaryBtn=vo.value,t.savePreferencesBtn=ko.value,t.serviceCounterLabel=wo.value,t.sections=[];for(const e of nn.children){const n=e.querySelector(".pm-section-title").value,o=e.querySelector(".pm-section-description").value,s=e.querySelector(".pm-section-linked-category").value,c={title:n,description:o};s&&(c.linkedCategory=s),t.sections.push(c)}return{consentModal:e,preferencesModal:t}}const we="change",G="consentModal",ne="preferencesModal",H={consentModal:{layout:v("cm-layout"),position:v("cm-position"),flipButtons:v("cm-flip"),equalWeightButtons:v("cm-weight")},preferencesModal:{layout:v("pm-layout"),position:v("pm-position"),flipButtons:v("pm-flip"),equalWeightButtons:v("pm-weight")}},vs=["top","middle","bottom"],ks=["left","center","right"];let Ot="",It="";const qe=e=>"top"===e||"bottom"===e;let on=!1;function _e(e,t,n){const o=B();if(e===G){if("layout"===t){const e=Ot.startsWith("bar"),t=o._cookieConsentConfig.guiOptions.consentModal,n=t.position;qe(n)?o._lastBarPosition=n:o._lastNonBarPosition=n,(!e&&qe(n)||e&&!qe(n))&&(Lo(!e),e?qe(n)||(t.position=H[G].position.value=o._lastBarPosition||"bottom"):t.position=H[G].position.value=o._lastNonBarPosition||De.guiOptions.consentModal.position)}if("position"===t){const e=o._cookieConsentConfig.guiOptions.consentModal.position;qe(e)?o._lastBarPosition=e:o._lastNonBarPosition=e}}else"layout"===t&&("box"===It?ft(!0):on&&ft(!1));o._cookieConsentConfig.guiOptions[e][t]=n,ie(o),Be(o,"consentModal"===e?1:2)}function dt(e){const t=window.CookieConsent.getConfig("guiOptions")[e];ws(e,t.layout,t.position),Es(e,t.flipButtons),Ss(e,t.equalWeightButtons)}function ws(e,t,n){H[e].layout.value=t,_s(e,n,t)}function _s(e,t,n){e===ne&&("box"===n?ft(!0):on&&ft(!1)),e===G&&Lo(!n.startsWith("bar")),H[e].position.value=t}function ft(e){on=e,H[ne].position.disabled=e}function Es(e,t){H[e].flipButtons.checked=t}function Ss(e,t){H[e].equalWeightButtons.checked=t}function Tn(e,t){const n=document.createDocumentFragment();function o(e){let t=document.createElement("option");t.text=t.value=e,n.appendChild(t)}return e.forEach((e=>{let n=e;t?t.forEach((t=>{n=e+" "+t,o(n)})):o(n)})),n}function Lo(e){let t;t=e?Tn(vs,ks):Tn(["top","bottom"]),H[G].position.textContent="",H[G].position.appendChild(t)}I(H[G].layout,we,(function(){Ot=this.value,_e(G,"layout",Ot)})),I(H[G].position,we,(function(){_e(G,"position",this.value)})),I(H[G].flipButtons,we,(function(){_e(G,"flipButtons",this.checked)})),I(H[G].equalWeightButtons,we,(function(){_e(G,"equalWeightButtons",this.checked)})),I(H[ne].layout,we,(function(){It=this.value,_e(ne,"layout",It)})),I(H[ne].position,we,(function(){_e(ne,"position",this.value)})),I(H[ne].flipButtons,we,(function(){_e(ne,"flipButtons",this.checked)})),I(H[ne].equalWeightButtons,we,(function(){_e(ne,"equalWeightButtons",this.checked)})),U(R._INIT,(()=>{dt(G),dt(ne)})),U(R._RESET,(()=>{dt(G),dt(ne)}));const Ls=document.querySelectorAll('input[name="theme"]');let Te="";U(R._PLAYGROUND_READY,(()=>{Te=B()._theme,pt(Te);for(const e of Ls)I(e,"change",(()=>{const t=B(),n=e.id;Te=t._theme;const o="cc--darkmode"===n;t._theme=n,ie(t),pt(n),bt(o),window.CookieConsent.show(!0)}))}));const pt=e=>{v(e).checked=!0;const{classList:t}=document.documentElement;t.add(e),Te&&Te!==e&&t.remove(Te),Te=e};U(R._RESET,(()=>pt(V._theme)));const sn="cc--darkmode",Ts="default-light",it=v("darkmode-checkbox");function bt(e){const t=e?"add":"remove";it.checked=e,document.documentElement.classList[t]("cc--darkmode")}U(R._PLAYGROUND_READY,(()=>{bt(B()._theme===sn)})),I(it,"change",(()=>{const e=B(),t=e._theme;document.documentElement.classList.remove(t),e._theme=it.checked?sn:Ts,bt(it.checked),pt(e._theme),ie(e),window.CookieConsent.show(!0)})),U(R._RESET,(()=>{bt(V._theme===sn)}));const gt=v("disablePageInteraction-checkbox");I(gt,"change",(()=>{const e=B();e._cookieConsentConfig.disablePageInteraction=gt.checked,ie(e),Be(e,1)})),U(R._PLAYGROUND_READY,(()=>{gt.checked=!!B()._cookieConsentConfig.disablePageInteraction})),U(R._RESET,(()=>{gt.checked=V._cookieConsentConfig.disablePageInteraction}));const As=v("reset-btn");I(As,"click",(()=>We()));const ht=v("disableTransitions-checkbox"),an="cc--disable-transitions";I(ht,"change",(()=>{const e=B(),t=ht.checked;e._disableTransitions=t,cn(an,t),ie(e),Be(e,1)})),U(R._PLAYGROUND_READY,(()=>{const e=B()._disableTransitions;ht.checked=e,cn(an,e)})),U(R._RESET,(()=>{const e=V._disableTransitions;ht.checked=e,cn(an,e)}));const cn=(e,t)=>{document.body.classList[t?"add":"remove"](e)},Ds=v("downloadConfigBtn");I(Ds,"click",ro),Vo("langInputs"),Xo(),window.CookieConsent=Yo,Uo(),Zt(R._PLAYGROUND_READY),eo(zt(B())).then((()=>{Zt(R._INIT)})); -
beautiful-and-responsive-cookie-consent/trunk/admin/new-banner/index.html
r3130577 r3305665 1 <!DOCTYPE html><html lang=en><head><meta charset=UTF-8><meta content="width=device-width" name=viewport><script> const queryString=window.location.search,urlParams=new URLSearchParams(queryString),url=urlParams.get("plugin_url_encoded");window.restURL=urlParams.get("rest_url_encoded"),window.nonce=urlParams.get("wp_nonce");const headfiles=[{tag:"script",attributes:[{attr:"as",value:"script"},{attr:"type",value:"module"},{attr:"src",value:`${url}admin/new-banner/_astro/index.js`}]},{tag:"link",attributes:[{attr:"rel",value:"stylesheet"},{attr:"href",value:`${url}admin/new-banner/_astro/index.css`}]}],bodyFiles=[{tag:"script",attributes:[{attr:"src",value:`${url}admin/js/iframeResizer/iframeResizer.contentWindow.min.js`}]}];function insertFiles(e,t){for(let r=0;r<t.length;r+=1){let a=document.getElementsByTagName(e)[0],n=document.createElement(t[r].tag);for(let e=0;e<t[r].attributes.length;e+=1)n[t[r].attributes[e].attr]=t[r].attributes[e].value;a.parentNode.insertBefore(n,a)}}insertFiles("script",headfiles)</script></head><body><script>insertFiles("body",bodyFiles)</script><header><h1 class=page-title>Banner 2 Settings</h1><h2 class=page-subtitle>Currently, the options for this banner are somewhat limited, but don't worry — future updates will bring more flexibility. If you have any ideas or features you'd like to see, we'd love to hear from you! Just shoot us an email at info@beautiful-cookie-banner.com.</h2><h2 class=page-subtitle>To access the preference modal, simply apply the class 'nsc-bara-manage-cookie-settings' to any link. Clicking on this link will then open the preferences modal.</h2><button class=nscbutton type=button id=downloadConfigBtn><span class=nscbutton__text>Save Banner Configs</span></button> <a style=padding-left:10px;cursor:pointer onclick="CookieConsent.eraseCookies("cc_cookie"),CookieConsent.show(!0)">show banner again</a><h2 class=page-subtitle id=nscBarErrorMessage style=display:none;background:#d32f2f;color:#e0e0e0;padding:1em>dffd</h2></header><main><section class=categories-section><div class="grid section__body"><div class=sub-section><h4 class=categories-title>Categories</h4><p class=categories-description>Categories can be edited in tab "Categories"</p><div class="custom-inputs custom-inputs--categories" id=bannerCategoriesSelect></div></div><div class="sub-section translations" id=translations-section><h4 class=translations-title>Translations</h4><p class=translations-description>Select the translations to include in your configuration. Languages can be added or removed in tab "Multilanguage".</p><div class=custom-inputs id=langInputs></div><button class=styled-btn type=button id=edit-translations-btn data-a11y-dialog-show=edit-translations-dialog>Edit translations</button><div class=dialog-container id=edit-translations-dialog aria-hidden=true aria-labelledby=dialog-title><div class=dialog-overlay></div><div class=dialog-content role=document><div class=dialog-header><div class=dialog-header--left><h1 class=dialog-title id=dialog-title>Current translation</h1><label for=editor-language-codes class=select-translation><select id=editor-language-codes></select> <span class=arrow-icon></span></label></div><button class="styled-btn dialog-close-btn" type=button data-a11y-dialog-hide aria-label="Close dialog">×</button></div><div class=dialog-body><div class=translations-editor id=editor-container><div class=translation-editor id=translation-editor><div class="editor editor--cm"><h4>Consent modal</h4><textarea id=consent-modal-title placeholder=Title spellcheck=false class=small-textarea></textarea> <textarea id=consent-modal-description placeholder=Description spellcheck=false></textarea> <input id=close-icon-label type=text placeholder="X/Close icon label" spellcheck=false> <input id=consent-modal-accept-btn type=text placeholder="Accept all button" spellcheck=false> <input id=consent-modal-reject-btn type=text placeholder="Reject all button" spellcheck=false> <input id=consent-modal-manage-btn type=text placeholder="Manage preferences button" spellcheck=false><div class=footer-textarea id=textarea-cm-footer><textarea id=editing placeholder=Footer spellcheck=false></textarea></div></div><div class="editor editor--pm"><h4>Preferences modal</h4><textarea id=pm-title placeholder=Title spellcheck=false class=small-textarea></textarea> <input id=pm-close-icon-label type=text placeholder="Close icon label" spellcheck=false> <input id=pm-accept-btn type=text placeholder="Accept all button" spellcheck=false> <input id=pm-reject-btn type=text placeholder="Reject all button" spellcheck=false> <input id=pm-save-btn type=text placeholder="Save preferences button" spellcheck=false> <input id=pm-service-counter-label type=text placeholder="Service counter label" spellcheck=false><div class=pm-sections><h3 class=pm-sections-title>Sections <span id=sections-counter></span></h3><ol id=pm-sections></ol><button class=styled-btn type=button id=add-section-btn>Add section</button></div></div></div></div></div><div class=dialog-footer><button class=styled-btn type=button id=save-translation-config-btn data-a11y-dialog-hide>Save & Preview</button></div></div></div></div><div class="sub-section language-more-options"><h4>Language options</h4><div class=default-language><label for=default-language class=select-label><span>Default lang.</span><span class=select-input> <select id=default-language name=default-language><option value=disabled disabled=disabled selected=selected>—</option></select> <span class=arrow-icon></span></span></label></div><div class=auto-language><div class=checkbox-div><input id=auto-language type=checkbox name=autoLanguage> <label for=auto-language>Auto detect language</label></div><label for=autodetect-mode class="select-label autodetect"><span>Detect from</span><span class=select-input> <select id=autodetect-mode name=autodetect disabled=disabled><option value=document>document</option><option value=browser>browser</option></select> <span class=arrow-icon></span></span></label><div class=language__details><p>Detected language: <code id=detected-language>-</code></p><p>Translation loaded: <code id=translation-found>-</code></p><p>Current language: <code id=current-active-language>-</code></p></div></div></div></div></section><section class=gui-options-section><div class=section__header><div class=section-title><h3>GUI Options</h3></div><div class=section-description></div></div><div class="grid section__body"><div class="sub-section consent-modal"><h4>Consent Modal</h4><label for=cm-layout class=select-label><span>Layout</span><span class=select-input> <select id=cm-layout name=layout><option value=box>box</option><option value="box inline">box inline</option><option value="box wide">box wide</option><option value=cloud>cloud</option><option value="cloud inline">cloud inline</option><option value=bar>bar</option><option value="bar inline">bar inline</option></select> <span class=arrow-icon></span></span></label> <label for=cm-position class=select-label><span>Position</span><span class=select-input> <select id=cm-position name=vertical></select> <span class=arrow-icon></span></span></label><div class=checkbox-group><div class="checkbox-div flip"><input id=cm-flip type=checkbox name=flip> <label for=cm-flip>Flip buttons</label></div><div class="checkbox-div weight"><input id=cm-weight type=checkbox name=weight> <label for=cm-weight>Equal weight buttons</label></div></div></div><div class="sub-section preferences-modal"><h4>Preferences Modal</h4><label for=pm-layout class=select-label><span>Layout</span><span class=select-input> <select id=pm-layout name=layout><option value=box>box</option><option value=bar>bar</option><option value="bar wide">bar wide</option></select> <span class=arrow-icon></span></span></label> <label for=pm-position class=select-label><span>Position</span><span class=select-input> <select id=pm-position name=position><option value=left data-excludedLayout=box>left</option><option value=right data-excludedLayout=box>right</option></select> <span class=arrow-icon></span></span></label><div class=checkbox-group><div class="checkbox-div flip"><input id=pm-flip type=checkbox name=flip> <label for=pm-flip>Flip buttons</label></div><div class="checkbox-div weight"><input id=pm-weight type=checkbox name=weight> <label for=pm-weight>Equal weight buttons</label></div></div><button class=styled-btn type=button data-cc=show-preferencesModal>Open Preferences Modal</button></div><div class="sub-section misc"><h4>Misc</h4><div class=checkbox-group><div class=checkbox-div><input id=darkmode-checkbox type=checkbox name=darkmode> <label for=darkmode-checkbox>Enable dark-mode</label></div><div class=checkbox-div><input id=disablePageInteraction-checkbox type=checkbox name=disablePageInteraction> <label for=disablePageInteraction-checkbox>Disable page interaction</label></div><div class=checkbox-div><input id=disableTransitions-checkbox type=checkbox name=disableTransitions> <label for=disableTransitions-checkbox>Disable transitions</label></div></div><button class=styled-btn type=button id=reset-btn>🗑️ Reset demo/config</button></div></div></section><section class=themes-section><div class=section__header><div class=section-title><h3>Themes</h3></div><div class=section-description></div></div><div class=section__body><div class="grid themes"><label for=default-light><input id=default-light type=radio name=theme checked=checked> <span class=input-label><span class=theme-type>(built-in)</span> <span class=theme-name>Light theme</span></span></label> <label for=cc--darkmode><input id=cc--darkmode type=radio name=theme> <span class=input-label><span class=theme-type>(built-in)</span> <span class=theme-name>Dark theme</span></span></label></div></div></section></main><footer data-astro-cid-scinlfmn><p data-astro-cid-scinlfmn>This is an open source banner, which was adjusted for WordPress. The original source code of the banner is brought to you by Orest Bida and many contributors and is released under the MIT License. Check out <a style=color:#bec0c2;text-decoration:underline target=_blank target=_blank data-astro-cid-scinlfmn href=https://github.com/orestbida/cookieconsent aria-label="Github repository" class="github-icon styled-link styled-link__2">github</a>. Copyright © 2020-present <a style=color:#bec0c2;text-decoration:underline target=_blank data-astro-cid-scinlfmn href=https://orestbida.com/contact>Orest Bida</a></p><p data-astro-cid-scinlfmn></p></footer></body></html>1 <!DOCTYPE html><html lang=en><head><meta charset=UTF-8><meta content="width=device-width" name=viewport><script>let pluginUrl,restURL,nonce;function bootstrapBanner(){const e=[{tag:"script",attributes:[{attr:"src",value:`${pluginUrl}admin/js/iframeResizer/iframeResizer.contentWindow.min.js`}]}];insertFiles("script",[{tag:"script",attributes:[{attr:"as",value:"script"},{attr:"type",value:"module"},{attr:"id",value:"nscbarNewBannerPlaygroundScript"},{attr:"src",value:`${pluginUrl}admin/new-banner/_astro/index.js`}]},{tag:"link",attributes:[{attr:"rel",value:"stylesheet"},{attr:"href",value:`${pluginUrl}admin/new-banner/_astro/index.css`}]}]),insertFiles("body",e)}function insertFiles(e,n){for(let t=0;t<n.length;t+=1){let r=document.getElementsByTagName(e)[0],o=document.createElement(n[t].tag);for(let e=0;e<n[t].attributes.length;e+=1)o[n[t].attributes[e].attr]=n[t].attributes[e].value;r.parentNode.insertBefore(o,r)}}function isValidWpNonce(e){return!/[^\w]/.test(e)}function isHttpUrl(e){try{const n=new URL(e);if("https:"===n.protocol||"http:"===n.protocol)return!0}catch(n){return console.error("Beautiful cookie Banner: Invalid URL:",e,n),!1}return!1}window.addEventListener("message",(e=>{"true"===localStorage.getItem("nscDebugLog")&&console.log("BCB: iFrame loaded, getting message",e),e&&e.data&&"beautiful-cookie-banner"===e.data.source?e.origin===window.location.origin?(({pluginUrl:pluginUrl,restURL:restURL,nonce:nonce}=e.data),isHttpUrl(pluginUrl)?isValidWpNonce(nonce)?(window.restURL=restURL,window.nonce=nonce,pluginUrl&&window.restURL&&window.nonce||console.error("Beautiful cookie Banner: Missing required data from parent admin.",pluginUrl,window.restURL,window.nonce),bootstrapBanner()):console.error("Beautiful cookie Banner: Invalid nonce:",nonce):console.error("Beautiful cookie Banner: Invalid plugin URL:",pluginUrl)):console.error("Beautiful cookie Banner: Received message from unknown origin:",e.origin):"true"===localStorage.getItem("nscDebugLog")&&console.log("BCB: IGNORING message",pluginUrl,restURL,nonce,e)}))</script></head><body><header><h1 class=page-title>Banner 2 Settings</h1><h2 class=page-subtitle>Currently, the options for this banner are somewhat limited, but don't worry — future updates will bring more flexibility. If you have any ideas or features you'd like to see, we'd love to hear from you! Just shoot us an email at info@beautiful-cookie-banner.com.</h2><h2 class=page-subtitle>To access the preference modal, simply apply the class 'nsc-bara-manage-cookie-settings' to any link. Clicking on this link will then open the preferences modal.</h2><button class=nscbutton type=button id=downloadConfigBtn><span class=nscbutton__text>Save Banner Configs</span></button> <a style=padding-left:10px;cursor:pointer onclick="CookieConsent.eraseCookies("cc_cookie"),CookieConsent.show(!0)">show banner again</a><h2 class=page-subtitle id=nscBarErrorMessage style=display:none;background:#d32f2f;color:#e0e0e0;padding:1em>dffd</h2></header><main><section class=categories-section><div class="grid section__body"><div class=sub-section><h4 class=categories-title>Categories</h4><p class=categories-description>Categories can be edited in tab "Categories"</p><div class="custom-inputs custom-inputs--categories" id=bannerCategoriesSelect></div></div><div class="sub-section translations" id=translations-section><h4 class=translations-title>Translations</h4><p class=translations-description>Select the translations to include in your configuration. Languages can be added or removed in tab "Multilanguage".</p><div class=custom-inputs id=langInputs></div><button class=styled-btn type=button id=edit-translations-btn data-a11y-dialog-show=edit-translations-dialog>Edit translations</button><div class=dialog-container id=edit-translations-dialog aria-hidden=true aria-labelledby=dialog-title><div class=dialog-overlay></div><div class=dialog-content role=document><div class=dialog-header><div class=dialog-header--left><h1 class=dialog-title id=dialog-title>Current translation</h1><label for=editor-language-codes class=select-translation><select id=editor-language-codes></select> <span class=arrow-icon></span></label></div><button class="styled-btn dialog-close-btn" type=button data-a11y-dialog-hide aria-label="Close dialog">×</button></div><div class=dialog-body><div class=translations-editor id=editor-container><div class=translation-editor id=translation-editor><div class="editor editor--cm"><h4>Consent modal</h4><textarea id=consent-modal-title placeholder=Title spellcheck=false class=small-textarea></textarea> <textarea id=consent-modal-description placeholder=Description spellcheck=false></textarea> <input id=close-icon-label type=text placeholder="X/Close icon label" spellcheck=false> <input id=consent-modal-accept-btn type=text placeholder="Accept all button" spellcheck=false> <input id=consent-modal-reject-btn type=text placeholder="Reject all button" spellcheck=false> <input id=consent-modal-manage-btn type=text placeholder="Manage preferences button" spellcheck=false><div class=footer-textarea id=textarea-cm-footer><textarea id=editing placeholder=Footer spellcheck=false></textarea></div></div><div class="editor editor--pm"><h4>Preferences modal</h4><textarea id=pm-title placeholder=Title spellcheck=false class=small-textarea></textarea> <input id=pm-close-icon-label type=text placeholder="Close icon label" spellcheck=false> <input id=pm-accept-btn type=text placeholder="Accept all button" spellcheck=false> <input id=pm-reject-btn type=text placeholder="Reject all button" spellcheck=false> <input id=pm-save-btn type=text placeholder="Save preferences button" spellcheck=false> <input id=pm-service-counter-label type=text placeholder="Service counter label" spellcheck=false><div class=pm-sections><h3 class=pm-sections-title>Sections <span id=sections-counter></span></h3><ol id=pm-sections></ol><button class=styled-btn type=button id=add-section-btn>Add section</button></div></div></div></div></div><div class=dialog-footer><button class=styled-btn type=button id=save-translation-config-btn data-a11y-dialog-hide>Save & Preview</button></div></div></div></div><div class="sub-section language-more-options"><h4>Language options</h4><div class=default-language><label for=default-language class=select-label><span>Default lang.</span><span class=select-input> <select id=default-language name=default-language><option value=disabled disabled=disabled selected=selected>—</option></select> <span class=arrow-icon></span></span></label></div><div class=auto-language><div class=checkbox-div><input id=auto-language type=checkbox name=autoLanguage> <label for=auto-language>Auto detect language</label></div><label for=autodetect-mode class="select-label autodetect"><span>Detect from</span><span class=select-input> <select id=autodetect-mode name=autodetect disabled=disabled><option value=document>document</option><option value=browser>browser</option></select> <span class=arrow-icon></span></span></label><div class=language__details><p>Detected language: <code id=detected-language>-</code></p><p>Translation loaded: <code id=translation-found>-</code></p><p>Current language: <code id=current-active-language>-</code></p></div></div></div></div></section><section class=gui-options-section><div class=section__header><div class=section-title><h3>GUI Options</h3></div><div class=section-description></div></div><div class="grid section__body"><div class="sub-section consent-modal"><h4>Consent Modal</h4><label for=cm-layout class=select-label><span>Layout</span><span class=select-input> <select id=cm-layout name=layout><option value=box>box</option><option value="box inline">box inline</option><option value="box wide">box wide</option><option value=cloud>cloud</option><option value="cloud inline">cloud inline</option><option value=bar>bar</option><option value="bar inline">bar inline</option></select> <span class=arrow-icon></span></span></label> <label for=cm-position class=select-label><span>Position</span><span class=select-input> <select id=cm-position name=vertical></select> <span class=arrow-icon></span></span></label><div class=checkbox-group><div class="checkbox-div flip"><input id=cm-flip type=checkbox name=flip> <label for=cm-flip>Flip buttons</label></div><div class="checkbox-div weight"><input id=cm-weight type=checkbox name=weight> <label for=cm-weight>Equal weight buttons</label></div></div></div><div class="sub-section preferences-modal"><h4>Preferences Modal</h4><label for=pm-layout class=select-label><span>Layout</span><span class=select-input> <select id=pm-layout name=layout><option value=box>box</option><option value=bar>bar</option><option value="bar wide">bar wide</option></select> <span class=arrow-icon></span></span></label> <label for=pm-position class=select-label><span>Position</span><span class=select-input> <select id=pm-position name=position><option value=left data-excludedLayout=box>left</option><option value=right data-excludedLayout=box>right</option></select> <span class=arrow-icon></span></span></label><div class=checkbox-group><div class="checkbox-div flip"><input id=pm-flip type=checkbox name=flip> <label for=pm-flip>Flip buttons</label></div><div class="checkbox-div weight"><input id=pm-weight type=checkbox name=weight> <label for=pm-weight>Equal weight buttons</label></div></div><button class=styled-btn type=button data-cc=show-preferencesModal>Open Preferences Modal</button></div><div class="sub-section misc"><h4>Misc</h4><div class=checkbox-group><div class=checkbox-div><input id=darkmode-checkbox type=checkbox name=darkmode> <label for=darkmode-checkbox>Enable dark-mode</label></div><div class=checkbox-div><input id=disablePageInteraction-checkbox type=checkbox name=disablePageInteraction> <label for=disablePageInteraction-checkbox>Disable page interaction</label></div><div class=checkbox-div><input id=disableTransitions-checkbox type=checkbox name=disableTransitions> <label for=disableTransitions-checkbox>Disable transitions</label></div></div><button class=styled-btn type=button id=reset-btn>🗑️ Reset demo/config</button></div></div></section><section class=themes-section><div class=section__header><div class=section-title><h3>Themes</h3></div><div class=section-description></div></div><div class=section__body><div class="grid themes"><label for=default-light><input id=default-light type=radio name=theme checked=checked> <span class=input-label><span class=theme-type>(built-in)</span> <span class=theme-name>Light theme</span></span></label> <label for=cc--darkmode><input id=cc--darkmode type=radio name=theme> <span class=input-label><span class=theme-type>(built-in)</span> <span class=theme-name>Dark theme</span></span></label></div></div></section></main><footer data-astro-cid-scinlfmn><p data-astro-cid-scinlfmn>This is an open source banner, which was adjusted for WordPress. The original source code of the banner is brought to you by Orest Bida and many contributors and is released under the MIT License. Check out <a style=color:#bec0c2;text-decoration:underline target=_blank target=_blank data-astro-cid-scinlfmn href=https://github.com/orestbida/cookieconsent aria-label="Github repository" class="github-icon styled-link styled-link__2">github</a>. Copyright © 2020-present <a style=color:#bec0c2;text-decoration:underline target=_blank data-astro-cid-scinlfmn href=https://orestbida.com/contact>Orest Bida</a></p><p data-astro-cid-scinlfmn></p></footer></body></html> -
beautiful-and-responsive-cookie-consent/trunk/admin/tpl/admin.php
r3215348 r3305665 34 34 35 35 <script> 36 const nscBarConsentType = `<?php echo $exposeJSConsentType ?>`; const nscBarCookieTypes = <?php echo $exposeJSCookieTypes ?> 36 const nscBarConsentType = `<?php echo $exposeJSConsentType ?>`; 37 const nscBarCookieTypes = <?php echo $exposeJSCookieTypes ?> 37 38 </script> 38 39 … … 66 67 67 68 // here all tabs go with newBanner not set at all 68 69 69 70 $activeTab = ""; 70 71 if ($tab->active === true) { … … 82 83 83 84 if (empty($_GET["tab"]) === false && $_GET["tab"] === "new_banner") { 84 $rest_url = urlencode(get_rest_url());85 85 $nonce = wp_create_nonce('wp_rest'); 86 86 echo wp_kses($objSettings->setting_page_fields->tabs[$active_tab_index]->tab_description, $allowed_html); … … 88 88 echo '<script>localStorage.setItem("nscBaraCookieBannerState",JSON.stringify(' . $fallbackStateNewBanner . '));</script>'; 89 89 } 90 echo '<script>addEventListener("load", (event) => {iFrameResize({ log: false, minHeight: 500 }, "#nsc_bar_new_banner");}); </script><iframe width="100%" id="nsc_bar_new_banner" src="' . NSC_BAR_PLUGIN_URL . 'admin/new-banner/index.html?plugin_url_encoded=' . urlencode(NSC_BAR_PLUGIN_URL) . '&rest_url_encoded=' . $rest_url . '&wp_nonce=' . $nonce . '&cb=' . NSC_BAR_PLUGIN_VERSION . '"></iframe>'; 90 echo '<script>addEventListener("load", (event) => {iFrameResize({ log: false, minHeight: 500 }, "#nsc_bar_new_banner");}); 91 </script><iframe width="100%" 92 id="nsc_bar_new_banner" 93 src="' . NSC_BAR_PLUGIN_URL . 'admin/new-banner/index.html?cb=' . NSC_BAR_PLUGIN_VERSION . '"> 94 </iframe> 95 <script> 96 (function(){ 97 const iframe = document.getElementById("nsc_bar_new_banner"); 98 iframe.addEventListener("load", ()=>{ 99 const config = { 100 source: "beautiful-cookie-banner", 101 pluginUrl: "' . esc_url(NSC_BAR_PLUGIN_URL) . '", 102 restURL: "' . esc_url(get_rest_url()) . '", 103 nonce: "' . esc_js($nonce) . '" 104 }; 105 if(localStorage.getItem("nscDebugLog") === "true") { 106 console.log("iFrame loaded, sending config",config); 107 } 108 iframe.contentWindow.postMessage(config, window.location.origin); 109 }); 110 })(); 111 </script>'; 91 112 } 92 113 -
beautiful-and-responsive-cookie-consent/trunk/admin/tpl/legacy.php
r3261487 r3305665 95 95 <?php echo $form_fields->nsc_bar_return_form_field($field_configs, $objSettings->plugin_prefix); ?> 96 96 <?php 97 if (!empty($field_configs->custom_component)) { 98 $rest_url = get_rest_url(); 99 $nonce = wp_create_nonce('wp_rest'); 100 $string = str_replace("{{REST_URL_ENCODED}}", urlencode($rest_url), $field_configs->custom_component); 101 echo str_replace("{{WP_NONCE}}", $nonce, $string); 97 if (empty($field_configs->custom_component) === false && empty($field_configs->plugin_url) === true) { 98 // introduced in v3.8.4 99 echo '<div class="nsc_bar_notice_error py-4 px-3 mt-2"> 100 <p>All good - your current configuration is still working smoothly! 101 However, to make any changes, you\'ll need to update to the latest version of the add-on. 102 Unfortunately, older versions of the add-on aren\'t compatible with the newest version of the main plugin.</p> 103 </div>'; 104 } 105 106 if (empty($field_configs->custom_component) === false && empty($field_configs->plugin_url) === false) { 107 echo ' 108 <iframe width="100%" 109 id="nsc_bar_cc_' . esc_attr($field_configs->field_slug) . '" 110 src="' . $field_configs->custom_component . '"> 111 </iframe> 112 <script> 113 addEventListener("load", (event) => {iFrameResize({ log: false, minHeight: 500 }, "#nsc_bar_cc_' . esc_attr($field_configs->field_slug) . '");}); 114 (function(){ 115 const iframe = document.getElementById("nsc_bar_cc_' . esc_attr($field_configs->field_slug) . '"); 116 iframe.addEventListener("load", ()=>{ 117 const config = { 118 source: "beautiful-cookie-banner", 119 pluginUrl: "' . esc_url($field_configs->plugin_url) . '", 120 mainPluginUrl: "' . esc_url(NSC_BAR_PLUGIN_URL) . '", 121 restURL: "' . esc_url(get_rest_url()) . '", 122 nonce: "' . esc_js(wp_create_nonce('wp_rest')) . '" 123 }; 124 if(localStorage.getItem("nscDebugLog") === "true") { 125 console.log("iFrame loaded, sending config",config); 126 } 127 iframe.contentWindow.postMessage(config, window.location.origin); 128 }); 129 })(); 130 </script>'; 102 131 } 103 132 ?> -
beautiful-and-responsive-cookie-consent/trunk/nsc_bar-cookie-consent.php
r3285444 r3305665 4 4 Description: An easy way to get a beautiful GDPR Cookie Consent Banner. Customize it to match your compliance requirements and website layout. Highly customisable and responsive. 5 5 Author: Beautiful Cookie Banner 6 Version: 4.6. 16 Version: 4.6.2 7 7 Author URI: https://beautiful-cookie-banner.com 8 8 Text Domain: bar-cookie-consent … … 29 29 define("NSC_BAR_PLUGIN_DIR", dirname(__FILE__)); 30 30 define("NSC_BAR_PLUGIN_URL", plugin_dir_url(__FILE__)); 31 define("NSC_BAR_PLUGIN_VERSION", "4. 5.4");31 define("NSC_BAR_PLUGIN_VERSION", "4.6.2"); 32 32 define("NSC_BAR_SLUG_DBVERSION", "nsc_bar_db_version"); 33 33 -
beautiful-and-responsive-cookie-consent/trunk/readme.txt
r3285444 r3305665 6 6 Requires PHP: 7.0.0 7 7 License: GPLv3 8 Stable tag: 4.6. 18 Stable tag: 4.6.2 9 9 10 10 Free and beautiful Cookie Consent Banner to make your website compliant. Highly customizable and not loading any files from 3rd party servers. … … 119 119 == Changelog == 120 120 121 = 4.6.2 = 122 - FIX: Fix potential XSS Vulnerability 123 121 124 = 4.6.1 = 122 125 - FIX: made validation more forgiving: in some misconfigured cases there was a fatal error.
Note: See TracChangeset
for help on using the changeset viewer.