1var __awaiter=this&&this.__awaiter||function(e,c,s,r){return new(s=s||Promise)(function(o,t){function n(e){try{a(r.next(e))}catch(e){t(e)}}function i(e){try{a(r.throw(e))}catch(e){t(e)}}function a(e){var t;e.done?o(e.value):((t=e.value)instanceof s?t:new s(function(e){e(t)})).then(n,i)}a((r=r.apply(e,c||[])).next())})},__generator=this&&this.__generator||function(n,i){var a,c,s,r={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]},e={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(o){return function(e){var t=[o,e];if(a)throw new TypeError("Generator is already executing.");for(;r;)try{if(a=1,c&&(s=2&t[0]?c.return:t[0]?c.throw||((s=c.return)&&s.call(c),0):c.next)&&!(s=s.call(c,t[1])).done)return s;switch(c=0,(t=s?[2&t[0],s.value]:t)[0]){case 0:case 1:s=t;break;case 4:return r.label++,{value:t[1],done:!1};case 5:r.label++,c=t[1],t=[0];continue;case 7:t=r.ops.pop(),r.trys.pop();continue;default:if(!(s=0<(s=r.trys).length&&s[s.length-1])&&(6===t[0]||2===t[0])){r=0;continue}if(3===t[0]&&(!s||t[1]>s[0]&&t[1]<s[3]))r.label=t[1];else if(6===t[0]&&r.label<s[1])r.label=s[1],s=t;else{if(!(s&&r.label<s[2])){s[2]&&r.ops.pop(),r.trys.pop();continue}r.label=s[2],r.ops.push(t)}}t=i.call(n,r)}catch(e){t=[6,e],c=0}finally{a=s=0}if(5&t[0])throw t[1];return{value:t[0]?t[1]:void 0,done:!0}}}},COOKIE_SPOOL_API="https://api.cookiespool.com",CookieSpool=function(){function e(e){var t=this;this.config=e,this.postData(COOKIE_SPOOL_API+"/site",{tenantId:e.tenantId,siteId:e.siteId,language:e.language}).then(function(e){t.siteData=e;e=t.readCookieSpoolCookie();t.siteData.isFooterButtonEnabled&&(document.body.insertBefore(t.createFooterButton(),document.body.firstChild),t.footer=document.querySelector("#cookiespool-footer")),e.userId?t.openFooter():(document.body.insertBefore(t.createBanner(),document.body.firstChild),t.banner=document.querySelector("#cookiespool-banner"),t.openBanner(),t.closeFooter()),document.body.insertBefore(t.createSettingsPopup(),document.body.firstChild),t.settingsPopup=document.querySelector("#cookiespool-modal-container")})}return e.prototype.createBanner=function(){var e=this,t=document.createDocumentFragment(),o=document.createElement("div"),n=(o.id="cookiespool-banner",document.createElement("div")),i=(n.className="cookiespool-cookies",document.createElement("div")),a=document.createElement("p"),c=(a.innerText=this.siteData.texts["banner.text"]+" ",i.appendChild(a),document.createElement("a")),a=(c.id="bannerPolicy",c.innerText=this.siteData.texts["popup.cookiePolicy"],c.href=this.siteData.texts["popup.cookiePolicyLink"],a.appendChild(c),n.appendChild(i),document.createElement("div")),c=(a.className="cookiespool-buttons",document.createElement("button")),c=(c.innerText=this.siteData.texts["banner.acceptButton"],c.id="banner-accept-button",c.name="banner-accept-button",c.addEventListener("click",function(){e.sendUpdate(e.createConsent({userId:null,performance:!0,marketing:!0,functional:!0})),e.closeBanner(),e.openFooter()}),a.appendChild(c),this.siteData.isBannerRejectButtonEnabled&&((i=document.createElement("button")).innerText=this.siteData.texts["banner.rejectButton"],i.addEventListener("click",function(){e.sendUpdate(e.createConsent({userId:null,performance:!1,marketing:!1,functional:!1})),e.closeBanner(),e.openFooter()}),a.appendChild(i)),document.createElement("button"));return c.innerText=this.siteData.texts["banner.settingsButton"],c.addEventListener("click",function(){e.openSettings(),e.closeBanner()}),a.appendChild(c),n.appendChild(a),o.appendChild(n),t.appendChild(o),t},e.prototype.createSettingsPopup=function(){var r=this,e=document.createDocumentFragment(),t=document.createElement("div"),o=(t.id="cookiespool-modal-container",document.createElement("div")),n=(o.id="cookiespool-popup",document.createElement("div")),i=(n.className="cookiespool-window",document.createElement("div")),a=(i.className="cookiespool-header",document.createElement("p")),a=(a.className="cookiespool-title",a.innerText=this.siteData.texts["popup.title"],i.appendChild(a),document.createElement("p")),c=(a.className="
1cookiespool-subtitle",a.innerText=this.siteData.texts["popup.subtitle"],i.appendChild(a),document.createElement("a")),a=(c.id="policy",c.innerText=this.siteData.texts["popup.cookiePolicy"],c.href=this.siteData.texts["popup.cookiePolicyLink"],c.target="_blank",a.appendChild(c),n.appendChild(i),document.createElement("div"));a.className="cookiespool-actions";(c=document.createElement("button")).id="accept",c.innerText=this.siteData.texts["popup.acceptAllButton"],a.appendChild(c);var i=document.createElement("button"),s=(i.id="cancel",i.innerText=this.siteData.texts["popup.rejectAllButton"],a.appendChild(i),this.readCookieSpoolCookie()),l=(c.addEventListener("click",function(){s.choices={functional:!0,marketing:!0,performance:!0},r.sendUpdate(s),r.closeSettings()}),i.addEventListener("click",function(){s.choices={functional:!1,marketing:!1,performance:!1},r.sendUpdate(s),r.closeSettings()}),n.appendChild(a),document.createElement("ul")),i=(l.id="accordion",[{id:"mandatory",title:this.siteData.texts["popup.mandatoryCookies.name"]},{id:"performance",title:this.siteData.texts["popup.performanceCookies.name"]},{id:"functional",title:this.siteData.texts["popup.functionalCookies.name"]},{id:"marketing",title:this.siteData.texts["popup.marketingCookies.name"]}].forEach(function(o){var e=r.readCookieSpoolCookie(),t=document.createElement("li"),n=document.createElement("div"),i=(n.className="cookiespool-ss",document.createElement("div")),a=(i.className="cookiespool-option","mandatory"!=o.id?((c=document.createElement("div")).className="cookiespool-check",(a=document.createElement("input")).type="checkbox",a.checked=!0===e.choices[o.id],a.name=o.id,a.addEventListener("change",function(e){var t=r.readCookieSpoolCookie(),e=e.target;t.choices[o.id]=e.checked,r.writeCookieSpoolCookie(t)}),c.appendChild(a),i.appendChild(c)):((e=document.createElement("p")).className="cookiespool-warning",e.innerText=r.siteData.texts["popup.mandatory"],i.appendChild(e)),n.appendChild(i),t.appendChild(n),document.createElement("div")),c=(a.className="cookiespool-panel",document.createElement("div")),s=document.createElement("button"),e=(s.innerHTML=o.title+'<span style="display:inline; font-size:20px; color:gray !important"> ⌄</span>',s.addEventListener("click",function(){var e=s.parentElement.parentElement.nextElementSibling;r.activeContentElement?r.activeContentElement==e?(e.style.maxHeight="0px",r.activeContentElement=null):(r.activeContentElement.style.maxHeight="0px",e.style.maxHeight=e.scrollHeight+"px",r.activeContentElement=e):(e.style.maxHeight=e.scrollHeight+"px",r.activeContentElement=e)}),c.appendChild(s),a.appendChild(c),t.appendChild(a),document.createElement("ul")),i=(e.className="cookiespool-content",document.createElement("li")),n=document.createElement("p");n.innerText=r.siteData.texts["popup."+o.id+"Cookies.description"],i.appendChild(n),e.appendChild(i),t.appendChild(e),l.appendChild(t)}),n.appendChild(l),document.createElement("div"));i.className="cookiespool-actions";(c=document.createElement("button")).id="accept",c.innerText=this.siteData.texts["popup.saveSettings"],i.appendChild(c);var a=document.createElement("a"),p=(a.id="cookiespoollink",a.innerText="Cookiespool",a.href="https://cookiespool.com",a.target="_blank",i.appendChild(a),this.readCookieSpoolCookie()),a=(c.addEventListener("click",function(){Object.keys(p.choices).forEach(function(e){var t=document.querySelector('#cookiespool-popup input[name="'+e+'"]');p.choices[e]=t.checked}),r.sendUpdate(p),r.closeSettings()}),n.appendChild(i),this.readCookieSpoolCookie()),a=(a.userId&&((c=document.createElement("div")).className="cookiespool-actions",(i=document.createElement("p")).id="consentid",i.innerText="consent id: "+a.userId,c.appendChild(i),n.appendChild(c)),document.createElement("div"));return a.className="cookiespool-pad",n.appendChild(a),o.appendChild(n),t.appendChild(o),this.config.enableClose&&t.addEventListener("click",function(e){e.target==e.currentTarget&&(e.target.style.display="none",document.getElementById("cookiespool-footer"))&&(document.getElementById("cookiespool-footer").style.display="flex")}),e.appendChild(t),e},e.prototype.createFooterButton=function(){var e=this,t=document.createDocumentFragment(),o=document.createElement("div"),n=(o.id="cookiespool-footer",o.className="
1cookiespool-footertooltip",document.createElement("button")),i=(n.className="cookiespool-footerbutton","tr"===this.config.language?"çerez izin ayarları":"cookie consent settings");return n.innerHTML='<img class="cookiespool-footer-img" border="0" src='+this.siteData.footerButtonImageUrl+'>\n <span class="cookiespool-footertooltiptext">'+i+"</span>",n.addEventListener("click",function(){e.openSettings(),e.closeFooter()}),o.appendChild(n),t.appendChild(o),t},e.prototype.openBanner=function(){this.banner.style.display="flex"},e.prototype.closeBanner=function(){this.banner.style.display="none"},e.prototype.openFooter=function(){this.siteData.isFooterButtonEnabled&&(this.footer.style.display="flex")},e.prototype.closeFooter=function(){this.siteData.isFooterButtonEnabled&&(this.footer.style.display="none")},e.prototype.openSettings=function(){var t=this.readCookieSpoolCookie();Object.keys(t.choices).forEach(function(e){document.querySelector('#cookiespool-popup input[name="'+e+'"]').checked=!0===t.choices[e]}),this.settingsPopup.style.display="flex"},e.prototype.closeSettings=function(){this.settingsPopup.style.display="none",this.openFooter()},e.prototype.readCookieSpoolCookie=function(){for(var e="cookiespool_consent",t=document.cookie.split(";"),o=0;o<t.length;o++){var n=t[o].trim();if(0==n.indexOf(e))return JSON.parse(n.substring(e.length+1,n.length))}return this.createConsent({userId:null,performance:!1,marketing:!1,functional:!1})},e.prototype.writeCookieSpoolCookie=function(e){var t=new Date,o="";0<this.siteData.consentExpireDayLength&&(t.setTime(t.getTime()+24*this.siteData.consentExpireDayLength*60*60*1e3),o="; expires="+t.toUTCString()),document.cookie="cookiespool_consent="+JSON.stringify(e)+o+"; path=/"},e.prototype.createConsent=function(e){var t=e.userId,o=e.performance,n=e.marketing,e=e.functional;return{tenantId:this.config.tenantId,siteId:this.config.siteId,userId:t,choices:{performance:o,marketing:n,functional:e}}},e.prototype.sendUpdate=function(t){var o=this;this.postData(COOKIE_SPOOL_API+"/consent",t).then(function(e){t.userId=e.userId,o.writeCookieSpoolCookie(t),o.config.onChangeSettings&&o.config.onChangeSettings(t)})},e.prototype.postData=function(t,o){return void 0===t&&(t=""),void 0===o&&(o={}),__awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:return[4,fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(o)})];case 1:return[2,e.sent().json()]}})})},e}();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.